Hi there,
In the past I had successfully used my Arduino Uno as an ISP to load sketches onto my ATtiny84. Suddenly, however, it stopped working. My Arduino will pop up and say "Done uploading." but my ATtiny doesn't actually do anything when I give it battery power. As I said, I have used the exact same method before and it worked perfectly.
It's meant to blink LEDs on every pin. I know the sketch works because I tried it with a separate Arduino, not through the ATtiny84, and it works fine. I've even tried a different ATtiny84 thinking that one of them went bad. But none of them I try seem to work.
I'm just really puzzled as to why it worked one day and now it doesn't. My only guess is that my IDE or some other program updated and now there's an incompatibility issue. Either that or I'm overlooking something super simple.
I have successfully loaded sketches onto my Attiny85 with Arduino IDE 1.8.13 and that same board manager. Your sketch looks good, like you said. I'll set up a breadboard and an Attiny85 with that (slightly modified) sketch and see if I can get it to work. The only difference is that I'm using a dedicated Attiny25/45/85 programmer instead of an Arduino Uno.
This is the error I am getting:
Arduino: 1.8.13 (Windows 10), Board: "ATtiny25/45/85, ATtiny85, Internal 1 MHz"
Sketch uses 720 bytes (8%) of program storage space. Maximum is 8192 bytes.
Global variables use 9 bytes (1%) of dynamic memory, leaving 503 bytes for local variables. Maximum is 512 bytes.
An error occurred while uploading the sketch
avrdude: can't open config file "C:\Users\yorka\AppData\Local\Arduino15\packages\attiny\hardware\avr\1.0.2/avrdude.conf": No such file or directory
avrdude: error reading system wide configuration file "C:\Users\yorka\AppData\Local\Arduino15\packages\attiny\hardware\avr\1.0.2/avrdude.conf"
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Not sure how a config file would just vanish on me, but the other core has more options so I'll use that anyway.
I read that you should burn the bootloader once (or when you change board options, such as clock rate). As far as I know that example sketch should work fine, but I've never tried it.
If you use the core I linked, then options I used are no bootloader on the board, 1MHz internal (external or 128kHz will cause serious issues), CPU frequency, LTO enabled, milis()/micros() enabled, EEPROM retained, and BOD disabled. I believe those options are only set when you burn the bootloader, even if not technically using a bootloader.
Thinking that the issue was with my Arduino UNO, I tried using an Arduino Mega as an ISP. The exact same issue is still occurring. This must mean something is wrong with the way my IDE is set up, but that's really confusing me because I didn't change anything in the time between programming was working, and then suddenly wasn't...
I downgraded my IDE to 1.6.13 and reinstalled my core from there. Tried everything again from scratch, still having the same problem.
I'm at a loss here.
EDIT: I'm going to buy some more ATtiny84s. I've only tried 2, maybe I'm having really bad luck and they're both faulty. That would explain the suddenness of all this. Would be a heck of a coincidence though lol.
I may also buy one of the programming boards from Adafruit or some such.
That seems like the best course of action. Worst case you have a few extra microchips for your next project. I believe the programmer I bought is based on the Adafruit one because it uses their drivers. It's only 8 pin though.