Failed to open com

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

I am getting a failed to open \\.\com18 Error 0x2.

 

My setup is my own board design, Atmel 6.2 sp2, a pololu avr programmer on a W7 laptop plugged into a docking station.

 

I can connect to the board & I can program and verify the code.

 

Then when I want to begin debugging and go to the tools selection drop down at the top of Atmel Studio, 'Attach to Target' is grayed out.  If I click on Start Debugging and Break, it builds the program without error but then gets the failure to open com error.

 

Why is the 'Attach to Target" grayed out?

 

Why do I get a com error when I can program the device successfully?

 

Thanks.

This topic has a solution.

Last Edited: Tue. Jul 28, 2015 - 05:21 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You have a programmer, not a debugger so that's why you are getting the error

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

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

Doh!!!!!

 

Thanks. 

 

Can I install gdb with atmel Studio 6.2 and debug that way?  Or do I need another piece of hardware in order to use it?

 

thanks again.

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

Or do I need another piece of hardware in order to use it?

YOu need any of the following to perform debugging:

 

Dragon)old)

JTAG-ICEMKII(old)

JTAGICE3

Atmel-ICE(best bet)

 

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jgmdesign wrote:
YOu need any of the following to perform debugging:

 

Dragon)old)

JTAG-ICEMKII(old)

JTAGICE3

Atmel-ICE(best bet)

Or a board with a built-in debug probe - such as the Xplained Pro or Xplained Mini

 

 

As this is not a device-specific section of the forum, and no specific device has been mentioned, we could add that 3rd-party debug probes are available (at least for the ARM-based parts); eg,

 

  • Segger J-Link (works with Atmel Studio & 3rd-party software);
  • Keil uLink (only works with Keil).

 

Note that the Atmel-ICE is just a badged Segger J-Link.

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

Thanks a lot for taking the time to respond and supplying more info than I requested.