STMicroelectronics / STM32CubeWB

Full Firmware Package for the STM32WB series: HAL+LL drivers, CMSIS, BSP, MW, plus a set of Projects (examples and demos) running on all boards provided by ST (Nucleo, Evaluation and Discovery Kits).
https://www.st.com/en/embedded-software/stm32cubewb.html
Other
227 stars 138 forks source link

aci_gatt_disc_all_primary_services sometime return 0xc #97

Closed huangliguang closed 2 months ago

huangliguang commented 3 months ago

You must power it on again to return 0x00

ALABSTM commented 3 months ago

Hi @huangliguang,

Would you mind providing more details about this issue please? We provide a template with different sections to fill with the relevant information. Thank you for your comprehension.

With regards,

huangliguang commented 3 months ago

code void Search_Service(void) { tBleStatus result; for(uint16_t idx = 0; idx < BLE_CFG_CLT_CONN_MAX_NUM; idx++) { if (server_Remote_Addr[idx].Req_Device_Connection_Status == APP_BLE_DISC_SERVICE_REQ) { uint16_t retry_count = 0x15ff; do { result = aci_gatt_disc_all_primary_services(server_Remote_Addr[idx].BleApplicationContext_legacy.connectionHandle); } while(result != BLE_STATUS_SUCCESS && retry_count--); server_Remote_Addr[idx].Req_Device_Connection_Status = APP_BLE_DISC_SERVICE_FINDING_REQ; if (result == BLE_STATUS_SUCCESS) { APP_DBG_MSG("* GATT : Start Searching Primary Services \r\n\r"); } else { APP_DBG_MSG("aci_gatt_disc_all_primary_services result 0x%x\r\n\r", result); } break; } } }

connectionHandle in debug mode value is not NULL,have value 0X80x

ALABSTM commented 2 months ago

Hi @huangliguang,

Please allow me to close this issue as the information provided is not easily understandable nor usable. Thank you for your comprehension.

With regards,