Quote Originally Posted by Jumper View Post
Cant you use an interupt that will start a timer when the circuit opens.. and then you use an interups to stop the timer when the circuit closes and reload timer.

Then you set up the timer to overflow at a suitable time. If the box is tilted the timer will overflow and give you a timer interupt. If the box is just shaked the time between sensor toggle is so small so you will not get an overflow.

maybe ;-)
Yes, it is a good idea to try. But the main issue is that the sensor gives a series of pulses when triggered. Is not like the mercury tilt switch. Either shaked or tilted.

Quote Originally Posted by AvionicsMaster1 View Post
You could put a capacitor across the sensor to "average" the oscillations. Better yet, a RC network tuned to give you the desired time you want.

I'm curious though, there is nothing in the datasheet says this will work as a "tilt" sensor. Only says it's a "vibration" sensor yet doesn't give you any specs on minimum movement required to trip the sensor. If someone moved the sensor very slowly would the sensor sense that? If not, it won't work as a tilt sensor as those trip when something is tilted no matter how slowly it's moved.
Since we have a microcontroler, why make an integrator with RC net? As for the kind of sensor, yes it is more a vibration that tilt sensor, though very sensitive and can be used I guess as such.

Quote Originally Posted by Jerson View Post
The last time I did something like this I used a mercury bulb switch. Yes, those were still available some years back; not sure about now. A slight tilt would cause the mercury blob to move thus breaking the circuit. For a vibration sensor, a cheap chinese toy was inspiration. Just needed a straight wire soldered perpendicular to a pcb surrounded by a spring (also soldered to pcb) with a blob of solder on its end to make its end heavy. Movement causes the blob to oscillate leading to multiple closures of the contact between spring and wire.
If this kind of sensor is commercially available, please give a link. This is going to be used in a relative low production.

Thanks all for the contribution.

Ioannis