Trouble reading frequency
Hello, I've used stamps many times over the years and this is the first time posting on this forum. BTW I have searched this forum and the net for an answer before coming here and still cannot find what I am looking for.
I am having trouble reading frequencies with my bs2 using piezo film sensor that I purchased from Parallax. I used the same schematics listed in the pdf. http://www.parallax.com/Store/Sensors/PressureFlexRPM/tabid/177/CategoryID/52/List/0/Level/a/ProductID/89/Default.aspx?SortField=ProductName,ProductName
My problem is that it will only show a frequency in debug window when I shake the sensor or by moving/bending it. It will not register anything if I put a loud radio speaker near it and not when I slam my hand on the table. I have to really hit the table hard near the breadboard to get it to show anything.
Am I using the wrong sensor for the task? I basically want to measure small vibrations or sounds of multiple frequencies (one would be from a cars exhaust).
Here's the basic set up.
Same schematics listed in the pdf from above page.
sample code.
v0 VAR Word
v1 VAR Word
v VAR Word
F VAR Word
MAIN:
PULSIN 5, 1, v1
PULSIN 5, 0, v0
v = (v0 + v1)*2
f = (50000/v)*20
DEBUG DEC f, " Hz "
DEBUG DEC v, " V ", CR ' just to show small numbers
P.S. I have also tried using 'COUNT' instead of 'PULSIN'.
Thank you,
I am having trouble reading frequencies with my bs2 using piezo film sensor that I purchased from Parallax. I used the same schematics listed in the pdf. http://www.parallax.com/Store/Sensors/PressureFlexRPM/tabid/177/CategoryID/52/List/0/Level/a/ProductID/89/Default.aspx?SortField=ProductName,ProductName
My problem is that it will only show a frequency in debug window when I shake the sensor or by moving/bending it. It will not register anything if I put a loud radio speaker near it and not when I slam my hand on the table. I have to really hit the table hard near the breadboard to get it to show anything.
Am I using the wrong sensor for the task? I basically want to measure small vibrations or sounds of multiple frequencies (one would be from a cars exhaust).
Here's the basic set up.
Same schematics listed in the pdf from above page.
sample code.
v0 VAR Word
v1 VAR Word
v VAR Word
F VAR Word
MAIN:
PULSIN 5, 1, v1
PULSIN 5, 0, v0
v = (v0 + v1)*2
f = (50000/v)*20
DEBUG DEC f, " Hz "
DEBUG DEC v, " V ", CR ' just to show small numbers
P.S. I have also tried using 'COUNT' instead of 'PULSIN'.
Thank you,
Comments
That is not a problem, that is what this sensor is designed for. moving and bending is the only way it can produce a voltage.
If you want to pick up sound from a piezo you need something like this http://parts.digikey.com/1/parts/33-buzzer-piezo-4-1khz-ext-drive-cep-1110.html
Or a standard transistor radio earphone also works as a microphone!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Think Inside the box first and if that doesn't work..
Re-arrange what's inside the box then...
Think outside the BOX!
Post Edited (metron9) : 1/28/2009 7:08:46 PM GMT
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
Thank you,