Tagged: i2C

MPU-6050 6-axes gyroscope and accelerometer 1

HAL Library 30- MPU6050 for STM32Fxxx

After MPU6050 library for STM32F4xx series only based on STM32F4xx Standard peripheral drivers, I’ve redesign this library for HAL support over all STM32 series. It has some more features then my first library. It can now read data from MPU6050 (obvious), set interrupts for data ready and motion detection, read interrupts status, set custom data rate for data ready interrupt and set new gyro and accelerometer sensitivities on the fly. More about lib is describe below and on HAL API site. Library...

HAL Library 16- I2C for STM32Fxxx devices 14

HAL Library 16- I2C for STM32Fxxx devices

Here it is. After some email for I2C library for HAL, I’ve made it. I ported my old for F4 to HAL based libraries for F0/F4/F7 series. I added method to read single byte, multi bytes, write single byte, write multi bytes, write/read single byte from/to register which has 16-bit address size. Library Read more about new HAL libraries Features Supports up to 4 I2C peripherals Supports different pinouts selectable on initialization Supports custom pin combinations Supports multiple read/write modes...

All STM32 HAL libraries 106

All STM32 HAL libraries

In this section, I will write all libraries based on HAL drivers from ST. If you see this first time, make sure you read this post first about how structure of my libs looks like! License All my softwares are published under MIT license. This means that you are allow to modify, share and use my source and other stuff in personal or commercial use. If you modify source code, it has to stay under GNU GPL v3 license too. I...

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...

All STM32F4 libraries 128

All STM32F4 libraries

Because there is a lot of libraries I have done, I will make a table with all of my libraries at one place. When new library will be created, it will be posted here. These libraries work on both Discovery boards, if not, it will be specified. Actually, libraries should work on STM32F4xx series of microcontrollers if they have peripherals that are need for library. All STM32F4xx MCUs don’t have everything inside. 🙂 Libraries are tested on my 4 STM32F4...

DS1307 I2C RTC Clock on STM32F4 33

Library 15- DS1307 Real Time Clock for STM32F4

In my 15th library, I will show you, how to operate with DS1307 Real Time Clock I2C module from maxim integrated. The DS1307 serial real-time clock (RTC) is a lowpower, full binary-coded decimal (BCD) clock/calendar plus 56 bytes f NV SRAM. Address and data are transferred serially through an I2C, bidirectional bus. The clock/calendar provides seconds, minutes, hours, day, date, month, and year information. The end of the month date is automatically adjusted for months with fewer than 31 days, including corrections for leap year. The clock operates in...