Failed to enter programming mode. ispEnterProgMode: Error status received: Got 0xc0, expected 0x00 (Command has failed to execute on the tool) Unable to enter programming mode.

Go To Last Post
81 posts / 0 new

Pages

Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello,

 

I hope you guys can help.  I have both an Atmega8 and an ATTiny441 that will not enter programming mode.  I keep getting "Error status received: Got 0xc0, expected 0x00" message. I have triple check all the connections, ohm'd out the wiring to the uC. I was using a USBASP, so I figured maybe that was the Issue.  I purchased an Atmel-ICE and am still getting the same thing.  The ATtiny is using its internal osc while the ATMEGA 8 has an external 8MHz crystal.

 

I have changed the ATTiny thinking may I did something to it with the USBASP programmer, but it does not appear that is the case.  I am using Atmel Studio 7 and the Atmel-Ice.  I have tried going directly into device programming mode.  It will read the voltage, but will NOT read the device ID.  I have tried bringing the clock all the down to 8khz up to 1 Mhz, same error.

 

Does anyone have any idea where I can look?

 

Thanks

 

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

Does anyone have any idea where I can look?

Yes; your schematic.   Show it to us.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

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

125KHz clock will work at all times IF YOU HAVE A CLOCK! If the chip was fused for external oscillator then you have no clock very likely.

 

It is also possible that the DW fuse has been turned on.

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

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

"Got 0xc0 ..." should proof, that somethings happening (out there), shouldn't it.

 

But to which command or parameter is ist the reply?

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

Hello

 

I attached the pertinent section of the schematic, I did add a 10k resistor from the reset to VCC to see if that would help.  It did not.  

 

As to the fuses being changed, On the ATTiny441, I replaced the chip and have not been able to connect to configure anything, so the fuses should be in default conditions.

 

I get the error when the device ID is attempting to be read.  I have tried using the "Device Programming" window in Atmel Studio, and just read "Device Signature" and receive the error message.

 

I am using the chip internal clock, and have tried setting the ISP clock 8 Khz, 125 Khz, 250Khz, 1 mHz.  With all settings, I receive the same message.

 

Attachment(s): 

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

How is the circuit powered when programming?   What is the VCC level?

 

Jim

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274

 

 

 

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

I attached the pertinent section of the schematic

You have no bypass capacitors...all of your power pins should have them, otherwise expect trouble. 

 

How do you expect your LED's to light since they are installed backwards???

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

Last Edited: Fri. Apr 27, 2018 - 03:50 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Are pins 9 and 10 both SCK ?  Is this the exact schematic of the prototype that you are using, or is it a schematic from the web of a "known-good" design?

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

As Simonetta pointed out...maybe sck issue...datasheet shows PA4 to be used

 

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

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

Simonetta wrote:
Are pins 9 and 10 both SCK ?

Good catch!  Looks like pin 9 is what the OP wants...

 

 

Jim

 

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274

 

 

 

Last Edited: Fri. Apr 27, 2018 - 04:25 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello,

 

OK, Simonetta was on to something.  I pulled pin 10 and shorted pin 9 to the pad.  I am able to connect... well sort of.  If I just click the read signature button it will read.  If I try anything else - Erase Chip, Program, Read Fuses, Device Information.  I get 

"Unexpected signature 0x00000102 (expected 0x001e9215).

Unable to enter programming mode. Verify device selection, interface settings, target power, security bit, and connections to the target device."  Once that happens I can even "read signature"  I have to select "Apply" on the Interface select, then I can read the signature, but again if I try anything else....

 

VCC on the chip is 5volts regulated with an LM317.  I add an additional decoupling cap (1uf) right on the VCC of the chip.  No Change.

 

Rich

 

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

Could you have the wrong chip # selected?  Double check!

also , tek a look:

 

https://www.avrfreaks.net/forum/191342-error-unexpected-signature-0x00000102-expected-0x001e9502-modulename-tcf-tcf-command

 

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

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

