Renaming inputs stops logging

Renaming the inputs has broken the logging.
Can anyone explain how this is working under the hood so I can get a better understanding please?
Seems like a bug, as I would have thought there would be an id for the input rather than keying on the name. But another post I found afterwards suggests this is expected behaviour.

Where did you rename them?

Is there more than one place I can access the inputs?

That would depend very much on what ā€œthisā€ is

Depending on application, either can be used.

Yes, that stems from the inputs database using the same field for either a numerical id or name, depending on itā€™s source/ configuration. There has been some development to use separate fields so that both index and name can be used as opposed to one or the other. that has since stalled unfortunately.

If you change the name for an input that is receiving data using a key:value api (or MQTT) then a new input will be created when the next data arrives with the original name, thus the newly named input stops updating.

You could set the name at source? eg If itā€™s an emonSD image with emonhub installed the name change should occur there first so that it sends the data with the new name, then the original input with a new name will start updating again, you can then delete the surplus input created and now not updating.

Yoiu can use indexes instead if you prefer, depending on the source.

I do not know the architecture, so ā€˜thisā€™ would be a general idea of how the ā€˜inputsā€™ map to the ā€˜feedsā€™ and the transport mechanism, which I believe is called mqtt. I am not familiar with it and I am not ready to yet. I only bought the emonpi about 3 weeks ago and the emontx 2 weeks ago, so I am trying to sort out the configuration so I can get monitoring in place.

I would not have expected to be able to change the configuration so that data logging breaks. For me that is a bug. It should be prevented or at least warned against. However, it is what it is and it is broken so I am frustrated that just at the point it all started to work, it all stopped working and I have to do the configuration all over again.

However I should say, thank you @pb66 for taking an interest in my comment and spending time discussing it.

Hello @NickC, yes Iā€™m afraid renaming an input will break the configuration, it uses the nodeid and name as the unique identifier to identify the input, so changing the name causes a new input to be created. You can set a description for each input and that is independent and will not break the configuration

Thanks @TrystanLea. I wish I hadnā€™t felt the need to fiddle!
And I now have another problem that didnā€™t exist before.

I have long periods where there are no values recorded on feeds such as use and solar, but the use_kwh seems to be updating.
The corresponding inputs have updating values and I havenā€™t configured the inputs to write to the same feed, so one is not overwriting the other.
The period the 2 feeds (use/solar) seem to stop logging correspond, as can be seen from the graph screenshot below.
Other feeds are continuing to update, such as the battery_charge.
These feeds correspond to the 3 sensors Iā€™ve installed.

Can anyone help me understand what is going wrong and how to fix it please?

Hello @NickC , any chance you could post a screenshot of your inputs page with the little blue tags for the processes visible?

P1
image

P2
image

P3

Iā€™m seeing all sorts of stuff going on that look like relics of previous configuration, such as the feed updating every 5 secs (as per previous emonpi input config), but as itā€™s the tx it only updates every 10 secs, so in the feed I see a +ive input value followed by 0 followed by +ive input value etc. But then there are these long periods with no value in the feed at all.

Iā€™m starting to think I should do a factory reset and start again. At least I am starting to get an idea of what not to do next time!

Iā€™m starting to trawl the config to find clues, and now I can see why renaming the inputs is a fatal flaw!
image

In the next release perhaps you could remove the option to edit the input nameā€¦

Thanks @NickC

input configuration all looks fine

on the graph view there is a show missing data checkbox at the top, does the graph show lots of missing data if you tick this? i assume likely not, so I think there are two sources of data colliding somewhere, do you just have the one emonpi? did you change the emoncmsorg interfacer or mqtt interfacer config in emonhub at all?

I kept the old input config on the emontx for reference as the config isnā€™t straightforward. Could that be the conflict?
Iā€™ve just removed it.

And no I havenā€™t touched the config on the emonpi at all.

Nopeā€¦ made no difference

when the feeds are zeroing are the inputs zero as well?

No, the inputs have value != 0

Might have spoken too soon. Hereā€™s a typical hour earlier today

And here is the last hour since I removed the other input config

Fingers crossed that was what was wrongā€¦

1 Like

Values are low as I havenā€™t included the battery discharge feed

1 Like