# Security Manager mode # none - Security manager disabled # auto - Use local PIN for incoming connections # user - Always ask user for a PIN # #修改成auto模式 security auto;
# Pairing mode # none - Pairing disabled # multi - Allow pairing with already paired devices # once - Pair once and deny successive attempts pairing multi;
# Default link mode # none - no specific policy # accept - always accept incoming connections # master - become master on incoming connections, # deny role switch on outgoing connections lm accept;
# Default link policy # none - no specific policy # rswitch - allow role switch # hold - allow hold mode # sniff - allow sniff mode # park - allow park mode lp rswitch,hold,sniff,park; }
2.配置完成後,重啟藍牙服務 sudo /etc/init.d/bluetooth restart
3.手機連接PC端藍牙設備,完成匹配,匹配時需要輸入hcid.conf中的匹配碼
4.配置/etc/bluetooth/rfcomm.conf
# # RFCOMM configuration file. #
rfcomm0 { # Automatically bind the device at startup bind yes;
# Bluetooth address of the device # 手機端的藍牙地址可以通過hcitool scan獲得 device 00:18:0F:8B:B0:63;
# RFCOMM channel for the connection channel 1;
# Description of the connection comment "NOKIA 5500 Bluetooth device"; }