ReadonlyapiReadonlylogThis function is invoked when homebridge restores cached accessories from disk at startup. It should be used to setup event handlers for characteristics and update respective values.
This method is used to discover the your location and devices. Accessories are registered by either their DeviceClass, DeviceModel, or DeviceID
Asynchronously retrieves the version of the plugin from the package.json file.
This method reads the package.json file located in the parent directory,
parses its content to extract the version, and logs the version using the debug logger.
The extracted version is then assigned to the version property of the class.
A promise that resolves when the version has been retrieved and logged.
If device level logging is turned on, log to log.warn Otherwise send debug logs to log.debug
Validate and clean a string value for a Name Characteristic.
The display name of the accessory.
The name of the characteristic.
The value to be validated and cleaned.
The cleaned string value.
Verify the config passed to the plugin is valid
HomebridgePlatform This class is the main constructor for your plugin, this is where you should parse the user config and discover/register accessories with Homebridge.