The ATtiny84 is another of Atmel's little tiny 8-Bit Processors. 8K of program space, 12 I/O lines, and 8-channel 10 bit ADC. It will run up to 20MHz with an external crystal and can be programmed in circuit.
This skill defines how difficult the soldering is on a particular product. It might be a couple simple solder joints, or require special reflow tools.
Skill Level: Rookie - The number of pins increases, and you will have to determine polarity of components and some of the components might be a bit trickier or close together. You might need solder wick or flux.
See all skill levels
If a board needs code or communicates somehow, you're going to need to know how to program or interface with it. The programming skill is all about communication and code.
Skill Level: Rookie - You will need a better fundamental understand of what code is, and how it works. You will be using beginner-level software and development tools like Arduino. You will be dealing directly with code, but numerous examples and libraries are available. Sensors or shields will communicate with serial or TTL.
See all skill levels
If it requires power, you need to know how much, what all the pins do, and how to hook it up. You may need to reference datasheets, schematics, and know the ins and outs of electronics.
Skill Level: Rookie - You may be required to know a bit more about the component, such as orientation, or how to hook it up, in addition to power requirements. You will need to understand polarized components.
See all skill levels
Based on 1 ratings:
Yes, extra I/O and ADC pins just for additional cost of 11 cents, why buy Attiny 85 ? With this SPI programming pins need not to share for I/O functions. Some libraries don't work (eg. Low power library), no UART but doesn't matter. You need to step up into raw AVR territory to play with these chips for more features ! By the way, the VUSB bootloader (see tutorials tab) didn't work for me even though I was able to burn the hex into the chip. Windows 7 didn't detect any USB device, now doing things the SPI way !
Looking for answers to technical questions?
We welcome your comments and suggestions below. However, if you are looking for solutions to technical questions please see our Technical Assistance page.
Log in or register to post comments.
See.... https://www.sparkfun.com/news/2237 ... for how to program this lovely chip with just an Uno and some free software.
That will, I think, be sufficient... but if it daunts you, maybe my "getting started" can help. It was written for the ATTiny85, but 99% of it (I hope! As I intend trying the 84 on the basis of that belief!) also applies to the 84.
85 and 84 cost nearly the same. But 84 gives you an extra 6 GPIO lines! (^_^)
My "Getting started" is at...
yay! a little-ish chip for little-ish projects. but not so little you run out of pins and yell obscenities at it.
Thank you Sparkfun! Now I can start my world Domination plan using ATtiny's with 8 Pins, 14 Pins, and 20 Pins.
20 pins –> ATtiny2313
If you want to use the arduino ide with this, the MIT High-Low Tech group have done a great job with the integration: http://hlt.media.mit.edu/?p=1695
I have one of these monitoring the temp/humidity in my frog tank. Works really well for a small project and is more or less a single chip 14 pin "arduino".
I wnt to use this as a permanent processor in a circuit prototyped on an Arduino, can I use the Tiny AVR programmer (https://www.sparkfun.com/products/11460) to program the chip? the project needs more pins that I can get on the Tiny85 so this would be a great solution!
That's how I do it. You just need to wire up the 6 pin connector to the appropriate pins on the tiny84 using jumper wires (vcc, ground, reset, sck, mosi, miso). Works like a charm. You'll almost certainly need to solder a header onto the tiny avr programmer board though.
According to the datasheet, it will work down to 2.7 volts at 8mhz, which makes this chip ideal for battery powered projects, since battery voltage goes down as the batteries die. Yet, it will also work fine at 5 volts (mine is running off of that and it hasn't left a crater in my breadboard) so it could run directly off of 3 AA batteries (1.5 v * 3 = 4.5 for alkalines, 1.2 * 3 = 3.6 for rechargeables)
Of course, you could use 6 AA batteries and a 5v regulator, but who wants to use that many batteries? I use rechargeable AA batteries to power my portable projects and a 9v 1000 mA, UL listed DC power supply for my stationary ones (with the appropriate regulators of course)
BTW, http://hlt.media.mit.edu/?p=1695 has a solution for those who want to make smaller projects using the Arduino environment. This makes for a relatively inexpensive project if you're looking to make a few small "light show" type devices and/or you're good at multiplexing. Since the Arduino Uno can be used as an ISP, I recommend picking up one of those, because you'll get to work with a pre-made board off the bat and then "graduate" to using one to program another.
Happy to see these here. They are a nice little chip. I still have a couple left in my stockpile, but I know where I will be replenishing my supply from now.
What is the difference between the ATtiny84 and the ATtiny2313?
Why bother even carrying these?... you can buy them from mouser for half the price that you sell them... stick with what you are good at and leave this stuff to the big boys...
That's not true. There's one that mouser sells for about half this price, but that one runs at 10 MHz. This one runs at 20 MHz, which mouser also sells... for $0.13 more than sparkfun.
Look at ATtiny84A... indeed runs at 20MHz and costs half... $1.55, in quantities over 25, it is $0.99.
That one is ATtiny84A not ATtiny84. First one has 0.512kB EEPROM 12 I/O Pins, second one doesn't.
This should be as popular as the t85. It is not and many are misinformed.
It is indeed the same... even the same signature. You should read datasheets so you are informed before you write.
I don't hate sparkfun... quite the contrary... sometimes they should do their homework too.
I bought one of these and transferred a small project onto it that uses a few pots and some pushbuttons and everything works just as it did when I initially set it up on my Uno however i can't seem to load any code onto the tiny84 if it's over 4.2k..? I get a compile error which I don't have in front of me but it said something about truncating the code. If i compile the exact same code but have my Uno as the selected board in the ide, it compiles fine. If I remove a few lines of the code and have the board set to atTiny84 then it compiles fine too if it is under 4.2k. Am I missing some step that allows for bigger code to be uploaded.? It is supposed to hold up to 8k right.?
You are running out of RAM, which the arduino IDE is not smart enough to tell you.
it has nothing to do with 4.2k... you have to change your code to use byte or char, if it makes sense... Otherwise it won't work... stop copying others and do something yourself.
Will this chip handle complex sketches that contain if statements?
It will handle if statements, but depending on just how complex your sketch is the sketch may not fit inside its limited memory. Wikipedia: ATtiny comparison chart
If you know your requirements, you can find a suitable AVR through AVR Freak: compare devices
Am I correct in saying that the internal clock it running at 8MHz?
The internal clock runs at 8 MHz, but it comes from the factory programmed to divide this 8 MHz clock by 8 which results in the chip running at 1 MHz You can make it run at the full 8mHz speed (without using an external clock) by modifying one of the fuse values. Refer to this link: http://www.engbedded.com/fusecalc Change the value of low fuse (LFUSE) from 0x62 to 0xE2. You can do this with Avrdude and a programmer that can deal with the Attiny84, or a programmer like the AVRISP MKII with the driver and programming interface that accompanies Atmel Studio (which can be downloaded free).
do i need to buy a crystal oscillator for this ship ?
This chip will run with either an external clock, or an internal one. This is selected when you're programming it. See the datasheet for more information.
Can these read serial data, for example, from an ID-12 RFID reader?
Near the bottom of...
... you will find a suggestion that this WILL read serial data streams. I haven't TRIED... but like my experiences to date with everything at the page cited... hence the work put into a "Getting started..." page...
... which was written for ATTiny85, but I believe applies in all significant ways to 84 as well.
These don't have a serial port, but do have TWI(I2C) and SPI.
And that's the wiring for programming it with Arduino: http://www.instructables.com/id/Full-Binary-Clock/step5/Programming-the-ATtiny84/ I tried programming it with Tiny AVR Programmer https://www.sparkfun.com/products/11460 and it works great. Please remember - programming pins MOSI, MISO and SCK are not "0","1","2" as on AtTiny85
so to upload code to this from my arduino through isp, I need a 10uf cap but does the voltage matter on the cap because I got a 10uf 25v and it didn't specify in any tutorials I found.
25V is plenty :) For longevity when using a capacitor as an actual component, most people tend to double the system's voltage to get the desired specified voltage. In this case, your Arduino will probably be running at 5V, so 25V is fine. ( The capacitor is only used in this case to prevent the Arduino from auto-resetting, so it's not as critical, as long as it isn't below the system's voltage. )
Ok sweet thanks
Does this come setup with the internal oscillator or do you need to buy a 20MHz crystal for it? If it's setup with the internal oscillator, how accurate is it?
You can use the internal 8MHz oscillator (and can divide that further down), or you can use an external crystal; the choice is up to you. The clock source selection is made while you're programming the chip. From experience the internal oscillator is reasonably accurate to begin with, but there's also a tuning register you can use to make it quite accurate. See the datasheet for all these details.
Is there an Eagle part for this in the SparkFun library? I couldn't find it, but I might have missed it.
Only the surface mount version is present.
Submitted pull request with DIP package.
How many output PWM pins does this have? I want to be able to individually control at least 4 rows of LEDs. Thanks
Love them...easy to fit in small spaces and they run at 8mHz with no external components whatsover. None. Zero. Zip. The chip and a power supply, that's all you need.
The Tiny85 is a bit too limited. These are just right.
(Will work bare ... although most people recommend adding a decoupling capacitor and an extra pullup resistor on the RESET pin)
For 11¢ more, I'm kind of thinking about these rather than the 85's. Plus 12 i/o would be nice. (Or maybe less if using crystal :p)
Any plans for a 14 pin AVR development board?
YES!! the possibility is limitless!! i'm going to build a prototype right after my order arrive.