Git Product home page Git Product logo

Comments (10)

kellerza avatar kellerza commented on June 27, 2024

Do you mean to the Device's description?

Device name you can specify in the configuration (Sunsynk/Deye/My inverter etc). Today it always adds the serial nubmber to that description

Why would you want to hide it?

from sunsynk.

cc120689 avatar cc120689 commented on June 27, 2024

mainly because I already had them configured like this without the name of the device in front, anyway it doesn't matter anymore I have modified the name showed so I will not suffer any more changes in future updates.
The thing about adding the name and the serial number in the entity_id of the sensors only started to happen in the last update
Now:
sensor.sunsynk_inverter_2112086414_pv1_power
Before:
sensor.pv1_power

from sunsynk.

kellerza avatar kellerza commented on June 27, 2024

Only noticed this today for the first time

It seems to be a change in the way HA assigns friendly_name: https://www.home-assistant.io/integrations/mqtt/#naming-of-mqtt-entities

The entity is a member of a device and entity.name is not None: friendly_name = f"{device.name} {entity.name}"

The device.name today is f"{MANUFACTURER} Inverter {SERIAL}". That should probably change to either just MANUFACTURER, or introduce a new NAME in settings.

Related to this is the entity_name, the entity.name should NOT include the SENSOR_PREFIX (as is the case today). Sensor prefix was meant for the entity_id, which seem to be the entity_object_id - so need to introduce entity.object_id = f"SENSOR_PREFIX {sensor.name}"

Comments welcome

from sunsynk.

cc120689 avatar cc120689 commented on June 27, 2024

Now I have everything configured again with the new entity ID, when I have a while I'll try adding a prefix to see if it replaces all that or simply adds it, I'll comment when I try it, thanks for your answer, you have a prefix ? With what id do your sensors appear?

from sunsynk.

cods4 avatar cods4 commented on June 27, 2024

he device.name today is f"{MANUFACTURER} Inverter {SERIAL}". That should probably change to either just MANUFACTURER, or introduce a new NAME in settings.

Sounds good. It should be an option in settings for each inverter. I.e I used to have INV1 PV1 Power, INV2 PV1 Power etc. Now it is 'Deye Inverter 734243290 PV1 Power'
I would like to be able to enter NAME: INV1, NAME: INV2... settings for each inverter
Or someone else might want to enter NAME: Sunsynk Inverter L1, NAME: Sunsynk Inverter L2, NAME: Sunsynk Inverter L3

from sunsynk.

kellerza avatar kellerza commented on June 27, 2024

Today we have ha_prefix per inverter and manufacturer as global setting. Can we work with these 2 only, or would you want a different name&ha_prefix per inverter. One for the entity object IDs and one for the pretty display

my preference is to have only the ha_prefix

from sunsynk.

cc120689 avatar cc120689 commented on June 27, 2024

It would be great if it could be customized to that level, manufacturer + num. serial is too long. I would prefer that adding the prefix overrides the global configuration and does not add a manufacturer.
Thanks for your attention!

from sunsynk.

cods4 avatar cods4 commented on June 27, 2024

Today we have ha_prefix per inverter and manufacturer as global setting. Can we work with these 2 only, or would you want a different name&ha_prefix per inverter. One for the entity object IDs and one for the pretty display

my preference is to have only the ha_prefix

You're right I forgot about the ha_prefix
For me just having ha_prefix & sensor_definition would work. The friendly name is important to some because voice assistants etc use it. It would be a pain if Home Assistant kept setting it back to some long string like it is now.

from sunsynk.

cc120689 avatar cc120689 commented on June 27, 2024

In any case, from your comment I understand that the id of the entity does not depend on your complement, but on the global configuration of Home assistant. I attached a screenshot so that it is completely clear what id I mean. If so, we can consider this petition closed and, as always, thanks for your work Kellerza, you have more and more followers in Spain!.
IMG_20230815_120041

from sunsynk.

kellerza avatar kellerza commented on June 27, 2024

Using just ha_prefix (per inverter) and manufacturer (global), I get the following

image

here you see the entity_id = sensor.ss_battery_current and the name = SS Battery power (without an override)

image

The only downside I see here is the SS as the name of the device (first picture). But since that forms the prefix to all the sensor's friendly_names there is no way to really improve this

from sunsynk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.