This application note provides I2C firmware optimized examples based on polling, interrupts and DMA, covering the four I2C communication modes available in the STM32F10xxx, that is, slave transmitter, slave receiver, master transmitter and master receiver.
The document aims to provide firmware examples based on polling, interrupts, and Direct Memory Access (DMA) covering the four I2C communication modes available in the STM32F10xxx family: slave transmitter, slave receiver, master transmitter, and master receiver. It also offers recommendations for the correct use of the I2C peripheral.
The note is organized into three main parts. The first part describes I2C master programming examples using polling, DMA, and interrupts, including flowcharts. The second part covers I2C slave programming examples using DMA and interrupts. The third part provides an overview of the accompanying firmware content.
This document applies to the STM32F101xx, STM32F103xx, STM32F105/107xx, and STM32F100xx device lines.
BTF is recommended if the software cannot manage the EV7 sequence before the current byte transfer ends.