Hello!
I use OH 3.3 and smarthomej tuya binding. I have some Tuya`s devices. Part of them added and work correctly, but two of them is switching status online/offline:
15:54:29.959 [INFO ] [hab.event.ThingStatusInfoChangedEvent] - Thing 'tuya:tuyaDevice:9f33009b6b' changed from UNKNOWN to ONLINE
15:54:30.214 [INFO ] [hab.event.ThingStatusInfoChangedEvent] - Thing 'tuya:tuyaDevice:9f33009b6b' changed from ONLINE to OFFLINE
15:54:35.278 [INFO ] [hab.event.ThingStatusInfoChangedEvent] - Thing 'tuya:tuyaDevice:9f33009b6b' changed from OFFLINE to ONLINE
15:54:35.590 [INFO ] [hab.event.ThingStatusInfoChangedEvent] - Thing 'tuya:tuyaDevice:9f33009b6b' changed from ONLINE to OFFLINE
WiFi devices in general tend to do this when they don’t have a strong signal from the router. Even if it’s close to the router, there could be a wall/appliance/etc. that’s blocking it.
If you can, move the bulb into line of sight of the router to see if this continues. If so, the bulb may be faulty. If the issue goes away, you’ll need to find a way to improve the signal where you want to use the bulb.
I have a relatively small space (800sq.ft.), but my refrigerator and stove are right in the middle of it. So I installed a mesh router to eliminate the dead zone the appliances were creating.
When you say that the devices are switching status, are they staying offline and inaccessible from openHAB (while remaining available in a Tuya app)? Or are you seeing these flaps in the log while generally being able to operate them from openHAB?
The reason I ask is that the Tuya apps don’t report every single status update, which is what you’re seeing in your log. So it would be possible for them to flap and you’d never notice on the Tuya side. In contrast, the SmarthomeJ binding connects to devices locally and is logging when those flaps occur.
I’ll be curious if this makes a difference. I’m not convinced that the SmarthomeJ binding is the problem, since other devices are working fine with it. All it can do is report when OH loses and regains contact with a device. Worth trying, though.
Before doing that, you might want to try reserving IP addresses for these devices in your router, then denying them Internet access. That would isolate them so that only OH and the SmarthomeJ binding can access them.
With my opinion, problem is in firmware of the device. As I remember, I got different results for working and non woking devices when I used iot portal Tuya.
*upd If divice did not work in OH, it did not get status here (control from Tuya aplication): *
Are the non-working devices identical to working devices? Or are they different models? Tuya seems to allow a lot of flexibility with how individual companies program their devices, which results in a lot of non-standard behaviour.
I have a Tuya ceiling light that allows me to activate the scene mode via openHAB, but not change scenes. I bought a table lamp expecting the same thing, but it would only allow scenes to be activated via the app or by pushing the single button on the back of the device. When I looked in the IOT portal, there was nothing in the JSON stream that I could use. It’s interesting that Tuya allows such flexibility, and maddening for the lack of consistency.
There are different kinds of devices. But I have also relay and dimmer from one manufacture, they stay in one place (big box). Dimmer is working with OH without problem, relay is not…
If you want, I can change connection of this devices to other Tuya account and give login& password.
Firmware could vary between any combination of device type and manufacturer. There are a lot of variables due to how Tuya operates.
No thanks. I would rather not have access to someone else’s devices.
That’s why I suggest trying to deny them Internet access. It’s possible that some firmwares are okay with simultaneous connections (the working devices) and other firmwares are not okay with it (the non-working devices). Every brand/type of device should probably be treated as having unique firmware.
I don’t know what you mean by this. You can’t get it to reconnect at all? Or it eventually comes back online without you having to do anything (which is not the impression I got earlier)?
I’m pretty much out of ideas and inclined to think the device is faulty.
I’ve tried mine with 2 bulbs (same package…Globe brand from Costco Canada) with same result. I haven’t done as much troubleshooting as Pavel due to my not feeling well. My bulbs just flap on-off line almost immediately and repeats. I can post some of my log when I get home, but it looks pretty much the same as Pavel’s in his original post. Note, my Globe smart plugs work great with the Tuya binding.
Craig
PS. The bulbs NEVER stay online. Just continuously toggle.