Skip to content

Commit 5c718ae

Browse files
authored
Merge pull request vedderb#176 from supercrazysam/supercrazysam-readme-update-patch
Added a guide for (.bin) custom firmware build and upload using vesc tool
2 parents 3a071ce + 388482f commit 5c718ae

File tree

1 file changed

+36
-4
lines changed

1 file changed

+36
-4
lines changed

README.md

+36-4
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,6 @@ brew install openocd
120120
```
121121

122122
## Build
123-
124-
Build and flash the [bootloader](https://github.com/vedderb/bldc-bootloader) first
125-
126123
Clone and build the firmware
127124

128125
```bash
@@ -131,11 +128,46 @@ cd vesc_firmware
131128
make
132129
```
133130

134-
Flash it using an STLink SWD debugger
131+
132+
## Upload to VESC
133+
### Method 1 - Flash it using an STLink SWD debugger
134+
135+
Build and flash the [bootloader](https://github.com/vedderb/bldc-bootloader) first
135136

136137
```bash
137138
make upload
138139
```
140+
### Method 2 - Upload Firmware via VESC tool through USB
141+
142+
1. Clone and build the firmware in **.bin** format
143+
144+
Reminder : Remember to select your board in [**conf_general.h**]
145+
146+
```bash
147+
git clone https://github.com/vedderb/bldc.git vesc_firmware
148+
cd vesc_firmware
149+
#make build/your_firmware_name_here.bin
150+
make build/VESC_fw.bin
151+
```
152+
In VESC tool
153+
154+
2. Connect to the VESC
155+
3. Navigate to the Firmware tab on the left side menu
156+
4. Click on Custom file tab
157+
5. Click on the folder icon to select the built firmware in .bin format (e.g. VESC_fw.bin)
158+
159+
##### [ Reminder : It is normal to see VESC disconnects during the firmware upload process ]
160+
##### **[ Warning : DO NOT DISCONNECT POWER/USB to VESC during the upload process, or you will risk bricking your VESC ]**
161+
##### **[ Warning : ONLY DISCONNECT your VESC 10s after the upload loading bar completed and "FW Upload DONE" ]**
162+
163+
6. Press the upload firmware button (downward arrow) on the bottom right to start upload the selected firmware.
164+
7. Wait for **10s** after the loading bar completed (Warning: unplug sooner will risk bricking your VESC)
165+
8. The VESC will disconnect itself after new firmware is uploaded.
166+
167+
## In case you bricked your VESC
168+
you will need to upload a new working firmware to the VESC.
169+
However, to upload a firmware to a bricked VESC, you have to use a SWD Debugger.
170+
139171

140172
## Contribute
141173

0 commit comments

Comments
 (0)