Measurement Applications
Encoder position measurement [STM32 Nucleo]

The STM32 timer has a function to count up and down using encoder 2-phase output pulses as input. This section explains how to use this function to measure the amount of motor rotation from the reference position by up-down counting the pulses from the rotary encoder. Purpose: To measure the amount of rotational position by […]

Read more
Measurement Applications
Encoder speed measurement [STM32 Nucleo]

The STM32 timer has the ability to measure external pulses. Encoders are often used as sensors to detect the position and speed of actuators such as robots, etc. This section introduces a method to measure pulses that vary with rotation speed from encoders. Purpose: To count encoder pulses pulled up and input to CH1 of […]

Read more
RTOS Applications
Queue-based application [STM32 and FreeRTOS].

This application combines a task and a queue. This program is not practical, but it is a sample program for learning to understand the concept of queues in an easy-to-understand way.

Read more
RTOS Applications
Switching between multiple tasks, Part 2 [STM32 and FreeRTOS]

This is a sample program that combines task switching and USART communication, and manages task execution and suspension based on whether or not the command code given externally matches. Colum The '@' at the end of the command is to recognize the end of the input string. Instead of '@', an enter key (CR) input […]

Read more
RTOS Applications
Switching between multiple tasks, Part 1 [STM32 and FreeRTOS]

This is a sample program that switches between two tasks with an external switch. A dedicated task is provided to manage the switching.

Read more
RTOS Applications
Multitasking by registering multiple tasks [STM32 and FreeRTOS]

This is a sample program to execute two registered tasks simultaneously. Using RTOS, it is easy to execute completely different processes at the same time. As shown in the sample program, the RTOS can be easily executed with a simple description.

Read more
Serial communication SPI Applications
SPI communication application[SPI of STM32]

Application program to read and write to SPI specification EEPROM. Details of the peripherals are explained in Serial Communication SPI.  Program Description 

Read more
Serial communication I2C Applications
I2C communication application [I2C of STM32]

This application program reads and writes to the I2C specification type EEPROM of STM32 MCU. Details of the peripherals are explained in Serial Communication I2C.  Program Description 

Read more
ADC Applications
Multi-channel continuous ADC (DMA) application [ADC of STM32]

This is a practical application that automatically converts multiple channels of analog signals in succession on an STM32 MCU and retrieves them into memory. Please understand it completely and make use of it by all means.  To convert the analog conversion values of two channels to memory by DMA:  Prepare variables (memory) to store AD […]

Read more
ADC Applications
Continuous ADC application with completion interrupt [ADC of STM32]

This program is an introduction to the combination of AD conversion and interrupts; interrupts are supposed to be generated each time AD conversion is completed, and as it is, the frequency of interrupts is too high to be practical, but please understand interrupts as a learning tool. Execution Example of Interrupt Status if(ADC_GetITStatus(ADC1, ADC_IT_EOC) != […]

Read more