Fantastic! It’s not a zero any more 2024.10.1 has just been released, you’ve no excuse now
Does this release affect the emoncms_history integration that I currently use to export data from HA to emoncms.org?
No, Emoncms Hisotry is a separate integration which is not effected by the UI upgrade to the Emoncms integration. Emoncms history still requires using YAML.
Here’s a few screenshots of what the user journey looks like to setup Emoncms integration on Home Assistant when running 2014.10 +. It’s now very straightforward:
1. Add the Emoncms integration
Settings > Devices and Services > Add new Integration > Search for ‘Emoncms’
2. Enter Emoncms URL & API
This will usually be https://emoncms.org, or a local emonpi e.g http://emonpi.local
The API key can be found on the Emoncms account page, you should enter the read-only API. Both API keys will work, but there’s no reason for HA to require write access, so it’s safer and best practice to use the read-only key.
3. Select the Emoncms Feeds you want in Home Assistant
It’s possible to add multiple Emoncms integrations e.g pull data from both emoncms.org and emonpi.local. To add a 2nd instance choose ‘Add Entry’ in Devices & Services > Emoncms
Blockquote No, Emoncms Hisotry is a separate integration which is not effected by the UI upgrade to the Emoncms integration. Emoncms history still requires using YAML
HA gave me a popup message this morning stating that Emoncms will not work if the YAML config is present and it needs it to be deleted for the UI integration to successfully work. Unfortunately I did not capture the pop up message but this was the gist of it. Seems at odds with your point above Glyn. Just wondering if anyone else come across this?
It is a bit confusing.
There is a EmonCMS sensor integration with is creating sensors FROM EmonCMS.
The EmonCMS History integration is sending from HA TO EmonCMS.
It would be good to get a clarification on the future of EmonCMS History.
This note said that it has imported the yaml config and that you should now delete the old entries in the configuration.yaml, as this will stop working next year.
You can delete the emoncms yaml section once imported into the UI, but leave the emoncms_history yaml section present.
Of course it’s worth doing a backup of the yaml and your whole installation before making changes.
Sorry, I’m totally lost by all this. Is there a TL;DR version?
I have an emoncms system; I have an HA system. In configuration.yaml I have
# configuration.yaml entry using local Emoncms
sensor:
- platform: emoncms
api_key: *** obfuscated ***
url: http://emonpi.fritz.box/
id: 1
scan_interval: 60
What if anything do I need to do before updating my HA system?
I have no idea what UUIDs are in this context I agree more units are needed % for humidity for example. Having kWh convert to energy increasing sounds wrong. My kWh go up when I’m consuming power and down when I’m exporting?
I’ve no idea what things like “use template sensors through the homeassistant template integration” mean? How do I find out?
I think it would be easiest if you told us what you want to achieve and then we’ll try to figure out how you can get there.
A unique id is an identifier which permits to identify a parameter in a unique manner in homeassistant. More here on unique ids in home assistant : Config flow | Home Assistant Developer Docs
It is a key which gives the ability to change the parameters through the UI :
When you click on settings :
You access to the configuration window :
if the entity has no unique id, home assistant does not allow to access to this configuration window
Template is an integration you can still manage both in yaml and via user interface. I think it is the only one but not sure…
for example, to modify feed values coming from the integration, you can use what they call jinja templating Below is a attempt to round some values :
template:
- trigger:
- platform: time_pattern
seconds: "30"
sensor:
- name: 'round-cellule_tcircuit'
state: "{{ states('sensor.emoncms_cellule_tcircuit') | round(0) }}"
unit_of_measurement: "°C"
device_class: temperature
- name: 'round-nordtcircuit'
state: "{{ states('sensor.emoncms_nordtcircuit') | round(0) }}"
unit_of_measurement: "°C"
device_class: temperature
This creates 2 new entities, named round-cellule_tcircuit
and round-nordtcircuit
from the entities created by the emoncms integration, here emoncms_cellule_tcircuit
and emoncms_nordtcircuit
When you use use the template integration in yaml, it creates entities without unique ids, so you will not be able to configure them through the UI…
There is a way to use the template engine through the UI. This requires to do things entity by entity, so it means a lot of clicks, but you will create entities with unique ids, so configurable through the UI
You find more details on how to use the template integration here : Template - Home Assistant
in emoncms, the same things can be achieved with the input processing
I thought I had? I want to update my HA system without destroying my existing emoncms integration. I gather some additional steps are required, so I’d like to know what those are?
OK, but as a naive user, I don’t expect or want to have to read developer docs! So in your example, is “[email protected] outdoor_humidity” the UUID? How was it chosen?
Sorry, I meant to ask what exactly is happening “downstream” of the integration. What can break in your setup? Do you just display the values of the emoncms sensors? Do you use them in your energy dashboard?
I don’t know what can break, but I’m scared something might because of this thread. Yes, at present I’m just displaying the values in my Overview.
Is the energy dashboard the display labelled Energy in the sidebar? It seems pretty useless. It has a solar graph where the forecast/estimate/prediction? (dotted line) seems to bear little relation to the observations (yellow bars). And it has an Energy usage chart that does indeed show usage bars but not when they go negative. And a rather silly animation that shows grid solar and home and some moving dots. So not something I use.
TBH I don’t use HA much. I just export the values from a bunch of Govee T&H sensors from it to emoncms.
That just means that you will have to update your overview to show the new sensors instead of the old ones - nothing can break for you.
Sorry I thought you were asking the question because you were curious about that. My mistake so but what is inside that part of the dev docs is only general knowledge about what is a unique id. I would have better linked to this Unique identifier - Wikipedia
No the “[email protected]” is not the uuid, it is the name, you can change it as you like. The uuid is something that it not available via the UI and that you cannot change. Actually if you have not migrated, you dont have any unique id…
For the question “what I have to do in order not to break my system ?” I would say that if your setup is simple, you will not break anything and if some things are not connected the right way because of the new names, it should be fairly simple to put things back in order. And there is a backup in homeassistant so you can also revert to a previous version
Yes I know what a UID is. I think in emoncms the feed ID is a UID. One thing that has puzzled me is that the emoncms HA integration seems to ignore the Tag. On my emoncms system, the Tag plus the name are also unique and what I use to refer to things. On HA I get multiple items called “EmonCMS rssi”, for example, which seems silly. Perhaps that improves in the new version?
The feed id is only unique within a single emoncms instance. It cannot be considered as a unique id. The unique id is something produced by a manufacturer like a serial number…
In HA, the new version of the integration defines for an entity its unique id as follow :
{entry_id}-{emoncms feed id}
where entry_id is a unique number generated by HA when you click on ADD ENTRY in the integration
In the future, this entry_id will be replaced by something produced by each emoncms install as emoncms (from version 11.5.7) can produce its own unique id, but that will be transparent
With the new version you will be able to modify the names to what you want. The tag is not inside the default name, as it was decided to produce the shortest default names possible…
But when you have to choose the feeds to import, the tag is chown in the selector so you can identify feeds clearly
The TL;DR is that because the integration was very old, and the development of HA has moved on significantly, there needed to be some significant updates to the integration which @alexandrecuer has put a great deal of time into.
Because it was so old, the update will break things - the new entities will have different names to the old ones.
It is unavoidable!! You will have to bear the pain.
Because you did not import a selected set of Feeds from emoncms, (which would be auto imported although the entities created would be new) you will need to select the Feeds after update, which will create new entities, and realign anything inside HA to match these new entity names. A pest but Hey Ho - there is no alternative.
Check you have the Units set in the Feeds on emoncms (just click edit the Feed in emoncms).