Page 1 of 1

No sound over HDMI

Posted: Tue Jul 17, 2012 8:25 am
by PaulCheffus
Hi

I have been trying to get my sound to work over HDMI on and off for the last couple of weeks. Nothing seems to make any difference when I use aplay. It appears to play the file but there is no sound. TV is a Panasonic Viera TXL37E30B.

I have tried two HDMI cables and various config.txt settings with no changes. hello_audio.bin 1 works fine.

This morning I decided the only thing left to try was to change the TV to the one from my sons room which is a Currys own brand 15" and without making any other changes I now have sound over HDMI (first part of the Front_Center.wav file is cut off). So what could be wrong with the PanasonicTV?

Below are the results of tvservice on the Panasonic
tvservice -s

Code: Select all

state: HPD high|HDMI mode|HDCP off|composite off (0x12001a), 1920x1080 @ 50Hz, progressive
tvservice -m CEA

Code: Select all

Group CEA has 16 modes:           
mode 1: 640x480 @ 60Hz, progressive           
mode 2: 720x480 @ 60Hz, progressive           
mode 3: 720x480 @ 60Hz, progressive           
mode 4: 1280x720 @ 60Hz, progressive           
mode 5: 1920x1080 @ 60Hz, interlaced           
mode 6: 720x480 @ 60Hz, interlaced           
mode 7: 720x480 @ 60Hz, interlaced  (native) 
mode 16: 1920x1080 @ 60Hz, progressive           
mode 17: 720x576 @ 50Hz, progressive           
mode 18: 720x576 @ 50Hz, progressive           
mode 19: 1280x720 @ 50Hz, progressive           
mode 20: 1920x1080 @ 50Hz, interlaced           
mode 21: 720x576 @ 50Hz, interlaced           
mode 22: 720x576 @ 50Hz, interlaced  (native) 
mode 31: 1920x1080 @ 50Hz, progressive           
mode 32: 1920x1080 @ 24Hz, progressive
tvservice -m DMT

Code: Select all

Group DMT has 0 modes:
My output from edidparser

Code: Select all