Hello everyone,

 

I'm going to piggy-back on this post because it is fairly recent and very close to my problem and hardware used. For some background, I am completely new to Atmel/AVR ucontrollers but experienced with 8 bit PICs.

 

I am attempting to re-program some ATTINY24's using the Atmel ICE and Atmel Studio 7. An important detail here: I emphasize that I am re-programming this device. My company used to assemble circuit boards for another company, and long-story-short, that company decided to get out of the business and we have come to own their assets, and intend to continue building the product. This includes a bunch of controller boards without microcontrollers installed, and they did not build a programming header onto them, as they had them programmed from the factory. There are two versions of firmware for different versions of the product and we have a whole bunch of these ATTINYs programmed with one version of the firmware, but we are wanting to sell (and indeed have already taken orders for) the other version. 

 

SO, I got my hands on this SOIC to DIP adapter by Logical Systems. Pretty neat little adapter. I have wired up a little breadboard as shown in the diagram below. Also see picture of setup.

 

I am getting the same error as OP "Failed to enter programming mode. ispEnterProgMode: Error status received: Got 0xc0, expected 0x00 (Command has failed to execute on the tool)  Unable to enter programming mode. Verify device selection, interface settings, target power, security bit, and connections to the target device."

 

This happens any time I try to read device information, look at fuses, etc etc. It also won't read voltage level except when I attempt to read device info, it will show the voltage in the little box. As can be seen from below picture I am powering this from a bench psu at 5V. 

 

 

 

So I have two questions:

1) Do I need a resistor from Vcc to the RESET pin? I have tried once with it and nothing changed.

 

2) Could the firmware already loaded on the device have fuses set which would prevent me from erasing, reading, programming, etc? Is there a way around that?

 

EDIT: forgot to mention, the controller board this is supposed to go on does not have a discrete crystal/oscillator, so I don't think it is set up to use external clock. I've read that can mess things up too.

 

Thanks in advance for any help!

 

-H

 

 

 

Last Edited: Thu. Jun 28, 2018 - 04:26 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

First step is to read the device signature, once that is successful the rest is easy!

The hook up looks ok, you may need to inject a clock signal into the xtal1 pin, 1MHz should work, an Arduino Uno works well for this, but any source with ttl level clock signal will do.

 

Jim

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274

 

 

 

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

Looking at the picture, your 2x3 header may be short out by the BB?

Use a meter to check for shorts between 1-2, 3-4, 5-6.

 

 

Jim

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274

 

 

 

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

OMGosh. Yeah duh I've got my flippin 2x3 header shorting together.....standby I will fix and update if all is good.

 

Thanks for pointing that out!

 

Sometimes it's just a silly mistake....

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

Pictures really help us to help you! 

We all have done silly things like that in the heat of the battle! 

 

Glad we could help.

 

Jim

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274

 

 

 

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

henmill wrote:
...  as they had them [tiny24 in SOIC] programmed from the factory.
fyi

AVR8 on Microchip Direct

by sydalmighty

https://www.avrfreaks.net/forum/avr8-microchip-direct

 

"Dare to be naïve." - Buckminster Fuller

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

>gchapman:

Good point, I could certainly have microchip program new ones for me. I will be re-spinning this board in the near future however, and will be adding a programming header. Just trying to use up as much of the sunk cost that I can. If I end up unable to make this work, then I may consider purchasing new pre-programmed chips.

 

 

Regarding my efforts to program...So I fixed up my arrangement and was ready to try it, and *poof* my ICE no longer shows up in the tool drop down in Studio. What the heck. It remained in device manager under Atmel but would not show up in Studio. So I've been searching around for solutions and I am certainly not the first to run into this. Have uninstalled the old driver, rebooted etc, and now windows cannot find drivers! UGH. Some people found that the usb.inf file was missing in their windows/inf directory, but mine is still present. Hmmmmm

 

