Update or Re-Flash via ST-Link
pdating via the ST-Link provides a reliable and easy way to flash any STM based MCU’s especially if you have issues entering DFU mode, the only time where it becomes problematic is when older/fake ST-Links are used, please see the notes and ways of identifying below.
Requirements
Section titled “Requirements”- ST-Link v2 (Below is a table of the most common ST-Link v2s. There are obviously more available on the market.
| STLink | ST-Link V2 Mini (Fake MCU) | ST-Link V2 Mini | ST-Link V2 |
|---|---|---|---|
| Image | ![]() |
![]() |
![]() |
| Note | Uses fake STM Chip, Pin order is different and isnt always recognised via STM Cube Programmer. | Occasional Issues, depending on age / firmware. | Most Reliable |
| STMCubeProg Compatible | ❌ May not work |
✅ | ✅1 |
- STM Cube Programmer - (recommended version v2.15.0) - if using Windows or MacOS
- 4x DuPont M-M or M-F Cables
- Cartographer V3 Probe
https://www.st.com/en/development-tools/stm32cubeprog.html#st-get-software
Step 1 - Wire up your probe
Section titled “Step 1 - Wire up your probe”Connect the following pins based upon the different ST-Links.
| Hardware | Pinout | Connections (STLink - Probe) |
|---|---|---|
| ST-Link V2 | ![]() |
SWDIO - SWD |
| ST-Link V2 Mini (Fake Chip) | ![]() |
SWDIO - SWD |
| ST-Link V2 Mini | ![]() |
SWDIO - SWD |
Connect your probe to the STLink connectors to the left and the right of the JST connector.
Pinout on Cartgorapher V2 and V3
Connected on ST-Link V2
Connected to a ST-Link v2 Mini (with a Genuine STM Chip)
If using Windows follow the next steps, if you are using Linux (Pi) click here
Section titled “If using Windows follow the next steps, if you are using Linux (Pi) click here”Open STM32CubeProg

Select Open File and select the file you want to open. For this, I recommend flashing the FULL complete firmware files, which include both bootloader and Cartographer firmware.
Select the file you need
Step 3 - Check the Settings
Section titled “Step 3 - Check the Settings”Ensure that you are writing to the correct memory location
If your firmware is from the combined-firmware folder or starts with the words Katapult, ensure that the address is set to 0x08000000

Ensure that you have ST-LINK slelected on the right (this can default to DFU mode if you havnt used this before)

Now press Connect and the screen should indicate that the probe is Connected

Flash and Confirm Firmware
Section titled “Flash and Confirm Firmware”Press download to Download the firmware to your Cartographer

The output should look something like this


Press Disconnect and unplug the probe.
Flashing via Linux (Pi)
Section titled “Flashing via Linux (Pi)”- SSH into your 3D Printer using your client of choice
- Run the following command (this may take a little while)
sudo apt-get updatesudo apt-get upgradesudo apt-get -y install stlink-tools- Navigate to the folder where your firmware is stored, usually
cd ~/cartographer-klipper/firmware/v2-v3/combined-firmware- Check if the ST-Link has been detected using
lsusbif it is not visable, unplug and re-plug it back in.
Original lsusb not being able to see the ST-Link, second one able to see it.
- run the following command replacing firmware.bin and the memory address with the correct address for the firmware that you are using.
st-flash write firmware.bin 0x08000000For example to flash the Survey CAN firmware
st-flash write Full_Survey_Cartographer_CAN_1M_5_0_0.bin 0x08000000Upon completion, you should see something like this
Successful Flash
Reconnect your probe to your printer
Section titled “Reconnect your probe to your printer”Reconnect your probe to your 3D Printer, and it should work perfectly :)







