I'm playing with a piezo electric plate to test pressure.
Simple hook up:
positive lead from the piezo to analog input 0
negative termial to ground.
Analog reading the input
serial printing the output to get the image below:
Problem:
As you can see, at a certain pressure point it maxes out the adc (1024). What I am wondering and can't figure out, is there a way to scale the voltage coming out of the piezo by say a factor of 2 or more so that the max voltage coming out of the piezo is half and thus can be graphed?
Add a load resistor across the piezo element. Piezo devices are charge sources, the lower the resistor value
across them the lower the voltage produced. Because its a charge source you only get current when the
force changes - you can't easily measure a steady load without integrating the current or voltage signal.
In theory you could use just the piezo element with a voltage sensor than can handle large voltages, in
which case it acts like a charge source across a capacitor, which gives a steady voltage out (ignoring
leakage). But the voltages aren't very practical and leakage is variable.
You could try adding a (low leakage) capacitor across the element too, which should just reduce the voltages involved.
A lower value load resistor also changes low frequency cutoff point.
Not sure what the graph represents.
It seems OP has used a pull up resistor.
Not sure what is being measured.
For vibration, the pull up might have to be replaced with a mid-voltage bias circuit.
Post a connection diagram.
Leo..
The graph represents the analog voltage generated from the piezoelectric plate. I am pressing hard on the plate and then releasing a bit of pressure and then pressing hard again
A piezo doesn't provide a DC reference so without a resistor, the input will "float" (to an undefined voltage).
It should be a high-value resistor (Typically 1M Ohms or more) connected between the analog input and ground. The lower the resistor value, the lower the signal.
With the resistor, the ADC should read zero (or near zero) when the piezo is "inactive". With a high impedance/resistance input, you will pick-up some noise, especially if the wires are long and/or near any AC voltages, so it probably won't read exactly zero.
Without a resistor you can get up to 80V from those things which will damage your Arduino.
As noted before it in not the pressure you are measuring but the change in pressure. For constant pressure you will get nothing. You only think you are getting something because you have charged up the input capacitor, it is a fake reading.
Grumpy_Mike:
Without a resistor you can get up to 80V from those things which will damage your Arduino.
As noted before it in not the pressure you are measuring but the change in pressure. For constant pressure you will get nothing. You only think you are getting something because you have charged up the input capacitor, it is a fake reading.
But the current is usually small, so the input protection diodes will generally protect from this, the
exception being high frequencies as the current goes up with frequency for an AC charge source.
You can use a capacitive voltage divider with piezos to preserve the frequency response. Since the piezo is itself a capacitor, placing a cap in parallel with it has the main effect of reducing the amplitude.
MarkT:
But the current is usually small, so the input protection diodes will generally protect from this, the
exception being high frequencies as the current goes up with frequency for an AC charge source.
So you are saying you can't blow up an Arduino pin with a raw input from a piezos? Well in this case you are wrong, done it myself.