Parsing edid.dat...
HDMI:EDID version 1.3, 1 extensions, unknown aspect ratio
HDMI:EDID features - videodef 0x80 !standby !suspend !active off; colour encoding:RGB444|YCbCr422; sRGB is not default colourspace; preferred format is native; does not support GTF
HDMI:EDID found monitor name descriptor tag 0xfc
HDMI:EDID monitor name is Panasonic-TV
HDMI:EDID found monitor range descriptor tag 0xfd
HDMI:EDID monitor range offsets: V min=0, V max=0, H min=0, H max=0
HDMI:EDID monitor range: vertical is 23-61 Hz, horizontal is 15-68 kHz, max pixel clock is 150 MHz
HDMI:EDID monitor range does not support GTF
HDMI:EDID found preferred CEA detail timing format: 1920x1080p @ 50 Hz (31)
HDMI:EDID found CEA detail timing format: 1920x1080p @ 60 Hz (16)
HDMI:EDID established timing I/II bytes are 00 00 00
HDMI:EDID standard timings block x 8: 0x0101 0101 0101 0101 0101 0101 0101 0101 
HDMI:EDID parsing v3 CEA extension 0
HDMI:EDID monitor support - underscan IT formats:no, basic audio:yes, yuv444:yes, yuv422:yes, #native DTD:2
HDMI:EDID found CEA detail timing format: 1920x1080i @ 50 Hz (20)
HDMI:EDID found CEA detail timing format: 1920x1080i @ 60 Hz (5)
HDMI:EDID found CEA detail timing format: 1280x720p @ 50 Hz (19)
HDMI:EDID found CEA detail timing format: 1280x720p @ 60 Hz (4)
HDMI:EDID found CEA detail timing format: 720x576p @ 50 Hz (17)
HDMI:EDID found CEA format: code 31, 1920x1080p @ 50Hz (native)
HDMI:EDID found CEA format: code 16, 1920x1080p @ 60Hz (native)
HDMI:EDID found CEA format: code 20, 1920x1080i @ 50Hz 
HDMI:EDID found CEA format: code 5, 1920x1080i @ 60Hz 
HDMI:EDID found CEA format: code 32, 1920x1080p @ 24Hz 
HDMI:EDID found CEA format: code 19, 1280x720p @ 50Hz 
HDMI:EDID found CEA format: code 4, 1280x720p @ 60Hz 
HDMI:EDID found CEA format: code 18, 720x576p @ 50Hz 
HDMI:EDID found CEA format: code 3, 720x480p @ 60Hz 
HDMI:EDID found CEA format: code 17, 720x576p @ 50Hz 
HDMI:EDID found CEA format: code 2, 720x480p @ 60Hz 
HDMI:EDID found CEA format: code 22, 1440x576i @ 50Hz 
HDMI:EDID found CEA format: code 7, 1440x480i @ 60Hz 
HDMI:EDID found CEA format: code 21, 1440x576i @ 50Hz 
HDMI:EDID found CEA format: code 6, 1440x480i @ 60Hz 
HDMI:EDID found CEA format: code 1, 640x480p @ 60Hz 
HDMI:EDID found audio format 2 channels PCM, sample rate: 32|44|48 kHz, sample size: 16 bits
HDMI:EDID found HDMI VSDB length 8
HDMI:EDID HDMI VSDB has physical address 3.0.0.0
HDMI:EDID HDMI VSDB supports AI:yes, dual link DVI:no
HDMI:EDID HDMI VSDB deep colour support - 48-bit:no 36-bit:yes 30-bit:yes DC_yuv444:yes
HDMI:EDID HDMI VSDB max TMDS clock 190 MHz
HDMI:EDID HDMI VSDB content type support: game|cinema|photo|text
HDMI:EDID adding mandatory support for DMT (4) 640x480p @ 60Hz
HDMI:EDID filtering formats with pixel clock > 162 MHz or h. blanking > 1023
HDMI:EDID best score mode is now CEA (1) 640x480p @ 60 Hz with pixel clock 25 MHz (score 136864)
HDMI:EDID best score mode is now CEA (2) 720x480p @ 60 Hz with pixel clock 27 MHz (score 141472)
HDMI:EDID CEA mode (3) 720x480p @ 60 Hz with pixel clock 27 MHz has a score of 141472
HDMI:EDID best score mode is now CEA (4) 1280x720p @ 60 Hz with pixel clock 74 MHz (score 2710592)
HDMI:EDID DMT mode (4) 640x480p @ 60 Hz with pixel clock 25 MHz has a score of 18432
HDMI:EDID best score mode is now CEA (5) 1920x1080i @ 60 Hz with pixel clock 74 MHz (score 3848832)
HDMI:EDID CEA mode (6) 1440x480i @ 60 Hz with pixel clock 27 MHz has a score of 120736
HDMI:EDID CEA mode (7) 1440x480i @ 60 Hz with pixel clock 27 MHz has a score of 120736
HDMI:EDID best score mode is now CEA (16) 1920x1080p @ 60 Hz with pixel clock 148 MHz (score 4973248)
HDMI:EDID CEA mode (17) 720x576p @ 50 Hz with pixel clock 27 MHz has a score of 2141472
HDMI:EDID CEA mode (18) 720x576p @ 50 Hz with pixel clock 27 MHz has a score of 141472
HDMI:EDID CEA mode (19) 1280x720p @ 50 Hz with pixel clock 74 MHz has a score of 3192160
HDMI:EDID CEA mode (20) 1920x1080i @ 50 Hz with pixel clock 74 MHz has a score of 4307360
HDMI:EDID CEA mode (21) 1440x576i @ 50 Hz with pixel clock 27 MHz has a score of 120736
HDMI:EDID CEA mode (22) 1440x576i @ 50 Hz with pixel clock 27 MHz has a score of 120736
HDMI:EDID best score mode is now CEA (31) 1920x1080p @ 50 Hz with pixel clock 148 MHz (score 5411040)
HDMI:EDID CEA mode (32) 1920x1080p @ 24 Hz with pixel clock 74 MHz has a score of 199532
HDMI:EDID preferred mode remained as CEA (31) 1920x1080p @ 50 Hz with pixel clock 148 MHz
HDMI:EDID has HDMI support and audio support
edid_parser exited with code 0
Relevant config.txt settings

Code: Select all

hdmi_force_hotplug=1
hdmi_drive=2
overscan_top=-20
overscan_bottom=-25
framebuffer_width=1920
framebuffer_height=1080
I've also tried just

Code: Select all

hdmi_force_hotplug=1
hdmi_drive=2
hdmi_group=1
hdmi_mode=31
I have also attached my edid.dat file from tvservice -d

Any help would be appeciated.

Cheers

Paul

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 9:00 am
by dom
Can you just confirm, with default settings, your TV plays audio with hello_audio ?
Can you try hdmi_force_edid_audio=1
http://elinux.org/RPi_config.txt#Video_mode_options

You may need to update your firmware first
http://elinux.org/R-Pi_Troubleshooting# ... g_firmware

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 9:17 am
by PaulCheffus
dom wrote:Can you just confirm, with default settings, your TV plays audio with hello_audio ?
Can you try hdmi_force_edid_audio=1
http://elinux.org/RPi_config.txt#Video_mode_options

You may need to update your firmware first
http://elinux.org/R-Pi_Troubleshooting# ... g_firmware
Hi Dom

Thanks for the reply.

Yes with the settings given hello_audio works. hello_audio.bin - output via 3.5mm Jack, hello_audio.bin 1 - output via TV

I did try hdmi_force_edid_audio=1 but that didn't make any difference, my firmware was last updated on 11 July according to the .firmware_revision file on the SD card.

Cheers

Paul

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 9:24 am
by dom
When it's not playing audio, is audio coming out of analogue (headphones) connector?

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 9:29 am
by PaulCheffus
dom wrote:When it's not playing audio, is audio coming out of analogue (headphones) connector?
Hi

Will need to check that later (at work at moment). I assume this is when it should be coming out of the TV.

Cheers

Paul

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 12:35 pm
by pholy
I have a Samsung UN40C5000 - about 2 years old - with very similar symptoms. Hello_audio works properly with both 0 and 1, but aplay only works when the route switch is set for analogue output; there is silence when set to auto or hdmi - although sometimes I hear a small burp from the tv - not always.

I have hdmi_drive = 2 and hdmi_force_edid_audio=1 in my config.txt, but I believe these are not needed, after viewing the edid parse. They did not affect the results.

I've zipped up the raw edid file and attached it.

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 12:37 pm
by pholy
Forgot to say I am using the wheezy-HF image that was announced in the Raspbian forum, without any new updates so far.

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 1:13 pm
by PaulCheffus
dom wrote:When it's not playing audio, is audio coming out of analogue (headphones) connector?
Hi

Ok I did the following

Code: Select all

amixer cset numid=3 0
aplay /usr/share/sounds/alsa/Front_Center.wav
No audio from either TV or headphones

Code: Select all

amixer cset numid=3 1
aplay /usr/share/sounds/alsa/Front_Center.wav
Audio from headphones, nothing from TV as you would expect

Code: Select all

amixer cset numid=3 2
aplay /usr/share/sounds/alsa/Front_Center.wav
No audio from either TV or headphones

Cheers

Paul

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 5:37 pm
by JanAlleman
Might be a tv issue.
I have a Samsung UE37C6000, with 4 hdmi slots, of which one can also be used as dvi port.
When I connect the pi to the latter, the picture is perfect, but there is no sound. If i connect the pi to one of the other ports, I have sound over hdmi, but the picture is of lesser quality, obviously not what you expect from a dvi port.
The tv manual does not mention it explicitly, but in their example of connecting a pc to the dvi port, they connect the sound by a separate s/p-dif cable, so I imagine that sound over hdmi is not supported on the dvi port.

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 5:47 pm
by dom
PaulCheffus wrote:

Code: Select all

amixer cset numid=3 0
aplay /usr/share/sounds/alsa/Front_Center.wav
No audio from either TV or headphones
Any different with a longer file?

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 7:03 pm
by 007-half
I had a similar problem with a Panasonic TXL19C20B and found an inelegant fix from the troubleshooting wiki:-

"sudo apt-get install alsa-utils
sudo modprobe snd_bcm2835"

This enabled the Debian Squeeze sound and "Cellule" plays ok.

The temporary solution is to re- sudo modprobe snd_bcm2835 at each RPi power-up.

I've messed about with a configure file and the test wavs and had the same result as reported earlier here, so still no permanent solution.

Hope that helps.

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 8:00 pm
by pholy
JanAlleman wrote:Might be a tv issue.
I have a Samsung UE37C6000, with 4 hdmi slots, of which one can also be used as dvi port.
When I connect the pi to the latter, the picture is perfect, but there is no sound. If i connect the pi to one of the other ports, I have sound over hdmi, but the picture is of lesser quality, obviously not what you expect from a dvi port.
The tv manual does not mention it explicitly, but in their example of connecting a pc to the dvi port, they connect the sound by a separate s/p-dif cable, so I imagine that sound over hdmi is not supported on the dvi port.
Good point; I also noticed that in my manual and connected to the 2nd port.
It also says "If there is no sound after connecting an HDMI cable, check the HDMI version of the external device. If you suspect the version is older than 1.3 contact the provider of the device to confirm the HDMI version and request an upgrade." So just as a formality, is the HDMI version 1.3 or better? I'm assuming it is, of course.

Re: No sound over HDMI

Posted: Tue Jul 17, 2012 8:05 pm
by PaulCheffus
dom wrote:
PaulCheffus wrote:

Code: Select all

amixer cset numid=3 0
aplay /usr/share/sounds/alsa/Front_Center.wav
No audio from either TV or headphones
Any different with a longer file?
Hi

Thanks, indeed it is. I put a 1.2Mb wav file on and after a silent pause at the beginning I then get sound playing though the HDMI on the TV. There is also a delay at the end of the playback before the command prompt comes back.

I did notice on the other TV that the beginning of the Front_Center file was garbled or missing but I expected the same result on this TV.

I assume this is to do with how quickly the TV realises that there is an audio input.

Cheers

Paul

Re: No sound over HDMI

Posted: Wed Jul 18, 2012 9:08 pm
by pholy
Yes, longer files play after missing out about one and a half seconds at the start. You can confirm this by using sox to make a series of wav files, then concatenate them:

Code: Select all

for n = C4 D4 E4 F4 G4 A4 B4 C5; sox -b16 -n $n.wav synth 0.5 sine $n; done
sox C4.wav D4.wav E4.wav F4.wav G4.wav A4.wav B4.wav C5.wav scale.wav
then listen to it and count the tones you hear:

Code: Select all

aplay scale.wav
I can hear a little bit of the third tone, then five more, clearly. Through the line-out jack, I hear all eight.

Is this the TV not starting its sound output (as the OP suggests), or the Pi's video core not generating it? Not having a way of connecting probes to the hdmi output, I can't think of a way to tell the difference. (I only have one hdmi TV :D ) But I guess I can live with it until there's a solution for short files.