@switchbot/homebridge-switchbot 3.5.0-beta.27 → 3.5.0-beta.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (136) hide show
  1. package/CHANGELOG.md +1 -0
  2. package/config.schema.json +67 -1
  3. package/dist/device/blindtilt.d.ts.map +1 -1
  4. package/dist/device/blindtilt.js +10 -5
  5. package/dist/device/blindtilt.js.map +1 -1
  6. package/dist/device/bot.d.ts.map +1 -1
  7. package/dist/device/bot.js +10 -5
  8. package/dist/device/bot.js.map +1 -1
  9. package/dist/device/ceilinglight.d.ts.map +1 -1
  10. package/dist/device/ceilinglight.js +36 -10
  11. package/dist/device/ceilinglight.js.map +1 -1
  12. package/dist/device/colorbulb.d.ts.map +1 -1
  13. package/dist/device/colorbulb.js +24 -5
  14. package/dist/device/colorbulb.js.map +1 -1
  15. package/dist/device/contact.d.ts.map +1 -1
  16. package/dist/device/contact.js +8 -3
  17. package/dist/device/contact.js.map +1 -1
  18. package/dist/device/curtain.d.ts.map +1 -1
  19. package/dist/device/curtain.js +8 -3
  20. package/dist/device/curtain.js.map +1 -1
  21. package/dist/device/device.d.ts +2 -1
  22. package/dist/device/device.d.ts.map +1 -1
  23. package/dist/device/device.js +23 -6
  24. package/dist/device/device.js.map +1 -1
  25. package/dist/device/fan.d.ts +51 -0
  26. package/dist/device/fan.d.ts.map +1 -0
  27. package/dist/device/fan.js +499 -0
  28. package/dist/device/fan.js.map +1 -0
  29. package/dist/device/hub.d.ts.map +1 -1
  30. package/dist/device/hub.js +33 -25
  31. package/dist/device/hub.js.map +1 -1
  32. package/dist/device/humidifier.d.ts.map +1 -1
  33. package/dist/device/humidifier.js +8 -3
  34. package/dist/device/humidifier.js.map +1 -1
  35. package/dist/device/iosensor.d.ts.map +1 -1
  36. package/dist/device/iosensor.js +26 -18
  37. package/dist/device/iosensor.js.map +1 -1
  38. package/dist/device/lightstrip.d.ts.map +1 -1
  39. package/dist/device/lightstrip.js +42 -5
  40. package/dist/device/lightstrip.js.map +1 -1
  41. package/dist/device/lock.d.ts.map +1 -1
  42. package/dist/device/lock.js +8 -3
  43. package/dist/device/lock.js.map +1 -1
  44. package/dist/device/meter.d.ts.map +1 -1
  45. package/dist/device/meter.js +26 -18
  46. package/dist/device/meter.js.map +1 -1
  47. package/dist/device/meterplus.d.ts.map +1 -1
  48. package/dist/device/meterplus.js +8 -3
  49. package/dist/device/meterplus.js.map +1 -1
  50. package/dist/device/motion.d.ts.map +1 -1
  51. package/dist/device/motion.js +8 -3
  52. package/dist/device/motion.js.map +1 -1
  53. package/dist/device/plug.d.ts.map +1 -1
  54. package/dist/device/plug.js +8 -3
  55. package/dist/device/plug.js.map +1 -1
  56. package/dist/device/robotvacuumcleaner.d.ts.map +1 -1
  57. package/dist/device/robotvacuumcleaner.js +10 -5
  58. package/dist/device/robotvacuumcleaner.js.map +1 -1
  59. package/dist/device/waterdetector.d.ts.map +1 -1
  60. package/dist/device/waterdetector.js +15 -8
  61. package/dist/device/waterdetector.js.map +1 -1
  62. package/dist/irdevice/airconditioner.d.ts.map +1 -1
  63. package/dist/irdevice/airconditioner.js +3 -2
  64. package/dist/irdevice/airconditioner.js.map +1 -1
  65. package/dist/irdevice/airpurifier.d.ts.map +1 -1
  66. package/dist/irdevice/airpurifier.js +3 -2
  67. package/dist/irdevice/airpurifier.js.map +1 -1
  68. package/dist/irdevice/camera.d.ts.map +1 -1
  69. package/dist/irdevice/camera.js +3 -2
  70. package/dist/irdevice/camera.js.map +1 -1
  71. package/dist/irdevice/fan.d.ts +1 -1
  72. package/dist/irdevice/fan.d.ts.map +1 -1
  73. package/dist/irdevice/fan.js +4 -3
  74. package/dist/irdevice/fan.js.map +1 -1
  75. package/dist/irdevice/irdevice.d.ts +2 -1
  76. package/dist/irdevice/irdevice.d.ts.map +1 -1
  77. package/dist/irdevice/irdevice.js +9 -2
  78. package/dist/irdevice/irdevice.js.map +1 -1
  79. package/dist/irdevice/light.d.ts.map +1 -1
  80. package/dist/irdevice/light.js +3 -2
  81. package/dist/irdevice/light.js.map +1 -1
  82. package/dist/irdevice/other.d.ts.map +1 -1
  83. package/dist/irdevice/other.js +3 -2
  84. package/dist/irdevice/other.js.map +1 -1
  85. package/dist/irdevice/tv.d.ts.map +1 -1
  86. package/dist/irdevice/tv.js +3 -2
  87. package/dist/irdevice/tv.js.map +1 -1
  88. package/dist/irdevice/vacuumcleaner.d.ts.map +1 -1
  89. package/dist/irdevice/vacuumcleaner.js +3 -2
  90. package/dist/irdevice/vacuumcleaner.js.map +1 -1
  91. package/dist/irdevice/waterheater.d.ts.map +1 -1
  92. package/dist/irdevice/waterheater.js +3 -2
  93. package/dist/irdevice/waterheater.js.map +1 -1
  94. package/dist/platform.d.ts +2 -1
  95. package/dist/platform.d.ts.map +1 -1
  96. package/dist/platform.js +68 -5
  97. package/dist/platform.js.map +1 -1
  98. package/dist/settings.d.ts +22 -4
  99. package/dist/settings.d.ts.map +1 -1
  100. package/dist/utils.d.ts +10 -5
  101. package/dist/utils.d.ts.map +1 -1
  102. package/dist/utils.js +23 -9
  103. package/dist/utils.js.map +1 -1
  104. package/package.json +3 -3
  105. package/src/device/blindtilt.ts +10 -5
  106. package/src/device/bot.ts +10 -5
  107. package/src/device/ceilinglight.ts +36 -10
  108. package/src/device/colorbulb.ts +26 -7
  109. package/src/device/contact.ts +10 -5
  110. package/src/device/curtain.ts +22 -17
  111. package/src/device/device.ts +24 -6
  112. package/src/device/fan.ts +548 -0
  113. package/src/device/hub.ts +31 -23
  114. package/src/device/humidifier.ts +9 -4
  115. package/src/device/iosensor.ts +28 -20
  116. package/src/device/lightstrip.ts +41 -7
  117. package/src/device/lock.ts +13 -8
  118. package/src/device/meter.ts +30 -22
  119. package/src/device/meterplus.ts +12 -7
  120. package/src/device/motion.ts +9 -4
  121. package/src/device/plug.ts +9 -4
  122. package/src/device/robotvacuumcleaner.ts +15 -10
  123. package/src/device/waterdetector.ts +15 -8
  124. package/src/irdevice/airconditioner.ts +5 -4
  125. package/src/irdevice/airpurifier.ts +5 -4
  126. package/src/irdevice/camera.ts +4 -3
  127. package/src/irdevice/fan.ts +4 -3
  128. package/src/irdevice/irdevice.ts +11 -3
  129. package/src/irdevice/light.ts +3 -2
  130. package/src/irdevice/other.ts +47 -46
  131. package/src/irdevice/tv.ts +3 -2
  132. package/src/irdevice/vacuumcleaner.ts +3 -2
  133. package/src/irdevice/waterheater.ts +3 -2
  134. package/src/platform.ts +71 -5
  135. package/src/settings.ts +34 -9
  136. package/src/utils.ts +24 -9
