h2zero / n-able-Arduino

An arduino core for ARM based BLE devices supported by the NimBLE stack.
GNU Lesser General Public License v2.1
35 stars 14 forks source link

NRF52810 Notify Limited By CONFIG_BT_NIMBLE_MSYS1_BLOCK_COUNT #53

Closed jackb60 closed 2 months ago

jackb60 commented 2 months ago

I am using a NRF52810 with <NimBLEDevice.h> and when an attempt is made to notify with a characteristic length of greater than 339 bytes, the central does not recieve the data and onStatus indicates a return code of 6 (operation failed due to resource exhaustion). That may also be the case with other operations but I only tested notify.

I was able to get it working by changing line 13 in nrf52810_nimconfig.h from

#define CONFIG_BT_NIMBLE_MSYS1_BLOCK_COUNT (8) to #define CONFIG_BT_NIMBLE_MSYS1_BLOCK_COUNT (12)

h2zero commented 2 months ago

That's exactly the correct solution 👍. Please see my comment here for a per sketch configuration solution to this.

Per my comment there you would add this: -DCONFIG_BT_NIMBLE_MSYS1_BLOCK_COUNT=12 to the build_opt.h file.

https://github.com/h2zero/n-able-Arduino?tab=readme-ov-file#configuration-optional