[RELEASE] HubiThings Replica

Would it essentially be:

  1. Create virtual devices in ST
  2. Setup HubiThings mirror mapping HE device to ST virtual device
  3. Make sure the mappings are correct

I'm fine with the manual work ... I'm not adding/changing shades.

yes, that is the process. you are very limited on commands and must work with attributes only. Here is a example of a dimmer to dimmer mirror. it might be buggy since it hasn't really be exercised. so if you see bad things let me know under private cover. also update to the latest 1.2.12 on github. it has a fix for mirrors in it.

BETA Samsung TV Replica now available at my repository. https://github.com/DaveGut/HubitatActive/tree/master/HubiThingsReplicaDrivers

5 Likes

Hi @djgutheinz ,
As a user of your Non-Replica drivers, could you please explain what will be the difference between using your Replica driver and the Non-Replica version?

HubiThings Replica allows for subscriptions to SmartThings for critical attributes. These update instantly. Speaking the TV Remote driver:

Installation: Once you get the Apps installed and running, installation is slightly easier.

ON / OFF is determined from SmartThings. This allows consistent on/off detection amount all of the platforms.

The ST interface provides a better interface for determining ART_MODE and AMBIENT status - allowing better control of those functions. Startup display of Art_mode/Ambient is currently limited to on executed through the Hubitat interface (i.e., it will not initiate the startup display if you use the physical remote.

Those are the big two changes. Once I finish this driver, I will be adding the newer Samsung Soundbars - providing a hook into Hubitat that does not yet exist. I will need support to test this. I will also begin migrating my existiong Samsung Appliance drivers over, but again need support testing.

2 Likes

I will be happy to help with testing the Soundbar driver.
Thanks you for your efforts.

4 Likes

I can test the Washer & Dryer.

1 Like

I will work on those after the soundbar. Fun!!!!!

I just tried the driver and got this exception:

2023-01-13 10:44:41.621 AM[error](http://192.168.1.20/logs?tab=past&deviceId=1345#)org.codehaus.groovy.runtime.metaclass.MissingMethodExceptionNoStack: No signature of method: user_driver_replica_Replica_Samsung_TV_1556.setSwitchValue() is applicable for argument types: (java.lang.String) values: [on] (method setSwitchValue)

1 Like

@djgutheinz

It's worth noting that I got the exception because I changed the driver from "Replica Switch" to this new driver but didn't click Configure. After I clicked Configure, I didn't get the exception anymore, but the switch doesn't work at all. Clicking On/Off in Hubitat doesn't do anything, and turning the TV on/off with the remote doesn't cause the switch state to change.

Working now. You had not set the deviceIP???? It should work either way, just need to know.

No, it's not working now, and I didn't set the deviceIP. Here's what I did:

  1. I started with my TV using the "Replica Switch" driver, because the only thing I'm really interested in is on/off status, and that driver works fine for those purposes.
  2. I figured I'd give your driver a try, so I installed it and changed the driver on the device.
  3. I turned on the TV with the remote, got the exception, turned it off, same exception.
  4. I looked in the Replica app and realized that changing the driver didn't automatically update the Replica rules, so I clicked Configure. Then, I verified that the Replica app had a whole different set of rules for the device.
  5. I turned the TV on with the remote. No exception this time, but the "switch" state still showed "off".

First, I have to say this is great.

I am not sure how to add the SmartthingsHub device though? I have the OAuth app confirmed, authorized and able to see devices but the hub itself isn't listed as one so I can't select it to create a HubiThings device.

The only thing I can think of is that I added the device code after confirming the OAuth app, if it would have been created as part of that I can redo the OAuth setup.

I took out the commands on and off at the last minute. Will fix and have out this afternoon.

To continue playing, enter the deviceIP. the design will force try local first and then the smartThings command. This is to allow basic control if the SmartThings interface fails.

I'll wait for your fix and try again over the weekend. I've tried your local drivers in the past, and found that my TV (a 2019 model) can fool the local driver into thinking it's turned on when it really isn't, so I don't want any local functionality.

(I don't think it's any fault of yours. Sometimes -- usually -- about a minute after turning off, it decides to turn its power partially on for another minute, and then back off. My soundbar thinks the TV is on too, but the screen is off. Samsung was no help with the issue, so I just live with it. It doesn't report this status change to SmartThings, though, so I'm forced into using that interface if I want an accurate status.)

The Hub should show as just another device in the device list. What version of hub are you running? It shouldn't matter but I have tested with the v2 & v3.

This is a view of a Hub in OAuth drop down selector:

I missed the hub in that list (I have way too many devices). Thanks for the pointer!

1 Like

Hopefully, Samsung figured out a way to process this out in smartThings.

Want to have fun, look at the SmartThing phone app status. Turn the set on for several minutes and then back on in 10 seconds or so via the remote. SmartThings takes several minutes to detect on again (on my TV anyway). Cause is the powerState being called from the TV set is in standby while it closes out the previous on state. (yes, the samsungTV device handler polls the tv frequently for critical changes (power, inputSource, tvChannel, etc) but not for everything (volume, mute, etc). Go figure).

Funny. I find when my TV is connected to Hubitat through SmartThings, I get switch state updates within milliseconds of turning it on or off, and response time in the app is usually pretty snappy.

When I turn my TV off, it decides to tell SmartThings not only that it's off, but that it's completely offline. I can't control it from the app until I turn it on with the remote again. The SmartThings app says that this can happen when the TV is connected over Ethernet (which mine is), but not if it's connected over WiFi. Of course, my TV can't maintain a stable WiFi connection, even though it's about 20 feet from the router in the same room...

Yeah, that would work -- until the next time I turn the TV off.