Welcome, Guest. Please Login or Register
Arduino IDE for Visual Studio
 
  HomeSearch Tutorials & Wiki visualmicro.com LoginHelpRegister  
 
Page Index Toggle Pages: 1
Send Topic Print
Adding Library in Lib (Read 5039 times)
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #14 - Oct 19th, 2016 at 12:56pm
 
Maybe the latest virus checkers are picking it up again. It only relates to an .exe used for esp8266 spiffs upload so if your virus checker removed the file yesterday you wouldn't see the error today.

It's also possible that the visual studio auto update installed a new version of visual micro yesterday or today which further confuses us Smiley

I will do some more testing at the weekend. It's annoying that a simple .exe is so difficult. Maybe it's time to add a signature to the .exe's but that makes the build and deployment more difficult.

I have my fingers crossed that it's okay now Smiley
Back to top
 
WWW  
IP Logged
 
Maarten
Newbies
*
Offline



Posts: 2
Re: Adding Library in Lib
Reply #13 - Oct 19th, 2016 at 12:40pm
 
Restarted Visual Studio 2015 this morning, no error anymore.  Roll Eyes

Still strange because I restarted the laptop yesterday as well. Anyway I can continue the quest...

Best regards,
Maarten
Back to top
« Last Edit: Oct 19th, 2016 at 12:50pm by Maarten »  

Win 10, Visal Studio 2015, Arduino IDE Version 1610.402, Arduino Uno
 
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #12 - Oct 18th, 2016 at 7:08pm
 
Hi, this was resolved in builds of last few months.

Can you please state the version you are using from "tools>extensions and updates"

Thanks
Back to top
 
WWW  
IP Logged
 
Maarten
Newbies
*
Offline



Posts: 2
Re: Adding Library in Lib
Reply #11 - Oct 18th, 2016 at 5:08pm
 
Any update about this case?
I have the same issue here.

Greetings Maarten
Back to top
 

Win 10, Visal Studio 2015, Arduino IDE Version 1610.402, Arduino Uno
 
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #10 - May 17th, 2016 at 2:40am
 
Okay arduino looked into it and the loaded.exe is raising a false positive with mcAffee. So the 101 core is fine.

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



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #9 - May 15th, 2016 at 12:24am
 
Update 2.

I have suspended testing with the Arduino 101 v1.0.5 core because my virus checker reports it contains a trojan.

I hope it is a false positive but have logged an issue with the Arduino IDE team:-

https://github.com/arduino/Arduino/issues/4952
Back to top
 
WWW  
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #8 - May 14th, 2016 at 11:51pm
 
Hi,

Thanks for the output. The deep search is failing which I will look into.

However, a workaround is to add #include <Servo.h> to the [project_name].ino it will work.

tip: if you always add #includes for any required libs to the [project_name].ino then you can work with "deep search" switched off which improves build times (substantially in some cases).

nb: First compile after altering the switch is always a full build

Back to top
« Last Edit: May 14th, 2016 at 11:51pm by Visual Micro »  
WWW  
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #7 - May 14th, 2016 at 3:51pm
 
Thanks.

Please switch on "tools>options>visual micro>compiler>show build properties" and also the "verbose" option.

Then click "Build>clean solution"

Then build and email the output to info [at] visualmicro.com

Thanks
Back to top
 
WWW  
IP Logged
 
Sava
Newbies
*
Offline



Posts: 4
Re: Adding Library in Lib
Reply #6 - May 14th, 2016 at 9:16am
 
Hi,

I had enshured, that the Arduino IDE was up to date, before I wrote...  Also the boards...
Yesterday I updated Visual Studio (and visual micro). Due to the lattest update the error message changed to:

In file included from C:\Users\Sebastian\Documents\Arduino\libraries\RobotArm\RobotArm.cpp:4:0:
C:\Users\Sebastian\Documents\Arduino\libraries\RobotArm\RobotArm.h:5:19: fatal error: Servo.h: No such file or directory
#include <Servo.h>
                   ^
compilation terminated.

An error was encountered during the 'Deep Search' discovery process.
Either resolve the error or switch off the 'Deep Search Includes' option.
     Tip: When deep search is switched off, headers must be #included in the [project_name.ino] for all required libraries (for example: #include <SPI.h>)
     Tip: Deep search must be off if the project source contains links/shortcuts to code outside of the project structure. The source will have been #included using a relative path preceeded by ..\ (for example: #include "..\..\foo\foo.h")

Has someone encountered the same problem for the board?
Back to top
 
 
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #5 - May 12th, 2016 at 11:41pm
 
Hi,

Can you confirm your visual micro version? Have you been keeping it up to date?

All the hardware manufacturers have been making huge updates as has the Arduino IDE team.

Please tell me the version you using from tools>extensions and updates>arduino ide for vs>version

Thanks
Back to top
 
WWW  
IP Logged
 
Sava
Newbies
*
Offline



Posts: 4
Re: Adding Library in Lib
Reply #4 - May 11th, 2016 at 8:01pm
 
Hi, the output from building for the 101 ends with:

RobotArm.cpp:In file included from
RobotArm.h:5:19: fatal error: Servo.h: No such file or directory
:#include <Servo.h>
:compilation terminated
Error compiling libraries

Hopefully it is the thing you wanted.

Thank. Wink
Back to top
 
 
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #3 - May 11th, 2016 at 4:35pm
 
Let me say that intellisense and build are two different things.

Let's ignore the Uno project because I think you are saying it is working fine.

For the 101 project:-

1)
Please confirm if it builds okay and that you are reporting intellisense errors?

or

2)
It does not build?


If the build fails then please copy and paste the output (ausgabe) (not error window image) into this thread

Thanks
Back to top
« Last Edit: May 11th, 2016 at 4:59pm by Visual Micro »  
WWW  
IP Logged
 
Sava
Newbies
*
Offline



Posts: 4
Re: Adding Library in Lib
Reply #2 - May 11th, 2016 at 4:26pm
 
Hi, as you can hopefully see deep search is included. The When building for the uno instead of 101 the the read underline everything seams to be ok.

Attachment 1... built for 101
Attachment 2... built for Uno
Back to top
 
 
IP Logged
 
Visual Micro
Administrator
*****
Offline



Posts: 7556
United Kingdom
Re: Adding Library in Lib
Reply #1 - May 11th, 2016 at 3:10pm
 
Hi,

I will give you some info and let me know your findings.

1) Before late last year if you #include another library from a library then you must also ensure that the #include exists in the [project_name].ino. This is typically the most efficint way for Arduino to find all libs and still applies to both the Arduino Ide and Visual Micro.

2) End of last year Arduino introduced a new system to auto-discover libraries in other libraries. This feature is optional in Visual Micro and can be enabled/disabled using menu item "vMicro>Deep Search Includes"

Summary

If you have 2) enabled in Visual Micro (default is enabled) then I would not have expect to see the error you report with missing indirect lib #include. If it is enabled and you see this error then I will look at why Visual Micro isn't performing "deep search" for the 101 tool chain.

Deep search slows the compile times which is why for more experienced users I suggest switching it off and #including all libs in the .ino even if only used in .cpp code.

Historically new users, for example, do not understand that if a library requires "spi.h" then it must be included in the .ino code. So this feature is mainly to prevent the errors for new users.


So the initial questions are, is deep search enabled? and if you include the related header in the .ino code does it build okay?
Back to top
 
WWW  
IP Logged
 
Sava
Newbies
*
Offline



Posts: 4
Adding Library in Lib
May 11th, 2016 at 3:00pm
 
Hi,

for a a project I am writting my own library. In it's header I want to add another library, so it's start with:

#include <Arduino.h>
#include <Servo.h>

I use visual micro with Visual Studio 2015 and test the code with the uno and the 101.

When I build the project for the 101, I get the Warning: "Servo.h: No such file or directory", when I build the project for the uno, I get no warning at all... and building ends with no problem shown. And also the uploading shows no problem.

Unforthantly I can not use the Uno for the project (it is only a sparfun redstick), because I the end I want to use the BLE capabilities of the 101...

When I use the same code base with the arduino IDE and the 101 building and uploading works normal and get a totally other error... I really would like to debug with the visual micro Wink

A hint when adding #include <Servo.h>, I get the hint to use <Servo/Servo.h> or similar... <Servo/src/Servo.h> or a third version, but none of them works...
Back to top
 
 
IP Logged
 
Page Index Toggle Pages: 1
Send Topic Print