Skip to content

Commit 5702dfc

Browse files
authored
Update U2Vydm8gQ29tcG9uZW50.h
Signed-off-by: Adrian <[email protected]>
1 parent 6e0a6a4 commit 5702dfc

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

src/U2Vydm8gQ29tcG9uZW50.h

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
#include <Servo.h>
2-
#include <stdio.h>
3-
#include <string.h>
42

53
typedef struct setup2 {
64
int servo;
@@ -9,9 +7,18 @@ typedef struct setup2 {
97

108
Servo servo;
119
ServoConfig pin1;
10+
ServoConfig pin2;
11+
ServoConfig pin3;
12+
ServoConfig pin4;
13+
ServoConfig pin5;
14+
ServoConfig pin6;
15+
ServoConfig pin7;
16+
ServoConfig pin8;
17+
ServoConfig pin9;
18+
ServoConfig pin10;
1219

13-
void moveServo(int angle) {
14-
pin1.angle = angle;
15-
servo.attach(pin1.servo);
20+
void moveServo(int i, int angle) {
21+
pin[i].angle = angle;
22+
servo.attach(pin[i].servo);
1623
servo.write(angle);
1724
}

0 commit comments

Comments
 (0)