Custom Capability and CLI Developer Preview

Thank- you for your reply. I’ve delayed responding because I’ve wanted to try some different things before I did. Here is what I have found so far regarding the use of a custom capability switch for the dashboard action, and separate custom capability label for the dashboard state:

  1. If I don’t include an alternatives section in my presentation json for the dashboard state label, then whatever my app sets for the attribute gets blanked out (it flashes for a brief moment but then disappears. The API documentation does not show that alternatives is a mandatory json section for dashboard, but it appears that it is.

  2. If the device application doesn’t update the dashboard state label value as well as the switch attribute when the switch is pressed, then the switch will spin for about 12 seconds. I found that updating the state label stops this spinning. So there does seem to be some kind of dependency between the action and state on the dashboard even if they are two separate capabilities.

  3. In the capability presentation json, trying to set any of the dashboard state label alternative types to “inactive” results in no state being shown for any value; and no change to the icon coloration. I want certain values to cause the icon to be greyed out vs. colored, and I thought this was the purpose of type=active/inactive in the alternatives section. However this doesn’t seem to be working with custom capabilities.