Closed TMRh20 closed 1 year ago
Did you try using null_ptr
instead?
NM, I think use of null_ptr
might need a void*
parameter type.
I just tested using nullptr
and same behaviour. I think because its a null value, the device has nowhere to put the data, so it causes an overflow & subsequent crash. Took me forever to track this down too. Pretty sure it would be a good idea to change in RF24 as well.
It is also good that you initialized the var to 0. This would be needed for consistent behavior in pyRF24 wrapper as well.
I just identified an issue with crashing, but it only seems to affect my new Feather 82450 Express board, not my XIAO BLE Sense board. In any case, it has to do with requesting a NULL value for pipe number in the
available()
function. On the Feather anyway, changing it to use a defined variable fixes the crashing. Logging this issue because it may also affect the RF24 library on different boards, it uses the same behaviour. Fix incoming.