VS Arduino
Visual Micro >> Microchip Studio (Atmel Studio 7) >> VM debugger not operating as expected
https://www.visualmicro.com/forums/YaBB.pl?num=1524086756

Message started by perigalacticon on Apr 18th, 2018 at 9:25pm

Title: VM debugger not operating as expected
Post by perigalacticon on Apr 18th, 2018 at 9:25pm
Hello today I have a problem which is the VM debugger does not seem to work in my sketch.  I have 5 breakpoints with the continue execution option disabled and print statements in them.  I am not seeing serial print output in the serial monitor even from my own print statements in the code from the main loop however I do see them from the setup section.  There is no output from the debugger in the Output window.  There is no difference if VM debugging is selected or not.  I've never had this happen before.  After a few seconds the sketch (a FastLED animation on esp8266) pauses and a string is printed to the serial monitor about every second like "VMDPE_3:2:66042:34887:31155_VMDPE" which appears to be the millis printout.  I don't have any special options selected in the project properties that I can see as far as debugging.  Can someone help me fix this?

Title: Re: VM debugger not operating as expected
Post by Visual Micro on Apr 18th, 2018 at 9:31pm
It could be few things.

When you use serial.print() do you terminate your printing with a linefeed? println()?

Is the tool bar set to Release or Debug?

Do you prints work okay when debugging is OFF?


Title: Re: VM debugger not operating as expected
Post by perigalacticon on Apr 18th, 2018 at 9:45pm
Thanks, it was the Debug/Release was set to Release.  I haven't used that option before, what does it do exactly?

Title: Re: VM debugger not operating as expected
Post by Visual Micro on Apr 18th, 2018 at 10:19pm
If you upload when set to Debug then serial debugging is used.

If you upload when set to Release then normal arduino without debug is used.

If you upload using Debug then switch to Release without uploading again then visual micro will not start debug when the serial monitor opens yet the arduino is still sending debug messages and runs any debug commands on the chip.  Remember that the IDE and the Arduino are two separate entities and don't really know about each other.


Title: Re: VM debugger not operating as expected
Post by Visual Micro on Apr 19th, 2018 at 2:50pm
ps/tips:

Make sure you open the solution (sln) not .ino file when you re-open projects.

Opening the Solution will retain your current settings and restore window layout etc.

If you don't see your "Solution" on the "File>Recent" menu, then click the Solution to activate it in the explorer then click "File>Save As". Saving the solution (even with same name) will force it onto the Recent menu.

When your solution is on the Recent menu you will have no need to use "File>Open Arduino" project, which is normally just used the first time you open an existing Arduino project in VS.

VS Arduino » Powered by YaBB 2.6.12!
YaBB Forum Software © 2000-2024. All Rights Reserved.