请问MULTI_ROLE工程中CC2640R2F作为主机发起连接,调用GAPRole_EstablishLink(DEFAULT_LINK_HIGH_DUTY_CYCLE, DEFAULT_LINK_WHITE_LIST,HCI_PUBLIC_DEVICE_ADDRESS, adress)函数后程序就卡死了,有没有大佬遇见过这个问题
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
请问MULTI_ROLE工程中CC2640R2F作为主机发起连接,调用GAPRole_EstablishLink(DEFAULT_LINK_HIGH_DUTY_CYCLE, DEFAULT_LINK_WHITE_LIST,HCI_PUBLIC_DEVICE_ADDRESS, adress)函数后程序就卡死了,有没有大佬遇见过这个问题
提供一下返回值:
SUCCESS : started establish link process
bleIncorrectMode : invalid profile role
bleNotReady : a scan is in progress
bleAlreadyInRequestedMode : can�t process now
bleNoResources : too many links
此外你修改了multi_role中的什么程序吗?
原始建立连接code如下:
bool mr_doConnect(uint8_t index)
{
// If already connecting...cancel
if (connecting == TRUE)
{
// Cancel connection request
GAPRole_TerminateConnection(GAP_CONNHANDLE_INIT);
Display_print0(dispHandle, MR_ROW_STATUS1, 0, "Connecting Cancelled");
// Clear connecting flag
connecting = FALSE;
}
// If attempting to connect
else
{
// Connect to current device in scan result
GAPRole_EstablishLink(DEFAULT_LINK_HIGH_DUTY_CYCLE,
DEFAULT_LINK_WHITE_LIST,
devList[index].addrType, devList[index].addr);
// Set connecting state flag
connecting = TRUE;
Display_print0(dispHandle, MR_ROW_STATUS1, 0, "Connecting to:");
Display_print0(dispHandle, MR_ROW_STATUS2, 0, (char*)devList[index].strAddr);
}
return TRUE;
}
您好,高手,你调用此GAPRole_EstablishLink函数卡死是什么原因啊?
我现在也遇到同样的问题了,扫到需要的mac时,在去调用GAPRole_EstablishLink连接时,就连不上了,但程序没有完全死掉,但断开连接api也不起作用、定时器也不起作用了。扫描api也出问题了,感觉协议栈被损坏了一样。api都不起作用了。