Sensbender Micro and v2.2 library



  • I have a somewhat modified sketch based on the Sensebender Micro sketch and this one failed to compile when changing to the v2.2 library. So I copied the original sketch from the homepage and also this one fails to compile when enabling MY_DEBUG. The error messages are numerous so it is pointless to add them here but a couple of examples are:

    \Arduino\libraries\MySensors-master-v220_180209/core/MyOTAFirmwareUpdate.cpp:63:41: error: expected ')' before 'PRIX16'

    OTA_DEBUG(PSTR("OTA:FRQ:FW REQ,T=%04" PRIX16 ",V=%04" PRIX16 ",B=%04" PRIX16 "\n"),

    \Arduino\libraries\MySensors-master-v220_180209/MyConfig.h:1815:43: note: in definition of macro 'DEBUG_OUTPUT'

    #define DEBUG_OUTPUT(x,...) hwDebugPrint(x, ##VA_ARGS) //!< debug

    \Arduino\libraries\MySensors-master-v220_180209/core/MyOTAFirmwareUpdate.cpp:63:3: note: in expansion of macro 'OTA_DEBUG'

    OTA_DEBUG(PSTR("OTA:FRQ:FW REQ,T=%04" PRIX16 ",V=%04" PRIX16 ",B=%04" PRIX16 "\n"),

    As this is in the core code it is something I am unable to figure out myself, unfortunately. But as the compilation runs through without problems when disabling MY_DEBUG it is not any mayor issue until the debug output is needed.



  • What version of the Arduino IDE are you using? I Had a similar problem but I solved that with updating the IDE to the latest version (1.8.5).



  • @davidzh Do not know what is going on with my browser, I have replied to your question but cannot see this reply anywhere. Also i did not receive any notification about your question so my reply is late, sorry.
    The issue showed up when compiling for library version 2.2 on Arduino 1.6.12. I will test with the latest version as you suggest, thank's a lot for the info.



  • @davidzh A change to 1.8.5 did not help. But disabling My_Debug still works so the problem is not critical.
    For the sake of clarity I have also tested with an unmodified Sensebender sketch and also this one gets compilation errors when enabling My_Debug. So the problem comes from the implementation of the debug code.



  • @mbj No problem!

    Actually, I've encountered another issue. But I found that that may depend on the bootloader.

    The first time I "solved" the problem was another board with a generic 328p breadboard bootloader (I apparently didn't pay attention when burning the BL for the various boards)

    Last week I had a problem with a board with the Gert Sanders 328p bootloader when I couldn't enable the MY_DEBUG. When I changed the board type it compiled, but wouldn't upload because of the differences in baud rate.

    I will probably have to reflash al boards withe the same bootloader but that means de-solder all radios ... 😣

    When I have time again I will investigate further.


 

366
Online

7.8k
Users

8.7k
Topics

93.0k
Posts