Weird slow programming of Mega128

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

Hi. I have met a really weird programming problem.

After being put away for a year or two, I got my old Ethernut board out in the daylight again. It has a Mega128 with a 14,something MHz crystal.

I hook it up to the ISP cable on my STK500 board, in order to program it, but it doesn't work. It won't work until I reduce the ISP programming clock to 4 kHz (yes, I mean kilo, not mega), but then it works fine. But it is slower than a snail that way.
The processor runs at 14,something MHz, as the serial port transmits at the programmed 115200 baud.
If I use my JTAG, I can program it at full speed without any problems, but I would prefer to use the STK500, as I need the JTAG to debug another AVR that will be connected to this one.

Any ideas? What can make a Mega128 refuse programming at higher speeds than 4 kHz, when it is running at 14 MHz?

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

A significant amount of capacitance on the lines perhaps? Is there anything else attached to the ISP lines?

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

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

Unfortunately not. That would have been an easy fix.

The lines does pass through a mux, which is controlled by a programming jumper. And yes, I have remembered to set the jumper :wink: