Jump to content

Google Home scene handling


Recommended Posts

Posted

ISY Scene exposed as a Google Home Scene

When you add a scene in ISY Portal, and leave the Google Home Category to Scene, please be aware that the scene will not show in the device list which may lead you to think it's not discovered. But no, the scene is there and can be controlled.

ISY Scene exposed as a Light

When an ISY Scene is configured with the Google Home Category Light, Switch or Outlet, Google Home will think your scene is an actual device. When clicking on the device in the App, this will query the device, which obviously is not possible in the ISY world.

Until now, ISY Portal would return an error as a scene can't be queried. Previously, the Google Home app would show an error, but would still allow the user to turn on/off the device. But recently, the GH app changed and if the query fails, it no longer allow the end user to turn on/off the device.

The following fix has been implemented: When the scene is queried, portal now returns it as off, instead of an error. In the app, the device will show as off, which can be inaccurate. However, the app now allows to turn on/off the device, and will show the "normal" state after a turn on / turn off.

EDIT 2020-05-06

ISY Scene exposed as a Light has been enhanced. When the scene is queried by GH, ISY Portal will check the status of a member of the scene and use it as an indicator of the scene status. It will use the first controller node, if available, or otherwise the first node.

If this node is non-zero, the scene will be considered On. It may not be 100% accurate because a scene turned on could in fact turn off a device, but the assumption is that in most cases, when turning on a scene, we want to turn on devices to a certain preset other than zero.

 

  • Like 4
  • 4 weeks later...
Posted

Apologies but this is confusing to me.  So my understanding of this is that the "scene" when added as a light or as a "scene" will work from an On/Off stance but will always show as OFF in Google Home?  Why doesn't Portal return the actual state of the Scene to Google?  Or I guess a better question is, How can I add a scene to Google and have it properly report the scene status back to Google?

Posted
9 minutes ago, rebirth24 said:

Apologies but this is confusing to me.  So my understanding of this is that the "scene" when added as a light or as a "scene" will work from an On/Off stance but will always show as OFF in Google Home?  Why doesn't Portal return the actual state of the Scene to Google?  Or I guess a better question is, How can I add a scene to Google and have it properly report the scene status back to Google?

Insteon scenes do not report their status so that is not possible. 

Posted (edited)

Hmm. So for example using Agave, what exactly is it doing when it comes to scene status? Just reporting the Scene status based on the devices within that scene? Are we saying the only way to report proper status of a group of devices in one room would be to add each individual device within that room/area into Google?

Edited by rebirth24
Posted
2 minutes ago, rebirth24 said:

Hmm. So for example using Agave, what exactly is it doing when it comes to scene status"? Just reporting the Scene status based on the devices within that scene? Are we saying the only way to report proper status of a group of devices in one room would be to add each individual device within that room/area into Google?

Using agave which was designed to work specifically with the Isy vs Google which was designed to operate the way Google wants (as well as with different vendors/protocols) are 2 different things.

Agave isn't actually looking at the fact that you are turning your scene on. It's simply reading the information that the isy presents in the system. For example, if you were to individually set all of your lights to your scene level, the "scene" itself would still be off in the eyes of the controller.

Since insteon scenes don't acknowledge the way individual devices do, there is no way for Google to know it's on.

Posted
1 minute ago, lilyoyo1 said:

Using agave which was designed to work specifically with the Isy vs Google which was designed to operate the way Google wants (as well as with different vendors/protocols) are 2 different things.

Agave isn't actually looking at the fact that you are turning your scene on. It's simply reading the information that the isy presents in the system. For example, if you were to individually set all of your lights to your scene level, the "scene" itself would still be off in the eyes of the controller.

Since insteon scenes don't acknowledge the way individual devices do, there is no way for Google to know it's on.

And you are also stating that the UD Portal can't make that declaration to Google either? I mean the UD Portal is the conduit for information going back to Google, correct?

Posted
13 minutes ago, rebirth24 said:

And you are also stating that the UD Portal can't make that declaration to Google either? I mean the UD Portal is the conduit for information going back to Google, correct?

No it cannot. If you read what bmercier stated about how Google home operates, the portal and nothing else can override that. Google home runs a query when a device is triggered. 

There is no query when it comes to a scene as scenes cannot be queried. Whenever a scene is used, devices are sent the command and it is assumed they got the command. Due to how insteon and the isy works, the actual true status of a scene is unknown by everything unless specific programming is in place to change that. This applies to apps as well. 

For example. A scene with 4 devices. 1 is off, 2 are 50% and 1 is fully on. If you individually set them at the devices to that level is the scene actually on? What if the scene is on but you manually change a couple of the devices? Is it still on then? 

Go ahead try it with your agave app. Look at the status of your keypad. Once a scene is on it'll show on. Once off it'll show off regardless of the actual device states. 

Posted
14 minutes ago, lilyoyo1 said:

