pont-uart.ino
The GIGA lines up 4 hardware UARTs: Serial1 on D0/D1 becomes the gateway to the TTL world. The bidirectional bridge configures a module live from the serial monitor.
Hardware required
An Arduino GIGA R1 WiFi (STM32H747, 1DX radio module: Wi-Fi b/g/n + BLE, u.FL antenna included), powered over USB-C. 1 3.3 V UART module (GPS, LoRa, RS-485…) + adapter if needed.
Wiring
Crossed TX/RX between D0/D1 and the module, common grounds, 3.3 V levels. Note: D0/D1 are the classic Serial pins on other boards.
How it works
Two FIFOs and two whiles: each stream drains every pass. With 4 UARTs + USB, the GIGA bridge can grow into a multi-module router. In the Arduino IDE, « Arduino Zephyr-based Boards » platform, « Arduino Giga R1 » board; fit the u.FL antenna before using the radio, then Upload.
Going further
Add frame parsing (prefix/terminator) and redirection onto the CAN bus.
pont-uart.ino
// Pont Serial USB <-> Serial1 (D0 RX / D1 TX) a 9600 bauds.
// Exemple typique : GPS, module LoRa, convertisseur RS-485.
void setup() {
Serial.begin(115200); // console USB
Serial1.begin(9600); // D0/D1 : le module
Serial.println("Pont USB <-> Serial1 actif");
}
void loop() {
while (Serial1.available()) // module -> console
Serial.write(Serial1.read());
while (Serial.available()) // console -> module (config AT)
Serial1.write(Serial.read());
}