Go Down

Topic: External crystal for Attiny85 (Read 6 times) previous topic - next topic

ProfePaco

Dec 25, 2011, 04:36 pm Last Edit: Dec 25, 2011, 04:39 pm by ProfePaco Reason: 1
I would like to employ an external 20MHz crystal for Attiny85.



I see that the crystal must be attached to pins 2 and 3. And datasheet gives us recommended values for the capacitors. OK.

However, the question is, pins 2 and 3, cannot be used for inputs/outputs if an external crystal is present?

Thanks in advance

Runaway Pancake

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

spycatcher2k

Hi - You can use the pins as I/O if you do not use a crystal, You can set the chip to use an internal 8Mhz (or 1Mhz with divide by 8 set). OR run the chip at upto 20Mhz with the crystal & caps.  Having built over 100 projects with 45/85 chips, I have not used a crystal setup yet (other than on my programming board,  just incase I set the fuses to use external clock).
Drew.
http://www.uk-pcb.co.uk - My UK Based PCB Fab & Assembly Company
Design work undertaken
SMD & Thru-Hole assembly

ProfePaco


Hi - You can use the pins as I/O if you do not use a crystal, You can set the chip to use an internal 8Mhz (or 1Mhz with divide by 8 set). OR run the chip at upto 20Mhz with the crystal & caps.  Having built over 100 projects with 45/85 chips, I have not used a crystal setup yet (other than on my programming board,  just incase I set the fuses to use external clock).


Yes... however in my case I need a lot of power because I have to make 3 FFT from 3 microphones continuously... so 20MHz better than 8. But I do not have pins enough if I use a external crystal.

I need 3 analogs input for the mics and one pin for sending the information to another Arduino.

BenF


... so 20MHz better than 8. But I do not have pins enough if I use a external crystal.

The AtTiny85 has a PLL circuit that can be used as a system clock source for 16MHz (64MHz / 4) operation. All you need is to program the approriate clock select fuse.

guardian of light



... so 20MHz better than 8. But I do not have pins enough if I use a external crystal.

The AtTiny85 has a PLL circuit that can be used as a system clock source for 16MHz (64MHz / 4) operation. All you need is to program the approriate clock select fuse.


Wow, thanks, that is mighty good to know.
Entrepreneurship, Arduino, Ham Radio & General Wannabe Hackery

http://insapio.com/
Twtr: @mltd_alexander

putyn

http://www.obdev.at/products/vusb/easylogger.html here is an example of the attiny45 (but could be used on attiny85)  used with its internal oscillator at 16.5Mhz if you download the source code youll see how that its done

hope this helps

ProfePaco


falcon74



Hi - You can use the pins as I/O if you do not use a crystal, You can set the chip to use an internal 8Mhz (or 1Mhz with divide by 8 set). OR run the chip at upto 20Mhz with the crystal & caps.  Having built over 100 projects with 45/85 chips, I have not used a crystal setup yet (other than on my programming board,  just incase I set the fuses to use external clock).


Yes... however in my case I need a lot of power because I have to make 3 FFT from 3 microphones continuously...


If I am not mistaken, FFT on a single channel it a quite a stretch on a ATmega328 (Arduino) at 20MHz, so 3 channel FFT with tiny45/85, is it realistic ?

naut

old topic, but related question:

If I want to use the SoftwareSerial library with an Attiny85 I would use an external 20Mhz crystal?

Erni


john1993

20mhz (actually 30mhz) is no problem for t85 using pll and oscal reg. however w/o a hardware multiplier fft would be hard.

Go Up