brutella / hc

hc is a lightweight framework to develop HomeKit accessories in Go.
Apache License 2.0
1.74k stars 189 forks source link

multiple accessories events #202

Closed zuozhehao closed 2 years ago

zuozhehao commented 3 years ago
for k, v := arr {

  as := accessory.New(v.Conf, v.Type)
    _ = s.Container.AddAccessory(as)

}

I add accessories in a loop, but I find that I don't know how to set a callback for each accessory.

Can someone help.

brutella commented 2 years ago

Please explain your issue in more detail. What kind of accessories are you creating?

brutella commented 2 years ago

Closed because of inactivity.