SmartShunt contribution to "DC Power" display is incorrect

This isn’t adding up. Specifically, the “DC Power” box seen on a Venus OS / Raspberry Pi display doesn’t seem to account for the DC loads correctly, and that the SmartShunt’s contribution is to blame. How is the math supposed to work?

Background: I’ve got a small semi-off-grid system, with power inputs from a Victron MPPT Solar charger and a DC power supply acting as the “AC Mains”. The DC power supply is monitored with a SmartShunt in DC Monitoring mode, set as an “AC Charger”. There’s a 315AH LiFePO4 battery, monitored via its own JBD-BMS that is connected into the Venus system with an OverkillSolar USB module. Loads consist of a Victron Phoenix inverter, along with some direct (unmonitored) 12v DC loads. The MPPT, Inverter, and SmartShunt are all connected with VE.Direct USB cables.

I was hoping that the Venus display’s DC Power box would show that net DC load on the system, but it’s not. For example, the real DC load on the system (measured with a clamp meter) is about 30w. With this DC load on the system I see a negative 60-ish watts being reported as DC Power. Significantly, at the time the DC Supply was contributing about 90 watts. Turning off the DC Supply (taking its contribution zero) doesn’t change the actual DC load, but I see the DC Power box now report a positive 30-ish watts, which is about where it should be. Adding a large (720w) load to the battery, the DC Power shows a large positive number (though not quite large enough), and changing the AC load from the Inverter correctly does not change the reported DC power, so at least those parts seem to be ok. Bottom line it seems like the Shunt specifically isn’t being handled correctly, that there’s an issue with the sign of its contribution. Also that the BMS data isn’t quite right, either, since turning off the DC supply would have increased the battery load to compensate. I tried swapping the shunt’s wires (so it reads negative vs positive) but that makes no difference in the DC Power reading. So Venus is incorrectly overriding the sign of its contribution, messing up the calculation of DC Power as a result.

Besides trying to swap the Shunt’s wiring, I also tried classifying it as a generic DC Source instead of an AC charger, but there was no change in behavior. Setting it to a Generic Load (instead of a Source) annoyingly causes it to disappear on the V2 GUI, but there’s still no change in the DC Power box.

How do I get the SmartShunt to behave, so that the computed DC Power reads correctly? How is the math behind the DC Power box supposed to work?

Thanks!

From the description, the behavior is normal and expected. The DC Loads is a derived value, and its sign indication of the direction of net power flow. (In this case + is flow to the loads, and - is flow from the loads.)


In this image, the AC Charger is a Smartshunt monitoring an external charger putting out 75A (4kW).
DC Loads represents (+) current drawn by (non-Victron) inverters, and the (-) current from the charger.
Note the charging power flowing into the battery. It is the sum of Solar charger output, AC charger output, less power consumed by the inverters (920W).

So, I see your math, but I can’t fathom why the computed DC Power can be positive or negative depending on circumstances. Regardless which sign you assign to it, it’s a load and always a load; it’s not possible to get power from it. Am I not understanding what the computed “DC Power” is actually indicating?

Turning off the power supply (measured by the Shunt), and leaving the 12v DC loads unchanged, rebalances the overall flow of power. A few minutes ago I had enough solar input, plus a little DC power (via the Shunt) to satisfy the Inverter and still put a little into the battery. Turning off the DC supply caused the expected reduction of battery charging current equal to the loss of DC input. The real DC load did not change, but the computed DC Power displayed by Venus DID. In my mind, it should not.

Since I have meters on all of the power sources and sinks (Solar, Power Supply, Battery, and Inverter) except for the 12v DC loads, the computation of inputs minus outputs should exactly account for and display only those DC loads, plus a little for, say, inverter inefficiency and a tiny bit of wire loss. No?

What am I missing?

The twist in this is we want +/- numbers to be arithmetic, and on the Venus display, they are symbolic logic.
The +/- here represent flow to or from a “nexus”.
We can start with the battery. Pretty much the entire industry, including Victron, uses + flow to indicate charge current, and - flow to indicate discharge current. In this case, flow direction and arithmetic correspond. (+100A charge | - 50A discharge | net 50A to battery.)
For Victron, the DC Loads logic flips that on its head. Now the + flow is toward the “load”. From a logic standpoint the nexus is load and as load consumes power the value rises. (A +100A load is represented by a direction arrow with a magnitude of +100).
Here’s the twist. The external Charger is represented as a DC Load by the SmartShunt in DC Power Meter mode. However the direction of the flow is AWAY from the “load” so is signed a - magnitude.
The stew thickens when both + magnitude and - magnitude loads are being represented. The two magnitude arrows partly (or fully) cancel.
The above is a somewhat confusing explanation to a somewhat confusing symbolic notation.
The simple takeaway is: For DC Loads, + flow is toward the load, - flow is away from the load.

