I'm a little bit confused how to configure extended capabilities for the entities in the MQTTController.
mqtt_cababilities.yaml states that: "...You can add your own capabilities by adding a "capabilities" section to your own local_mqtt_capabilities.yaml file in your config directory."
So I did this in my local_mqtt_capabilities.yaml in the config directory:
version: 22353
revision: 1
format: 1
capabilities:
x_my_config:
attributes:
partyMode:
type: bool
actions:
some_action:
topic: '%topic/write'
payload: "some value"
And in my reactor.yaml I have following configuration entry:
my-config:
name: 'My custom configuration'
topic: 'my-config'
query: "%topic%/read"
init: "%topic%/read"
capabilities:
- x_my_config
primary_attribute: x_my_config.partyMode
events:
"%topic%/status":
"x_my_config.partyMode":
json_payload: true
expr: "payload.partyMode"
This sort of works but not quite. The partyMode attribute gets updated when messages arrive for that specific topic, so that's fine. But I don't see x_my_config capability in the Capabilities list in the UI and also the some_action is missing.
Screenshot from 2023-03-09 19-42-49.png
Addition to that the primary value is not set and I'm getting the following error:
Screenshot from 2023-03-09 19-30-42.png
Have I completely misunderstood the idea behind the capability extension and the attributes? If so, could someone point me to the right direction with few explanatory example configs.
What I'm trying to achieve is a set of configuration options that could be updated thru the MQTT, and also provide some actions that the rules could invoke.
Reactor (Multi-hub) latest-23063-c464b685 + MQTTController [0.1.23010]
br,
mgvra