I am in the middle of adding an alert to my current project, that is, a simple loud three tone beep when a trigger occurs.
I have a small 8ohm speaker set up connected to stereo headhone jack pins so that if there are no headphones connected, the sound signal will goto the speakers, if there are headphones connected, the headphones will work and not the speaker. I managed this by using a stereo jack that has swtches built in that disconnect when a stereo plug is plugged in...
The problem I have is..
Using the code 'sound 5 (100, 20, 150, 20, 110, 30)
I get a relatively small volume through the 8 ohm speaker, and when I connect the headphones, they are extremely loud! I added a 4k7 resistor between the picaxe sound signal and the headphone jack (and speaker) and this brought the volume of the headphones down to a comfortable volume however nothing can be heard by the speaker when headphones aren't connected.
Is there any way I can level out the volume without using two pins for the two different sound outputs?
Lower/ higher impedance speakers? a 5k log pot perhaps? so user adjusts headphone / speaker volume?
I have a small 8ohm speaker set up connected to stereo headhone jack pins so that if there are no headphones connected, the sound signal will goto the speakers, if there are headphones connected, the headphones will work and not the speaker. I managed this by using a stereo jack that has swtches built in that disconnect when a stereo plug is plugged in...
The problem I have is..
Using the code 'sound 5 (100, 20, 150, 20, 110, 30)
I get a relatively small volume through the 8 ohm speaker, and when I connect the headphones, they are extremely loud! I added a 4k7 resistor between the picaxe sound signal and the headphone jack (and speaker) and this brought the volume of the headphones down to a comfortable volume however nothing can be heard by the speaker when headphones aren't connected.
Is there any way I can level out the volume without using two pins for the two different sound outputs?
Lower/ higher impedance speakers? a 5k log pot perhaps? so user adjusts headphone / speaker volume?