AVR Reset Problem

I am using the AT90S2313 in a pulse generating project but I am having trouble getting the AVR to come out of reset.

When I reset, or initially apply power, the AVR will not proceed to execute until I ground Pin 4, which is one of the crystal pins.

I am using a 10Mhz crystal, with the standard 22 pF caps to ground.

I was having the same problem when I was using breadboard so I made a small board for the AVR and soldered the crystal and caps directly to the avr.

Am I being naive and this is this normal operation?

Could it still be noise?

Sincerely, James

Reply to
J. McMillan
Loading thread data ...

Try to use "supervisor" like MCP100 or something like this.

Maybe you power rising front is't fast.

Reply to
artem

A 1k resistor from the reset pin to 5V and a 100n cap to ground should do the trick...

Reply to
AVRFreak

AVRFreak wrote: : A 1k resistor from the reset pin to 5V and a 100n cap to ground should do : the trick...

AVR site docs recommend 4.7K and .01uf (100nf). I've used that and it works well. Using a 10K and .1uf does NOT work well, so the reset line is a bit tempermental on AVR's I think.

DLC

:> > When I reset, or initially apply power, the AVR will not proceed to :> > execute until I ground Pin 4, which is one of the crystal pins. :>

:> Try to use "supervisor" like MCP100 or something like this. :>

:> Maybe you power rising front is't fast. :>

--
============================================================================
* Dennis Clark         dlc@frii.com                www.techtoystoday.com   * 
* "Programming and Customizing the OOPic Microcontroller" Mcgraw-Hill 2003 *    
============================================================================
Reply to
Dennis Clark
÷ ÐÉÓØÍÅ Fri, 21 Nov 2003 10:16:23 +1300, AVRFreak ÎÁÐÉÓÁÌ:

Not if rising front is very long.

Supervisor or WDog is the best choise. But if you choise a bad soldering flux....

Reply to
artem

I've always used 10k and 100n without any problems.

Leon

Reply to
Leon Heller

Unlike others already pointed out, this has IMO nothing to do with a proper reset signal. 22p caps are ofter recommended but too low. A crystal is specified to be loaded with 25pF. The two 22p caps are in series from the crystals' point of view, thus too low. The capacitance of the AVR is added to this but is mostly not more that 5 to 10 pF. I always use 33pF at least (and up to 47p when the crystal frequency should really be spot on). And another very important thing is proper grounding of the caps. So use a small groundplane underneath the crystal and caps and connect that plane with the ground pin of the AVR in the sortest way possible.

Meindert

Reply to
Meindert Sprang

J. McMillan wrote: ...

... What means standard in this case? Are such values for caps specified in the crystal datasheet? Maybe it is "simple" case when used capacitance did not match crystal charcteristics and it cannot start oscillating. When you ground pin 4 you also change circuit capacitance for the moment and it causes start of crystal oscillation.

Regards,

--
Artur Lipowski
Reply to
Artur Lipowski

I would agree with the response from Meindert Sprang. The 22pf caps are probably just a bit low. I think you'll find that the lower the value of the caps the faster the osc will start up and the more likely it will fail to start at all. If you go with higher value caps the startup time will be a bit longer, not usually a problem, but it will startup reliably. Btw, I've used reset timing as high as 10uf and 10k with no problems at all. The only time I've ever had problems with a slow power source was with a switchmode supply that had to have soft start and that was fixed using a power supervisor circuit.

Mike

Reply to
Exador

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.