This is awfully frustrating. I don't want to steer the conversation away from the original topic of this thread, but if any of y'all have suggestions on this separate issue, fire away please.

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

Someone makes a kind of "fake chip" that has a 3x2 ISP header that plugs into "straddle the divide" down the middle of a breadboard and deliver 3 signals to either side. May be worth a search though I'm not sure what the Google search terms would actually be?

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

henmill wrote:
Have uninstalled the old driver, rebooted etc, and now windows cannot find drivers! UGH.

http://www.microchip.com/mplab/avr-support/atmel-studio-7

http://www.microchip.com/mymicrochip/filehandler.aspx?ddocname=en594569

11.4 Driver and USB Issues

11.4.1 How do I get my Tool to be recognized by Atmel Studio?

This should happen automatically, but sometimes the Windows driver does not recognize the tool correctly. To correct this, you have to check that the tool is listed under the Atmel node in the device manager in Windows. If your tool is not listed, try to find it under Unknown devices. If it is located there, try to reinstall the driver by double-clicking the tool, click the Driver tab and choose Update Driver. Let Windows search for the driver. The driver should be reinstalled and the tool should be displayed under Atmel. Now, the tool should be usable from Atmel Studio.

 

"Dare to be naïve." - Buckminster Fuller

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

Thanks for was only aware of Proto Advantage.

Proto Advantage - SOIC-14 Socket to DIP-14 Adapter (150 mil body, 1.27 mm pitch)

http://www.proto-advantage.com/store/product_info.php?products_id=3600009

 

"Dare to be naïve." - Buckminster Fuller

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

UPDATE: this is still regarding getting my ICE working again. Sorry to be diverging from original topic further but figured I'd keep you guys updated. I promise I will come back once I get a successful program!

 

I've been able to re-install the driver for the Atmel ICE so that it shows up again properly in device manager. So, after uninstalling the drivers windows couldn't reinstall the drivers on its own. It was listed under Other Devices in the device manager as Atmel-ICE Data Gateway with the little exclamation symbol indicating there was a problem. I dug around and found promising files under C:\Program Files (x86)\Atmel\Studio\Drivers\inf\winusb\atmel_winusb. I then went back to device manager and updated driver and pointed to the file atmel_winusb.inf and lo and behold windows was happy again and it looked like a properly functioning device in device manager.

 

BUT: I still can't see the tool in Studio. I think I might try uninstalling/reinstalling the software.

 

There is a thread relevant to this issue here: https://www.avrfreaks.net/forum/...

 

Feel free to offer any suggestions. 

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

clawson wrote:
Someone makes a kind of "fake chip" that has a 3x2 ISP header that plugs into "straddle the divide" down the middle of a breadboard and deliver 3 signals to either side.

Something like this:

Adafruit 6-pin AVR ISP Breadboard Adapter Mini Kit

https://www.adafruit.com/product/1465

 

 

Search term: "isp header to breadboard adaptor"

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...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

henmill wrote:
I think I might try uninstalling/reinstalling the software.
Atmel Studio 7 clean, summary :

https://www.avrfreaks.net/forum/atmega328p-running-old-code#comment-2495961

henmill wrote:
There is a thread relevant to this issue here: ...
fyi, Atmel Studio's USB driver changed from Jungo to Microsoft WinUSB in 7.0.1416 & subsequent for all that's pre-Atmel-ICE.

 

"Dare to be naïve." - Buckminster Fuller

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

Good morning and Happy Friday!

 

So I left off yesterday by trying a software "repair". It took a heck of a long time to complete, but once it did successfully, Studio recognized the ICE again. Yay!

 

But I'm still getting the same error message that started this thread. Failed to enter programming mode. However, now it's saying: "Failed to enter programming mode. ispEnterProgMode: Error status received: Got 0xcc, expected 0x00 (Unknown status message)"

It's seeing CC instead of C0 as before....not sure it means anything besides junk though.

 

