rLink 2 Channel RS485 / Parallel Relay Module

£4.99
VAT excluded

https://forum.hobbycomponents.com/viewtopic.php?f=139&t=3188The rLink 2-Channel Relay Module is an addressable relay module designed for reliable control of loads over an RS485 bus. Using the rLink register-based protocol, multiple relay modules can be controlled from a single master device on a shared bus.

Quantity

Image

The rLink 2-Channel Relay Module is an addressable relay module designed for reliable control of loads over an RS485 bus. Using the rLink register-based protocol, multiple relay modules can be controlled from a single master device on a shared bus.

Each module provides two independent relay outputs, making it suitable for switching lights, pumps, motors, solenoids, and other loads in automation and control applications.

Communication is handled via RS485, offering excellent noise immunity and long cable runs of up to 1200 meters. The protocol is based on standard UART-style serial communication, making it straightforward to integrate with microcontrollers, USB-to-RS485 adapters, PLCs, and embedded systems.

By using a ¼ load RS485 transceiver, up to 128 devices can be connected to a single bus. Device address, baud rate, and relay behaviour can be configured via protocol commands and are stored in non-volatile memory. Optionally, the relays can be configured to automatically turn off after a programmable amount of time allowing for fail safe operation.

Although the module is designed for remote operation, it has a physical interface to allow the relays to be controlled locally like a standard parallel relay module.

PLEASE NOTE: To control the module using a microcontroller such as a Raspberry Pi or Arduino you will need an RS485 adapter to interface the microcontrollers GPIO interface to the RS485 bus. We recommend our RS485 transceiver which is compatible with both 3.3V and 5V microcontrollers:

https://hobbycomponents.com/our-brand-exclusives/1229-hobby-components-rs485-transceiver


For Arduino and Raspberry Pi users, we provide a library (for Arduino) or a Python module (for Raspberry Pi) that allows easy control of rLink modules without needing to worry about the low-level protocol. In both cases, the library/module communicates with one or more modules via a serial UART interface, using a suitable serial-to-RS485 adapter (see SKU: HCMODU0270).


Image


Key Features

  • 2 independent relay outputs

  • RS485 bus interface

  • UART-style serial protocol

  • Up to 128 addressable devices on a shared bus

  • Configurable baud rate

  • Register-based control protocol

  • Optional timed relay operation

  • Non-volatile configuration storage
     

  •  

  • Specification

  • Module code: HCMODU0281 (2ch relay module)

  • Supply Voltage (VDD): 4.5V to 5.5V

  • Current consumption (relay(s) off): 5.5mA

  • Current consumption (relay(s) on): 125mA

  • Interfaces: RS485, relay digital input(s), NO-COM-NC relay screw terminals.

  • I2C Interface speed: 9600bits/s (default), 115200bits/s (max)

  • I2C default address (HEX): 0h02

  • RS485 bus impedance: 120 Ohms

  • Relay input low level voltage: 0V to 1.5V 

  • Relay input high level voltage: 3.5V to 5V

  • Relay input pulldown resistor: 100K

  • Relay contact rating (resistive load): 5A max at 28VDC or 240VAC

  • Maximum number of modules: 128 per bus

  • Module dimensions: 59mm x 38mm x 19.2mm




Image


Image

 

Toggle Relay Example:

Repeatedly turns relay 0 on and off every 5 seconds

 

#include <SoftwareSerial.h>
#include "rLink.h"
 
#define RX_PIN   2
#define TX_PIN   3
#define DIR_PIN  4
#define RLY_ADD  0x02
 
// Create SoftwareSerial instance
SoftwareSerial softserial(RX_PIN, TX_PIN); // RX, TX
 
// Create rLink bus using SoftwareSerial
 
rLink rlink(softserial, DIR_PIN);
 
// Create relay module at address 2 and attach to the rLink bus
rLinkRelay2CH relay(rlink, RLY_ADD);
 
 
void setup()
{
  // Start the software serial interface
  softserial.begin(9600);
 
  // Initialise rLink library.
  rlink.init();
}
 
void loop()
{
  // Turn the relay on
  relay.setRelay(0, true);
  delay(5000);
  // Turn the relay off
  relay.setRelay(0, false);
  delay(5000);
}





Image


Image
 

 

Toggle Relay Example:

Repeatedly turns relay 0 on and off every 5 seconds

 

import time
import rlink
from rlink.bus import RLinkBus
from rlink.relay2ch import Relay2Ch
 
# ===============================
# Configuration
# ===============================
SERIAL_PORT = "/dev/serial0"
DIR_PIN     = 18
RELAY_ADDR  = 0x02
 
 
# ===============================
# Initialise bus and relay module
# ===============================
bus = RLinkBus(SERIAL_PORT, DIR_PIN, Relay2Ch.BAUD_9600)
relay = Relay2Ch(bus, RELAY_ADDR)
 
 
print("Toggling relay 0 every 5 seconds")
 
while True:
    success = relay.setRelayConfirm(0, True)
    print(f"Relay 0 state: {'ON' if success else 'UNKNOWN!'}")
 
    time.sleep(5)
   
    success = relay.setRelayConfirm(0, False)
    print(f"Relay 0 state: {'OFF' if success else 'UNKNOWN!'}")
   
    time.sleep(5)



  

For more information, including example Arduino sketches please see our support forum here

HCMODU0281
10 Items

Specific References