Program an ATtiny45/85 with an Arduino Uno without Any Errors | Complete In-Depth Tutorial (2024)

preview_player
Показать описание
Welcome to Keon's Lab!
In this video I'll show you how to program an ATtiny 45 or ATtiny 85 using an Arduino Uno as programmer! I'll point out the most common reasons errors occur and how to avoid them to get a successful program upload every time!

When I first learned about the ATtiny, it took me forever to figure out how to upload a sketch onto it because all the tutorials and guides always left out a couple key pieces of information regarding pin numbers and uploading that are critical to successfully uploading a program using Arduino as ISP.

My goal in making this tutorial is to provide an in-depth guide to programming an ATtiny that I wish I had back when I learned about the ATtiny over 10 years ago. I hope this video is useful to anyone having trouble getting their ATtiny to work.

Remember to please Like and/or Subscribe for more videos! :)

Chapters:
00:00 Intro
01:03 About the ATtiny
02:12 Required Materials
02:42 Setting the Arduino as ISP
04:38 Wiring up the ATtiny
08:15 Configuring the Arduino IDE
10:21 Configuring Upload Settings for the ATtiny
11:22 Burning the Bootloader to the ATtiny
12:14 Uploading a Sketch to the ATtiny
14:33 Blink Sketch Running on the ATtiny
16:12 Adding a Second LED
19:08 Powering with a Lithium-ion Battery
20:00 Lithium Super Capacitor Powering the ATtiny
20:38 Outro
Рекомендации по теме
Комментарии
Автор

Should I make a tutorial on programming the Atmega328p or the ATtiny13a?

KeonsLab
Автор

Perfect video lesson.
I have damaged an Attiny85 tried in other ways. Your explanation is accurate and it works, it works very well.
Thank you very much.

murilomilani
Автор

Just digging through my electronics and came across a tube of 20 ATtiny85 from back in my PIC16F84 days (mid 90's).
I have a remote control project so I was going to use one of them to provide the code and flash the LED when the remote button is pressed.

Found a "digispark" thing in the same drawer as the ATtiny85 and thought that might work as a test bed.
Long story short. I'm glad I found this video and will get my Arduino setup as a programmer.
Thanks!

jdholbrook
Автор

I tried programming the Attiny45 for RBG common anode LEDs with no results. All the videos I've seen so far have been confusing. I think you explained the programming of the Attiny microcontroller the best. Having said that you have encouraged me to try again. Thank you very much. All the best wishes

Kimiamodularedheinteligjencaar
Автор

Of all the videos I have looked at, this is the 'Holy Grail'. Top marks. I had built a shield for my Uno based on the instructions from another video. Got the PCB made and inserted the relevant components, Attempted to program an ATTiny85 - Nothing!! Tried all combinations of settings. Nothing. Programmer required!! Looked at other videos. Still no joy!

Came across your video an noticed the words 'Complete in-depth tutorial' and thought, Okay. try this one to see what happens. Wired up the breadboard as per your instructions and set the test program up. THEN CAME THE CRITICAL BIT at 12:20 in the video!!

None of the other tutorials mentioned using the 'Upload using Programmer' command in the sketch menu. WHAT!!! OKAY!!. Hmm!! Do as the man says!! It uploaded to the breadboard setup and I had no errors. OKAY!! Try the Blink sketch. Uploaded it and Hey Presto! the LED started blinking!! One happy guy so, curiosity then kicked in.

I installed the PCB header I got made. and uploaded the same sketch. Boom!! LED started blinking on the PCB.

BRILLIANT!! And all because of one small command - A KEY STEP!! - that every other video seems to have missed out.


Thank You!!

dpbarry
Автор

Nicely explained, especially the important point about 'upload using programmer'. Just a small point though, the cap has to be disconnected after bootloading. And lastly, used Arduino IDE ver 2.3.2. Thanks again.

rectifyer
Автор

Where were you years ago when I needed you 🤣😭🤣Excellent Video tutorial! Earned another sub from me 🙂Have you considered turning this into a step by step free PDF download for your viewers, I am sure there are many oldies like me who love to print it out and have it in front of them.

merkabaenergy
Автор

Hi, I was getting so frustrated, then I found your tutorial. It worked right away. THANK YOU so much!

pierodis
Автор

I really appreciate your straightforward tutorial

tikroute
Автор

Nice👍, very interesting.
Now learned something new, thanks to you.
Keep doing such interesting videos.

valixg
Автор

Such a clean and well explained tutorial! I suppose this will work the same for other Attiny85 variants such as the ATTINY85-20SU model? I also noticed this smaller version is used in Digispark Attiny85 boards. I have a few 20SU that i need to program and then i will have to solder them to the ready PCB i ordered. Since this model is smaller, i will have to connect it to the breadboard using a OTS-20-1.27-01 SOP8 adapter socket.

redpill
Автор

Make a video about the ATtiny13a. Looking foward.

rectifyer
Автор

Nice. P.S.: That was actually really cool.

mikebond
Автор

Always wanted to use these little guys but the documentation isnt as easy to understand for me. Maybe now I can give it a go. Thanks for the video.

JH-uujl
Автор

Excellent, thank you!
Btw 8192 bytes is exactly 8 kB.

SamiJumppanen
Автор

So 0, 1, 2 are for programming only? not outputs

michaelstraughn
Автор

Why do we need to insert a 10 uf cap ??

sooraj_
Автор

Hi im getting theerror invalid signature failed to erase chip. Wiring correct.please help.

janakasilva