问题如题
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.
抱歉,确实没看清。
用GapSetParmValue()设置GAPROLE_ADV_DIRECT_ADDR就可以了,举个栗子:
uint8_t advEvType = GAP_ADTYPE_ADV_LDC_DIRECT_IND; GAPRole_SetParameter(GAPROLE_ADV_EVENT_TYPE, sizeof(uint8_t), &advEvType); uint8_t myFriend[B_ADDR_LEN] = {0x57, 0xE6, 0xD4, 0xF7, 0xB1, 0x34}; // address is 0x34B1F7D4E657 GAPRole_SetParameter(GAPROLE_ADV_DIRECT_ADDR, B_ADDR_LEN, &myFriend);我刚刚测试了,设置了定向广播,确定该地址以外的设备都搜索不到了,
我还想请教一个问题,我在看资料是看到以下参数
LE_Scan_Type
|
0x00 |
Passive scanning(被动扫描),不会发送扫描请求包(SCAN_REQ)(Default) |
|
0x01 |
Active scanning(主动扫描),可发送扫描请求包(SCAN_REQ) |
|
0x02 – 0xFF |
Reserved for future use |
这个参数主机端在哪里设置,我去查找没有查找到,谢谢!