Designed for any purpose that might need a very sensitive, any-direction, do-not-tilt switch. This instruction describes construction of: 1) My initial, hand-built prototype, thrown together in a single afternoon out of spare parts merely as proof of concept; 2) The follow-on, 2nd generation prototype; and 3) circuit board layout for a final design not yet etched and built. For reference I will call them the Mk1, Mk2 and Mk3 tilt trigger mechanisms. During that first hasty effort on the Mk1 I learned a few object lessons. I labored to circumvent these in the Mk2. Ditto from the Mk2 to my as yet unbuilt Mk3 design. I'll describe the lessons learrned so that you may not repeat my own mistakes. First photo shows you the rough-finished Mk1 prototype which I built almost entirely of parts from Radio Shack. Second photo is of the Mk2 which inc ludes some parts from a national chain hobby store.
Parts List for Mk1 sensor:
Two Circuit boards, Radio Shack 276-148
One CMOS 4011 quad NAND gate
Two resistors, 10M
2 sq in of metal duct tape
Some 30 guage wire wrap wire
Additionally the Mk2 requires:
Thin copper foil.
Thin brass wire (stiffer than resistor leads).
Also shown in both photos is some ancillary circuitry tossed into the project just to make demonstration easy. The add on circuit is nothing but a 555 timer in monostable mode with a red LED for visual output to show when the sensor trips. As this timer circuit is can be had from Google (and found in data books going back to since I was in high school) I won't detail that part here. But for reference, these are the parts I used to built that circuit too.
One LM555 timer
One resistor, 18M
One resistor, 560R
One capacitor, 1uF
One capacitor, 10nF
One LED, red
The 1st picture shows the Mk1 sensor and ancillary timer, all in one (crudely built) package. The 2nd photo shows the Mk2 slightly less crudely constructed.
Step 1: The Sensor Circuit
In the schematic above, note the symbol at top left marked S1 and DPST_TRGR. Read the notes next to it describing the function of pin 1 and also of pins 2 & 3. Refer back to the photo at the introduction and I think you'll make the connection.
Just in case it's not so obvious as I hope, imagine the circuit kind of like this. Picture a double headed base drum, one with a soccer ball inside. Imagine that both drum heads are of metal, that they are connected electrically both to each other and to the battery POSITIVE lead. The soccer ball too is metallic. Not only that, but that the sides of the drum are metal bars like a circular jail cell. Those bars are floating with only a tiny gap between the drum heads as metal ceiling and floor. Of that cage, all the odd numbered metal bars are electrically connected to one another and also to ground through a 10M resistor. Likewise the even numbered bars, but separately from the odds, and via their own separate 10M resistor. The metal soccer ball then, being otherwise free to move inside this cage, will naturally want to come to rest somewhere. In doing so, it will make a tri-point contact between whichever two bars and plate are the lowest.
In that position the metal ball will short two adjacent bars to either one drum head or the other. Tip it in any other direction and one of those tri-point contacts will break, at least momentarily. On rolling over one bar the ball must lose contact with the other. That bar's connection to positive being now lost, it now has no path to positive but only its ground path through the resistor. It's signal falls from high to low. That same ball, on rolling away from contact with either drum head lets both adjacent bars fall to low. Likewise if the ball bounces, however minimally.
Sensitivity is therefor dependent on how easily the bearing will jounce from resting upon any given pair of bars connecting them to one of the drum heads to resting elsewhere. A small bearing resting deeply between rather widely spaced bars will, of course, be less sensitive to being perturbed than a much larger bearing resting atop bars spaced more closely together. Regardless of spacing considerations, however, any jouncing whatsoever likewise triggers this device.
So basically, it turns out to be more of a do-not-move switch than anything else. Being somewhat asymmetrical in response a critical application might require more than one such tilt switch. It might require two or even three to be mounted all at right angles to one another with their outputs AND'd together. For my own purpose I will probably go with just one.
Therefor in my diagram, all I have shown is the bearing (symbolically connected to BATTERY POS) at repose on a single pair of bars. As I drew this up in KiCad, some kind of symbol was required (one that I had to create) and this was what made sense to me.
So the path to high is via the bearing. Paths to ground are via resistor. In between we have a NAND gate. With the bearing at repose both NAND inputs are HIGH. They are 1 and 1, which in a NAND gate gets you a 0. For all the other conditions (1&0, 0&1, 0&0) the NAND gate gives you a 1. And this would light up the LED shown.
That's not where I really put my own LED however. Why not? Because I wanted to know just how sensitive my circuit was. So in my prototype I left out the LED shown in favor of one driven by a 555 timer in monostable mode. It's well that I did because it turns out that the circuit is very sensitive indeed.
How sensitive? The prototype turned out so extremely sensitive that barely a touch was often enough. A touch so brief would not have lit the LED brightly enough or long enough for me to notice so I'd have most likely missed it. But the 555 timer lengthened each to about 30 seconds. So long an extension was deliberate as a part of my larger design as downstream circuits may be in sleep mode to save battery power. Because of this the LED stayed on nearly all of the time as I was not able to hold the circuit still enough for it ever once to settle. And as a result at first I thought my circuit was malfunctioning. But there was nothing wrong with the circuit. The ball-and-cage sensor, however, did have some defects of design and hasty construction. I will explain these two you so that you may avoid them.
Anyhow, in the schematic, that 2nd NAND gate is for input to the 555 timer, which takes a LOW for its trigger. With both its inputs shorted, a NAND gate becomes a NOT gate, inverting the trigger circuit output.