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
Hot Topic (More than 8 Replies) EXCEPTION DURING DEBUG (Read 2815 times)
Marco (Italy)
Full Member
***
Offline


Posts: 165
Joined: Jul 12th, 2019
EXCEPTION DURING DEBUG
Aug 21st, 2019 at 2:46pm
Print Post  
Hi !
I have see this error that block in an infinite loop my debugger. Can you tell me something about this. 
in attach a pic of my error.
 
This error occours inside the ethernet.h arduino library
Best
Marco
  

Please Register or Login to the Forum to see File Attachments
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: EXCEPTION DURING DEBUG
Reply #1 - Aug 21st, 2019 at 3:09pm
Print Post  
First I suggest you changed from "Default Optimization" to "No Project + Libraries"

That might help and usually is required. You can see the optimization setting is "default" in your picture

If that does not help then try to stop on a normal code line.
  
Back to top
WWW  
IP Logged
 
Marco (Italy)
Full Member
***
Offline


Posts: 165
Joined: Jul 12th, 2019
Re: EXCEPTION DURING DEBUG
Reply #2 - Aug 21st, 2019 at 4:16pm
Print Post  
Thank you.
The error is no longer there, but now I no longer work a part of the program a library (FastLed) has stopped working. If I put the setting back in default, the error reoccurs but the fastled library works well.

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


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: EXCEPTION DURING DEBUG
Reply #3 - Aug 21st, 2019 at 5:32pm
Print Post  
That's GDB for you Smiley Try setting "No Project Optimization" instead of "No Project + Libraries" then your own code should debug fully but some library code will not debug fully.
« Last Edit: Aug 21st, 2019 at 5:33pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
Marco (Italy)
Full Member
***
Offline


Posts: 165
Joined: Jul 12th, 2019
Re: EXCEPTION DURING DEBUG
Reply #4 - Aug 21st, 2019 at 5:39pm
Print Post  
Hello I tried with all configurations:
Default: FastLed works - Ethernet does not work
NO optimizations : FastLed does not work - Ethernet works
NO optimizations + libraries : FastLed does not work - Ethernet works

My goal is: FastLed + Ethernet working together.

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


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: EXCEPTION DURING DEBUG
Reply #5 - Aug 21st, 2019 at 5:44pm
Print Post  
It's interesting.

You mean you want to debug both FastLED and Ethernet at the same time?


  
Back to top
WWW  
IP Logged
 
Marco (Italy)
Full Member
***
Offline


Posts: 165
Joined: Jul 12th, 2019
Re: EXCEPTION DURING DEBUG
Reply #6 - Aug 22nd, 2019 at 5:58am
Print Post  
Hi my goal is not to a library debugging. I want debug my code on my custom made board. 
Unfortunately, during debugging I saw the error I reported to you, and the compiler output does not even run without an emulator. It seems that the compiler in some cases does not produce code correctly. Hence my need to activate debugging. Normally the library functions called by my code are not explored internally using the STEP-OVER debug option. Unfortunately the problem I reported only occurs within the libraries and to understand it I had to use the STEP-INTO function. That's it

You can help me understand, or suggest some solution. Here is a list of the libraries I use. If necessary, I can send you the source code.


#include <Ethernet.h>
#include <FreeRTOS_ARM.h>
#include <basic_io_arm.h>

/* For E2PROM emulation use Bank1 for e2prom emulation*/
#include <DueFlashStorage.h>
#include <efc.h>
#include <flash_efc.h>
/************RF2.4GHZ MODULE****************************/
#include <printf.h>
#include <RF24.h>
#include <RF24_config.h>
/************LED MANAGEMENT*****************************/
#include <FastLED.h>

Smiley
« Last Edit: Aug 22nd, 2019 at 5:58am by Marco (Italy) »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: EXCEPTION DURING DEBUG
Reply #7 - Aug 22nd, 2019 at 11:17am
Print Post  
Thanks, it sounds like we need a new feature that allows you to specify libraries that will not be subject to disabled optimization. It sounds like FastLED can not be debugged without optimization yet other libraries can only be debugged without optimization.

In this case future versions of visual micro might support a library.properties flag called something like "disable_optimzation=never" that you could add to fastLED

Make sense?


  
Back to top
WWW  
IP Logged
 
Marco (Italy)
Full Member
***
Offline


Posts: 165
Joined: Jul 12th, 2019
Re: EXCEPTION DURING DEBUG
Reply #8 - Aug 23rd, 2019 at 9:49am
Print Post  
Hello!
Yes, it makes sense to me, too. Because the arduino platform, as you know, is open and therefore each person has developed the libraries with their own philosophy, so it is interesting the possibility of a compiler that fits better for each library. If you want I can be a tester. Let me know what you decide.
Smiley Cheesy
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint