Advertisement
makispaiktis

Arduino - Servo Example

Apr 16th, 2019 (edited)
270
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <Servo.h>
  2.  
  3. Servo myservo;
  4.  
  5. void setup() {
  6.   // put your setup code here, to run once:
  7.   myservo.attach(3);
  8. }
  9.  
  10. void loop() {
  11.   // put your main code here, to run repeatedly:
  12.   myservo.write(0);
  13.   delay(1500);
  14.   myservo.write(90);
  15.   delay(1500);
  16.  
  17. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement