* feat: add api for device re-interview
- Adds an API that allows for the re-interview of a device. This can be
useful a device firmware upgrade adds new device endpoints (as is the case
when upgrading an Inovelli VZM31-SN to 2.18). Without the ability to
re-interview, one must remove and re-add the device.
* rename from reinterview to interview
* publish devices after interview.
* only allow device ids or names, not endpoints
* (feat) Expose Custom Clusters in MQTT
- Introducing bridge/definitions
- Updating test case for custom clusters
- Updating new path after ZCL revamp with 0.47.0
This change is needed for nurikk/zigbee2mqtt-frontend#2001
* Fixing test case
* Update lib/model/device.ts
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
* Update test/bridge.test.js
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
* Removing the publishDefinition call from some events. updating tests
---------
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
* Add function resolveEntityByID() function as an improved alternative for parseEntityID()
* Port deviceGroupMembership.ts from parseEntityID() to resolveEntityByID()
* Migrade groups.ts from parseEntityID() to resolveEntityByID()
* Improve test coverage on groups functionality
* Migrate from parseEntityID() to resolveEntityByID() for bridge functionality
* Migrate from parseEntityID() to resolveEntityByID() for bind functionality
* Finally get rid of parseEntityID() function
* Fix linter issues
* Move resolveEntityAndEndpoint() function to zigbee.ts
---------
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
* Add endpoint matching based on the endpoint names list in the device definition
* Cleanup debug prints
* Correct creating endpoint names list, filter out null elements
* Correct test due to slightly changed behavior
* Fix endpoint name lookup when converter does not provide full name-to-id mapping
* Simplify topic name matching
* Remove obsolete branches, improve code coverage
* Make linter happy
* Make linter happy
* Remove dependency on endpoint names while removing device from all groups
* Get rid of predefined list of endpoints when processing group state update
---------
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
* Update homeassistant.ts
* Update homeassistant.ts
* Update homeassistant.ts
* Update homeassistant.ts
* Remove entity_category and add some icons and device classes
* Remove device_class for calibrated because of inverted state mapping
* emit event on converter triggers
* use meta.deviceExposesChanged() instead
* add ExposesChanged event for homeassistant discovery
* add tests for receive.ts and homeassistant.ts
* Add exposes starting with 'config' or 'diagnostic' to respective Home Assistant categories
* alt proposal: default category based on new Expose property
* Use single category 'system' instead of 'config' and 'diagnostic'
* Revert "Use single category 'system' instead of 'config' and 'diagnostic'"
This reverts commit 416dd9c568.
* lint