Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 105523

Modubs Switch Configuration

$
0
0

Hello Community,

i have a modbus switch topic. :slight_smile:

This is how my switch is configured:

switches:
  - name: "NameOfSwitch"
    unique_id: "UniqueIdSwitch"
    slave: 255
    address: 5608
    write_type: coil
    command_on: 1
    command_off: 0
    scan_interval: 1
    verify:

This Code is working as expected.
But i want to invert on / off

For that i tried:

switches:
  - name: "NameOfSwitch"
    unique_id: "UniqueIdSwitch"
    slave: 255
    address: 5608
    write_type: coil
    command_on: 0
    command_off: 1
    scan_interval: 1
    verify:

is not working

then i tried this:

switches:
  - name: "NameOfSwitch"
    unique_id: "UniqueIdSwitch"
    slave: 255
    address: 5608
    write_type: coil
    command_on: 1
    command_off: 0
    scan_interval: 1
    verify:
      input_type: coil
      address: 5608
      state_on: 0 # Inverted state verification
      state_off: 1

but this is also not working as expected.

My Goal is that in PLC the switch is off an in HA.

Many Thanks for your help

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 105523

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>