"req node id"



  • Hello,

    I'm facing with a "req node id" problem

    For the gateway I use a mega2560, and for sensor node, a nano with a DS18B20 sensor.
    Both are usb powered, and radios have decoupling capacitors

    I read the temperature correctly

    The both arduinos seem to communicate, but I have always the message "req node id"

    From what I understood,, it's the gateway who sends the id ??

    For the temperature node
    Node.jpg

    And for the gateway
    Gateway.jpg

    So any tip ?

    And in general, what does this mean => 0;0;3;0;9;read: 255-255-0 s=255, c=3............ ?

    Thanks.


  • Admin

    @Totche said:

    From what I understood,, it's the gateway who sends the id ??

    No, the controller hands out id.
    (MQTT gateway is an exception here)



  • @Totche said:

    So any tip ?

    And in general, what does this mean => 0;0;3;0;9;read: 255-255-0 s=255, c=3............ ?

    I also am having trouble with understanding this type of code.



  • Thanks for the answer.

    1. So how do you give an Id to a node, or is it unnecessary ?

    2. Is it possible to read/check the sent values on the gateway, and send them on the serial port (always with the gateway) ?

    Thanks



  • @Totche

    1. The controller would do that. If you are using a serial gateway it should be passing all the messages and then the controller would send the correct message back. If you are just setting this up for testing then you can create the message manually.
      I believe that this should work and then just replace X with a number.

      255:255:3:0:4:X

    2. That is what the serial gateway does.


  • Admin

    @Totche said:

    And in general, what does this mean => 0;0;3;0;9;read: 255-255-0 s=255, c=3............ ?

    To see exacly what the debug prints means, you can have a look in the code here:
    https://github.com/mysensors/Arduino/blob/master/libraries/MySensors/MySensor.cpp#L222
    and
    https://github.com/mysensors/Arduino/blob/master/libraries/MySensors/MySensor.cpp#L273

    @Totche said:

    1. So how do you give an Id to a node, or is it unnecessary ?

    All nodes must have an id. But you can set it statically in gw.begin if you don't have any controller. See api.

    1. Is it possible to read/check the sent values on the gateway, and send them on the serial port (always with the gateway) ?

    I don't understand. If you enable debug it will print the same information as the nodes when messages is received/sent. The only difference is that it prepends it with as a LOG-entry so the controller won't be confused.



  • I you read the first message, it is a screencopy of the serial monitor for both, and I don't see the temperature on the gateway. from the node

    Ps : ok the two are the same for the last question above 😉

    Ps : I don't have a controller



  • @Totche said:

    I you read the first message, it is a screencopy of the serial monitor for both, and I don't see the temperature on the gateway. from the node

    Ps : ok the two are the same for the last question above 😉

    Ps : I don't have a controller

    Your going to want a controller in the long term. For testing you can either hard code the node ID in the sketch (you will want to flash the EEPROM clear sketch when you get a controller)

    The reason your not seeing the temp on the gateway is because it doesn't get sent if there is no node ID.

    Basically the node is asking the gateway/controller who am I and the controller isn't responding so it just keeps asking.



  • Ok thanks, now it's clear.



  • I had the same questions when I started a few weeks ago.

    Maybe one of the site admins could add the fact that the controller and not the gateway normally handles assigning IDs since it isn't clear.


  • Admin

    I don't know how to make it more clear. If you got improvements, please help me.

    http://www.mysensors.org/about/network

    "Each node is assigned a unique sensorId or address that is used for sending and receiving point-to-point messages. You can assign a static sensorId or let the controller automatically assign one to the sensor. AUTO-mode configures the sensor to request a sensorId from the controller and is the default option for all the examples that we provide. The sensor stores the assigned sensorId in its non-volatile memory to ensure the correct sensorId persists across power transitions."



  • I may be able to give a pointer towards this.
    I am, as I type this, a first time user digging into the MySensors universe in search for knowledge on how to get a reading (from my first ever mysensor) to pop up (on my first ever mysensor compatible controller).

    And what I frequently found a little frustrating was your site navigation.
    It somehow manages to hide some of the good bits -- or probably more correct; the item names in the top and side navigation bars does not always give me a sense of direction when I go information hunting on a given subject.
    And thus I sometimes simply fold and head to the forum only to discover there is a page for the exact topic - which I just could not spot from the navigation bars.

    I can not tell you if it is just me or if others feel the same.
    In general your site seems very thorough put together and maintains a consistently high level across the board.

    Alas I have no solution to offer per se, other than maybe there could be some more cross-linking directly between pages, or perhaps adding tags to each page as iot-playground.com does, which is really helpful when narrowing down which pages could be relevant to visit next in search of a solution.


  • Admin

    @Ghydda

    Thanks for the feedback. Agree, hard to create a good navigation. Open for suggestions.


Log in to reply
 

Suggested Topics

  • 3
  • 2
  • 3
  • 2
  • 2
  • 10

1
Online

11.2k
Users

11.1k
Topics

112.5k
Posts