Hello I'm working on a monitoring current project to monitor my Ac system. I searched online and i have found this website here. I followed everything correctly same parts. My background is in hardware not software but Im learning. So I'm looking at the example code.
Edited: i did forget to say I'm using the same resitors and caps. I'm also using the same current sensor. All hardware from the site is the same and the wiring and setup is the same. I'm using a arduino mega2560 it is the only one i currently have available.
I know the 230.0 is the voltage but not sure about the 111.1 and the 1480.0. Can someone help me to figure thi out please?
My voltage is US 120v so I'm not sure if i need to change anything else I'm getting different on the serial monitor i do not understand.
Something not stressed or well covered is while apparent the software is written around 230 VAC it is also written around 50 Hz current and not the 60 Hz common in the us. At 50 Hz mains each cycle of current is 20 mSec. not the 16.66 mSec of 60 Hz current. The 1480 is the number of samples of mains current taken.They use a 1 second window and count the number of zero crossings. You can find some more in depth explanations here:
Measuring RMS current is complex enough but actually getting true RMS is more difficult. While Apparent Power (S) is just V * A getting True Power (P) in watts and Reactive Power (VAR) gets a little more complex. The main problem is the article fails to explain any of this.
Hello Ron, Thank you for the reply back. Yes it is a little over my head it seems that there might be a newer library and the resistor for the 33Ohms is outdated and replaced with a 18Ohms resistor. But I do not know what to change to make it work for the 120v 60Hz system. Not even sure where to find the latest library at.
OK, with a focus for now on current and only current. A ST (Current Transformer) is one of several ways to measure AC current. The little CT used in this instance is a 100:0.050 CT meaning 100 Amps of primary current (current through the loop) results in a secondary current of 50 mA. So 0 to 100 Amps primary = 0 to 0.050 Amps secondary. The way we measure that secondary current is by using what we call a burden resistor. We can pass the current through a resistance and get a subsequent voltage drop across the resistor which is proportional to the primary current.
This explains burden resistance quite well and you will see why 33 ohms or 18 ohms is used.
Check out that link. That should leave you with an understanding of a CT and burden resistor. Keep in mind through all of this we are looking at a true clean sine wave working into a purely resistive load. So lets just focus on the CT and what a burden resistor does for now.
You can buy current transducers based around a current transducer that give a O-5v DC output - that is the simplest and safest way of doing it , providing both isolation and a simple to use output .
If you want to measure power , do t dismiss just buying a second hand electricity meter with a pulse output - it can work out cheaper and easy to use . ( for example I have a small electronic meter that flashes an led every 1/100 KWh )
That's another thing to consider. Current sensors like the one you are working with are aimed more at hobby enthusiast. There are commercial versions offering 4 - 20 mA, 0 to 5 volt, 0 to 10 volt and other assorted outputs.
Those are a few whose products I have used and been happy with. Just about any transducer you could want but again, commercial units which come with a price.
Thank you all for the Help. I'm still trying out Everything and slowly changing numbers to fit my Current setup. I will report back what i find so far.