[alsa-devel] uda1380 and pxa255 plays nothing but noise
Hello, I'm trying to enable sound on my iPAQ h2200 device using ALSA ASoC. I've created driver basing on hx4700.c and magician.c files, but I can't hear is anything. When I am playing music on device file uda1380-codec.0-0018/dapm/Playback shows that stream Playback is active, but in DAC that stream is inactive (but DAC is on). I also noticed that on I2S bus is nothing going on. I've lost many hours on looking for problem. Is there anyone who could help me?
Łukasz Dałek
On Tue, Aug 07, 2012 at 09:18:41PM +0200, nerwusek wrote:
I'm trying to enable sound on my iPAQ h2200 device using ALSA ASoC. I've created driver basing on hx4700.c and magician.c files, but I can't hear is anything. When I am playing music on device file uda1380-codec.0-0018/dapm/Playback shows that stream Playback is active, but in DAC that stream is inactive (but DAC is on). I also noticed that on I2S bus is nothing going on. I've lost many hours on looking for problem. Is there anyone who could help me?
Have you checked that the output isn't muted, has the audio routed to the output you're using and has a suitable volume?
On 07.08.2012 21:26, Mark Brown wrote:
On Tue, Aug 07, 2012 at 09:18:41PM +0200, nerwusek wrote:
I'm trying to enable sound on my iPAQ h2200 device using ALSA ASoC. I've created driver basing on hx4700.c and magician.c files, but I can't hear is anything. When I am playing music on device file uda1380-codec.0-0018/dapm/Playback shows that stream Playback is active, but in DAC that stream is inactive (but DAC is on). I also noticed that on I2S bus is nothing going on. I've lost many hours on looking for problem. Is there anyone who could help me?
Have you checked that the output isn't muted, has the audio routed to the output you're using and has a suitable volume?
On 07.08.2012 21:26, Mark Brown wrote:
Have you checked that the output isn't muted, has the audio routed to the output you're using and has a suitable volume?
Yes I have checked all that things. I have 2 routes from VOUTHP{LR} and from VOUT{LR} and I think it's ok because of info in logs "asoc: uda1380-hifi <-> pxa2xx-i2s mapping ok". I have also observed that if I change Output Mux from DAC to Analog Mixer and change Anolog Mixer volume up the noise and louder. In my opinion problem is somewhere else. I think that I forgot to enable sth in ALSA. As I said when I enabled I2C debugging data flows only when playback is starting or when I change values in alsamixer, when music is played no data are send to codec.
Łukasz Dałek
Maybe some amplifier is not enabled? On iPAQ h1940 and rx1950 you need to toggle gpio pin to hear something from internal speaker (not sure if that pin disables headphones).
Anyway, you can just mimic WinMobile behavior, use haret to see if there's some GPIO activity. If you need to learn some haret magic - just ask me :)
Regards Vasily
On Tue, Aug 7, 2012 at 10:41 PM, nerwusek luk0104@gmail.com wrote:
On 07.08.2012 21:26, Mark Brown wrote:
Have you checked that the output isn't muted, has the audio routed to the output you're using and has a suitable volume?
Yes I have checked all that things. I have 2 routes from VOUTHP{LR} and from VOUT{LR} and I think it's ok because of info in logs "asoc: uda1380-hifi <-> pxa2xx-i2s mapping ok". I have also observed that if I change Output Mux from DAC to Analog Mixer and change Anolog Mixer volume up the noise and louder. In my opinion problem is somewhere else. I think that I forgot to enable sth in ALSA. As I said when I enabled I2C debugging data flows only when playback is starting or when I change values in alsamixer, when music is played no data are send to codec.
Łukasz Dałek
Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
On 07.08.2012 23:18, Vasily Khoruzhick wrote:
Maybe some amplifier is not enabled? On iPAQ h1940 and rx1950 you need to toggle gpio pin to hear something from internal speaker (not sure if that pin disables headphones).
When I change volume of Analog Mixer the noise in headphones is getting stronger or weaker so GPIOs in my opinion are set up correctly.
I'll enable debug messages on i2s bus and see if there is sth sent to codec. Maybe alsa is sending music packets to /dev/null.
I will also want to see what debugfs files should contain when audio works. Could you send me few examples or point me to address with them?
Łukasz Dałek
On Wed, Aug 8, 2012 at 12:48 AM, nerwusek luk0104@gmail.com wrote:
On 07.08.2012 23:18, Vasily Khoruzhick wrote:
Maybe some amplifier is not enabled? On iPAQ h1940 and rx1950 you need to toggle gpio pin to hear something from internal speaker (not sure if that pin disables headphones).
When I change volume of Analog Mixer the noise in headphones is getting stronger or weaker so GPIOs in my opinion are set up correctly.
I'll enable debug messages on i2s bus and see if there is sth sent to codec. Maybe alsa is sending music packets to /dev/null.
I will also want to see what debugfs files should contain when audio works. Could you send me few examples or point me to address with them?
Well, I've no compiled kernel nor rootfs for my PDAs :( and I'll be pretty busy this weekend, so it'll take some time to get debugfs contents for you.
Regards Vasily
On Tue, Aug 07, 2012 at 11:48:24PM +0200, nerwusek wrote:
When I change volume of Analog Mixer the noise in headphones is getting stronger or weaker so GPIOs in my opinion are set up correctly.
This sounds like either the CPU isn't actually sending data or there's a digital mute.
On 08.08.2012 11:57, Mark Brown wrote:
This sounds like either the CPU isn't actually sending data or there's a digital mute.
Debugfs file asoc/ipaq/uda.../dapm/Playback shows: Playback: On in 1 out 1 stream Playback active out "static" "DAC" out "static" "DAC" out "static" "DAC"
and file DAC shows: DAC: On in 3 out 4 - R2(0x2) bit 10 stream Playback inactive in "static" "Playback" in "static" "Playback" in "static" "Playback" out "DAC" "Output Mux" out "static" "Analog Mixer"
is it correct? Shouldn't stream Playback in DAC show active status? Also I noticed that alsamixer works slower when playing music so some data must be sent to codec but I don't know is that music data or sth else.
Łukasz Dałek
On 08.08.2012 13:16, nerwusek wrote:
On 08.08.2012 11:57, Mark Brown wrote:
This sounds like either the CPU isn't actually sending data or there's a digital mute.
Debugfs file asoc/ipaq/uda.../dapm/Playback shows: Playback: On in 1 out 1 stream Playback active out "static" "DAC" out "static" "DAC" out "static" "DAC"
and file DAC shows: DAC: On in 3 out 4 - R2(0x2) bit 10 stream Playback inactive in "static" "Playback" in "static" "Playback" in "static" "Playback" out "DAC" "Output Mux" out "static" "Analog Mixer"
is it correct? Shouldn't stream Playback in DAC show active status? Also I noticed that alsamixer works slower when playing music so some data must be sent to codec but I don't know is that music data or sth else.
Łukasz Dałek
I also booted handhelds kernel (2.6.21) and compared UDA registers with it. Everything was the same except in my kernel (3.4) was silence. At this point I have no idea where is the problem.
Łukasz Dałek
On Tue, Aug 7, 2012 at 10:41 PM, nerwusek luk0104@gmail.com wrote:
On 07.08.2012 21:26, Mark Brown wrote:
Have you checked that the output isn't muted, has the audio routed to the output you're using and has a suitable volume?
Yes I have checked all that things. I have 2 routes from VOUTHP{LR} and from VOUT{LR} and I think it's ok because of info in logs "asoc: uda1380-hifi <-> pxa2xx-i2s mapping ok". I have also observed that if I change Output Mux from DAC to Analog Mixer and change Anolog Mixer volume up the noise and louder. In my opinion problem is somewhere else. I think that I forgot to enable sth in ALSA. As I said when I enabled I2C debugging data flows only when playback is starting or when I change values in alsamixer, when music is played no data are send to codec.
Audio data should be sent over I2S, so there's no I2C traffic during audio playback.
Regards Vasily
Łukasz Dałek
participants (3)
-
Mark Brown
-
nerwusek
-
Vasily Khoruzhick