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

nrf nus service cpu bandwidth usage as peripheral

pca10040 S132 5.1.0

if i run only a single nrf nus service (rx and tx) at 4 k bytes / sec both directions, how much load would this put on the 52832

the test is assuming simple pass through from bluetooth to serial

i need to evaluate how much cpu bandwidth would be left for the main application ... in this application bluetooth is only communicating to an android human control interface and data logger at the above rate ... the serial port in the app will be used for debug only

the main app will be busy providing parallel pulse train input capture and altered timing output with some calculations on a pulse by pulse basis

it also crunches numbers based upon adc inputs and also provides some pwm outs

my question is to evaluate the raw cpu load with only 4k bytes going in and out via bluetooth at the same time with no other activities

cheers Klaus

Parents Reply Children
  • one of my application will need a certain amount of cpu bandwidth in order to fulfill it's functionality, like reading injector pulses and outputting them again, otherwise the engine stops ... most of it will be handled in high prio isrs (not as high as the nrf radio isrs) and some other isrs and some stuff will run at the main loop level

    i have no real estimate of how much this will take and would not know in which measurement units i would express this

    a previous product was based upon an ARM7TDMI-S cpu (lpc2148) and it ran fine ... had plenty of cpu left, based upon the main loop frequ.

    since the unit is vehicle battery powered, i'm not worried about sleep or similar power saving options ... also my main loop test-setup is not setup to support sleeping at the moment

    is there any cpu bandwidth measurement available to correlate a certain bit-rate in and out with no retries and cpu load % value ... and then how much does it degrade on a certain % of retries

    since there is a practical max ble data rate for a single connection, or the whole radio, there should be a cpu on vs sleep % available for it ... one would think ???

    it's hard to believe that i'm the only one asking for this ... yes there are apps where the cpu sleeps most of the time, but mine can't be the only one where the data throughput is the important factor and what's left over after all the data flow is handled

    i suppose i could measure (estimate) it in a similar way by having a simple main loop freq measurement without ble connected and then connect and load the cpu with specified data in and out rates and see how the main loop frequ drops

    any supporting thoughts are always highly appreciated

    cheers Klaus

  • Maybe this blog is of interest: Instrumenting with Segger SystemView.

    You can find some information about the Softdevice's CPU usage here: Processor usage patterns and availability

Related