Defines | |
#define | NUM_ROWS 8 |
Functions | |
s32 | BLM_CHEAPO_Init (u32 mode) |
s32 | BLM_CHEAPO_PrepareCol (void) |
s32 | BLM_CHEAPO_GetRow (void) |
s32 | BLM_CHEAPO_ButtonHandler (void *_notify_hook) |
s32 | BLM_CHEAPO_DebounceSet (u8 delay) |
s32 | BLM_CHEAPO_DebounceGet (void) |
s32 | BLM_CHEAPO_DOUT_PinSet (u32 pin, u32 value) |
s32 | BLM_CHEAPO_DOUT_PinGet (u32 pin) |
s32 | BLM_CHEAPO_DOUT_SRSet (u32 row, u8 value) |
u8 | BLM_CHEAPO_DOUT_SRGet (u32 row) |
BLM_CHEAPO Driver
#define NUM_ROWS 8 |
s32 BLM_CHEAPO_ButtonHandler | ( | void * | _notify_hook | ) |
This function should be called from a task to check for button changes periodically. Events (change from 0->1 or from 1->0) will be notified via the given callback function <notify_hook> with following parameters: <notifcation-hook>(s32 pin, s32 value)
s32 BLM_CHEAPO_DebounceGet | ( | void | ) |
Returns the debounce delay
Sets the debounce delay
[in] | delay | between 0..255 update cycles (usually mS) |
Returns LED status
[in] | pin | the pin number |
Sets LED to 0 or Vss
[in] | pin | the pin number |
[in] | value | the pin value |
Returns content of red or green "virtual" shift register
[in] | colour | the colour selection (0/1/2) |
[in] | sr | the shift register number |
Sets 8 LEDs of a row at once
[in] | sr | the row number |
[in] | value | state of 8 LEDs |
s32 BLM_CHEAPO_GetRow | ( | void | ) |
This function gets the button values of the selected row. It should be called from the APP_SRIO_ServiceFinish() hook
Initializes the BLM_CHEAPO driver Should be called from Init() during startup
[in] | mode | currently only mode 0 supported |
s32 BLM_CHEAPO_PrepareCol | ( | void | ) |
This function services the row selection lines at J15 and the LED output lines at J5A/B It should be called from the APP_SRIO_ServicePrepare()