This application note provides implementation solutions for In-Application Programming (IAP) using the STM32F407/STM32F417 Ethernet communications interface. Two possible solutions are provided on top of the LwIP TCP/IP stack: TFTP and HTTP.
This document provides implementation solutions for In-Application Programming (IAP) on the STM32F407/STM32F417 microcontroller family. It details how to upgrade firmware in the field using the MCU's Ethernet communications interface via two methods: TFTP and HTTP.
The note explains that both solutions run on top of the LwIP TCP/IP stack (v1.3.2). The TFTP method uses a client/server architecture over UDP, while the HTTP method utilizes HTML Forms for file uploads over TCP. It covers the theory of operation, specific implementation steps for each protocol, and software usage instructions.
| Supported Microcontrollers | STM32F407/STM32F417 |
|---|---|
| LwIP Stack Version | v1.3.2 |
| TFTP Data Block Size | 512 bytes |
The IAP code allows the microcontroller to be put into a mode where it executes firmware upgrade instructions instead of normal application code.
In this implementation, the data block size is fixed to 512 bytes.
The application note provides solutions using TFTP and HTTP on top of the LwIP TCP/IP stack.
The server erases the total user Flash area when a write request is received.