Tips for the VESC FW update and SWD program mode
In VESC, FW is do the main job of load the FW, not its bootloader. FW loads bootloader, FW buffers the new FW, the bootloader is only do a copy job.
Why my FW still keeps old version after update?
This often happens when the bootloader is lost or not installed.
Settlement: In the VESC tool PC edition, go to
Choose the bootloader file suit for you ESC.
Click download
Then go to firmware page to try to update firmware again.
Why my VESC bricked?
Click update firmware to the ESC in VESC tool and watching the progress bar to finish, is just first step, it is just saves the new FW in to its buffer zone, the ESC will then starts to erase old FW, copies new one from buffer to the FW zone.
If this copy process been ceased or interrupted, the FW zone will be incomplete or corrupted. And in VESC, it is FW to undertakes initialization and load FW task, not the bootloader, so FW corrupt will cause ESC 'bricked'.
That's why the VESC tool promotes ‘wait at least 10 seconds for finish the update’ message after download FW in to ESC.
When bricked, we need to re-program ESC through MCU's SWD interface. SWD is mean for Serial Wire Debug
SWD mode for Ubox dual
We have a blog here:https://spintend.com/blogs/news/6-steps-to-flash-bricked-vesc-without-programmer-in-easy-way
SWD mode for Ubox single 75V
Limited by its size, Ubox single 75V does not place the SWD port on the case.
When bricked, may be you have a Ubox dual in hand to rescue him.
Ubox single 75V | Ubox dual |
---|---|
3V3 | VCC |
SWC | SWDCLK |
GND | GND |
SWD | SWDIO |
NRST | NRST |
Ubox single doesn't have a socket, so we need to solder SWD, GND, SWC, 3V3 with a cable, connect cable to another Ubox or a third party VESC, then try VESC tool's SWD programmer.
Why not to connect NRST?
Usually, the NRST is no use, because VESC have no pin for controlling NRST, and SWD port can works without external reset pin.
But in some time, SWD can not reset chip with SWDIO and SWDCLK only, in this time, we can try to reset chip manually, by short this NRST pin to ground then release it during we do SWD connect in VESC tool, try this several times, maybe miracle will happen.
Keep a stable connection during SWD programming, otherwise the VESC may 'bricked'.