No it cannot. If you read what bmercier stated about how Google home operates, the portal and nothing else can override that. Google home runs a query when a device is triggered. 

There is no query when it comes to a scene as scenes cannot be queried. Whenever a scene is used, devices are sent the command and it is assumed they got the command. Due to how insteon and the isy works, the actual true status of a scene is unknown by everything unless specific programming is in place to change that. This applies to apps as well. 

For example. A scene with 4 devices. 1 is off, 2 are 50% and 1 is fully on. If you individually set them at the devices to that level is the scene actually on? What if the scene is on but you manually change a couple of the devices? Is it still on then? 

Go ahead try it with your agave app. Look at the status of your keypad. Once a scene is on it'll show on. Once off it'll show off regardless of the actual device states. 

If I do not TOUCH the scene in Agave and adjust the individual items within that scene, the Agave scene adjusts.  

 

Example - I have 3 lights in the "Office" scene (Wall/Ceiling/Hallway).  When I turn on the Wall Lights in the office, Agave shows the Scene as ON.  When I turn off the Wall lights Agave shows the Scene as OFF. If I have the wall lights dimmed On Agave shows the Scene as ON. If I have the Ceiling Lights On Agave shows the Scene as ON. If I have both lights off it shows the scene as OFF.  If any combination of devices has any of them in the ON position (dimmed or otherwise) Agave shows the scene as ON. If ALL the devices are OFF Agave shows the scene as OFF. 

When I command the Scene ON in Agave it shows the Scene as ON.  When I manually turn off all the devices the Scene then goes to OFF in Agave.

Why can't Google/UD Portal act and report this same way?

Posted

That works because in that scene all devices are controllers so simple on/off will do that.  However, scenes can take the form of many different things. 

Take a scene where you may have a service that is a controller and a few responders and see what happens when you change the responders. You can even try it in your admin console with your hallway light. Turn on your scene manually. Then go to the individual device  and adjust it. Your app will believe that the scene is still on.

Just because you want things to be a certain way doesn't make it so. How insteon and isy works is not how Google works. UDI can only program for what Google's api allows

Posted
1 minute ago, lilyoyo1 said:

That works because in that scene all devices are controllers so simple on/off will do that.  However, scenes can take the form of many different things. 

Take a scene where you may have a service that is a controller and a few responders and see what happens when you change the responders. You can even try it in your admin console with your hallway light. Turn on your scene manually. Then go to the individual device  and adjust it. Your app will believe that the scene is still on.

Just because you want things to be a certain way doesn't make it so. How insteon and isy works is not how Google works. UDI can only program for what Google's api allows

Confused by your assertion as these are all added to the scene as responders. I appreciate the blanket "How Insteon and ISY works is not how Google works" but you still aren't providing any technical reason as to why Agave is able to do what it looks like the UD Portal cannot?  No matter what combination of device states and how I bring them into that state, if ANY of the devices are ON, Agave shows the Scene as ON. If ALL the devices are OFF it shows the scene as OFF.

Isn't Google just getting the scene status return from UD if added as a light OR as a scene? Perhaps I am asking too much and this is just a limitation of the UD Portal and an enhancement request for it to act more like Agave is what I am seeking? 

 

 

 

Posted (edited)

That works because in that scene all devices are controllers so simple on/off will do that.  However, scenes can take the form of many different things. 

Take a scene where you may have a device that is a controller and a few responders and see what happens when you change the responders. You can even try it in your admin console with your hallway light. Turn on your scene manually. Then go to the individual device  and adjust it. Your app will believe that the scene is still on.

Just because you want things to be a certain way doesn't make it so. How insteon and isy works is not how Google works. UDI can only program for what Google's api allows

Edited by lilyoyo1
Posted
32 minutes ago, rebirth24 said:

Confused by your assertion as these are all added to the scene as responders. I appreciate the blanket "How Insteon and ISY works is not how Google works" but you still aren't providing any technical reason as to why Agave is able to do what it looks like the UD Portal cannot?  No matter what combination of device states and how I bring them into that state, if ANY of the devices are ON, Agave shows the Scene as ON. If ALL the devices are OFF it shows the scene as OFF.

Isn't Google just getting the scene status return from UD if added as a light OR as a scene? Perhaps I am asking too much and this is just a limitation of the UD Portal and an enhancement request for it to act more like Agave is what I am seeking? 

 

 

 

The portal can do anything. It's how Google interprets the info

Posted
Just now, lilyoyo1 said:

The portal can do anything. It's how Google interprets the info

And as stated above when queried the portal throws back an OFF in order to avoid an ERROR being returned. So why couldn't the portal act as Agave does and report back an ON/OFF/OFF (error) depending on Scene Status? (as a standard)

Posted
8 minutes ago, rebirth24 said:

And as stated above when queried the portal throws back an OFF in order to avoid an ERROR being returned. So why couldn't the portal act as Agave does and report back an ON/OFF/OFF (error) depending on Scene Status? (as a standard)

