Motion sensing fog machine

Our favorite holiday is just around the corner, so there’s no surprise in seeing a few builds to scare children turning up in the tip jar. [Greg] also loves Halloween and apparently puts on a good show – he always uses a fog machine on his porch on All Hallow’s Eve, but triggering it at the right time is always a pain.

This year, [Greg] decided to build a motion-sensing fog machine. His machine featured a wired remote with a light to signal when the fog machine is ready and a button to start the pump. This remote runs at 120V AC, but [Greg] figured he could stick a small USB phone charger in the remote and power an ATtiny85 microcontroller.

The actual circuit is just a piece of perfboard, a large, old relay from Sparkfun, and a PIR sensor [Greg] picked up last year. Whenever the PIR detects movement, the Tiny85 activates the fog machine for 5 seconds and disarms itself for another 10, until it sees movement again. Just the thing for a little interactive ambiance for [Greg]’s Halloween display.

Video after the break.

Continue reading “Motion sensing fog machine”

Another Automatic Air Freshener Use


We’ve seen air fresheners used for many hacks here at hackaday. This one is a bit different as it uses the PIR sensor assembly to turn on LEDs in sequence, rather than reversing a motor. Generally, the motor would be reversed by the fact that this assembly is reversing the voltage on a motor (see [H Bridge] on Wikipedia), but instead it turns on one set of LEDs and then the other.

This works because a diode (the “D” in LED) only allows current to flow one way. The LEDs are reversed with respect to the voltage source, making them come on in sequence. An Arduino or other microprocessor could of course be used to accomplish the same thing (see this [HAD] post about harvesting the PIR sensor only). However, if you had $10 or less to start your hardware hacking career, this is yet another way an air freshener can be hacked up to do your bidding.

Be sure to see the video of this simple hack after the break, used to “LED-ify” a Star Wars AT-ST painting. If you’re interested in using the gears and motor of an air fresher as well, why not check out this post on remotely triggering a camera with the internals from a time-based model? Continue reading “Another Automatic Air Freshener Use”

Dual PIR photo trigger by crossing the streams

Motion sensing can be quite effective when taking photographs of wildlife. But how can one be sure that the motion was at the center of the frame? A PIR sensor picks up motion in its entire viewing range. It’s not really something that can be aimed. But if you use two PIR sensors you can monitor a focused area for motion.

The trick is to use a logic circuit. By building an AND gate you can trigger based on motion in the area which is overlapped by both of the sensors. In this case the AND gate is built from a voltage divider. The outputs of the PIR sensors are connected above and below the divider’s connection to the photo trigger. Both have a protection diode, and the divider is tuned so that both PIR outputs must come one in order to raise the trigger input above the voltage threshold. So much for never crossing the streams.

[via TriggerTrap]

Motion sensitive RGB lamp can standby for 3 years

Ooooh, nice enclosure! This is a little motion sensing lamp which [Krazatchu] built a few years back as a Mother’s Day gift. The PIR sensor is easy enough to see as the white dome on the front of the case. But look closely below that and you’ll see the LDR which it uses to keep the thing asleep during the day. This is intended to save on batteries but the original version still ate through them like crazy. This year he gutted it and worked out a much more power-friendly design.

He moved to a TLC1079 OpAmp which greatly reduced power consumption when reading from the PIR sensor. The microcontroller was also upgraded from an ATtiny13 to an ATmega328, making the new version Arduino compatible. It puts itself to sleep and keeps the lights out during the day, drawing just 0.08 mA. When driving the RGB LED the lamp pulls about 50 mA. That should still last a while on three AA batteries but we’d still recommend using rechargeables.

Continue reading “Motion sensitive RGB lamp can standby for 3 years”

Stop light converted to control office foot traffic


When [Paul Rea] started work with his current employer, he was intrigued by a traffic light that sat unused near the entrance of the “Engineering Loft” where he was stationed. He promised himself that he would get it working one day, but several years passed before he had the chance to take a closer look at it.

He took the light home with him over Thanksgiving weekend last year, and started to dig around inside to see how things were wired up. It turns out the light was a pretty simple contraption, though he discovered it ran on mains voltage, something [Paul] didn’t really want to fiddle with. He swapped out the traffic light’s bulbs for some low-voltage models, which he could easily power with a 12v wall wart.

[Paul] then added an Arduino and PIR sensor to the light fixture in order to detect when someone was leaving the Engineering Loft, warning those who are on their way in. He says that people don’t really pay attention to the light very much, though he is pretty happy with the results.

Continue reading to see a short video of the traffic light in action.

Continue reading “Stop light converted to control office foot traffic”

Pee-light gives guidance for nocturnal tinkles

This light is a rather dim LED module whose purpose is to give you a very small bit of illumination when using the restroom at night. If you rely on it instead of using the overhead lighting in the bathroom, you’ll be able to find your way back to bed with your night-vision undisturbed.

[Fred] built the project as a way to learn more about using MSP430 microcontrollers. The protoboard seen above has a pair of female pin headers designed to accept an MSP430-PIR board, which uses the low-power microcontroller to monitor a PIR motion sensor. The chip can be reprogrammed and [Fred] did just that, using the USB dongle side of the eZ430-F2013 dev stick. Now when the sensor detects motion the chip first checks the light-dependent resistor on the protoboard to see if it’s dark in the bathroom. If so, it switches on the LED and sets a timer to shut if off again.

The system runs on a 9V battery, which is a bit under-powered for the 12V-spec’ed LED module. But [Fred] says the light it produces is just the right intensity.

[Thanks Jeremy]

Building a battery-powered motion alarm

[Brad] was asked by his Sister to design a motion-based alarm that would help her catch her son sneaking out of the house at night. Obviously this didn’t need to be a long-term installation so he decided to throw something together that is only active at night and can be battery-powered. What he came up with is a light-sensitive motion sensor that uses very little power.

He knew that an Arduino would be overkill, and decided to try his hand at using the Arduino to develop code for an ATtiny85. It has an external interrupt pin connected to the output of the PIR module, which triggers action when motion is detected. The first thing it does is to check the photoresistor via the ADC. If light levels are low enough, the buzzer will be sounded. [Brad] measured the current consumption of his circuit and was not happy to find it draws about 2.5 mA at idle. He spent some time teaching himself about the sleep functions of the AVR chips and was able reduce that to about 500-600 uA when in sleep mode. Now all he has to do is find a nice place behind the house to mount the alarm and there’ll be no more sneaking around at night.

If you’re trying to keep a tight leash on your own kids you could always make them punch the time clock.