This is an old revision of the document!
Timer Input
Programming Example
The code snippet bellow shows how to configure and use a GPIO pin as input.
#include "reg_stm32f4xx.h" /* TO-DODELI DOO. */
Configuration Registers
CR1
SMCR
Slave mode control register
ETR | 0 | ETR is not inverted, active at high level or rising edge |
1 | ETR is inverted, active at low level or falling edge | |
ECE | 0 | External clock mode 2 disabled |
1 | External clock mode 2 enabled. Clock enabled by any active edge on ETRF |