|
Digital Input/Output Reusable Driver v1.1
This project implements a GPIO reusable driver that can be adapted to various microcontrollers.
|
This module contains the implementation for the digital input/output peripheral configuration. More...
#include "dio_cfg.h"
Functions | |
| const DioConfig_t *const | DIO_configGet (void) |
| size_t | DIO_configSizeGet (void) |
Variables | |
| const DioConfig_t | DioConfig [] |
This module contains the implementation for the digital input/output peripheral configuration.
| const DioConfig_t *const DIO_configGet | ( | void | ) |
Description: This function is used to initialize the DIO based on the configuration table defined in dio_cfg module.
PRE-CONDITION: configuration table needs to be populated (sizeof > 0)
POST-CONDITION: A constant pointer to the first member of the
configuration table will be returned.
Example:
| size_t DIO_configSizeGet | ( | void | ) |
Description: This function is used to get the size of the configuration table.
PRE-CONDITION: configuration table needs to be populated (sizeof > 0)
POST-CONDITION: The size of the configuration table will be returned.
Example:
| const DioConfig_t DioConfig[] |
The following array contains the configuration data for each digital input/output peripheral channel (pin). Each row represent a single pin. Each column is representing a member of the DioConfig_t structure. This table is read in by Dio_Init, where each channel is then set up based on this table. The NUMBER_DIGITAL_PINS constant should be accorded with the number of rows.