Testing the shift register. Flashing status led and shift register pins 0, 1 and 7 in sequence.

This commit is contained in:
Michael Mandl 2017-02-19 22:05:13 +01:00
parent bee4bf5c46
commit d863aaad39

View file

@ -20,17 +20,27 @@ void flashStatusLed()
int main()
{
setupStatusLed();
LcdShiftReg lcdShiftReg;
while (true)
{
flashStatusLed();
_delay_ms(400);
lcdShiftReg.set(1);
_delay_ms(100);
lcdShiftReg.set(0);
_delay_ms(400);
lcdShiftReg.set(1 << 1);
_delay_ms(100);
lcdShiftReg.set(0);
_delay_ms(400);
lcdShiftReg.set(1 << 7);
_delay_ms(100);
lcdShiftReg.set(0);
_delay_ms(400);
}
}