This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Bug: infinite loop when using the mesh advertiser

Using: NRF52832, SD 132 6.1.1, SDK 15.3.0, Mesh SDK 3.1.0.

I started using the mesh SDK advertiser, with a single advertisement packet with infinite repeats, and that got my app to gets stuck in an infinite loop in packet_buffer.c at packet_buffer_packets_ready_to_pop().

I fixed this by slightly increasing the buffer size i give to advertiser_instance_init(). Size was set to ADVERTISER_PACKET_BUFFER_PACKET_MAXLEN, now i just added a few bytes.

I guess there should either be a check for the buffer size, or a check in the while loop.

PS: RADIO_POWER_NRF_NEG30DBM is 0xD8, shouldn't that be 0xE2 instead?

Related