Since becoming a dad about a year ago, I find myself strangely drawn to things like Lego, Scalextric and remote control toys "for my son". I also feel that ratherjust than buying toys I want to make personal one-off stuff for him and introduce him into the ways of being a maker himself.

I saw this large Lego figure torch (about 9 inches tall) and felt that it had to be hacked to have a geekier use. So with the addition of a programmable PIR sensor and a few simple components, a motion sensing nightlight was born. Now rather than an on/off switch it will sense if my son wakes up in the middle of the night and gently fade up some LED lighting. Once there's been no movement for 30 seconds then it will fade down again. His room can be completely dark at night and I feel that if he wakes up it's nice that he can see where he is.

I decided this would be a perfect entry to the Hack It contest because it's a double-hack. Not only has the toy been hacked to take a PIR sensor, but the PIR sensor has also been hacked and reprogrammed to do more than it was intended to - it fades the external LEDs up and down gradually using pulse width modulation. If you feel this meets the spirit of the contest then a vote would be nice. However, check out the other entries and vote for one of them too if you think they're good too.

Here's a video of the finished product. You can see it sensing movement and fading up the light. Then I switch it off using his arm as a hidden switch.

Step 1: What You'll Need

Firstly, there's the things you'll obviously need.

  • A Lego figure torch like this one. There are a few available, but I liked the construction worker with his hard hat. If you think he's a little bit Village People there always a fireman (hmmm still a bit YMCA) or Darth Vader (that's better), a Stormtrooper or a Ninja. There's even a "plain" figure if none of those work for you. Avoid the dynamo or alarm clock version if you're doing exactly this hack.
  • A MSP430 based PIR sensor from Olimex.

Then there are a few little electronic bits and pieces. These are the sort of things that anyone who dabbles with electronics should have lying around anyway.

  • A basic NPN transistor
  • 1 x 1K ohm resistor
  • 2 x 100 ohm resistors
  • A small amount of stripboard
  • Some wire
  • A switch

Finally, you'll need some tools

  • A soldering iron (and solder)
  • A Dremel or a craft knife if you're careful
  • A MSP430 launchpad direct from TI's eStore
  • Some superglue

Got all that? Good - then we can begin.

I saw this and thought as a "green" night light to buy a solar garden stake thing, and mounting the solar panel and light sensor to the back of a Darth Vader light. The black of the solar panel will mostly blend in with Darth's suit, and for use, just put him in the window, let him charge and come bed time, it is ready to go lol
I like the modification, that LEGO minifig looks great!
Thanks. I tried to make the modification subtle so it looks like it was always meant to be that way. Ninja hack!
LEGO?! Ninja?! :) <br /> <br />Nicely done, I usually don't condone cutting into LEGO pieces but this ones doesn't really count and you did it so well it seems like a natural thing. LEGO upgrade!
I've only just realised that matches you avatar. I suppose &quot;stealth hack&quot; might be more appropriate but I suppose was thinking of the Ninjago version of the figure...
Love it! <br> <br>Could you please post a schematic and a link to the launchpad as I could only find the PIR. <br> <br>Thanks heaps <br> <br>Steve
I've added a link to TI's eStore for the Launchpad. I'll get the schematic up very soon.
Perfect mate, thanks heaps
Nice! I can see this being a good mod for a Dalek too, but adding an LED to its 'eye'.
I haven't seen a Lego Dalek, but there is a Darth Vader. I'm sure the PIR's red LED could find its way to his light saber! Maybe I should give that a go next...
www.43oh.com, not www.430h.com <br>Can't read the code.
40oh link fixed. Sorry about the typo. <br> <br>Click on the attached C file and you should be able to download the source code - it's just a text file.
Great work, good use of the I'm a dad now so I can by toys line.

About This Instructable




More by fred27:Motion sensing Lego figure nightlight 3D printing records for a Fisher Price toy record player Easy CNC conversion of a small mill 
Add instructable to: