Closed cristianchelu closed 5 months ago
How annoying... I'll see how we can support that without making the code too ugly :)
Can you try with that ^ commit? You can then use e.g.:
binary_sensor:
- platform: "miot"
miot_siid: 4
miot_piid: 9
miot_true: "1"
miot_false: "0"
name: "Top Lid"
device_class: opening
(and the same for switches)
Confirmed both switch
and binary_sensor
are reported and controlled well with the new commit & configuration.
Thanks!
Nice, thanks for the confirmation!
The specs for Smart Pet Food Feeder (mmgg.feeder.fi1) use a
uint8 0 ~ 1
value instead of aboolean true ~ false
to read or control the status of some properties, for exampleSIID 6 PIID 1 (Child Lock)
,SIID 3 PIID 1 (Indicator Lights)
,SIID 4 PIID 8 (Food outlet door)
andSIID 4 PIID 9 (Food storage cover)
.I'm not really sure if this should be handled as a configuration option in this component or if it's better to leave it as a combination of filters in the esphome config (or I missed some obvious solution, in which case I'm sorry for the time waste!).
I have the following configuration:
For the Child lock switch, here's a verbose log for triggering it via the mcu_command service with
command: "set_properties 6 1 0"
The inverted switch is now on in the UI, and toggling it back off results in the following verbose log
For the read-only top lid state, here's the verbose log when I physically open it:
and when I physically close it back:
ESPHome 2023.12.9 esphome-miot@5bff0dc