Skip to content

Latest commit

 

History

History

README.md

Firmware

MCU Language Build

C firmware for the STM32F103. Samples three potentiometers (PA0-PA2) with ADC + DMA, filters them with a low-pass filter and deadband, and reports changes over USB CDC. Generated with STM32CubeMX; application logic is in Core/Src/main.c.

Protocol

One line per update, raw 12-bit ADC values (0-4095):

P0=2048;P1=4095;P2=0

The full state is resent whenever the host opens the port.

Build

Requires arm-none-eabi-gcc, CMake and Ninja.

cmake --preset Release
cmake --build --preset Release

Flash

Over SWD with an ST-Link:

openocd -f openocd/bluepill-stlink.cfg -c "program build/Release/firmware.elf verify reset exit"