emonTx with alternative CT's and 3-phase

Been outside now, looking at my house-meter which gives me readings from L1, L2, L2. It seems like the first phase (L1) get’s read out correct. And that number is then (more or less) presented at L2, L3 in emoncms.

House:
L1: 2000
L2: 400
L3: 700

Sum 3100

Emoncms:

L1: 2340
L2: 2230
L3: 2390

Well. I will load the 3-phase sketch in a few days and go from there.

Now I have uploaded the 3-phase sketch to my emonTx! Used Arduino IDE and choose board Arduino UNO and put the rfm.ino in the same folder as the emonTxV3_4_3Phase_Voltage.ino. Everything went well i think.

Then hooked up the emonTx to my CT’s and AC:AC.

Added “log to feed” and “Power to kWh” for all node inputs.

This is images of “log to feed” from today. Can you help me understand if it is working as it should and how I should configure emoncms (or point me to where I can read about it) to see actual instant usage (sum of the three phases?) and todays import/export ?

In emonCMS, on your Input page, after you have logged that input to a feed, you can do

+input [the second phase],
+input [the third phase],
log to feed [this is the total]

If you want kWh for each feed, then, after doing the Power to kWh on the first, you’ll need to reset to zero, then do +input [ the first phase again], then add the other two phases, then do Power to kWh on the total.

So I did this, hopefully as you recommended. My concern is that this sum seems to be negative a lot ot the time. I sure have a solar PV but it is not producing anything at night for example…

I need to verify this but I think the CT’s are hooked up on three phases going in to my house and not the actual cable that exits the house (and have the solar pv attached to it). What I mean is what I am measuring right nog would probably be positive all the time right ? Only import. I need to talk to an electrician to move the CT’s.

Anyhow it should me positive readings i guess ?

How can I start to look for errors, is one or more of the CT’s in the wrong direction ? Is the error from me using the same ground for all three CT’s ? Me not understanding emoncms ? Anything else ?

Obviously, I do not know exactly how your house is wired, nor how you have installed the CTs. All I can say to help you is that you must get the basic information for each phase correct as it comes from the emonTx, or at least understand how and where it is wrong, before you worry about emonCMS.

Your problem seems to be where you are measuring. Forget for a moment that you have three phases. There are 3 quantities that are closely related, Nett grid power, Used power and Generated power. Knowing two, you can calculate the third.
Nett grid = Used - Generated
But you must know, or assume, the direction of power flow to get the sign of the power correct, and that’s where the direction that the CT points comes in. We count Used and Generated as positive (so your inverter consumes 50 W, or ‘generates’ - 50 W, at night when it is dark), and imported Nett grid as positive.
Therefore, where you measure current tells you which of the three versions of that formula you need:
Nett grid = Used - Generated
Used = Nett grid + Generated
Generated = Used - Nett grid

You should be able to deduce what each CT is measuring if you know, or you can reasonably assume, what it ought to measure given a particular set of conditions. You will probably need to turn appliances (and your PV) on and off while you make measurements, and record the results.
Note, you do not need to get an electrician to reverse the CT, you can put a minus sign in the sketch.

I will read your thoughts over and over again and try to find a local person who can explain things for me. I will be home tomorrow to look closely where the CT’s are situated. My guess from looking before is that they are located on incoming cables to my house. My PV inverter is mounted in my garage which is outside the scope of the cables where the CT’s are currently measuring. Thus giving only “positive” readings would make sense to me because I don’t have anything else in house except for consuming products. These low numbers of negative readings must be some sort of error if you ask me.

I’ve just read this Zero consumption calibration and all of this confuses me but I got some kind of feeling this guy has had the same issue as I’m experiencing right now.

Anyway, thank you for helping me with this!

That is possible. If there is no current input to your emonTx, then you might measure some small power due to electrical noise. 240 W is about 1% of the maximum that you can measure, I would expect the noise to measure less than that.
I have the sketch running here, with only one CT which is not near a cable, and I am seeing a small current and very small real power (3 samples):

Voltage: 249.62 Phase 1: 0.00 A, -0.01 W, 1.14 VA, PF=-0.006 Phase 2: 0.00 A, 0.00 W, 0.00 VA, PF=nan Phase 3: 0.00 A, 0.00 W, 0.00 VA, PF=nan Input 4: 0.00 A, 0.00 W, 0.00 VA, PF=nan Temperatures: 26.80 27.10 20.30 Pulses=1
Voltage: 249.58 Phase 1: 0.03 A, 0.28 W, 6.93 VA, PF=0.041 Phase 2: 0.00 A, 0.00 W, 0.00 VA, PF=nan Phase 3: 0.00 A, 0.00 W, 0.00 VA, PF=nan Input 4: 0.00 A, 0.00 W, 0.00 VA, PF=nan Temperatures: 27.10 27.30 20.30 Pulses=1

Voltage: 251.34 Phase 1: 0.00 A, -0.01 W, 1.15 VA, PF=-0.011 Phase 2: 0.00 A, 0.00 W, 0.00 VA, PF=nan Phase 3: 0.00 A, 0.00 W, 0.00 VA, PF=nan Input 4: 0.00 A, 0.00 W, 0.00 VA, PF=nan Temperatures: 27.20 27.50 20.30 Pulses=1

Ok, in my installation there seems to be some big problem according to me, not just noise or “error”. Looking at these images from 15 to present - today reveals some measurement going on and around 17-18 this evening you can see some cooking taking place probably (and number around 3-5000watts is probably right). But two of three phases are mainly negative and one of them is slightly negative but mostly above 0. What could cause this ?

The “Power to kWh of three phases” - log sums up to -1.5 in these three ours.

Until you have your CTs in the correct places, anything you measure could be wrong.

I do not have a 3-phase supply. But on a single-phase test load, the sketch can be calibrated to give the expected “wrong” values, and others have reported that the sketch works for them, so - disregarding small errors that are unavoidable with the emonTx - I think the sketch works as intended.

Can you photograph your CTs now with a bigger picture so that I can see where the wires come from and go to?

If you have a CT on the wrong phase, or facing the wrong way (or the wires are swapped), then you will get a negative reading when it should be positive.

If your CTs are on the supply side of the place where the PV joins, then if your PV is generating, you may (correctly) have negative readings.

I see from the photo that the blue wires from the CTs are connected, and go to the white wire into your emonTx. That white wire must connect to the TIP of the jack plugs for the emonTx, which is the ‘earthy’ side of the input; and the brown, green and yellow wires to the SLEEVE. The way that the CTs are wired is bad practice, ideally each should have had a twisted pair of wires all the way to the emonTx.

[Edit]
Having now checked with a simulation, if you have made the common connection to the sleeves of the emonTx plugs, then you will certainly get undesirable interaction between the inputs.
Unfortunately, this would be the way I, and I think anyone, would expect to wire the plugs, but because of the way the socket is wired so that the built-in switch can be used to signal “no connection”, it is wrong.

Do I understand you correct that the re-use of the “ground” wire to all CT’s can be causing the problem ?

In general, yes. In your case, if you wire it as I say (white wire to the plug tip), it should be good. Otherwise, you are putting approximately the same signal on each input of your emonTx.

I really must write a “learn” page about extending the wires to a CT.

Here are two pictures to explain more in detail how my house and CT/emonTx is wired. Sorry for the bad picture on my emonTx. It should be wired as you suggested with the “signal” cable to the tip and the GND from CT to SLEEVE.

Thank you. I think your PV comes via the 16 A Hager m.c.b’s on the left, and the white box that is open is the place where the PV joins the house supply. I looks as if your c.t.'s are on the house supply, so you will not measure the PV contribution.

