My three year old grandson loves his LEGO train, and this Christmas he asked if I could make him a few remote switches (OK, he had a little prompting from me on this). I knew there were other solutions out there, but I wanted to spin my own. I'm a radio control model airplane enthusiast, so my solution involved components from that hobby. Total outlay for the components for four train track switches was $55 on Amazon. That got me four servos, a servo tester, and a battery box for four AA cells to power everything. All other parts are official LEGO, and the switches required no modifications.
The pic shows a left turn switch modified to be a remote switch. The servo is a little hard to see, so I put an extra servo in the pic in the same orientation as the one in the mod. The device with the red knobs is a servo tester that can drive up to six servos. It's mounted with double stick tape on top of the battery box. Each servo is wired to the tester, and I later lengthened the cables to 7' myself. The servos are exactly 40 mm long, perfect for 4+1=5 nubs of LEGO spacing--the servos just press-fitted in. I cut a piece of LEGO base panel to engage with the control arm base of the switch. Just a simple LEGO build from there on!!!
Please use our links: LEGO.com • Amazon
Recent discussions • Categories • Privacy Policy • Brickset.com
Brickset.com is a participant in the Amazon Services LLC Associates Program, the Amazon.com.ca, Inc. Associates Program and the Amazon EU Associates Programme, which are affiliate advertising programs designed to provide a means for sites to earn advertising fees by advertising and linking to Amazon.
As an Amazon Associate we earn from qualifying purchases.
Comments
Seriously, this is pretty great though.
I liked how you put it all together and can see making sheds or other structures to hide the assemblies.
As for it not being 100% pure Lego, automating trains/switches 100% in Lego isn't easy, so those of us severely bitten with the bug often incorporate 3rd party products. For example, the curved track Lego makes is only available in one radius and it's actually pretty tight, which makes the train motors work harder and drains the batteries faster. Wider radius curved tracks from 4DBrix or BrickTracks alleviate that and allow for better looking layouts because you can have two tracks running side by side, with 8 stud separation, through a curve. Now if Lego were to offer different track geometries, I would buy them, but they don't, so I have no issues buying compatible products.
This project prompted me to go out last week and buy an Arduino Starter Kit ($29). I wanted a better solution than the servo tester shown in the pic in my original post. I had never done anything with Arduino, but I'm a quick learn on these sorts of things. Arduino boards can directly drive servos, and the kit I got had a small IR remote control with 21 keys, including a 0-9 numeric keypad. So I now have the Arduino board connected to the servos to control them, and the remote changes the switches with just a button push. Push "2" once, and switch #2 toggles over to straight. Push it again, and it toggles back to curved. He really likes that solution better.
I can imagine the Arduino being in a LEGO "Train Control Station" that he will build for himself, but we haven't done that step yet. I just got the Arduino to light up LEDs to show the switch states. I need to solder things together, rather than having the prototype board shown in the pic above, taken in my Development Laboooratory, as we call it. Final product will be about the size of a deck of cards, with LEDs mounted on a LEGO board of some sort, to integrate into the Station. The Station can be put in the back of the layout to keep wiring out of the way better. Fun project!.
The Final Solution: The final product is below, ready to be surrounded by a LEGO building of some sort. In the first pic, the small unit is an Arduino Nano (under $4.00) and the larger unit is a servo driver ($14.00). This hardware can drive up to 16 servos if needed. I have four switches so far, and only two are connected in the pic.
I used a new, smaller, servo that costs just $1.70, if you buy 10. Plenty of power to throw the switch. Used a paper clip to make the link to the LEGO control arm.
Two switches shown, mounted back to back. LED bar (upper right) displays the switch status for six switches (red for curve, green for straight). The blue "tower of power" to the left is the IR receiver for the remote. Both the LEDs and the tower will be incorporated into the building I'll make for the control electronics. Fun project--I learned a lot.