Updated Flashing (markdown)

Eric Helgeson 2021-06-18 21:28:38 -05:00
parent 7be0605e9d
commit 839b5af68a

@ -6,19 +6,33 @@ When flashing you have two options:
## Using STLink v2 (preferred)
### Setup STLinkV2
Be sure to buy the "Clone" STLink V2 programmer - the official one does not seem to work as well.
### Procedure (PlatformIO)
* Remove SD Card
* Make sure the STLinkV2 is up to date - [Latest Firmware](https://www.st.com/en/development-tools/stsw-link007.html)
* Connect pins `SWDIO(2)`, `GND(4)`, `SWCLK(6)`, and `3.3v(8)` from the programmer to the Blue Pill.
* NOTE: These are not the same as Serial ports.
* Run the [PlatformIO: Upload task](https://docs.platformio.org/en/latest/integration/ide/vscode.html#project-tasks).
### Procedure (STM32CubeProgrammer)
* Remove SD Card
* Open STM32CubeProgrammer
* Move the BOOT0 (furthest from the reset button) to 1
* Push the reset button on the BluePill
* Click Connect in STM32CubeProgrammer
* Select the .bin file and program.
* Move BOOT0 back to 0
* Push the reset button on the BluePill
* You should see the LED `PC_13` flashing indicating no SD Card detected.
### Procedure (PlatformIO)
* Remove SD Card
* Move the BOOT0 (furthest from the button switch) to 1
* Push the reset button on the BluePill
* Run the [PlatformIO: Upload task](https://docs.platformio.org/en/latest/integration/ide/vscode.html#project-tasks).
* Expected output:
```
Uploading .pio/build/genericSTM32F103C8/firmware.elf
@ -37,14 +51,11 @@ xPSR: 0x01000000 pc: 0x08000194 msp: 0x20000690
** Verify Started **
** Verified OK **. <-- Everything flashed OK
** Resetting Target **
in procedure 'program'
*** [upload] Error 1 <-- Note this error can be ignored
```
* Move BOOT0 back to 0
* Push the reset switch on the BluePill
* You should see the LED `PC_13` flashing indicating no SD Card detected.
* Insert SD Card, boot on your favorite Mac!
The following YouTube video demonstrates the steps of flashing & updating your BlueSCSI https://www.youtube.com/watch?v=bRLAOts_MTM
## Trouble Shooting