1414 * limitations under the License.
1515 */
1616
17- #include "nimble_store.h"
18-
19- #include <stdlib.h>
20-
17+ #include <FreeRTOS.h>
2118#include <bluetooth/init.h>
2219#include <comm/bt_lock.h>
23- #include <kernel/pebble_tasks.h>
24- #include <os/tick.h>
25- #include <system/logging.h>
26- #include <system/passert.h>
27-
28- #include <FreeRTOS.h>
29- #include <semphr.h>
30-
3120#include <host/ble_hs.h>
3221#include <host/ble_hs_stop.h>
3322#include <host/util/util.h>
23+ #include <kernel/pebble_tasks.h>
3424#include <nimble/nimble_port.h>
25+ #include <os/tick.h>
26+ #include <semphr.h>
3527#include <services/dis/ble_svc_dis.h>
3628#include <services/gap/ble_svc_gap.h>
3729#include <services/gatt/ble_svc_gatt.h>
30+ #include <stdlib.h>
31+ #include <system/logging.h>
32+ #include <system/passert.h>
33+
34+ #include "nimble_store.h"
3835
3936static const uint32_t s_bt_stack_start_stop_timeout_ms = 2000 ;
4037
@@ -67,9 +64,7 @@ static void prv_host_task_main(void *unused) {
6764 nimble_port_run ();
6865}
6966
70- static void prv_ble_hs_stop_cb (int status , void * arg ) {
71- xSemaphoreGive (s_host_stopped );
72- }
67+ static void prv_ble_hs_stop_cb (int status , void * arg ) { xSemaphoreGive (s_host_stopped ); }
7368
7469// ----------------------------------------------------------------------------------------
7570void bt_driver_init (void ) {
@@ -94,11 +89,11 @@ void bt_driver_init(void) {
9489
9590#if NIMBLE_CFG_CONTROLLER
9691 TaskParameters_t ll_task_params = {
97- .pvTaskCode = nimble_port_ll_task_func ,
98- .pcName = "NimbleLL" ,
99- .usStackDepth = (configMINIMAL_STACK_SIZE + 400 ) / sizeof (StackType_t ),
100- .uxPriority = (configMAX_PRIORITIES - 1 ) | portPRIVILEGE_BIT ,
101- .puxStackBuffer = NULL ,
92+ .pvTaskCode = nimble_port_ll_task_func ,
93+ .pcName = "NimbleLL" ,
94+ .usStackDepth = (configMINIMAL_STACK_SIZE + 600 ) / sizeof (StackType_t ),
95+ .uxPriority = (configMAX_PRIORITIES - 1 ) | portPRIVILEGE_BIT ,
96+ .puxStackBuffer = NULL ,
10297 };
10398
10499 pebble_task_create (PebbleTask_BTController , & ll_task_params , & s_ll_task_handle );
0 commit comments