... | ... | @@ -43,6 +43,37 @@ udhcpc -i mlan0 |
|
|
> input name: AnWBT (for example)
|
|
|
...
|
|
|
```
|
|
|
|
|
|
## set device adress
|
|
|
```
|
|
|
================bluetooth menu=================
|
|
|
...
|
|
|
4.SetLocalDevAddrOrName
|
|
|
...
|
|
|
===============================================
|
|
|
> input num: 4
|
|
|
0.set local name
|
|
|
1.set local address
|
|
|
> 1
|
|
|
> input addr(xx:xx:xx:xx:xx:xx): 48:b8:a3:d5:8f:33 (for example)
|
|
|
...
|
|
|
```
|
|
|
## view version
|
|
|
```
|
|
|
================bluetooth menu=================
|
|
|
...
|
|
|
6.View version
|
|
|
...
|
|
|
===============================================
|
|
|
> input num:6
|
|
|
```
|
|
|
you can get the message of version
|
|
|
```
|
|
|
--------------------------------------
|
|
|
Version:1000111
|
|
|
--------------------------------------
|
|
|
```
|
|
|
|
|
|
## power on init
|
|
|
```
|
|
|
================bluetooth menu=================
|
... | ... | @@ -114,54 +145,9 @@ AnWBTSERVICE_NEW_DEVICE_FOUND name[CSR - bc7] devclass[2098184] |
|
|
input num: 3
|
|
|
...
|
|
|
```
|
|
|
When StartInquiry is running, execute StopInquiry immediately and stop inquiry
|
|
|
## pair response
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
4.PairResponse
|
|
|
...
|
|
|
===============================================
|
|
|
input num: 4
|
|
|
...
|
|
|
```
|
|
|
|
|
|
## set pin code
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
5.SetPinCode
|
|
|
...
|
|
|
===============================================
|
|
|
input num: 5
|
|
|
input pincode:1111
|
|
|
```
|
|
|
## set local DevCoD
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
6.SetLocalDevCoD
|
|
|
...
|
|
|
===============================================
|
|
|
input num:6
|
|
|
input devClass:7995916
|
|
|
```
|
|
|
## get local OOB data
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
7.GetLocalOOBData
|
|
|
...
|
|
|
===============================================
|
|
|
input num:7
|
|
|
...
|
|
|
```
|
|
|
Note:then you can get the respond message from log,"status[0]" indicates success,for example
|
|
|
```
|
|
|
AnWBTService_MsgCallback(13)
|
|
|
AnWBTSERVICE_GET_LOCAL_OOB_DATA status[0] hash_c192...
|
|
|
```
|
|
|
## connect device a.k.a. spp connect
|
|
|
## connect device
|
|
|
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
... | ... | @@ -174,9 +160,22 @@ AnWBTSERVICE_GET_LOCAL_OOB_DATA status[0] hash_c192... |
|
|
```
|
|
|
Note: You can find mobile BT mac from "Setting->General->About-> Bluetooth" (iphone)
|
|
|
```
|
|
|
> input profile_mask: 0x00000040
|
|
|
> input profile_mask: 0x00000040 (Take spp as an example)
|
|
|
```
|
|
|
Note: Then, connected.Querying the mobile phone shows that the connection is successful
|
|
|
profile_mask:
|
|
|
HFP_HF = 0x00000001;
|
|
|
HFP_AG = 0x00000002;
|
|
|
A2DP_SINK = 0x00000004;
|
|
|
A2DP_SOURCE = 0x00000008;
|
|
|
PBAP_CLIENT = 0x00000010;
|
|
|
MAP_CLIENT = 0x00000020;
|
|
|
SPP = 0x00000040;
|
|
|
HID = 0x00000080;
|
|
|
IAP = 0x00000100;
|
|
|
OPPS = 0x00000200;
|
|
|
OPPC = 0x00000400;
|
|
|
ALL = 0xFFFF
|
|
|
## spp write
|
|
|
```
|
|
|
================ common Menu ==================
|
... | ... | @@ -225,6 +224,55 @@ After execution, you can receive the answer message of disconnection and find ca |
|
|
AnWBTService_MsgCallback(7)
|
|
|
AnWBTSERVICE_DEV_PROFILE_STATE_CHANGED profile_mask[10] devclass[7995916] isConnected[0]
|
|
|
```
|
|
|
|
|
|
When StartInquiry is running, execute StopInquiry immediately and stop inquiry
|
|
|
## pair response
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
4.PairResponse
|
|
|
...
|
|
|
===============================================
|
|
|
input num: 4
|
|
|
...
|
|
|
```
|
|
|
|
|
|
## set pin code
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
5.SetPinCode
|
|
|
...
|
|
|
===============================================
|
|
|
input num: 5
|
|
|
input pincode:1111
|
|
|
```
|
|
|
## set local DevCoD
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
6.SetLocalDevCoD
|
|
|
...
|
|
|
===============================================
|
|
|
input num:6
|
|
|
input devClass:7995916
|
|
|
```
|
|
|
## get local OOB data
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
7.GetLocalOOBData
|
|
|
...
|
|
|
===============================================
|
|
|
input num:7
|
|
|
...
|
|
|
```
|
|
|
Note:then you can get the respond message from log,"status[0]" indicates success,for example
|
|
|
```
|
|
|
AnWBTService_MsgCallback(13)
|
|
|
AnWBTSERVICE_GET_LOCAL_OOB_DATA status[0] hash_c192...
|
|
|
```
|
|
|
|
|
|
## set scan mode
|
|
|
```
|
|
|
================ common Menu ==================
|
... | ... | @@ -339,6 +387,24 @@ then the log print the status that the device is connected or not connected,for |
|
|
```
|
|
|
connect_status[1](0-not connected 1-connected)
|
|
|
```
|
|
|
|
|
|
## View BT Name and address
|
|
|
```
|
|
|
================ common Menu ==================
|
|
|
...
|
|
|
20.View BT Name&address
|
|
|
===============================================
|
|
|
> input num:20
|
|
|
```
|
|
|
then you can get the local device message ,for example
|
|
|
```
|
|
|
---------------------------------------
|
|
|
Local Host Name:ddd
|
|
|
|
|
|
Local Host Address:[48:b8:a3:d5:8f:33]
|
|
|
---------------------------------------
|
|
|
```
|
|
|
|
|
|
# HFP Menu
|
|
|
## outgoing call
|
|
|
```
|
... | ... | |