verjus commented on issue #552: URL: https://github.com/apache/mynewt-nimble/issues/552#issuecomment-703295854
Thank you for taking the time to answer my question. This is very helpful. I thought there was something wrong with my fragmentation code. For now, I will increase the value of MSYS_1_BLOCK_COUNT as you suggested, which is indeed set by default to (12). This explains why I am failing at packet 13. Meanwhile, I read in [this](https://github.com/espressif/esp-idf/issues/4328) post that os_msys_num_free() can be used to monitor the number of available free blocks. The same post suggests monitoring this value before sending the next notification. I may try to change my code accordingly to determine when the number of free blocks has increased before sending the next batch of notifications. This adds a lot of complexity but would ensure that the code keeps working with small MTUs and relatively large buffers. I wonder if this logic should be incorporated as a feature in NimBLE, i.e. automatically and transparently fragment and send a long notification based on the negotiated MTU. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
