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 Leading spaces are supressed in serial monitor (Read 2859 times)
Joao Tavares
Newbies
*
Offline


Posts: 9
Joined: Nov 24th, 2017
Leading spaces are supressed in serial monitor
May 24th, 2018 at 2:42pm
Print Post  
In my Visual micro Version 1.1803.26 the leading spaces sent to the serial windows are suppressed what causes a lot of stress for someone trying to develop something without too much experience. I thought that I was doing something wrong. I tried with a different serial monitor and things are correct with the leading spaces 
What is happening ? Why are not others speaking about this only something in 2013.
Best regards

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


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Leading spaces are supressed in serial monitor
Reply #1 - May 24th, 2018 at 2:51pm
Print Post  
Hi,

This only happens when in debug mode. If you switch the toolbar from Debug to Release and then upload you will see the spaces are not removed.

You can find a forum thread where it was discussed here 

Thanks
  
Back to top
WWW  
IP Logged
 
Lookingooder
Newbies
*
Offline


Posts: 2
Joined: Aug 21st, 2019
Re: Leading spaces are supressed in serial monitor
Reply #2 - Aug 22nd, 2019 at 2:20pm
Print Post  
Thank you for reply.

Here is short test code:
Code (C++)
Select All
#include <ESP8266WiFi.h>
#include <ESP8266WebServer.h>

const char* myssid = "AP MODE";				//SSID AP MODE
const char* mypassword = "12345678"; //Password AP MODE


char output_buffer[5000] = "\
<!DOCTYPE html>\
<html>\
 <head>\
  <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\">\
  <title>Main page</title>\
 </head>\
 <body>\
			What is Visual Micro?\
																																													\
			Visual Micro is an so called extension for Microsoft Visual Studio 2017 and 2019 and\
			for Atmel Studio 7 that allows any Arduino project to be developed, compiled, and\
			then uploaded to any Arduino board, while taking benefit of the powerful features of Visual Studio and Atmel Studio.\
																																																\
			Visual Micro is fully compatible with the Arduino development environment and uses\
			the same libraries, source code, and development tools. The difference lies\
			in Visual Micro's user interface which provides an advanced and professional\
			development environment, and allows for more advanced development than the existing Arduino IDE.\
																																																				\
			What does the term IDE mean?\
																																																					\
			In this documentation, you will often find the term \"IDE\". This is an industry\
			standard term meaning  Integrated Development Environment, which is a software\
			application that incorporates a source code editor, build tools such as a compiler\
			and a debugging system. The IDE is used to write, edit, build, and test your software.\
			Whilst Arduino's IDE provides a basic starter level IDE, Visual Micro in conjunction\
			with Microsoft Visual Studio or Atmel Studio provides an enhanced and more functional IDE.\
	</body>\
</html>\
";

WiFiServer server(80);
ESP8266WebServer serverAP(80);

void handleRoot()
{
// serverAP.send(200, "text/html", "<h1>Connected</h1>");
	serverAP.send(200, "text/html", output_buffer);
}

void setup()
{
	Serial.begin(115200);
	Serial.println(output_buffer);
	Serial.println("\n=========================");

 WiFi.mode(WIFI_AP);

 //AP
 IPAddress myIP =WiFi.softAP(myssid, mypassword);
 serverAP.on("/", handleRoot);

 serverAP.begin();

}//setup()

void loop()
{
 serverAP.handleClient();
 delay(100);
}//loop()

/*
*/ 



and outputs sent to E-mail
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Leading spaces are supressed in serial monitor
Reply #3 - Aug 22nd, 2019 at 2:25pm
Print Post  
Does the problem happen when to switch the tool bar to Release mode?
  
Back to top
WWW  
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Leading spaces are supressed in serial monitor
Reply #4 - Aug 27th, 2019 at 2:28pm
Print Post  
I have tested this and the trimming of white space only happens in Debug Mode. A Release compile shows all text including whitespace.

Maybe this was a bug in the older vs2013 version of visual micro. Did you try vs2017 o 2019?

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


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Leading spaces are supressed in serial monitor
Reply #5 - Nov 16th, 2019 at 2:16pm
Print Post  
This is resolved in both Release and Debug mode in Visual Micro versions since late sept. 2019
  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint