Ateml-ICE fails to enter programming mode in AS7

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

I'm trying to program an ATTiny85 via Atmel-ICE and debugWire from AS7, but I get an error:  

My devices seem to be set up correctly:

What might be causing this?  Thanks.

Last Edited: Mon. Jun 25, 2018 - 05:03 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Is there a capacitor on the reset pin?

Please check the wiring as persistent as possible.

Please upload the schematics if possible.

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

Which version of Studio do you have? We've just released 7.0.1931, https://www.avrfreaks.net/forum/atmel-studio-701931.

 

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

I'm trying to program an ATTiny85 via Atmel-ICE and debugWire from AS7

Debug wire is NOT for programming but for debugging. If you are in debug mode already then you can't program using ISP until you EXIT debug.

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

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

> Is there a capacitor on the reset pin?

 

There's a provision for a capacitor on the reset pin, put it's currently unpopulated.

 

> Please check the wiring as persistent as possible.

 

I'm not sure what you mean here, but I've verified there's 5V on the programming header, and the ICE confirms this with its green LED.

 

> Please upload the schematics if possible.

 

Below:

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

je_ruud wrote:

Which version of Studio do you have? We've just released 7.0.1931, https://www.avrfreaks.net/forum/atmel-studio-701931.

 

7.0.1645.  Is my problem an issue in the version I have?

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

js wrote:

I'm trying to program an ATTiny85 via Atmel-ICE and debugWire from AS7

Debug wire is NOT for programming but for debugging. If you are in debug mode already then you can't program using ISP until you EXIT debug.

Good point.  I was never able to enter debug mode to begin with, so I don't think I'm in it now.  I get the same error if I switch the interface back to ISP, fwiw.

Last Edited: Mon. Jun 25, 2018 - 03:10 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

 

so reliability is an option ?!

 

surprise

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
Last Edited: Mon. Jun 25, 2018 - 03:09 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

awneil wrote:

 

so reliability is an option ?!

 

surprise

 

Sub-optimal wording.  Just a reminder to myself to keep it off during debug, and to put it in if I'm seeing reliability issues.

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

Maybe I'm missing it, but I don't see a .1uf from vcc pin to gnd pin!

Has this device ever entered programming mode?

 

Jim

 

Click Link: Get Free Stock: Retire early!

share.robinhood.com/jamesc3274

 

 

 

Last Edited: Mon. Jun 25, 2018 - 06:24 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ki0bk wrote:

Maybe I'm missing it, but I don't see a .1uf from vcc pin to gnd pin!

Has this device ever entered programming mode?

I realize I'm cutting a corner here, but I'm using the regulator's output capacitor as the MCU's bypass capacitor as they're both supposed to be .1 uf and the output cap is so close to the MCU.  See below:

It may not be best practice, but I've made 160 of these things and haven't had a problem.  Plus, when I try to connect to to a known good one of these boards, I get the same error from AS.

 

This board has never entered programming mode, but the known good board did, since it's programmed and still works.  But I can't reprogram it due to this issue.  I have the same issue with ImageCraft C, so I suspect there's a problem with my Win10 system, rather than the IDE.  I've also swapped out ICE pods, to no effect.

Last Edited: Mon. Jun 25, 2018 - 08:48 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I was never able to enter debug mode to begin with, so I don't think I'm in it now

Don't need to guess, just try to start a debug session "Start debug and break". If it works than you have DW enabled, maybe accidentally.

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

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

I had missed the blue trace on the right side with VCC.

 

In the photo of the board, I'm not sure pin 1 is soldered to the pad, I see solder on the pin but can not tell if it flows to the pad from that angle.

If so that would prevent programming!

 

A little no-clean flux and some hot air will clean up those solder joints and make it look very nice.

 

 

Jim

 

Click Link: Get Free Stock: Retire early!

share.robinhood.com/jamesc3274

 

 

 

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

js wrote:

I was never able to enter debug mode to begin with, so I don't think I'm in it now

Don't need to guess, just try to start a debug session "Start debug and break". If it works than you have DW enabled, maybe accidentally.

I've tried.  I get this error:

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

ki0bk wrote:

In the photo of the board, I'm not sure pin 1 is soldered to the pad, I see solder on the pin but can not tell if it flows to the pad from that angle.

If so that would prevent programming!

I'm so ashamed!  That was it.  Thanks everyone, but especially Jim.  I normally reflow these things, but didn't want to "bother" with just this one (a new variation).  Live and learn.

 

Karl

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

I have had that happen to me with an OLDER version of the ICE that does not run well above 1MHz clock and Studio defaults to 4MHz I think.

 

Reducing the clock to 1 MHz allow me to use the ICE all day.

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

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

I received the exact same error message as shown at the top of this topic. I am trying to program a simple LED blink program on an Atmega168 20PU using ICE (for the first time). The interface is set to ISP (not the debugger). The ISP clock is 125 kHz (default) and I also tried 1 MHz. I am using Windows 10 with Studio 7.0. All connections have been triple checked. By the way, I am new to this so I hope you don't go over my head. I have not programmed a microcontroller before. If anything, this might help the problem from lautman as an independent test.

 

I have one 0.1microfarad ceramic capacitor connecting point 7 (Vcc) to ground. The tutorial I am following does not have a capacitor for the reset pin, but I added one 0.1 microfarad after reading the comments above and got the same message. Then added another to the other Vcc (20).

 

The message includes checking the target power. I am using a 9 v battery connected to a 5v regulator and checked that there is 5 v out with a multimeter.

 

I just tried "start debugging and break" and received the following message:

 

isp on Atmel-ICE (J41800092799) does not support debugging. Device is only programmed. Use Start without Debugging to avoid this message.

 

I don't know what "DW" in one of the posts above means.

 

I also tried swapping to an Atmega168A PU microcontroller.

 

I hope you can answer the original problem and mine (probably the same). My wife wants me back for the last waking hour for this weekend.

 

Erwin Carpenter

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

You cannot debug using ISP, only program. Of you want to debug, you need to change the interface to debugWire.

:: Morten

 

(yes, I work for Atmel, yes, I do this in my spare time, now stop sending PMs)

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

meolsen wrote:
You cannot debug using ISP, only program. Of you want to debug, you need to change the interface to debugWire.

 

 

In my case, I thought I was just trying to program, but probably need to debug. Could you point me to the section in the ICE users guide for debugging. I can't determine what type of cable or connection I need. Taking the USB cable straight from ICE to the breadboard does not work.

Erwin Carpenter

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

:: Morten

 

(yes, I work for Atmel, yes, I do this in my spare time, now stop sending PMs)

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

Taking the USB cable straight from ICE to the breadboard does not work.

WHAT??

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly