Ah! Hvis du klarer å lese VB-kode, så kan du f.eks. se VirtualThermostat-pakken min.
Nærmere bestemt her:
'Associating devices
rootDevice.Relationship(hs) = HomeSeerAPI.Enums.eRelationship.Parent_Root
rootDevice.AssociatedDevice_Add(hs, setpointRef)
rootDevice.AssociatedDevice_Add(hs, roomTempRef)
setpointDevice.Relationship(hs) = HomeSeerAPI.Enums.eRelationship.Child
setpointDevice.AssociatedDevice_Add(hs, rootRef)
roomTempDevice.Relationship(hs) = HomeSeerAPI.Enums.eRelationship.Child
roomTempDevice.AssociatedDevice_Add(hs, rootRef)
Merk at jeg setter referanser "begge veier". Parent har flere childs, men child har kun én parent.