Introduction: IT's HEAD

For this first therm, we have been told that we should create an animatronic project related with Halloween, using our knowledge of programing and arduino’s components.

In our case we have done an animatronic mask that rotates 360º and it stops moving it’s mouth and brighting it’s eyes when detects someone in front.


  • Arduino 1 Board
  • 2 x 220Ohms Resistance
  • Wires
  • Ultrasonic Sensor
  • Servomotor
  • Stepper Motor
  • 2 x Red LED’s
  • BreadBoard
  • Porexpan Head
  • American Tape
  • IT’s Mask
  • Ping Pong Balls
  • Wood Box

Step 2: BUDGET

Arduino Kit (Amazon) 30€

EPS (Porexpan) Head 15€

IT’s Mask 10€

Ping Pong Ball 1€

Wood Box “FREE”

Sheet of Al “FREE”



This is a schematic sketch of our animatronic system using Tinkercad.

Step 4: HOW?

To do this project we have carried out different phases.

Starting with the idea of our Halloween project, we decided the functions that our arduino board would have to carry out.

We decided that our system would work with the ultrasonic sensor, which would activate a servo motor, 2 LEDs and a stepper motor.

Next we assemble our initial circuit on the breadboard using the Arduino 1 R3 motherboard.

Once the entire circuit is assembled, we must join the entire circuit to the head of the mannequin. In our case we have established the base plate at the nape of the head because it is the easiest part where to connect the cables so that the mask does not bother us.

For the eyes we have drilled the head, and we have passed the LEDs until we reach the eyes, finally we have used half a ping pong ball for each eye.

In the case of the movement of the jaw, when having to move it, we thought about doing the scissor effect. Establishing a fixed piece of wood and another integral part to the servomotor, to achieve the scissor movement.

We have also developed the head rotation system using a stepper motor together with metal supports in contact with a metal surface to reduce friction.

Finally we have joined all the head structure on a wooden structure, which will support the hole animatronic system. Also we have attached a power bank to the head for giving energy to the hole system.


#include // Ultrasonic Sensor Library

#include // ServoMotor Library

#include // Stepper Motor Library

Servo myservo;

int trigPin = 7; //Trigger "Emits a signal"

int echoPin = 6; //Echo "Recieves the signal, when it bounce something"

UltraSonicDistanceSensor distanceSensor(trigPin, echoPin); // Initialize sensor that uses digital pins 7 and 6.

int led1 = 4; //Red led attached to pins 4 and 2

int led2 = 2;

const int stepsPerRevolution = 2048; //Number of steps in a lap

Stepper myStepper = Stepper(stepsPerRevolution, A0, A2, A1, A3); // Stepper Motor Attached to pins A0, A1, A2 AND A3

void setup() { //Inside void setup we describe the type of data we are going to receive

Serial.begin(9600); //We inicialize the program specifying its initial velocity

myservo.attach(5); //We declare that our servo it is attached to pin 5

pinMode(led1, OUTPUT);

pinMode(led2, OUTPUT);

pinMode(trigPin, OUTPUT);

pinMode(echoPin, INPUT);

myStepper.setSpeed(10); //Stepper Motor Speed, (maximum speed 18)


void loop() { //Inside void loop we are going to describe the functions that we want to run

int distance = distanceSensor.measureDistanceCm();

Serial.print (distance);

Serial.println("CM"); //We establish the units of distance measurements


if (distance <= 50 && distance >= 0) // Measures the signal distance of the ultrasonic sensor, if the distance is equal or less of 45 cm, the sensor will activate.


digitalWrite(led1, HIGH); // Turn on the LED'S

digitalWrite(led2, HIGH);

myservo.write(110); //Move the servomotor to 110 deegrees

delay(500); //We have established a delay of 500 miliseconds between an actions

myservo.write(0); //Returns the servo to its initial position





digitalWrite (led1, LOW); // Turn off the LED'S

digitalWrite (led2, LOW);

myservo.write(0); //Maintain the servo at 0 deegrees

myStepper.step(250);// We establish a step quantity for reading the ultrasonic sensor




After all the ideation and creation process of our Animatronic set on Halloween, we have achieved the main objective that involves all the content and knowledge acquired during the quarter.

MADE BY: Aleix Mas, Jordi Noguer and Alejandro Morales