Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Sound Reactive LEDs

Status
Not open for further replies.

Sizer

New Member
Firstly Hi!...noob here....

Im trying to do a project with my two lads and don't know a great deal about electronics but I do know what we want to achieve

We want:

10 LED's to light up to music (all at the same time not a bar type thing).
To be able to turn it off and on.
To be able to turn off the light syncing leaving "all LED's" lit.
To be able to adjust the Electret Microphone Sensitivty.
To Run off USB.

At the moment I believe the power from the Microphone needs to be amplified but I dont know how or how much to amplify it by.

The Mic :
(0dB = 1V/µbar at 1kHz, Vcc = 4.5V, Rl = 1kΩ) 60dB ±3dB
**broken link removed**

Done a bit more digging around and found these circuits which I mocked up in iCurcuit....

Source for the left one : https://www.electro-tech-online.com/custompdfs/2012/11/picaxe_sound.pdf
Source for the right one (with video) : http://www.ledhoops.net/2011/10/01/sound-to-light-with-an-electret-microphone/

They both seem to work when simulated so was hoping for some input on wether they will actually work, which ones better or if there is a better solution.

Any help appreciated.
 
You are being RIPPED OFF by being charged nearly 7.5 times as much money for a no-name-brand electret mic that costs much less everywhere else.

Why are the new schematics NEGATIVE images?

The first schematic WILL NOT WORK as I explain on my POSITIVE image.
The second schematic will blow up the LEDs when the switch is turned on.
 
Since you don't want the classic LED bar (LM3915 style) this video will give you a hint.

https://afrotechmods.com/tutorials/2011/11/28/op-amp-comparator-tutorial-and-clapper-circuit/

You should make some aditions (for example a transistor to drive more LED's, a power supply, etc). They are all explained on the other Afrotech's posts. I suggest you starting with the basics (learning how each component works) before starting to connect things together.

PS: You could also take the LM3915 approach, but connecting all the LED's on the same leg via a transistor.
 
Last edited:
You are being RIPPED OFF by being charged nearly 7.5 times as much money for a no-name-brand electret mic that costs much less everywhere else.

Why are the new schematics NEGATIVE images?

The first schematic WILL NOT WORK as I explain on my POSITIVE image.
The second schematic will blow up the LEDs when the switch is turned on.

The diagrams are negative as i use an app on the ipad and its easier on the eye. The second one does seem to work in the video, although i know it needs resistors added to the LED's. The only difference between the 2nd one and mine is he used different transistors but i dont know which ones as the model wasnt stated.

As for the mic, its from a local store although i think that needs changing as its only 4.5v and i want it all to run off 5v.
 
Since you don't want the classic LED bar (LM3915 style) this video will give you a hint.

https://afrotechmods.com/tutorials/2011/11/28/op-amp-comparator-tutorial-and-clapper-circuit/

You should make some aditions (for example a transistor to drive more LED's, a power supply, etc). They are all explained on the other Afrotech's posts. I suggest you starting with the basics (learning how each component works) before starting to connect things together.

PS: You could also take the LM3915 approach, but connecting all the LED's on the same leg via a transistor.

Thanks, just going to investigate the link!
 
OK, had a good look and as I said im starting at the bottom here, but if I understood those tutorials correctly (which I doubt...lol) then maybe this one will work??
So can someone confirm if this is correct, if not where have I gone wrong?

(excuse the colours, was simulating when i took the screenshot)

View attachment 68498
 
Last edited:
The over-priced microphone is designed to be powered by 1.5V when it has a 1k series resistor. Then its voltage is half at 0.75V and its current is 0.75V/1k= 0.75mA.
With my 9V supply then I use a resistor that is (9V/2)/0.75mA= 6k (use 6.2k) then it has a voltage less than 4.5V.

Your new circuit has problems:
1) Its opamp does not have a positive supply and does not have a ground.
2) The 1k resistor that powers the mic wrongly powers the volume control and all the LEDs.
3) The very low resistance of your volume control shorts the signal from the mic.
4) It is missing an important supply bypass capacitor that prevents the opamp from oscillating.
5) The transistor is an on-off switch that lights the LEDS when there is ANY sound so the LEDs will be almost continuously lighted when there is music instead of flashing with the beat.

I fixed it:
I use the transistor as a linear emitter-follower so the LEDs' brightness follows music or voice levels.
 
The over-priced microphone is designed to be powered by 1.5V when it has a 1k series resistor. Then its voltage is half at 0.75V and its current is 0.75V/1k= 0.75mA.
With my 9V supply then I use a resistor that is (9V/2)/0.75mA= 6k (use 6.2k) then it has a voltage less than 4.5V.

