I am working on my second plugin. This will work with the sprinkler device to have a weather-dependant system based on default on/off devices for the valves. I have a workable version but cannot understand some of the properties of the indigo.sprinkler class. Take dev.zoneCount as an example. It defaults to 8, but here I want to work with 3 zones Trying
- Code: Select all
dev.zoneCount = 3
throws AttributeError: the attribute "zoneCount" is read-only on this instance
Trying
- Code: Select all
localPropsCopy = dev.pluginProps
localPropsCopy['zoneCount'] = 3
dev.replacePluginPropsOnServer(localPropsCopy)
seems to work OK. Checking the device, I see that the ownerProps have changed. But reading the zoneCount
- Code: Select all
print (dev.zoneCount)
still shows 8 to me, which is the default value.
What am I missing here. Looking at the device documentation or the Rachio examples brought me to the above trials but did not give me the wanted answer.
Can you guide me please how I can update these properties like zoneCount, zoneNames etc?
Thanks Rudi