Changes

Jump to navigation Jump to search
3,646 bytes added ,  19:35, 7 December 2021
added Modbus protocol and default configuration
Line 1: Line 1:  +
[[File:HHC-N8I8OP_Stock_Photo_Top.jpg|thumb|top view]]
 +
 +
[[File:HHC-N8I8OP_Stock_Photo_Front.jpg|thumb|front view]]
 +
 +
[[File:HHC-N8I8OP_Stock_Photo_Back.jpg|thumb|back view]]
 +
 +
[[File:HHC-N8I8OP_Stock_Photo_Bottom.jpg|thumb|bottom view]]
 +
 
== Overview ==
 
== Overview ==
   Line 6: Line 14:     
There is Chinese software to configure the MAC address, IP address, Modbus baud-rate, etc.
 
There is Chinese software to configure the MAC address, IP address, Modbus baud-rate, etc.
 +
 +
== Configuration ==
 +
 +
{| class="wikitable"
 +
! Setting
 +
! Default Value
 +
|-
 +
| Mode
 +
| TCP Service
 +
|-
 +
| Destination Port
 +
| 5000
 +
|-
 +
| Local Port
 +
| 5000
 +
|-
 +
| Implementer Name
 +
| HHC-N8I8OP
 +
|-
 +
| Input Mode
 +
| Ordinary
 +
|-
 +
| Automatic acquisition of IP
 +
| off
 +
|-
 +
| Power-off preservation
 +
| off
 +
|-
 +
| Local IP
 +
| 192.168.0.105
 +
|-
 +
| Subnet Mask
 +
| 255.255.255.0
 +
|-
 +
| Gateway
 +
| 192.168.0.1
 +
|-
 +
| Destination IP
 +
| 192.168.0.101
 +
|-
 +
| MAC Address
 +
| 485300575500
 +
|-
 +
| Domain Name
 +
|
 +
|-
 +
| Serial Baud Rate
 +
| 9600
 +
|-
 +
| Serial Parity
 +
| none
 +
|-
 +
| Serial Data Bits
 +
| 8
 +
|-
 +
| Serial Stop Bits
 +
| 1
 +
|-
 +
| Modbus TCP
 +
| off
 +
|-
 +
| Heartbeat Time Interval
 +
| 0 seconds
 +
|-
 +
| Heartbeat Content
 +
| HHC-N8I8OP
 +
|-
 +
| Heartbeat Detection Time
 +
| 0 seconds
 +
|-
 +
| Boot Firmware Version:
 +
| HHC-N8O8OP-V1.2-V00002
 +
|-
 +
| App Firmware Version:
 +
| 20201231-VS0003
 +
|}
 +
 +
== Modbus ==
 +
 +
=== Modbus TCP ===
 +
 +
By default the device has a simplistic non-Modbus plaintext "console style" protocol for querying the device. If you enable Modbus TCP mode via the configuration software, you can connect (using the same port) with Modbus TCP capable software.
 +
 +
=== Coils ===
 +
 +
The table below applies to the following Modbus function codes:
 +
 +
* Function 01: Read Coils
 +
* Function 05: Write Single Coil
 +
 +
The following appears to be unsupported:
 +
 +
* Function 15: Write Multiple Coils
 +
 +
{| class="wikitable"
 +
! Address (dec)
 +
! Description
 +
|-
 +
| 16
 +
| Relay #1
 +
|-
 +
| 17
 +
| Relay #2
 +
|-
 +
| 18
 +
| Relay #3
 +
|-
 +
| 19
 +
| Relay #4
 +
|-
 +
| 20
 +
| Relay #5
 +
|-
 +
| 21
 +
| Relay #6
 +
|-
 +
| 22
 +
| Relay #7
 +
|-
 +
| 23
 +
| Relay #8
 +
|}
 +
 +
Attempting to read addresses 0-15 or 24-128 will not give a response. Reading addresses 16-23 is known to work, though it's possible there are more valid ranges further out in the address space.
 +
 +
