Setup notification with AT commands

RickARM
Posts: 4
Joined: Tue Jun 06, 2023 6:23 pm

Setup notification with AT commands

Postby RickARM » Tue Jun 06, 2023 6:32 pm

I am trying to set up notification like this link:
https://docs.espressif.com/projects/esp ... mples.html

Notify of a characteristic:

ESP32 Client:(1) Configure the characteristic’s descriptor. Please note that the target characteristic’s property has to support notifications.

AT+BLEGATTCWR=0,3,6,1,2

Response:
> // waiting for data
OK



However it is unclear what data to send. I think notification is 0x01 so I have tried:

HW_UART_PutString(BLE_UART, "AT+BLEGATTCWR=0,3,1,1,2\r\n"); // notification
HW_TIM_Delay(500);
HW_UART_PutChar(BLE_UART, 0x00);
HW_UART_PutChar(BLE_UART, 0x01);

and

HW_UART_PutString(BLE_UART, "AT+BLEGATTCWR=0,3,1,1,2\r\n");
HW_TIM_Delay(500);
HW_UART_PutChar(BLE_UART, 0x01);
HW_UART_PutChar(BLE_UART, 0x00);

Both of them give ERROR.

GATT looks like
AT+BLEGATTCCHAR=0,3
+BLEGATTCCHAR:"char",0,3,1,0x442F15718A009A28CBE1E1D4212D53EB,0x12 //read notify
+BLEGATTCCHAR:"desc",0,3,1,1,0x2902
+BLEGATTCCHAR:"char",0,3,2,0x442F15728A009A28CBE11D4212D53EB,0x1c // write
+BLEGATTCCHAR:"desc",0,3,2,1,0x2902

And my understanding is that descriptor 0x2902 shall be used for set up notificaiton on a GATT characterstic 0x442F15718A009A28CBE1E1D4212D53EB.

I am using this firmware:
AT+GMR
AT version:2.4.0.0(4c6eb5e - ESP32 - May 20 2022 03:11:58)
SDK version:qa-test-v4.3.3-20220423
compile time(5641e0a):May 20 2022 11:12:05
Bin version:2.4.0WROOM-32)

Can some one help me understand what I am doing wrong?

ESP_Sun
Posts: 288
Joined: Thu Dec 30, 2021 9:52 am

Re: Setup notification with AT commands

Postby ESP_Sun » Mon Jun 12, 2023 8:36 am

Hi,

Maybe you can provide your modified ble_data file?

RickARM
Posts: 4
Joined: Tue Jun 06, 2023 6:23 pm

Re: Setup notification with AT commands

Postby RickARM » Mon Jun 12, 2023 11:49 am

Can you clarify what you mean by modified ble_data file?

Who is online

Users browsing this forum: No registered users and 54 guests