// Connect 8 leds to port A. connect 8 push button switches to port B
// Press second switch first glow first LED, delay,
// 2nd led, delay, 5th led, delay, sixth led
#include "ecen.h"
void setup(){
init_portA();
init_portB();
}
void loop(){
if(inputB() == 0x04){
outputA(0x02);
delay_ms(1000);
outputA(0x04);
delay_ms(1000);
outputA(0x20);
delay_ms(1000);
outputA(0x40);
delay_ms(1000);
}
else{
outputA(0x00);
}
}