Introduction: Servo Controlled Marble Maze Build 2

Picture of Servo Controlled Marble Maze Build 2

This is an updated build based on a previous Instructable. This one is easier to make and looks a little better. In addition, some new building techniques like using magnets to attach the Lego maze are kind of cool.

The project is for a web site that lets you control this device over the Internet. As before, since it's a web site with latency (no Wiimotes), there are only 4 commands: Up, Down, Left and Right. So the maze itself has to be designed carefully to work with only those primitive commands, and those designs are covered here.

This Instructable is about the mechanical build of this project. Other ones cover the web control. For local control with an Arduino, this Instructable has the controller design and code to make it run. I have also attached the latest version of the local control code to the last step of this Instructable.

Step 1: Parts

Picture of Parts

Metal, Wood & Misc.

6.5" of angle aluminum 1.5" x 1.5" x 1/16" thick

4 feet of aluminum bar 1.5" x 1/8" thick - 1/16" might be OK too. I had some nice anodized bar, but any kind will do.

Plastic sheet - 10" x 10" x 1/16" thick. I recommend polycarbonate/lexan since it's less likely to crack

Lego Base - 10" x 10" (32 studs x 32 studs)

1x Lego bricks

Marble - the right size marble for two Lego studs is 9/16" (14mm), which is common on board games. Land of Marbles has many colors and styles available in this size.

1x4 pine - about 5 feet

(8) 1/4" round x 1/16" thick neodymium magnets

Servos - Hitec HS-5645MGs are recommended


Hardware

I use McMaster-Carr to order the stainless screws, nuts and washers, but you can get most of them at a local hardware store. The wood screws were from the local home store.

(4) 3/8" long #8-32 pan head socket screws for the X Axis brackets to plastic mount

(4) #8 flat washers, split lock washers, and hex nuts - Keps nuts can be used for these instead

(8) 1/2" long #8-32 pan head screws for the Y Axis bracket

(8) #8-32 Keps nuts

(4) 3/8" long #6-32 pan head screws for mounting the servos (two per servo)

(4) #6-32 split lock washers + hex nuts

(2) 1/4" long #4-40 pan head screws for the X Axis servo horn

(2) 3/8" long #4-40 pan head screws for the Y Axis servo horn (the aluminum is thicker)

(2) 3/4" long #4-40 pan head screws for the pivots

(6) #4-40 nuts - maybe a couple split lock washers and flat washers for the pivots would be good.

(8) 1 58" long drywall screws

(4) 3/4" long #8 mod truss lath screws

Step 2: Building the Platform and X Axis

Picture of Building the Platform and X Axis

For the platform, I used a square piece of polycarbonate plastic. Polycarbonate is nicer than acrylic since it will not crack when being drilled and cut. Since the Lego base is 10" square, I made the plastic that size also.

We need to attach a servo horn and a pivot to the base, so I cut a couple of 1.25" pieces from the 1.5" x 1.5" x 1/16" aluminum angle. I actually cut three of them since we need one more in the next step.

I drilled four 3/16" holes in each piece for mounting on the platform, but in the end, I only used two of them for mounting - I used a pair of diagonal holes. I marked the holes in the plastic using the brackets as templates - I held the plastic vertically on a table to make it square, and held the bracket against it to mark the holes. The heads of the screws stick up where the Lego plate will be, but the magnet attaching system I used is taller, so that is not an issue.

On one bracket, you only need a 7/64" hole in the center for the 3/4" long #4-40 screw.

On the other bracket, you need a large hole in the center for the servo horn. I highly recommend a step drill for this - it is much safer and easier for these larger holes. On the servo horn, I drilled out two of the holes with the 7/64" bit, and traced them to the bracket and drilled the bracket. 1/4" long #4-40 screws were used to hold the servo horn to the bracket.

To attach the Lego plate to the plastic base, I used pairs of magnets - one pair in each corner glued to each side so the Lego plate can be removed easily for work. I used super-glue (cyanoacrylate) and you need to be careful not to glue the magnets together! So, I put drops of glue on the plastic and stuck the magnets to the glue rather than putting the glue on the magnets. Once those dried, I put glue on the Lego base and pushed it on top of the magnet pairs.

Step 3: Building the Y Axis

Picture of Building the Y Axis

