void setup() {
DDRD=B11111100;
DDRB=B11111111;
PORTD=B00000001; //pinMode(0, INPUT_PULLUP);
}
void loop() {
//Tugas 3. Program 3 Persimpangan
{
PORTB=B00001100; PORTD=B00100100; //1
delay(5000);
PORTB=B00010010; PORTD=B01000100; //2
delay(1000);
PORTB=B00100001; PORTD=B10000100; //3
delay(5000);
PORTB=B00010001; PORTD=B01001000; //4
delay(1000);
PORTB=B00001001; PORTD=B00110000; //5
delay(5000);
PORTB=B00001010; PORTD=B00101000; //6
delay(1000);
}
}