6
\$\begingroup\$

If I set up the fuses on an ATTINY so that the system clock uses the internal 128Khz oscillator (sometimes called the "Watchdog oscillator"), does the internal 8Mhz oscillator still run?

It does not seem to say either way in the data sheet, but I would guess that the primary motivation for running off the 128KHz oscillator would be power savings - in which case it would make sense to shut down the unused 8Mhz oscillator.

Can you think of a way you could even tell? Maybe a super-sensitive antenna coil near the chip looking for a tiny 8Mhz signal while the chip is running?

\$\endgroup\$
2
  • 1
    \$\begingroup\$ What are your observations in a specific datasheet? You could definitely use a radio receiver system with a small antenna to verify state of the oscillators. \$\endgroup\$ Commented Jul 6, 2016 at 2:51
  • \$\begingroup\$ I checked data sheets for ATTINY4313, ATTINY2/4/85, and even for higher end AVRs but all I learned is that the normally excellent Atmel data sheets have (at best) incomplete info on clocks. For example, the ATTINY4313 does not even show the prescaler on the block diagram, and all of them mix the terms "watchdog oscillator" and "128Mhz oscillator" without explanation. \$\endgroup\$
    – bigjosh
    Commented Jul 6, 2016 at 2:58

2 Answers 2

6
\$\begingroup\$

Official word back from Atmel is that the 8Mhz oscillator is disabled when the 128KHz oscillator is selected as the clock source.

This could be very useful complying with the FCC Part 15 exemption for products that do not generate any frequency higher than 1.705Mhz.

Atmel's response is pasted below.


Commented by Abirami Sivakumar (Atmel) 2016-07-12 02:31 PDT

Hello Josh,

If you choose the internal 128KHz oscillator, 8Mhz oscillator won’t run. It is a separate internal low power on-chip oscillator.

Best Regards, Abirami Sivakumar


07/11/2016 08:11:39 AM PDT [josh]

To: [email protected]

Thank you. If I do change the system clock to the 128KHz oscillator, will the 8Mhz oscillator still run or will it be disabled?

Thanks, josh


07/11/2016 05:05:40 AM PDT [Abirami Sivakumar]

[Recipients: Josh Levine]

Hello Josh Levine,

Thanks for contacting Atmel Technical Support Team.

The default clock source setting is the Internal RC Oscillator running at 8 MHz with longest start-up time and an initial system clock prescaling of 8, resulting in 1.0 MHz system clock

If you are changing the fuses, system clock will change according to the new fuse value.

You can output the system clock on the CLKO pin. Please refer to the section “6.4 Clock Output Buffer” in the datasheet.

Link: http://www.atmel.com/images/atmel-2586-avr-8-bit-microcontroller-attiny25-attiny45-attiny85_datasheet.pdf

Best Regards, Abirami Sivakumar


07/08/2016 02:11:25 PM PDT [Josh Levine]

On an ATTINY2/4/85, if I configure CKSEL fuses to select the 128kHz internal oscillator as trhe clock source, will the 8MHz internal oscillator still run?

I am asking specifically trying to use an ATTINY25 in a design that must fall under FCC Part 15 47 CFR 15.103 (h), which requires that the "the highest frequency generated and the highest frequency used are less than 1.705 MHz", so I am looking to confirm that the 8MHz oscillator is not active when the chip is configured to not use it.

Thanks!

\$\endgroup\$
3
\$\begingroup\$

From page 25 of the ATTiny2313 Datasheet, there is the following paragraph:

Internal Osc Description

While this doesn't specifically prove one way or the other, it does suggest that it only runs when selected. Note how it says "If select, it will operate ...". That sort of implies that if not selected it won't operate.

I would also suggest that it shouldn't operate given how much effort has gone in to reducing power consumption of the range.


Granted this is all circumstantial evidence and assumption, but it was worth posting.

\$\endgroup\$
5
  • \$\begingroup\$ I think this is just saying that internal RC 8MHz oscilator is self-sufficient and does not need any external components (as opposed to an external clock, crystal, or resonator), but clearly the wording is awkward and ambiguous. Does the RC oscillator require external components if it is not selected? (empirically it does not) Does the 128KHz oscillator will also run without external components if selected? (empirically it does) Am I reading it wrong? \$\endgroup\$
    – bigjosh
    Commented Jul 6, 2016 at 3:09
  • \$\begingroup\$ @bigjosh It may just be me reading between the lines, but I read it as it will only operate (and will do so with no external components) if selected. \$\endgroup\$ Commented Jul 6, 2016 at 3:12
  • \$\begingroup\$ That reading would certainly suit my needs, but my gut is that the engineer who wrote that just wanted to make sure you knew that you could run off the internal oscillator with no external parts needed. But certainly shows that this section of the datasheet is not as precise and exhaustive as I've come to enjoy form the some of the other parts. \$\endgroup\$
    – bigjosh
    Commented Jul 6, 2016 at 3:16
  • \$\begingroup\$ @bigjosh, as I say, it's not clear either way, that was just my gut reaction. It would be interesting to set the clock source as the watchdog and the prescaler to maximum (256) and upload a program where it is doing nothing but a while(1) loop. That would leave it effectively idling at 500kHz. Then with a resistor in series with the ground, measure the voltage across the resistor with a scope. If you see any current ripple around 8MHz, you know it is still running the 8MHz osc (because the CPU is running at a much lower frequency, so won't be from that). \$\endgroup\$ Commented Jul 6, 2016 at 3:18
  • \$\begingroup\$ This was going to be my next step - compare the ripple at 8Mhz between running off the RC with /64 prescale to running directly off the 128Khz (both while the processor was at idle). But I have a feeling that ripple is going to be very hard to detect, even with my awesome uCurrent pro! We are talking about nA here... Probably need to make some kind of a resonant circuit to amplify and detect it... Anyway - thought easier first step would be to ask on SE! :) \$\endgroup\$
    – bigjosh
    Commented Jul 6, 2016 at 3:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.