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 bitlash.h:116:25: error: 'Serial' undeclared (Read 5178 times)
miromeir_1
Newbies
*
Offline


Posts: 1
Joined: Jul 24th, 2016
bitlash.h:116:25: error: 'Serial' undeclared
Jul 24th, 2016 at 9:18am
Print Post  
Hi!

I have stumbled upon a problem while using some libraries with visual micro at compile - yet the arduino IDE compiles successfully.

For start:
The Bitlash Library: https://github.com/billroy/bitlash/wiki/download.

I install using VMicro.
Reload IDE.

VMicro adds: Quote:

#include <conio.h>
#include <bitlash.h>


then compiler returns errors, among them:
Quote:
bitlash.h:116:25: error: 'Serial' undeclared (first use in this function)

Quote:
mygetch.c:7:18: fatal error: time.h: No such file or directory
:#include <time.h>


Some of those errors are related to Linux-Specific libraries, which aren't supposed to be used. my guess would be that compiler doesn't get the "if defined" macros that distinguish between platforms - **But that's just an observation, i really have no idea why it does'nt compile, while arduino IDE does.

I tried everything i can for about a week now without success.

Would love to hear your advise!
« Last Edit: Jul 24th, 2016 at 9:19am by miromeir_1 »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: bitlash.h:116:25: error: 'Serial' undeclared
Reply #1 - Jul 24th, 2016 at 4:45pm
Print Post  
Hi,

Is vMicro>Compiler>Deppe search enabled?

Does switching the toolbar from Debug to Release improve things?

Which board and arduino ide version?

On latest release of Visual Micro?

Thanks
  
Back to top
WWW  
IP Logged
 
klonk sk
Newbies
*
Offline


Posts: 1
Joined: Aug 16th, 2016
Re: bitlash.h:116:25: error: 'Serial' undeclared
Reply #2 - Aug 16th, 2016 at 10:26pm
Print Post  
i have same isue with bitlash.h Sad

Both Debug/Relese , Deep search onOf

I tried it on arduino uno /nano 

Latest VS / VSMicro 

Any advise welcome  Smiley
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: bitlash.h:116:25: error: 'Serial' undeclared
Reply #3 - Aug 17th, 2016 at 7:35pm
Print Post  
Hi,

Thanks for the info.

Please switch on vMicro>Compiler>Verbose and vMicro>Compiler>Show build properties so that I can replicate your config and know things such as which board you are using.

If you then build and post the output as a .txt or email to info[at]visualmicro,com thanks
« Last Edit: Aug 17th, 2016 at 7:36pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: bitlash.h:116:25: error: 'Serial' undeclared
Reply #4 - Aug 17th, 2016 at 7:47pm
Print Post  
Okay I have looked at the lib home page and it says it is for the Due

I see the library actually has an invalid structure. I suspect the "bitlash.h" in the lib root is required for arduino and not the "bitlash.h" in the src folder.

Arduino libraries originally supported the lib folder and optional lib\utility folder for "private" sources

In the past year or so a new library structure has been released by arduino which has the lib headers in an \src folder below each library and an unlimited number of "private" sub folders below that.

The new lib structure also has a library.properties text file in the lib root however libraries such as the ArduinoJSON library also broke the rules (until recently) by putting the main lib sources in the \src folder but without a library.properties file. 

So this library has the normal code in the root with some duplicated files in the \src folder and Visual Micro is seeing the \src folder and expecting that to be the main library code. Uggh Smiley

I think it is safe to undo the change made for libs such as ArduinoJSON because the Arduino Ide no longer compiles them and considers them invalid.

I'll take a look and release an update over the next day or so.

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


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: bitlash.h:116:25: error: 'Serial' undeclared
Reply #5 - Aug 18th, 2016 at 8:22pm
Print Post  
Please try the latest release (1608.18). The first point in the release notes describes the change.

The release should appear in tools>extensions & updates>updates
« Last Edit: Aug 18th, 2016 at 8:23pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint