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

NCS NUS example - bigger buffer

Hi,
I have two Nordic BLE devices, one nrf52-DK that has peripherial_uart application and nrf52840-DK that has central_uart application. This works well, but the thing I need to change is buffer size (from central to peripheral) which is set to 20 bytes by default. I need it to be much bigger, around 500 bytes. This is because I need it to send more data et once, and not 20 my 20 bytes. 

I have managed to change this on the peripherial_uart application size in the Kconfig file so now buffer on the peripheral side is 1024. On the central size I have tried changing buffer size in the main file: #define UART_BUF_SIZE 20, from 20 to something bigger, but I get a fault when try to send data that is bigger than 20 bytes. 

What else needs to be done besides just increasing buffer size on both applications? I suppose there is something with BLE or NUS?

I am using Ubuntu 18.04LTS and NCS v1.2.0

Best regards,
Vojislav.

Parents
  • So when I want to send a bigger data packet (with code changed in central application) I get a response:

    E: ***** BUS FAULT *****␍␊
    [13:03:07:755] E:   Precise data bus error␍␊
    [13:03:07:755] E:   BFAR Address: 0x1000257␍␊
    [13:03:07:761] E: r0/a1:  0x00000010  r1/a2:  0x01000257  r2/a3:  0x00001010␍␊
    [13:03:07:761] E: r3/a4:  0x01000257 r12/ip:  0x00000003 r14/lr:  0x00002ec3␍␊
    [13:03:07:769] E:  xpsr:  0x21000000␍␊
    [13:03:07:769] E: Faulting instruction address (r15/pc): 0x00002ec4␍␊
    [13:03:07:776] E: >>> ZEPHYR FATAL ERROR 0: CPU exception on CPU 0␍␊
    [13:03:07:784] E: Current thread: 0x200010b4 (unknown)␍␊
    [13:03:07:784] E: Resetting system␍␊

Reply
  • So when I want to send a bigger data packet (with code changed in central application) I get a response:

    E: ***** BUS FAULT *****␍␊
    [13:03:07:755] E:   Precise data bus error␍␊
    [13:03:07:755] E:   BFAR Address: 0x1000257␍␊
    [13:03:07:761] E: r0/a1:  0x00000010  r1/a2:  0x01000257  r2/a3:  0x00001010␍␊
    [13:03:07:761] E: r3/a4:  0x01000257 r12/ip:  0x00000003 r14/lr:  0x00002ec3␍␊
    [13:03:07:769] E:  xpsr:  0x21000000␍␊
    [13:03:07:769] E: Faulting instruction address (r15/pc): 0x00002ec4␍␊
    [13:03:07:776] E: >>> ZEPHYR FATAL ERROR 0: CPU exception on CPU 0␍␊
    [13:03:07:784] E: Current thread: 0x200010b4 (unknown)␍␊
    [13:03:07:784] E: Resetting system␍␊

Children
No Data
Related