Вы находитесь на странице: 1из 3

Atmel

START

Initialize R18,R17,R19
R18 as input (from push button 1 and 2)

Compare R18 and R17


R17=0b00000100

N
o

Yes
Compare R18 and R19

Out PORTD with


pin no.2 is HIGH

R19=0b00001000

Yes

Out PORTD with


pin no.3 is HIGH

Both Output to
Arduino

END

N
o

Arduino

START

Initialize pin, Input = Pin9, Pin10


Output = Pin3, Pin6

Read value from Input Pin9, Pin9 = Pin


no.2 atmel
LO
W

HIG
H
Output Pin3 is
HIGH

Read value from Input Pin10, Pin10 =


Pin no.3 atmel

Motor 1 start

HIG
H

Output Pin6 is
HIGH
Motor 2 start

END

LOW

Вам также может понравиться