Beside that, I still continue complete my robot....
After done the soldering, I try the robot using the ARDUINO uno to see my robot can walk or not...
I use the example coding that i have found on my research..
#include <Servo.h>
Servo frontservo,backservo;
char forward[] =
{60,100,100,100,100,60,60,60};
void setup()
{
frontservo.attach(9);
backservo.attach(10);
}
void loop()
{
for(int n=0;n<4;n++)
{
frontservo.write(forward[2*n]);
backservo.write(forward[(2*n)+1]);
delay(300);
}
}
This is the video that I have done using the ARDUINO uno
No comments:
Post a Comment