m working on a custom application to upload .apj files to Pixhawk 6C CUPE Plus Orange using the Bootloader protocol. The application is built using Qt QML + C++.
- I am using the official PX4 Bootloader protocol:
namespace BL {
const uint8_t INSYNC = 0x12;
const uint8_t OK = 0x10;
const uint8_t GET_SYNC = 0x21;
const uint8_t CHIP_ERASE = 0x23;
const uint8_t PROG_MULTI = 0x27;
const uint8_t REBOOT = 0x30;
const uint8_t EOC = 0x20;
const int PROG_MULTI_MAX = 64;
}
Current Behavior:
-
The serial port opens correctly.
-
GET_SYNC and REBOOT commands work and respond correctly with 12 10.
-
However, both CHIP_ERASE and PROG_MULTI commands fail, and I receive 12 13 (INVALID) or FAILED responses.
Example output:
Opened port: COM13 : Pixhawk6C
Opened port: COM14 : Pixhawk6C
MAVLink reboot-to-bootloader sent to SYS_ID=1 COMP_ID=1
Starting scan…
Port opened: COM12 (Pixhawk6C-BL)
Sending INSYNC+GET_SYNC…
GET_SYNC response: 12 10
CHIP_ERASE (takes ~6 seconds)…
CHIP_ERASE response: 12 13 ← FAIL
SET_ADDRESS 0x08004000…
SET_ADDRESS response: 00 00 00 00 12 10 ← FAIL
Writing Firmware (PROG_MULTI)…
resp 12 13 12 13 ← FAIL at offset 0
Sending REBOOT command…
REBOOT response: 12 10
