[Node-RED] Contact sensor event-state node missing states

I have some contact sensors that used to work great.
But, for some reason after eWeLink CUBE 2.0.0 update, all them stopped updating states on Node RED, although they work normally on iHost.

image

I can’t remember what options it had before as State, but now it shows only Battery state and I suspect the lack of a “contact” state (opened/closed) causes the component to be useless when used with a contact sensor.

image

As a matter of fact, a temperature sensor I have shows all possible states as expected:

image

node-red-contrib-ewelink-cube version: 1.2.2
eWeLink CUBE version: 2.0.0
Node-RED version: 3.1.10

1 Like

Can you send us your node-red add-on log?
We’ll look into it ASAP.

Sure. How can I extract it?

Just download it from here.

Here it goes.
I don’t believe the Node-RED docker image has any issue.
Maybe it’s a node-red-contrib-ewelink-cube problem.

20e396e3-6724-4d33-baf6-af73a99faec3.zip (5.6 MB)

I’ve also discovered that Homebridge with eWeLink CUBE plugin (homebridge-plugin-ewelink-cube) isn’t receiving contact sensor states either.

It’s log has:

[6/25/2024, 4:14:07 PM] [homebridge-plugin-ewelink-cube] This plugin generated a warning from the characteristic 'Contact Sensor State': characteristic value expected valid finite number and received "NaN" (number). See https://homebridge.io/w/JtMGR for more info.

1 Like

What’s the model of your contact sensor?
We’ll see if is a compatibility issue.

It’s a Aqara Door/Window ZigBee Sensor MCCGQ11LM.

It’s working fine in iHost, right?
We’ve checked.
The result is this device used new capability which is not supported by node-red plugin yet.
We’ll support it in next version of node-red-contrib-ewelink-cube.

1 Like

Yes, it works fine on iHost.

It’s no longer working on both homebridge and node-red eWeLink plugins.

Thank you for your feedback.

when can we expect an update?

I’m also really interested in this.
Unfortunately all my contact sensor are useless outside iHost, where all my automations run.

@ward do you have any information about the ihost update and the node-red ewelink cube add-on?

iHost generally has monthly updates, while add-ons will depend.

Just to add what I found –

I was starting to do some NR with a couple of spare contact sensors when in the debug noticed that some do not report ‘detect’ – it is not even a capability – but not every sensor suffers the same!

The sensors report correctly in the ihost dashboard.

When can we expect the expansion?

@SuiKa Do we have a vague timeline for this? Or it needs more time?

We’ll fix it at the end of next month.

1 Like

Oh, so these unfortunate people are F-ed for two months, basically. That’s not something responsible business would do.

Out of sheer curiosity then: how can people bring back the old firmware and run it as a temporary solution, till a new firmware is pushed out?

Seriously guys, telling people that their smart home is out of order for 1/6th of a year on top of all problems the CUBE has been giving so far is ludicrous.

Hotfix! Does it ring any bells anywhere…?

Cheers…

2 Likes

iHost API there is no state object for contact Sensor
/open-api/v1/rest/devices/status

{
        "serial_number": "***",
        "name": "test",
        "manufacturer": "eWeLink",
        "model": "DS01",
        "firmware_version": "0.5",
        "display_category": "contactSensor",
        "capabilities": [
          {
            "capability": "battery",
            "permission": "read"
          },
          {
            "capability": "rssi",
            "permission": "read"
          }
        ],
        "protocol": "zigbee",
        "app_name": null,
        "state": {
          "battery": {
            "battery": 100,
            "updated_at": 1721225261166
          },
          "rssi": {
            "rssi": -54,
            "updated_at": 1721225261166
          }
        },