Learn STM32 input capture using HAL. Use HAL_TIM_IC_CaptureCallback to measure signal frequency and pulse width with timers and interrupts.
Microcontroller Tutorials with Code from Scratch
Learn STM32, ESP32, and embedded systems by writing code from scratch using datasheets and reference manuals. All tutorials are tested on actual hardware to help you build reliable, real-world projects with full control and understanding.
What’s New in STM32
HCSR04 Ultrasonic sensor and STM32
This tutorial will cover how to interface the HCSR04 Ultrasonic distance sensor with STM32…
How to use 4×4 keypad with STM32
This tutorial will cover how to interface a 4×4 keypad with STM32. We will use the blocking mode to read the key data and then…
How to interface DS18B20 with STM32
Interface DS18B20 Temperature sensor with STM32 using the microseconds delay generated using the Timer. The sensor uses one wire…
STM32 RTC Example | Real-Time Clock Alarm, VBAT, LCD Display (HAL + CubeMX)
STM32 RTC tutorial with alarm, VBAT backup, and LCD display. Learn real-time clock config using HAL and CubeMX with example code.
STM32 SPI Communication Example – HAL Read/Write with ADXL345
Learn STM32 SPI with HAL. Configure SPI in CubeMX and perform read/write with ADXL345 sensor using HAL_SPI_Transmit and HAL_SPI_Receive.