Attempting to write addresses 256-280 will not give a response. Writing addresses 0-255 are known to work, but only the range 16-23 has an understood purpose at the moment.
 +
 +
=== Discrete Inputs ===
 +
 +
* Function 02: Read Discrete Inputs
 +
 +
{| class="wikitable"
 +
! Address (dec)
 +
! Description
 +
|-
 +
| 32
 +
| Input #1
 +
|-
 +
| 33
 +
| Input #2
 +
|-
 +
| 34
 +
| Input #3
 +
|-
 +
| 35
 +
| Input #4
 +
|-
 +
| 36
 +
| Input #5
 +
|-
 +
| 37
 +
| Input #6
 +
|-
 +
| 38
 +
| Input #7
 +
|-
 +
| 39
 +
| Input #8
 +
|}
 +
 +
The value returned is whether or not a logic high (+5V) is present on the input. The "+5V" and "COM" (GND / 0V) pins must be powered externally.
 +
 +
NOTE: A pulse (to +5V) on Input #9 is an override to turn all relays on along with a red LED, until a pulse (to +5V) on Input #10 turns them all off.
 +
 +
Attempting to read addresses 0-31 or 256-999 will not give a response. Reading addresses 32-255 is known to work, though it's possible there are more valid ranges further out in the address space.
 +
 +
=== Holding Registers ===
 +
 +
* Function 03: Read Holding Registers
 +
* Function 06: Write Single Register
 +
* Function 16: Write Multiple Registers
 +
 +
Attempting to read addresses 0-330 doesn't work, but more of the address space will need to be explored.
 +
 +
Attempting to write addresses 0-140 doesn't work, but more of the address space will need to be explored.
 +
 +
=== Input Registers ===
 +
 +
* Function 04: Read Input Registers
 +
 +
Attempting to read addresses 0-140 doesn't work, but more of the address space will need to be explored.
    
== Factory Reset Button ==
 
== Factory Reset Button ==
Line 83: Line 272:     
[https://www.amazon.com/dp/B083KK3CZL Amazon.com: Walfront 8 Channel Network Relay Module Remote Control Relay Device Ethernet to RS485, TCP Relay Module: Home & Kitchen]
 
[https://www.amazon.com/dp/B083KK3CZL Amazon.com: Walfront 8 Channel Network Relay Module Remote Control Relay Device Ethernet to RS485, TCP Relay Module: Home & Kitchen]
 +
 +
[https://www.ebay.com/itm/283585060271 HHC-N8I8OP 8 Network TCP Relay Module Remote Control Relay Device DC7~24V | eBay] (source for photos)
    
[https://www.aliexpress.com/i/4000127882795.html 8 way network relay RS485 to Ethernet switch controller MODBUS TCP IP relay|Relays| - AliExpress]
 
[https://www.aliexpress.com/i/4000127882795.html 8 way network relay RS485 to Ethernet switch controller MODBUS TCP IP relay|Relays| - AliExpress]
Line 92: Line 283:  
[https://www.chinese-forums.com/forums/topic/58422-need-help-with-baidu-wangpan/ Need help with Baidu Wangpan - Chinese Computing and Electronics - Chinese-forums.com]
 
[https://www.chinese-forums.com/forums/topic/58422-need-help-with-baidu-wangpan/ Need help with Baidu Wangpan - Chinese Computing and Electronics - Chinese-forums.com]
   −
[https://github.com/natm/iocontrollergw natm/iocontrollergw: I/O Controller Gateway]
+
[https://github.com/natm/iocontrollergw natm/iocontrollergw: I/O Controller Gateway | GitHub]
    
[https://gitlab.com/sigmundk/hhc-n-8i8o-relais-board Sigmund Kreuzer / HHC-N-8I8O Relais board · GitLab]
 
[https://gitlab.com/sigmundk/hhc-n-8i8o-relais-board Sigmund Kreuzer / HHC-N-8I8O Relais board · GitLab]
 +
 +
[https://github.com/gabrielgbs97/hhc_n8i8op_mqtt gabrielgbs97/hhc_n8i8op_mqtt | GitHub]

Navigation menu