AlCalzone / ioBroker.zwave2

Z-Wave for ioBroker. Better. Faster. Stronger.
MIT License
23 stars 13 forks source link

Thermostat receiver SSR303 does not change the BinarySwitch and ThermostatMode states #1012

Open sucesor opened 1 year ago

sucesor commented 1 year ago

Versions:

The states of BinarySwitch and ThermostatMode did not change in ioBroker when the device changes its state. https://products.z-wavealliance.org/products/1618

Device:

Logfile of an interview: zwavejs_2023-06-19.log

AlCalzone commented 1 year ago

This device does not support Associations, so it is unable to report the changed state on its own. It has to be polled regularly for its state to get updated. Since that is only necessary for a handful of legacy devices and can have severe negative influences on a Z-Wave network if not done correctly, iobroker.zwave2 does not poll on its own. You can use the javascript adapter however to do this, e.g. to poll those two states every minute:

// Poll every minute, see https://github.com/ioBroker/ioBroker.javascript/blob/master/docs/en/javascript.md#time-schedule for details
schedule("* * * * *", () => {
  sendTo(
    "zwave2.0",
    "sendCommand",
    {
      nodeId: 2, // The target node
      commandClass: "Binary Switch", // Which command class to use
      command: "get", // Which command should be sent
    },
    ({ error, result }) => {
      //
    }
  );

  sendTo(
    "zwave2.0",
    "sendCommand",
    {
      nodeId: 2, // The target node
      commandClass: "Thermostat Mode", // Which command class to use
      command: "get", // Which command should be sent
    },
    ({ error, result }) => {
      //
    }
  );
});