Self-Balancing Robot
User Guide
37
www.terasic.com
July 12, 2018
followed by 16-bit Client Code, 8-bit Key Code and 8-bit Inversed Key Code, which is the reverse
value of the Key Code, the robot IR receiver can use the Inversed Key Code to verify the Key Code.
The logic is judged through different time lengths, 560us carrier frequency plus 1690us 0 signal
represents the transmission of logic 1, 560us carrier frequency plus 560us 0 signal represents logic
0.
Figure 1- 25 NEC protocol leader & length variable block
The IR receiver on the balanced car can decode the carrier frequency of 38 kHz and reverse the
received signal. Therefore, it should be noted that the signal processed in the FPGA will be opposite
to that of the transmitter, as shown in
Figure 1- 26
.
Figure 1- 26 The signal received by IR receiver
◼
◼
S
S
e
e
l
l
f
f
-
-
B
B
a
a
l
l
a
a
n
n
c
c
i
i
n
n
g
g
R
R
o
o
b
b
o
o
t
t
m
m
o
o
t
t
i
i
o
o
n
n
k
k
e
e
y
y
d
d
e
e
f
f
i
i
n
n
i
i
t
t
i
i
o
o
n
n
a
a
n
n
d
d
K
K
e
e
y
y
C
C
o
o
d
d
e
e
See
Figure 1- 27
for IR controller’s function and key and its corresponding Inversed Key Code,
Key Code and Custom Code are shown in
Table 1-7.