Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Measure Mains AC current

Status
Not open for further replies.

abicash

Member
Hello

I am designing a system where one of a smaller part requires measuring the current of the Mains connected electrical appliance and switching it off upon current crossing a predetermined value.

Now this device is controlled by a relay which is switched by a microcontroller.
The power (5VDC) to this micro is derived from an unisolated Mains.
Now if I put a resistor shunt in the appliance path it will drop an AC voltage.
How do I convert this voltage to a DC voltage with maximum current corresponding to 5VDC which can be fed to the ADC on this microcontroller for comparison?
I was planning to use a CT but it costs some amount and that price is not viable for this project.

All ideas welcome
Thanks in advance and thanks for reading!!!!:)
 
A diode rectifier wouldn't work because the diode voltage drop would be too large relative to the voltage drop across the shunt. But what if you used a super diode to overcome this voltage drop limitation? You could put a full-bridge rectifier made of super diodes to rectify the votlage across the shunt resistor.

Precision rectifier - Wikipedia, the free encyclopedia
 
Last edited:
Hello
Thanks for replying.Much appreciated!!! :)

That thought had occurred to me.But
1)If a diode rectifier is used,wont it just rectify just the mains voltage and NOT the drop across the shunt?
2) If I were not to rectify the voltage and command my MCU to measure the peaks,how do I take care of negative peaks?Basically it will have destroyed my MCU by that time.

Please suggest
 
I mean stick the rectifier (or single diode) so it only rectifies the voltage across the shunt going to the MCU, not the AC mains voltage itself.

Like the attached diagram (except use super diodes instead of regular diodes to get rid of the voltage drop).

image1-gif.25528
 

Attachments

  • Image1.gif
    Image1.gif
    29 KB · Views: 4,173
Last edited:
Hello dknguyen

Thanks again for being helpful :)

I dont want to use another IC for this.
The response is also not that important.It should just measure it and put it off!

Is there a way that i measure the voltage drop across this shunt only?

I had planned a Current Transformer in the series of the main current carrying path and drop a dc voltage across a Resistor across its secondary ,but I am trying to replace this with measuring current directly...since isolation is also not very important in this case!!!!

Thanks again :)
 
See schematic in my previous post. I just realized that things get complicated because the op-amps need dual voltage supplies to withstand the positive and negative voltage across the shunt resistor. But I don't see another way of doing it without a CT, or hall-effect current sensor (which can also come as an IC).

I just realized the scheme I proposed would work only if your MCU power supply was isolated, Because it is impossible to wire it so the shunt resistor (with or without a rectifier) and DC power supply voltage to always have the same ground voltage if neither is isolated from the AC mains. At best, the ground voltage would only be the same 50% of the time. THe other 50% of the time would damage your MCU.

I don't see a simple way to do what you are asking. You need isolation in one point, either current measurement or DC power supply (hall effect sensor IC provides isolation without CT).
 
Last edited:
Hello dknguyen

Thanks for being patient and helpful :)

I agree that the schem. wont work due to these glaring issues you pointed out.

So it seems that CT would be the only option now since hall effect sensors are a bit expensive.
I was just hoping that someone might come with a really fantastic idea...since people here are really intelligent :)

Anyways thanks for the support!!!
 
Why not use a current sensor made to measure the exact RMS-current? They usually have an output isolated from mains and their signal can be used directly on an MCU.

Google for AC-current measurement.

Boncuk
 
Why not use a current sensor made to measure the exact RMS-current? They usually have an output isolated from mains and their signal can be used directly on an MCU.

Google for AC-current measurement.

Boncuk

Exactly what I would be using!
 
I would use something similar to this:
**broken link removed**
**broken link removed**

However, it is another IC, but it is small and easy to work with. You can just drop it into your circuit with no changes.
 
Last edited:
I would use something similar to this:
However, it is another IC, but it is small and easy to work with. You can just drop it into your circuit with no changes.

what would be budgetary cost? have you used it before?
[EDIT]I see USD 1.62 on digikey


Thanks as usual
 
Last edited:
For single quantity, it is $3-$6USD depending on whether it it is the large IC or the small IC. I've only had plans to use these, I haven't actually used them yet.
 
Thats a lot of cost.
This system will be manufactured in good quantity and current protection was just another feature thrown in at the last moment.

Also Allegro doesnt seem to have good support in my part of world.

I would really wind a Current Transformer myself in a really small form factor and that would be it!!!
I dont understand why you wont approve of a CT?
Since I dont require response and accuracy as much.


Thanks again
 
I don't not approve of a CT. It's just for me I'd probably use that IC rather than CT.
 
hallo
I want a current measuring ic. if any one can suggest any appropreate IC for this purposs.
I need a AC 230v Current measuring IC.
 
Abi, since simple and cheap is the keyword, it might help to see a schematic of what you have already. Your circuit is unisolated mains powered, which could possibly be used to advantage for a simple and cheap solution. Mostly detail required on how you are powering the circuit from the mains and how the return is accomplished. As is often the case, a good solution depends on how well the problem is defined.
 
Hello ccurtis

Thanks for replying and apology for acknowledging it so late :eek:
(My mailbox plays wonders with mails sometimes)

Anyways please find the ckt diag attached.

(there are two schem. one for the MCU and the other for the PSU)

Please get back if you have something interesting
 

Attachments

  • Schem02.PNG
    75.7 KB · Views: 1,154
  • 5V Power Supply PI.PNG
    5V Power Supply PI.PNG
    26.2 KB · Views: 2,239
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top