@@ -136,8 +136,8 @@ export class Contact extends deviceBase {
136
136
  });
137
137
 
138
138
  //regisiter webhook event handler
139
- if (this.device.webhook) {
140
- this.infoLog(`${this.device.deviceType}: ${this.accessory.displayName} is listening webhook.`);
139
+ if (device.webhook) {
140
+ this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} is listening webhook.`);
141
141
  this.platform.webhookEventHandler[this.device.deviceId] = async (context) => {
142
142
  try {
143
143
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} received Webhook: ${JSON.stringify(context)}`);
@@ -280,6 +280,11 @@ export class Contact extends deviceBase {
280
280
 
281
281
  // FirmwareRevision
282
282
  this.accessory.context.FirmwareRevision = deviceStatus.body.version;
283
+ this.accessory
284
+ .getService(this.hap.Service.AccessoryInformation)!
285
+ .setCharacteristic(this.hap.Characteristic.FirmwareRevision, this.accessory.context.FirmwareRevision)
286
+ .getCharacteristic(this.hap.Characteristic.FirmwareRevision)
287
+ .updateValue(this.accessory.context.FirmwareRevision);
283
288
  }
284
289
 
285
290
  /**
@@ -348,7 +353,7 @@ export class Contact extends deviceBase {
348
353
  this.debugWarnLog(`${this.device.deviceType}: ${this.accessory.displayName} deviceStatus: ${JSON.stringify(deviceStatus)}`);
349
354
  this.debugWarnLog(`${this.device.deviceType}: ${this.accessory.displayName} deviceStatus statusCode: ${deviceStatus.statusCode}`);
350
355
  if ((statusCode === 200 || statusCode === 100) && (deviceStatus.statusCode === 200 || deviceStatus.statusCode === 100)) {
351
- this.debugErrorLog(`${this.device.deviceType}: ${this.accessory.displayName} `
356
+ this.debugSuccessLog(`${this.device.deviceType}: ${this.accessory.displayName} `
352
357
  + `statusCode: ${statusCode} & deviceStatus StatusCode: ${deviceStatus.statusCode}`);
353
358
  this.openAPIparseStatus(deviceStatus);
354
359
  this.updateHomeKitCharacteristics();
@@ -454,10 +459,10 @@ export class Contact extends deviceBase {
454
459
  this.ContactSensor.Service.updateCharacteristic(this.hap.Characteristic.ContactSensorState,
455
460
  this.hap.Characteristic.ContactSensorState.CONTACT_DETECTED);
456
461
  if (!this.device.contact?.hide_motionsensor) {
457
- this.MotionSensor!.Service.updateCharacteristic(this.hap.Characteristic.MotionDetected, false);
462
+ this.MotionSensor!.Service.updateCharacteristic(this.hap.Characteristic.MotionDetected, false);
458
463
  }
459
464
  if (!this.device.contact?.hide_lightsensor) {
460
- this.LightSensor!.Service.updateCharacteristic(this.hap.Characteristic.CurrentAmbientLightLevel, 100);
465
+ this.LightSensor!.Service.updateCharacteristic(this.hap.Characteristic.CurrentAmbientLightLevel, 100);
461
466
  }
462
467
  }
463
468
  }
@@ -154,8 +154,8 @@ export class Curtain extends deviceBase {
154
154
  });
155
155
 
156
156
  //regisiter webhook event handler
157
- if (this.device.webhook) {
158
- this.infoLog(`${this.device.deviceType}: ${this.accessory.displayName} is listening webhook.`);
157
+ if (device.webhook) {
158
+ this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} is listening webhook.`);
159
159
  this.platform.webhookEventHandler[this.device.deviceId] = async (context) => {
160
160
  try {
161
161
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} received Webhook: ${JSON.stringify(context)}`);
@@ -408,20 +408,20 @@ export class Curtain extends deviceBase {
408
408
  this.WindowCovering.PositionState = this.hap.Characteristic.PositionState.INCREASING;
409
409
  this.WindowCovering.Service.getCharacteristic(this.hap.Characteristic.PositionState).updateValue(this.WindowCovering.PositionState);
410
410
  this.debugLog(`${this.device.deviceType}: ${this.WindowCovering.CurrentPosition} INCREASING`
411
- + ` PositionState: ${this.WindowCovering.PositionState}`);
411
+ + ` PositionState: ${this.WindowCovering.PositionState}`);
412
412
  } else if (Number(this.WindowCovering.TargetPosition) < this.WindowCovering.CurrentPosition) {
413
413
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} Opening, CurrentPosition: ${this.WindowCovering.CurrentPosition} `);
414
414
  this.WindowCovering.PositionState = this.hap.Characteristic.PositionState.DECREASING;
415
415
  this.WindowCovering.Service.getCharacteristic(this.hap.Characteristic.PositionState).updateValue(this.WindowCovering.PositionState);
416
416
  this.debugLog(`${this.device.deviceType}: ${this.WindowCovering.CurrentPosition} DECREASING`
417
- + ` PositionState: ${this.WindowCovering.PositionState}`);
417
+ + ` PositionState: ${this.WindowCovering.PositionState}`);
418
418
  } else {
419
419
  this.debugLog(`${this.device.deviceType}: ${this.WindowCovering.CurrentPosition} Standby,`
420
- + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
420
+ + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
421
421
  this.WindowCovering.PositionState = this.hap.Characteristic.PositionState.STOPPED;
422
422
  this.WindowCovering.Service.getCharacteristic(this.hap.Characteristic.PositionState).updateValue(this.WindowCovering.PositionState);
423
423
  this.debugLog(`${this.device.deviceType}: ${this.WindowCovering.CurrentPosition} STOPPED`
424
- + ` PositionState: ${this.WindowCovering.PositionState}`);
424
+ + ` PositionState: ${this.WindowCovering.PositionState}`);
425
425
  }
426
426
  } else {
427
427
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} Standby, CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
@@ -447,7 +447,7 @@ export class Curtain extends deviceBase {
447
447
  this.LightSensor!.CurrentAmbientLightLevel = set_maxLux;
448
448
  }
449
449
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName}`
450
- + ` CurrentAmbientLightLevel: ${this.LightSensor!.CurrentAmbientLightLevel}`);
450
+ + ` CurrentAmbientLightLevel: ${this.LightSensor!.CurrentAmbientLightLevel}`);
451
451
  }
452
452
 
453
453
  // BatteryLevel
@@ -465,6 +465,11 @@ export class Curtain extends deviceBase {
465
465
 
466
466
  // FirmwareRevision
467
467
  this.accessory.context.FirmwareRevision = deviceStatus.body.version;
468
+ this.accessory
469
+ .getService(this.hap.Service.AccessoryInformation)!
470
+ .setCharacteristic(this.hap.Characteristic.FirmwareRevision, this.accessory.context.FirmwareRevision)
471
+ .getCharacteristic(this.hap.Characteristic.FirmwareRevision)
472
+ .updateValue(this.accessory.context.FirmwareRevision);
468
473
  }
469
474
 
470
475
  async refreshStatus(): Promise<void> {
@@ -530,7 +535,7 @@ export class Curtain extends deviceBase {
530
535
  this.debugWarnLog(`${this.device.deviceType}: ${this.accessory.displayName} deviceStatus: ${JSON.stringify(deviceStatus)}`);
531
536
  this.debugWarnLog(`${this.device.deviceType}: ${this.accessory.displayName} deviceStatus statusCode: ${deviceStatus.statusCode}`);
532
537
  if ((statusCode === 200 || statusCode === 100) && (deviceStatus.statusCode === 200 || deviceStatus.statusCode === 100)) {
533
- this.debugErrorLog(`${this.device.deviceType}: ${this.accessory.displayName} `
538
+ this.debugSuccessLog(`${this.device.deviceType}: ${this.accessory.displayName} `
534
539
  + `statusCode: ${statusCode} & deviceStatus StatusCode: ${deviceStatus.statusCode}`);
535
540
  this.openAPIparseStatus(deviceStatus);
536
541
  this.updateHomeKitCharacteristics();
@@ -704,17 +709,17 @@ export class Curtain extends deviceBase {
704
709
  this.WindowCovering.PositionState = this.hap.Characteristic.PositionState.INCREASING;
705
710
  this.setNewTarget = true;
706
711
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} value: ${value},`
707
- + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
712
+ + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
708
713
  } else if (value < this.WindowCovering.CurrentPosition) {
709
714
  this.WindowCovering.PositionState = this.hap.Characteristic.PositionState.DECREASING;
710
715
  this.setNewTarget = true;
711
716
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} value: ${value},`
712
- + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
717
+ + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
713
718
  } else {
714
719
  this.WindowCovering.PositionState = this.hap.Characteristic.PositionState.STOPPED;
715
720
  this.setNewTarget = false;
716
721
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} value: ${value},`
717
- + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
722
+ + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
718
723
  }
719
724
  this.WindowCovering.Service.setCharacteristic(this.hap.Characteristic.PositionState, this.WindowCovering.PositionState);
720
725
  this.WindowCovering.Service.getCharacteristic(this.hap.Characteristic.PositionState).updateValue(this.WindowCovering.PositionState);
@@ -751,7 +756,7 @@ export class Curtain extends deviceBase {
751
756
  this.accessory.context.CurrentPosition = this.WindowCovering.CurrentPosition;
752
757
  this.WindowCovering.Service.updateCharacteristic(this.hap.Characteristic.CurrentPosition, Number(this.WindowCovering.CurrentPosition));
753
758
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} updateCharacteristic`
754
- + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
759
+ + ` CurrentPosition: ${this.WindowCovering.CurrentPosition}`);
755
760
  if (this.device.mqttURL) {
756
761
  this.mqttPublish('CurrentPosition', this.WindowCovering.CurrentPosition.toString()); // Convert to string
757
762
  }
@@ -765,7 +770,7 @@ export class Curtain extends deviceBase {
765
770
  this.accessory.context.PositionState = this.WindowCovering.PositionState;
766
771
  this.WindowCovering.Service.updateCharacteristic(this.hap.Characteristic.PositionState, Number(this.WindowCovering.PositionState));
767
772
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} updateCharacteristic`
768
- + ` PositionState: ${this.WindowCovering.PositionState}`);
773
+ + ` PositionState: ${this.WindowCovering.PositionState}`);
769
774
  }
770
775
  if (this.WindowCovering.TargetPosition === undefined || Number.isNaN(this.WindowCovering.TargetPosition)) {
771
776
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} TargetPosition: ${this.WindowCovering.TargetPosition}`);
@@ -776,7 +781,7 @@ export class Curtain extends deviceBase {
776
781
  this.accessory.context.TargetPosition = this.WindowCovering.TargetPosition;
777
782
  this.WindowCovering.Service.updateCharacteristic(this.hap.Characteristic.TargetPosition, Number(this.WindowCovering.TargetPosition));
778
783
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} updateCharacteristic`
779
- + ` TargetPosition: ${this.WindowCovering.TargetPosition}`);
784
+ + ` TargetPosition: ${this.WindowCovering.TargetPosition}`);
780
785
  }
781
786
  if (this.WindowCovering.HoldPosition === undefined) {
782
787
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} HoldPosition: ${this.WindowCovering.HoldPosition}`);
@@ -787,12 +792,12 @@ export class Curtain extends deviceBase {
787
792
  this.accessory.context.HoldPosition = this.WindowCovering.HoldPosition;
788
793
  this.WindowCovering.Service.updateCharacteristic(this.hap.Characteristic.HoldPosition, this.WindowCovering.HoldPosition);
789
794
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} updateCharacteristic`
790
- + ` HoldPosition: ${this.WindowCovering.HoldPosition}`);
795
+ + ` HoldPosition: ${this.WindowCovering.HoldPosition}`);
791
796
  }
792
797
  if (!this.device.curtain?.hide_lightsensor) {
793
798
  if (this.LightSensor!.CurrentAmbientLightLevel === undefined || Number.isNaN(this.LightSensor!.CurrentAmbientLightLevel)) {
794
799
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName}`
795
- + ` CurrentAmbientLightLevel: ${this.LightSensor!.CurrentAmbientLightLevel}`);
800
+ + ` CurrentAmbientLightLevel: ${this.LightSensor!.CurrentAmbientLightLevel}`);
796
801
  } else {
797
802
  if (this.device.mqttURL) {
798
803
  this.mqttPublish('CurrentAmbientLightLevel', this.LightSensor!.CurrentAmbientLightLevel.toString());
@@ -830,7 +835,7 @@ export class Curtain extends deviceBase {
830
835
  this.accessory.context.StatusLowBattery = this.Battery.StatusLowBattery;
831
836
  this.Battery.Service.updateCharacteristic(this.hap.Characteristic.StatusLowBattery, this.Battery.StatusLowBattery);
832
837
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} updateCharacteristic`
833
- + ` StatusLowBattery: ${this.Battery.StatusLowBattery}`);
838
+ + ` StatusLowBattery: ${this.Battery.StatusLowBattery}`);
834
839
  }
835
840
  }
836
841
 
@@ -195,13 +195,13 @@ export abstract class deviceBase {
195
195
  if (device.offline !== undefined) {
196
196
  config['offline'] = device.offline;
197
197
  }
198
- if (device.maxRetry !== undefined) {
198
+ if (device.maxRetry !== 0 ) {
199
199
  config['maxRetry'] = device.maxRetry;
200
200
  }
201
- if (device.webhook !== undefined) {
201
+ if (device.webhook === true) {
202
202
  config['webhook'] = device.webhook;
203
203
  }
204
- if (device.connectionType !== undefined) {
204
+ if (device.connectionType) {
205
205
  config['connectionType'] = device.connectionType;
206
206
  }
207
207
  if (device.external !== undefined) {
@@ -479,6 +479,11 @@ export abstract class deviceBase {
479
479
  device.bleModel = SwitchBotBLEModel.Unknown;
480
480
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} Model: ${device.model}, BLE Model: ${device.bleModel}`);
481
481
  break;
482
+ case 'Robot Vacuum Cleaner S10':
483
+ device.model = SwitchBotModel.RobotVacuumCleanerS10;
484
+ device.bleModel = SwitchBotBLEModel.Unknown;
485
+ this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} Model: ${device.model}, BLE Model: ${device.bleModel}`);
486
+ break;
482
487
  case 'Ceiling Light':
483
488
  device.model = SwitchBotModel.CeilingLight;
484
489
  device.bleModel = SwitchBotBLEModel.CeilingLight;
@@ -509,6 +514,11 @@ export abstract class deviceBase {
509
514
  device.bleModel = SwitchBotBLEModel.Unknown;
510
515
  this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} Model: ${device.model}, BLE Model: ${device.bleModel}`);
511
516
  break;
517
+ case 'Battery Circulator Fan':
518
+ device.model = SwitchBotModel.BatteryCirculatorFan;
519
+ device.bleModel = SwitchBotBLEModel.Unknown;
520
+ this.debugLog(`${this.device.deviceType}: ${this.accessory.displayName} Model: ${device.model}, BLE Model: ${device.bleModel}`);
521
+ break;
512
522
  default:
513
523
  device.model = SwitchBotModel.Unknown;
514
524
  device.bleModel = SwitchBotBLEModel.Unknown;
@@ -599,15 +609,23 @@ export abstract class deviceBase {
599
609
  /**
600
610
  * Logging for Device
601
611
  */
612
+ infoLog(...log: any[]): void {
613
+ if (this.enablingDeviceLogging()) {
614
+ this.log.info(String(...log));
615
+ }
616
+ }
617
+
602
618
  successLog(...log: any[]): void {
603
619
  if (this.enablingDeviceLogging()) {
604
- this.platform.log.success(String(...log));
620
+ this.log.success(String(...log));
605
621
  }
606
622
  }
607
623
 
608
- infoLog(...log: any[]): void {
624
+ debugSuccessLog(...log: any[]): void {
609
625
  if (this.enablingDeviceLogging()) {
610
- this.log.info(String(...log));
626
+ if (this.deviceLogging?.includes('debug')) {
627
+ this.log.success('[DEBUG]', String(...log));
628
+ }
611
629
  }
612
630
  }
613
631