AC current sensors
Jonathan
Posts: 1,023
Hi All,
I have been working on a smart, off grid water system controller. I have the classic rural system, well pump, storage tank and pressure pump.
So far it can track gallons used and uses an ultrasonic transducer for determining depth of water in the tank. It senses the system pressure and turns the pressure pump on and off, instead of the usual diaphram pressure switch. If it senses a fault, such as low tank water, pressure pump cycling too long or too often it can shut everything down. This is good for me because a burst hose while I am away could result in running my batteries flat. And for off-gridders, the battery bank is King.
Anyhoo, I want to add current sensing of the pressure pump. In theory if the pump is dry it should use less current. So I can watch for that. Also, I could make a profile and then watch for changes. I've done a lot of DC current sensing but AC is tougher. There are a lot of offering out there and I'm wondering if anyone has any recomendations.
Needs:
Cheap, 20 bux US would be nice.
20 Amps
RMS?
Thanks!
JOnathan
I have been working on a smart, off grid water system controller. I have the classic rural system, well pump, storage tank and pressure pump.
So far it can track gallons used and uses an ultrasonic transducer for determining depth of water in the tank. It senses the system pressure and turns the pressure pump on and off, instead of the usual diaphram pressure switch. If it senses a fault, such as low tank water, pressure pump cycling too long or too often it can shut everything down. This is good for me because a burst hose while I am away could result in running my batteries flat. And for off-gridders, the battery bank is King.
Anyhoo, I want to add current sensing of the pressure pump. In theory if the pump is dry it should use less current. So I can watch for that. Also, I could make a profile and then watch for changes. I've done a lot of DC current sensing but AC is tougher. There are a lot of offering out there and I'm wondering if anyone has any recomendations.
Needs:
Cheap, 20 bux US would be nice.
20 Amps
RMS?
Thanks!
JOnathan
Comments
Search on ebay for current transformer 20A
I'm getting some of these ones http://www.ebay.com.au/itm/0-20A-Input-Precision-Current-Transformer-TA17L-04-Red-/301122015370?pt=AU_B_I_Electrical_Test_Equipment&hash=item461c45508a
300R sampling resistor, 10mA and 3V output. That works out well because that may not need any preamplifying.
Next need a half wave rectifier. There are op amp circuits around that use two diodes, and because these are part of the op amp circuit, the forward voltage of the diode is removed. Google op amp half wave rectifier
and images.
eg http://sound.westhost.com/appnotes/an001.htm
I'm also looking at some of my op amp cookbooks. There is a circuit whit a 10k resistor, two signal diodes, a 22k resistor and a 1uF capacitor. This gives you the gain to correct for RMS, rectifying and filtering all with one op amp.
Then a second op amp as a comparator with a pot on the input to set the threshold.
Only problem with these circuits is they assume a split supply. For single supply circuits, need a virtual earth. LM324 quad op amp with a 5V supply can't go rail to rail, but you can set the virtual earth at 2.5V with one op amp as a voltage follower. Then use this reference for other circuits. So you could connect one half of the current transformer to this 2.5V reference and it then swings max 2.5V +/- 3V. Need reduce that to +/-1V so goes 1.5V to 3.5V as this is the maximum rail to rail the 324 can go. So maybe that is a different load resistor, or maybe divide the output from the load resistor by 3 with a voltage divider. And maybe don't need to do the RMS gain.
I am looking for the simplest circuit to get this data into a PC. I think it is going to be a cheap USB to serial cable for $2, a picaxe chip for $4, a max3232 for $1, a LM324 for 30c, and a current transformer, plus resistors and capacitors and diodes. Should come in under $20.
Might be worth using CA3140 rail to rail op amps - then the final DC output can be 0 to 5V and that uses the full voltage range of the picaxe - hence better resolution.
I'm building this for smarter solar power. If the sun is shining and making more than a pump would use, turn on the pump. If enough power for a second pump, turn that on too. But add some other rules too eg if a cloud goes over every few minutes, don't turn the pumps on and off all the time. Wait for 5 mins of steady sunshine. Excess power charges batteries and/or runs other loads that don't care so much about the timing, eg pool pump. Maybe really smart load control - eg buy a 1kw, 2kw, 4kw and 8kw pump, and then you can switch these in a binary fashion to get from 0 to 15kw in 1kw steps.
I'll ponder this some more. The $20 challenge is a good one!
Jonathan
I actually already can pretty much tell if it's dry, as the system pressure will fall and the controller is aware of (and controlling the pump) pressure.
Thanks!
Jonathan
Do you want to output to a PC? Or do you want it to close a relay if there is a fault?
I've been pondering making a PC connection even simpler. USB to serial adapters are only a couple of dollars. There might be a circuit that removes the need for a picaxe or microcontroller, and even removes the need for a power supply.
Re the supply, take one of the control lines eg pin 7, and toggle it in software. Use two capacitors and two diodes and if it toggles -9 to +9V say once a second, that can give us a dual rail power supply.
Then use a low current quad op amp maybe a TL084 or something. Use a standard precision rectifier circuit to create a DC voltage proportional to current. Then use another op amp circuit to create a triangle waveform, and compare with the voltage. The waveform can be slow eg a few seconds. Feed that into a comparator and then into an input control pin eg pin 8 request to send. In software measure the duty cycle of this pin.
It *might* be possible to do this with one chip costing 40c, and a few resistors and capacitors.
Disadvantage - need a little program on a PC to control and read the RS232 lines.
Advantage - no need to be programming microcontrollers.
addit - rummaging around the internet trying to find the cheapest way to get analog data into a PC
found this http://numato.com/8-channel-usb-gpio-module
Dr, I want to convert the signal to use with a 10 bit ADC. I see quite a few circuits out there, most relatively complex. Ultimate accuracy isn't my goal, what I want to do is to characterize the pump's current draw, then watch for changes. The objective being to distinguish between a dry and wet pump and perhaps be able to alert pump problems. So if I can, I'd rather find a simple and low part count solution.
Thanks!
JOnathan
I am using the Octopus Sensor I got from EBAY for $8
http://www.ebay.com/itm/AC-TA12-100-Current-Sensor-Module-for-Arduino-/131013399404?pt=LH_DefaultDomain_0&hash=item1e8101d36c
BTW - When looking for devices, search for Current Sensor for the best results.
I used a schottky diode, a 25UF Cap and a 10K Resistor. Feed the output of the sensor through the diode, charge the cap, use the 10k to discharge the cap. Feed the results into the ADC. Smooths out the pulsing well. My ADC is 8 bit 0-5 VDC. I multiply the output by 6/100 (I think) in PBasic and I have a pretty good current sensor. I actually can have 4 of them. The ADC has 4 inputs.
I am sure I can improve the circuit and the software, but it is working well now. I am not sure I need anything better. I may move on to another project.
I would like to upgrade to something that will do 25 amps. I may try one of these..
http://www.ebay.com/itm/Non-invasive-Split-Core-Current-Transformer-AC-current-sensor-30A-SCT-013-030-/281150975569?pt=LH_DefaultDomain_0&hash=item4175e76e51
Pretty nice package for under $10. Its a nice clamp on device 0-30 Amps.
I'll make a little video in a few days and post it here.
Greg
Jonathan
The Octopus has a built in load resistor. Not sure about the clamp on device.
The Octopus also has a +5 pin. I hooked up to it, but I sort of think it doesn't do anything.
One other test I wanted to try was to use RCTime to read the signal. My current project already had the ADC installed. I would try adding this to my schematic above.
681 kohm 470 ohm
Vx ----/\/\/\---o
/\/\/\----P0 to stamp
unknown |
voltage ===== 0.01 uF film
|
Vss
Of course this gets hooked up to the output of my other schematic.
Greg