Thanks, I think I’m understanding how it is supposed to behave, but I’m not understanding why it behaves the way I’m seeing. Seems like a bug to me, or missing function… See below. (n.b., I’ve been a programmer by profession.)

The configuration of the SmartShunt includes setting a role. Once set into DC Energy Meter mode, there is a setting for DC meter type. That includes a bunch of options, some of which are clearly energy sources, and some clearly energy sinks. An Solar Charger will never consume energy, and a Fridge will never generate it. The system clearly knows which way the energy is flowing, yet when I select “Generic Source” or “Generic Load”, the resulting calculation is the same. And wrong.

But you’ve given me an idea… Time for a bit more spelunking into its behavior. I tried selecting “Solar charger” from the list, and HA! the numbers suddenly make sense. The DC Power correctly shows about 30 watts, and doesn’t change when I turn the supply off. But the Shunt is now bundled in with the real Solar controller. Let’s try the other options for things that are clearly power sources. Result: Some work, some don’t.

Working: Solar charger, Alternator, Fuel Cell
Not working: Wind, Shaft, and Water generators, DC-DC and AC chargers, along with Generic Source.

For fun, I tried calling it a Fridge, and the apparent DC Power got even worse (more negative). I suspect the same some-work / some-don’t situation applies to the Load choices, but didn’t spend the time to try them all. Generic Load had no effect, for example.

Bottom line, it looks like there some choices that are offered but incompletely implemented behind the scenes. As a workaround, I’m calling the local power company a “fuel cell”, and letting it run that way. At least I’m seeing the data I want.

Follow-up… Time to file a bug report.

Makes sense. The code for the DC Load profiles are obviously in a stage of “arrested development”.
Alternator, IIRC, is said to be the most mature.
I also found, during setup, that the software got somewhat confused about the selection I made, and it took a certain amount of non-duplicatible “tweeking” to get it into a usable profile.
I’m a bit suprised, given the number of BMV/SS units Victron sells, that they don’t have dev resources dedicated to the products. (There’s other stuff that looks like it was finished on a Friday.)

Usually the ‘DC Power’ (‘DC Loads’ on NewUI) is populated by a by-difference calculation. It jumps around a lot as the sample sources aren’t all taken at exactly the same time.

It can be used to show the current directly from a SmartShunt though, by setting the SS as "DC System’. To get that tile in the first place, you had to enable ‘Has DC System’. So it’s not such a weird choice of name.
But you may find that option is only available for selection with a bluetooth connection, not via a pc, etc.

Thanks, JohnC. I understand the jumping around thing (not too bad, really) and did have the DC System option set. All is displaying properly, except for the values shown. The problem was that the Shunt’s contribution wasn’t being included in the calculations properly. Turns out that there appears to be some missing functionality in the software for some of the Shunt’s DC Monitoring options. See my list, above. Calling the Shunt either a “Fuel Cell” or “Alternator” instead of an “AC Charger” made the numbers come out right.

Here is the “Has DC system” in my setup. It does not change anything in my display. Is there another “Has DC system”?

This probably should be a separate thread, but to answer the question, no I believe there is only the one “DC Power”. Turning “Has DC System” on under the setup screen should enable the display of a box:

To this thread, the value displayed in that box was affected by how my SmartShunt was configured, but the box was there regardless of that configuration. Turning “Has DC System” off removes the box.

Ok, Smart Shunt “as DC system” is another setup switch than (ESS) “has DC system”. Cannot understand why Ve-direct cable from Smart Shunt to PC shows diffrent menues than BT but I am going to borrow the smart phone of my girl friend to search for the correct menue switch. I purchased the smart shunt with hope to have a more accurate DC value display. Smart Shunt in device list already shows accurate and stable values, only dash board is unstable.

Ah, ok. Now I understand your question.

I haven’t tried the BT interface into the SmartShunt, so I don’t know what’s going on there. My purpose with this thread was to understand why the values in the DC Power box on the V1 display weren’t correctly including the power coming into the overall system through the SmartShunt that is attached to an external DC power supply. By configuring the SmartShunt to be an “Alternator”, “Fuel Cell”, or “Solar” would properly include the data into the DC Power box on the screen. The obvious choice of “Generic Source”, for example, did not work.

The configuration of the SmartShunt was using the VE.Direct cable into my laptop, where the VictronConnect software was running. You need to first set the mode to not be a battery monitor, then the role to be something like a Fuel Cell or Alternator. Configuring it to be Solar would lump the SmartShunt’s contribution into that of the SmartSolar MPPT charger that I also have, which would be incorrect for how I have my system wired.

Found the menu location for correct setup using Ve-direct cable to PC running VictronConnect.
DC -SYSTEM is correct selection. Before it was Generic DC Load.

DC Values in Dashbaord V1 and V2 are now stable and within the expected accuracy