# `mix firmware.qdl`
[🔗](https://github.com/jimsynz/nerves_system_arduino_uno_q/blob/v0.1.1/lib/mix/tasks/firmware.qdl.ex#L1)

Provisions an Arduino UNO Q with your Nerves firmware over USB.

Use this the first time you install Nerves on a board, or to recover one.
It works whatever is on the eMMC, because it uses the QRB2210's Emergency
Download (EDL) mode, which is built into the chip. After that, update the
board as usual with `mix upload`.

It rewrites the eMMC with:

  * Qualcomm's boot firmware, from Arduino's eMMC bootloader bundle
  * a partition table with the Nerves partitions
  * your firmware, as `fwup -t complete` would write it

Anything in the application data partition is lost.

    mix firmware.qdl

## Requirements

  * `fwup` on your `PATH`
  * access to USB device `05c6:9008`. On Linux, add a udev rule such as
    this, which also keeps ModemManager away from the board:

        SUBSYSTEMS=="usb", ATTRS{idVendor}=="05c6", ATTRS{idProduct}=="9008", MODE="0660", GROUP="plugdev", ENV{ID_MM_DEVICE_IGNORE}="1"

It uses [`qdl`](https://github.com/linux-msm/qdl) to talk to the board. If
`qdl` isn't on your `PATH`, it downloads Arduino's prebuilt `qdl` for your
computer.

## Options

  * `--firmware PATH` - the `.fw` file to install. Defaults to the one
    `mix firmware` builds.
  * `--dry-run` - prepare everything and run `qdl --dry-run` without a board

---

*Consult [api-reference.md](api-reference.md) for complete listing*
