Initial Commit

This commit is contained in:
KillerBossOriginal 2024-12-03 16:31:00 +01:00
commit 5cb4ca8b7f

25
Promano.ino Normal file
View file

@ -0,0 +1,25 @@
#include <Servo.h>
Servo myServo;
int const potPin = A0;
int potVal;
int angle;
void setup() {
myServo.attach(8);
Serial.begin(9600);
}
void loop() {
potVal = analogRead(potPin);
angle = map(potVal, 0, 1023, 0, 179);
Serial.print("Potval: ");
Serial.print(potVal);
Serial.print(" Angle: ");
Serial.print(angle);
myServo.write(angle);
delay(15);
}