How elecskku/stm32 works
This repository demonstrates reliable BMP transfer between a PC and an STM32, with a W25Q32 SPI flash as persistent storage. The main workflow is to prepare a BMP, send it in CRC-protected chunks, store and verify it on the board, then read it back and compare the restored file. The README also documents ID, erase, verify, and visual-comparison capabilities. The firmware implementation files are absent from the tree: the firmware node is represented by its available API header, so its internal protocol behavior is based on README documentation.
Main entry points: flash_tool.py Python Transfer Tool · app.h UART App API · main_clean.cpp Windows Serial Client · w25q32.h W25Q32 Driver API
Components 10
PC Tools
- Python Transfer Tool
PC/flash_tool.py - Windows Serial Client
main_clean.cpp
STM32 Firmware
- UART App API
Inc/app.h - W25Q32 Driver API
Inc/w25q32.h
Flash Storage
- W25Q32 Flash
Other components
- Operator
- Input BMP
- Restored BMP
- UART Link
- SPI Link
Connections 14
- Operator → Python Transfer Tool: runs commands
PC/flash_tool.py - Operator → Windows Serial Client: runs client
main_clean.cpp - Input BMP → Python Transfer Tool: supplies BMP
PC/flash_tool.py - Python Transfer Tool → UART Link: sends protocol
README.md - Windows Serial Client → UART Link: sends protocol
main_clean.cpp - UART Link → UART App API: carries commands
README.md - UART App API → W25Q32 Driver API: uses flash operations
README.md - W25Q32 Driver API → SPI Link: controls flash
Inc/w25q32.h - SPI Link → W25Q32 Flash: reads and writes
README.md - UART App API → UART Link: returns data and status
README.md - Python Transfer Tool → Restored BMP: saves readback
PC/flash_tool.py - Operator → Python Transfer Tool: requests ID, erase, verify
PC/flash_tool.py - Python Transfer Tool → Input BMP: generates or converts BMP
PC/flash_tool.py - Python Transfer Tool → Restored BMP: compares images
PC/flash_tool.py