Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Debugging and VS2008 (Read 5662 times)
davidcoward
Junior Member
**
Offline


Posts: 56
Joined: Oct 5th, 2012
Debugging and VS2008
Oct 9th, 2012 at 6:16pm
Print Post  
I've been using the debugger with VS2008, visualisations and all. It is going well so far. There is an occasional "Visual Studio has had to close blah blah" but generally OK. 

I set a breakpoint in an interrupt sub-routine (just to see what occurs) and that broke it, which isn't surprising and a reminder that good practice is to set a flag in the ISR and then put the processing code in the main loop.

No complaints at all, though. Very smart, very clever, very useful.

  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Debugging and VS2008
Reply #1 - Oct 10th, 2012 at 10:30am
Print Post  
Great. Good to hear 2008 is working. Thanks for testing it.

I hope to nail any remaining issues over the next few weeks. I'll do some vs2008 testing at the same time.

And yes you are right, you can only set breakpoints where you can normally use Serial.print(). 

Breakpoints in interrupts and global class initializers will fail (or crash the Arduino). But it will be obvious immediately when the program runs?
« Last Edit: Oct 10th, 2012 at 10:32am by Tim@Visual Micro »  
Back to top
IP Logged
 
David Vorreiter
Newbies
*
Offline


Posts: 2
Joined: Oct 6th, 2012
Re: Debugging and VS2008
Reply #2 - Oct 22nd, 2012 at 11:56am
Print Post  
Ok I must be missing something. I have installed the plugin for debug but I cannot debug any projects. I also cannot see the same project properties window that is shown in the video tutorial. I always get the standard vs2008 project properties windows. I have already used the arduino plugin to code and compile projects successfully but I cannot see the debugging options. Do you have a link on how to setup an arduino project for debugging? Thanks
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Debugging and VS2008
Reply #3 - Oct 22nd, 2012 at 12:33pm
Print Post  
Hi, it is a bit confusing because VS has "Property Pages", "Properties Window" and "Property Manager"

We need to make sure you are using the right one. The one you want is "Property Window". 

It is normally access from the "View" menu or by pressing F4. It should be a small tool window that appears docked within the IDE and normally below the Solution Explorer. It should have a title of "Properties"

Can you see the "Property Window"?

Thanks
« Last Edit: Oct 22nd, 2012 at 12:34pm by Tim@Visual Micro »  
Back to top
IP Logged
 
David Vorreiter
Newbies
*
Offline


Posts: 2
Joined: Oct 6th, 2012
Re: Debugging and VS2008
Reply #4 - Oct 23rd, 2012 at 11:13am
Print Post  
OK thanks for that. 

All is well now with the debugger except when I set the debugger option "Enable Break/Pause" to true. 

When I do this and recompile I get the following error messages. Obviously something about "avr-objcopy".

What causes this and what is the trick to setup step by step debugging or break and pause debugging?


Compiling 'Blink' for 'Arduino Mega 2560 or Mega ADK'
Binary sketch size: 1650 bytes (of a 258048 byte maximum) (0.256 secs)
Compiling debug version of 'Blink' for 'Arduino Mega 2560 or Mega ADK'
Blink.cpp.o : In function `loop'
Blink.cpp : breakWait(unsigned char)'
avr-objcopy* : No such file
avr-objcopy* : No such file
Couldn't determine program size: D:\arduino-1.0.1\hardware\tools\avr\bin\avr-size: 'C:\Users\David\AppData\Local\VMicro\Arduino\Builds\Blink\mega2560\Blink.hex': No such file
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Debugging and VS2008
Reply #5 - Oct 23rd, 2012 at 1:01pm
Print Post  
Yes got a but fix due over the next few days for that. It crept into the last version. 

From memory, I think that problem happens for breakpoints that do not have WhenHit" messages with variables such as 

Hello World i={i}

or
{i}{someVar}{anotherVar}

etc


« Last Edit: Oct 23rd, 2012 at 4:17pm by Tim@Visual Micro »  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint