Code: Select all
uint16_t rawCodes[] = {2550, 950, 350, ……., 600, 300};
So maybe I have something wrong with the method called, or I should call another method to send data. I hope you can give me some suggestion on how to send the data without delay, thank you very much!
This is my code that I call the method "esp_ble_gattc_write_char()" to send my data(rawCodes):
Code: Select all
sendData(conn_id, (uint8_t*)&rawCodes, sizeof(rawCodes));
void sendData(uint16_t conn_id, uint8_t *value, uint16_t len) {
esp_ble_gattc_write_char(
4,
conn_id,
&service_id,
&tx_rx_id,
len,
value,
ESP_GATT_WRITE_TYPE_RSP,
ESP_GATT_AUTH_REQ_NONE);
}
Code: Select all
**********************GATT CALLBACK 4**************************
WRITE: status 0
sending...
E (220278) BT: value resp op_code = ATT_RSP_PREPARE_WRITE len = 22
E (220378) BT: value resp op_code = ATT_RSP_PREPARE_WRITE len = 22
E (220478) BT: value resp op_code = ATT_RSP_PREPARE_WRITE len = 22
E (220578) BT: value resp op_code = ATT_RSP_PREPARE_WRITE len = 22
E (220678) BT: value resp op_code = ATT_RSP_PREPARE_WRITE len = 16