HAP-python icon indicating copy to clipboard operation
HAP-python copied to clipboard

Cannot call CurrentTemperature characteristic properly

Open ilyamordasov opened this issue 7 years ago • 3 comments

My implementation is here: self.char_get = serv_kettle.configure_char('CurrentTemperature', setter_callback=self.get_temperature)

def get_temperature(self, value): run_cmd() print("Current temperature was called")

And when I tell Siri 'what's current temperature of Bridge?' the get_temperature() function isn't called (print isn't displayed) and Siri answers smth like 'Current temperature at your home is 0 degrees'

Any ideas why it's working so?

ilyamordasov avatar Jul 18 '18 14:07 ilyamordasov

I think you're looking for the getter_callback.

cdce8p avatar Jul 18 '18 18:07 cdce8p

exactly, thank you! But have got new uncomfortable state, so when I still ask what's current temperature of Bridge? - where Bridge is my accessory - Siri answers 'The temperature at My Home is ...' is it possible to point that answer would have keyword Bridge, not My Home? It returns the correct number

ilyamordasov avatar Jul 19 '18 14:07 ilyamordasov

Assign the accessory to the specific room the sensor is in.

cdce8p avatar Jul 19 '18 19:07 cdce8p