Author Topic: Atmega328P Reset Pin DIrect To Positive Supply  (Read 1943 times)

0 Members and 1 Guest are viewing this topic.

Offline petersanchTopic starter

  • Regular Contributor
  • *
  • Posts: 62
  • Country: 00
Atmega328P Reset Pin DIrect To Positive Supply
« on: August 04, 2018, 07:03:36 am »
Hi All
Im building a PCB with an Atmega328p running Arduino. The Atmega will be programmed by the distributor and never needs to be reprogrammed. Can I connect the reset pin directly to +5v instead of using a pull up resistor?

Cheers
 

Offline westfw

  • Super Contributor
  • ***
  • Posts: 4199
  • Country: us
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #1 on: August 04, 2018, 07:21:21 am »
Why?It's actually got a built-in pullup resistor; in theory, you need not connect it to anything.  (which is less ... limiting ... than connecting it to Power.)
 

Online Kleinstein

  • Super Contributor
  • ***
  • Posts: 14172
  • Country: de
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #2 on: August 04, 2018, 08:02:18 am »
Some of the newer AVRs allow to use the reset pin as an normal IO if the reset function is disabled.  I have not checked if this works with the 328P though.  Usually there is no need to have the reset pin hard at VCC, though it would be possible.
 

Offline petersanchTopic starter

  • Regular Contributor
  • *
  • Posts: 62
  • Country: 00
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #3 on: August 04, 2018, 08:13:28 am »
Why?It's actually got a built-in pullup resistor; in theory, you need not connect it to anything.  (which is less ... limiting ... than connecting it to Power.)

Thanks.
The reason is to lower the list of parts. I read that the builtin resistor is quite weak and should not be used for production. Has any body had any luck with only the internal pull  up for production? Were there any glitches?
 

Offline Rerouter

  • Super Contributor
  • ***
  • Posts: 4694
  • Country: au
  • Question Everything... Except This Statement
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #4 on: August 04, 2018, 10:28:26 pm »
The default pullup is in the order of 100K, its fine when its just a pad, or single digit mm away from your ICSP header with no ground plane breaks under it,

When its longer, or has breaks under it with high speed traces, (Sometimes you route yourself into a corner), you should just throw a single passive at the problem, e.g. a 10K pullup.

And for the biggest reason, if you hard tie the reset you can never reprogram via ICSP without removing the chip from the board, it uses the reset pin for programming.
 

Offline Siwastaja

  • Super Contributor
  • ***
  • Posts: 8168
  • Country: fi
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #5 on: August 06, 2018, 10:03:40 am »
Older AVRs had a silicon design fault so that the reset circuitry was unreliable and very sensitive to noise; the official solution was to override the large pullup resistor with a smaller external value, typically around 4.7k, and possibly add a small capacitor to the ground. Some programming devices AFAIK went so far as to measure the value of this resistance and refuse to work without a properly sized external resistor. At least I remember using an official programmer which never worked at all unless you added the pullup.

Now, I'd guess they have already fixed their product, so the pullup shouldn't be necessary anymore - but it became common practice to use one, and you can see the legacy on the forums.

I'd keep the pin open to have the reprogrammibility, unless you are doing very massive batches with pre-programmed chips from Atmel/Microchip and you are sure your firmware won't need updating, or have your own reliable and verified in-application programming in place. Even if this means trusting the internal pullup, it shouldn't be a problem anymore.
 

Offline cv007

  • Frequent Contributor
  • **
  • Posts: 825
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #6 on: August 06, 2018, 03:25:04 pm »
The datasheet shows the internal pullup as 30-60k.
Put a footprint for the pullup resistor on the pcb, either route a trace between the pads or leave as-is.
All the bases will be covered-
no ext pullup resistor needed as you wish
if using a trace between pads- if re-programming ever needed for some reason just cut trace
if not using trace between pads- if internal pullup not adequate for some reason, just place pullup resistor or short pullup pads 
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #7 on: August 06, 2018, 04:14:38 pm »
As a matter of practice, I never tie any logic signal hard to Vcc.  I just don't!
I will tie them hard to Gnd.
Mostly this is left over from the early days of TTL but, seriously, how much does an 0805 (or smaller) resistor cost in quantity?

"Never need reprogramming" sounds a lot like the Eureka Syndrome.  "Eureka, I got the last bug out!".  I would absolutely put the ICSP header on the board.  I see this implemented on many boards as simply plated through holes.  The pads are placed slightly out of line (staggered) so that the programmer header will be forced to make a connection on all pins.  The pads are probably no cost except real estate.

 

Offline Siwastaja

  • Super Contributor
  • ***
  • Posts: 8168
  • Country: fi
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #8 on: August 06, 2018, 04:32:06 pm »
"Never need reprogramming" sounds a lot like the Eureka Syndrome.  "Eureka, I got the last bug out!".  I would absolutely put the ICSP header on the board.  I see this implemented on many boards as simply plated through holes.  The pads are placed slightly out of line (staggered) so that the programmer header will be forced to make a connection on all pins.  The pads are probably no cost except real estate.

If it's a very cheap mass produced device, it's cheaper to just ship replacement boards when the bug is found, with the new SW revision, than to try to reprogram. Reprogramming with the AVR ISP is a can of worms; you need a special device, so practically the customer cannot do it. If you calculate for two-way shipping, someone manually programming the devices, OR shipping a programmer to the customer, it's always at least tens if not hundreds of $. This is why single-time programmable devices exist, as well.

Similarly, sometimes the combined real estate cost, P&P cost, BOM line cost and part cost of a resistor is non-negligible. In a very simple and cheap design, it can account for 5% of total cost.

And, if you have a customer-reprogrammable firmware (by using your custom reflasher code), it's fine without the reset pin.
 

Offline Scrts

  • Frequent Contributor
  • **
  • Posts: 797
  • Country: lt
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #9 on: August 06, 2018, 05:14:16 pm »
As a matter of practice, I never tie any logic signal hard to Vcc.  I just don't!
I will tie them hard to Gnd.
Mostly this is left over from the early days of TTL but, seriously, how much does an 0805 (or smaller) resistor cost in quantity?

"Never need reprogramming" sounds a lot like the Eureka Syndrome.  "Eureka, I got the last bug out!".  I would absolutely put the ICSP header on the board.  I see this implemented on many boards as simply plated through holes.  The pads are placed slightly out of line (staggered) so that the programmer header will be forced to make a connection on all pins.  The pads are probably no cost except real estate.

Even if you put the resistor in, you can do the tests and not populate it in the final BOM. But I don't think connecting reset to VCC is a good idea.
 

Offline Quarlo Klobrigney

  • Frequent Contributor
  • **
  • Posts: 967
  • Country: pt
  • This Space For Rent
Re: Atmega328P Reset Pin DIrect To Positive Supply
« Reply #10 on: August 14, 2018, 03:44:57 pm »
I'd still hang a low value cap off it for noise immunity. I also turn all unused pins into outputs to avoid the same issue i.e. floating holes (0=in, 1=out) for which noise can fall in to.
Voltage does not flow, nor does voltage go.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf