When DIP switch #8 is high and #1 is low, turn on all the even numbered LEDs and let them stay on even after the switch #8 is changed to low.
When DIP switch #1 is high and #8 is low, turn on all the odd numbered LEDs and let them stay on even after the switch #1 is changed to low.
When both DIP switches #8 and #1 are high, turn on all LEDS. Afterwards, if one of the two is changed to low, turn off the corresponding even or odd LEDs.
Once LEDS are on, the only way to turn them off is to make the PA0 pin HIGH. LEDs will continue to be off as long as PA0 pin is HIGH. LEDs will be on/off according to the switches when PA0 pin becomes low again.
Your program must monitor PA0 and DIP switches continuously until a Reset.
0 rating(0 Reviews)