STM32 Input Capture Mode.

STM32 Input Capture Mode.
STM32

Capture mode is a special timer mode that works like this: when the logic level on a certain microcontroller pin changes, the value of the counter register is written to another register, called the capture register. What is it for? This mode lets you measure the pulse width or period of a signal. The STM32 capture mode has some features:...

STM32 Debugging over SWD.

STM32 Debugging over SWD.
STM32

STM32 has a very convenient interface for debugging and flashing the MCU: Serial Wire Debug, SWD for short. Its convenience is that debugging requires connecting only two data pins plus two power pins. The wiring diagram looks like this. Once the pins are connected, you need to enable SWD debugging in the development environment; in KEIL this is done as follows...