Standard Practice for including custom library in examples folder

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












I have created my custom library with examples folder in them. The main header file is ABC_Node.h. I am referring the structure of Adafruit libraries for Arduino and in some repos under the examples folder I found a conflict for the inclusion of their header files.



Example



in some repos. they use double quotes ("") for including their header files e.g. #include "Adafruit_SHT31.h"
SHT31test.ino



on the contrary, in their BNO055 Arduino library they use brackets (<>) #include <Adafruit_BNO055.h> BNO055 Bunny sketch



I locally tested my library on the IDE and I have examples in which my library is in #include "ABC_Node.h" and it compiles without a problem.



Soon I wish to make the repository public and want to know if there is a standard practice for including header files for examples.










share|improve this question

























    up vote
    1
    down vote

    favorite












    I have created my custom library with examples folder in them. The main header file is ABC_Node.h. I am referring the structure of Adafruit libraries for Arduino and in some repos under the examples folder I found a conflict for the inclusion of their header files.



    Example



    in some repos. they use double quotes ("") for including their header files e.g. #include "Adafruit_SHT31.h"
    SHT31test.ino



    on the contrary, in their BNO055 Arduino library they use brackets (<>) #include <Adafruit_BNO055.h> BNO055 Bunny sketch



    I locally tested my library on the IDE and I have examples in which my library is in #include "ABC_Node.h" and it compiles without a problem.



    Soon I wish to make the repository public and want to know if there is a standard practice for including header files for examples.










    share|improve this question























      up vote
      1
      down vote

      favorite









      up vote
      1
      down vote

      favorite











      I have created my custom library with examples folder in them. The main header file is ABC_Node.h. I am referring the structure of Adafruit libraries for Arduino and in some repos under the examples folder I found a conflict for the inclusion of their header files.



      Example



      in some repos. they use double quotes ("") for including their header files e.g. #include "Adafruit_SHT31.h"
      SHT31test.ino



      on the contrary, in their BNO055 Arduino library they use brackets (<>) #include <Adafruit_BNO055.h> BNO055 Bunny sketch



      I locally tested my library on the IDE and I have examples in which my library is in #include "ABC_Node.h" and it compiles without a problem.



      Soon I wish to make the repository public and want to know if there is a standard practice for including header files for examples.










      share|improve this question













      I have created my custom library with examples folder in them. The main header file is ABC_Node.h. I am referring the structure of Adafruit libraries for Arduino and in some repos under the examples folder I found a conflict for the inclusion of their header files.



      Example



      in some repos. they use double quotes ("") for including their header files e.g. #include "Adafruit_SHT31.h"
      SHT31test.ino



      on the contrary, in their BNO055 Arduino library they use brackets (<>) #include <Adafruit_BNO055.h> BNO055 Bunny sketch



      I locally tested my library on the IDE and I have examples in which my library is in #include "ABC_Node.h" and it compiles without a problem.



      Soon I wish to make the repository public and want to know if there is a standard practice for including header files for examples.







      arduino-ide library






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked 38 mins ago









      Shan-Desai

      1488




      1488




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          3
          down vote













          You can use either. There is no "standard".



          When using a raw C compiler there is a difference between the two as regards the order in which directories are searched for files to include, but with the Arduino that is completely irrelevant, so either can be used.



          Personally I use <...> for libraries and "..." for header files that form part of the sketch. It makes for easier identification of which is which, and conforms to the C standard of <...> for system-installed headers, and "..." for local headers.






          share|improve this answer




















          • me too :-) (123)
            – Juraj
            24 mins ago










          Your Answer





          StackExchange.ifUsing("editor", function ()
          return StackExchange.using("schematics", function ()
          StackExchange.schematics.init();
          );
          , "cicuitlab");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "540"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2farduino.stackexchange.com%2fquestions%2f56810%2fstandard-practice-for-including-custom-library-in-examples-folder%23new-answer', 'question_page');

          );

          Post as a guest






























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          3
          down vote













          You can use either. There is no "standard".



          When using a raw C compiler there is a difference between the two as regards the order in which directories are searched for files to include, but with the Arduino that is completely irrelevant, so either can be used.



          Personally I use <...> for libraries and "..." for header files that form part of the sketch. It makes for easier identification of which is which, and conforms to the C standard of <...> for system-installed headers, and "..." for local headers.






          share|improve this answer




















          • me too :-) (123)
            – Juraj
            24 mins ago














          up vote
          3
          down vote













          You can use either. There is no "standard".



          When using a raw C compiler there is a difference between the two as regards the order in which directories are searched for files to include, but with the Arduino that is completely irrelevant, so either can be used.



          Personally I use <...> for libraries and "..." for header files that form part of the sketch. It makes for easier identification of which is which, and conforms to the C standard of <...> for system-installed headers, and "..." for local headers.






          share|improve this answer




















          • me too :-) (123)
            – Juraj
            24 mins ago












          up vote
          3
          down vote










          up vote
          3
          down vote









          You can use either. There is no "standard".



          When using a raw C compiler there is a difference between the two as regards the order in which directories are searched for files to include, but with the Arduino that is completely irrelevant, so either can be used.



          Personally I use <...> for libraries and "..." for header files that form part of the sketch. It makes for easier identification of which is which, and conforms to the C standard of <...> for system-installed headers, and "..." for local headers.






          share|improve this answer












          You can use either. There is no "standard".



          When using a raw C compiler there is a difference between the two as regards the order in which directories are searched for files to include, but with the Arduino that is completely irrelevant, so either can be used.



          Personally I use <...> for libraries and "..." for header files that form part of the sketch. It makes for easier identification of which is which, and conforms to the C standard of <...> for system-installed headers, and "..." for local headers.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered 32 mins ago









          Majenko♦

          62.9k42873




          62.9k42873











          • me too :-) (123)
            – Juraj
            24 mins ago
















          • me too :-) (123)
            – Juraj
            24 mins ago















          me too :-) (123)
          – Juraj
          24 mins ago




          me too :-) (123)
          – Juraj
          24 mins ago

















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2farduino.stackexchange.com%2fquestions%2f56810%2fstandard-practice-for-including-custom-library-in-examples-folder%23new-answer', 'question_page');

          );

          Post as a guest













































































          Comments

          Popular posts from this blog

          What does second last employer means? [closed]

          List of Gilmore Girls characters

          One-line joke