So - everything looks correct, except for the connections at the emonTx. You must swap the connections, so that the brown, green and yellow wires go to the sleeve, and the common black wire to the tip. When you do that, I think everything should work correctly, and emonCMS will record your house consumption. The emonTx will not see the PV generated, and it will not see garage consumption.

Great. So I misunderstood the connection of TIP and SLEEVE of the 3.5 mm connector.

I did read the instructions from you about connecting the CT to the 3.5 mm connector in the beginning of this thread couple of times but ended up thinking that GND would be SLEEVE.

Anyhow when I get around moving the CT’s to the incoming wires from the electricity company I guess it will measure the total import / export including house, pv and garage ?

That is what anyone would expect, but when you look at the circuit diagram of the emonTx, you will see that it is wrong. I can easily understand why you got it wrong.

Yes, that is correct. When your PV generated exceeds your house + garage use, power will be negative. The rest of the time, it should be positive. If it is the opposite of that, you will need to multiply by -1 inside emonCMS, or reverse the c.t.'s on their cables.

So I did as you told me, this is the result. Two things,

  • two phases seems to be negative almost all the time.
  • I don’t think I’m using up to 25.000 watt momentarily.

I’m using this sketch:

The good thing is that the 3 inputs are now showing very different numbers. So we are doing something right!
Did you change the burden resistors in your emonTx, and the current calibration constants, as in post no. 4? If you changed one and not the other, that would account for the current being wrong. Is the power about 4 × too big? If yes, that is the wrong calibration constant in the sketch (90.9 → 22.727).

I cannot see a reason for the negative power, but there might be one. Here are the things that could make it wrong:
The CT in input 1 is not on the same phase as the a.c. adapter.
The 3 c.t’s are not in the correct sequence.
The c.t. is reversed on it’s cable (but it looks right to me), or it has been made or labelled wrongly.

You need to be careful with the phase colours, because I can see several wires in your photo which are wrong. e.g. the wires from the PV are brown, black, grey above the m.c.b. but brown, brown, brown below it.
The phase sequence should be 1 = brown, 2 = black, 3 = grey. But for the emonTx, whichever phase the a.c. adapter on is defined as 1, then the others follow in order. But beware: I wrote “should be” - it is not unknown for electricity companies and installers to get it wrong.

Fantastic, we are advancing. I’m very sorry, I had forgot or not read correctly about calibration in the sketch. This is now done. I also have identified the right phase-order, brown, black, grey and connected them in order 1-2-3 on emonTx. This gives me the most correct readings so far! I still have some negative readings on all three phases but they seem to reflect my actual usage more than before.

One of your possible reasons for negative reading, the one about the AC:AC adapter not being on the same phase as input 1. Might this be the final problem ? I mean, is it obligatory to have the AC:AC adapter on the same phase as input 1 on emonTx? I have tried to look inside my house where all the electric cables are distributed but it is hard or impossible for me alone to understand which phase supplies what part of my house. I then need to ask someone.

This image is a sum of the three phases log to feed’s.

Yes it is - as the sketch is written. But as I wrote earlier, the emonTx’s Phase 1 does not have to be Brown, it can be any phase, as long as the next two phases follow in the correct sequence.

If you can look inside your distribution board, ideally you will find that the circuit breakers are marked, or you might be able to see how the busbars are arranged. The breakers might be grouped by phase, or maybe every third breaker will be the same phase. I assume you will not be able to isolate one phase at a time and see what goes off?

[Edit]
I forgot to mention this: You will of course read zero volts (or very nearly) between circuits on the same phase, and 415 V between circuits on different phases. But that will only tell you which circuits are on the same phase, it cannot tell you the phase sequence.

When you put it like that again I had an “aha” moment and realized that I probably might be able to keep the nice L1-L2-L3 order I arranged today and just move all three inputs one the emonTx one step at a time instead of searching what phase the AC:AC adapter is connected to. And there it was, two steps to the left and I now have what I can tell good readings!

All three inputs positive and around 500-1000 watts which seams reasonable right now.

Thankyou! I will follow up after some logging…