HARMcksL: ARM HAL toolbox (yet STM32 oriented) 1.6
SMFSW collection of HAL hacks for STM32
Loading...
Searching...
No Matches
GPIO_in.c File Reference

GPIO input handling. More...

#include "sarmfsw.h"
#include "GPIO_in.h"
Include dependency graph for GPIO_in.c:

Functions

void GPIO_in_init (GPIO_in *const in, GPIO_TypeDef *const GPIOx, const uint16_t GPIO_Pin, const GPIO_PinState polarity, const uint16_t filter, void(*onSet)(const GPIO_in *const), void(*onReset)(const GPIO_in *const), const bool repeat)
 Initialize GPIO_in instance.
 

Detailed Description

GPIO input handling.

Author
SMFSW

Function Documentation

◆ GPIO_in_init()

void GPIO_in_init ( GPIO_in *const in,
GPIO_TypeDef *const GPIOx,
const uint16_t GPIO_Pin,
const GPIO_PinState polarity,
const uint16_t filter,
void(* onSet )(const GPIO_in *const),
void(* onReset )(const GPIO_in *const),
const bool repeat )

Initialize GPIO_in instance.

Parameters
[in,out]in- GPIO_in instance to initialize
[in]GPIOx- port to read from
[in]GPIO_Pin- pin to read from
[in]polarity- set to GPIO_PIN_RESET if active state is GND, GPIO_PIN_SET if Vdd
[in]filter- input filtering time
[in]onSet- Pointer to callback ON function
[in]onReset- Pointer to callback OFF function
[in]repeat- To repeat callback ON as long as input is set
Here is the call graph for this function: