Magic 8 Ball Mod

How to add custom messages and put your 8 Ball on the Internet of Things with IPv6, 6LowPAN, RPL and Contiki

Mariano Alvira

< mar@devl.org >



Overview

The steps outlined here will show you how to modify a standard Magic 8 Ball to replace the normal message icosahedron with a OLED screen, and how to add wireless microcontroller, and accelerometer. The screen is submersed in the normal Magic 8 Ball goo so that all the original aesthetics are preserved. The messages can be reprogrammed wirelessly without having to open the 8 Ball. The accelerometer detects when the 8 Ball is in use (e.g. tipped from resting to looking through the Magic Hole) and signals the microcontroller to turn on screen and fade in the messages.

This page currently only documents the highlights --- I intend to provide more detailed instructions for many of the steps later. I also intend to make available, as a kit, the elements that are harder to construct. Also, I've only made one of these, so I will not be able to show pictures of certain things until I start making some more.

The steps are as follows:

  1. Buy a Magic 8 Ball or three.
  2. Open the Magic 8 Ball
  3. Drain and keep the blue goo.
  4. Construct the new blue goo keeper.
  5. Construct and test the tethered OLED screen assembly.
  6. Assemble the blue goo keeper screen assembly and add your favorite microcontroller.
  7. Fill the blue goo keeper with blue goo.
  8. Add battery holders
  9. Add accelerometer
  10. Program microcontroller with your favorite firmware.
  11. Modify 8 Ball hemisphere to add threaded insert.
  12. Screw the 8 Ball hemisphere on to the top of the blue goo keeper.

Step 1: Purchase Magic 8 Balls

First you need some Magic 8 Balls. I bought mine from Amazon. I bought four and ended up using three. If this is your first time doing this then I'd get at least two. It can be difficult to find the right tools to open the Magic 8 Ball without damaging it. You will also be modifying the blue goo holder inside so if you mess that up or spill the blue goo everywhere you'll need to crack an extra ball.


Step 2: Open the Magic 8 Ball

These are hard to crack without damage. I settled on squeezing the ball in a large vise. Squeeze until you hear some cracking sounds then release and rotate slightly. Repeat all the way around several times. You are breaking the adhesive bond. Eventually the whole thing will open up.

Remove the white retainer ring --- you don't need that.


Step 3: Drain the blue goo

The blue goo fill plug is held with three screws. Remove those and drain the goo; save it for later.


Step 4: Construct the new blue goo keeper

This step is difficult, time consuming, and will stain your hands, table, and clothes blue. (You can clean the table off with Windex.)

If you have some machine tools you can go ahead and try to build the thing you see in the picture. Otherwise, I will eventually release a kit of parts to make this step easier.

To make your own keeper:

  1. Remove the backside of the keeper.

    I held the keeper in a vise and used a hacksaw to remove the white back piece.

  2. Recover the bubble catcher.

    Inside the keeper is a conical bubble catcher. YOU NEED THIS. A Magic 8 Ball loses much of it's magic without its bubble catcher. Perhaps the magic is in the bubbles?

  3. Face the end of your hacksawed keeper.

    You need a nice flat surface to seal.

  4. Rig up someway to attach the new lid.

    I made a PVC insert held with radial screws. The lid attaches with four cap screws. This works well although it is a bit of a pain. DON'T FORGET TO MAKE ROOM FOR THE BUBBLE CATCHER.

  5. Make a lid.

    I used 1/4" aluminum. Four cap screw hold the lid to the PVC insert. I added a central screw to interface to the 8 Ball Hemisphere (the modded 8ball hemispheres screw together on this threaded post). Then I added a fill plug and cable harness pass through. The pass through was made by drilling a hole through a bolt and countersinking the top-side (to receive an ample amount of RTV sealant). All of this is going to be redone in a better way for the kit. If you are making you own take this as inspiration, not directions.

Key points of inspiration for the brave who don't want to wait for the kit:

  1. The lid/keeper interface needs to be flat. RTV gasket maker makes a great seal.
  2. In addition to a fill plug you should also have an air escape plug --- otherwise filling is slow and painful (and messy).
  3. The central post and 8 ball hemisphere is a really good idea. It works great!
  4. The wire harness escapement is bad. A better way would be to come out the side so that the wires aren't threaded through the lid
  5. DON'T FORGET THE BUBBLE CATCHER
  6. Adding mounting material with a PVC insert for the lid is OK. A better plan though would be to have the lid clamp around the keeper flange with D washers.

Step 5: Assemble the screen assembly; add microcontroller

The screen used is a tiny white OLED 32 x 128 from CrystalFontz:

CFAL12832C-W-B1

This is then attached to a CFAL12832 minimal breakout board that is sold at Redwire

The screen and breakout board is pigtailed. Then the breakout board is coated in Plasti-Dip.

Next the screen assembly is threaded through the bubble catcher and lid. Then it's wired to your microcontroller.

The microcontroller I used is the MC13224v from Freescale. This is an inexpensive little powerhouse from Freescale. Besides only costing $5, you get 24MHz ARM7, 802.15.4 wireless radio with a single-ended 50-Ohm output, 96kB RAM (yeah, that's a lot), and a built in bootloader (no extra programming hardware is necessary). It's fully supported in Contiki so you can go ahead and run a webserver and the latest 6LowPAN with RPL routing on your Magic 8 Ball. No really, your Magic 8 Ball will be running state-of-the-art software using over-the-air protocols that will soon be running the Smart Grid --- and you'll still have 30kB of RAM leftover to do stuff.

I used the Redbee Module and the Redbee Module breakout board.

After wiring up the screen, test it with some code.

My code is available here http://git.devl.org/git/malvira/8ball.git:

$ git clone git://git.devl.org/git/malvira/8ball.git

It includes a perl script to convert a black and white pnm image into the C data structure used in the program.

CrystalFontz also provides test code for AVR microcontrollers.


Step 6: Fill the blue goo keeper with blue goo.

Don't make a mess.

Step 7: Add battery holders

I run the MC13224v and the logic supply for the screen from two AAA batteries in series. The OLED supply on the screen needs greater than 8V. I'm using a 9V battery for this.

With some cleaver hot glueing you can get everything to fit.


Step 8: Add accelerometer

Just about any two-axis accelerometer will do. I just used one I had lying around the shop. I think it's discontinued too --- so it was perfect for the job! The kit will have an option to include a accelerometer and breakout but you can find these just about everywhere.

Don't worry about how its positioned, just make sure you have its sensing plane roughly vertical --- we'll have the software guys sort out where gravity is exactly!


Step 9: Program microcontroller with your favorite firmware.

My 8 ball firmware is here: http://git.devl.org/git/malvira/8ball.git

Everything that is suppose to work does, however it's still in bits-and-pieces. I will be integrated everything together in this tree.

The basic software features are:

  1. Screen control
  2. Tilt detection with accelerometer
  3. Sleeping (and wakeup with tilt detection)
  4. Wireless modification
  5. Webserver/6LowPAN

Step 10: Modify 8 Ball hemisphere to add threaded insert.

Construct a threaded insert to mate with the threaded rod on the lid. Glue this into the 8 Ball hemisphere. I suggest screwing it onto the lid while it dries so that you can avoid alignment issues.


Step 11: Screw the 8 Ball hemisphere on to the top of the blue goo keeper.

Screw it all together! Now you are done. Get beer.