limitations for threads ?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
ritu_2178811
Level 3
Level 3
5 likes given First like received First like given

Hello,

I am extending the snip / bluetooth / bt_dualmode_server for my own needs. While creating threads, I noticed 2 strange behaviours.

1) In initialize(&sWrap) function, I create 3 threads and if I give a delay later on, the system gets stuck. If I comment out the delay, threads run fine

void application_start()

{

   ...

   initialize(&sWrap);

   wiced_rtos_delay_milliseconds(100); // comment out this and threads run fine, otherwise system gets stuck

}

2) When I enable the bluetooth stack, some of the threads fail to start, I solved this error by decreasing the stack size to 5000 from the default value. Is this normal or do I miss some other thing? I have 3 threads and my platform is redbear duo and I am using SDK 3.7.0

    wiced_bt_stack_init( bt_dualmode_server_management_cback, &wiced_bt_cfg_settings, wiced_bt_cfg_buf_pools );

    initialize(&sWrap);

  }

I would be happy if you can guide me about this

rifo

0 Likes
1 Solution
Anonymous
Not applicable

Hi rifo,

Could you kindly try with the latest version of WICED which is 5.1. There is a high probability that you might not see this issue with the newer versions.

View solution in original post

0 Likes
1 Reply
Anonymous
Not applicable

Hi rifo,

Could you kindly try with the latest version of WICED which is 5.1. There is a high probability that you might not see this issue with the newer versions.

0 Likes