In this example I think it only read high or low input but when I try to read it I can't read anything from sensor. It have no 5V to trigger input high. And If I want to read vibration for build car security how to do it with PIC.
Mike Walne
Joined: 19 Feb 2004 Posts: 1785 Location: Boston Spa UK
Posted: Fri Jul 06, 2012 4:31 am
Begin by having a look at the sensor output on a 'scope.
This will tell you:-
(1) Whether the sensor is working or not.
(2) What kind of a signal you're playing with.
(3) The starting point for your coding.
Mike
SherpaDoug
Joined: 07 Sep 2003 Posts: 1640 Location: Cape Cod Mass USA
Posted: Fri Jul 06, 2012 6:26 am
The Parallax example works if the sensor is used as a switch, like if you tap it with your finger. If you are looking for vibrations you must look for smaller signals. At least use a PIC A/D pin or better yet use an amplifier.
Mike is right. You need to look at the signal with a scope to see just what you are dealing with. _________________ The search for better is endless. Instead simply find very good and get the job done.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum