Throughput example

Hey!
 I am working with 2 nrf5340 boards(nrf5340 Audio-DK as peripheral and nrf534DK as Central) and am trying to send 12750 bytes of data at one second from Audio-DK to DK using the NUS service.

I was going through the Throughput example sample output and it shows, the server was able to send data at 1363kbps.


What were the configuration settings made to achieve this data rate?


What does "[peer] received 1242945 bytes (1213 KB) in 2511 GATT writes at 1415583 bps" mean ? Does it mean 495 bytes of data was sent 2511 times ?

For me to achieve my desirable data rate, ie 102Kbps, what change in settings am I supposed to do? Does increasing UART_BUF_SIZE help me achieve it?


Can you please help me out ?Your response will be of great help.

Regards
Thank you 

Parents
  • Hi Pallavi, 
    Have you tried to test with the sample ? 
    My suggestion is to take a look at the code to see how it works, pay attention to the test_run() function. 

    The data is sent by using GATT write without response. 

    I have made a blog here on how to improve throughput , please take a look:  Building a Bluetooth application on nRF Connect SDK - Part 3 Optimizing the connection 

  • Hey  

    I tested the sample and, also got to know the configuration settings used in the throughput sample.

     I am working with 2 nrf5340 boards(nrf5340 Audio-DK as peripheral and nrf534DK as Central) and am trying to send 12750 bytes of data at one second from Audio-DK to DK using the NUS service.

    I did some changes to the prj.conf on the peripheral side and observed that I am able to get the required no. of bytes at the central in almost 30 secs. 
    What change am I supposed to make to receive the data in 1 second? If not 1 second, what shoul I do to decrease the 30 seconds?

    Regards
    Thank you

  • Hi, 
    12750 bytes in 30 sec seems to be quite low throughput. 
    If you compare to the result you have with the throughput sample 1363kbps = 170kB/s  .
    So it's a lot slower than the sample. 
    Please follow my blog and check: 

    - connection interval

    - Data length extension

    - ATTMTU. 

    - How fast you queue your data

    - How you send your data, via notification or indication, via write or write with resposne. 

    You can try capture a sniffer trace so that it's easier to debug. 

    Note that if you are testing with nRF5340 you need to have a separate configuration for the network core. Please pay attention to the nrf5340dk_nrf5340_cpuapp.conf in boards folder. 

  • OK.

    Please follow my blog and check: 

    - connection interval

    - Data length extension

    - ATTMTU. 

    - How fast you queue your data

    - How you send your data, via notification or indication, via write or write with resposne. 


    The above mentioned configurations are to be done in the central side?


    You can try capture a sniffer trace so that it's easier to debug. 

    I do not have a sniffer board with me right now. Any other way to trace it?


    Note that if you are testing with nRF5340 you need to have a separate configuration for the network core. Please pay attention to the nrf5340dk_nrf5340_cpuapp.conf in boards folder. 

    The sample builds to both the Application and Network core in VS Code as shown below.


    Also, I do not have the nrf5340dk_nrf5340_cpuapp.conf in my sample code folder. How do I add that ?

    Regards
    Thank you

Reply
  • OK.

    Please follow my blog and check: 

    - connection interval

    - Data length extension

    - ATTMTU. 

    - How fast you queue your data

    - How you send your data, via notification or indication, via write or write with resposne. 


    The above mentioned configurations are to be done in the central side?


    You can try capture a sniffer trace so that it's easier to debug. 

    I do not have a sniffer board with me right now. Any other way to trace it?


    Note that if you are testing with nRF5340 you need to have a separate configuration for the network core. Please pay attention to the nrf5340dk_nrf5340_cpuapp.conf in boards folder. 

    The sample builds to both the Application and Network core in VS Code as shown below.


    Also, I do not have the nrf5340dk_nrf5340_cpuapp.conf in my sample code folder. How do I add that ?

    Regards
    Thank you

Children
  • Hi Pallavi, 
    If you are not so familiar with nRF Connect SDK and Bluetooth Low Energy. My suggestion is to go through our dev Academy here. I would suggest to try going through 2 courses: nRF Connect SDK fundamental and Bluetooth Low Energy fundamental: 
    https://academy.nordicsemi.com/

    pal_722 said:
    Also, I do not have the nrf5340dk_nrf5340_cpuapp.conf in my sample code folder. How do I add that ?

    Please put the file inside a boards folder in your project. Please refer to the throughput project folder. 

Related