Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
L

laschlo

@laschlo
About
Posts
3
Topics
1
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Can't get nodeID from the controller
    L laschlo

    Damn, I should have read documentation more carefully :) For some reason I assumed Gateway will send out nodeIDs. So now I'm going to start digging into MySensors and OpenHAB documentation.

    Thanks HEK!

    Troubleshooting

  • Can't get nodeID from the controller
    L laschlo

    @hek
    Controller is an Arduino UNO, flashed with SerialGateway example.

    Troubleshooting

  • Can't get nodeID from the controller
    L laschlo

    Howdy folks!
    I'm a new user of the MySensors library, however Im not new into AVRs and Arduinos ;) I've been trying to setup 2 UNOs with two radios and MySensors - 1 controller and one sensor ( in my case just for the example purpose - door sensor). Both radios connected as instructed. First UNO (controller) flashed with the SerialGateway example code, second - the sensor with example from the webpage. If i set nodeID manually on the sensor with gw.begin, everything seems to be ok. But when I try to get nodeID from the controller, it seems sensor is trying to send following message over and over again, thus not getting nodeID from the controller.

    Sensor serial data (DEBUG mode ON):

    req node id
    send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,st=ok:
    sensor started, id 255
    req node id
    send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,st=ok:
    req node id
    send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,st=ok:
    req node id
    send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,st=ok:
    

    Controller serial data (DEBUG mode ON)

    0;0;3;0;9;Inclusion started by button.
    0;0;3;0;5;1
    0;0;3;0;9;
    read: 255-255-0 s=255,c=3,t=3,pt=0,l=0:
    255;255;3;0;3;
    0;0;3;0;9;
    read: 255-255-0 s=255,c=3,t=3,pt=0,l=0:
    255;255;3;0;3;
    0;0;3;0;9;
    read: 255-255-0 s=255,c=3,t=3,pt=0,l=0:
    255;255;3;0;3;
    

    Sensor sketch:

    #include <MySensor.h>
    #include <SPI.h>
    #define ID 1
    #define OPEN 1
    #define CLOSE 0
    
    MySensor gw;
    MyMessage msg(ID, V_TRIPPED);
    
    void setup() 
    { 
      gw.begin();
      gw.present(ID, S_DOOR); 
    }
    
    void loop()
    {
     gw.send(msg.set(OPEN)); 
     delay(10000); // Wait 10 seconds
    }
    
    Troubleshooting
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular