CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

pic ADC gives erratic readings
Goto page Previous  1, 2
 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
temtronic



Joined: 01 Jul 2010
Posts: 9097
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Tue May 01, 2018 5:36 am     Reply with quote

I have to ask why not just buy a 'wallwart' ( pre made cube) power supply? Wiring up 10-11 components connected to 'mains' is risky to begin with and really NOT cheaper. I get 5V 2A wallwarts for $2 each here in Canada,even have grn pwr LED !

Jay
Ttelmah



Joined: 11 Mar 2010
Posts: 19215

View user's profile Send private message

PostPosted: Tue May 01, 2018 6:58 am     Reply with quote

Yes. In some cases the basic little USB 5v ones are actually cheaper than you can buy a bare plug for!. Thousands of times safer.
POPE19



Joined: 27 Jun 2017
Posts: 71

View user's profile Send private message

PostPosted: Tue May 01, 2018 7:37 am     Reply with quote

Thanks for suggestion. I will purchase one and move ahead. Thanks again.
Mike Walne



Joined: 19 Feb 2004
Posts: 1785
Location: Boston Spa UK

View user's profile Send private message

PostPosted: Tue May 01, 2018 2:54 pm     Reply with quote

Something is seriously wrong with your power supply circuit.
You appear not to understand most of what is happening.
Your rectifier is immediately followed by what you say is a 25V zener.
If your circuit was working correctly you should get ~25V at the rectifier input and output.
(The zener simply clamps both rectifier input & output at the zener voltage, ie 25V)
Your measured 50V is in error by a factor of 2.


A few calculations with considerable rounding off:-

Assuming your on 110V 60Hz sine wave mains.
Connecting your 660nF cap across the mains gives an RMS current of:-
2 * pi * 60 * 110 * 660 * 10^-9 Ampere = 27.4mA

After rectifying that will give 27.4mA RMS.
With a minimum of zero and a maximum of 27.4mA * SQRT(2) = 38.8mA
(The effects of other components will reduce this value.)

The mean DC current will be 38.8mA * 2 / pi = 24.6mA
(Your measured 30mA could be within tolerance.)

Your first zener needs to be rated at 1W as a minimum.
A typical 24V 1W zener has a maximum zener impedance of 25Ohm.

So your ripple current should give a pk-pk ripple voltage across the zener of less than 25Ohm * 38.8mA = 970mV.

All things considered you're at risk of killing yourself by working on a potentially lethal circuit.

I think you should take the advice offered by others and use an off the shelf 5V supply to power this circuit.
At least until you've got the circuit to work correctly, then consider why you may need a cap dropper power supply.

Mike
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group