BT1058 programming user guide
Introduction
Description
This design guide is suitable for engineers to develop BT1058 series Bluetooth modules
Module Default Settings
Name |
FSC-BT1058-XXXX |
LE-Name |
FSC-BT1058-LE-XXXX |
Pin Code |
0000 |
Secure Simple Pairing Mode |
ON |
UART Baudrate |
115200/8/N/1 |
Hardware Description
Pin Diagram
FSC-BT1058 as an example:

Pin Description
Pin |
Pin Name |
Type |
Pin Descriptions |
---|---|---|---|
4 |
I2S_CLK |
I/O |
I2S BCLK |
5 |
I2S_IN |
I |
I2S DATA IN |
6 |
I2S_OUT |
O |
I2S DATA OUT |
7 |
I2S_WS |
I/O |
I2S SYNC |
8 |
RESET |
I |
External reset input: active Low |
13 |
UART_TX |
O |
UART TX |
14 |
UART_RX |
I |
UART RX |
15 |
UART_CTS |
I/O |
UART CTS |
16 |
UART_RTS |
I/O |
UART RTS(default: PA mute pin) |
17 |
LED0 |
I/O |
Output square wave in pairing mode,
output high level when bluetooth is connected
|
18 |
LED1 |
I/O |
BIS is not connected to output low level,
connected to output high level
|
32 |
GND |
GND |
GND |
33 |
VDD |
VDD |
Power supply for I/O ports, DC 3.3V |
34 |
VREG_IN |
I |
Typically connected to an ON/OFF push button |
36 |
VDD_IO |
I |
pio supply |
43 |
MIC_LP |
Audio |
MIC0/Line_IN differential L input, positive |
44 |
MIC_LN |
Audio |
MIC0/Line_IN differential L input, negative |
45 |
MIC_BIAS |
Audio |
MIC Power Supplies |
46 |
SPK_RN |
Audio |
Headphone/speaker differential R output, negative |
47 |
SPK_RP |
Audio |
Headphone/speaker differential R output, positive |
48 |
SPK_LN |
Audio |
Headphone/speaker differential L output, negative |
49 |
SPK_LP |
Audio |
Headphone/speaker differential L output, positive |
51 |
EXT_ANT |
ANT |
Change the 0 ohm resistance near the antenna,
you can connect an external Bluetooth antenna
|
Hardware Design Notes
The simple test of the module only needs to connect VDD/VDD_IO/VREG_IN/GND/UART_RX/UART_TX to use
After drawing the schematic diagram, please send it to Feasycom for review,so as to avoid the Bluetooth distance not reaching the best effect
Function Description
Profiles & Features
SPP (Serial Port Profile)
GATTS (Generic Attribute Profile LE-Peripheral role)
GATTC (Generic Attribute Profile LE-Central role)
HFP-HF (Hands-Free Profile)
HFP-AG (Hands-Free-AG Profile)
A2DP-Sink (Advanced Audio Distribution Profile)
A2DP-Source (Advanced Audio Distribution Profile)
AVRCP-Controller (Audio/Video remote controller Profile)
AVRCP-Target (Audio/Video remote controller Profile)
HID-DEVICE (Human Interface Profile)
PBAP (Phonebook Access Profile)
MAP (Message Access Profile)
LEA (LE Audio)
GATT Default service and characteristic
Type |
UUID |
Characteristic |
Description |
Service |
0xFFF0 |
throughput services |
|
Write |
0xFFF2 |
Write,Write Without Response |
app send to module |
Notify |
0xFFF1 |
Notify |
module send to app |
Command Description
Terms
Throughout this specification:
Content between { } is optional
Content behind << represents a COMMAND from Host
Content behind >> represents a RESPONSE/EVENT to Host
Command Format
All commands start with “AT”, end with <CR><LF>
<CR> means “carriage return”, corresponds to hex value 0x0D
<LF> means “line feed”, corresponds to hex value 0x0A
If Command has Parameter, Parameter follows behind ‘=’
If Command has multiple Parameters, Parameter must be separated by ‘,’
If Command has Response, Response starts with <CR><LF>, ends with <CR><LF>
Module will always report command’s execution result by using “OK” for success or “ERROR” for failure
Event Format
All Events start with <CR><LF>, end with <CR><LF>
If Event has Parameter, Parameter follow behind ‘=’
If Event has multiple Parameters, Parameter must be separated by ‘,’
Commands Table
General Commands
AT+HELP - Firmware Function/Command Summary
Command |
AT+HELP |
Response |
<FIRMWARE FUNCTION: appropriate working scenario >
<OTA PATH: latest suitable firmware path on server for upgrade On-The-Air>
<ENABLED PROFILES: LINKS: ON/OFF>
…
…
<COMMAND SUMMARY: DESCRIPTION: PROFILE CATEGORY>
|
Description |
Using help command to get the basic summary information |
AT+VER - Get Firmware Version
Command |
AT+VER |
Response |
+VER=Param1,Param2,Param3 |
|
Module type |
|
Firmware version |
|
Firmware Compile time |
AT+BAUD - Get/Set Uart Baudrate
Command |
AT+BAUD{=Param} |
|
9600/19200/38400/57600/115200(default)/230400/460800/921600 |
Response |
+BAUD=Param |
Description |
Module will change baudrate to target value immediately or
after reboot depending on firmware
|
AT+I2SCFG - Get/Set I2S Settings
Command |
AT+I2SCFG{=Param} |
|
A base-10 representation of a bit field, default:0, for each bit |
|
0:disable; 1:enable |
|
0:master; 1:slave |
|
0:FS=48000Hz;1:FS=44100Hz |
|
0:left justified; 1:right justified |
|
0:data 1 bit delay; 1:data no delay |
|
00: bit depth=16bits
01: bit depth=24bits
10: bit depth=32bits
|
|
0:WS at high level,SD data is right channel 1:WS at high level,SD data is left channel |
Response |
+I2SCFG=Param |
Note |
BIT[4] is valid only at the condition of BIT[3]=0. BIT[7] Partial firmware support |
Example:usual configuration and description
1 |
I2S Master; Sample rate=48000Hz; Resolution=16bits; Bit clock= 48000*16*2ch=1.536Mhz |
3 |
I2S Slave; Sample rate=48000Hz; Resolution=16bits; Bit clock= 48000*16*2ch=1.536Mhz |
65 |
I2S Master; Sample rate=48000Hz; Resolution=32bits; Bit clock= 48000*32*2ch=3.072Mhz |
67 |
I2S Slave; Sample rate=48000Hz; Resolution=32bits; Bit clock= 48000*32*2ch=3.072Mhz |
AT+SPDIFCFG - SPDIF Format Configuration
Command |
AT+SPDIFCFG{=Param} |
|
0-Disable SPDIF for audio output 1-Enable SPDIF for audio output |
Description |
SPDIF output only support: BT1058、BT806、BT1026A、BT1026B、BT1026E
If the audio output is spdif, the I2S configuration is invalid.
|
AT+SPKVOL - Get/Set Analog Output Volume
Command |
AT+SPKVOL{=Param} |
|
Volume (‘+’ / ‘-’/ 0-15, default:15) |
Description |
Adjust Output volume, Adjust A2DP volume when play music,adjust HFP volume when talking |
AT+REBOOT - Soft Reboot
Command |
AT+REBOOT |
Response |
OK |
Description |
Module release all Bluetooth connections with remote device then reboot |
AT+RESTORE - Restore Factory Settings
Command |
AT+RESTORE |
Response |
OK |
Description |
Module restore all factory settings then reboot |
AT+BTEN - Bluetooth On/Off
Command |
AT+BTEN{=Param} |
|
0-Power off 1-Power on |
AT+PROFILE - Bluetooth Profile Selection
Command |
AT+PROFILE{=Param} |
|
A base-10 representation of a bit field, for each bit: |
|
SPP (Serial Port Profile) |
|
GATT Server (Generic Attribute Profile) |
|
GATT Client (Generic Attribute Profile) |
|
HFP-HF (Hands-Free Profile Handsfree) |
|
HFP-AG (Hands-Free Profile Audio Gateway) |
|
A2DP Sink (Advanced Audio Distribution Profile) |
|
A2DP Source (Advanced Audio Distribution Profile) |
|
AVRCP Controller (Audio/Video remote controller Profile) |
|
AVRCP Target (Audio/Video remote controller Profile) |
|
HID Keyboard (Human Interface Profile) |
|
PBAP Server (Phonebook Access Profile) |
|
Map Server (Message Access Profile) |
|
Bis Source (Le audio broadcast source) |
|
Bis Sink (Le audio broadcast sink) |
|
CIS Source (Le audio unicast source) |
|
CIS Sink (Le audio unicast sink) |
Response |
+PROFILE=Param |
Description |
GATT Server and Client, HFP Sink and Source, A2DP Sink and Source, AVRCP Controller
and Target cannot be enabled simultaneously because of mutual exclusion.
|
AT+AUTOCONN - Turn On/Off Power On Auto Reconnect
Command |
AT+AUTOCONN{=Param} |
|
(0~15, default:3)
(0) Turn Off
(1-15) Turn on and reconnect times
|
Response |
+AUTOCONN=Param |
Description |
Module will attempt to connect last device after power on if set. |
AT+STAT - Get All Profile State
Command |
AT+STAT |
Response |
+STAT=Param1, Param2, Param3… |
|
DEVSTAT |
|
SPPSTAT |
|
GATTSTAT |
|
HFPSTAT |
|
A2DPSTAT |
|
AVRCPSTAT |
|
CISSTAT |
|
PBSTAT |
|
BISSTAT |
AT+DEVSTAT - Read Device State
Command |
AT+DEVSTAT |
Response |
+DEVSTAT=Param |
|
A base-10 representation of a bit field, for each bit: |
|
0: Power Off; 1: Power On |
|
0: BR/EDR Not Discoverable; 1: BR/EDR Discoverable |
|
0: BLE Not Advertising; 1: BLE Advertising |
|
0: BR/EDR Not Scanning; 1: BR/EDR Scanning |
|
0: BLE Not Scanning; 1: BLE Scanning |
Example:usual combination and description
0 |
Device power off |
1 |
Device power on |
3 |
Device power on, BR/EDR Discoverable |
5 |
Device power on, BR/EDR Not Discoverable, BLE Advertising |
7 |
Device power on, BR/EDR Discoverable, BLE Advertising |
13 |
Device power on, BR/EDR Not Discoverable, BLE Advertising, Scanning nearby BR/EDR devices |
AT+ADDR - Get BR/EDR MAC Address
Command |
AT+ADDR |
Response |
+ADDR=Param |
|
Module’s BR/EDR MAC address (12 Bytes ASCII) |
AT+LEADDR - Get BLE MAC Address
Command |
AT+LEADDR |
Response |
+LEADDR=Param |
|
Module’s LE MAC address (12 Bytes ASCII) |
AT+NAME - Get/Set BR/EDR Local Name
Command |
AT+NAME{=Param1{,Param2}} |
|
BR/EDR local name(1~31 Bytes ASCII) |
|
MAC address suffix(0/1,default:1)
0: Disable suffix
1: Enable suffix “-XXXX” (lower 4 bytes of MAC address) after local name
|
Response |
+NAME=Param |
Description |
Write local name if parameter exist, otherwise read current local name |
AT+LENAME - Get/Set BLE Local Name
Command |
AT+LENAME{=Param1{,Param2}} |
|
BLE local name(1~25 Bytes ASCII) |
|
MAC address suffix(0/1,default:1)
0-Disable suffix
1-Enable suffix “-XXXX” (lower 4 bytes of MAC address) after local name
|
Response |
+LENAME=Param |
AT+SSP - Get/Set BR/EDR Pairing Mode
Command |
AT+SSP{=Param} |
|
Pairing mode (0~1, default:0)
(0) Legacy pairing, use pin code for pairing
(1) Secure simple pairing, auto pairing
(2) Secure simple pairing, display yes/no in pairing
|
Description |
Because BT1058 Bluetooth 5.4 with LEA function. BT1058 BT1038 series does not support ssp 0 parameters |
Response |
+SSP=Param |
Note |
need reboot. |
AT+COD: Get/Set Device Class
Command |
AT+COD=Param |
|
Class of device(6 bytes ASCII, default:240408 Handsfree device) |
Response |
+COD=Param |
Related configuration reference: COD.
AT+PAIR: Get/Set BR/EDR/BLE Visibility
Command |
AT+PAIR=Param |
|
Mode(0-1)
0: Leave BR/EDR/BLE discoverable mode (stop advertising/broadcasting)
1: Enter BR/EDR/BLE discoverable mode (start advertising/broadcasting)
|
Description |
Module will always be discoverable if no device connected (BR/EDR or BLE),
and be undiscoverable if connected with remote device, unless received this command
|
AT+PLIST - Get/Delete Paired List
Command |
AT+PLIST{=Param} |
|
(0/1~6/12 Bytes MAC address)
(0) Clear all paired record
(1~6) Clear specific paired record with index
(MAC) Clear specific paired record with MAC address
|
Response1 |
+PLIST=Param1, Param2, Param3{,Param4} |
|
(1~6) Paired device’s index |
|
(MAC) Paired device’s MAC address |
|
(UTF8) Paired device’s name |
Response2 |
+PLIST=E End of the paired record |
AT+DSCA - Release All Connections
Command |
AT+DSCA |
Description |
Module release all Bluetooth connections with remote device |
AT+TPMODE - Turn On/Off Throughput Mode
Command |
AT+TPMODE{=Param} |
|
Throughput mode(0~1,default:0) 0: Turn Off 1: Turn On |
Response |
+TPMODE=Param |
Description |
When SPP/GATT profile connected and throughput mode is on,
the AT command will be de-active,
every byte received via physical UART will be sent to air, vice visa
|
AT+AUXCFG - Audio Input Mode Configuration
Command |
AT+AUXCFG=Param1 |
|
mode(0-4,default:0)
0: BT Mode
1: LineIn Mode
2: Spdif Mode
3: I2S Mode
4: USB Mode
|
Description |
This command is used to configure the input mode of the module,
BT1006A, BT1026C, BT1026D do not support spdif
After BT1026A, BT1026B,are set to spdif, PA_MUTE pin will be modified to 20 pin
BT1058 V1.0.7 does not support spdif, I2S input
|
AT+MUTEPIO - Set PA_MUTE pin
Command |
AT+MUTEPIO{=Param} |
|
PIO(0-63, 1026C default:PIO23, BT1058 default:PIO2) |
AT+LINEPIO - Set LineIn Pin
Command |
AT+LINEPIO{=Param} |
|
PIO(0-63, BT1058 default:PIO26) |
Description |
Active low |
AT+MICMUTE - mute MIC
Command |
AT+MICMUTE=Param |
|
0-unmute 1-mute |
Description |
mute mic when call active |
AT+SPKMUTE - mute Speaker
Command |
AT+MICMUTE=Param |
|
0-unmute 1-mute |
HFP Commands
AT+HFPSTAT - Read HFP State
Command |
AT+HFPSTAT |
Response |
+HFPSTAT=Param |
Description |
Format description reference: +HFPSTAT - HFP State |
AT+HFPRES - Get/Set HFP Sample Rate
Command |
AT+HFPRES{=Param} |
|
Sample rate (Hz) for HFP voice call, 0:16k 1-48K |
Response |
+HFPRES=Param |
Note |
BT1058 V1.0.1 does not support this command function |
AT+HFPCONN - Establish HFP Connection
Command |
AT+HFPCONN{=Param} |
|
MAC address of target device (12 Bytes ASCII) |
Description |
Reconnect to last HFP device if parameter not exist |
AT+HFPDISC - Release HFP Connection
Command |
AT+HFPDISC |
Description |
Release current HFP connection with remote device |
AT+HFPDIAL - Dial/Redial Phone Number
Command |
AT+HFPDIAL{=Param} |
|
Phone number (1~25 Bytes ASCII) |
Description |
Dial specific number if parameter exist, otherwise redial |
AT+HFPDTMF - Send DTMF code
Command |
AT+HFPDTMF{=Param} |
|
DTMF (0~9/#/*) |
AT+HFPANSW - Pick Up Incoming Call
Command |
AT+HFPANSW |
Description |
Pick up an incoming call |
AT+HFPCHUP - Reject/Hung up Call
Command |
AT+HFPCHUP |
Description |
Reject incoming call or hung up outgoing/active call |
AT+HFPADTS - Transfer Voice Audio Between Local and Remote Device
Command |
AT+HFPADTS=Param |
|
0: Transfer voice audio from module to remote device
1: Transfer voice audio from remote device to module
|
Description |
Transfer voice audio between module and remote device by default if no parameter set |
AT+HFPVR - Start/Stop Voice Recognition of Remote Device
Command |
AT+HFPVR=Param |
|
0-Stop 1-Start |
Description |
Start/Stop Voice Recognition of Remote Device (such as Siri for iOS devices) |
AT+HFPSCO - HFP SCO Configuration
Command |
AT+HFPSCO=Param |
|
0-default 1-always to HF 2-always to AG |
AT+HFPBATT - Send device battery level
Command |
AT+HFPBATT=Param |
|
level(0-9) |
A2DP/AVRCP Commands
AT+A2DPSTAT - Read A2DP State
Command |
AT+A2DPSTAT |
Response |
+A2DPSTAT=Param |
Description |
Format description reference: +A2DPSTAT - A2DP State |
AT+A2DPCONN - Establish A2DP Connection
Command |
AT+A2DPCONN{=Param} |
|
MAC address of target device (12 Bytes ASCII) |
Description |
Reconnect to last A2DP device if parameter not exist |
AT+A2DPDISC - Release A2DP Connection
Command |
AT+A2DPDISC |
Description |
Release current A2DP connection with remote device |
AT+A2DPCFG - Read/Write A2DP Configuration
Command |
AT+A2DPCFG=Param |
|
A base-10 representation of a bit field, for each bit |
|
0: Disable AAC Codec 1: Enable AAC Codec |
|
0: Disable APTX Codec 1: Enable APTX Codec |
|
0: Disable APTX-LL Codec 1: Enable APTX-LL Codec |
|
0: Disable APTX-HD Codec 1: Enable APTX-HD Codec |
|
0: Disable APTX-AD Codec 1: Enable APTX-AD Codec |
|
0: Disable LDAC Codec 1: Enable LDAC Codec |
AT+A2DPDEC - Read A2DP Decoder
Command |
AT+A2DPDEC |
Response |
+A2DPDEC=Param |
|
1:SBC 2:AAC 3:APTX 4:APTX-HD 5:APTX-AD |
AT+A2DPRES - The resampling function is enabled
Command |
AT+A2DPRES |
Response |
+A2DPRES=Param |
|
0:disable 1:enable |
AT+A2DPBIS - Classic Bluetooth to BIS broadcast stream
Command |
AT+A2DPBIS |
|
0:close 1:open |
AT+AVRCPSTAT - Read AVRCP State
Command |
AT+AVRCPSTAT |
Response |
+AVRCPSTAT=Param |
Description |
Format description reference: +AVRCPSTAT - AVRCP State |
AT+AVRCPCFG - Get/Set AVRCP Configuration
Command |
AT+AVRCPCFG{=Param} |
|
A base-10 representation of a bit field, default:11, for each bit: |
|
Auto get track ID3 information (title, artist, album) on track changed.default:1 |
|
Auto get track play progress if value > 0. default:5 second |
|
Enable volume synchronization Settings. Default :0 |
AT+PLAYPAUSE - Track Play/Pause
Command |
AT+PLAYPAUSE |
Description |
Send play or pause command to remote media player according to current play status |
AT+PLAY - Track Play
Command |
AT+PLAY |
Description |
Send play command to remote media player |
AT+PAUSE - Track Pause
Command |
AT+PAUSE |
Description |
Send pause command to remote media player |
AT+STOP - Track Stop
Command |
AT+STOP |
Description |
Send stop command to remote media player |
AT+FORWARD - Track Forward
Command |
AT+FORWARD |
Description |
Send forward command to remote media player |
AT+BACKWARD - Track Backward
Command |
AT+BACKWARD |
Description |
Send backward command to remote media player |
AT+FFWD - Track FastForward
Command |
AT+FFWD=Param |
|
0-Fast Forward Release, 1-Fast Forward Press |
Description |
Send fast forward command to remote media player |
AT+RWD - Track Rewind
Command |
AT+RWD=Param |
|
0-Rewind Release, 1-Rewind Press |
Description |
Send rewind command to remote media player |
PBAP Commands
AT+PBSTAT - Read PBAP state
Command |
AT+PBSTAT |
Response |
+PBATAT=Param |
Description |
Format description reference: +PBSTAT - PBAP State |
AT+PBCONN - Establish PBAP Connection
Command |
AT+PBCONN{=Param} |
|
MAC address of target device (12 Bytes ASCII) |
Description |
Module will use current HFP device’ MAC address if parameter not exist
For some firmware release, module will establish PBAP connection
automatically on received command AT+PBDOWN
|
AT+PBDISC - Release PBAP Connection
Command |
AT+PBDISC |
Description |
Release current PBAP connection with remote device |
AT+PBDOWN - Download Phonebook
Command |
Param1{,Param2} |
|
Phonebook type(0-5)
(0) Phonebook (SIM Storage)
(1) Phonebook (Phone Storage)
(2) Received call log
(3) Dialed call log
(4) Missed call log
(5) All call log
|
|
Max items (1~65535, default:3000 for phonebook; 50 for call log) |
Description |
For some phones (e.g. iPhone), the contact download permission
must be turned on in phone’s Bluetooth settting
refer to application note for more description: Phonebook downloading
|
SPP Commands
AT+SPPSTAT - Read SPP State
Command |
AT+SPPSTAT |
Response |
+SPPATAT=Param |
Description |
Format description reference: +SPPSTAT - SPP State |
AT+SPPCONN - Establish SPP Connection
Command |
AT+SPPCONN{=Param} |
|
MAC address of target device (12 Bytes ASCII) |
Note |
BT1058 V1.0.7 does not support this command function |
AT+SPPDISC - Release SPP Connection
Command |
AT+SPPDISC |
Description |
Release current SPP connection with remote device |
AT+SPPSEND - Send Data Via SPP
Command |
AT+SPPSEND=Param1,Param2 |
|
Payload length (1~492) |
|
Payload (1~492 Bytes) |
Description |
If throughput mode is on, this command is de-active |
GATT Commands
AT+GATTSTAT - Read GATT State
Command |
AT+GATTSTAT |
Response |
+GATTATAT=Param |
Description |
Format description reference: +GATTSTAT - GATT State |
AT+GATTDISC - Release GATT Connection
Command |
AT+GATTDISC |
Description |
Release current GATT connection with remote device |
AT+GATTSEND - Send Data Via GATT
Command |
AT+GATTSEND=Param1,Param2 |
|
Payload length (1~492) |
|
Payload (1~492 Bytes) |
Description |
If throughput mode is on, this command is de-active |
BIS Commands
AT+BISSTAT - Read BIS State
Command |
AT+BISSTAT |
Response |
+BISATAT=Param |
Description |
Format description reference: +BISSTAT - BIS State |
AT+BISSCAN - Scan BIS-Source devices
Command |
AT+BISSCAN{=Param} |
|
Scan timeout |
AT+BISADD - Add a synchronous broadcast source
Command |
AT+BISID{=Param1,Param2} |
|
adv_sid |
|
broadcast_id |
AT+BISREMOVE - BIS Remove broadcast source
Format |
AT+BISREMOVE |
|
NULL |
AT+BISPLAYPAUSE - BIS Play pause control
Format |
AT+BISPLAYPAUSE=Param1 |
|
NULL |
AT+BISPLAY - BIS play
Format |
AT+BISPLAY=Param1 |
|
NULL |
AT+BISPAUSE - BIS pause
Format |
AT+BISPAUSE=Param1 |
|
NULL |
CIS Commands
AT+CISSTAT - Read CIS State
Command |
AT+CISSTAT |
Response |
+CISSTAT=Param |
Description |
Format description reference: +BISSTAT - BIS State |
GAME Command
AT+GAMEENABLE - Game mode enabled
Format |
AT+GAMEENABLE=Param |
|
NULL |
AT+GAMEDISABLE - disable
Format |
AT+GAMEDISABLE=Param |
|
NULL |
Device mode Command
AT+MODCFG - Device mode setting
Format |
AT+MODCFG=Param |
|
0-slave 1-master |
AT+AUDMODE - Device Bluetooth audio mode Settings
Format |
AT+AUDMODE=Param |
|
0-bredr 1-bis 2-cis |
Events Table
General Events
+PAIRED - Pair Result
Format |
+PAIRED=Param |
|
MAC address (12 Bytes ASCII) of current pairing device |
HFP Events
+HFPSTAT - HFP State
Format |
+HFPSTAT=Param |
|
(0~6)
(0) Unsupported
(1) Standby
(2) Connecting
(3) Connected
(4) Outgoing call
(5) Incoming call
(6) Active call
|
+HFPDEV - HFP Remote Device Information
Format |
+HFPDEV=Param1{,Param2} |
|
(12 Bytes ASCII), Remote MAC address of current HFP connection |
|
(UTF8), Remote device name of current HFP connection |
+HFPCID - Incoming/Outgoing Call Number
Format |
+HFPCID=Param |
|
(1~25 Bytes ASCII), Call number |
+HFPCIE - Incoming/Outgoing Call Name
Format |
+HFPCIE=Param |
|
(UTF8), Call name |
Note |
This event is supported by IOS mobile phones, but not supported by most Android phones |
+HFPAUDIO - HFP Voice Audio State
Format |
+HFPAUDIO=Param |
|
(0) HFP voice audio disconnected, audio input/output routed to remote device
(1) HFP voice audio connected, audio input/output routed to module
|
+HFPSIG - HFP Remote Device Network Signal Strength
Format |
+HFPSIG=Param |
|
(0~5)Network signal strength of remote device |
+HFPROAM - HFP Remote Device Roaming State
Format |
+HFPROAM=Param |
|
(0/1) Roaming state of remote device |
+HFPBATT - HFP Remote Device Battery Level
Format |
+HFPBATT=Param |
|
(0~5) Battery level of remote device |
+HFPNET - HFP Remote Device Network Operator Selection
Format |
+HFPNET=Param |
|
(UTF8)Network operator selection of remote device |
+HFPMANU - HFP Remote Device Manufacture
Format |
+HFPMANU=Param |
|
(UTF8)Manufacture name of remote device |
+HFPNUM - HFP Remote Device Phone Subscriber Number
Format |
+HFPNUM=Param |
|
(ASCII)Phone subscriber number of remote device |
+HFPIBR - HFP Remote Device In-band-ring Support
Format |
+HFPIBR=Param |
|
(0/1) In-band-ring support |
Description |
Report whether the current connected phone support in-band-ring |
A2DP/AVRCP Events
+A2DPSTAT - A2DP State
Format |
+A2DPSTAT=Param |
|
(0) Unsupported
(1) Standby
(2) Connecting
(3) Connected
(4) Paused
(5) Streaming
|
+A2DPDEV - A2DP Remote Device Information
Format |
+A2DPDEV=Param1{,Param2} |
|
(12 Bytes ASCII), Remote device’s MAC address of current A2DP connection |
|
(UTF8), Remote device’s name of current A2DP connection |
+AVRCPSTAT - AVRCP State
Format |
+AVRCPSTAT=Param |
|
(0) Unsupported
(1) Standby
(2) Connecting
(3) Connected
|
+PLAYSTAT - Media Player State
Format |
+PLAYSTAT=Param |
|
(0) Stopped
(1) Playing
(2) Paused
(3) Fast Forwarding
(4) Fast Rewinding
|
+TRACKSTAT - Media Player Play Progress
Format |
+TRACKSTAT=Param1,Param2,Param3 |
|
(0~4), Media Player State, see +PLAYSTAT |
|
(Decimal ASCII),Elapsed time of current track in millisecond |
|
(Decimal ASCII),Total time of current track in millisecond |
+TRACKINFO - Media Track Information
Format |
+TRACKINFO=Param1,Param2,Param3 |
|
title |
|
artist |
|
album |
Phonebook Access Events
+PBSTAT - PBAP State
Format |
+PBSTAT=Param |
|
(0) Unsupported
(1) Standby
(2) Connecting
(3) Connected
(4) Downloading
|
+PBCNT - Phonebook Entries of Remote Device
Format |
+PBCNT=Param |
|
Phonebook entries of remote device |
+PBDATA - Phonebook Data
Format1 |
+PBDATA=Param1<FF>Param2<FF>Param3{<FF>Param4} |
|
Type
(0) Phonebook (SIM Storage)
(1) Phonebook (Phone Storage)
(2) Received call log
(3) Dialed call log
(4) Missed call log
|
|
Name |
|
Number |
|
(15 Bytes ASCII), Call time if current download type is call log
Format:
Year(4Bytes) Month(2Bytes) Day(2Bytes) T(1Byte) Hour(2Bytes)
Minute(2Bytes) Second(2Bytes). e.g. 20161012T152826 represents
2016/10/12/15/28/26
|
Format2 |
+PBDATA=E: Download complete |
Description |
Call time may not exist for some mobile phones |
SPP Events
+SPPSTAT - SPP State
Format |
+SPPSTAT=Param |
|
(0) Unsupported
(1) Standby
(2) Connecting
(3) Connected
|
+SPPDATA - SPP Received Incoming Data
Format |
+SPPDATA=Param1,Param2 |
|
Payload length |
|
Payload |
GATT Events
+GATTSTAT - GATT State
Format |
+GATTSTAT=Param |
|
(0) Unsupported
(1) Standby
(2) Connecting
(3) Connected
|
+GATTDATA - GATT Received Incoming Data
Format |
+GATTDATA=Param1,Param2 |
|
Payload length |
|
Payload |
BIS Events
+BISSTAT - BIS State
Format |
+BISSTAT=Param |
|
(0) Unsupported
(1) Standby
(2) Scanning
(3) Connected
(4) Paused
(5) Streaming
|
+BIS - BIS The scanning result
Format |
+BIS=Param1,Param2,Param3,Param4,Param5,Param6 |
|
index value |
|
RSSI |
|
broadcast sid |
|
broadcast id |
|
mac address |
|
device name |
CIS Events
+CISSTAT - CIS State
Format |
+BISSTAT=Param |
|
(0) Unsupported
(1) LeaUnicasSink_idle
(2) LeaUnicasSink_disconnected
(3) LeaUnicasSink_ase_enabling
(4) LeaUnicasSink_ase_streamming
|
Application scenarios
profiles initializing and change parameter
The following figure shows Profile initialization and name modification
MCU change device name CARKIT reference code:
1void change_name(void)
2{
3 uart_send("AT+NAME\r\n");
4 if(uart_read("+NAME",name_buf))
5 {
6 if(memcmp(name_buf,"CARKIT",6))
7 {
8 uart_send("AT+NAME=CARKIT,0\r\n"); //defalut disable MAC address suffix
9 uart_send("AT+NAME\r\n"); // read bt name
10 if(uart_read("+NAME",name_buf))
11 {
12 if(memcmp(name_buf,"CARKIT",6))
13 {
14 //change name fail
15 }
16 else
17 {
18 //change name success
19 }
20 }
21 }
22 }
23}
Note
modify any parameters, it is recommended to query first and then modify the final verification
Classic BT Receive mode connection
LE Audio Broadcast Scan connection
Phonebook downloading
Appendix
设备模式切换