Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] TiBook II G4 667Mhz, Sound start then stop
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC
View previous topic :: View next topic  
Author Message
lagrenouille
n00b
n00b


Joined: 08 Jan 2006
Posts: 18
Location: Liège (BELGIUM)

PostPosted: Thu Feb 28, 2008 5:12 pm    Post subject: [solved] TiBook II G4 667Mhz, Sound start then stop Reply with quote

Hello,

i have a strange problem with my TiBook and alsa (with oss emulation and snd-powermac driver).

The sound cards seems to be detected well and the beep is working.

When i try to read a mp3 (with mplayer for example), the sound start for like 2-5 seconds then it stop.
Mplayer isnt reading anymore and when i hit 'ctrl+c' twice, i have to wait a few seconds for mplayer to be killed.
(The problem has nothing to do with mplayer, i know it is just an example^^..)

By the way, i can hear the sound.. not just beep, so i suppose my cards is ok.
Furthermore, after i doubled 'ctrl+c' mplayer and waited for it to die, i can launch it again and it start (then stop) reading (without any intermediate operation) the mp3.

As a test for concurent sound use, i launched another instance of mplayer.. the result is below.. it says that the device is busy.

i can :
use alsamixer and save state
save state for the card with alsactl.
aplay detect the card too.


> mplayer mymp3.mp3
==========================================================================
Ouverture décodeur audio : [mp3lib] MPEG layer-2, layer-3
AUDIO: 44100 Hz, 2 ch, s16be, 128.0 kbit/9.07% (ratio: 16000->176400)
Codec audio sélectionné : [mp3] afm : mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
AO: [oss] 44100Hz 2ch s16be (2 bytes per sample)
Vidéo : pas de vidéo
Démarre la lecture...
A: 5.3 (05.2) of 248.0 (04:08.0) 2.8%


If i try reading another mp3 while the first instance of mplayer is idle, it says :

> mplayer anothermp3.mp3
==========================================================================
Ouverture décodeur audio : [mp3lib] MPEG layer-2, layer-3
AUDIO: 44100 Hz, 2 ch, s16be, 128.0 kbit/9.07% (ratio: 16000->176400)
Codec audio sélectionné : [mp3] afm : mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
[AO OSS] audio_setup: Impossible ouvrir périphérique audio /dev/dsp : Device or resource busy
[AO_ALSA] alsa-lib: pcm_dmix.c:864:(snd_pcm_dmix_open) unable to open slave
[AO_ALSA] Erreur ouverture de lecture : Device or resource busy
[AO ESD] Echec de esd_open_sound : No such file or directory
[AO SDL] Ãchantillonnage : 44100Hz Canaux : Stereo Format s16be
[AO_ALSA] alsa-lib: pcm_dmix.c:864:(snd_pcm_dmix_open) unable to open slave
[AO SDL] Impossible ouvrir audio : No available audio device
DVB card number must be between 1 and 4
AO: [null] 44100Hz 2ch s16be (2 bytes per sample)
Vidéo : pas de vidéo
Démarre la lecture...
A: 7.7 (07.6) of 248.0 (04:08.0) 3.1%



Hardware and software :
Linux localhost 2.6.23-gentoo-r8

(PowerBook Titanium G4 667Mhz)
processor : 0
cpu : 7450, altivec supported
clock : 667.000000MHz
revision : 0.1 (pvr 8000 0201)
bogomips : 66.30
timebase : 33290001
platform : PowerMac
machine : PowerBook3,3
motherboard : PowerBook3,3 MacRISC2 MacRISC Power Macintosh
detected as : 72 (PowerBook Titanium II)
pmac flags : 0000001b
L2 cache : 256K unified
pmac-generation : NewWorld

Alsa (with oss emulation) is built in the kernel while the snd-powermac driver is built it as a module (as u can see below)
I load snd-powermac with the /etc/modules.autoload/kernel-2.6 (wich loads allright)
I have emerged the latest avaible stable version of alsa-lib, alsa-oss, alsa-headers, alsa-tools, alsa-utils but havent emerged alsa-driver.


Here is my kernel config :

#
# Sound
#
CONFIG_SOUND=y

#
# Advanced Linux Sound Architecture
#
CONFIG_SND=y
CONFIG_SND_TIMER=y
CONFIG_SND_PCM=y
CONFIG_SND_HWDEP=m
CONFIG_SND_RAWMIDI=m
CONFIG_SND_SEQUENCER=y
CONFIG_SND_SEQ_DUMMY=y
CONFIG_SND_OSSEMUL=y
CONFIG_SND_MIXER_OSS=y
CONFIG_SND_PCM_OSS=y
CONFIG_SND_PCM_OSS_PLUGINS=y
CONFIG_SND_SEQUENCER_OSS=y
# CONFIG_SND_DYNAMIC_MINORS is not set
CONFIG_SND_SUPPORT_OLD_API=y
CONFIG_SND_VERBOSE_PROCFS=y
# CONFIG_SND_VERBOSE_PRINTK is not set
# CONFIG_SND_DEBUG is not set

