Skip to content

Commit

Permalink
beta.6.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Zacknetic committed Nov 29, 2020
1 parent 12701d0 commit 6412993
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"private": false,
"displayName": "Homebridge MagicHome Dynamic Platform",
"name": "homebridge-magichome-dynamic-platform",
"version": "1.8.5-beta.6.1",
"version": "1.8.5-beta.6.2",
"description": "Dynamically discovers and adds MagicHome Bulbs and controllers to Homebrige.",
"license": "Apache-2.0",
"repository": {
Expand Down
5 changes: 1 addition & 4 deletions src/platformAccessory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,23 +157,20 @@ export class HomebridgeMagichomeDynamicPlatformAccessory {
this.colorCommand = true;
this.processRequest();
callback(null);
this.updateHomekitState();
}

setSaturation(value: CharacteristicValue, callback: CharacteristicSetCallback) {
this.lightState.HSL.saturation = value as number;
this.colorCommand = true;
this.processRequest();
callback(null);
this.updateHomekitState();
}

setBrightness(value: CharacteristicValue, callback: CharacteristicSetCallback) {
this.lightState.brightness = value as number;
this.colorCommand = true;
this.processRequest();
callback(null);
this.updateHomekitState();
}

/*
Expand All @@ -188,7 +185,6 @@ export class HomebridgeMagichomeDynamicPlatformAccessory {
this.lightState.isOn = value as boolean;
this.processRequest();
callback(null);
this.updateHomekitState();
}

//=================================================
Expand Down Expand Up @@ -458,6 +454,7 @@ export class HomebridgeMagichomeDynamicPlatformAccessory {


processRequest(){
this.updateHomekitState();
if(!this.deviceUpdateInProgress){
this.deviceUpdateInProgress = true;
setTimeout( () => {
Expand Down

0 comments on commit 6412993

Please sign in to comment.