Hi @mak-dev,
I did some more playing around (I would to like to know how to code…but this is still playing)
like mentioned yesterday I got it working (sort off).
The values are seen by enoceanmqtt and they do show up in Mosquitto. But when I look at the devices and entities only the button for [delete] and the RSSI value show up. Even tough I have values for EDIM, SW I cannot get Mosquitto to create an entity for a light.
This is my mapping part.
0x38: # start input heubie
0x08:
device_config:
command: "COM"
channel: "CMD"
log_learn: ""
entities:
- component: light
name: "State"
config:
state_topic: "SW"
state_value_template: >-
{% if value_json.SW == 1 %}on{% else %}off{% endif %}
- component: sensor
name: "Command ID"
config:
state_topic: ""
value_template: "{{ value_json.COM }}"
- component: light
name: "Brightness"
config:
state_topic: "2"
brightness_value_template: "{{ value_json.EDIM }}"
- component: number
name: "Timming"
config:
state_topic: "1"
value_template: "{{ value_json.TIM }}"
and these errors show up in Home-assistant.log when I restart EnoceanMQTT.
2023-02-03 16:10:03.924 ERROR (MainThread) [homeassistant.util.logging] Exception in async_discover when dispatching ‘mqtt_discovery_new_number_mqtt’: ({‘state_topic’: ‘enoceanmqtt/light/zitkuil_R/1’, ‘value_template’: ‘{{ value_json.TIM }}’, ‘unique_id’: ‘enocean_A53808_FF8CE884_Timming’, ‘name’: ‘e2m_light_zitkuil_R_Timming’, ‘device’: {‘name’: ‘e2m_light_zitkuil_R’, ‘identifiers’: ‘FF8CE884’, ‘model’: ‘A5-38-08 @FF8CE884’, ‘manufacturer’: ‘EnOcean’}, ‘platform’: ‘mqtt’},)
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/components/mqtt/mixins.py”, line 334, in async_discover
config: DiscoveryInfoType = discovery_schema(discovery_payload)
File “/usr/local/lib/python3.10/site-packages/voluptuous/validators.py”, line 232, in call
return self._exec((Schema(val) for val in self.validators), v)
File “/usr/local/lib/python3.10/site-packages/voluptuous/validators.py”, line 355, in _exec
raise e if self.msg is None else AllInvalid(self.msg, path=path)
File “/usr/local/lib/python3.10/site-packages/voluptuous/validators.py”, line 351, in _exec
v = func(v)
File “/usr/local/lib/python3.10/site-packages/voluptuous/schema_builder.py”, line 272, in call
return self._compiled([], data)
File “/usr/local/lib/python3.10/site-packages/voluptuous/schema_builder.py”, line 818, in validate_callable
return schema(data)
File “/usr/local/lib/python3.10/site-packages/voluptuous/schema_builder.py”, line 272, in call
return self._compiled([], data)
File “/usr/local/lib/python3.10/site-packages/voluptuous/schema_builder.py”, line 595, in validate_dict
return base_validate(path, iteritems(data), out)
File “/usr/local/lib/python3.10/site-packages/voluptuous/schema_builder.py”, line 433, in validate_mapping
raise er.MultipleInvalid(errors)
voluptuous.error.MultipleInvalid: required key not provided @ data[‘command_topic’]
Can you (or anybody else) to take that last step?