Make you ideal fun
36
distance
=
(
collectDistance
[
0
]+
collectDistance
[
1
]+
collectDistance
[
2
]+
collectDista
nce
[
3
]+
collectDistance
[
4
])/
5
;
delay
(
20
);
}
// walk forward
void
moveForward
()
{
// loop for the servo angels to smoothen the steps
for
(
f
=
0
;
f
<
39
;
f
++){
frontRightUp
++;
backLeftForward
--;
frontServo
.
write
(
frontRightUp
);
rearServo
.
write
(
backLeftForward
);
delay
(
10
);
}
// loop for the servo angels to smoothen the steps
for
(
r
=
0
;
r
<
39
;
r
++){
frontRightUp
--;
backLeftForward
++;
frontServo
.
write
(
frontRightUp
);
rearServo
.
write
(
backLeftForward
);
delay
(
10
);
}
}
// walk backwards to the left
void
moveBackRight
()
{
frontServo
.
write
(
frontRightUp
);
rearServo
.
write
(
backRightForward
-
6
);
delay
(
110
);
frontServo
.
write
(
centerPos
);
rearServo
.
write
(
centerPos
-
6
);
Содержание Insect-Robot
Страница 1: ...Make you ideal fun 1 Insect Robot Instruction Manual...
Страница 9: ...Make you ideal fun 9 Figure 11 Bend the cutted paper into the shape as figure 12 Figure 12...
Страница 11: ...Make you ideal fun 11 Install the Nano board on the servo as figure 15 but don t fix Figure 15...
Страница 27: ...Make you ideal fun 27 Figure 43...
Страница 28: ...Make you ideal fun 28 After adjusting the angle you can completely fix the forefoot Figure 44...