Add support for dimmers and dimmable bulbs

The exposes entry looks similar to a switch, except the type is a
"light" and it has `state` and `brightness`. Tested only on single
channel dimmers.

Also added a PercentageTranslator to translate between the HomeKit
`brightness`, which is a percentage, to/from an arbitrary numeric value
in Z2M.
This commit is contained in:
Darell Tan
2023-06-25 02:20:01 +08:00
parent 7fbbec79d9
commit c61da984c9
3 changed files with 98 additions and 0 deletions

View File

@@ -15,6 +15,7 @@ Currently only supports the types of Zigbee devices I have:
- Contact sensors
- Motion sensors
- Wall switch
- Dimmer, or dimmable light bulbs
If you do use this software, note that it's in development and may contains bugs,
or may even burn your house down. I offer no warranty, but you are welcome to file bugs.