Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#include "Servo.h"
Servo m;
int SVRpin=A1;
void setup() {
m.attach(9);
}
void loop() {
int r = analogRead(SVRpin);
int v = map(r, 0, 1023, 20, 160);
m.write(v);
delay(100);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.