Spinning Skull Controlled by Web App

by CJA3D in Circuits > Arduino

2802 Views, 48 Favorites, 0 Comments

Spinning Skull Controlled by Web App

Halloween - Spinning Skull controlled by Web app - powered by LinkIt ONE
562ef0a145bceb59d50002d3.jpeg
562da8a34936d427b100049d.jpeg
562daa4145bcebcee30008ab.jpeg

Here is a great halloween decor item for the dinner/snacks table for your Halloween party. Make a spooky spinning skull which you can trigger from a simple Web App on you tablet/mobile while your guests are picking up their snacks..

The spinning skull movement is triggered when you click the "Move Head" link in the web app which is hosted on Mediatek LinkIt ONE board connected to a servo. In addition you can change the color of the RGB LED in the skull using the web app as shown in the video above.

Collect the Componets You'll Need

IMG_9069.JPG
562d820e15be4d3d0c00074c.jpeg

Here are the list of components you will need to complete the build

Electronic component

  • Mediatek LinkIt ONE board
  • Arduino Proto shield
  • RGB LED
  • 2 Red LEDs
  • 220 ohms resistors (6)
  • Servo
  • 4 AA batteries
  • 4AA battery holder
  • Bread boarding wire
  • USB cable to program the skull
  • Skull - while selecting the skull take the Link It one, servo and battery holder to check that they approximately will fit in the Skull
  • Tuna can to mount the Skull
  • 3D printer and filament to print the part for the servo mount , this is optional you can use hot glue and other items like cardboard/wood.
  • In addition you will also need a Xacto knife and hot glue

3D Print the Tuna Can Servo Holder

562d836a4fbadeaf650001b7.jpeg
Screen Shot 2015-10-26 at 9.54.24 AM.png
IMG_9072.JPG

To mount the skull on the Tuna tin for free rotation using a servo , 3D print the STL file attached using black PLA filament or a color that suits the color of the other decor items

In my case I am using Repetier-Host as my 3D printing software with the Printrbot Simple metal, and the slicer set at 0.2mm layer height .

  • Slicing the files should take about 30 seconds
  • And printing the files takes about 40-50 mins.

Attaching Servo to the Skull

IMG_9074.JPG
IMG_9076.JPG
IMG_9078.JPG
IMG_9081.JPG
IMG_9089.JPG
IMG_9091.JPG

Now to add the Servo the skull and mount it on the tuna tin,start off cutting the skull from behind with enough space to add battery holder and the LinkIt one board.

Cut a hole just below the jaw at the spot where you are going to add the servo

Using hotglue/screws that came with the servo secure the servo the skull , and add the servo horn to the 3D printed part and attach and secure it to the skull using a screw.

Using a couple of rubber bands secure the tuna tin with the 3D printed part.

Putting the Circuit Together

IMG_9182.JPG
IMG_9095.JPG
IMG_9099.JPG

Mount the Arduino Proto shield on the LinkIt One board and make the following connections using a 220 ohms resistor

  • Red LED for the left eye to pin#12
  • Red LED for the Right eye to pin#13
  • RGB LED connected to pin #7 , 8 and 10

Now connect the signal line of servo the pin #9 which is one of the PWM pins on the LinkIt one board and that other +ve pin to battery holder and ground . Here remember to also connect the ground from the battery holder to the common ground on the Proto shield.

Once done cut holes in the eyes on the skull to add the Red LEDs.

Uploading the Code and Running a Basic Test

Screen Shot 2015-10-25 at 6.55.44 PM.png
562dab272e7fb652440014a3.jpeg

To setup the Arduino IDE for the LinkIt ONE register and create an account on the MediaTek Labs website

Then follow the link below to download the latest driver and software LinkOne Board

http://labs.mediatek.com/site/global/developer_too...

Upload the blink example sketch that comes with the Arduino IDE and see if the LED on the LinkIt one board blink, in our case it the Red LED which we are going to add to the right eye.

Now download the ino file attached and change the WIFI_AP and WIFI_PASSWORD to you home Wifi router name and password.

Select the board and the port and upload the code as shown in the first picture above.

If you want to debug/modify the code, un-comment the Serial.begin(115200); line and you should be able to use your serial monitor for debugging as shown in the second picture above when a link on the web app is pressed.

Securing the LinkIt-one to the Skull Using Zip Ties

562da48e4936d4b9770000e7.jpeg
IMG_9117.JPG
562ef36515be4d0260000198.jpeg
IMG_9173 copy.JPG

Now using zip ties/string secure LinkIt ONE board and proto shield to the top of the skull and battery holder to the bottom.

If you are not planing to run the LinkIt ONE using the Lipo, but plan on using a USB cable connected to the wall socket make cut the section of the skull to insert the USB cable.

Finally cover up the tuna tin using tape or cloth .