Vcc vs Frequency Question - Let's beat this horse one more time

Go To Last Post
15 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0


I did my typical forum search and never found what I believed to be a clear answer to my question.  Per the datasheets (Atmega32U4 in particular) when they show the specification for Max speed vs Vcc, I see this as being ambiguous.  Does MAX SPEED refer to the CPU clocking frequency or the input clock frequency.  i.e. if I use a 16 MHz crystal and set the clock prescaler to give myself a CPU speed of 8 Mhz and if Vcc is at 3.2V, does this comply with the spec? 

 

I would appreciate your thoughts regarding this.

Thanks

Jim

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I guess both the MCU core stages and oscillator driver (its transistors) have that SOA. The 4809 also has an SOA somewhat like that but lacks some of those crystal oscillator options.

 

Anything outside the SOA and Microchip is not responsible. At least that is how I think of such things. Can you run the core in spec and the oscillator stage out of spec? Sure, but the next question is, who becomes responsible? Not Microchip.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

rfdes wrote:
i.e. if I use a 16 MHz crystal and set the clock prescaler to give myself a CPU speed of 8 Mhz and if Vcc is at 3.2V, does this comply with the spec? 

 

Yes.  Or no.

 

I seem to recall previous threads, but can understand that it might be quite difficult to find appropriate search terms.

 

As "evidence" see the discussion on CKDIV8,e.g.:

3. If 8 MHz frequency exceeds the specification of the device (depends on VCC
), the CKDIV8
Fuse can be programmed in order to divide the internal frequency by 8. It must be ensured
that the resulting divided clock meets the frequency specification of the device.

And interestingly, clock prescaler survives many kinds of reset.  So if you get your clock proper, then you can survive the next readet.  BUT think about what happens during power-on reset...

 

My off-the-cuff recommendation:  Use CKDIV8 if your clock is too fast.  Then once everything is stable modifi CLKPR value to your needs.

 

 

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I realize the OP's question pertains to the Atmega32U4 but the new xTinys have info in the data sheet that imply the oscillator functions at full speed over the entire voltage supply range with the caveat that the clock divisor is set appropriately for the actual voltage applied:

Letting the smoke out since 1978

 

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

rfdes wrote:

I did my typical forum search and never found what I believed to be a clear answer to my question.  Per the datasheets (Atmega32U4 in particular) when they show the specification for Max speed vs Vcc, I see this as being ambiguous.  Does MAX SPEED refer to the CPU clocking frequency or the input clock frequency.  i.e. if I use a 16 MHz crystal and set the clock prescaler to give myself a CPU speed of 8 Mhz and if Vcc is at 3.2V, does this comply with the spec? 

MAX is the Flash / CPU speed.

However, the much simpler clock dividers can run a lot faster, but that's often not clearly stated.  /2 from 16MHz at 3.2V sounds fine.

 

IIRC the Xmega  did spec 120 or 125Mhz for CLKIN max, but the CPU lcock must be <= 32MHz 

You could always ball-park sanity test it, if you have a 100MHz variable clock source - set a larger CLKDIV and then ramp the MHz at 3.2V to see where it falls over on some test code.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I appreciate all of the excellent input.  thanks to all

Jim

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Who-me wrote:
IIRC the Xmega  did spec 120 or 125Mhz for CLKIN max, but the CPU lcock must be <= 32MHz
142MHz max into its prescaler.

ATxmega128A1U - 8-bit AVR Microcontrollers

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

But ... I also thought that the crystal oscillator (not clock-in; the oscillator circuitry) was also one of the first things to stop working in "overclocking" situations.

Thus the new crop of 20MHz chips with 16MHz oscillators :-(

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

rfdes wrote:

I appreciate all of the excellent input.  thanks to all

Jim

Oh no, another Jim wink

 

 

 

 

fly over Jim

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274
get $5 free gold/silver https://www.onegold.com/join/713...

 

 

 

 

Last Edited: Wed. Nov 6, 2019 - 09:53 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Depends on the crystal oscillator's safety factor (gain margin) though that's inversely proportional to the square of the frequency.

Abracon-Application-Note-1025-18pF-Crystals-May-Not-Oscillate-with-Energy-Saving-MCUs.pdf

[page 2, middle of left column]

Thus the new crop of 20MHz chips with 16MHz oscillators :-(

And the future crop of 24MHz AVR-DA follow-on to some megaAVR.

AVR128DA64 - 8-bit Microcontrollers due to What are the AVR28DA128 AVR32DA128 AVR48DA128 AVR64DA128 ?? | AVR Freaks

 

edit : gain margin

 

"Dare to be naïve." - Buckminster Fuller

Last Edited: Wed. Nov 6, 2019 - 10:42 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

gchapman wrote:

Depends on the crystal oscillator's safety factor (gain margin) though that's inversely proportional to the square of the frequency.

Abracon-Application-Note-1025-18pF-Crystals-May-Not-Oscillate-with-Energy-Saving-MCUs.pdf

[page 2, middle of left column]

Thus the new crop of 20MHz chips with 16MHz oscillators :-(

And the future crop of 24MHz AVR-DA follow-on to some megaAVR.

AVR128DA64 - 8-bit Microcontrollers due to What are the AVR28DA128 AVR32DA128 AVR48DA128 AVR64DA128 ?? | AVR Freaks

 

edit : gain margin

 

 

Which raises the obvious question, of can those new AVRs support a 24MHz xtal ?  :)  (or do they use the same 16MHz cell ?)

 

26MHz would have been a rather nicer AVR-DA  target spec, as that's a common GPS/Bluetooth timebase - very well sourced and cheap.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Who-me wrote:
Which raises the obvious question, of can those new AVRs support a 24MHz xtal ?

LOL Back when I was your age, certain AVR8 models had 24MHz in the early datasheets.

https://www.avrfreaks.net/forum/...

https://www.avrfreaks.net/forum/...

...

 

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

Last Edited: Thu. Nov 7, 2019 - 02:18 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So, interesting questions:

- if clocked by an external clock signal wave, does a 3V chip run at 16MHz or higher?

- does the prescaler itself, alone, run on higher clock frequencies than the rest of the MCU? It seems so sinve the datasheet recommends using the divider when the input frequency is higher than the recommended value...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hmm... For some time it was 32MHz, not 24. 

24MHz is not a big step from the current 20MHz state of the art. 5V, I know.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

rammon wrote:

So, interesting questions:

- if clocked by an external clock signal wave, does a 3V chip run at 16MHz or higher?

- does the prescaler itself, alone, run on higher clock frequencies than the rest of the MCU? It seems so sinve the datasheet recommends using the divider when the input frequency is higher than the recommended value...

 

Yes, the flash memory is the limiter, if you enable the divider and feed in an external clock, you can have more MHz at the pin, but stay in spec on SysCLK.

 

See comments #5, and #7 with an actual MAX divider-only MHz spec, from XMEGA, but you can get an idea of the scaling from that.