3-phase power consumption measurement

I think the 3em reports all three phases at once so you can total them up, or use individually, as required. (but I don't have one so can't confirm live :slight_smile: ).

Ah sorry for the noise then!
Thought that Paul was referring to you when he wrote above "By example, Colin plots his power every 1.3 seconds, I plot mine every 5 seconds.".

Yes indeed I think so when you look at the example message in their api. But when you want a chart like Paul with a value every 5 seconds, then the Shelly needs to send such a message every 5 seconds...

It depends upon what you consider acceptable, and what you intend to do with the readings.
This is the sort of power results that you may get, in this example, the smallest amount is about 15W, and the maximum is 4.25kW.

chart

It's not 'instead of', the two things are different units and tell you different things.
You would get the energy data direct from the Shelly's internal meter, that would be the most accurate, but you don't have to plot power if you don't want it. However, it's very useful to see how much power is being consumed in real time (remember our discussion about Particle Swarm Optimisation?)
Energy (kWh) is how your energy supplier bills you.
Power (W) tells you how much power is currently being used by your appliances

In most Shelly products, you can easily specify the update period for MQTT in 1 second increments (not sure if the minimum is 1 second???), but you can even make a status request by telling the shelly to do so via MQTT.

The wires only carry small amounts of current, so almost any cable will do, provided it is suitably insulated for the voltage. (Very thin wires!!)
For a Shelly 3EM, you would need just 4 wires, common, phaseA, phaseB and phaseC.

1 Like

Ok, ok, ok. The fog is starting to fading away in my head.
So this is for private usage only. When I e.g. turn my grinding machine on, you want to see the small peak it produces at startup. And when I should measure only the power, then that peak would be averaged across the measurement interval. Which means the peak would be flattened.

Hopefully I got it right now, because I must driving you guys nuts meanwhile :crazy_face:
I certainly need to develop some nodes before Christmas, to pay my debts in this community :rofl:

I assume that you meant "And when I should measure only the energy...".
If you plotted an energy chart, it would start at zero and gradually increase according to the rate of power being consumed. It would only ever increase, and never go down.
However plotting Power, that chart line would increase when more power is being consumed, and decrease when less power is being consumed.

Yes of course. Now I have started to drive myself nuts in the head :crazy_face:

Ah I thought that you would calculate the delta yourself (= last energy value - previous energy value)?

Most of these devices will do a running total for you - at whatever rate they are sampling at - typically (and i have not used the Shelly) they would give you something like energy per day (24 hours), per week, per month etc

The onus is on you to ensure you zero the totals when you first start and that you set the time and date correctly - including DST start and stop - otherwise your daily totals will start and stop at different times.

For instance with the power plugs running tasmota they will keep daily, weekly (and most of them) monthly totals that you can query and get back.

Some of them have weird implementations that you need to check out - for instance some will not keep the previous days total - so you need to query that and store it at 11:59PM

Craig

1 Like

In my node-red-contrib-watt2kwh node I convert power to energy, so yes you can reverse that process, if that's what you want to do.
The power reading has already been converted to a energy amount in the shelly, so you could use a simple calculation to change it back again, something like;

  • Present energy reading - previous energy reading (result will be in watt-minutes)
  • Calculate the time in seconds between the present energy reading - previous energy reading (using the epoch stamps from the shelly)
  • Multiply the time x watt-minutes = average power being used in Watts

Obviously using the raw power data processed by the shelly would be the best source to use - if you sampled it often enough, but there is nothing to stop you 'reverse engineering' the energy data.

1 Like

I store the raw watts data in influxdb. Then if you want the usage over a period (over a day for example) you can use an influx query to integrate it into kWh to get the total for the day, or the running total during the day, or whatever you want. I use it to check my monthly bills for example.

Just a thought Bart, but do you have some kind of impulse leds on the meter, that flash based on load :wink:
I do have a smart meter but found this the easy way to get the usage info from it !

@smcgann99,
That is an idea I have been playing in the past. But after having the above discussion, I will go all the way with a way oversized solution for my purpose :wink:

Well that all makes sense. Seems indeed a lot more information when you capture the power.
Although in this discussion they advice to do the opposite...

That's interesting Bart.

I've known dBC in the openenergymonitor forum for must be 7 or 8 years at least, and I hold him in the highest regard, but isn't he talking about the alternative firmware presented by cab123?

In the alternative firmware, it appears that it takes a snapshot from the power register every 10 seconds, which may, or may not coincide with transient power data.
That reading may give a false impression that the transient reading was consistent for the whole 10 seconds, and therefore be inaccurate.

In my firmware, which I publish every 5 seconds, the power register is averaged over the 5 seconds, and published as a mean value, and I would have thought that Shelly would also be doing the same (disappointed if not :flushed:)

