Rule updating state but not switching device

I am using openhab3 and zigbee2mqtt to connect my devices. I have added a plug and I can switch it on/off from “devices” without problems.
But now I have started playing with rules, and the rule is updating switch status on web, but the device isn’t switched on.
I suppose the error is in the rule I generated using the UI, the code is

triggers:
  - id: "1"
    configuration:
      cronExpression: 0/3 * * * * ? *
    type: timer.GenericCronTrigger
conditions: []
actions:
  - inputs: {}
    id: "2"
    configuration:
      itemName: endoll5_state
      state: ON
    type: core.ItemStateUpdateAction

To affect a device, send commands.
It’s a fairly important distinction to learn in openHAB
command “Do something”
state “This is the way it is”

You are right, I thought I was sending the command to change state. Now it works.

Thanks a lot

1 Like