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
Locked Topic Creating a new Library (Read 1154 times)
Arnd
Newbies
*
Offline


Posts: 5
Location: Europe & Caribbean
Joined: Jan 12th, 2019
Creating a new Library
Feb 17th, 2019 at 9:13am
 
The recommended structure for an Arduino library is:

libname/library.properties
libname/src/library.h
libname/src/library.cpp
libname/examples/example1/example1.ino
libname/examples/example2/example2.ino
libname/examples/example3/example3.ino

I am trying, without success, to have a single VisualMicro solution containing those files/paths so that it can be uploaded with a single click to GitHub (ignoring all the Visual-Studio related files and directories).

When I use the VisualMicro library functionality I get a "libname/libname" directory structure and I cannot get restructure that layout.

Is it possible to make a file and directory layout as shown at the beginning or should I continue to make a separate solution for each of the "example.ino" files?

And thanks for creating this product, I keep on getting reminded of the great functionality every time I revert back to the original IDE.
« Last Edit: Feb 17th, 2019 at 9:13am by Arnd »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12070
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Creating a new Library
Reply #1 - Feb 17th, 2019 at 3:38pm
 
Hi,

I am not entirely clear how you are configuring your solution. Maybe there is some information that will help or maybe there is some problem I don't understand. 

I would create the environment in a single solution as follows. Assume the solution structure is the physical file/folder layout after clicking the "Show all files" mini icon above the solution explorer.

Solution1
c:\Test\MySolution
c:\Test\MySolution\Libs
Shared Library Project
c:\Test\MySolution\Libs\Lib1
c:\Test\MySolution\Libs\Lib1\library.properties
c:\Test\MySolution\Libs\Lib1\src
c:\Test\MySolution\Libs\Lib1\src\Lib1.h
c:\Test\MySolution\Libs\Lib1\src\Examples
c:\Test\MySolution\Libs\Lib1\src\Examples\Example1
c:\Test\MySolution\Libs\Lib1\src\Examples\Example1\Example1.ino
Normal Arduino Project
c:\Test\MySolution\Projects
c:\Test\MySolution\Projects\Project1
c:\Test\MySolution\Projects\Project1\Project1.ino

Q: If you are encountering a build issue in a solution that has both Project1 and Lib1 then please state that is the case. If not please explain what the problem is.

Thanks
« Last Edit: Feb 17th, 2019 at 3:39pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint