10-05-2024, 04:46 AM
(10-05-2024, 12:45 AM)admin Wrote: sorry, i don't know the "WP3082ADAM". maybe you can use USB-RS485 adapter to test firstly. when you send command manually and check whether have feedback. if OK, then test with ESPHome.
Hey I just realised I was reading the schematic incorrectly.
The correct GPIO pins for RS485 on A6 are described here:
https://devices.esphome.io/devices/KinCony-KC868-A6
In case this is helpful for anyone else, I now have RS485 working on A6 using following ESPHome config:
Code:
uart:
- id: rs485
tx_pin: GPIO27
rx_pin: GPIO14
baud_rate: 9600
- id: rs232
tx_pin: GPIO17
rx_pin: GPIO16
baud_rate: 9600
modbus:
id: modbus1
uart_id: rs485
send_wait_time: 200ms
modbus_controller:
- id: wp3082adam1
address: 1
modbus_id: modbus1
update_interval: 2s
Now receiving data correctly in ESPHome:
[14:15:20][D][text_sensor:064]: 'analoginputs': Sending state '00000000000000000334'