Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

restructering folder-structure to enable the use of add-ZIP-library of the Arduino-IDE #12

Closed
StefanL38 opened this issue Dec 19, 2020 · 1 comment

Comments

@StefanL38
Copy link

Hi yoursunny,

I donwloaded your WifiEspNow-library and compiled and tested successfully EspNowBroadcast.ino-example

after downloading the code as a zipfile WifiEspNow-master.zip and unzipping it and analysed the strucure of the folders and files

it is well sorted but does not match the structure needed to use the add-zip-library function of the arduino-IDE

the *.h and *.cpp-file has to be in a folder that has the name of the *.h-file

For using the add-zip-library-function the structure must be

C:\Users\Stefan\Documents\Arduino\libraries\WifiEspNow\WifiEspNow.h

C:\Users\Stefan\Documents\Arduino\libraries\WifiEspNowBroadcast\WifiEspNowBroadcast.h

in general:

 ....libraries\WifiEspNow\WifiEspNow.h

 ....libraries\WifiEspNowBroadcast\WifiEspNowBroadcast.h

same principle for the examples there has to be a sub-folder below WifiEspNowBroadcast named "examples" 

and inside the examples-folder there must be a folder with the name of the sketch and the *.ino-file is then inside this folder

.....Arduino\libraries\WifiEspNowBroadcast\examples\EspNowBroadcast\EspNowBroadcast.ino

If the folder-structure is roganised like this the examples show up under the

file - examples-menu of the Arduino-IDE

So what do you think about re-structering in this way to make it easier to use?

May I suggest an additional thing. IMHO names of example-sketches should include the word "demo" so a file-search with keywords like "ESP" "Demo" *.ino would be quite specific to find it.

@yoursunny
Copy link
Owner

All my libraries should be installed using git, not as ZIP archives.
I have added installation steps in README.md.

Having *.h in the library root folder is the convention of Arduino 1.0.x.
I'm publishing as 1.5.x+-only libraries, where the source code resides in the src folder.
See Arduino library specification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants