.. _gateway-xs-os-flashing: Flashing Debian ================== *OS* | *image* | *Debian* **For assistance:** contact **CTHINGS.CO Support** at `support.cthings.co `_. Goals ----- This guide explains how to flash the **Edge IoT Gateway XS** using the **NXP UUU utility**. Prerequisites --------------- You will need: * A CTHINGS.CO Debian BSP ``.zip`` package for Edge IoT Gateway XS containing: * Bootloader binary (``flash.bin``) * Root filesystem image (``*.img``) * UUU script needed for flashing bootloader and image (``uboot.auto``) * (Optional) Integrity checksum (``*.sha256``) * Flashing tool: **NXP UUU** * USB drivers required by your host operating system .. image:: images/gw-xs-uuu.png :width: 75% :alt: Location of UUU programming port :align: center Steps --------- Installing NXP UUU ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Follow the instructions here (it is recommended to use a Linux-based host computer): `https://github.com/nxp-imx/mfgtools `_ If you would like to install the ``uuu`` utility to your computer, optionally run ``sudo make install`` after compiling. Preparing the image files ^^^^^^^^^^^^^^^^^^^^^^^^^^ Download the Debian BSP package for Edge IoT Gateway XS from CTHINGS.CO and extract the ``.zip`` file on your host computer. The package contains the Debian image and the ``xs_flash.bin`` flashing binary. Accessing the UUU port ^^^^^^^^^^^^^^^^^^^^^^ 1. Power off the gateway. 2. Connect the micro-USB interface to your host computer. This is the NXP UUU interface. 3. Power on the device by long-pressing the **ON** button for approximately 1-2 seconds. The gateway should be detected automatically by the **UUU** tool. Flashing the full eMMC image ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Run the command from the directory containing the extracted BSP files. Replace ``cthingsco-edge-gw-xs-debian-bookworm-base-.img`` with the image filename provided in your package. **Edge IoT Gateway XS** .. tab-set:: .. tab-item:: Linux .. code:: console $ sudo uuu -b uboot.auto xs_flash.bin cthingsco-edge-gw-xs-debian-bookworm-base-.img .. tab-item:: Windows .. code:: powershell .\uuu.exe -b uboot.auto xs_flash.bin cthingsco-edge-gw-xs-debian-bookworm-base-.img First boot ^^^^^^^^^^ After the flashing process completes: 1. Disconnect power. 2. Wait 1-2 seconds. 3. Power on the gateway. On first boot, the Debian system resizes the filesystem and then reboots automatically. After this automatic reboot, the device is ready to use. .. note:: To obtain the image and firmware, please contact **CTHINGS.CO Support** at `support.cthings.co `_.