Here's a screenshot of my interface settings:

 

I will probably pick up that little adafruit board that awneil linked. For now this is my header:

 

I rotated the 2x3 header 180 degrees cause it made wiring a little neater. I'm (reasonably) certain I'm getting good connections and my wiring is correct. So this brings me back to a thought I had yesterday. Are there settings that could have been programmed in that would prevent easily reprogramming the device?

 

Thanks for any thoughts,

 

-H

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

henmill wrote:
Are there settings that could have been programmed in that would prevent easily reprogramming the device?

Well, yes -- the RSTDISBL fuse.  And/or SPIEN fuse? 

 

It could also be in debugWire mode.  I'd think you could use your ICE to fuss with that.

 

As you have "a number" of these chips, perhaps it would be well worth it to purchase a few new/virgin of the same model (which might be hard to do because only '24A in distribution?) and practice ISP on those.

 

 

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

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

Yeah I went ahead and ordered a small quantity of fresh chips. DigiKey (and other places) had them in stock. Part number is ATTINY24V-10SSU. 

 

What is the difference between my part and -24A part?

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

henmill wrote:
What is the difference between my part and -24A part?

AVR526: Migrating from ATtiny24/44/84 to

ATtiny24A/44A/84A

http://ww1.microchip.com/downloa...

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

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

EUREKA!

 

So I have the C source file for this firmware and was looking through it for any clues, and there is a note: "// ATTINY24V 5KHZ ISP frequency (5.050kHz)"

 

I tried setting the ISP clock to that frequency, but it wouldn't let me. But set it to 8kHz and voila! I can read the device and have successfully programmed one! yes

 

Now on to test on an actual board and I might be seeing light at the end of this short, but winding tunnel.

 

Thank you all for your attentiveness and help,

 

EDIT: thanks for the link theusch

 

-H

Last Edited: Fri. Jun 29, 2018 - 03:08 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

In the pic, the power supply is not connected now, the chip needs power before it can be programmed.

In post 26 you show the ICE tool, try reading the device signature, once you can do that then you can program it, until then it will not work.

 

Jim

 

 

Edit: never mind, you got it work! smiley

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274

 

 

 

Last Edited: Fri. Jun 29, 2018 - 03:11 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

???  Does that app run at e.g. 32kHz?  Strange.

 

[edit]  Or a high CLKPR value?  That can be side-stepped by holding the AVR in reset at poweron.

 

Still strange to many of us to run a main clock that slowly.  A guess is power consumption.  But run at a reasonable rate, do your work "fast", then take a siesta and you'll probably use less energy.

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

Last Edited: Fri. Jun 29, 2018 - 03:11 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

>ki0bk: Yes I'm powering the BB from bench power supply, just wasn't connected in that pic.

 

>theusch: Yeah I guess so. This board mostly just strobes LEDs so maybe it was easier to get longer delay times this way? I find it strange to run that "slow" as well.

EDIT: the fuse LOW.SUT_CKSEL is selected "WD. Osc. 128kHz; Start-up time PWRDWN/RESET: 6 CK/14CK + 0ms"

From my limited understanding I think this means it is using the internal 128kHz oscillator as the system clock?

Last Edited: Fri. Jun 29, 2018 - 03:19 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

henmill wrote:
From my limited understanding I think this means it is using the internal 128kHz oscillator as the system clock?

That's what I would think.  Look in the source for references to CLKPR as well.

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

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

henmill wrote:
This board mostly just strobes LEDs so maybe it was easier to get longer delay times this way?

You'll probably not want to spend the time to re-write this "legacy" app.  But just for fun, let's explore my premise.

 

LOL -- first, if the app "strobes LEDs" then the power consumption of the AVR probably isn't even significant.

 

The datasheet chart tells us that with the 128kHz oscillator at 5V the draw is 100uA.

 

Let's say the app has 50% processor utilization at 128kHz.  YMMV.

 

Now, if we run at 8MHz/5V the draw is a bit less than 5mA.  50x more than at 128kHz, so OBVIOUSLY the slower clock is better.  But wait -- there's more...

 

8MHz is about 64x 128kHz.  So we can get 64x more work done.  Actually, since the processor has 50% load, we can do the needed work in about 1% of the time. 

 

So over a time period, we use 1% of 5000uA or 50uA.  Then the rest of the time we use a sleep mode.  Simplest is Idle at about 20uA for 99% of the time.  Very roughly without using my power-budget spreadsheet that would be an AVR draw of about 25uA -- less than the 100uA with the slower oscillator.

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

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

henmill wrote:
My company used to assemble circuit boards for another company, and long-story-short, that company decided to get out of the business and we have come to own their assets, and intend to continue building the product.
Will the production operators be using Atmel-ICE?

Reasons :

  • Atmel-ICE 50mil pitch target connectors whereas 100mil pitch is common with third party AVR ISP
  • Atmel-ICE in the lab for engineers and technicians (it's a debugger)

​If it's Atmel-ICE on production then

Microchip Technology Inc

Microchip Technology

Application Notes

AN2466 Using Atmel-ICE for AVR® Programming In Mass Production

http://www.microchip.com//wwwAppNotes/AppNotes.aspx?appnote=en599598

...

The application note introduces Atmel-ICE setup, driver installation, user guide of the Atmel Studio command line utility (atprogram.exe), and provide a PC programming tool project written in C#. The Visual C# example project can be downloaded along with this application note and run with the ATmega328PB Xplained Mini kit.

...

via https://www.microchip.com/wwwproducts/en/ATtiny24

 


Pololu USB AVR Programmer v2.1

https://www.pololu.com/product/3172

 

Edit: typo

 

"Dare to be naïve." - Buckminster Fuller

Last Edited: Fri. Jun 29, 2018 - 05:23 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Alright guys, back to issues dealing with the ICE. It has disappeared once again from studio. What gives? Has anyone else had issues like this with the Atmel ICE? It seems horribly inconsistent. It even came with a bad USB cable...

 

I tried communicating with my device via atprogram as described here: https://www.microchip.com/webdoc...

 

I get this error:

 

I don't know if anything I have done triggered the loss of recognition in Studio. Could antivirus be messing with files??

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

henmill wrote:
What gives?
What's the Windows major and minor version?

Reason: Windows 10 version 1803 and recent threads on Atmel Studio 7 issues (two IIRC) were resolved by rolling back to Windows 10 version 1709.

henmill wrote:
Could antivirus be messing with files??
Yes though I don't recall the specifics on solving that problem.

Microsoft anti-virus might be more compatible with Atmel Studio.

 

"Dare to be naïve." - Buckminster Fuller

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

Running Windows 7 Home Premium SP1

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

henmill wrote:

Could antivirus be messing with files??

Born: Windows Defender isn’t getting updates @ AskWoody

by woody

June 29th, 2018

https://www.askwoody.com/2018/born-windows-defender-isnt-getting-updates/

Not sure of the cause, but it looks like Windows Defender for Win7 is broken.

... [URL]

 

"Dare to be naïve." - Buckminster Fuller

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

Hello everyone, back to work for a couple days. Here is a quick update on where I stand.

 

Came back to work with the same scenario: Atmel studio does not recognize any available tools (including simulator). I performed another "repair" and that fixed it again. I have since programmed about 60 parts successfully, then was interrupted programming with an error and all of a sudden -- no tools available again. Curious. I closed the error messages before thinking to capture them for you unfortunately.

 

I was starting to think maybe as long as I don't mess with any other USB devices maybe I'd be ok, but no, that wasn't it. I didn't remove or plug in anything this morning during my programming session.

 

Some more details to consider: I use Avast antivirus free and Windows 7 Home Premium (as mentioned above). Interestingly, the Atmel ICE doesn't show up in device manager except as Unknown Device. It was this way too before it quit showing up in Studio this morning. I'm sure another installation repair will get me going again, but for how long? There is clearly some strange business going on behind the scenes and I'd like something other than a band-aid. Perhaps its time for me to piggy back a different thread to try to drill down on this issue.

 

Thank you all for all the insight.

 

-H

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

henmill wrote:
... then was interrupted programming with an error and all of a sudden -- no tools available again. Curious. I closed the error messages before thinking to capture them for you unfortunately.
atbackend.exe log might have some information in it (or another log?)

FAQ: Obtaining detailed Backend Agent log from Atmel Studio

https://microchip.secure.force.com/microchipknowledge/articles/en_US/FAQ/Obtaining-detailed-Backend-Agent-log-from-Atmel-Studio/

FAQ: My installation fails. Where can I get the log files for the installation?

https://microchip.secure.force.com/microchipknowledge/articles/en_US/FAQ/My-Atmel-Studio-7-installation-fails-where-will-I-get-the-log-files-for-installation/

 

"Dare to be naïve." - Buckminster Fuller

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

Thanks gchapman, you have provided me with lots of good info throughout this thread!

 

I did another installation repair and was able to continue programming. So I started looking through the logs and without knowing really what I'm looking at, I think I found the section where things went awry:

 

12:06:35.714: 12 06 35 714: msg recv(8):C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32
12:06:35.714: 12 06 35 714: pro JtagIce3 <<< 06 00 00 02 00
12:06:35.714: 12 06 35 714: dap rddi_CMSIS_DAP_Commands nCmds=1 cmdSize0=14 msg=80 11 00 0A 0E 00 BA 14 11 06 00 00 02 00 
12:06:35.715: 12 06 35 715: dap DAP_Commands replySize0=512 msg=80 01 00 07 0E ...
12:06:35.715: 12 06 35 715: dap rddi_CMSIS_DAP_Commands nCmds=1 cmdSize0=1 msg=81 
12:06:35.715: 12 06 35 715: dap DAP_Commands replySize0=512 msg=81 11 00 06 0E ...
12:06:35.715: 12 06 35 715: pro JtagIce3 >>> 06 00
12:06:35.715: 12 06 35 715: pro JtagIce3 <<< 14 01 00 20
12:06:35.715: 12 06 35 715: dap rddi_CMSIS_DAP_Commands nCmds=1 cmdSize0=13 msg=80 11 00 09 0E 00 BB 14 11 14 01 00 20 
12:06:35.716: 12 06 35 716: dap DAP_Commands replySize0=512 msg=80 01 00 06 0E ...
12:06:35.716: 12 06 35 716: dap rddi_CMSIS_DAP_Commands nCmds=1 cmdSize0=1 msg=81 
12:06:36.761: ChannelTerminator2  with exception Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host.   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.IO.Stream.ReadByte()
   at Atmel.VsIde.AvrStudio.Services.TargetService.TCF.Core.ChannelTCP.Get()
   at Atmel.VsIde.AvrStudio.Services.TargetService.TCF.Core.StreamChannel.Read()
   at Atmel.VsIde.AvrStudio.Services.TargetService.TCF.Core.AbstractChannel.InputThread.Run()
12:06:36.762: 12:06:36: [WARNING] TCF command: Modules:verifyMemory receiving failed, channel is closed
12:06:36.775: Modules:verifyMemory 1063.0608 msecs
12:06:36.777: 12:06:36: [INFO] TCF command: Modules:remove sending failed. Backend may have terminated
12:06:36.777: Modules:remove 0 msecs
12:06:36.777: 12:06:36: [ERROR] , ModuleName: Modules:remove:Timed Out
12:06:36.781: RemovePeer was called on unregistered 
12:06:36.786: 12:06:36: [ERROR] Command [C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32] aborted, ModuleName: Command [C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32] aborted
12:06:36.805: 12:06:36: [WARNING] The back end process exited with code 0
12:06:50.378: 12:06:36: [ERROR] Command [C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32] aborted, ModuleName: Command [C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32] aborted
12:06:50.390: 12:06:36: [ERROR] Command [C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32] aborted, ModuleName: Command [C 2751 Modules verifyMemory "Module_131" "Mem_prog_793" 1268 32] aborted
12:06:50.392: 12:06:50: [INFO] TCF command: Device:endSession sending failed. Backend may have terminated
12:06:50.393: Device:endSession 1.0001 msecs
12:06:50.393: 12:06:50: [ERROR] , ModuleName: TCF (Device:endSession:Timed Out)
12:06:50.393: 12:06:50: [ERROR] Error occured when trying to end programming session, see output/log for details.
12:07:02.273: 12:07:02: [INFO] TCF command: Tool:tearDownTool sending failed. Backend may have terminated
12:07:02.273: Tool:tearDownTool 0 msecs
12:07:02.273: 12:07:02: [ERROR] , ModuleName: TCF (Tool:tearDownTool:Timed Out)

 

Definitely appears to be related to a problem with atbackend.exe.  Also note in post #37 when I was trying to manually communicate with the tool I got an error from the same, atbackend.exe. saying I was missing a dll. Right now, the tools are available and atbackend.exe is easy to spot running in task manager. Whenever it breaks again, I will try manually starting the process and see what happens....

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

Dear All,

I am facing the same issue, checked all the discussion above but the problem is not solving.

 

I am using ATTINY4313 (Ref Design attached), ATMEL ICE, and ATMEL STUDIO 7.

 

Initially, In the device programming page i got couple of times the device signature read (0x1E920D) after trying switching off, on the device.

But I am unable to get the device signature read again and hence cannot program the device.

 

 

Following error i am getting

 

 

,

 

Since then I tried following things

 

1) IC Replaced (Worked couple of times the device signature but after lot of struggle)

2) Not getting into DebugWire mode as well

3) Checked Supply

4) Checked Reset

5) Checked the Hardware Connections for SPI (Disconnected all other activities on SPI)

6) Checked shorts on pins

 

Let me know what I can try else using ATMEL ICE or on hardware.

 

Thanks in advance 

Ajay Tiwari

 

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

Why are you using such a low ISP frequency? Use 250KHz or 125KHz clock. Did you try to change any fuses before this happened?

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

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

Hey everybody, im new in this forum this is my first post. I am from germany, so may my english becomes a little weired sometimes :D

 

I have the same issue here, i am searching for a solution a hole while and couldnt find anything. Some weekes ago i played around with an ATMEGA32 on a breadboard, connectet via JTAGICE3. I accidently shortet Vcc to Gnd and then the problem showed up for the first time. I wanted to write some changes in the code to the flash but the "failed to enter programming mode....got 0xc0,expected 0x00". I thougt first that i had broke down my ICE3, but today i wanted to give it another try, but i got the same errormessage. So i changed the device to a arduino nano. But i get the same error message. So i grabed my old STK500 out of my "Bastelkiste" and put the MEGA32 in it, but i stil get this error message. I tried several devices (MEGA2560 arduino, TINY13, MEGA32) but nothing changes.

 

If i try to read out the device id (in ATMEL STUDIO 7) i get the same errormessage, but the voltage is read out shows some numbers. But if i try to read out the voltage only it says "failed to read voltage". Again no difference between STK500 and ICE3 and several µC....

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

