Then hooking that up to an esp32 or similar to get data back to emoncms. I had some questions hopefully someone more experienced than me can answer
In the application notes, the diagrams do not separate AC and DC ground, but I’m pretty sure they should be separate, correct?
I’m going to be measuring a split phase 120v 200a line. To accurately measure voltage, should I connect to both hot legs to measure them?
Since I’m putting AC voltage into this board, is there any other protection that should be on the hot lines besides varistors?
I don’t plan on powering the DC components from the AC line, but with a separate 5v transformer.
In the application notes it shows a series of 7 240k resistors for each hot wire. In mine I replaced these with 4 220k resistors and a MOV varistor for each hot wire to earth ground. I thought that would be a sufficient replacement for transformers, but is that not the case?
Consider what happens if one leg and neutral fall off outside your house, between the house and the local transformer (where the main earth is), but you have some loads connected (as you’d expect!). The “ground” is then connected to the remaining live line through your load, and the whole circuit is live to 120 V. Unless you have complete galvanic isolation further down the chain, everything connected to what you think is ground will in fact be live. Even if you do, you must treat the whole circuit as ‘live’ while you’re working on it.
I’ll find that note and look, but that’ll be a bit later.
I think that depends on what you mean by ‘separate’. No, I don’t think you should separate them such that a significant voltage can exist between the two grounds, but it’s normal practice to keep the two grounds generally separate and join them at one point only, such that currents flowing in the digital ground - by inference noise that you don’t want to enter the ADCs - don’t generate a voltage that the ADC can see. But then, if the ground is sufficiently solid, that shouldn’t matter.
If you do decide to keep your dropper resistor chain for the voltage, then you can only use the opto-isolated pulse outputs, and you must dedicate the power supply to the non-isolated side of that circuit only, and not share it with anything else. You cannot use any of the other outputs or inputs (e.g. serial data) unless those too pass through opto-isolators.
And of course the withstand voltage must be adequate to cope with spikes on the mains plus the neutral failure.
Funny, my power wires have actually been knocked down 2 times due to a tree breaking in my back yard, so that’s not too far fetched.
What if I don’t have the neutral connected and only have earth ground connected though? Same situation?
By separate I mean not using a single ground and only connecting the two in one place, yes. The IC itself has a digital and analoge ground as well. They are setup exactly the as in the application note.
Not quite, but then you’re measuring Line-earth voltages and not line-neutral. They should be the same, but won’t be.
Then of course you’ll have what will be seen a leakage path from line to earth when your installation is tested, and that should show up as a fault and cause questions to be asked.
I’m afraid everyone thinks it won’t happen to them, and in the main, they’re right. But sometimes it does. If you’re lucky, it might just blow up a computer. If you’re not, lives can be lost.
All the points with the “earth” symbol on that diagram connect to the “digital ground” of the i.c. If you want to measure the line to neutral voltages, then you must connect that to the supply neutral, which is what I think is shown by the terminals UA, UB & UC on the left-hand edge. It’s even clearer on the 3-phase diagram, where the 4 terminals are UA, UB, UC & UN.
But note, you must not connect that ground to the protective earth. If you do, any current arising from a fault elsewhere in your house will be shared between the neutral-earth link at the transformer and that connection on you circuit board. That’s dangerous.
No protective earth is shown on the drawing, but unless the equipment is double-insulated, you should have one and you should connect all exposed metalwork, and the transformer inter-winding screens (if they exist) to the protective earth.
Rather than rock messing something up with AC voltage, I’ve redesigned everything to use a 12v AC/AC transformer to read the voltage, and then some diodes and an LDO to convert that to a usable DC 3.3v
Now I just have to get everything to work properly with the SPI interface, which, so far is not going well.
Cost and complexity, mainly. I would need to use 2 26 ICs. With the 32, I can just turn off one set of channels and configure it the way I want.
So far I’ve gotten things calibrated the way I want them, I just need to make a couple more adjustments to things like the voltage divider, the LDO, one of the voltage rectifiers, and make sure it works with a different brand of current sensor.