Appearance
Y204-R Standard Ethernet DTU Technical Manual
Table of Contents
- Introduction
- System Overview
- Hardware Interfaces
- Electrical Specifications
- Serial Configuration & Packaging
- Ethernet Networking & Web Console
- Socket Protocol Workflows
- Modbus Gateway & JSON Services
- Advanced Functions
- Remote Management & Diagnostics
- AT Command Highlights
1. Introduction
Y204-R is the quad-port member of the Yanji Standard Ethernet DTU family. It exposes four isolated RS232/RS485 interfaces that can be bridged to 10/100 M Ethernet with dual sockets per port, Modbus RTU ↔ TCP gateway services, registration packets, heartbeats, HTTP/MQTT clients, JSON uploader, and remote AT workflows consistent with Y201/Y202 devices. The enlarged enclosure provides redundant power inputs (terminal + barrel) and thermal headroom for 24/7 cabinet operation.
| Item | Description |
|---|---|
| MCU & OS | Dual-core 240 MHz MCU + RTOS, hardware & software watchdog |
| Serial Interfaces | 4 × RS232/RS485 (per-port selectable) |
| Ethernet | 10/100Base‑T RJ45, static/DHCP |
| Services | Transparent TCP/UDP, HTTP Client, MQTT Client, Modbus gateway, JSON scheduler, OTA |
| Form Factor | 150 × 110 × 35 mm DIN-rail housing |
Mechanical drawings, SKU matrix, and ordering information reside in the Y204-R Specification.
2. System Overview
- Multi-Port Architecture – Four independent COM ports, each exposing Socket A/B, packaging rules, Modbus conversion switches, and dedicated heartbeats.
- Unified Firmware – Shares the same RTOS build as Y202-R/Y208-R, enabling uniform AT command sequences, backup images, and OTA distribution across fleets.
- Power & Reliability – Wide 9–36 V DC input, reverse/over-voltage protection, optional 12 V barrel jack, dual watchdogs, and programmable reboot-on-silence for unattended cabinets.
- Web + AT Management – Browser console (Status/System/Port tabs) mirrors AT command sets; remote AT and discovery tools simplify large-scale rollouts.
- Application Targets – Substations, factory cells, traffic cabinets, and energy monitoring nodes needing simultaneous access from SCADA, MES, and cloud systems.
3. Hardware Interfaces
| Group | Description |
|---|---|
| Power | 2-wire terminal (V+/V-) plus Ø5.5/2.1 mm DC barrel; inputs are diode-isolated for redundant feeds. |
| Serial | Two removable terminal blocks: COM1/2 and COM3/4. Each channel can be wired as RS232 (TX/RX/GND) or RS485 (A/B/GND) through firmware selection. |
| Ethernet | Single RJ45 10/100Base‑T with LINK/ACT LEDs and auto MDI/MDIX. |
| USB | Micro-USB console (CDC) for local AT access and firmware upload. |
| Button | Reload – 3–10 s restores last saved config, >10 s triggers factory defaults. |
LED Behavior
| LED | Behavior | Meaning |
|---|---|---|
| POWER | Steady on | DC supply OK |
| WORK | Fast blink (~400 ms) | Boot sequence / waiting for IP |
| WORK | Slow blink (~2 s) | IP acquired, sockets ready |
| DATA | Off | No socket session |
| DATA | Steady | At least one socket connected |
| DATA | Blink | Serial ↔ Ethernet payload flowing |
| TXn/RXn | Blink | Activity on COMn (n = 1..4) |
4. Electrical Specifications
| Parameter | Value |
|---|---|
| Supply Voltage | 9–36 V DC terminal + 12 V barrel jack |
| Typical Current | 220 mA @ 12 V with four sockets active |
| Power Protection | Reverse polarity, surge clamp, user-fused input recommended |
| Operating Temp | -35 °C ~ +75 °C (extended SKU -40 °C ~ +85 °C) |
| Humidity | 5% ~ 95% RH, non-condensing |
| Isolation | COM-port galvanic isolation, >1.5 kV between channels |
| Mounting | 35 mm DIN rail clip with optional panel ears |
Maintain ≥20 mm clearance around the chassis, keep shielded RS485 pairs away from AC feeders, and terminate long buses with 120 Ω resistors at both ends.
5. Serial Configuration & Packaging
5.1 UART Parameters
Per-port command: AT+UARTn=<baud>,<databits>,<stopbits>,<parity>,<fc> (n = 1‒4).
| Field | Options | Default |
|---|---|---|
| Baud Rate | 1,200–460,800 bps | 115,200 |
| Data Bits | 7 / 8 | 8 |
| Stop Bits | 1 / 2 | 1 |
| Parity | NONE / EVEN / ODD | NONE |
| Flow Control | NFC (RS232) / auto-direction (RS485) | NFC |
5.2 Packaging (AT+UARTTLn)
- Length trigger: 64–1024 bytes (default 1024).
- Gap trigger: 1–300 ms (default 0 ms adaptive).
Any satisfied condition flushes data toward both sockets of the selected COM.
5.3 Modes
- Transparent Mode – Default serial tunnel for payload transfer.
- AT Command Mode – Enter
++++ guard time +a; exit usingAT+EXITor reboot. Network forwarding pauses ≤3 s during the transition. - Broadcast AT – Enable via
AT+EXATto allow socket-side AT control across multiple ports.
6. Ethernet Networking & Web Console
6.1 Default Profile
| Parameter | Value |
|---|---|
| IP Mode | Static |
| IP Address | 192.168.10.8 |
| Gateway | 192.168.10.1 |
| Netmask | 255.255.255.0 |
| HTTP Login | admin / admin |
Steps:
- Set a laptop to the same subnet and connect via RJ45.
- Browse to
http://192.168.10.8and authenticate. - Use Status (live metrics), System (WAN, time, OTA), and Port tabs (COM1‒COM4 parameters, sockets, Modbus gateway).
- Save/Apply and click Reboot to activate changes.
6.2 LAN Commands
- DHCP:
AT+WAN=DHCP - Static:
AT+WAN=STATIC,<ip>,<gateway>,<mask> - DNS backup:
AT+DNS=<address>(default 114.114.114.114) - Broadcast discovery:
AT+SEARCH=<udp_port>,<keyword>(default8168,HuayunIOT) - MAC info:
AT+DEVINFO
7. Socket Protocol Workflows
Each COM exposes Socket A and Socket B. Enable with AT+SOCKENns=ON (n = 1‒4, s = A/B) and define behavior using AT+SOCKns=<type>,<addr>,<port>[,localport].
7.1 TCP Server
- Default listen port 8010; accepts up to eight concurrent clients per socket.
- Example (COM1 SocketA):
AT+SOCKEN1A=ON AT+SOCK1A=TCPS,0.0.0.0,8010 AT+REBOOT
7.2 TCP Client
- Auto-reconnect every second until successful. Suitable for redundant SCADA head-ends.
- Example (COM3 SocketB):
AT+SOCKEN3B=ON AT+SOCK3B=TCPC,10.10.10.50,9000 AT+REBOOT
7.3 UDP Server/Client
UDPCtargets a fixed IP/port; specifylocalportif firewalls demand a known source.UDPSlistens for any origin and responds to the most recent sender—ideal for handheld maintenance terminals.
7.4 HTTP Client
- Switch socket to
HTPC, configure headers (AT+HTPHDn), request mode (AT+HTPREQn=GET/POST/AUTO), and optional URL (AT+HTPURLn). AUTO mode allows inline request composition separated by\r\n.
7.5 MQTT Client
- Use
AT+MQCONFn,AT+MQAUTHn,AT+MQPUBn,AT+MQSUBn. Supports QoS 0/1/2, keepalive up to 65,535 s, TLS-offload via upstream gateways, and Aliyun quick template (AT+MQALI).
7.6 Registration Packets & Heartbeats
- Registration:
AT+REGTPn(MAC/CUS),AT+REGMDn(OFF/FIRST/EVERY/ALL),AT+REGDATn(payload). - Heartbeats:
AT+HEARTMDn(OFF/NET/UART),AT+HEARTTMn(seconds),AT+HEARTDATn. - No-data reboot:
AT+SOCKRTO=<minutes>per device.
8. Modbus Gateway & JSON Services
- Enable per COM via Port tab or
AT+MBMDn=ON. Incoming Modbus TCP frames convert to RTU on the selected serial bus, preserving timing gaps and returning responses automatically. - Scheduler example:
AT+MBCFG1=ON,200,5 AT+MBCMD1=010300000002C40B AT+MBJS1=ON,30 - JSON uploader fields include MAC, timestamp, and key/value pairs defined with
AT+HJREG+AT+MBJSn. Payloads can be pushed over HTTP or MQTT according to socket mapping.
9. Advanced Functions
| Feature | Command | Description |
|---|---|---|
| Offline Cache | AT+CACHEn=ON/OFF | Buffers up to 50 frames per COM when uplink fails. |
| Data Conversion | AT+DTCVTn=<uplink>,<downlink> | Automatic HEX↔RAW conversion templates. |
| Remote AT over Sockets | AT+EXAT=<mode>,<keyword> | Enables password-protected AT channel via sockets. |
| HTTP OTA | AT+DOWNLOAD=<uri> | Pulls firmware via HTTP; integrity checked before swap. |
| Dual Watchdog | AT+WDOG=<enable>,<threshold> | Configurable software watchdog supplementing hardware one. |
| Backup/Restore | AT+BKCFG, AT+RSTCFG, AT+CLRCFG | Capture, restore, or factory reset configuration. |
10. Remote Management & Diagnostics
- Use registration packets (FIRST) so head-ends receive MAC + cabinet ID on every reconnect.
- Configure NET heartbeats (e.g., 60 s) and UART heartbeats for PLC partners to detect line breaks.
- Set
AT+SOCKRTO(30–120 min) for auto reboot when sockets remain idle. - Schedule HTTP OTA windows and keep firmware packages reachable over HTTPS/HTTP.
- After commissioning, run
AT+BKCFGand store the binary to your CMDB for quick disaster recovery. - Enable
AT+CACHEplus JSON uploader when working over spotty uplinks; cached frames auto-flush after connectivity returns.
Diagnostic toolkit:
AT+DEVINFO– Model, firmware version, MAC, serial number.AT+SOCKLK– Runtime socket states (type/IP/port).AT+PING=<host>– Reachability test.AT+NETSTAT– LAN statistics, DHCP status.AT+LOG=<level>– Switch debug verbosity for short periods.- Reload button – Restores last saved params without laptop access.
11. AT Command Highlights
| Command | Purpose |
|---|---|
AT+LIST | Enumerate supported instructions |
AT+VER | Firmware version |
AT+WAN | Static/DHCP selection |
AT+SOCKns, AT+SOCKENns | Define/enable sockets (n = 1‒4) |
AT+REGTPn, AT+REGMDn, AT+REGDATn | Registration packets |
AT+HEARTMDn, AT+HEARTTMn | Heartbeat mode & interval |
AT+MBCFGn, AT+MBCMDn, AT+MBJSn, AT+HJREG | Modbus scheduler & JSON mapper |
AT+MQCONFn, AT+MQAUTHn, AT+MQPUBn, AT+MQSUBn | MQTT workflows |
AT+HTPURLn, AT+HTPHDn, AT+HTPREQn | HTTP client settings |
AT+DOWNLOAD | HTTP OTA upgrade |
AT+CACHEn, AT+SOCKRTO | Offline cache & auto-reboot |
AT+BKCFG, AT+RSTCFG, AT+CLRCFG | Backup/restore/factory reset |
- Linked Documents: Y204-R Specification · DTU Overview
- Manufacturer: Hunan Yanji Tech Co.,Ltd · Email: hi@yanjiiot.com
