My own library with MyS commands



  • I want to make my own library. In that library I will put stuff that I use in all my sketches.
    I will still include MySensors.h, version 2.1.1
    What I want to do is to put MyMessage for 3 childs that I always use in my sketches, of course I can write it in my sketch but it looks cleaner and I want to learn more about library.
    When I use MyMessage in my new library I get an error in Arduino IDE,
    'MyMessage' was not declared in this scope
    I guess that MyMessage is not public or something like that.

    Anyone that can help in correct direction?


  • Mod

    @flopp The Arduino build system is 'tricky' on includes, to state it mildly...
    Maybe you can get some inpiration from my Dollhouse sketches, which share the 'DemoSensorConfig' library.

    https://github.com/Yveaux/Dollhouse_sketches



  • @Yveaux
    Thanks, i will have a look at it


Log in to reply
 

Suggested Topics

  • 1844
  • 18
  • 7
  • 54
  • 3
  • 1
  • 1
  • 3

157
Online

9.6k
Users

10.2k
Topics

106.1k
Posts