Monthly Archive: May 2015

FFT result of matlab generated signal 58

Library 62- Fast Fourier Transform (FFT) for STM32F4xx

HereĀ is an example of Fast Fourier Transform on STM32F4xx devices. Today, I was looking something on ARM DSP documentation and I saw that some functions for FFT used in my example are deprecated and will be removed in future. That was the main reason I decided to make a library for FFT on STM32F4xx. To use this library, some third-party libraries are also required. All these required files can be found in STM32F4xx Standard peripheral drivers and DSP instructions provided...

SSD1306 OLED I2C LCD with STM32F4 47

Library 61- SSD1306 OLED I2C LCD for STM32F4xx

Yeah, I got it too. These little, small and with nice contrast devices are really great. I2C communication from my module isn’t really powerful because of slow I2C, even at 400kHz. To update full LCD, there are 1024 bytes of data to be transfered. And this can really take a while. But anyway, for having this LCD just to showing small updates and notifications for users in your project, I2C is still nice. Probably I should make it using I2C...

Library 60- CPU load monitor for STM32F4xx devices 3

Library 60- CPU load monitor for STM32F4xx devices

Yesterday, I’ve made a post about monitoring CPU load depending on CPU work and it’s sleep time using DWT counter. This post can be found here. This post is now a library, set together from post about CPU load. Library Features Measures CPU load. Load depends between sleep time and work time of CPU CPU load is updated for every System core clock cycles. In other words, that is each 1 second DWT counter used for measurements Sleep mode which...

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 59- Change PLL settings while STM32F4xx is running 4

Library 59- Change PLL settings while STM32F4xx is running

I’ve been already talking about topic, how to properly set clock speed for your device with PLL settings. This article could be found here and it is definetelly worth of readiny, especially for beginners. Today, it was very rainy and bad day, so I was thinking about a library that could dynamically change PLL settings. This can be used to change current consumption of your device if there is no need for very high speed clock for some time. Changing...

Library 58- Dynamic strings on STM32F4xx 0

Library 58- Dynamic strings on STM32F4xx

Have you ever been in position where you need to store some string informations just for a small amount of time? Did you reserve ram memory before you worked with strings? If you did it like that, than this library might be a solution for you. This library was designed directly for a purpose where you need to store your information for a few time. For example, getting some string informations from your sensor, USART, etc. It uses malloc and...