Tiny13 Fuse Settings, AVRISP2 problem

Go To Last Post
8 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

I have an unusual problem. I use AVR Studio 4, the GCC compiler chain and the AVR ISP2 to program Tiny 13s. I have done this successfully 400+ times using the same object code. Nothing has changed (that I know of!).

Today I tried to program some brand new tiny 13s. When the chip leaves the factory SUT_CKSEL is set to 9.6MHz and 64mS and CKDIV8 is on. However when I tried to download the object code to the new chip the programmer - via AVR studio said that SUT_CKSEL was blank and CKDIV8 was unchecked. I couldn't change these via AVR Studio and, of course, the attempt to program the chip failed. Thinking the chip was bad i tried a second chip and the same thing happened. I logged the programming output to a file. All this told me was SD=0x3e..okok. Not very useful. I tried another chip and the same thing happened.

Has anyone seen this before? Is there a cure?

Thanks in advance,

Steve

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You may have altered the ISP frequency since you last programmed Tiny13s.

Or they may be a batch that left the factory without the proper fuses.

Set ISP frequency to 125kHz.
If that does not work, supply an external clock to XTAL1 pin.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

David,
Thanks for replying. Actually I kept the ISP frequency as the default. I tried reducing it but it has no effect. Could you be a bit more explicit about supplying a clock to Xtal pin 1. What will this do?

Thanks, Steve

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks Clawson. I'll try that.

One of the symptoms I have observed is that if I try to program a fresh AVR from a batch I have programmed before the programmer/software seems not to read the fuses from the new AVR. It is as if it stores the values from a previous AVR somewhere and uses these rather than reads them from the new AVR. The result is I cannot program the new AVR :-(. Have you seen this before?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

That is complete mumbo-jumbo.

However, the intelligent programmers like AVRISP-2 or STK500 remember ISP frequency.

So if you have programmed a virgin AVR at 200kHz.
Cleared the CKDIV8 fuse, and then programmed at 1500kHz.

When you next try a virgin, the ISP frequency is too high.

If you use Makefiles or batch files, it is wise to set your desired ISP frequency.

If you like using GUIs, remember to observe what the dialogs actually say.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

David,

I am not sure what you mean by mumbo-jumbo. All i can say is that this behaviour is what I have observed and verified. Thank you for the point on the AVRISP-2, I did not realise this. And, believe it or not I like GUIs, and I do read the dialogs.

Clawson,

Thanks for the very helpful advice > I'll knock up a 1 MHz xtal oscillator to try and reinstate the factory settings. If not I guess I'll have to shell out (no pun intended) for a high voltage programmmer. BTW I used to live and work at Weathersfield just down the road from you.

Regards to all,

Steve

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Guys,

Thanks for the help. I just ordered an AVR Dragon from RAPID so that I can do some high voltage programming and clear the ill set fuses on the unusable chips. Part of the problem would seem to be low voltage on the target board, neither the AVRISP2 or it's software complained about the low voltage. But I swapped the batteries for some fresh ones and I can program the Tiny13s again.