Hardware Abstraction Layer for FreeRTOS
|
Macros | |
#define | MUX_CTL_OPEN BIT(0) |
#define | MUX_CTL_PULL_DOWN BIT(1) |
#define | MUX_CTL_PULL_UP BIT(2) |
#define | MUX_CTL_SCHMITT BIT(3) |
#define | MUX_CTL_MODE(x) (x << 8) |
Functions | |
struct mux * | mux_init () |
int32_t | mux_deinit (struct mux *mux) |
int32_t | mux_pinctl (struct mux *mux, uint32_t pin, uint32_t ctl, uint32_t extra) |
This is Mux Subsytem
#define MUX_CTL_MODE | ( | x | ) | (x << 8) |
Configure mode of pin
#define MUX_CTL_OPEN BIT(0) |
Configure pin without pull down or pull down
#define MUX_CTL_PULL_DOWN BIT(1) |
Configure pin with pull down
#define MUX_CTL_PULL_UP BIT(2) |
Configure pin with pull up
#define MUX_CTL_SCHMITT BIT(3) |
Configure pin with Schmitt Trigger
int32_t mux_deinit | ( | struct mux * | mux | ) |
Deinit Mux Subsystem
mux | Mux handle |
struct mux* mux_init | ( | ) |
Init Mux Subsystem
int32_t mux_pinctl | ( | struct mux * | mux, |
uint32_t | pin, | ||
uint32_t | ctl, | ||
uint32_t | extra | ||
) |
Configure pin
mux | Mux handle |
pin | Pin Number |
ctl | Config Pin can be: MUX_CTL_OPEN or MUX_CTL_PULL_DOWN or MUX_CTL_PULL_UP and MUX_CTL_SCHMITT and MUX_CTL_MODE Options can mixed with Or Operator: Example: (MUX_CTL_PULL_DOWN | MUX_CTL_SCHMITT | MUX_CTL_MODE(1)) |
extra | Extra config for mach specific settings |