ptz0n / homebridge-verisure

 Platform plugin for Homebridge allowing to manage and control Verisure devices.
https://www.npmjs.com/package/homebridge-verisure
MIT License
66 stars 15 forks source link

Change & get audio level of lock #145

Closed albinmedoc closed 2 years ago

albinmedoc commented 2 years ago

I have added function to get and set audio level of the door lock. The accepted values are SILENCE, LOW & HIGH.

Whats left to do is to add an accessory reflecting this.

albinmedoc commented 2 years ago

I don't know if we could use this?

ptz0n commented 2 years ago

I believe this one should be a good fit: https://developers.homebridge.io/#/service/Speaker

albinmedoc commented 2 years ago

Looks good. I will give it a try.

albinmedoc commented 2 years ago

I have now implemented and tested the mute/unmute functionality.

I'm not sure how to implement the volume. One idea I have is the following:

If volume set to 0 = set to SILENCE If volume set to <= 50 = set to LOW If volume set to > 50 = set to HIGH

albinmedoc commented 2 years ago

Otherwise we could leave it as it is now. Mute = SILENCE Unmute = HIGH

ptz0n commented 2 years ago

I don't have this accessory in my installation so I guess you as an end user get to decide what makes the most sense.

albinmedoc commented 2 years ago

I have now created a switch that toggles the audio level. The speaker accessory was only visible in the Eve-app.

By using a switch we can only use two of the three volume settings... I updated the configuration so the user can specify what volume setting will be applied on switch on/off.

I also added an option to hide this switch, and while I was at I did the same for the Auto Lock switch (#94).

albinmedoc commented 2 years ago

If this PR gets accepted we can close #94 & #144.

ptz0n commented 2 years ago

Please merge: https://github.com/albinmedoc/homebridge-verisure/pull/1