Opened 17 years ago
Closed 15 years ago
Last modified 15 years ago
#5342 closed patch (fixed)
AudioOutputAlsa is only able to open the mixer of card 0
| Reported by: | stuartm | Owned by: | JYA |
|---|---|---|---|
| Priority: | minor | Milestone: | unknown |
| Component: | MythTV - Audio Output | Version: | head |
| Severity: | low | Keywords: | |
| Cc: | Ticket locked: | no |
Description
While trying to get MythTV to use the mixer of card 1 in a new frontend I found the following note in AudioOutputAlsa: TODO: This is opening card 0. Fix for case of multiple soundcards
I'd like to get this fixed ASAP, but if someone with a better knowledge of the ALSA api wants to help I'd appreciate it.
Attachments (2)
Change History (11)
comment:1 by , 17 years ago
comment:2 by , 17 years ago
The TODO comment is indeed out of date, it applied to an older version of the ALSA api where the second argument of snd_mixer_open did specify the device number.
However the problem still stands, or certainly did on the two occasions I've tried it - you can't change volume etc if using anything except the first device on the system.
by , 17 years ago
| Attachment: | alsa_mixer_fix_5342_v1-trunk18117.patch added |
|---|
comment:4 by , 17 years ago
Having demonstrated (yet again) what a stupid old man I can be, I'll complete the exercise. With an sblive as card 0, an hda intel as card 1, and myth set to the hda it works fine. Swapping the arrangement over, hda as 0, sblive as 1, and myth on the sblive, it also works fine. When I initially plugged the second card in, it didn't work. I can only put that down to operator error(s) during the process of adjusting asound.conf to the altered arrangements (which always takes several attempts).
comment:5 by , 17 years ago
| Milestone: | 0.21.1 → unknown |
|---|---|
| Priority: | critical → minor |
| Severity: | high → low |
| Type: | defect → patch |
comment:6 by , 16 years ago
| Component: | mythtv → MythTV - Audio Output |
|---|
comment:7 by , 16 years ago
| Owner: | changed from to |
|---|---|
| Status: | new → assigned |
comment:8 by , 15 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
comment:9 by , 15 years ago
Are you sure this hasn't broken things? Sound was working before, but with this commit I get the following errors in the log (and no sound). If I back out this one commit, sounds works again.
2010-05-28 19:49:33.973 ALSA, Error: snd_pcm_info_get_card: Operation not permitted 2010-05-28 19:49:33.973 Opening ALSA audio device 'default'. 2010-05-28 19:49:33.978 AudioOutput Warning: mmap not available, attempting to fall back to slow writes 2010-05-28 19:49:34.225 ALSA, Error: no playback control PCM found on mixer device default 2010-05-28 19:49:34.227 AudioOutput Error: Aborting reconfigure 2010-05-28 19:49:34.227 NVP(0): Disabling Audio, reason is: Aborting reconfigure

I believe the only error here lies with the TODO comment. In the alsa source, the \brief comment against snd_mixer_open() reads "Opens an empty mixer". The open function doesn't associate with any card whatsoever, it just yields a mixer handle which is subsequently bound to the nominated device via snd_mixer_attach().