Skip to content

Commit

Permalink
Update NimBLE core version to esp-nimble 1.4.0 @3c2e1d4
Browse files Browse the repository at this point in the history
  • Loading branch information
h2zero committed May 29, 2022
1 parent 5a8f786 commit 8bc6813
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,6 @@ struct ble_npl_event;
typedef void ble_npl_event_fn(struct ble_npl_event *ev);

struct ble_npl_event {
#if CONFIG_BT_NIMBLE_USE_ESP_TIMER
ble_npl_event_fn *fn;
#endif
void *event;
};

Expand Down
12 changes: 6 additions & 6 deletions src/nimble/porting/npl/freertos/src/npl_os_freertos.c
Original file line number Diff line number Diff line change
Expand Up @@ -771,10 +771,9 @@ IRAM_ATTR npl_freertos_callout_init(struct ble_npl_callout *co, struct ble_npl_e
PLATFORM_BLE_LL_ASSERT(callout);

memset(callout, 0, sizeof(*callout));
ble_npl_event_init(&callout->ev, ev_cb, ev_arg);

#if CONFIG_BT_NIMBLE_USE_ESP_TIMER
callout->ev.fn = ev_cb;
callout->ev.event = ev_arg;
callout->evq = evq;

esp_timer_create_args_t create_args = {
Expand All @@ -793,6 +792,8 @@ IRAM_ATTR npl_freertos_callout_init(struct ble_npl_callout *co, struct ble_npl_e
} else {
callout = (struct ble_npl_callout_freertos *)co->co;
PLATFORM_BLE_LL_ASSERT(callout);
callout->evq = evq;
ble_npl_event_init(&callout->ev, ev_cb, ev_arg);
}
#else

Expand All @@ -802,10 +803,9 @@ IRAM_ATTR npl_freertos_callout_init(struct ble_npl_callout *co, struct ble_npl_e
PLATFORM_BLE_LL_ASSERT(callout);

memset(callout, 0, sizeof(*callout));
ble_npl_event_init(&callout->ev, ev_cb, ev_arg);

#if CONFIG_BT_NIMBLE_USE_ESP_TIMER
callout->ev.fn = ev_cb;
callout->ev.event = ev_arg;
callout->evq = evq;

esp_timer_create_args_t create_args = {
Expand All @@ -824,11 +824,11 @@ IRAM_ATTR npl_freertos_callout_init(struct ble_npl_callout *co, struct ble_npl_e
else {
callout = (struct ble_npl_callout_freertos *)co->co;
PLATFORM_BLE_LL_ASSERT(callout);
callout->evq = evq;
ble_npl_event_init(&callout->ev, ev_cb, ev_arg);
}
#endif

callout->evq = evq;
ble_npl_event_init(&callout->ev, ev_cb, ev_arg);
}

void
Expand Down

0 comments on commit 8bc6813

Please sign in to comment.