#
# ALSA PowerMac devices
#
CONFIG_SND_POWERMAC=m
CONFIG_SND_POWERMAC_AUTO_DRC=y

#
# Apple Onboard Audio driver
#
CONFIG_SND_AOA=m
CONFIG_SND_AOA_FABRIC_LAYOUT=m
CONFIG_SND_AOA_ONYX=m
CONFIG_SND_AOA_TAS=m
CONFIG_SND_AOA_TOONIE=m
CONFIG_SND_AOA_SOUNDBUS=m
CONFIG_SND_AOA_SOUNDBUS_I2S=m



Here my lsmod after booting :

Module Size Used by
snd_hwdep 8516 0
radeon 144456 2
drm 88120 3 radeon
snd_powermac 45408 2
pmac_zilog 18692 0
serial_core 20352 1 pmac_zilog
airport 5824 0
orinoco 41716 1 airport
hermes 7008 2 airport,orinoco
snd_aoa_i2sbus 21508 0
snd_aoa_soundbus 6244 1 snd_aoa_i2sbus
ub 18560 0
ohci1394 36592 0
usb_storage 42816 0
yenta_socket 28172 0
rsrc_nonstatic 11168 1 yenta_socket
ieee1394 92864 1 ohci1394
pcmcia_core 41336 2 yenta_socket,rsrc_nonstatic
uninorth_agp 9900 1
agpgart 33884 2 drm,uninorth_agp




Here is what aplay -l says :

**** List of PLAYBACK Hardware Devices ****
card 0: Tumbler [PowerMac Tumbler], device 0: PMac Tumbler [PowerMac Tumbler]
Subdevices: 1/1
Subdevice #0: subdevice #0



Here is what is inside (alsactl store 0 -f) ~/asound :

state.Tumbler {
control.1 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 176'
iface MIXER
name 'Master Playback Volume'
value.0 117
value.1 117
}
control.2 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Master Playback Switch'
value.0 true
value.1 true
}
control.3 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 72'
iface MIXER
name 'Tone Control - Bass'
value 23
}
control.4 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 72'
iface MIXER
name 'Tone Control - Treble'
value 22
}
control.5 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 176'
iface MIXER
name 'PCM Playback Volume'
value 132
}
control.6 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 95'
iface MIXER
name 'DRC Range'
value 57
}
control.7 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Headphone Playback Switch'
value false
}
control.8 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PC Speaker Playback Switch'
value true
}
control.9 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'DRC Switch'
value true
}
control.10 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Auto Mute Switch'
value true
}
control.11 {
comment.access read
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Headphone Detection'
value false
}
control.12 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 100'
iface MIXER
name 'Beep Playback Volume'
value 15
}
}


Here is what is inside /proc/asound :

lrwxrwxrwx 1 root root 5 Feb 27 12:09 Tumbler -> card0
dr-xr-xr-x 3 root root 0 Feb 27 12:09 card0
-r--r--r-- 1 root root 0 Feb 27 12:09 cards
-r--r--r-- 1 root root 0 Feb 27 12:09 devices
dr-xr-xr-x 2 root root 0 Feb 27 12:09 oss
-r--r--r-- 1 root root 0 Feb 27 12:09 pcm
dr-xr-xr-x 2 root root 0 Feb 27 12:09 seq
-r--r--r-- 1 root root 0 Feb 27 12:09 timers
-r--r--r-- 1 root root 0 Feb 27 12:09 version


