Let's Make Robots!


I tried to write a code but the servo would not stay so

Please can someone write a c++ code for arduio for me

What I would like is to simply to move a servo say:   ( 90’) And stay at 90


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

thanks so much!

your a big help!

#include <Servo.h> 

Servo S;  

 void setup() 

 S.attach(9);  // attaches the servo on pin 9 to the servo object 

S.write(90);                  // sets the servo position according to the scaled value 


void loop()   { }