Like several others on here, I’m trying to make a multilink nus central firmware. My Peripheral devices run the ble_app_uart example, and the central device runs a modified multilink example that includes the ble UART service. My code is based on Adam’s form here
Hardware: x3 NRF52832 boards. (1 Central, 2 identical Peripherals)
Here is my code
To view my code, download and copy to the original SDK location (nRF5_SDK_14.2.0_17b948a/examples/ble_central/).
The only modified library was the nus header which can be found here.
In summary, everything compiles, and I can get multiple UART peripherals to correctly connect to a single Central device.
When I send UART data from any peripheral, the central correctly receives the data. However, when the Central tries to echo the message back to the peripheral (or send any UART message to the peripherals), the Central sends a single byte, then crashes with this error:
<error> app: ERROR 4 [NRF_ERROR_NO_MEM].
See below for a complete terminal
After debugging the NRF_ERROR_NO_MEM in the central code, it stems from a NRF_ERROR_SVC_HANDLER_MISSING whenever the Central tries to transmit.
I’m at a loss here. There have been several forms with people trying to make a multilink NUS, and I’ll happily share my final code for others reference if we figure this out.
I have downloaded your code, added the ble_nus_c.h header file & included the file in the preprocessor field in SES, but I receive an error m_ble_nus_c undeclared. Where is m_ble_nus_c first defined?
Thank you for the fast reply. You are correct; I tried downloading from scratch from a different computer and got your same error. Something else in my SDK must have been altered.
As a temporary fix, here is my entire current SDK (V14.2). I just checked, this compiles just fine. Please use this to troubleshoot in the meantime. Thank you again for the help!
Complete SDK (V14.2)
Have you had any luck with this? Please let me know!
It seems the NRF_ERROR_SVC_HANDLER_MISSING is related to wrong softdevice header files (see link). Can you confirm that you are using the s132 v5.0.0 softdevice? This link might also be useful.
That did it, thank you Bjorn. My version was correct, but I restarted the project anyway and made sure to pull all the needed UART headers from the correct softdevice. Everything is working now. Thank you!