What can i do :?:
_________________
;;Student-"Institut d'Informatique"(http://www.info.fundp.ac.be/).
;;Working on a Tibook II G4 667MHz without any hardware failure yet (try to find such quality products nowadays..)
update:
I got my master's degree, yay :D


Last edited by lagrenouille on Tue Mar 04, 2014 8:37 pm; edited 2 times in total
Back to top
View user's profile Send private message
JoseJX
Retired Dev
Retired Dev


Joined: 28 Apr 2002
Posts: 2774

PostPosted: Sat Mar 01, 2008 4:54 pm    Post subject: Reply with quote

In the example you showed, it was using OSS emulation. Does it happen when you use ALSA directly too?
_________________
Gentoo PPC FAQ: http://www.gentoo.org/doc/en/gentoo-ppc-faq.xml
Back to top
View user's profile Send private message
lagrenouille
n00b
n00b


Joined: 08 Jan 2006
Posts: 18
Location: Liège (BELGIUM)

PostPosted: Sat Mar 01, 2008 8:02 pm    Post subject: With -ao alsa Reply with quote

When i try mplayer with '-ao alsa' option, it does the same apart that it doesnt say the device is busy for the second call,
it says nothing and it is stuck trying to play the song.



Well, don't bother helping me with this problem, i installed a debian.

It was nice using gentoo but i think i got things messed up by lots of use and especially misuse of it^^
I used it since 2.6.14 and tried many masked package (even tried some without the unstable keyword.. and didnt rebuild dep etc. i am the only one responsible for my problem i pretty sure now^^)
Btw the sound is working fine on my debian, it use oss-emul by default for my card (and alsa drivers works as well)
The sound card is a Tumbler (powermac) and here the lsmod i did under debian!!


nls_utf8 2272 1
nls_cp437 6080 1
vfat 14112 1
fat 59996 1 vfat
isofs 39640 1
udf 91364 0
radeon 129448 2
drm 80600 3 radeon
rfcomm 44252 0
l2cap 25092 5 rfcomm
bluetooth 59436 4 rfcomm,l2cap
lp 13612 0
parport 43312 1 lp
ipv6 288364 15
snd_powermac 48188 1
dm_snapshot 19836 0
dm_mirror 23508 0
dm_mod 65136 2 dm_snapshot,dm_mirror
sbp2 24840 0
loop 20040 0
apm_emu 7884 2
snd_aoa_i2sbus 24228 0
snd_pcm_oss 52032 0
snd_mixer_oss 20704 1 snd_pcm_oss
snd_pcm 91396 3 snd_powermac,snd_aoa_i2sbus,snd_pcm_oss
snd_timer 26500 1 snd_pcm
snd_page_alloc 12008 1 snd_pcm
snd 65908 8 snd_powermac,snd_aoa_i2sbus,snd_pcm_oss,snd_mixe r_oss,snd_pcm,snd_timer
soundcore 11204 1 snd
pcmcia 43472 0
firmware_class 11744 1 pcmcia
snd_aoa_soundbus 8004 1 snd_aoa_i2sbus
sd_mod 24432 2
airport 7104 0
orinoco 44340 1 airport
hermes 8224 2 airport,orinoco
yenta_socket 29644 1
rsrc_nonstatic 12864 1 yenta_socket
pcmcia_core 47128 3 pcmcia,yenta_socket,rsrc_nonstatic
uninorth_agp 10888 1
agpgart 37212 2 drm,uninorth_agp
evdev 12352 3
tsdev 9120 0
eth1394 21508 0
ext3 155080 1
jbd 69544 1 ext3
mbcache 9668 1 ext3
usb_storage 89164 1
scsi_mod 169168 3 sbp2,sd_mod,usb_storage
usbhid 58756 0
ide_cd 47460 1
cdrom 43516 1 ide_cd
ide_disk 18976 3
ohci1394 40528 0
ieee1394 426800 3 sbp2,eth1394,ohci1394
ohci_hcd 23108 0
sungem 34916 0
sungem_phy 10528 1 sungem
usbcore 146752 4 usb_storage,usbhid,ohci_hcd
i2c_powermac 6048 0


_________________
;;Student-"Institut d'Informatique"(http://www.info.fundp.ac.be/).
;;Working on a Tibook II G4 667MHz without any hardware failure yet (try to find such quality products nowadays..)
update:
I got my master's degree, yay :D
Back to top
View user's profile Send private message
lagrenouille
n00b
n00b


Joined: 08 Jan 2006
Posts: 18
Location: Liège (BELGIUM)

PostPosted: Wed Mar 12, 2008 10:30 am    Post subject: Reply with quote

Oh i forgot,
i think this problem is linked without doubt to in-kernel module : snd-powermac
(i fixed my problems with a stable debian with 2.6.18 kernel after i had so much trouble with 2.6.22 or 2.6.23)

There is a patch existing for that (for the kernel)
http://launchpadlibrarian.net/11311439/pmac.c.diff

Where i have heard about the patch (the distribution doesnt matter much i think)
http://lists.openwall.net/linux-kernel/2007/09/02/91
https://bugs.launchpad.net/ubuntu/+source/linux-source-2.6.20/+bug/87652
_________________
;;Student-"Institut d'Informatique"(http://www.info.fundp.ac.be/).
;;Working on a Tibook II G4 667MHz without any hardware failure yet (try to find such quality products nowadays..)
update:
I got my master's degree, yay :D
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum