The EZ-KIT Lite provides four push buttons and sixteen LEDs for general-purpose IO.
Sixteen LEDs, labeled LED5 through LED20, are controlled by the processor’s programmable flags PF32 through PF47 (equivalent to PPI0_D15-8 and PPI1_D15-8). These LEDs are accessed though the FLAG 2 registers. First, the direction must be configured to output by setting the bits of the FIO2_DIR register to 1. Then the value of the LEDs are modified using one of the FIO2_FLAG_D, FIO2_FLAG_C, FIO2_FLAG_S, or FIO2_FLAG_T registers.
The four general-purpose push buttons are labeled SW6 through SW9. The buttons connect to the programmable flags PF8-5. A status of each individual button can be read through the FIO0_FLAG_D register. A switch is being pressed-on when the corresponding bit of the register reads 1. When the switch is release, the bit reads 0. A connection between the push button and PF input is established through the SW4 DIP switch. For information on how to disconnect the switch from the programmable and use it for another objective, see “Push Button Enable Switch (SW4)”.
An example program is included in the EZ-KIT installation directory to demonstrate the functionality of the LEDs and push buttons.