fix(ble): Perform GATT notifies from dedicated queue.

* Zephyr BT stack frees TX buffers from system workqueue,
  and to avoid blocking waiting to allocate, perform notify
  from a dedicated queue.
This commit is contained in:
Pete Johanson
2020-12-03 16:04:48 -05:00
parent 4aa78a6f8d
commit a5c39dfa76
3 changed files with 123 additions and 18 deletions

View File

@@ -57,8 +57,9 @@ void peripheral_event_work_callback(struct k_work *work) {
K_WORK_DEFINE(peripheral_event_work, peripheral_event_work_callback);
static uint8_t split_central_notify_func(struct bt_conn *conn, struct bt_gatt_subscribe_params *params,
const void *data, uint16_t length) {
static uint8_t split_central_notify_func(struct bt_conn *conn,
struct bt_gatt_subscribe_params *params, const void *data,
uint16_t length) {
static uint8_t position_state[POSITION_STATE_DATA_LEN];
uint8_t changed_positions[POSITION_STATE_DATA_LEN];