# NACK Received when updating voxl esc

Source: https://forum.modalai.com/topic/3551/nack-received-when-updating-voxl-esc
Category: ESCs, Sensors and Accessories (https://forum.modalai.com/category/15/escs-sensors-and-accessories)
Tags: esc
Posted: 2024-06-14 01:38:43 UTC by wilkinsaf
Replies: 5 · Views: 1171

## wilkinsaf · 2024-06-14 01:38:43 UTC

I am getting a "NACK Received" when I am trying to update the firmware on my voxl esc. I get to about 4% and then I get this error
Here is a video explaining it in closer detail
[https://www.loom.com/share/f016b3a706a242c2a2235107f2faabb0](https://www.loom.com/share/f016b3a706a242c2a2235107f2faabb0)

## Reply by Alex Kushleyev (ModalAI staff) · 2024-06-14 02:56:18 UTC

@wilkinsaf , you have a M0117 ESC, this can be seen @ 0:32 of  your video (and other parts), but you are trying to install firmware for M0138 ESC.

Also, three of your ESC channels have ESC version 39 (ids 0,1,2) and id 3 has firmware version 36.

In any case, you can use the following script to auto detect the ESC (and pick correct firmware) and install it : 

```
cd /usr/share/modalai/voxl-esc-tools/
./voxl-esc-upload-firmware-all.sh
```

This should update firmware for all all 4 ESCs. 

Then you will need to install the desired ESC params to your ESC. Please note that IDs 0 and 3 are missing params (that is why they are defaulting to 57600 baud rate), but the `voxl-esc-upload-params.py` script should take care of it. You can always force the update params script to use specific baud rate (such as 57600).

Alex

## Reply by wilkinsaf · 2024-06-14 14:36:53 UTC (in reply to Alex Kushleyev)

@Alex-Kushleyev 

Yes, whenever I try to have the auto-update for the firmware I get this

```
VOXL Platform: M0054
Detected RB5 Flight, VOXL2 M0054 or M0104!
INFO: Scanning for ESC firmware: /dev/slpi-uart-2, baud: 2000000
Sending library name request: libslpi_qrb5165_io.so
Sending initialization request
INFO: ESC(s) detected on port: /dev/slpi-uart-2, baud rate: 2000000
INFO: ESC(s) detected: [1, 2]
WARNING: Specified ESC ID not detected; perform manual power cycle now
Updated baud rate to 230400
INFO: Installing firmware to ESC ID 0 : /usr/share/modalai/voxl-esc-tools/firmware/modalai_esc_firmware_m0117_1_v0_39_RC10_eb6fb500.bin

ERROR: An error occured during the write process.

```

## Reply by wilkinsaf · 2024-06-14 14:41:41 UTC (in reply to wilkinsaf)

When I try and update the parameters I get

```
voxl2:/usr/share/modalai/voxl-esc-tools$ ./voxl-esc-upload-params.py --params-file ../voxl-esc-params/D0012_Starling_MAX/esc_params_m0129_f2203_5_1500kv_7x3.7x3.xml 
Detected Python version : 3.6.9 (default, Mar 10 2023, 16:46:00) 
[GCC 8.4.0]
dpkg-query: no packages found matching voxl-esc-board-detect.py
dpkg-query: no packages found matching voxl-esc-calibrate.py
dpkg-query: no packages found matching voxl-esc-led.py
dpkg-query: no packages found matching voxl-esc-neopixel-test.py
dpkg-query: no packages found matching voxl-esc-scan.py
dpkg-query: no packages found matching voxl-esc-spin-helper.sh
dpkg-query: no packages found matching voxl-esc-spin-sine.py
dpkg-query: no packages found matching voxl-esc-spin-step.py
dpkg-query: no packages found matching voxl-esc-spin.py
dpkg-query: no packages found matching voxl-esc-tools-bin
dpkg-query: no packages found matching voxl-esc-upload-firmware-all.sh
dpkg-query: no packages found matching voxl-esc-upload-firmware.py
dpkg-query: no packages found matching voxl-esc-upload-params.py
dpkg-query: no packages found matching voxl-esc-verify-params.py
dpkg-query: no packages found matching voxl_esc_setup_paths.py
dpkg-query: no packages found matching voxl_serial.py
Found voxl-esc tools bin version: 1.6

INFO: Params file name : ../voxl-esc-params/D0012_Starling_MAX/esc_params_m0129_f2203_5_1500kv_7x3.7x3.xml 
INFO: Params file size : 7507 bytes

VOXL Platform: M0054
Detected RB5 Flight, VOXL2 M0054 or M0104!
INFO: Scanning for ESC firmware: /dev/slpi-uart-2, baud: 2000000
Sending library name request: libslpi_qrb5165_io.so
Sending initialization request
INFO: ESC(s) detected on port: /dev/slpi-uart-2, baud rate: 2000000
INFO: ESCs detected:
INFO: ---------------------
ID: 1, SW: 39, HW: 34: ModalAi 4-in-1 ESC (M0117-1)
ID: 2, SW: 39, HW: 34: ModalAi 4-in-1 ESC (M0117-1)
---------------------
INFO: Loading XML config file...
INFO: Uploading params for ESC ID 255...
-- board config
-- id config
-- uart config
-- tune config
    DONE
INFO: Resetting ESCs...
    DONE
VOXL Platform: M0054
Detected RB5 Flight, VOXL2 M0054 or M0104!
INFO: Scanning for ESC firmware: /dev/slpi-uart-2, baud: 250000
INFO: Scanning for ESC bootloader: /dev/slpi-uart-2, baud: 230400
Updated baud rate to 230400
ERROR: No ESC(s) detected
VOXL Platform: M0054
Detected RB5 Flight, VOXL2 M0054 or M0104!
INFO: Scanning for ESC firmware: /dev/slpi-uart-2, baud: 921600
INFO: Scanning for ESC bootloader: /dev/slpi-uart-2, baud: 230400
Updated baud rate to 230400
ERROR: No ESC(s) detected
VOXL Platform: M0054
Detected RB5 Flight, VOXL2 M0054 or M0104!
INFO: Scanning for ESC firmware: /dev/slpi-uart-2, baud: 230400
INFO: Scanning for ESC bootloader: /dev/slpi-uart-2, baud: 230400
Updated baud rate to 230400
ERROR: No ESC(s) detected
VOXL Platform: M0054
Detected RB5 Flight, VOXL2 M0054 or M0104!
INFO: Scanning for ESC firmware: /dev/slpi-uart-2, baud: 57600
INFO: ESC(s) detected on port: /dev/slpi-uart-2, baud rate: 57600
INFO: ESCs detected:
INFO: ---------------------
ID: 0, SW: 39, HW: 34: ModalAi 4-in-1 ESC (M0117-1)
ID: 3, SW: 36, HW: 34: ModalAi 4-in-1 ESC (M0117-1)
---------------------
ERROR: ESC firmware version 36 is incompatible with params supported by this utility
       Acceptable ESC firmware versions are:  [38, 39]

```

I have tried a parameter set in the "old" parameter folder with similar results

## Reply by wilkinsaf · 2024-06-14 14:52:24 UTC (in reply to wilkinsaf)

Ok, Here is how I solved it. 

1. Installed old firmware: `./voxl-esc-upload-firmware.py --firmware-baud-rate 57600 -f firmware/old/modalai_esc_firmware_m0117_1_v0_36_f75f1fdb.bin --id 0`
2. Installed newer firmware: `./voxl-esc-upload-firmware.py --firmware-baud-rate 250000 -f firmware/modalai_esc_firmware_m0117_1_v0_39_RC10_eb6fb500.bin --id 0`

I was loading a custom SDK on this vehicle so I am theorizing that there is somehting custom/funky going on with voxl-esc

## Reply by Alex Kushleyev (ModalAI staff) · 2024-06-14 17:45:19 UTC (in reply to wilkinsaf)

@wilkinsaf , yes, you got it. By the way, you did not have to restore the old firmware, you could have just done this:

```
./voxl-esc-upload-firmware.py --firmware-baud-rate 57600 -f firmware/modalai_esc_firmware_m0117_1_v0_39_RC10_eb6fb500.bin --id 0
```

The following note does not really help, if you also have power connected to VOXL2..
```
WARNING: Specified ESC ID not detected; perform manual power cycle now
```
However, if the ESC is connected to a PC, you can just power cycle the ESC and the the bootloader will start up and firmware update will being.

Alex
