psamulat
(Peter Samulat)
March 9, 2023, 7:01pm
1
Hi,
using a Win7-based MODBUS test software the NT18B07 module is working fine with address 9. Connected to HA there is no response. So the question is: while sensor SDM530_1_Ph1_Power ist working fine, sensor Temp_Ch0 is not responding. Maybe a configuration mistake? Is there any experience using this temperature module with HA?
Kind regards,
Peter
# MODBUS serial connection
modbus:
- name: MODBUS1
type: serial
baudrate: 9600
bytesize: 8
method: rtu
parity: N
port: /dev/ttyUSB0
stopbits: 1
delay: 5
timeout: 5
sensors:
- name: SDM530_1_Ph1_Power
unique_id: SDM530S1A12
slave: 1
address: 12
input_type: input
count: 2
precision: 2
data_type: float32
unit_of_measurement: W
device_class: power
- name: Temp_Ch0
unique_id: Temp_Ch0
slave: 9
address: 0
input_type: input
count: 2
scale: 0.1
precision: 2
data_type: float32
unit_of_measurement: °C
device_class: temperature
I’m having trouble too
I have something else on modbus that works
but with nt18b07 I have problems
I’m trying
- name: "Return 2"
scan_interval: 15
address: 5
slave: 3
input_type: input
scales: 0.1
precision: 1
device_class: temperature
unit_of_measurement: "°C"
blbb
July 26, 2024, 11:10pm
3
Hi there any progress on using those rs485 boards?
This is my yaml:
uart:
id: uart_bus
tx_pin: GPIO17
rx_pin: GPIO18
baud_rate: 9600
modbus:
id: modbus1
uart_id: uart_bus
modbus_controller:
- id: modbus_device
address: 0x1 ## address of the Modbus slave device on the bus
modbus_id: modbus1
setup_priority: -10
sensor:
- platform: modbus_controller
modbus_controller_id: modbus_device
id: temp_sensor_1
name: "Temperature Sensor 1"
unit_of_measurement: "°C"
address: 0x0001
register_type: read
value_type: U_WORD
- platform: modbus_controller
modbus_controller_id: modbus_device
id: temp_sensor_2
name: "Temperature Sensor 2"
unit_of_measurement: "°C"
address: 0x0002
register_type: read
value_type: U_WORD
blbb
August 7, 2024, 12:48pm
4
I was able to make it work. It was simpler than I thougth:
uart:
tx_pin: GPIO17
rx_pin: GPIO18
baud_rate: 9600
id: uart_bus
modbus:
id: modbus1
uart_id: uart_bus
modbus_controller:
- id: modbus_device
address: 0x01 # Set to the Modbus address I confirmed works with the RS485 to USB
modbus_id: modbus1
setup_priority: -10
update_interval: 5s # Adjust the polling interval as needed
sensor:
- platform: modbus_controller
modbus_controller_id: modbus_device
id: temp_sensor_1
name: "Temperature Sensor 1"
unit_of_measurement: "°C"
address: 0x0000 # Register address for CH1
register_type: holding # Ensure the correct register type
value_type: U_WORD
filters:
- lambda: if (x > 32767) return (x - 65536) / 10.0; else return x / 10.0;