[SOLVED] NRF24 Sniffer and V2.1 Library



  • Re: 💬 NRF24 Sniffer

    I have been using Version 1.51 very successfully with the sniffer, but when upgrading to V2.1 I find that the (v1.51) sniffer doesn't see any traffic anymore even though the PAN-ID and RF channels match in the config files.

    What has changed at the RF link layer that makes the sniffer not detect any traffic and what do I have to do to it to make it work again?
    tnx



  • And I forgot to mention that the data rate in the sniffer and the network match as well..


  • Mod

    @GaryStofer It should at least detect the raw nRF packages, as these remain unchanged with different MySensors versions.
    Is the hardware used identical in your new setup?

    You could try compiling the sniffer swketch with 'BINARY_OUTPUT' not defined so the output of the sniffer can be observed as text in the serial console.



  • @Yveaux So I found the problem now.

    The disconnect between the sniffer and the network running V2.1 stemmed from the change in the way the NETWORK_BASE_ID is defined.

    In the sniffer and V1.51 of the lib it is defined as a single uint64_t but in the V2.1 lib it is defined as a list of 5 individual bytes which are then later used to initialize a 5 byte char array via a macro.

    Since earlier I had chosen a different NETWORK_BASE_ID from the default this uint64_t defined ID was now used to initialize the 5 byte array, except of course that only the first location got assigned anything. Luckily all of this happened without a compiler warning or error...

    After I changed the NETWORK_BASE_ID in my nodes & gateway to use the 5 individual bytes format in the correct order everybody is all :smile: again. Even my V1.51 sensors that have not been recompiled yet seem to be just fine with the network.

    Thanks


  • Mod

    @GaryStofer well, great to hear you nailed it!


Log in to reply
 

Looks like your connection to MySensors Forum was lost, please wait while we try to reconnect.