Is there anyway to turn it on and off using part of your code? I'm trying to figure out if this is a hardware or software problem...
# Left speaker On, Right speaker Off amixer -D hw:0 set PCM 100%,0 # Left speaker Off, Right speaker On amixer -D hw:0 set PCM 0%,100%