• sales

    +86-0755-88291180

Modbus RTU Relay User Guide

Overview

This is an industrial 8-ch relay module controlled via RS485 bus, utilizing Modbus RTU protocol. It features embedded protection circuits such as power isolation, ADI magnetical isolation, and TVS diode, etc. It also comes with an ABS enclosure.

The Modbus RTU Relay is very easy to use. Due to its fast communication, stability, reliability, and safety, it is an ideal choice for industrial control equipments and/or applications with high communication requirements.

Hardware testing

  • Connect USB to 485 moduble to Modbus RTU Relay board by wires. Connect A to A and B to B. Then connect the USB to 485 module to your PC

  • Download the SSCOM software and Open it in your PC. Select the correct COM port (according to Devices Manager), set baud rate to 9600. Click Extension and send the commands to test

If you want to send other commands, please check HEX option and choose ModbusCRC16 parity. Input the commands and send.


For more details of the commands, please refero Protocol Manual of Modbus RTU Relay

Examples

Raspberry Pi

Enable Serial port
  • Open terminal of Raspberry Pi
  • Run the following command to configure
sudo raspi-config
  • Choose Interfacing Options -> Serial -> No -> Yes
  • Then reboot Raspberry Pi
sudo reboot
Hardware connection

You need to connect and RS485 devices to Raspberry Pi (the demo codes provided is based on our RS485 CAN HAT), Connect Modbus RTU Relay module to the RS485 CAN HAT, A to A and B to B.

Run example

Use the following commands to run the demo codes

sudo apt-get install p7zip
wget https://www.waveshare.com/w/upload/f/f9/Modbus_RTU_Relay_Code.zip
7zr x Modbus_RTU_Relay.7z -r -o./Modbus_RTU_Relay
cd Modbus_RTU_Relay/Python3
sudo python3 main.py

STM32

The Demo codes for STM32 is based on NULCEO-F103RB and RS485 CAN Shield module

Download the #demo codes and open the STM32 project by Keil software.

Program the codes to NUCLEO board

The codes will run and toggle the relay in turn.

Arduino

The Arduino demo is based on Waveshare UNO Plus and RS485 CAN Shield

Open Arduino project and program it to the UNO board.

The codes will run and toggle the relay in turn.
TAG: Raspberry Pi DS3231 Python HTTP Request Communication Industrial USB TO RS232/485 (C) UART FT232RNL 2m For 3.3V / 5V For Switchable RS232/RS485 ESP32 S3 LCD Development Board 1.3 inch Display 1.3inch Screen ST7789 240x240 Mini TV SD-Port QST QMI8658 Gyro Sensor LVGL For Arduino Raspberry Pi display LuckFox Core3566 3D Display Wireless AW CB375N 2.4G/5GHz Dual Band WiFi5 Wireless module RTL8822CE CG Bluetooth 5.0 ESP32-S3 GEEK 5inch Milk-V Duo User Guide Sipeed NanoCluster Mini Cluster Board mini data center For Raspberry Pi CM45 / Computer /LM3H /M4N Raspberry Pi 5 Argon-NEO-M.2-NVME-PCIE-Expansion-Board Only For Argon NEO 5 Case (Not include) DeepSeek AI Voice Chat Camera Robot BOX ESP32-S3 Development Board 2 inch LCD N16R8 Touchscreen Display Camera 2.66inch e-Paper e-link Module 360x184 4-Color Red Yellow Black White For Arduino Raspberry Pi STM32 Jetson Tutorial Information Wiki Program Code User Guide SpotPear Code ESP32 ST7789 tutorial Jetson-nano-to-boot-the-system User Guide DeepSeek AI Voice Chat ESP32 C6 Development Board 1.69 inch LCD Display 240x280 1.69inch TouchScreen Programmable Watch MPS2280 POE Raspberry Pi 5 PCIe to M.2 NVMe SSD Adapter Board HAT Pi5 2280/2242/2230