I'm expecting your next post will be then what's the difference?

  • Using the power register which averages the values before publishing...
    or
  • Using the energy register to re-calculate, and create the power data.

Maybe less processing time? Precision lost through calculations? Your choice :wink:

1 Like

It may seem low tech, but is totally none invasive and could be worth doing as well as any other method as a double check.

I just taped a TSL257-LF High-sensitivity light-to-voltage optical converter over the LED and connected to a spare GPIO configured as a counter, on a near by ESP 2866 running Tasmota.

Very low cost, very accurate because it counts exactly what the meter does.
Easy to calculate other figures from the meter reading then, eg hourly daily weekly etc.

I have it send the count every 10 seconds, so can also calculate the average load in the last 10 seconds. Which is near enough real time for me.

Other high load devices have monitoring plugs and a couple of PZEM004. So those devices can be subtracted from Meter reading and show as "other" on my data.

I'm still going around the house with more monitoring plugs to reduce the "other" value as much as I can :wink:

5 Likes

@smcgann99 - I wonder how much energy is used by all of your monitoring devices themselves :grin::grin::grin:

2 Likes

Hard to say but they are less than 1W each.

I use some to turn off my TV and SKY box when not in use to save on standby power of around 20W !!!

So they do pay for themselves :wink:

2 Likes

Yes, I do the same.
Teasing aside, I checked the power usage of my Sonoff's & Shelly's a while ago, and agree, it's negligible.

1 Like

Sorry for the delay for responding :flushed:

Yes absolutely correct, it is about alternative firmware on the Shelly. But that discussion caught my eye, because they talk about some interesting use cased. For example this:

From our above discussion I thought that it would be better to measure the power at high sample rates (e.g. 1 measurement per few seconds), to have the current reading instead of an average reading. But from the above screenshot I understood that they don't want to see the fluctuations. Or perhaps I am interpreting it incorrectly... Because I should think it might be interesting to see the fluctuations. And when you zoom out in your chart, that you show the average (or maximum) of the values.

Thanks for sharing the details! Makes sense what you are doing. And indeed 100% non-invasive... Might give that a thought in the future.

I have such a blinking led for my solar production, where I could use it. But don't have it on my old classic meter of the metering company.
And I need to have a more fine grained analysis of my energy consumption also, because the wife is wondering which devices are causing high consumption.

Haha. That was also my initial idea, but had no time for it meanwhile. So therefore I would like to have a setup that monitors my circuits automatically. Otherwise it even won't happen in the next 20 years (which I know 100% for sure based on the extrapolation of my past 49 years :wink: ).

I don't know what the internal sampling rate is in the Shelly, but I would expect it to be 1,000's of times a second, otherwise it would not achieve it's accuracy.
By example, my firmware samples every 400 microseconds.
So internally, the readings are calculated to continuously provide the present power being consumed, and usually (but not in the alternative firmware which you mention above) the device will calculate the mean average of power usage between each successive output reading, so if the shelly is programmed to output it's reading every second, you will get the mean average for the previous second, which will give you the granularity to see for example a induction hob, pulsing power.
If you programmed it to output it's reading every 10 seconds instead, you would probably get just a straight line on your chart showing the average over the previous 10 seconds.

So, if you used the the 1 second data output for a chart, yes, you can zoom in to see the most detail, or out to show the average of (the averaged 1 second readings) - if you follow me :wink:

1 Like

Hi @edstobi,
My final plan above was to go full scale for a Shelly based approach. And today they have 25% discounts on their em products. So I grabbed my electricity drawings from the cubbet, and started counting what I needed. But it was still way too expensive. And after all it is about saving energy (and money), not about spending piles of money to an energy management system...

So I would like to experiment with a wt32-eth01 (which I am really fond of) in combination with a series of pzem-004t v3 devices. I would really appreciate a LOT if you could share some more details. Like a wiring diagram, experiences, links to where you bought your materials (like e.g. the green terminal blocks, ...), or other stuff that can get me started...

I am also not sure how thick the wires should be (both for the current and voltage inputs). And also not sure how to connect N of these devices to a single phase, so that the (230V) wiring is nicely done and safe.

So if you (or others of course) can help me with that, then I will have more free time left to develop new nodes for this community :wink:

Thanks!!!

Bart,

You can get these from lots of places, prices vary on Aliexpress now I found this - Pzem004

Not sure what you mean about green terminal block ? This device has screw conectors built in.

And also not sure how to connect N of these devices to a single phase

You would need to connect the mains voltage feed to each pzem, to the same phase that its loop is connected to.

Some usefull info here - https://github.com/arendst/Tasmota/discussions/10567