Welcome, Guest. Please Login or Register
Arduino IDE for Visual Studio
When Logging a Support Issue in the Forum, please ensure you have also:-
  • Enabled vMicro > Compiler > Show Build Properties and Verbose
  • 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
  HomeSearch Tutorials & Wiki visualmicro.com LoginHelpRegister  
Page Index Toggle Pages: 1
Send Topic Print
Debugger not working in library cloned to project (Read 283 times)
Junior Member

Posts: 16
Debugger not working in library cloned to project
Apr 10th, 2021 at 10:59pm
I'm trying to debug an Adafruit library using the serial debugger find that breakpoints/tracepoints work fin in my loop{} but not in the in the library.  I'm using an ESP32 board.  The library is not mine so I cloned it to the project.  By using Serial.print statements, I know I'm executing code in the library.  However, the breakpoint set just after the Serial.print statement does not work.  The optimization is set for "no project + library optimization".

In the screen shot attached notice there are 2 breakpoints set, one in loop{} and the other in Adafruit_seesaw.cpp.  I put a Serial.print statement just before the breakpoint in the Adafruit_seesaw library.  The output window shows that the Serial.print statement in the library is working and the breakpoint in loop{} is working.  The screenshot shows that execution has paused, and it is paused at line 52 in loop{}.   

Soooooo, I know serial debug is working as expected in loop{} but not in the library code that I know is being executed.  I found a post about someone having similar issues with Arduino Mega....and the solution was to use hardware debugging.  I'm using ESP32 so not sure what to do.  I'd prefer to use serial debug if possible.  Thanks.....jimf
Back to top

Please Register or Login to the Forum to see File Attachments
IP Logged
Simon@Visual Micro

Posts: 1014
Re: Debugger not working in library cloned to project
Reply #1 - Apr 12th, 2021 at 9:46am
Thanks for the report.

Can you confirm the library has been cloned into your solution as a Shared Project?

Just to note the optimization changes should not be required for the Serial Debugger.
Back to top
IP Logged
Page Index Toggle Pages: 1
Send Topic Print