Sound

I have a pi B+ and I am trying to get sound from it without success. I am using hdmi cable to an LG tv, volume is set to 80, mute is not on. I have checked the setup and the entry in /boot/config and it is set correctly. I am using sonic pi to carry out tests.

What can I be doing wrong?

Malcolm Smith

--
T M Smith 
Using an Iyonix and RISC OS 5.20 in the North Riding of Yorkshire
Reply to
T M Smith
Loading thread data ...

Now having to answer my own mail!!!! I did not think there would be so many place to set the output to hdmi but it is now working.

cheers Malcolm

--
T M Smith 
Using an Iyonix and RISC OS 5.20 in the North Riding of Yorkshire
Reply to
T M Smith

Same results here to a Sony TV.

Now looking to see if there is a GUI to control sound settings.

Googling so far suggests that the sound output should default to HDMI when available. I am using a TV so there should be no issues about HDMI/DVI confusion. Have you checked to see if sound is coming out of the headphone socket? [I haven't yet.]

Dave R

--
Windows 8.1 on PCSpecialist box
Reply to
David

Looking at various websites suggests there are two audio options in config.txt

hdmi_drive=2 force sound over hdmi

I would try this first

hdmi_force_edid_audio=1 pretends all audio formats are supported by the display, allowing passthrough of DTS/ACe even when not reported as supported.

Might be worth a try next.

--
Alan Adams, from Northamptonshire 
alan@adamshome.org.uk 
http://www.nckc.org.uk/
Reply to
Alan Adams

No I did not bother with the headphone socket

Malcolm

--
T M Smith 
Using an Iyonix and RISC OS 5.20 in the North Riding of Yorkshire
Reply to
T M Smith

Care to detail where you changed the settings? This would be very helpful.

Cheers

Dave R

--
Windows 8.1 on PCSpecialist box
Reply to
David

I went to raspberrypi.org/documentation/configuration/audio-config.md.

Tried 'amixer cset numid=3 2' which did not do the job. I was using Sonic Pi to check progress and found a menu entry to change the output to HDMI so changed that setting. Then changed raspi-config setting. Still no joy.

Then found the /boot/config.txt file where hdmi_drives was still hashed out. Changed that 'using sudo' so it was active and rebooted and I had lift-off.

Sonic Pi then became an interesting Programme.

Hope this helps

Malcolm

>
--
T M Smith 
Using an Iyonix and RISC OS 5.20 in the North Riding of Yorkshire
Reply to
T M Smith

Thanks.

I spent some time thrashing around to try and find the equivalent of the sound control on Windows but didn't get far.

I tried alsamixer and could see that Alsa seemed to be working and I could change the volume. No 'mute' function, though.

Plugged in a set of headphones - still nothing.

Used raspi-config to force output to headphones - there was a lot of background hiss but I could play a sound.

Forced HDMI and nothing.

Checked /boot/config.text and uncommented hdmi_drive=2, rebooted and I have sound.

The documentation link you posted (thanks) says "In some rare cases, it is necessary to edit config.txt to force HDMI mode (as opposed to DVI mode, which does not send sound). "

Looks like we were two of these "rare cases".

I didn't see any settings for DVI mode in raspi-config - just 0 for auto,

1 for headph "Here is a list of all CEA and DMT formats (as of CEA-861 E and DMT V1 r12 respectively).

If you want to use any of these modes explicitly, set hdmi_group and hdmi_mode to the correct values in the config file. Note that NOT all modes are supported by the Raspberry Pi hardware (mainly the high resolution/high frame rate modes) and all explicit modes are subject to EDID* support of the monitor/TV.

*EDID: When starting the raspberry-Pi asks the TV for information about itself. This information is returned by the TV in a data structure called an 'EDID' block."

Further down:

"If the file config.txt is not present or the output format is not set explicitly, the default output format is chosen as follows:

  1. If the preferred format in EDID is supported, this will be chosen.

  1. If the preferred format is not supported, then all the formats supported will be ranked according to some heuristics. The format with the highest score will be chosen.

If the chosen format is a DMT format, the default driven mode will be DVI. The user will need to explicitly set driving mode to 2 if HDMI output is desired. In DVI mode there will be no sound!"

So this suggests that the TV may be returning an EDID block which selects DMT format (or not returning a compatible CEA preferred format), so forcing DVI mode.

Ah!

"If you are unsure what formats are supported, set the output format to VGA 60Hz and then follow the instructions below to parse the EDID to find out what formats are supported. All executables are found under /opt/vc/ bin.

  1. Run ?tvservice ?m CEA? to give a list of CEA supported modes.
  2. Run ?tvservice ?m DMT? to give a list of DMT supported modes.
  3. Run ?tvservice -s? to give you the current state. "

Did that, and the Sony TV returns a {preferred} for DMT mode 39: 1360 *

768 @ 60Hz 16:9, clock clock:85MHz progressive.

This is what it is currently set to, and seems to be working fine.

So working backwards from the solution:

If you have connected via HDMI and you are getting no sound, run 'tvservice

-s'.

If that returns a DMT mode then you are in DVI mode for (no) sound, so edit /boot/config.txt to uncomment hdmi_drive=2.

Be nice if we had found the short version!

Cheers

Dave R

--
Windows 8.1 on PCSpecialist box
Reply to
David

[snip]

Well we got there in the end. The forum thread makes it seem complicated so I am pleased to be a rare case.

Malcolm

--
T M Smith 
Using an Iyonix and RISC OS 5.20 in the North Riding of Yorkshire
Reply to
T M Smith

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.