> For the complete documentation index, see [llms.txt](https://docs.arkelectron.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.arkelectron.com/products/flight-controller/arkv6x/firmware.md).

# Firmware

The ARKV6X ships with PX4 and can be flashed with ArduPilot. The ARKV6X Extended Range needs PX4 1.14 or later, or ArduPilot 4.6.3 or later.

| Firmware  | Build target                                                                                                    |
| --------- | --------------------------------------------------------------------------------------------------------------- |
| PX4       | `ark_fmu-v6x_default` ([boards/ark/fmu-v6x](https://github.com/PX4/PX4-Autopilot/tree/main/boards/ark/fmu-v6x)) |
| ArduPilot | `ARKV6X` ([hwdef](https://github.com/ArduPilot/ardupilot/tree/master/libraries/AP_HAL_ChibiOS/hwdef/ARKV6X))    |

## PX4

### Flashing Firmware

#### QGroundControl (USB-C)

Firmware can be flashed over USB C using [QGroundControl](https://qgroundcontrol.com/).

#### px4\_uploader.py (USB or UART)

[`px4_uploader.py`](https://github.com/PX4/PX4-Autopilot/blob/main/Tools/px4_uploader.py) can flash firmware over USB or UART. For UART flashing, only the **Telem1** port is supported.

Over USB:

```sh
python3 Tools/px4_uploader.py build/ark_fmu-v6x_default/ark_fmu-v6x_default.px4
```

Over UART (via Telem1):

```sh
python3 Tools/px4_uploader.py --port /dev/<your-uart> build/ark_fmu-v6x_default/ark_fmu-v6x_default.px4
```

### Building Firmware

```
make ark_fmu-v6x_default
```

and optionally upload

```
make ark_fmu-v6x_default upload
```

## ArduPilot

### Flashing Firmware

Firmware can be flashed over USB C using [QGroundControl](https://qgroundcontrol.com/).

### Building Firmware

```
./waf configure --board ARKV6X
./waf copter
```

and optionally upload

```
./waf copter --upload
```

For a carrier board with an IOMCU, change the hwdef first: see [hwdef modifications for use with an IOMCU](https://docs.arkelectron.com/products/flight-controller/arkv6x/ardupilot-instructions.md#hwdef-modifications-for-use-with-an-iomcu).

## Recovering the Bootloader (SWD)

The application is at `0x08020000` (128 KB sectors).

```bash
st-flash write ark_fmu-v6x_bootloader.bin 0x08000000
```

Use `ark_fmu-v6x_bootloader.bin` from `boards/ark/fmu-v6x/extras/` in PX4-Autopilot, or from [PX4 GitHub releases](https://github.com/PX4/PX4-Autopilot/releases). Then flash `ark_fmu-v6x_default.px4` over USB. Setup: [ST-LINK Flashing Guide](https://docs.arkelectron.com/knowledge-base/knowledge-base/st-link-flashing-guide.md#flashing-px4-flight-controllers).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.arkelectron.com/products/flight-controller/arkv6x/firmware.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
