Melanie pretty much said it all, but there's schematics and math formulas for transformerless supplies in this Microchip appnote:
http://ww1.microchip.com/downloads/e...tes/00954A.pdf
steve
Melanie pretty much said it all, but there's schematics and math formulas for transformerless supplies in this Microchip appnote:
http://ww1.microchip.com/downloads/e...tes/00954A.pdf
steve
Hi all
Thanks to everyone for their help so far ..
Steve for the tongue-tip-test tip and for the latest one
but I am already referring to that document in post number 1 in this thread .. and that's the source of the confusuion.
Amgen thanks for the bridge-rectifier based sketch and formulae !
Dave Houston I will remain eternally grateful for the X-10 info pages and other links.
Adam those links you pointed me to where a great read and it seems I may have opened a can of worms with this thread ??
Dave, Mackrackit aka "CODE EYES" thanks for the forewarning and all the help thus far.
Melanie not only did you clear up my confusion regarding the calculation but have also given some fantastic tips to take into consideration which also triggered some more thoughts/questions.
So far I have the following calculated.
For 220V @ 50Hz to drive a MAX load of 30mA, I would need the following values (or have I messed up somewhere and is it just under 15mA?)
MOV(VDR1) = 275V
C1 = .47uF (suggested is X2 rated 275VAC based on other forums posts and internet sources)
R1 = 100 OHM (1/2 Watt)
D1 = IN4007
C2 = 470uF 25V (electrolytic)
D2 = 5V1 Zener
If all is correct, this output a half-wave rectified, smoothed 5V supply, right? If full wave were required I would need to a
If there are any further suggestions/changes I would appreciate them.
Is it true to say that the circuit ground 'hovers'(for lack of a better word) below HOT/LIVE and is not reference to EARTH GROUND and this is why all the warnings and danger signs ?
My questions are ...
(And while I ask I am busy reading/checking up on the following)
1.Whats happens when the circuit wants to draw more than max Ohms ?
2.How do I check the current draw of my PIC (assuming the PIC is standalone and not connected to anything other than power ?)
3. Once I start connectinng things like a push-button or triac or relay and perhaps an LED and maybe a POT for dimming, what would the ball-park usage start looking like and why ?
4.Which component is taking the most strain as the circuit draws current, is it C1 ?
5.Is C1 the current limiting factor of this circuit ?
6. I was thinking of using a BT139 Triac (since I have quite a few lying around), is it a good choice? I read that
7.What should the value for R3 be if I am to drive a triac ?
8. Is it feasible/possible to add a wireless TX module to the PIC circuit and if so what safegaurds (if any) like noise reduction should I put in place and where ?
9.In post #14 here amgen points out that we are looking at 0.15UF per 10MA and this seems to run true for both bride rectifier (full-wave) based as well as for the non-bridge based (half-wave) supplies. So the question is why choose to use a rectifier or not ? Is it cost ? Less of a smoke factor ? Space ?
10.To test the voltage on the output side could I just pop my good old Fluke meter on 5V and circuit GND with it set to read DC volts.
(and yes I will make sure I am insulated - rubber sole shoes, no jewellery, rubber gloves - hell I will wear a rubber suit if needs be!)
11. Are there any tips for connecting things up on the PIC side ?
12.And for taking measurements on the PIC side ? Apart from the app note SAFETY PORTION which refers to using an isolation tranformer.
Anyone have a schematic/block-diagram for measurements please?
13. Unless I am planning to use zero-crossing point to control the triac (can't think of a use right now, can you ? ) ,should I be concerned about zero-crossing issues as I have read somewhere that this circuit may cause slight delays in switching the load on or off based on Wattage and type either resistive or inductive) because the zero-crossing signal is phase shifted from the actual zero-crossing?
Oh and last but not least I can think of at least two applications that might be a no-no
1.Touch-sensitive pad(s)
2.ICSP
But what about things like USB or Connection to the PC serial port?
What sort of buffering or isolation would be required if is possible.
Apologies for the lengthy post and any questions which may seem obvious or silly to anyone reading this post (and the other posts too!)
Thanks once again
Kind regards
Dennis
Dennis,
Very through work !, and good questions.
Your diag had diodes in wrong places.
1) too much current draw will drop voltage to PIC to a point of no-operation,
thats why my ckt had 12V ZD and 5V reg, it provides smoother supply.
2)you have to insert DC ammeret (can be digital meter) in wire supplying PIC and other circuit.
3)Probably getting toward your 30MA, keep draws as small as possible, example---2MA led
4) C1 drops most voltage but most all parts are critical for operation
5)C1 is the current limiter, could use 600VAC rated part which is larger than say 250V part
-R1 developes heat by the amount of -- Current squared times Resistance
- also Z diode makes a little heat -----Z voltage times current through it (can measure or estimate
6) use an OPTO triac driver then any triac of the amps you need is OK
7) use 200 to 500 ohm to drive the triac driver depending on the opto chosen
8) consider added power used (more current) by added parts, within range of designed supply components
9) full-wave bridge makes use of pos and neg cycle of ACV, where 2 diodes only uses 1/2 cycle and the other 1/2 cycle is just wasted. bridge rectifiers come in dip package up to 1000 volts.
10,11,12,13,1,2))) If not using Z crossing, you could hook 10 or 20 volts from an ac or dc supply to test,adjust, ICSP then after all working hook to 110/220 power.
I think touch-sense sw's would be possible shock hazzard due to lack of higher voltage isolation, at some point Transformer isolation makes more sence.
I made some push-button 110V fan timers with this circuit, fits in wall switch box, never skipped a beat or burned one up, so I was addressing the same issues as you.
good luck,
don
amgen
Dennis,
Glad to see you are not jumping into this without asking the questions.
But by asking the questions I see you are not familiar with high voltage.
So it is a "catch 22" to learn how to handle it. This is one of the places where "self experimentation" could get you in trouble.
Make sure you have a low value fuse in the system.
I do not want you to end up looking like my avatar
Yes, I am getting to be an "old fuddy duddy"
Dave
Always wear safety glasses while programming.
Hi guys :-)
Don thanks for the reply and update :-)
Which diode is in the wrong place ??Your diag had diodes in wrong places.
Dave ....
Thanks for the tip .. just curious though ..fast blow low current fuses ?
Kind regards
Dennis
Happy New Year Boys...
That's a very dangerous circuit you've posted Dennis.
What you've got is Vdd at LIVE potential, and Vss is just -5v below it. You've put all your voltage drop in the NETURAL rail. That means your ENTIRE low-voltage PIC circuitry is actually referenced against your HIGH VOLTAGE LIVE. Yes it will work, but there is no margin for error anywhere, because GROUND is (more than) 250 volts away...
If you look at other half-wave rectified circuits (posted on this forum), you'll notice that Vss (0v) is sitting at NEUTRAL, with Vdd +5v above it (with all the voltage drop being done in the LIVE rail). So, in that instance most of your PIC circuit is close to GROUND (since NETURAL and GROUND 'should' be connected together somewhere along the Power Grid to your Wall Socket). This makes it a damn sight 'safer' if you really want to play with mains. I use the word 'safer' cautiously - because playing with supply mains for folks that don't know what they're doing is not safe at all.
All the above is negated by the fact that some countries Power Systems allow users to plug appliances in either way around.
Now I'm going to get serious here. Your questions highlight the fact that you don't know what you're doing and you're asking the forum for advice on values of components and such. Read the Datasheets for the components you're using and determine if what you are doing is correct for the purpose intended. For example, the TRIAC Datasheet should tell you what Gate current it requires (your R3 question) to switch on. Because if ANYONE gives advice on a particular component or value, and you end up killing yourself, the liability falls onto the person that gave you the advice.
I would like to take a step back.........and agree with Melanie about this power supply danger.
Any possible touching or contacting of any parts of this circuit can cause serious injury!!! Leaving this circuit available for any person to contact in any way would be very negligent. Only persons with strong electronic knowledge should be working with this type of circuit.
Never want to see someone hurt.
df
amgen
Hi All (Happy new year by the way :-) I hope it's a good and prosperous one for everyone!)
Melanie thanks for the clarity and tips again ,
So if we are using a 3 prong plug, (Three wire system)
then Brown wire is LIVE
and Blue is NEUTRAL
and YELLOW/GREEN is EARTH
The measured voltages are as follows
At the time I measured
Between LIVE and EARTH = 227.5 V (Readings may vary 235 to 225V (Varies based on time of day load etc) )
Between NEUTRAL and EARTH = < 1 V (May vary too!)
Between LIVE and NEUTRAL = 227.1 V
In most AC driven appliances where a mechanical SWITCH is used to switch
Either one of two switches are used (not so ?)
1.
ON-OFF
Single Pole, Single Throw = SPST
A simple on-off switch. This type can be used to switch the power supply to a circuit.
When used with mains electricity this type of switch must be in the live wire, but it is better to use a DPST switch to isolate both live and neutral.
2.
Dual ON-OFF
Double Pole, Single Throw = DPST
A pair of on-off switches which operate together (shown by the dotted line in the circuit symbol).
A DPST switch is often used to switch mains electricity because it can isolate both the live and neutral connections.
In at two wire system (2 prong plug) we are using LIVE and NEUTRAL
So....
In for the example of a PIR security light controller, the circuit draws its power from the mains , when the PIR detects a movement (PIC pin goes high) it opens the power to the load , in this instance it switches the light on (the light draws from the same mains power that the circuit draws from)
See the attached diagram..
So without creating a dangerous circuit how does one draw from the very same power that you are switching on and off (or dimming for that matter) ???
Melanie, what exactly are you suggesting to make it safe ?
You said ...
I agree it would be better to be 5V away from ground than 5v away from 250V :-)What you've got is Vdd at LIVE potential, and Vss is just -5v below it. You've put all your voltage drop in the NETURAL rail. That means your ENTIRE low-voltage PIC circuitry is actually referenced against your HIGH VOLTAGE LIVE. Yes it will work, but there is no margin for error anywhere, because GROUND is (more than) 250 volts away...
You also said ...If you look at other half-wave rectified circuits (posted on this forum), you'll notice that Vss (0v) is sitting at NEUTRAL, with Vdd +5v above it (with all the voltage drop being done in the LIVE rail).
[/QUOTE]
What keywords did you search on ? I tried transformerless and transformer-less as well as half-wave, and didn't find very much :-(
I did find some that you had suggested to others ...
Like this onehttp://www.picbasic.co.uk/forum/atta...9&d=1213285761
and this one
http://www.picbasic.co.uk/forum/atta...1&d=1139474240
In the cuits I have seen, not many actually depict how the PIC is to be wired for various operations.
You aslo said ...
I totally agree hereSo, in that instance most of your PIC circuit is close to GROUND (since NETURAL and GROUND 'should' be connected together somewhere along the Power Grid to your Wall Socket). This makes it a damn sight 'safer' if you really want to play with mains. I use the word 'safer' cautiously - because playing with supply mains for folks that don't know what they're doing is not safe at all.
But how do you suggest I change the circuit to do that ?
Please check the attached (but no yet complete) updated diagram , what's missing here is the value for R2, R3 and the TRIAC stage (I plan to use a BT139F (see attached diagram) ..Is 01A correct ?
I did raise a question about it being correct.
I do understand the risks of the circuit and have been shocked before and why I am raising all these questions is because I would like to cover all the bases and not just dive into the deep-end.
And regarding the calculations and so forth , I last used most of them 20 years ago when I was studying electronics (and sadly it is not my full-time career!) so please forgive me for being a little rusty.
Electronics and PIC programming are a really fond hobby of mine which I recently re-kindled after a nearly 4 or 5 year break !
As regards the safety aspects ... thanks to everyone who has issues warnings here and all have been noted and considered.
I have a question though .. did you all encounter the dangers first-hand by a shock or was it from a warning from others ?
Was it that feeling of total shock and frustration (at yourself) when you opened the equipment to work on or look inside while ignoring the DANGER and HIGH-VOLTAGE warning stickers ?
I look forward to your responses be they critical, analytical or other :-)
Kind regards
Dennis
Bookmarks