Path: utzoo!yunexus!ists!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!bloom-beacon!mcgill-vision!clyde!maxwell!jean
From: jean@maxwell.Concordia.CA ( JEAN GOULET )
Newsgroups: sci.electronics
Subject: Re: Need help to finalize my circuit
Summary: Power supply problem
Message-ID: <1544@clyde.Concordia.CA>
Date: 7 Nov 89 19:43:30 GMT
Article-I.D.: clyde.1544
References: <1508@clyde.Concordia.CA>
Sender: usenet@Clyde.Concordia.CA
Reply-To: jean@maxwell.Concordia.Ca ( JEAN GOULET )
Organization: Concordia University, Montreal Quebec
Lines: 41

Thanks to all of you who helped me find the solution to my problem.  I got
over a dozen replies, and almost all of them suggested that I add two
capacitors to Vin and Vout.
                                  ______
                                  |7805|
                       ~13Vdc     |    |   4.7Vdc
                         |        ------     |
                         v        | | |      v    _________
120V AC ---- AC adapter ----------| | |-----------|26 ohms|------
                                  V G V           ---------      |
                                  i n o                          |
                                  n d u                         Gnd
                                  |   t
                                  |   |
                                 ___ ___
                                 --- ---
                                  |   |
                                  \Gnd/

The funny thing is that I actually *had* put in capacitors at Vin/Vout,
but I actually removed the capacitors from the circuit because I really
didn't think it would matter, and I didn't bother drawing them in the diagram.
What a mistake! 

It's interesting that practically everyone suggested different values for
the capacitors, ranging from putting a massive electrolytic at Vin, to
a little sub-microfarad tantalum on both pins.  I experimented with the
capacitors I had, and found that 0.01uF was about as good as using a 100uF
electrolytic.

The moral of the story:

   1) Always bypass a 7805 with capacitors!
   2) Beware: An AC adapter marked '9V DC' probably has more AC than you'd
      want, and it probably has an incorrect DC level too!

                                             Jean Goulet
                                             Electrical Engineering
                                             Class of '89
                                             Concordia University
                                             Montreal, Canada