CH592 CH582 CH573添加广播回调函数

/*********************************************************************
 * @fn      BLE_AdvertiseEventCB
 *
 * @brief   Callback from advertise over
 *
 * @param   None
 *
 * @return  none
 */
void BLE_AdvertiseEventCB( uint32_t timeUs )
{
    GPIOA_ResetBits(GPIO_Pin_4);
  PRINT("timeUs %d=\n",timeUs);
  PRINT("Current RTC-Cnt= %d  \n",RTC_GetCycle32k());
  GPIOA_SetBits(GPIO_Pin_4);
}

 声明函数

 函数调用

LL_AdvertiseEventRegister(BLE_AdvertiseEventCB);

 

 运行结果

 

posted @ 2024-07-02 16:18  debugdabiaoge  阅读(26)  评论(0编辑  收藏  举报