The Interactive Robot, Chris

Introduction: The Interactive Robot, Chris

His name is Chris. A friendly robot who talks to those living alone and need someone be in the room. It has a motion sensor, and as long as it senses someone in the room it will talk. I made this some time ago, therefore I will re-sketch the idea manually with pics and videos showing how it works. Lets take a look

Step 1: The Plan

Failing to plan = planning to let us put a plan. PIR sensor senses that someone is moving in the room, it triggers the Arduino Nano. Nano sends signals to 4 servos to move randomly. Two servos move the head left-right and up-down. 3rd servo moves eyeballs left-right. and servo 4 moves the eyelids up and down. All these move independently and randomly. Nano will also call a random audio file stored into the JQ6500 mp3 module. So now it will talk. audio signal is then fed back into Analog input A5 of arduino to map it to servo 5 to move the jaw of Chris.

Step 2: Parts List

Parts needed here are these

-Neck holder, I used a metal base of a table lamp

-Plastic pipe 2 inch Diameter, 6 inch long shall be the neck

- Swivel joint bearing 3 inch dia called lazy suzan

- 4 small servos like SG90 and one mid size like MG995

-Stars of the party Arduino Nano + Audio module JQ6500 mp3 module

-PIR sensor HC-SR501

-Servo shield for Arduino nano

-2 ping pong balls are the eyeballs

-plastic mask as face.

-Speaker 8 ohm

-Any servo and sensor shield

- Everything else is cut and bend small pieces of aluminum and tin including for the eyelids

- Persistance.

Step 3: Make the Neck

Base harvested from a table lamp. Neck the 2 inch diameter. Fix servo of left-right movement on the pipe side, Then on the top of the pipe fix the swivel bearing sometimes called lazy suzan. You can use any swivel size but I used 3 inch type. On top of the swivel fix a servo with an oval shaped disc which will change the head vertical angel when this oval disc moves. Fix the speaker at Adam apple position. The closer the speaker to the mouth area the more natural it will look when it speaks. Do not place speaker on the base, it will not look natural. As you see the servo shield I also fixed on the neck. I used a low cost sensor shield but I modified it to function as a servo shield by separating the VCC of sensors from VCC of Arduino. This maybe worth another instructable in future so if you are not a soldering person simply use a ready servo shield.

Step 4: Make the Head

connect 2 ping pong as eyeballs and servo with a disc connected to metal wires. Another servo for the eyelids, use thin aluminum for eyelids that makes them easy to blink. This eyelid is important in the coding.

Step 5: Load the Sketch and See the Results

Arduino sketch is sending random angles to the servos and random mp3 file calls, therefore this robot will talk things you may not expect. Prepare mp3 files up to hundreds of phrases and load them into thee JQ6500 .

Loading mp3 files into JQ6500 can be found here

JQ6500 mp3 module

I loaded the Arduino code some time ago. But I did find the initial one which did not include the audio mapping. I will update the instructable once I find it in that old desktop. So please keep an eye.

/*ROBOT HEAD initial sketch created by Goldenshuttle . Coutesy of MESOCODE CANADA 2018 Modified by Goldenshuttle on year 2020 */ #include VarSpeedServo NeckVertical, NeckHorizontal, Eyeball, Eyelid; const int PIRpin = 2; long int now; long int start; long int stopper; long int val; long int startTimeL; long int stopTimeL; long int startTimeB; long int stopTimeB; long int randomEyelid; long int randomEyeBall; long int eyeLidOpen; long int eyeLidClose; boolean eyeLidState=false; // false = close, true = open int EBall,NHorizontal,NVertical; void setup() { Serial.begin(9600); pinMode(PIRpin, INPUT); NeckVertical.attach(5); NeckHorizontal.attach(6); Eyeball.attach(3); Eyelid.attach(9); } void loop() { alternateDelay(500); startTimeL=millis(); randomEyelid= random(1,4)*1000; startTimeB=millis(); randomEyeBall= (random(1,4)*1000)/2; while(PIRpin == LOW) { digitalWrite(13,HIGH); alternateDelay(500); servoMove(); if(PIRpin == HIGH ) { digitalWrite(13,LOW); break; } } alternateDelay(500); } void alternateDelay(int lag) { start = millis(); while(1) { now = millis() - start; if(now ==lag) { break; } } return; } void servoMove() { //Servo Neck Vertical NVertical=random(30,90); NeckVertical.write(NVertical,127,false); Serial.print("NVertical at "); Serial.println(NVertical); //Servo Neck Horizontal NHorizontal=random(20,150) ; NeckHorizontal.write(NHorizontal,127,false); Serial.print("NHorizontal at "); Serial.println(NHorizontal); //Servo Eyelid stopTimeL=millis()-startTimeL; if((((stopTimeL-randomEyelid)<500)&&((stopTimeL-randomEyelid)>0))||(((randomEyelid-stopTimeL)>500)&&((randomEyelid-stopTimeL)>0))||(stopTimeL==randomEyelid)) { if(!eyeLidState) { Eyelid.write(eyeLidOpen,255,false); eyeLidState=true; Serial.println("EyeLid is Open "); } else if (eyeLidState) { Eyelid.write(eyeLidClose,255,false); eyeLidState=false; Serial.println("EyeLid is Closed "); } startTimeL=millis(); randomEyelid= random(1,4)*1000; } //Servo EyeBall stopTimeB=millis()-startTimeB; if((((stopTimeB-randomEyeBall)<500)&&((stopTimeB-randomEyeBall)>0))||(((randomEyeBall-stopTimeB)>500)&&((randomEyeBall-stopTimeB)>0))||(stopTimeB==randomEyeBall)) { EBall=random(30,60); Eyeball.write(EBall,255,false); eyeLidState=true; Serial.print("Eyeball at "); Serial.println(EBall); startTimeB=millis(); randomEyeBall= (random(1,4)*1000)/2; } }

Step 6: Challenges, Tips and Prospects

Here are challenges

sketch needed to provide random motion for all servos but speed is critical too fast or too slow will make robot head erratic.

Using the function delay is not recommended when you make robots simply because you are trying to multitask. That was the biggest challenge.

The eyeballs and eyelids. it is needed to make research of how natural eye movement looks like because if eyes move left and right too fast or slow it looks scary. The eyelids are another story..if they open and close too fast they will not be noticeable. if they move too slow robot Chris will look sleepy. this one was easy after making some research about human eye movement speeds. I prefer to use a small solenoid for the eyelids but it was not easy to find at the time.

The jaw movement still needs to be developed because mapping audio signal has problems and we need to pick the peaks of audio and perhaps a solenoid will deliver a more nice results. There are modules ready online that move the jaw nicely, but you better rely on yourself and study how it works and make it better. Once we understand how it works we save and simplify

have a look at this

Audio to motion

I found a first attempt of sketch but did not find the final one which is shown in the video.,I will look for it in my old desktop to share it.

Apart from the aesthetic enhancements, a major prospect to enhance is by adding a speech recognition shield and then calling a random audio phrase from JQ6500 mp3 module that relates to what was received by the speech module. This will make it as if robot understands and builds rapport with you.

Robots Contest

Participated in the
Robots Contest

Be the First to Share


    • Microcontroller Contest

      Microcontroller Contest
    • Fandom Contest

      Fandom Contest
    • Halloween Contest

      Halloween Contest



    Reply 2 years ago

    Thanks indeed