Koenkk / zigbee2mqtt

Zigbee 🐝 to MQTT bridge πŸŒ‰, get rid of your proprietary Zigbee bridges πŸ”¨
https://www.zigbee2mqtt.io
GNU General Public License v3.0
11.76k stars 1.64k forks source link

NodOn SIN-4-RS-20 state note updated #18412

Open jiquem opened 1 year ago

jiquem commented 1 year ago

What happened?

The status (OPEN, CLOSE, STOP) of my roller shutter module NodOn SIN-4-RS-20 is not updated very regularly in Home Assistant. From time to time it's updated, and from time to time it isn't. I have to go into zigbee2mqtt to perform a manual refresh.

What did you expect to happen?

State to be updated like for others devices

How to reproduce it (minimal and precise)

No response

Zigbee2MQTT version

1.32.1

Adapter firmware version

20221226

Adapter

zStack3x0

Debug log

No response

Wireheadbe commented 1 year ago

Have the same issue. Manually changing reporting settings fixes this for a while, or powercycling them. Possible firmware issue @AlexisPolegato ? (There's a newer firmware posted to the OTA repo a couple weeks back, but trying to install it, gives an error Update of 'SaJefRolluik' failed (No image available for imageType '265'))

jiquem commented 1 year ago

Thanks @Wireheadbe Which reporting setting do you change ?

Grandma-Betty commented 1 year ago

Same issue here, but for a different NodOn device, NodOn SIN-4-1-20 in my case. It gives me the following errors when trying to update the firmware via Z2M OTA:

Update of 'NodOn_SIN-4-1-20_01' failed (Timeout: device did not request any image blocks)
Update of 'NodOn_SIN-4-1-20_01' failed (No image available for imageType '266')
jiquem commented 1 year ago

I've got this message after updating z2m to 1.32.2

Info 2023-08-02 14:01:12MQTT publish: topic 'zigbee2mqtt/cover_cuisine', payload '{"last_seen":1690977522426,"linkquality":72,"position":100,"state":"OPEN","tilt":0,"update":{"installed_version":523,"latest_version":541,"state":"available"},"update_available":null}'
Info 2023-08-02 14:01:12MQTT publish: topic 'zigbee2mqtt/bridge/response/device/ota_update/update', payload '{"data":{"id":"cover_cuisine"},"error":"Update of 'cover_cuisine' failed (Timeout: device did not request any image blocks)","status":"error","transaction":"n3pzs-1"}'
Error 2023-08-02 14:01:12Update of 'cover_cuisine' failed (Timeout: device did not request any image blocks
github-actions[bot] commented 1 year ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days

jiquem commented 1 year ago

Still the same behavior with the 1.33

trollix commented 11 months ago

Idem for me, update failed again in 1.33-1 screenshot_1501

Grandma-Betty commented 11 months ago

For those who are not aware: NodOn has released an Android/iOS app for device firmware upgrades: https://nodon.fr/en/nodon-connect-application/ I have just tested this now and the Android application says that my NodOn device's firmware is up to date, despite the fact that it still shows up as updateable in Z2M. This either means that updating the firmware via Z2M was successful but Z2M still wrongly reports the device as updateable or there is no firmware update available at all and Z2M is reporting it wrongly as updateable. Either way, it seems that Z2M is showing up NodOn devies as updateable even when there is no firmware update available, for whatever reason. Could that be possible @Koenkk?

Koenkk commented 11 months ago

Some improvements have been pushed regarding the OTA update mechanism, please check if this issue is fixed now. (https://www.zigbee2mqtt.io/advanced/more/switch-to-dev-branch.html)

jiquem commented 11 months ago

Hello, I've just tested on HA with 1.33.1-dev commit: [9cff19b] and got the same error

Wireheadbe commented 10 months ago

Have the same issue. Manually changing reporting settings fixes this for a while, or powercycling them. Possible firmware issue @AlexisPolegato ? (There's a newer firmware posted to the OTA repo a couple weeks back, but trying to install it, gives an error Update of 'SaJefRolluik' failed (No image available for imageType '265'))

No updates from NodOn. States not updated a lot of times (covers open, but reported closed, unless forcing a position refresh, which i now do as work-around every 5 minutes...). Sometimes, in the middle of the night, they go up a bit and down again. No idea why. Instant wake-up..

Firmware updates don't work, even though someone from the company actively posts firmware to the repo. Can't recommend these modules. Had hoped this would be a quality brand...

AlexisPolegato commented 10 months ago

Hello @Wireheadbe ,

This should be fixed in the latest version of the device firmware.

Unfortunately, there's an issue in the mechanism of firmware update in Z2M, it can work if you try several times but it's quite random. Alternatively, you could try to update your products through the NodOn Connect Application (available on your Android/iOS).

Wireheadbe commented 10 months ago

Hi @AlexisPolegato - thanks for coming back.

However, on my Moto G100 running Android 12, the app crashes when trying to upgrade. On my wife's A52s, the app isn't available since NodOn Connect isn't compatible with Android 13. Thus, no dice to be able to upgrade.

Why would the firmware upgrade fail - because I've updated numerous devices from e.g. Philips, Ikea,... Would you mind sharing tips/tricks? I've noticed in the app, that the modules disappear after a while. So i did reconnect a module to the mains before trying to upgrade: app still crashes on my phone, and the upgrade doesn't work via Z2M as well. Do I have faulty modules?

aurel32 commented 10 months ago

Alternatively, you could try to update your products through the NodOn Connect Application (available on your Android/iOS).

Is there some documentation available about that application? I have tried to get it working with my SIN-4-RS-20 devices, and the application does not find any devices. I have tried to powercycle them, but it doesn't work either.

AlexisPolegato commented 10 months ago

Hi @AlexisPolegato - thanks for coming back.

However, on my Moto G100 running Android 12, the app crashes when trying to upgrade. On my wife's A52s, the app isn't available since NodOn Connect isn't compatible with Android 13. Thus, no dice to be able to upgrade.

Why would the firmware upgrade fail - because I've updated numerous devices from e.g. Philips, Ikea,... Would you mind sharing tips/tricks? I've noticed in the app, that the modules disappear after a while. So i did reconnect a module to the mains before trying to upgrade: app still crashes on my phone, and the upgrade doesn't work via Z2M as well. Do I have faulty modules?

There are 2 Firmwares in the Device. The Device asks an update on a certain Firmware and the Gateway should answer with this Firmware. But Zigbee2Mqtt does not currently handle that, so when the device asks a certain Firmware, the Gateway does not answer with the right Firmware and the Update does not happen...

AlexisPolegato commented 10 months ago

Alternatively, you could try to update your products through the NodOn Connect Application (available on your Android/iOS).

Is there some documentation available about that application? I have tried to get it working with my SIN-4-RS-20 devices, and the application does not find any devices. I have tried to powercycle them, but it doesn't work either.

Here but it's in French: https://nodon.fr/nodon/application-nodon-connect/

When you power cycle the device, it does not appear in the App ?

Wireheadbe commented 10 months ago

There are 2 Firmwares in the Device. The Device asks an update on a certain Firmware and the Gateway should answer with this Firmware. But Zigbee2Mqtt does not currently handle that, so when the device asks a certain Firmware, the Gateway does not answer with the right Firmware and the Update does not happen...

Hi @AlexisPolegato - thanks for the info. Any way we can work together with @Koenkk if you provide some more technical details to this mechanism you have implemented?

(would appreciate a fix on Android 12 and a build for Android 13 as well πŸ˜‰ )

Edit: was able to update one to 2.31.0-1.1.2 via an iPad I loaned. At first, everything was fine (except my hardware switch was suddenly reversed.. quickly fixed by rotating in the frame.. πŸ˜„ ), however, this evening, after the covers were closed, the state wasn't updated automatically. I had to poll it again manually. (I did do a calibration today, related?)

AlexisPolegato commented 9 months ago

@Wireheadbe What do you mean exaclty by "the state wasn't updated automatically" ? You changed the state locally (from the Switch ?) or from Z2M ? And you didn't get the right status back ?

If you check the logs, you don't see any reports ? Something like that:

Info 2023-11-21 16:03:12MQTT publish: topic 'zigbee2mqtt/SIN-4-RS-20', payload '{"linkquality":76,"position":0,"state":"OPEN","tilt":100,"update":{"installed_version":543,"latest_version":543,"state":"idle"},"update_available":null}'

dgseten commented 9 months ago

Hi @AlexisPolegato , I have installed few of ADEO SIN-4-RS-20_LEX and I love them, one of them is working fine but in the rest of them I am seeing the issue explained in this page. I guess that the issue is the same.

I think the product is the same than this NodOn SIN-4-RS-20 and Nodon is the real manufacturer of this product, but OTA updates are not supporthed neither. It would be fantastic to have ota updates also for these devices.

I just check with the Nodon Connect app, but there are not options to update the version of this product. Could you help us?

Screenshot (27 nov
aurel32 commented 9 months ago

Alternatively, you could try to update your products through the NodOn Connect Application (available on your Android/iOS).

Is there some documentation available about that application? I have tried to get it working with my SIN-4-RS-20 devices, and the application does not find any devices. I have tried to powercycle them, but it doesn't work either.

Here but it's in French: https://nodon.fr/nodon/application-nodon-connect/

When you power cycle the device, it does not appear in the App ?

No it didn't work. But I have found the issue. I was trying from an Android 13 device. When I tried from an old phone running IIRC Android 11, the device got discovered, and I was able to upgrade the firmware. The upgrade went fine, the only issue I have noticed is that the up and down switch inputs got swapped in the new firmware, so I had to rewire it.

Wireheadbe commented 7 months ago

Worked fine for a while on the newest firmware, but sadly, at some point, they stop reporting the status of the shutter (e.g. trigger shutter close, they do the actuation, but they do not report back the position (in this case, closed)) - need to manually refresh.

Balooforever commented 7 months ago

Worked fine for a while on the newest firmware, but sadly, at some point, they stop reporting the status of the shutter (e.g. trigger shutter close, they do the actuation, but they do not report back the position (in this case, closed)) - need to manually refresh.

Same for me. I don’t know if the update state is on z2m or on module.. With my Old module in a very old firmware, all work fine ..

cedricbarbecue commented 7 months ago

@Wireheadbe same behaviour but I use the z2m report apply option on z2m interface on my nodon module and everything was then corrected.

Wireheadbe commented 7 months ago

@Wireheadbe same behaviour but I use the z2m report apply option on z2m interface on my nodon module and everything was then corrected.

That works for a while, but then at some point it stops again..I've even factory-reset them, on the latest firmware, and re-paired them. Nothing helps. I have heaps of zigbee devices, and these are the only ones I have headaches with. Even at night, sometimes, it'll just open a shutter for a bit, and close it again. Like it's doing some form of calibration... But then wakes you! I've reverted to a node-red flow, which force-refreshes the status of Nodon devices every 5 minutes.

dguihal commented 6 months ago

OK got a "fix" (probably more a workaround) for this

  1. Get to your device in z2m interface
  2. Get to "Reporting" Tab
  3. Remove everything where attribute is related to "TiltPercentage" (I sometime got 2 here ...). Goal is to keep only one "currentPositionLiftPercentage"

And that's it, my device magically started to report correctly again

I still don't get why this "Tilt" feature has been added to this device as there is no physical tilt connectors in it. You may want to control some tilt with the regular lift output but you certainly can't have both and this looks like the source of all of this trouble

Wireheadbe commented 6 months ago

This only works for a while. At some point, the device will again stop reporting, unfortunately.

AlexisPolegato commented 6 months ago

@Wireheadbe How long would you say before reporting stops ?

Wireheadbe commented 6 months ago

Hi @AlexisPolegato - many thanks for coming back. Happy to help with whatever question you might have. It depends. Sometimes it's a week, sometimes it can take multiple weeks.

Power-cycling the module usually fixes it.. Altough, as you can see, workarounds work for "some" time as well.

cweber26 commented 6 months ago

Hello, I think the issue is not exclusively linked to the NodOn module. Because I was had the same issue with one of my Proxalus cover motor which have a zigbee 3 embedded It solve the issue by clicking on the button Apply button of the Reporting tab of the cover on Z2M. And as I said in a previous comment I also had the same issue and workaround with the live power consommation info on a connected plug.

cweber26 commented 6 months ago

@Wireheadbe can you share us the command to do the refresh by an automation ? Thanks

jiquem commented 6 months ago

Hello I have 3 covers. I put in place an ugly automation to update the reporting parameters every hour. This workaround prevent me to face reporting issues.

alias: "[ADMIN] Reporting cover"
description: ""
trigger:
  - platform: time_pattern
    hours: "*"
    minutes: "0"
    seconds: "0"
condition: []
action:
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_salon/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_salon/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_sejour/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_sejour/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_cuisine/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_cuisine/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
mode: single
Wireheadbe commented 6 months ago

@Wireheadbe can you share us the command to do the refresh by an automation ? Thanks

Hi, I'm using Node-Red for this.. I basically make sure to save the MQTT output of zigbee2mqtt/bridge/devices in a global var (eek! global vars! - I know πŸ˜† )

let devices = msg.payload;
global.set('devices',devices);

And then via a timer, every 5 minutes, I retrieve what's stored in the global var:

msg.payload = global.get('devices')
return msg;

I then pass that on to a "split" node, which splits using "\n"

And then I send that output to another function node:

if ( msg.payload.definition != null) {
    let model = msg.payload.definition.model;
    let name = msg.payload.friendly_name;

    if (model === "SIN-4-RS-20") {
        msg.topic = "zigbee2mqtt/" + name + '/get' ;
        msg.payload = {
            "position": ""
        }
        return msg;
    }
}

Which then sends that back to MQTT - by searching for every device occurence of "SIN-4-RS-20" and sending a payload to force-get the position.

lieblinger commented 6 months ago

@Wireheadbe Could you share your Node-RED flow? I'm facing the same issue and it's really annoying.

Thanks in advance!

cweber26 commented 5 months ago

Hello I have 3 covers. I put in place an ugly automation to update the reporting parameters every hour. This workaround prevent me to face reporting issues.

alias: "[ADMIN] Reporting cover"
description: ""
trigger:
  - platform: time_pattern
    hours: "*"
    minutes: "0"
    seconds: "0"
condition: []
action:
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_salon/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_salon/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_sejour/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_sejour/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_cuisine/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_cuisine/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
mode: single

Thanks that exactly what I needed. I've just create the automation and run it, I see on Z2M that the reporting configuration is ok. I think that a pretty good workaround.

EderlMarkus commented 3 months ago

Hello I have 3 covers. I put in place an ugly automation to update the reporting parameters every hour. This workaround prevent me to face reporting issues.

alias: "[ADMIN] Reporting cover"
description: ""
trigger:
  - platform: time_pattern
    hours: "*"
    minutes: "0"
    seconds: "0"
condition: []
action:
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_salon/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_salon/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_sejour/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_sejour/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionTiltPercentage","cluster":"closuresWindowCovering","id":"cover_cuisine/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
  - service: mqtt.publish
    data:
      payload: >-
        {"attribute":"currentPositionLiftPercentage","cluster":"closuresWindowCovering","id":"cover_cuisine/1","maximum_report_interval":60,"minimum_report_interval":1,"reportable_change":1}
      topic: zigbee2mqtt/bridge/request/device/configure_reporting
mode: single

I also have the same problem, I've got 10 SIN-4-RS-20 and I've tried the workaroud, although I'm trying mine in Node-Red: flows.json

But still, theres always 1 or 2 that simply stop reporting their position from one day to the next. Still a sustainable solution would make my day :D

Is there anything I could take a look at in the Source Code or are there any logs i can provide that could help?