Guess the solution to your problems may be disabling debugWire Mode. At least it is worth a shot.

 

To disable debugWire, try this:

- open or create a project in Atmel Studio

- set up your device in the project menu, confirming debugWire Mode

- Enter a debug session by attaching to Target: Debug ---> Attach to Target

- Close DebugWire Session, not by pressing "Stop Debugging" but choosing Debug ---> Disable Debug Wire and close

 

Hope this will help. I use the ATmega328PB Xplained mini an had the same error message.

 

Last Edited: Tue. Nov 27, 2018 - 03:27 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Guys,

I am battling sort of a similar problem, think it relates to this topic.

Using Studio 7.0.1931  with ISP MK2 on a ATMega1281 chip

 

every now and then when I am having the programmer connected for a long time I do get the screen like this:

It then will no longer program my board. The board is known good with respect to power supply and other things, and in general programming is not a problem at all.

So I am updating some code program the device and it restarts with the new code loaded.

do updates again... progeam again... not problem

Then when I wait longer do more changes and then after a while program again I get the message above.

Sometimes all I need to do is disconnect the programmer and target re-connect and I am fine again ( it never seems to restore by itself)

But sometimes even that does not help and I need to shut down the pc and restart it again.

Closing and restarting AS7 does not work either, really need to restart the machine in order to have it working again.

Now lately even these things no longer seemed to be helping and all I could do was hope that at some point things started working again which it sometimes magically did after a couple of restarts.

 

The strange thing that happened today is that I was working on this Mega1281 project and that stopped working again. At that point a got a notice that I needed to re program another board on another project.

A bit pissed I opened the standalone programming interface (Tools -> device programming) selected the other processor and hex file. and low and behold programming without a problem.

Changed the processor back to the mega1281 and project hex file in that programming window and now that also worked again mysteriously. 

even the normal way I program ( hit the green play button that starts a build action and when successful also programs the device) all of the sudden is working normally again.

 

what could be wrong? as this is getting a bit annoying.

 

edit, forgot a small thing that I also noticed.

When programming fails, from that moment on the green 'usb' led on the ISP is flickering long on period and then a flash off.

That in this case also changed back to 'normal' were the LED is permanently on again.

 

Last Edited: Mon. Dec 10, 2018 - 04:41 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

meslomp wrote:
Using Studio 7.0.1931  with ISP MK2 on a ATMega1281 chip
... on what Windows? (version, current update's identifier)

Reason :

Sometimes Atmel Studio malfunctions due to a Windows update.

 

Are the Wndows drivers up to date and are OEM instead of Microsoft?

Reason :

Windows is dependent on drivers; OEM drivers are of better quality.

meslomp wrote:
what could be wrong?
After "Failed to enter programming mode.", does the AVRISP mkII correctly appear in Device Manager?

Reason :

WinUSB underwent major updates in Windows 10 though later builds seem to be stable.

 


https://www.avrfreaks.net/forum/studio6-slower-compile-time?page=2#comment-2594311

 

"Dare to be naïve." - Buckminster Fuller

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

Using Win7 64 bit.

 

Will have to check the ISP state in the device manager when it fails again. I think I did that once and then I did not see anything strange, but will double check when it occurs again.

 

The only thing I find strange in that perspsective is that if the driver has failed, I would not expect that just selecting another chip and program that would solve that.

writing this I will also see what happens if when it fails I take a second board with the same MCU and see if I then can program that, or that I indeed need to actually change the chip I want to program for things to work again.

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

I get same error. My circuit start working with basic schema:

All components I used as SMD (1206). No need to add extra capacitpr between RST ang GND (100nF). I will tested with capacitor but working without it.

Power supply: 5V (not from USB), Atmel-ICE read 5.2V

In some circuits in web there some extra resistor on crystal (between XLAT1 and XLAT2 chip pins) -> my circuit working without it.

I tested on: ATmega16, ATmega8, ATtiny13A, Atmega328P (on Arduino-UNO R3 board) all working good (Atmel_ICE read device without any errors).

ISP clock: 125 kHz (as standart set)

 

I get such error on board (my own design) where I use not SMD component (resistors and capacitors). Don't know difference. Can't figure out why)

Last Edited: Wed. Jan 2, 2019 - 02:21 PM

Pages