Your new circuit has problems:
1) Its opamp does not have a positive supply and does not have a ground.
2) The 1k resistor that powers the mic wrongly powers the volume control and all the LEDs.
3) The very low resistance of your volume control shorts the signal from the mic.
4) It is missing an important supply bypass capacitor that prevents the opamp from oscillating.
5) The transistor is an on-off switch that lights the LEDS when there is ANY sound so the LEDs will be almost continuously lighted when there is music instead of flashing with the beat.

I fixed it:
I use the transistor as a linear emitter-follower so the LEDs' brightness follows music or voice levels.

Thank you for your help i will compare the two and your comments so i understand where i went wrong.

1. The app doesnt let me add that bit...but yh i was aware it needed it.

3. The VR was meant to adjust the sensitivity not the volume or is that what you meant?

4. I read about them but perhaps misunderstood what it did, i thought it levelled out the voltage. So, i left it put so that the lights brightness varied depending on the level of the sound.
 
Can anyone recommend an op-amp and let me know for what reason??
Or is it a case of the cheapest one going?
 
Can anyone recommend an op-amp and let me know for what reason??
Or is it a case of the cheapest one going?
Cheap usually means poor quality or poor performance (or both).
Thousands of opamps are inexpensive. A few are cheap and cost the same. A few are expensive but you don't need them.
I would use an MC33171 or MC34071 because they are single-supply (their inputs work at the negative supply voltage that could be ground) and they are single opamps.
You could use a single opamp from an LM358 dual single supply opamp.
 
Cool they have the 33171 for £2.

Another thought (maybe stupid, maybe not!), assuming using a 100k variable resister, if that is then turned down to 0, the voltage at the LED's would be 9 volts?
In which case the resistors allowing for 7 volts out of the transistor would not be adequate?
 
Cool they have the 33171 for £2.
An MC33171 costs $1.09US at Digikey today which is only £0.68 British pounds sterling so again you are being RIPPED OFF.

Another thought (maybe stupid, maybe not!), assuming using a 100k variable resister, if that is then turned down to 0, the voltage at the LED's would be 9 volts?
No.
The 100k resistor and the 1k resistor connected to it set the voltage gain, not the maximum output voltage. The maximum output of the opamp is about 1.3V less than the supply voltage and the maximum emitter voltage of the transistor is about 0.7V less than that. So the maximum output of the transistor is 7.0V when the supply is 9V.
When the 100k resistor value is reduced then the voltage gain drops then the output voltage is less, not more.

In which case the resistors allowing for 7 volts out of the transistor would not be adequate?
No.
The maximum output voltage from my transistor emitter-follower is about 7V when the supply is 9V.
 
Ok found a nice cheap uk site, but they dont have the MC op amps, would any of these be a suitable replacement??

**broken link removed**
 
In the UK I'd suggest you check out Rapid, Farnell or CPC (a subsidiary of Farnell, but they have different stock and pricing). If I can't get a part from these then sometimes I will use eBay.

Anywhere else, especially Maplins, is going to charge you extortionate prices.
 
Ok found a nice cheap uk site, but they dont have the MC op amps, would any of these be a suitable replacement??

**broken link removed**
You could use one of the two opamps in an LM358 but it does not produce high audio frequencies.
 
You could use one of the two opamps in an LM358 but it does not produce high audio frequencies.

To have the always on feature im after can i connect a switch that makes the voltage goto the transistor emitter so the leds are powered on constantly?

I got an on-off-on switch so i want it off, on or syncing.
 
To have the always on feature im after can i connect a switch that makes the voltage go to the transistor emitter so the leds are powered on constantly?
No.
The maximum allowed emitter-base voltage for the transistor is only 5V. When you force the emitter high then the negative feedback to the opamp will cause the output of the opamp to go to 0V. Then the emitter-base gets 9V which might destroy the transistor and might destry the opamp.

I got an on-off-on switch so i want it off, on or syncing.[/QUOTE]
Connect the center pin of the switch to +9V.
Connect one side pin to power the syncing circuit.
Connect the other side pin to the emitter of the transistor that is OK because the transistor and the circuit are not powered.

A 9V alkaline battery will have a load of 200mA when all LEDs are lighted. Then the battery voltage will drop to 7V in half an hour and will be dead in 2 hours and 30 minutes.
 
Status
Not open for further replies.

Latest threads

Back
Top