Incorrect COP calculation in HeatPump app

I have finally managed to get my ASHP to interface into the emoncms app!!! I am using a Kamstrup modbus heatpump monitor, a EMU modbus energy monitor, collected via a MOXA gateway and then to emon via MQTT using a Loxone miniserver. ( Works very well as I can directly control the ASHP’s flow temperature via a A1M modbus device connected to the same MOXA gateway. All the values, circulator etc are not under direct control of the ASHP. )

Anyway… onto my issue!

I am getting a very strange COP stated of 7.76 within the main window. It is MUCH higher than it really should be and increases when I scroll to include periods when the ASP is running. The calculation at the bottom seems much more reasonable at 3.48. See the screenshot.

What is going on? It seems like there could be a bug in the COP calculation.

How does the COP get calculated?

Does it use the l/min flow rate?

Does it use the electrical kwh feed in preference to the kw feed?

COP is simply the heat produced divided by the electricity consumed, which we can get from this bit of the table is 5.003 divided by 1.486 is about 3.37, which seems about right.


I don’t know why the app is display odd numbers for COP. Maybe there are some null values in your feeds that are confusing it. Maybe @TrystanLea can look into it?

Thank you. Some of the feeds were not getting updated when the values were zero. Not null values, just not being regularly updated with zeros.

I have updated the upstream config so that they are updated.

I will report back in a day or so to see if this has helped.

It looks like there is no flow rate in the tail end of that run?
What happens if you zoom in on that last 30 mins?

I think flow rate has to be zero, no null, otherwise the calcs get screwy.

heat output (W) = specific heat (4.2 water) x flow rate x DT

So those variables always need values, otherwise it can’t calculate would be my guess?

You can get all the heat output calcs direct from the heat meter, so not sure why/when the heatpump app chooses to do its own calcs?

This was exactly the problem… that null values were being passed rather than zeros. This was happening in the flow rate and the heat output.

I am passing both the heat output and flow rate. I think that the app uses the heat output, rather than recalculating.

Now I have applied a slight increase in the values being bassed (by adding 0.1) now the value are always being passed. Emon recognizes them as zero, rather than 0.1. Which is a little bit weird.

My COP calculation is now correct!

1 Like

You might find it better for the emoncms input processing to check for null and if it is, add that to the feed (rather than the null).

Not sure why you think it thnks it is a zero? You see that on the input page? How are you sending the data to emoncms? HTTP or MQTT?