1
\$\begingroup\$

The ATTiny85 in the below circuit refuses to do anything.

$ avrdude -c usbtiny -p attiny85
avrdude: initialization failed, rc=-1
         Double check connections and try again, or use -F to override
         this check.    
avrdude done.  Thank you.

My setup:

  • Programmer: USBTiny ISP (Verified it works with an ATTiny with 0.1" pins in a breadboard that I could program just fine)
  • Environment: avrdude via OSX
  • Programmer interface: 6 header pins shoved into 6 pin ISP plug and inserted into offset programmer holes

I've verified:

  • ATTiny chip is mounted in the correct orientation, the dot lines up where it should.
  • Positive voltage (~4V from LiPo) exists between VCC and GND pins on the chip.
  • All traces from the ISP holes to the chip pins are connected where they should be.
  • Ceramic oscillator contacts connect with correct pins, and it's GND is grounded.
  • I can't find any shorts between discreet traces.

I've done everything I can think of and everything checks out. Except that my USBTinyISP programmer cannot talk to this chip. It acts as the programmer pins are not connected to anything.

Lastly, a previous iteration of this board seemed to work fine. That older board didn't include the LiPo charging circuit and it connected the ISP 5V+ pin to the power line (which shouldn't be required if the battery is powering the circuit).

  • Could my chip be bad?
  • What are the chances the ATTiny85 cap was put on backwards?

I'm out of troubleshooting ideas. What am I missing?

Project Schematic Project PCB Project Photo

\$\endgroup\$
  • \$\begingroup\$ Decoupling capacitors are conspicuous by their absence... \$\endgroup\$ – Majenko Jan 6 '15 at 18:41
  • \$\begingroup\$ Indeed. You might also try a new 't85 that has never been fused to depend on an external resonator. Once it has, it can't be programmed without a working clock. Beware that programming with 5v signals while supplying less is out of spec (and I have seen it cause damage) - though you may be able to fix that with series resistors as long as there is little on-board liading. It's probably worth modifying a board for external power as a test anyway - and beware of mistreating lipos. \$\endgroup\$ – Chris Stratton Jan 6 '15 at 19:14
  • \$\begingroup\$ @Majenko, Indeed. Embarrassingly enough, I'm not sure when or where I would use decoupling capacitors. But the previous version of this board seemed to require no such thing. \$\endgroup\$ – Alex Wayne Jan 6 '15 at 19:17
  • \$\begingroup\$ @ChrisStratton this chip was virgin from a Mouser strip of parts. I'm not sure what the default fuses are (cause I can't read them), but I imagine they would default to the internal clock, right? \$\endgroup\$ – Alex Wayne Jan 6 '15 at 19:18
  • \$\begingroup\$ You can probably retrofit some smt caps on the prototype where power nets are on adjacent pins, such as your connectors. \$\endgroup\$ – Chris Stratton Jan 6 '15 at 19:19
0
\$\begingroup\$

Apparently, I had a bad chip! I swapped out the ATTiny85 with a spare and it booted right up. Weird. Perhaps the DOA rate of these chips are higher than I expected, or maybe I static discharged it somehow?

No idea, at least I'm glad I didn't miss something silly :)

\$\endgroup\$
  • \$\begingroup\$ It may the fuse programming. \$\endgroup\$ – copper.hat Jan 6 '15 at 20:49
  • \$\begingroup\$ Yes, most likely corruption of the fuses from a previous attempt. Though applying higher voltages than the supply to the pins - as you seem to be doing here - can also cause damage. \$\endgroup\$ – Chris Stratton Jan 6 '15 at 22:31
  • \$\begingroup\$ Are you saying that using a fully charged LiPo at 4.2V and then using 5V logic form the programmer can cause damage to the chip? If so, I guess that's a good reason to connect the 5V power pin from the programmer to the chip, to bring the supply voltage up to match the logic voltage? \$\endgroup\$ – Alex Wayne Jan 6 '15 at 22:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.