Attiny 85 at 16mhz

Is it possoble to clock a attiny 85 at 16mhz internal. if so, how is it done?

Will you be able to conrtoll servoes better because I cannot get the 8bitservo lib to control servos

thanks
Paul

Yes it is possible via modifying the fuses, but not every ATTINY85 can run at 16MHz

that is great, how does one modify the fuses?

what attiny85 you have?

The ATTinyCore core makes it easy to set the fuse options and burn a bootloader. Use the IDE boards manager to install the core.

that is done. at85 gives me choices of mhz. One of the choices is 16mhz, with the right at85 will it set the fuses for 16? i tried a few and i can only use8mhz

See post #4

Select the "16 MHz Internal PLL" clock option, connect your ISP programmer, and do tools -> burn bootloader. In keeping with the convention set by the official cores and followed by all third party classic AVR cores, fuses are only set by "burn bootloader", so this step is needed even if you are not using a bootloader (just select the ATtiny85/45/25 (no bootloader) option).

Not sure what you're on about the the "types of attiny85" - unless you're referring to the ATTiny85V which is rated for only 10 MHz at most (V = 1.8V-2.7V @ 4 MHz 2.7-5.5 @ up to 10 MHz, non-V = 2.7-5.5v @ up to 10 MHz 4.5-5.5V @ up to 20 MHz.

So only an ATtiny 85 not-V running at at least 4.5V (ie, 5v nominal) would be in spec running from the PLL

It might help a little with servos to run it faster (note that ATTinyCore comes with it's own version of the servo library, including a variant named Servo_ATTinyCore.h that you can include in place of Servo.h if you have installed the Servo library normally, in which case the incompatible Servo.h in your libraries folder will be chosen by the IDE in favor of the compatible one I include with ATTinyCore)

Last time I tried it the library seemed to work passably on tiny85s.

Sadly, during the chip design phase, the tiny85 was not given the standard issue 16-bit timer that almost all classic AVRs have (I believe the only exceptions with >= 2k of flash are the high-speed-timer tinies (x5, x61, and the ancient 26), plus the tiny43 with the on-chip boost converter and a lack of every other desirable feature. And the modern (post 2016-revolution) AVRs all have 16-bit timers - several kinds actually), so the hardware they have to work with just isn't great for controlling servos.

An ATtiny84 (or 841, or any of the modern AVRs) would be better suited to servo control.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.