Customize and reference mysensor sensors in configuration
-
Hi!
Just got Home Assistant set up with a Mysensor MQTT gateway and it works like a charm. I get my sensors discovered as soon as they start sending data and they show up fine in Home Assistant.
Now I'd like to customise my devices (sensors) and also group them together but I cannot figure out how to reference them in the configuration?
It's a bit frustrating, I'm a professional system developer, working with yaml configs all day long :). I feel like I'm either stupid, or the documentation is leaving out big chunks of information...
Is the mysensor gateway a "platform"? How do I name each sensor and what type of properties can I set on them? I'd like to give each sensor some friendly name, perhaps an entity picture and then group them together, is that doable?
The only config examples I can find are related to setting up the gateway, which I already have done. If someone has a
configuration.yaml
doing some more stuff with the mysensor integration than just enabling the gateway, like referencing the sensors, it would fantastic if you could share it here as a reference.
-
I think what you are trying to achieve is more controller related than mysensors. In mysensors each sensor has a child ID and they are grouped under the Node ID, but besides that I don't think you can ask more to mysensors
-
Ok, but does that mean that I can reference each sensor in the hass configuration.yaml using
node-id
.child-id
? Or do I need to use some mysensor prefix?Like this:
customize: 170.0: entity_picture: https://example.com/images/humidity.jpg friendly_name: Living room humidity 170.1: entity_picture: https://example.com/images/temp.jpg friendly_name: Living room temperature
-
I'm sorry, I can't answer that as I haven't used Home Assistant
-
@gohan said in Customize and reference mysensor sensors in configuration:
I'm sorry, I can't answer that as I haven't used Home Assistant
Ok, you're aware that this is the Home Assistant controller support forum, right?
Anyway, figured out how to reference the sensors by looking in the code and the log files. The format is:
sensor.<sketch-name>_<node-ID>_<child-ID>
. Example:sensor.temperatureandhumidity_170_0
.Sketch name is the name sent during presentation using the
sendSketchInfo()
method and should be in all lower case,Using this naming pattern I was able to set a friendly name on my humidity sensor like so:
homeassistant: ... customize: sensor.temperatureandhumidity_170_0: friendly_name: Guest room humidity
-
I am glad you figured it out
-
I also just found that you can find all entity names of all registered devices in the developer tools > states view (just click the
< >
icon under developer tools).Grouping the mysensor sensors is done like this, using the entity names as described above:
group: name: Guest Room entities: - sensor.temperatureandhumidity_170_1 - sensor.temperatureandhumidity_170_0
-
Hi!
All the answers that you've already found yourself should be available on these two pages, except the structure of entity_ids for mysensors devices. The latter is something we should add to the docs.
https://home-assistant.io/docs/configuration/devices/
https://home-assistant.io/docs/configuration/customizing-devices/
Suggested Topics
-
Forum Theme Problems
Announcements • 8 Apr 2014, 07:05 • hek 8 Apr 2014, 07:05 -
mysensors regularly disconnect from HA
Home Assistant • 1 Oct 2021, 20:25 • keithellis 29 Aug 2023, 18:09 -
How I delete a node from HA and start over.
Home Assistant • 18 Oct 2024, 02:05 • OldSurferDude 18 Oct 2024, 02:05 -
2x BME 280 on 2x arduino nano hangs in HomeAssistant
Home Assistant • 27 Jul 2024, 12:25 • HJ_SK 11 Aug 2024, 19:56 -
Node 2 is unknown warning in Homeassistant.
Home Assistant • 10 Mar 2019, 19:27 • badisensors 15 Oct 2024, 20:33 -
Home Assistant update changed USB port name
Home Assistant • 14 Jan 2024, 17:25 • therik 15 Jan 2024, 10:26