Dual RS485 Modbus Gateway Adaptation | Obeita
This configuration is proposed for assessment. Confirm interfaces, components and performance for your specific project.

Connect two separate Modbus RTU buses to an ESP32-C3 gateway, then expose their measurements through Modbus TCP or MQTT. The design includes register interpretation and browser-based configuration, so integration is about useful equipment data rather than an opaque stream of serial bytes.
Independent polling and data conversion
Each RS485 bus needs its own serial settings and polling schedule. The mapping layer interprets registers, converts byte order and applies engineering scaling before exposing values upstream. A slow or unresponsive slave should not block the other bus; timeout limits, retry counts and scan budgets are therefore part of the gateway configuration.
Web configuration and live operation
The management workflow covers Wi-Fi provisioning, serial parameters, custom register definitions and live measurements. Online writes require clear access permissions and a defined mapping to device registers. OTA updates are another part of the management design; configuration retention and interrupted-update recovery must be tested alongside the update itself.
Compact DIN-rail hardware
The ESP32-C3 design uses MAX485ESA transceiver paths, TPS5430DDA for the 12-to-5 V conversion and AMS1117-3.3 for the logic rail. An 82 × 54 × 32 mm rail enclosure and an external 2.4 GHz antenna are the mechanical direction. Antenna location, bus termination and access to configuration controls should be reviewed with the cabinet layout.
Proposed design configuration
These are configuration inputs for development; the final assembly, firmware and acceptance tests define the delivered specification.
| Item | Configuration |
|---|---|
| Controller | ESP32-C3 |
| Field buses | 2 independent RS485 / Modbus RTU channels |
| Upstream services | Modbus TCP mapping and MQTT publishing |
| Data handling | Byte-order conversion and engineering scaling |
| Management | Web setup, live data, online writes, OTA development scope |
| Enclosure direction | 82 × 54 × 32 mm, rail mounted |
Project questions
How do I map a floating-point value from two registers?
Specify register order, byte order, data type and scaling. Verify the decoded result against a known instrument value before exposing it over TCP or MQTT.
Can one device timeout delay all measurements?
It can if scheduling is not designed carefully. Separate bus tasks and bounded retries should be tested with deliberately disconnected slaves.
Plan this project
Send both bus device lists, register maps, scan interval and desired TCP/MQTT fields for a mapping proposal.