Gravity and magnetism are your friends! Especially if you'd like to create an interactive exhibit on the history of 16th-century Portuguese trading networks...
This robot is based on the same mechanics as a drawbot, but uses magnets instead of a stylus. When you look at the bot from the front (or whatever you want to call the side without the motors), all you see is a magnet moving across the board. A controller hooked up to a computer lets passers-by move the magnet to whatever location they want.
This robot was created for a one-semester-long graduate History course in Interactive Exhibit Design. You can read more about that on my blog. Now let's get to making it!
Step 1: Build the Frame
What you'll need:
- Foam core (I used a 17.5in x 11.5in piece of foam core; the MicroRAX dimensions below are based on that)
- Stepper motors x 2
- PhidgetStepper Unipolar 4-motor
- Accompanying USB cable
- 12 V DC cable
- String (enough to reach all areas of the foam core with some extra string left on each bobbin)
- Strong spherical magnet
- Zip ties
- Double-sided poster tape
- Strong, small magnet
- 17.25in piece x 3
- 11.5in x 4
- 8in x 2
- 2.4in x 2
- Corner-style joining plate x 6
- L-style joining plate x 4
- 90-degree joining bracket x 14
- 56 screws (I think, lost count after a while) and around 28 of the thin plates to screw into
- Circuit board standoff set
First, decide how big of a "display" you want, keeping in mind that a portion at the top will be unusable because this is where the motors will be mounted. How big the front is will depend partly upon what you want to display - in my case, a portion of a 16th-century world map. Foam core is a good choice, because it's thick enough to slide into the grooves of the MicroRAX.
The frame of the robot can essentially be built in whatever configuration you'd like, as long as it's sturdy. You may need more or less of the MicroRAX depending on how big your robot's going to be.
Once the frame is built, mount the stepper motors, one in each corner at the top. Mount the Phidget in the middle so that the motors can be hooked up to it.
Wind the string around the bobbins and attach them to the stepper motors. You want an equal amount of string on each bobbin so that the magnet will hang from the middle of the string. You may want to consider having wider stoppers on the ends of the bobbins so that string can't slip off.
Suspend the magnet from the middle of the string. On this robot, the magnet was surrounded by mesh which was closed off by zip ties. Zip ties can also be used on the cables to keep things tidy.
Finally, print your image of choice and mount it to the foam core. Double-sided poster tape works well for this. After inserting the foam core into the robot, add another piece of MicroRAX across the top to hold it in place. A small magnet placed on the outside of the foam core will now stay in place, thanks to the suspended spherical magnet on the other side.
Step 2: Programming
By using Phidgets, I was able to create a robot that is controlled by Cycling 74's Max 6. What does that mean? It means I don't have to worry about gcode, that's what.
What you'll need:
Max 6 is a visual programming language, which I find helpful, as a beginner. The other great thing about Max is the ability to switch from a programming mode (or "patching" mode) to a presentation mode, which shows everything you want users to see and nothing you don't. In my program, I used simple game navigation to let users choose which "port" on the map they wanted to visit next. The first video shows one of my first test runs of the program and the robot to give you an idea of how it works.
In addition to making the robot move the magnet from place to place on the map, for each stop the presentation mode of my program displays pictures and text, plays audio, calculates current distance travelled and shows users their options for where to go next. This is where the second video comes in, which is another test run from a bit further along in the programming. You can read more about that and download the code in several versions from my blog.
If you want to use the robot to lead users through a series of prearranged paths, like I did with the story of Portuguese trade networks, the first thing you'll want to do is decide how many stops you want the robot to make, and where those stops are on the foam core. Then choose the place you want the small magnet to start off at. Steer the motors to that location within the program. Save and turn off Max, then unplug the robot; plug the robot back in and restart Max. This should set the current location of the robot to 0,0 (if you think of the piece of foam core as a Cartesian plane).
Now that you've set a "home location," find the "coordinates" of each other place in the journey by steering the robot there in the program. Take note of these numbers and incorporate them into your program so the robot knows which set of coordinates corresponds to each place. Try to avoid picking stops that are close to the edges of the display, since the robot tends to get less precise as it moves towards the edges.
The next thing you need to do is specify the relationship between the stops, i.e. which places lead to which other places. In Max, I gave each city a number, then used a message to specify how the numbers were related (1 leads to 2, 2 leads to 3, 3 leads to 4 or 7, etc.). Users choose where they want to go to next based on the arrow keys. When an arrow key is pressed, the next city in that direction is chosen, the coordinates for that city are relayed through the Phidget to the stepper motors, and the suspended magnet behind the map moves, causing the magnet at the front to move with it.
**IMPORTANT** When you're testing and using the bot, make sure that you always return to your "home" location before turning Max and the robot off. If you don't, whatever your current location is will be remembered as 0,0, and all your other pairs of coordinates will be thrown off!
Step 3: Create a Custom Control Panel (Optional)
It's not necessary, but having a custom controller is way more fun than manipulating the robot through a boring old computer keyboard. Because my program included visuals, I built the panel at an angle to leave a strip of the laptop screen visible.
What you'll need:
- USB-powered joystick or other controller of choice
- Arcade button
- Makey Makey
- Cardboard (I used two old iMac boxes)
- 8 hinges
- 16 re-clips
If you're using the panel to cover a portion of your computer, like I did, start by taking measurements of the computer. Keep in mind that you will need enough space between the keyboard and the cardboard for the wiring of the joystick and the button. Note the measurements and cut the cardboard to fit.
Decide where you'd like your controller to go. I used a joystick for navigating in each of the four cardinal directions, and an arcade button to restart. Once you've selected locations for these items, cut holes in the cardboard to fit them through. Secure them with extra cardboard pieces and tape.
Once those are secure, hook up your button and joystick to a Makey Makey. This is an easy way to make your device talk to the computer. I hooked the joystick up to be read as the four arrow keys, and the button as the W key. Max 6 can then read these devices as key inputs and respond accordingly.
Next I measured the distance between the tabletop and the top of my laptop screen when it was leaning at the desired angle for display. I then created a stand from cardboard and Makedo for the robot to sit on. This allows users to see the robot and the screen in the same field of vision. If you aren't going to have your computer visible, this step may be unnecessary. Make sure that the stand is sturdy.
Now put it all together...and you're done! Sit back and enjoy watching people as they see your map marker "magically" move on demand.