Using a brand new ATmega8515

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

My code and external circuitry are working great using the 8515 embedded in in the STK500.

So I built a cut down version of my target circuitry (AVR, external crystal, 2x 22pF caps and /RESET tied to Vcc thru 1K) to run standalone from the STK500, but to use the 6-pin ISP programming interface from the STK500 to update the s/w as required.

To keep things simple for now, I'm powering the external circuit from the VTG connector on the 6-pin - current draw is minimal and I have 5v on the target circuit OK.

But with a brand spanking new ATMega8515 in circuit I get all the symptoms of not having an AVR at all :-(

...the STK cannot read any fuses, do any updates etc etc

Do I need to initially program the 8515 in the STK500 for the right fuses and oscillator etc, or is there some other gotcha that I'm obviously unaware of?

(I could just try it, but I'm at work at the mo, but can't get the problem outta my mind!)

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

Most (all?) AVRs run off the calibrated internal oscillator when brand new. The ATmega8515 is shipped with the fuses set so that it is running off the internal calibrated oscillator at 1 MHz.

As the ISP frequency may be at most one quarter of the AVR clock frequency it has to be at most 250 KHz. Higher than that and You will get problems with reading the chip signature, program fuses, FLASH and EEPROM etc. Try lowering Your ISP frequency to, say, 115.2 KHz.

If You can program the fuses this way, You can then run the AVR off the external chrystal You have provided, and run the ISP at one quater of the frequency of that chrystal.

As of January 15, 2018, Site fix-up work has begun! Now do your part and report any bugs or deficiencies here

No guarantees, but if we don't report problems they won't get much of  a chance to be fixed! Details/discussions at link given just above.

 

"Some questions have no answers."[C Baird] "There comes a point where the spoon-feeding has to stop and the independent thinking has to start." [C Lawson] "There are always ways to disagree, without being disagreeable."[E Weddington] "Words represent concepts. Use the wrong words, communicate the wrong concept." [J Morin] "Persistence only goes so far if you set yourself up for failure." [Kartman]

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

I tried that last night (sorry, I forgot to put that in the original post) - I put the ISP frequency to 57Khz (IIRC). No luck :-(

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

Checked my wiring :(
Checked my wiring again :(
Checked that I hadn't got the 6 pin the wrong way round :(
Checked my wiring again :(
Changed the 1K from /RESET to Vcc to 10K - not thinking it would make a difference 8)

Fantastic forum gents! Many thanks!

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

SteveN wrote:
Sorry for being dense, so the 10K fixed the problem?

Don't be dense - observe the smilies, Steve! I'd say Your advice made the difference and did the trick.

MartinM57 wrote:
Fantastic forum gents!

Yeah, we know! "Resistance is futile. You will be assimilated."

As of January 15, 2018, Site fix-up work has begun! Now do your part and report any bugs or deficiencies here

No guarantees, but if we don't report problems they won't get much of  a chance to be fixed! Details/discussions at link given just above.

 

"Some questions have no answers."[C Baird] "There comes a point where the spoon-feeding has to stop and the independent thinking has to start." [C Lawson] "There are always ways to disagree, without being disagreeable."[E Weddington] "Words represent concepts. Use the wrong words, communicate the wrong concept." [J Morin] "Persistence only goes so far if you set yourself up for failure." [Kartman]

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

Is it Friday yet?
Unfortunately not 8)