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.

怎样加设备到white list中?

Other Parts Discussed in Thread: CC2540

我知道可以通过gapRole_AdvFilterPolicy参数来控制只有white list中的手机才能连接BLE的设备,

但我一直没有搞清楚:怎样加设备到white list中呢?

望各位指教.

多谢

  • 论坛有类似问题,请参考回复: http://e2e.ti.com/support/wireless_connectivity/f/538/t/105830.aspx

  • 我按照他提供的方法再连接上之后直接调用HCI_LE_AddWhiteListCmd函数把手机h增加到white list中,但好像仍然无作用。

    我的想法是: 我的手机连到CC2540后,CC2540就通过HCI_LE_AddWhiteListCmd把连到的手机设备增加到white list中,之后再把gapRole_AdvFilterPolicy参数设置成GAP_FILTER_POLICY_WHITE,这样以后若再有其它手机想连接CC2540的话,因为没有在white list列表中,所以就不能连接了. 而我的手机在white list中,之后应该都可以正常连接才对. 但我通过上述的方法设置后,我自己的手机也无法连接了,好像根本没有增加到white list中一样?

    我的上述实现方法是否是正确的呢?

    谢谢!