v2.0 and SerialGateway



  • I just got started with a goal of building a few simple temperature sensors. I used the IDE to install the latest v2.X release and followed the SerialGateway instructions. However it appears that the instructions and example are based on an earlier release as there are numerous missing libraries/includes...but also and include for MySensor.h as opposed to MySensors.h.

    Looking at the SerialGateway example provided with the v2.0 install, it appears to be just a stub. I'm sure I missing something here, so help getting me back on track would be appreciated. Is there are current v2.0 SerialGateway sketch or should i be using the one provided in the tutorial? If the older one is still valid, do I need to grab the older libraries in addition to the v2.0 install from the IDE?

    I appreciate the help and patience with newbie questions.


  • Mod

    @Kodiak80 very welcome to the MySensors community!

    The build page still shows the 1.5 examples. An update is on the way, but still some time away unfortunately. Sorry for the confusion.

    The example included with 2.0 is the one that you should use. The sketch is very simple, which is on purpose. There really isn't more you need to do to get it running 🙂 It is possible to extend from there, but start with just the example and add more when you've got the basics working.



  • Thanks for the quick replay. I'm new to Arduino, so maybe I'm missing something, but the SerialGateway example with v2.X has empty setup and loop functions. Without those I was under the impression there was no logic in this sketch. Particularly when I compare it to the version in the Serial Gateway video tutorial.

    On a related note, I setup one of my Dallas Temperature sensors following the tutorial for that sensor. It appears the example sketch provided is also for a previous version of MySensors (pre-v2.x), and needs some updates to be compatible with the latest version. Is my best option to just update that sketch or is there another one around for the current release?

    I appreciate the help.


  • Mod

    @Kodiak80 the Dallas example for MySensors 2 is avaliable at https://github.com/mysensors/MySensorsArduinoExamples/blob/master/examples/DallasTemperatureSensor/DallasTemperatureSensor.ino

    The sketch needs some additional libraries. The libraries are included if you download the entire repo from https://github.com/mysensors/MySensorsArduinoExamples

    Unfortunately, some of the libraries have introduced breaking changes so it is not possible to use the libraries that can be installed from thr Arduino IDE library manager.


Log in to reply
 

Suggested Topics

  • 3
  • 5
  • 2
  • 8
  • 6

42
Online

11.4k
Users

11.1k
Topics

112.6k
Posts