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

How to increase stack memory allocation to number of threads in RTX?

Hello All,

I am using nRF51822 with SDKv10.0.0 and s110 soft device with RTX os. My project have 5 different threads with 1000 bytes of memory is needed in each thread. While RTX_Conf_CM.c file have settings to run only 3 concurrent threads and only 400 bytes of memory to main thread so somehow I am not able to run RTX os with my project due to 5 number of threads and high amount of memory(1000 bytes for each) is needed for each thread. So how can I resolve this issue? What kind of configuration settings are needed for RTX os in my case?

Please help me as soon as possible as I am critically depends on it. Thanks in advance!

Parents
  • Hi Ethan

    If you want to have 5 threads each with 1000 bytes, then I suspect it is hard to execute that on a nRF51822 QFAA (16kB RAM), but should be well possible with nRF51822 QFAC (32kB RAM). When I configure the ble_app_hrs_rtx application to have 5 threads and 1000 bytes each I get around 11kB of RAM used. The S110 softdevice uses 8kB, so total use should be 8kB+11kB = 19kB.

    If you have an application with smaller profile than the ble_app_hrs_rtx sample application, I suspect it should consume less RAM, but perhaps still over 16kB, Im not sure.

Reply
  • Hi Ethan

    If you want to have 5 threads each with 1000 bytes, then I suspect it is hard to execute that on a nRF51822 QFAA (16kB RAM), but should be well possible with nRF51822 QFAC (32kB RAM). When I configure the ble_app_hrs_rtx application to have 5 threads and 1000 bytes each I get around 11kB of RAM used. The S110 softdevice uses 8kB, so total use should be 8kB+11kB = 19kB.

    If you have an application with smaller profile than the ble_app_hrs_rtx sample application, I suspect it should consume less RAM, but perhaps still over 16kB, Im not sure.

Children
No Data
Related