I am trying to force audio output to the 3.5mm output jack, but I have been unsuccessful. I am using Raspbian.
Many sources suggest using this line to force the Pi to use 3.5mm jack for audio output:
$ amixer cset numid=3 1
I don't think this works. Given these two commands:
$ amixer -h
cset cID P set control contents for one control
$ amixer controls
numid=4,iface=MIXER,name=’Master Playback Switch’
numid=3,iface=MIXER,name=’Master Playback Volume’
numid=2,iface=MIXER,name=’Capture Switch’
numid=1,iface=MIXER,name=’Capture Volume’
I think the line I initially referenced sets the Master Playback Volume to nearly zero. The line does not seem to control whether the Pi outputs audio to the 3.5mm jack or the HDMI port.
The only way I was able to get any audio out of the 3.5mm jack was by running the test code below.
$ cd /opt/vc/src/hello_pi/
$ ./rebuild.sh
$ cd hello_audio
$ ./hello_audio.bin
But this does not allow me to play the WAV files I have put on my Pi.