Advertisement
gersonfer

servo_nano

Sep 6th, 2019
392
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.34 KB | None | 0 0
  1. define   RSP       11              // right servo pin
  2. #define   LSP      12              // left  servo pin
  3.  
  4. #include  <Servo.h>
  5. Servo rightServo;
  6. Servo leftServo;
  7.  
  8. void setup() {
  9. rightServo.attach(RSP);
  10. leftServo.attach(LSP);
  11. }
  12.  
  13. void loop() {
  14. rightServo.writeMicroseconds(1320);   //1320
  15. leftServo.writeMicroseconds(1680);    //1680
  16.  
  17. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement