Firmware Update

The board contains two MCUs, each with an independent SWD programming connector. Program the two MCUs separately. If both chips use the same function, the same firmware file can be programmed to both.

Important: do not perform a full-chip erase. A full-chip erase deletes factory identity data, saved communication parameters, and offline batches. A normal update only requires programming and verifying the firmware.

Important: do not use a third-party SDK. SANPO products use genuine ST STM32 chips. Use the ST official tools and SDK in STM32CubeIDE for development. Do not use third-party vendor projects, especially Keil SDK projects that have not been certified by the original vendor. Programming a non-ST SDK may lock the chip, and SANPO reserves the right to refuse repair.

Firmware Download

Download the latest STM32G0B1 V83 release package. After extracting it, program spine_v8_v83_g0b_release.bin and verify its integrity with the SHA-256 file in the same directory.

Preparation

  • Download and install STM32CubeProgrammer.

  • Prepare an ST-LINK programmer and SWD cable.

  • Connect the SANPO SPINE communication board to USB power.

ST-LINK SWD wiring

Important Warning

Do not perform a full-chip erase. High Flash addresses may store device identity, authorization information, communication settings, and offline batch tasks. A full-chip erase deletes this data, and a normal firmware image cannot restore it automatically.

Download the firmware starting at 0x08000000. Use Download & Verify or Program & Verify. Do not select a full-chip erase.

Update with STM32CubeProgrammer

Prepare an ST-LINK, STM32CubeProgrammer, and the selected release firmware, then follow these steps:

  1. Connect ST-LINK to the SWD connector of the first MCU.

  2. Select ST-LINK in STM32CubeProgrammer and connect.

  3. Select the *_release.bin file in the release directory and set the download address to 0x08000000.

  4. Download and verify directly; do not erase the full chip first.

  5. Disconnect ST-LINK, connect it to the second MCU’s SWD connector, and repeat steps 2-4.

  6. Power-cycle the board.

STM32CubeProgrammer firmware update

Check the Board After Updating

Open the USB management serial port for each MCU. Windows normally displays it as SANPO Studio Management Port. Send:

AT+VER

Use CRLF as the line ending. The response should match the firmware just programmed, for example:

V83

Then query the communication settings:

AT+SETFDCAN?
AT+SETRS485?
AT+SPIMODE?
AT+RS485RAWCH?
AT+BATAUTO?

An update normally preserves existing communication settings, so the values may differ from the factory defaults. If you need to restore communication defaults, send AT+CFGERASE only after confirming that it is appropriate for the installed firmware.

Factory Communication Defaults

Item

Default

Classic CAN / CAN FD arbitration phase

1 Mbit/s

CAN FD data phase

5 Mbit/s, BRS enabled

RS485

4 Mbit/s, 1 stop bit, no parity, 8 data bits

SPI

SHORT, 23 bytes per transfer

When the SPI host needs CAN FD, send:

AT+SPIMODE=LONG