node-red-contrib-shelly icon indicating copy to clipboard operation
node-red-contrib-shelly copied to clipboard

Shelly HT ERROR: connect EHOSTUNREACH after update

Open ht38f opened this issue 1 year ago • 25 comments

ShellyHT.json

Screenshot 2024-04-01 213130

Shelly HT ERROR: connect EHOSTUNREACH after update. see attached photo and flow

ht38f avatar Apr 02 '24 20:04 ht38f

This Shelly HT https://www.shelly.com/en/products/shop/shelly-plus-h-and-t

ht38f avatar Apr 03 '24 19:04 ht38f

It is still the same issue with 10.21.0

ht38f avatar Apr 06 '24 19:04 ht38f

@ht38f I tested your flow and it works here... can you make sure that the shelly's IP is reachable from where you run node-red?

windkh avatar Apr 07 '24 19:04 windkh

Shelly should be reachable. I did a factory reset, gave it a new static ip based on MAC address in the router. The sensor is mostly disconnected but shows up a few seconds in the router and disappears again. I assume this is to preserve battery

ht38f avatar Apr 07 '24 21:04 ht38f

So why do you get an error if it works here? Hm strange

windkh avatar Apr 07 '24 21:04 windkh

Did you press the inject node while the shelly is sleeping?

windkh avatar Apr 07 '24 21:04 windkh

I tried. Same issue. I now watched the app and waited for it to update.23.19:25 it updated the Shelly app. IMG_0228 IMG_0227

ht38f avatar Apr 07 '24 21:04 ht38f

@ht38f the AxiosError occurs when you inject while the shelly is sleeping. That is ok, as the node can not talk to the shelly in this state. Devices that sleep should be run in "callback" mode. Nevertheless the connect EHOSTUNREACH is strange. Is something logged to the node-red console?

windkh avatar Apr 07 '24 21:04 windkh

Shelly firmware is 20240223-141926/1.2.2-g7c39781

ht38f avatar Apr 07 '24 21:04 ht38f

I am running node red on a Victron Cerbo and have no access to the files :(

ht38f avatar Apr 07 '24 21:04 ht38f

Shelly firmware is 20240223-141926/1.2.2-g7c39781

0240223-141926/1.2.2-g7c39781 is installed on mine

windkh avatar Apr 07 '24 21:04 windkh

So it’s the same. I just received a debug showing data from the sensor! IMG_0229

ht38f avatar Apr 07 '24 21:04 ht38f

Did you set a password?

windkh avatar Apr 07 '24 21:04 windkh

No password

ht38f avatar Apr 07 '24 21:04 ht38f

@ht38f what node-red version and what nodejs version do you use?

windkh avatar Apr 07 '24 21:04 windkh

3.1.5

ht38f avatar Apr 07 '24 21:04 ht38f

do you use different IP Address ranges in your home? what is the IP of the victron device?

windkh avatar Apr 07 '24 21:04 windkh

Think js is v18

ht38f avatar Apr 07 '24 21:04 ht38f

Victron is 192.168.1.138

ht38f avatar Apr 07 '24 21:04 ht38f

Shelly sensor is also in cloud. That’s how I see it updates.

ht38f avatar Apr 07 '24 21:04 ht38f

what happens if you enter the following into the browser http://192.168.1.207/rpc/Shelly.GetStatus

windkh avatar Apr 07 '24 22:04 windkh

I need to check. I am not at the install but working remotely from victron VRM. I tried to connect to 192.168.1.207 earlier today. I did not manage to connect. I believe the device turns on and connects to the router and then goes back to sleep so it is not more visible

ht38f avatar Apr 07 '24 22:04 ht38f

will go to bed now... maybe we should do a teams meeting where you can show it to me.

windkh avatar Apr 07 '24 22:04 windkh

I have been watching the flow and suddenly it says connected and is green. A few seconds after it goes back to ehostunreach

ht38f avatar Apr 07 '24 22:04 ht38f

Have a good night! Thanks for the help!

ht38f avatar Apr 07 '24 22:04 ht38f

@ht38f hi... sorry I forgot to ask if the error is still there or not?

windkh avatar Apr 26 '24 10:04 windkh

Hi. The error is still there. When I try to get the status http://192.168.1.207/rpc/Shelly.GetStatus I get this: The server at 192.168.1.207 is taking too long to respond.

This makes sense as the H&T is only connected to the router a few seconds before it goes back to sleep. All other Shelly devices work normal.

ht38f avatar Apr 26 '24 21:04 ht38f

The shellies that normally sleep like HT or smoke or door/window should not be polled. Instead you should use callback mode.

windkh avatar Apr 27 '24 09:04 windkh