Looking for guidelines on using LED indicators on a Dashboard

I have not modified the file, after it was mentioned that doing so could break the update process. But the values in the file running in my installation of EmonPi are not in thousands, they are single integer values like
(status>3 && status <=4) { // Purple.
And now that I typed that, I see they actually DID isolate values by using <=4 in that one, and then using >4 in the Yellow one below it. THAT is why I ended up with Purple. So I was in error thinking they overlapped. They don’t. My mistake. I copied the values into the reference notes I am using here simply as noted above, without the <= included. So my list posted above is wrong.

I’ve flagged that post and asked if I could fix it to list the correct values.

Eventually, I finally worked out the kinks, and have an LED correctly displaying whether my heat pump is running or not. Here is how I did it:

It’s a bit strange for me not having statements like If/Then/Else, Gosub, Return, and End. But I managed to do it with the provided tools. I am guessing those who set this up were wanting to keep the number of available instructions to a minimum. I would like to see a way to add remarks, though. Or maybe to generate our own line numbers. I had to get creative and assign some imaginary line numbers on the flowchart I drew to do this, and then convert them to the actual process line numbers once it was all typed in.

Again, thanks for the help!

If you click on the ellipsis symbol (...) at the bottom of the post you want to edit, you should see a “pencil” symbol with the pop-up “edit this post”.

I’m past the allowable time limit to edit it. I’ve flagged it and asked if I may go back and edit it somehow. Thanks.

I don’t think I can extend your limit or allow you to go back. Write the text you’d like to have in a PM to me and I can edit it for you.

But don’t worry about it - things like that are easily missed. I was afraid you thought - and others might pick up - that the original code was wrong, so I thought I’d better point it out.

@Robert.Wall

Message sent. Thanks!

Here’s my latest update on my Power Dashboard. I have figured out how to utilize LEDs not only to indicate relative “on” or “off” conditions (ignoring small vampire wattage on certain circuits) as well as how to indicate what things are running on the same branch circuit by changing the LED color. For example, a vent fan that pulls 160 watts and another on the same circuit that pulls about 300 watts (an attic roof ventilator). So if the draw is 160, its the vent fan, if it is 300 it is the attic fan, and if both are running the draw would be over 400 watts. I have a different color displayed on the same single LED for each of those 3 values. I did the same kind of thing for a different attic ventilator on the same circuit as an outdoor yard light.

I learned the hard way to always filter for values starting with the largest anticipated target value and working your way down to the smallest, or 0. I wish the Input process list had the ability to drag a line into the sequence you want it. Creating each new line at the bottom and clicking it up a dozen times to get it up top taught that very quickly. :grin: