Help understanding addressing and log messages



  • Hello to all,

    I'm new to this forum and find this project awesome!
    I've used the old RF24 library (maniacbug) for a long while. a lot of code lines now replaced by this great library.

    I've only some doubts and I'm really confused with logging. I've used an arduino as MQTT gateway. I'm seeing these messages on the serial console. Could someone explain me how to understand it correctly?

    Example1:
    0;0;3;0;9;read: 21-20-0 s=0,c=1,t=0,pt=7,l=5:16.7

    Example2:
    0;0;3;0;9;read: 20-20-0 s=5,c=1,t=1,pt=7,l=5:54.0

    Example3:
    0;0;3;0;9;send: 0-0-20-20 s=2,c=1,t=2,pt=0,l=1,st=ok:0

    Example4
    MyMQTT/21/3/V_HUM
    .>> 30 17 00 11 4D 79 4D 51 54 54 2F 32 31 2F 33 2F 56 5F 48 55 4D 34 37 2E 32
    This last should be MQTT a message.

    Thanks for help!

    Simon



  • Based on this: http://www.mysensors.org/build/serial_api

    Example 1
    id Node-id 0
    Child-id 0
    internal message
    no ack
    payload is type I_LOG_MESSAGE
    and your actual payload is "read: 21-20-0 s=0,c=1,t=0,pt=7,l=5:16.7"

    EDIT: I'm not sure if there is an easier place to get this, but I looked in the code for process where it prints "read" messages and found this to describe the payload. Send is also in there.

    msg.sender
    -msg.last
    -msg.destination
    s=msg.sensor
    c=mGetCommand(msg)
    t=msg.type
    pt=mGetPayloadType(msg)
    l=mGetLength(msg)
    :msg.getString(convBuf));



  • @pete1450 said:

    Based on this: http://www.mysensors.org/build/serial_api

    Example 1
    id Node-id 0
    Child-id 0
    internal message
    no ack
    payload is type I_LOG_MESSAGE
    and your actual payload is "read: 21-20-0 s=0,c=1,t=0,pt=7,l=5:16.7"

    EDIT: I'm not sure if there is an easier place to get this, but I looked in the code for process where it prints "read" messages and found this to describe the payload. Send is also in there.

    Mysensor.cpp Line 221-222


Log in to reply
 

Suggested Topics

18
Online

11.4k
Users

11.1k
Topics

112.7k
Posts