mirror of
https://github.com/mtan93/homebridge.git
synced 2026-05-13 14:26:04 +01:00
Merge pull request #254 from SphtKr/yamaha-issue-247
YamahaAVR Issue #247
This commit is contained in:
+12
-12
@@ -31,24 +31,24 @@ function YamahaAVRPlatform(log, config){
|
|||||||
|
|
||||||
YamahaAVRPlatform.AudioVolume = function() {
|
YamahaAVRPlatform.AudioVolume = function() {
|
||||||
Characteristic.call(this, 'Audio Volume', '00001001-0000-1000-8000-135D67EC4377');
|
Characteristic.call(this, 'Audio Volume', '00001001-0000-1000-8000-135D67EC4377');
|
||||||
this.format = 'uint8';
|
this.setProps({
|
||||||
this.unit = 'percentage';
|
format: Characteristic.Formats.UINT8,
|
||||||
this.maximumValue = 100;
|
unit: Characteristic.Units.PERCENTAGE,
|
||||||
this.minimumValue = 0;
|
maxValue: 100,
|
||||||
this.stepValue = 1;
|
minValue: 0,
|
||||||
this.readable = true;
|
minStep: 1,
|
||||||
this.writable = true;
|
perms: [Characteristic.Perms.READ, Characteristic.Perms.WRITE, Characteristic.Perms.NOTIFY]
|
||||||
this.supportsEventNotification = true;
|
});
|
||||||
this.value = this.getDefaultValue();
|
this.value = this.getDefaultValue();
|
||||||
};
|
};
|
||||||
inherits(YamahaAVRPlatform.AudioVolume, Characteristic);
|
inherits(YamahaAVRPlatform.AudioVolume, Characteristic);
|
||||||
|
|
||||||
YamahaAVRPlatform.Muting = function() {
|
YamahaAVRPlatform.Muting = function() {
|
||||||
Characteristic.call(this, 'Muting', '00001002-0000-1000-8000-135D67EC4377');
|
Characteristic.call(this, 'Muting', '00001002-0000-1000-8000-135D67EC4377');
|
||||||
this.format = 'bool';
|
this.setProps({
|
||||||
this.readable = true;
|
format: Characteristic.Formats.UINT8,
|
||||||
this.writable = true;
|
perms: [Characteristic.Perms.READ, Characteristic.Perms.WRITE, Characteristic.Perms.NOTIFY]
|
||||||
this.supportsEventNotification = true;
|
});
|
||||||
this.value = this.getDefaultValue();
|
this.value = this.getDefaultValue();
|
||||||
};
|
};
|
||||||
inherits(YamahaAVRPlatform.Muting, Characteristic);
|
inherits(YamahaAVRPlatform.Muting, Characteristic);
|
||||||
|
|||||||
Reference in New Issue
Block a user