= Ignition Programming Dongle Assembly Instructions

== Materials

- One (1) 913-0000089 Adafruit FT232H breakout board (Adafruit Product ID [2264](https://www.adafruit.com/product/2264))
- One (1) 913-0000091 Adafruit Ignition Adapter PCBA
- One (1) 920-0000116 Ignition Programming Cable (Samtec SFSD-05-28-G-3.25-D-NDX)
- 1-inch diameter adhesive-lined heat shrink tubing with a 3:1 shrink ratio
- X-Acto knife or scalpel
- Superglue
- Heat gun
- Brother PTouch PT-P700 printer
- Brother TZE 9mm black-on-white label tape
- Dymo Rhino 4200 label maker
- Dymo A18057 19mm heat shrink label tube
- (Optional) One 3D-printed https://github.com/oxidecomputer/hardware-adafruit-ignition-adapter/tree/main/assembly/adafruit_soldering_fixture[Adafruit soldering fixture]

== Assembly

. Remove the Adafruit FT232H breakout board from its package. Confirm that the
`I2C MODE` switch on the Adafruit FT232H breakout board is set to `OFF`.

. Slide the Adafruit FT232H breakout board onto the headers installed on the
Ignition adapter board as shown in Figure X. If you're assembling lots of these
dongles, we recommend using the 3D-printed
https://github.com/oxidecomputer/hardware-adafruit-ignition-adapter/tree/main/assembly/adafruit_soldering_fixture[Adafruit
soldering fixture] to achieve consistent alignment.

. Solder the Adafruit Ignition adapter board to the Adafruit FT232H breakout
board.

. Cut a 2-inch length of 1-inch diameter heat shrink tubing and shrink wrap the
entire PCBA, including the connectors, as shown in Figure X.

. Once the heat shrink has cooled and hardened completely, cut the heat shrink
away from the Ignition programming connector with an X-Acto knife or scalpel as
shown in Figure X.

. Plug in the SFSD-05-28-G-10.00-D-NDX cable to connector J3 and apply a dot of
superglue at the joint between the connector and the cable to secure the cable
in place.

== Flashing the FT232 EEPROM

For some reason, https://forums.adafruit.com/viewtopic.php?t=147113[Adafruit
programs all their FT232H breakout board EEPROMs with identical, invalid EEPROM
images]. Oxide's manufacturing stations identify dongles by serial number, so we
use a Python script to generate a random serial number and flash the EEPROM with
a valid image. The Python script also prints out a serial number label for the
dongle so we can identify it during programming station setup.

Dependencies:

- `python3`
- `ftdi-eeprom`
- `ptouch-print` (manually built following [these instructions](https://github.com/HenrikBengtsson/brother-ptouch-label-printer-on-linux))


Clone the [oxidecomputer/hardware-toolbox
](https://github.com/oxidecomputer/hardware-toolbox)repo and run
`adafruit-fix.py`.

```
$ git clone https://github.com/oxidecomputer/hardware-toolbox
$ cd hardware-toolbox/adafruit-programming
$ python3 adafruit_fix.py
```

See `$ python3 adafruit_fix.py --help` for a list of optional arguments.

Running `adafruit_fix.py` will generate a random serial number, program the
FT232 EEPROM, and print a label with the serial number. Apply the serial number
to the bottom of the dongle as shown in Figure X.

== Labels

Each Ignition programming dongle needs two labels:

- A label on the dongle with the FT232 serial number. Running `adafruit_fix.py`
prints this label automatically

- A label on the programming cable, to help operators identify which dongle is
which. Print the ceble label on 19mm Dymo heat shrink label tape in 12pt font
and apply it to the ignition cable:

```
IGNITION SPI
920-0000116
```

Apply the labels to the dongle and the cable as shown in Figure X: