Ne5532 op amp peak detector

Thread Starter

seayaker

Joined Jan 27, 2009
74
I need to build a peak detector circuit for a piezo drum pad. I've tried a dozen or so of these schematics and can't get any to work. The piezo puts out about 2 volts max, I just need to amplify the signal enough to compensate for the diode loss. 1.png
 

crutschow

Joined Mar 14, 2008
34,280
You need a bleed resistor across the capacitor, otherwise the output will stay indefinitely at the peak voltage or drift to one of the rails.
How long do you want the circuit to hold the peak value?
 
Last edited:

Thread Starter

seayaker

Joined Jan 27, 2009
74
You need a bleed resistor across the capacitor, otherwise the output will stay indefinitely at the peak voltage or drift to one of the rails.
How long do you want the circuit to hold the peak value?
I don't want it to hold the value at all. This is for a midi drum pad, so I need a circuit that will detect the peaks very quickly.
 

Thread Starter

seayaker

Joined Jan 27, 2009
74
That's the classical circuit. Just make sure C is low leakage and temperature stable.
can you tell me what I'm doing wrong? I have 5 volts connected to the vcc terminals and the piezo connected to v in and gnd. but I get nothing when I hit the piezo
 

crutschow

Joined Mar 14, 2008
34,280
don't want it to hold the value at all. This is for a midi drum pad, so I need a circuit that will detect the peaks very quickly.
If you don't want to hold the peaks then you don't want a peak detector, since that's what they do.

So what do you want the circuit to do with the peaks once it "detects" them? :confused:
 

dl324

Joined Mar 30, 2015
16,839
can you tell me what I'm doing wrong? I have 5 volts connected to the vcc terminals and the piezo connected to v in and gnd. but I get nothing when I hit the piezo
I suspect a problem with the common-mode input voltage range.
upload_2018-7-9_19-53-19.png
upload_2018-7-9_19-53-37.png

With a supply voltage of 5V, the opamp isn't guaranteed to work. With a typical device, the sweet spot for the input would be between 2 and 3V. If you can't use a higher (and bipolar) supply, you need a different opamp.

The circuit you're using is only good for holding the peak voltage.
 

Sensacell

Joined Jun 19, 2012
3,432
There is no DC bias path at the opamp input either.

A piezo looks like a capacitor, you need at least a high value resistor from input to ground to bias the input stage.
 

crutschow

Joined Mar 14, 2008
34,280
Something like this?
You can change the value of the R3C1 time-constant to get the filter decay time you want.

Note: To use the NE5532 with this circuit you need a dual plus and minus supply voltage.

upload_2018-7-10_17-9-29.png
 
Last edited:

Thread Starter

seayaker

Joined Jan 27, 2009
74
Something like this?
You can change the value of R3 to get the filter decay time you want.

View attachment 155956
Can I use the ne5532 op amp instead of the lm324? I don't completely understand how this works, I never used op amps before. I thought I could use this simple circuit Peak-detector-circuit.png but it made the piezo signal to weak so I was trying amplify the signal with an op amp. The drum pads are velocity sensitive so the AD converter has to have a definite peak. I wanted to keep it as simple as possible because I have 24 pads and need to build a circuit for each pad.
Thanks for your help and I'm glad to hear the boys are safe.
 

crutschow

Joined Mar 14, 2008
34,280
Can I use the ne5532 op amp instead of the lm324?
Yes, but as I noted, that will require a dual supply, whereas the LM324 is designed for single supply operation so only needs one supply.

What supply voltage(s) do you have?

What is the impedance of the circuit that this signal feeds into?
If it's high enough you may be able to get by with just one op amp per channel instead of two.
 
Last edited:

MrAl

Joined Jun 17, 2014
11,388
Hi,

I would also have to ask what the accuracy requirement is. How accurate does this have to be. Sometimes a diode and cap work, and calibration can come in different ways. It also depends what loads the output.
The frequency is also important, what frequency it has to operate at. Audio would be different than RF for example.
 

Thread Starter

seayaker

Joined Jan 27, 2009
74
Yes, but as I noted, that will require a dual supply, whereas the LM324 is designed for single supply operation so only needs one supply.

What supply voltage(s) do you have?

What is the impedance of the circuit that this signal feeds into?
If it's high enough you may be able to get by with just one op amp per channel instead of two.
I have either 5 or 3.3v, I don't know how to measure the impedance, all I have is a multi meter. I would like to use just one of the ne5532s op amps per channel since I already have them. I have enough to use 2 if needed. if you could put a schematic of the circuit up with any known values I'd really appreciate it.
DSCN045.JPG
 
Last edited:
Top