Here's what I'm doing now, but it looks unnecessary complicated.
1. I made it configurable for each device so I can experiment - ctrlType is the swich
2. If value is chaged from HS via SetIOMulti - I can't use CAPIControlHandler to confirm back to HS - I must use SetDeviceValueByRef , hence the additional forceSetDeviceValueByRef switch.
Announcement
Collapse
No announcement yet.
SetDeviceValueByRef vs CAPIControlHandler
Collapse
X
-
SetDeviceValueByRef vs CAPIControlHandler
So, there are two ways to set device value - SetDeviceValueByRef and CAPIControlHandler. First I thought that SetDeviceValueByRef is just a convinience wrapper for CAPIControlHandler. But.
SetDeviceValueByRef doen't seem to work with physical devices like Raspberry IO outputs. It looks like it changes the value in HS ui, but output doesn't change.
So. I try CAPIControlHandler - it does work with Raspberry IO outputs - but is not reflected in HS ui.
So WTH should I be using? I use both and it seems to work - but it's ridiculous.Tags: None
Leave a comment: