Usage Dependencies pip install pyserial PlatformIO ( pio ) must be in PATH for build/flash functionality. Running Auto-detect STM32 device (VID 0x0483 ): python3 serial_commander.py Specify port and baud rate manually: python3 serial_commander.py --port /dev/ttyACM0 --baud 115200 If multiple STM32 devices are connected, the script presents a numbered selection menu before opening the TUI. Default Parameter Values Parameter Default erpm 2000 accel 1000 time_ms 5000 pio target upload pio env can_board Typical Workflow Connect STM32 CAN board via USB. Run python3 serial_commander.py — port is detected automatically. Adjust erpm , accel , time_ms with e / a / t as needed. Send speed ( 1 ) or profile ( 3 ) and observe STM32 response in INCOMING. Use b to build/flash directly if firmware changes are needed. Press q to quit — serial port closes cleanly.