Tagged: stm32f4xx

HAL Library 33- DMA extension for SPI on STM32Fxxx 21

HAL Library 33- DMA extension for SPI on STM32Fxxx

SPI DMA library allows you to send and receive data via SPI in non-blocking mode. It can be use for TX only, RX only or both (transmissing mode). This library is extension for my SPI library. It requires SPI library as basic to make this to work. Library Read more about HAL libraries Features SPI extension for non-blocking TX, RX or both modes Supports all SPI peripherals on STM32F4 and STM32F7 device Supports interrupt processing Allows you to start DMA transmissing and wait till done This is...

HAL Library 31- DMA for STM32Fxxx devices 1

HAL Library 31- DMA for STM32Fxxx devices

It’s been a while since last published library. From that time, I got some requests about making DMA library for HAL and later using this library with USART, SPI, ADC and more libraries. So I’ve made a first step in DMA libraries list. Basic “root” library for DMA process has been created for managing things with DMA streams for STM32F4 and STM32F7 devices. What else it supports, you should check below. Library Read more about HAL libraries Features Root library...

CPU load monitor for STM32F4xx 0

CPU load monitor for STM32F4xx

I’ve been searching for a simple CPU load monitor on STM32F4xx device. Today, I’ve managed to get one very, very primitive CPU load monitor for these devices. Check library here. STM32F4xx have built-in DWT (Data Watchpoint and Trace unit) which has several timers there. 2 of them are cycle counter and sleep counter. The first counts number of CPU cycles and the second counts number of cycles where CPU was sleeping. It would be very easy to get CPU load,...

Library 54- General library for STM32F4xx devices 5

Library 54- General library for STM32F4xx devices

For 54th lib I decided to make it’s name to be “General”. With this name I mean that in this library, a lot of different stuff, maybe unrelated between, but very useful things will be implemented. It allows you to make software reset, get reset source, disable or enable global interrupts (NVIC) and more. It will be updated frequently but for now it’s just a start to use it in your projects. Library Features Support for software reset with callback...

Project 03- STM32F4xx PID controller 32

Project 03- STM32F4xx PID controller

CMSIS files from ARM provides ARM Math functions. There are also PID controller functions in different formats for f32, q31 and q7. This tutorial/project will talk about how to implement PID controller on STM32F4xx using PID functions from ARM. PID Controller Fast about PID controller. PID stands for Proportional-Integral-Derivative controller. This is a control loop feedback mechanism widely used in industrial control systems. It calculates the error between measured value and the desired setpoint value. According to the error, it...

Servo motor 69

Library 42- Control RC servo with STM32F4

Library 42 allows you to simple connect and interface RC servo motors with STM32F4. They are small, cheap motors, commonly used for RC (Radio Control), small scale robotics and more. Servos are really simple to interface. They expect 50Hz signal on the input. According to the pulse length (duty cycle) they rotate between 0 and 180 degrees. If signal has 1ms pulse length, motor rotation will be 0 degrees and if signal has 2ms length, then it will have 180degrees rotation. Any pulse length...