Through the HDMI Cable? If so I had the same problem. I will check and find the fix I used.
Edit: found it
Wow - thanks so much!!
HDMI audio is finally working
1)
http://elinux.org/R-Pi_Troubleshooting#Sound really did the trick
- in \boot\config.txt , uncomment hdmi_drive=2
2) Next I did :
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install alsa-utils
sudo modprobe snd_bcm2835
Nothing changed, but then
3) I ran this command -
amixer cset numid=3 2
(yes I put the space after the 3 and then the 2)
And sound now works beautifully
The other thing that really helped was getting the sound to come out louder. I fixed that by doing this:
Enter the command 'alsamixer' and use the control to check that the volume is up (arrow keys) and that the output is not muted (M key).
Now my sound is perfect. Thanks very much!!