The scene does not have a status. Insteon itself does not keep track of status. With some stuff you may accomplish what you want such as a scene with all controllers. With others the proper status wouldn't be updated. 

As I stated earlier, agave and other app makers are able to come up with work around for stuff (just like udi does for insteon) because they are geared towards a specific device and task. Google however is not geared towards insteon and udi specifically which means there will be limitation for what udi can do.

At the end of the day you don't get it and I've run out of ways to explain it. 

Posted
4 minutes ago, lilyoyo1 said:

The scene does not have a status. Insteon itself does not keep track of status. With some stuff you may accomplish what you want such as a scene with all controllers. With others the proper status wouldn't be updated. 

As I stated earlier, agave and other app makers are able to come up with work around for stuff (just like udi does for insteon) because they are geared towards a specific device and task. Google however is not geared towards insteon and udi specifically which means there will be limitation for what udi can do.

At the end of the day you don't get it and I've run out of ways to explain it. 

Yes. You probably aren't the correct person to explain it.  Agreed.

  • Sad 1
Posted
And as stated above when queried the portal throws back an OFF in order to avoid an ERROR being returned. So why couldn't the portal act as Agave does and report back an ON/OFF/OFF (error) depending on Scene Status? (as a standard)
The problem is that there is no way to know if a scene is on or off. What if you have 2 scenes with all the same responders but different on levels? When any of those responders are on Agave will show the scene percentage as on, but that's not true.

Bottom line is that ISY doesn't store if a scene is turned on or off, because there is no way to keep track, so there is no guaranteed way to know if it's on. If you think of scenes as groups, then makes sense, but insteon scenes are more than just groups.

I've been a proponent asking for a better way to handle this, but it will likely never happen. The hacks like Agave does, while nice is most cases, probably won't happen in the portal.


Sent from my Pixel 3 XL using Tapatalk

  • Like 1
Posted
11 minutes ago, Jimbo said:

Mine still says; Sorry, something went wrong...
Even though it actually does what I asked.

Sent from my Pixel 3 XL using Tapatalk
 

Please PM me you uuid, I will check the logs

Posted
26 minutes ago, Jimbo said:

Mine still says; Sorry, something went wrong...
Even though it actually does what I asked.

Sent from my Pixel 3 XL using Tapatalk
 

You may want to check your scene, just make sure it has members.

I made a fix to adress the case where a scene has no members, please try again.

Benoit

Posted
You may want to check your scene, just make sure it has members.
I made a fix to adress the case where a scene has no members, please try again.
Benoit
It has many controllers and responders which I observed being controlled.

Sent from my Pixel 3 XL using Tapatalk

Posted

Please pm me your uuid

Another test you could do:

http://<your isy>/rest/nodes/<your scene>?members=true

Check if the members sections has link tags.

For further analysis, I would need your uuid and/or the output of the above rest command.

Benoit

  • Like 1
Posted (edited)

First Off...Thanks a bunch for working on this!

Using an example of a 4 responder light scene added as a light scene into google home.

When I turn the scene on/off via google home it now shows it as OFF or ON and remains in whichever state I place it in regardless of the state of the individual devices within that scene.  If i turn them all OFF it still says the scene or light in this case is still "On". If it was OFF before and I turn every single light to ON via Admin console or other means it still remains in the "Off" state.

All in all it is not doing what you stated it should be doing. 

Edited by rebirth24
Posted
On 4/7/2020 at 7:42 PM, bmercier said:

ISY Scene exposed as a Light has been enhanced. When the scene is queried by GH, ISY Portal will check the status of the first member of the scene and use it as an indicator of the scene status. If the first node of the scene is non-zero, the scene will be considered On. It may not be 100% accurate because a scene turned on could in fact turn off a device, but the assumption is that in most cases, when turning on a scene, we want to turn on devices to a certain preset other than zero.

 

This is awesome that you are trying to get this working. For all my long years on this forum being screamed at about ISY scenes not having status I didn't think this could happen :) even though I hacked around it in the hue emulator.  But, would it be better if you looked at the status of the first Controller in case the first member is a responder?  

Posted

Years back it was identified that device status on dimmable items is not an exact science. IIRC some of this was based on levels are set using 1/00 resolution to represent the levels to humans in percent. Then most devices behind the scenes use a 8 bit value  ie: 0-255. The conversion process can entail rounding off the conversion or truncation.

eg. In a scene you set a device to 55%. When you read back the status of the device you may get anything from 53% to 57% and yet nothing else has interfered with the scene setting for that device. Is the scene still considered on, or has another system inflicted a different scene to that participating device and that scene should be considered "off"? Scenes were only meant to be one way controls to duplicate what X10 was doing with All On affecting a particular "House Code".

Bravo to bmercier but this is still only a guess.

Guest
This topic is now closed to further replies.

×
×
  • Create New...