There are a couple ways to make the Y axis. I used 1/8" thick aluminum bar and bent it. 1/16" might be fine, and would be a lot easier to bend. You could also make corner brackets from angle aluminum or use standard brackets and just 4 straight pieces of aluminum. That may make the construction easier since bending the metal perfectly can be tricky, though bending is very quick to do, and the bracket approach may be heavier and requires a lot more screws and holes.

For this project, the Y Axis was 11.25" x 12". For the bending approach, I split one of the 12" sides up for the bracket. In my case, with the 1/8" metal joining plate opposite the servo allowed them to balance out nicely so the servo does not need to struggle to hold it level.

To join the loop, I used a 1.5" piece of bar, and drilled 3/6" holes and used #8-32 1/2" long screws with Keps nuts. I drilled the 8 holes in the joining piece first, then traced those holes on the Y axis, laying it flat on a table to make it line up nicely. With the corner bracket approach, this step would not be necessary.

On one side of the Y Axis, the servo for the Z Axis needs to be mounted. I traced the servo outline, making sure the servo horn was in the middle of the side. The servo body will be a little off-set. Then I used a Dremel tool to cut out the rectangle, and filed it square and smooth. To mount the servo, I used the servo itself as a guide, and drilled two 7/64" holes for the #6-32 screws to mount it. I used a screw, a split lock washer, and a nut to hold them - there was not enough room for a flat washer.

On the opposite side from the servo, at the joining bracket, drill a 7/64" hole for the pivot to fit in to.

A servo horn and pivot need to be added to the Y axis - just as in the previous step.

Step 4: Building the Base

Picture of Building the Base

There will be one servo bracket and one pivot on the base. One side of those angle aluminum pieces can be trimmed to 3/4" wide since they will rest on the pine boards. The pivot is just one more 1.25" long piece of angle aluminum, with a 3/16" hole in it.

You can buy servo brackets or make one - see the picture for one way. For the one I made, I used a 2.5" long piece of the 1.5" x 1.5" angle aluminum.

The base can be made of of wood. I used high quality 1x4 boards. Two of them were 15" long, and two were 13.25" long - those were critical to make sure the servo and pivot fit perfectly. I used 1-5/8" drywall screws to hold them together. I pre-drilled the holes with a counter-sink drill since they were close to the edge of the wood.

The pivot is centered on one of the 11.25" sides, and the servo bracket on the other side - make sure to center the servo horn, not the servo body, which will be a little offset.

I drilled a couple 3/6" holes in the bottom of the two brackets and used 3/4" long #8 lath screws (large pan heads) to screw them into the wood.

Step 5: Maze Design

Picture of Maze Design

With only four primitive moves (Up, Down, Left, Right), designing the maze can be a challenge. You can't turn the marble in the middle of a hallway, so some special designs are needed. See the picture for the shapes that allow branching. The center of the patterns can be different sizes, and possibly not be used at all, but having something there helps keep the ball on track if it is not moving exactly straight. Those designs have four exits, but you can block one of them to have three.

Step 6: Servos

Picture of Servos

I have tried a few servos with this project. Standard ones will work, but will be a bit unsteady holding the level position. I also have used Hitec HS-645MG servos since they did much better holding the level position. For this project, though, I switched to Hitec HS-5645MG digital servos since they have plenty of holding power without jittering on the level table, and the dead band can be adjusted for the table leveling if necessary.

The latest Arduino code for the local control mode is attached. Have fun! This is a great project for kids of all ages to play with.

Comments

tmamedov1 (author)2015-05-08

Sorry. Correct email is daniil.shapovalov@gmail.com
We've sent you an email

tmamedov1 (author)2015-05-06

Hi Carl. We are creative group from LA. And we would love to discuss a possibility of working together. Please email us at dainiil.shapovalov@gmail.com

mrandle (author)2015-04-16

Does the marble get caught up on all the exposed nubs? I would imagine it would have to be flat or else the marble could get stuck.

CarlS (author)mrandle2015-04-16

The table tilts enough to overcome the resistance of the studs. They actually help keep the marble still when it is not moving intentionally, and allows the table to work when it is not perfectly level.

About This Instructable

7,401views

85favorites

License:

Bio: A Maker since childhood with all the classic symptoms, a robot builder, and an Internet software CTO by day.
More by CarlS:WiFi Mesh Synchronized LED BarsMarching Band Field PropGlow in the Dark Tombstones
Add instructable to: