VESC - Installing a bootloader

thx for this thread guys!

Just wanted to point out that you no longer need to do all this fancy stuff, because the new Vesc-tool can upload a bootloader to vescs that don’t already have one. I did this with my Maytech vesc and it went fine. Let me know if you need any help.

Hey folks, maybe i’m too tired but I’m looking for the good wiring on a FOCBOX to flash it with a STLINK

Focbox. Stlink Rst. Rst Dio. Swdio Clk. Swclk Gnd. Gnd

Dont think you need the 3.3V @okp

1 Like

Thanks for the support. That went perfectly fine. I have put back the FW2.16.

I just can’t upload FW 3.x with VESC TOOL. It seems to upload but nothing is upgraded. Either the FW or Bootloader

Any idea?

You need to upload the bootloader through command lines, not using VESC Tool. Bootloader uploading through VESC Tool is only a trick Vedder coded in emergency to deal with VESCs with a FW but no bootloader (I mean, it has NEVER been uploaded). If you try to upload it although one was already existing, you mess it up. (See the warning of Vedder at the early stage of Beta for beta-testers : )

OK, Id really love some things confirmed if anyone can help:

  • I have a Vesc with 2.18 FW and its 4.12 HW
  • I have a Mac
  • I have an STLinkV2 ordered

I want to update the Firmware so I can use full features of the @rpasichnyk Metr App.

  1. Do I need to download Ubuntu?
  2. Do I need a PC emulator?
  3. Or, can I just do the upgrade via VescTool on my Mac?

I’ve been reading and watching some vague vids for a few hours and there seems to be a few ways to do this and all of them are confusing for different reasons. Theres talk of a Hex file. When I download from the link above, I get a folder with a few things in it. Will it all become apparent when I finally figure out how to run the STLink Utility?

If you have a VESC with a firmware already installed you can flash the bootloader from VescTool. If somehow you accidentally removed the firmware from the device you’ll need the STLink to recover it.

I had the misfortune to have used a bad USB cable and broke my firmware during a config upgrade on my FOCBOX. In case that happens, you have to use the STLink tool to flash any firmware (I used 2.18 firmware file) back to the device. I don’t have the instructions for that nearby, but if needed I can go look them up :slight_smile:

TLDR; if there’s a firmware on there you can flash bootloader via VescTool.


Thanks Jamy! That sounds pretty simple then. SO the VESC TOOL will have the latest firmware automatically on it or do I need to direct it to somewhere?

Vesc_tool will have the latest 3.XX firmware. I’m not sure if that’s compatible with Metr, but if it isn’t you can always downgrade :slight_smile:

1 Like

I think it is. SO just to confirm… My Vesc absolutley does not currently have a Bootloader on it. So, with VESC TOOL, this doesnt matter? The tool puts a bootloader on it or acts as the boot loader?

Vesc tool will ask you if you want to install a bootloader when you connect it :slight_smile:

1 Like

Cheers man! Ill give it a go and it it goes tits up, the STLink is in the mail.

Hey Jamy, so what was yours wiring diagram to the Fox ? Did you use the 3.3v ? Or just Rst Swdio Swclk & Gnd ? Thanks for your help :v:

It’s all back in my Raptor 2, but I got a picture here. I soldered to each of the pins above the cap (which was a pain in the ass because there was solder already in there…

The ground pin was the worst so I just connected elsewhere to ground.

So, tldr; connect to: RST, DTO, GND, CLK, 3.3

1 Like

:+1: Perfect ! Thank you, treenutter and JdogAwesome a lot guys :wink:

1 Like

Hi All, does anyone can share the link of the bootlaoder file for VESC 6? thanks.

1 Like

Bump @JohnnyMeduse have vesc 6 bootloader hex you can post?

Hummmm… I don’t have it… I usually program them with the bootloader from the 4 and upgrade them after :crazy_face:

1 Like