Document afio function

This commit is contained in:
Steins7 2023-05-13 15:48:07 +02:00
parent 245b9238e9
commit db5180d3e7
2 changed files with 11 additions and 1 deletions

View File

@ -19,6 +19,13 @@
//--functions-------------------------------------------------------------------
/**
* Maps the exti lines to gpio ports. The ExtiLine enum can be used as a
* mask to configure multiple lines at the same time. This function is used by
* the exti module to configure its line and calling it directly should should
* thus normaly not be needed. It could however still be usefull when wanting to
* change the port linked to an exti without reconfiguring it entirely
*/
void afio_map_exti(enum ExtiLine line_mask, enum GpioPort port);

View File

@ -71,7 +71,10 @@ typedef void (*ExtiCallback)(void);
* exti 1). When possible, it is recommanded to use the lowest id possible for
* better performance. The ExtiConfig enum can be used as mask. If no callback
* is specified, the interrupt won't be enabled, but an event will still be sent
* to wake the cpu up
* to wake the cpu up.
*
* Note: wich port is linked to a line can be changed atfer the fact using
* afio_map_exti()
*/
void exti_configure(enum ExtiLine line_mask, enum GpioPort port,
enum ExtiConfig config_mask, ExtiCallback callback);