Posts: 6,323
Threads: 808
Joined: Oct 2020
Reputation:
155
not need add others, just let your 10pcs of E16S board all connect to router by network cable in local network.
Posts: 6,323
Threads: 808
Joined: Oct 2020
Reputation:
155
08-01-2024, 12:46 AM
(This post was last modified: 08-01-2024, 12:46 AM by admin.)
How can I toggle E16S relays from digital inputs on different E16S boards? There are two solution:
A. download KCS firmware, then create IFTTT command, let controller A's digital input trigger controller B's Relay by network custom protocol or RS485 command. if you also want use home assistant, let KC868-E16S integrate to home assistant by MQTT.
B. let your all controller integrate to Node-Red by MQTT. Then you can config any controller's INPUT trigger any controller's OUTPUT. this way just use Node-Red as a bridge.
solution A is let two controller work directly without any other software.
Posts: 4
Threads: 1
Joined: Mar 2023
Reputation:
0
Hi admin,
I'm having a hard time to integrate the E16S ESP devices and MQTT.
How do I code the yaml files for the e16s to establish MQTT topics for each momentary switch to toggle the outputs?
Regards,
Keith
Posts: 4
Threads: 1
Joined: Mar 2023
Reputation:
0
Thanks for the reply and example yaml.
I wish to use MQTT within Home Assistant. Ideally, I wish to leverage Node-Red as a bridge and use the ESPHome In and Out (recognizes all E16S devices and entities), and MQTT input and output nodes to manage the switches and relays of the E16S boards (there will be 6 when I finish this home automation setup).
The A8S code you shared doesn't reflect the gpio platform code lines for the outputs of the E16S. Should I add as follows;
switch:
- platform: gpio
name: "e16s-output16"
pin:
pcf8574: pcf8574_hub_out_2
number: 7
mode: OUTPUT
inverted: true
unique_id: kc868-e16s-output-16
state_topic: 'KC868_E16S/08F9E08B1F58/STATE'
command_topic: 'KC868_E16S/08F9E08B1F58/SET'
payload_on: '{"output1":{"value":true}}'
payload_off: '{"output1":{"value":false}}'
value_template: '{{ value_json.output1.value }}'
state_on: true
state_off: false
How can I add code for the inputs?
binary_sensor:
- platform: gpio
name: "e16s-input1"
pin:
pcf8574: pcf8574_hub_in_1
number: 0
mode: INPUT
inverted: true
Posts: 6,323
Threads: 808
Joined: Oct 2020
Reputation:
155
Yes, your OUTPUT config is correct. INPUT example as these:
binary_sensor:
- name: 'input-1'
unique_id: input-1
state_topic: 'KC868_E16S/08F9E08B1F58/STATE'
value_template: '{{ value_json.input1.value }}'
payload_on: true
payload_off: false