Ardbox Q¶
Ardbox Q is an industrial DIN rail PLC with an Arduino UNO Q inside. It combines an STM32U585 microcontroller for real-time control with a Qualcomm Dragonwing QRB2210 processor running Debian Linux. It is available in two versions: Ardbox Q AD, with digital and analog inputs and outputs, and Ardbox Q ADR, with relay outputs. Each version is available with 2 GB or 4 GB of RAM.
What is included on purchase (default product)
- 1x Ardbox Q (AD or ADR) with an Arduino UNO Q inside (2 GB RAM + 16 GB eMMC, or 4 GB RAM + 32 GB eMMC, selectable at the moment of purchase).
- Plug-in terminal blocks for all the connections (6 on the Ardbox Q AD, 12 on the Ardbox Q ADR).
Requirements to use
- 1x Ardbox Q
- 1x USB-C cable
- DC power supply (12-24 Vdc)
Pinout¶
Ardbox Q AD pinout¶
Ardbox Q ADR pinout¶
The numbers next to each terminal are the Arduino UNO Q pins. A0 to A5 are the analog pins of the Arduino UNO Q (also D14 to D19). The SPI terminals go to the SPI header of the Arduino UNO Q.
Technical Features¶
| Power supply | 12-24 Vdc (operating range 11.4 to 25.4 Vdc) |
| Maximum power | 20 W |
| CPUs |
Qualcomm Dragonwing™ QRB2210 (4 × Cortex-A53) with Adreno GPU
STM32U585 (Cortex-M33) |
| Clock speeds |
Qualcomm: 2.0 GHz
STM32: up to 160 MHz |
| Flash and RAM capacities |
Qualcomm: 16 GB eMMC + 2 GB LPDDR4X RAM, or 32 GB eMMC + 4 GB LPDDR4X RAM
STM32: 2 MB of flash, 786 kB of SRAM |
| Operating systems |
Qualcomm: Debian Linux
STM32: Arduino Core on Zephyr OS |
| Inputs |
Ardbox Q AD: 10 (I0.0-I0.3 digital, I0.4-I0.9 analog/digital)
Ardbox Q ADR: 10 (I0.0-I0.3 digital, I0.4-I0.9 analog/digital) |
| Outputs |
Ardbox Q AD: 10 digital (Q0.0-Q0.9, PWM on Q0.0-Q0.7) and 7 analog 0-10 V (A0.0-A0.6, sharing pins with Q0.0-Q0.6)
Ardbox Q ADR: 8 relays (R1-R8) and 2 analog 0-10 V (A0.0, A0.1) |
| USB | 1x USB-C (USB 3.1) |
| Wireless | Dual-band Wi-Fi 5 and Bluetooth 5.1 |
| RS485 | 1x RS485 interface, half or full duplex (STM32) |
| RS232 | 1x RS232 interface (STM32), not at the same time as RS485 |
| SPI | 3.3 V SPI bus (STM32) |
Usage Environments¶
| Ambient temperature (operating) | 0 to 60 °C |
| Ambient temperature (storage) | -20 to 60 °C |
| Ambient humidity (operating) | 10 to 90 % (non-condensing) |
Measures¶
| Dimensions (W × H × D) | 45 × 101.4 × 119.6 mm (without terminal blocks) |
| DIN Rail | TS35 |
Power Supply¶
The Ardbox Q is supplied with 12 to 24 Vdc (operating range 11.4 to 25.4 Vdc). The power input is protected by a 2.5 A fuse (not resettable) and against reverse polarity.
Danger
Exceeding these limits may cause the equipment to malfunction, or even end up being damaged.
Consumption characteristics¶
The maximum power is 20 W: it is the worst case of the Arduino UNO Q (up to 15 W) plus the inputs, outputs and the internal power supply. Use it to size the power supply.
In normal operation the consumption is lower. Several factors can affect power consumption, for example:
- Arduino UNO Q model.
- Peripherals connected to the USB-C port.
- Number of outputs or relays switched on.
- Temperature and environmental conditions.
Custom Configurations¶
When you purchase an Ardbox Q, its software will come with the standard Arduino software, plus some modifications that make it our PLC. This section explains which modifications have been made and why they are necessary.
STM32 (Zephyr OS)¶
To build and flash firmware for the Ardbox Q STM32 you must add our custom Zephyr board definitions. These custom boards contain the device tree, pinmux, peripheral configuration, and board-specific Kconfig/settings that let Zephyr support the Ardbox Q hardware (GPIO mappings, UARTs, RS485 and RS232 libraries...).
You can follow these instructions to install these custom boards and use them with the Arduino IDE.
Qualcomm Dragonwing™ (GNU/Linux)¶
To prevent USB disconnection issues on your Ardbox Q PLC, you need to have two scripts and their associated services into the GNU/Linux operating system. These configurations typically come pre-loaded on your device, so you only need to follow these steps if you've manually updated the operating system of your Ardbox Q.
The Arduino Uno Q runs a GNU/Linux OS accessible via USB using Android Debug Bridge. ADB is a tool you install on your computer to access the board's shell and run system operations.
First of all, connect your Arduino Uno Q to your PC using only the USB-C connection. You don't need the 12-24 Vdc power supply for these steps. Then you can check how to install the necessary tools and access the Arduino Uno Q with the official Arduino tutorial.
Once you've confirmed ADB access is working, execute the following commands to apply the custom configurations needed for the Ardbox Q PLC:
- Reboot the ADB service when a USB disconnection is detected:
cat <<EOF | sudo tee /usr/local/libexec/adb-log-watchdog.sh #!/usr/bin/env bash # Configuration UDC_NAME=$(ls /sys/class/udc/ | head -n 1) GADGET_PATH="/sys/kernel/config/usb_gadget/g1" echo "ADB Log Watchdog starting for UDC: $UDC_NAME" # Start monitoring the journal for the specific suspend event journalctl -u adbd.service -f -n 0 | while read -r line; do if echo "$line" | grep -q "FUNCTIONFS_SUSPEND"; then echo "Detected USB Suspend in logs. Triggering reset..." systemctl stop adbd.service sleep 1 systemctl start adbd.service echo "ADB reset complete. Waiting for next event." fi done EOF sudo chmod +x /usr/local/libexec/adb-log-watchdog.sh cat <<EOF | sudo tee /etc/systemd/system/adb-watchdog.service [Unit] Description=ADB Log Watchdog After=adbd.service [Service] ExecStart=/bin/bash /usr/local/libexec/adb-log-watchdog.sh Restart=always User=root [Install] WantedBy=multi-user.target EOF sudo systemctl daemon-reload sudo systemctl enable --now adb-watchdog - Force the Arduino Uno Q USB-C into device mode:
cat <<EOF | sudo tee /etc/systemd/system/force-usb-device-mode.service [Unit] Description=Force USB-C Device Mode on Arduino UNO Q After=multi-user.target Before=docker.service containerd.service [Service] Type=oneshot ExecStartPre=/bin/sleep 3 ExecStart=/bin/sh -c 'echo device > /sys/kernel/debug/usb/4e00000.usb/mode' ExecStartPost=/bin/systemctl restart adbd.service RemainAfterExit=yes # Logging StandardOutput=journal StandardError=journal SyslogIdentifier=usb-host-mode [Install] WantedBy=multi-user.target EOF sudo systemctl daemon-reload # This command will close the ADB shell when applied. Don't worry, the # changes have definitely been applied. However, since it resets the USB # connection, you will be logged out of the shell. sudo systemctl enable --now force-usb-device-mode - After executing the previous commands, force-write all the files to the flash and reboot the board: