i8beef / node-red-contrib-castv2

MIT License
22 stars 15 forks source link

Node keeps disconnecting and reconnecting, but doesn't allow a cast to device #88

Closed Intecpsp closed 2 years ago

Intecpsp commented 2 years ago

I've recently moved to this module from the built-in cast one after I tried sending STOP commands and it killed my Node Red instance.

I had this working for about a week, and now it won't do anything. After ~26-30 seconds, the node will go from connected to disconnected and then connect again. While it is connected (and I can see the info from the connection from a debug node, screenshot below), I try to send it a cast command, and nothing happens. I am using the <IP>:8009 configuration and the devices are on different VLANs. Are there any logs I can pull to see why it continuously disconnects? I will add that the device (Nest Mini) never goes offline and I can tell it to do something (play white noise) and it does so until I tell it to stop, sometimes hours later.

UPDATE: Checked the log and found this:

Error: Device timeout
    at fn.ontimeout (/config/node-red/node_modules/castv2-client/lib/senders/platform.js:56:26)
    at Object.onceWrapper (node:events:641:28)
    at fn.emit (node:events:527:28)
    at Timeout.ontimeout [as _onTimeout] (/config/node-red/node_modules/castv2-client/lib/controllers/heartbeat.js:44:10)
    at listOnTimeout (node:internal/timers:559:17)
    at processTimers (node:internal/timers:502:7)

Screenshot 2022-08-16 at 8 21 36 AM

Intecpsp commented 2 years ago

Changed the AP the device is on and it is stable in Node Red now as well as on the network in general