AVR Freaks

AVR forum - mega16 and 3 pin reg 7805

thakkarhimanshu - Apr 20, 2009 - 10:33 AM
Post subject: mega16 and 3 pin reg 7805
I have made a experimental dimmer board using Tiny44 and Mega16. The board has a supply voltage input of 9V dc which was stepped down to 5v using a 7805CV regulator IC. This board worked very much up to the expectations.

I have received prototype board now. When I connect 9v supply with all the components mounted except Mega16, the VCC(output of 7805) is 5.12V. The problem occurs once I mount the Mega16 IC. The VCC now reads around 7.8V. I have traced the circuit and have found nothing wrong with it as far as the tracks and layout of the PCB goes. The Mega16 IC when mounted on the experimental board gives no problem with the supply but it does on the prototype board. I have seen on the datasheet of 7805 that if the ground pin of 7805 is elevated then the output is increased but in my prototype board it is zero volts.

I am appearing a bit helpless now since I do not even know where I should start looking for the problem. Any suggestions are welcomed. Thanks in advance.
npat_avr - Apr 20, 2009 - 11:26 AM
Post subject: RE: mega16 and 3 pin reg 7805
Did you check the supply on a scope?
Can you post your schematic?
thakkarhimanshu - Apr 20, 2009 - 11:40 AM
Post subject: RE: mega16 and 3 pin reg 7805
yes I did check the supply on the scope and my initial post closely follows that. I am attaching the circuit diagram.
Karl63 - Apr 20, 2009 - 11:58 AM
Post subject: RE: mega16 and 3 pin reg 7805
Hi,
I would think if the VCC is 7 V then that M16 has had it. Logic follows, If putting in the chip, causes the voltage to rise, then it must be coming from somewhere on the socket right? Keep the part out and use a voltmeter or scope and check all the socket pins before putting another part in. I would look for a short somwhere. Maybe from that net that runs the 9V to the other connector.
Good Luck
- Karl
Jepael - Apr 20, 2009 - 12:01 PM
Post subject: RE: mega16 and 3 pin reg 7805
Weird. Only thing wrong that I see is that AVCC is not connected to anywhere, but it should not cause that.
thakkarhimanshu - Apr 20, 2009 - 03:30 PM
Post subject: RE: mega16 and 3 pin reg 7805
Hi karl63,

Welcome to the forum. Your good luck has worked out. There was a hairline shorting between the 9v supply and one of the M16 pin. Once I removed the shorting it was all fine. Thanks a lot.

Hi Jepael,

I have not used the A to D converter of the IC, that is the reason I did not connect it ( or I did not cared for it, is more appropriate description). Now just out of eagerness, is it necessary to connect something to AVCC even though we are not using it.
clawson - Apr 20, 2009 - 03:39 PM
Post subject: RE: mega16 and 3 pin reg 7805
Quote:

I have not used the A to D converter of the IC, that is the reason I did not connect it ( or I did not cared for it, is more appropriate description). Now just out of eagerness, is it necessary to connect something to AVCC even though we are not using it.

Personally I'd do what the datasheet says along with AVR040 and AVR042, after all Atmel know better than anyone how they intended their chips to be used.
danni - Apr 20, 2009 - 04:01 PM
Post subject: Re: RE: mega16 and 3 pin reg 7805
thakkarhimanshu wrote:
I have not used the A to D converter of the IC, that is the reason I did not connect it


All pins should be connected according the datasheet:

"AVCC is the supply voltage pin for Port A and the A/D Converter. It should be externally
connected to VCC, even if the ADC is not used."

So, if you not want using Port A, maybe AVCC can be left unconnected.


Peter
Jepael - Apr 20, 2009 - 06:07 PM
Post subject: Re: RE: mega16 and 3 pin reg 7805
danni wrote:

So, if you not want using Port A, maybe AVCC can be left unconnected.


I guess this was meant as a joke, right?

Who knows what happens if parts of the chip is unpowered. There is a maximum differential voltage limit between VCC and AVCC pins, AVCC should be within 0.3V of VCC, and AVCC should be within 2.7V-5.5V

Although datasheet says AVCC *should* be connected, so it does not say it absolutely must be connected, but effectively the fact that AVCC depends on VCC would indicate it must be connected.

Well, no datasheet is perfect, but they should be better. Still, even now, people should understand not to leave AVCC disconnected from the datasheet.
dbvanhorn - Apr 20, 2009 - 06:19 PM
Post subject: RE: Re: RE: mega16 and 3 pin reg 7805
I guess "Should" in this case can be taken at "You should connect this pin to VCC if you desire deterministic behaviour of the processor."

Smile
npat_avr - Apr 20, 2009 - 06:41 PM
Post subject:
Does this depend on the AVR used? I was just looking at the Reset/Crystal circuit on avrbeginners.net and saw that AVCC was connected to GND through caps.
theusch - Apr 20, 2009 - 06:45 PM
Post subject:
By that logic there are no hookups to Vcc and Gnd either.
clawson - Apr 20, 2009 - 06:46 PM
Post subject:
Quote:

Does this depend on the AVR used? I was just looking at the Reset/Crystal circuit on avrbeginners.net and saw that AVCC was connected to GND through caps.

The datasheets usually suggest a 10uH inductor between AVcc and Vcc with 100nF to Gnd but obviously one shouldn't design by assumption - there's no substitute for reading datasheets and app notes.
Jepael - Apr 20, 2009 - 07:42 PM
Post subject:
clawson wrote:
Quote:

Does this depend on the AVR used? I was just looking at the Reset/Crystal circuit on avrbeginners.net and saw that AVCC was connected to GND through caps.

The datasheets usually suggest a 10uH inductor between AVcc and Vcc with 100nF to Gnd but obviously one shouldn't design by assumption - there's no substitute for reading datasheets and app notes.


It would not make sense if on some AVRs you can leave it disconnected and on some AVRs you must connect it. Even if it would be like that, it still would be safest to just connect it.

It is also wise not to believe everything there is on the net and verify things from couple of places - there is no place like datasheet.

Datasheets suggest an LC filter if ADC is used, otherwise it can be directly connected to VCC.
dbvanhorn - Apr 21, 2009 - 04:59 PM
Post subject:
theusch wrote:
By that logic there are no hookups to Vcc and Gnd either.


Yup. Smile
dbvanhorn - Apr 21, 2009 - 05:03 PM
Post subject:
npat_avr wrote:
Does this depend on the AVR used? I was just looking at the Reset/Crystal circuit on avrbeginners.net and saw that AVCC was connected to GND through caps.


I can't really make out the picture here, but they aren't "connecting" it to ground, they are bypassing it.

Wether you use a series inductor or not, or what size that inductor is, or what bypassing is needed, is an exercise that depends on how you'll use the port, but the AVCC pin should always be connected to VCC.

This is similar to the argument that one can leave ground or VCC pins disconnected on packages that have multiple ground or VCC pins. Maybe it "works", but it's not a good idea.
All times are GMT + 1 Hour
Powered by PNphpBB2 © 2003-2006 The PNphpBB Group
Credits