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
Serial debugger stuck on "Launching debugger..." (Read 1568 times)
Isaac
Newbies
*
Offline



Posts: 3
Serial debugger stuck on "Launching debugger..."
May 20th, 2020 at 8:15pm
 
I tried to search for other posts about this same issue but none of the threads had applicable solutions.

I have an Due. I have successfully uploaded a number of sketches. The serial output from these sketches comes through to the monitor no problem. However, I have been unable to get debugging to work. When I switch to debug mode and click build and upload, everything seems to go fine but the micro debug trace output simply shows Launching Debugger... (along with some tutorial text when I have tutorial mode on).

In order to reduce confounding factors, I'm following the debugging tutorial.

I am using the native usb port on the due.
Back to top
 

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



Posts: 11127
United Kingdom
Re: Serial debugger stuck on "Launching debugger..."
Reply #1 - May 21st, 2020 at 12:30am
 
If your own sketch code uses serial then please make sure you have set the speed that you use in vMicro>Debugger>RemoteSpeed. That should also change the LocalSpeed menu item to be the same.

Please also ensure the DTR on the serial monitor is enabled otherwise any breakpoints in setup() might be missed.

If those two points don't help then please confirm if you own code uses Serial.read() and an example of where you have placed a breakpoint.

Thanks

Back to top
 

Tim Leek
home
WWW  
IP Logged
 
Isaac
Newbies
*
Offline



Posts: 3
Re: Serial debugger stuck on "Launching debugger..."
Reply #2 - May 21st, 2020 at 12:56am
 
I'm trying the debugger on the "Blink without delay" example sketch which doesn't use serial at all. I set the breakpoint on the loop function declaration (as the tutorial instructed).

Since you mentioned it, DTR doesn't seem to work. Is it supposed to reset my board when I deselect and reselect 'connect'?.
Back to top
 
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline



Posts: 11127
United Kingdom
Re: Serial debugger stuck on "Launching debugger..."
Reply #3 - May 23rd, 2020 at 1:00pm
 
Some boards don't use the DTR, the Native USB Port is one of them.

Bacause you are usig the native usb port on a due I think I recall that it uses Serial1 and not Serial for that port.

In that case set "vMicro>Debugger>Remote Port" to Serial1. See if that works?

(We should be detecting that and switching to Serial1 but maybe that detection is failing)



Back to top
 

Tim Leek
home
WWW  
IP Logged
 
Isaac
Newbies
*
Offline



Posts: 3
Re: Serial debugger stuck on "Launching debugger..."
Reply #4 - May 25th, 2020 at 5:07pm
 
That pointed me in the right direction. Overriding the remote port to serial1 didn't work but overriding to SerialUSB did.
Back to top
 
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline



Posts: 11127
United Kingdom
Re: Serial debugger stuck on "Launching debugger..."
Reply #5 - May 25th, 2020 at 5:35pm
 
Thanks, we will look into that. It should auto detect SerialUSB for that board unless you specifically set the RemotePort.

Back to top
 

Tim Leek
home
WWW  
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 1014
Re: Serial debugger stuck on "Launching debugger..."
Reply #6 - May 27th, 2020 at 8:42pm
 
The Latest Release (20.05.18.5) contains a fix for this issue, let us know if there are any further problems.

Previous Releases, New Releases and Notifications
Back to top
 
 
IP Logged
 
gj
Junior Member
**
Offline



Posts: 40
Re: Serial debugger stuck on "Launching debugger..."
Reply #7 - Nov 25th, 2020 at 10:04am
 
So, I'm having the same problem.
Using D1 mini, and a real small sketch (to exclude any software errors on my side)
VM is version 2020.910.8
VStudio Community 2019 is V16.8.2

Code (C++):
void setup() {
	Serial.begin(38400);
}

void loop() {
	Serial.println("*");
	delay(500);
}
 



Switching to an Arduino Uno works fine, so it seems it's related to the combination of the board I have and the one that I choose in the settings.
Also I have been able to upload software and run the Debugger, but for some reason that stopped working.
So, currently it sometimes works but most of the time it doesn't.
Sometimes, but not always, I get the additional message "User Experience: The serial debugger was delayed waiting for an incoming line of data. [...]"

I tried:
* Clean solution and rebuild
* DTS off and on (and also RTS)
* Serial speed down to 9600
* Use Serial1 instead of Serial
* Manually matching the Remote/Local speed in VM
* Selecting other boards in VM that seem the same (Wemos D1 R1, LOLIN(Wemos) D1 R2&mini,  LOLIN(Wemos) D1 mini Pro, LOLIN(Wemos) D1 mini Lite). Even the 'Generic ESP8266 Module'.
All to no avail

So, how to proceed?
Back to top
« Last Edit: Nov 25th, 2020 at 5:52pm by gj »  
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 1014
Re: Serial debugger stuck on "Launching debugger..."
Reply #8 - Nov 25th, 2020 at 10:59am
 
Thanks for the detail.

The Serial Debugger runs by default at 115200, and the rate can be changed in the vMicro > Project Properties > Local Speed.
Doc: https://www.visualmicro.com/page/User-Guide.aspx?doc=Debugging-With-Different-Po...

Can you please attach a copy of the build log with the settings as shown at the top of this page so we can investigate further?
Back to top
« Last Edit: Nov 25th, 2020 at 4:59pm by Tim@Visual Micro »  
 
IP Logged
 
gj
Junior Member
**
Offline



Posts: 40
Re: Serial debugger stuck on "Launching debugger..."
Reply #9 - Nov 25th, 2020 at 3:14pm
 
I did change the verbose and other settings and recompiled.
However, the instruction at the top is not specific on where to find the actual log to attach.
I have a Debug-directory in the projectfolder, but that contains 16 items.
Which one to attach?  Huh
Back to top
« Last Edit: Nov 25th, 2020 at 3:16pm by gj »  
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline



Posts: 1014
Re: Serial debugger stuck on "Launching debugger..."
Reply #10 - Nov 25th, 2020 at 3:42pm
 
The logging is just the content from the Visual Studio Output window > Micro Build.
Back to top
 
 
IP Logged
 
gj
Junior Member
**
Offline



Posts: 40
Re: Serial debugger stuck on "Launching debugger..."
Reply #11 - Nov 25th, 2020 at 5:55pm
 
And as always.... now it works fine both with the real project as well as the 'empty' project.  Angry.
And for all of the 3 Wemos I have....
Anyhow, the log is in the attachment (for the 'empty' project) , but I assume you won't find anything out of the ordinary...

I'll get back with another log when the problem magically re-appears.
Back to top
« Last Edit: Nov 25th, 2020 at 5:56pm by gj »  

Please Register or Login to the Forum to see File Attachments
 
IP Logged
 
Page Index Toggle Pages: 1
Send Topic Print