User's Manual

23
www.lairdtech.com
Laird Technologies
BTM410/411
Bluetooth
®
AT Data Module
22. AT+BTAn {Control Audio Channel}
Once a Bluetooth connection is active, and assuming the peer device is also a Laird Technologies
device, this command is used to start/stop a SCO channel which will connect the PCM interfaces
of the two peer devices. This means that if a codec is attached to the PCM pins, then 2-way
audio can be established.
On receipt of the command, the following response immediately follows.
Response: <cr,lf>OK<cr,lf>
The lower layers then go through the process of setting up the SCO channel, and as soon as a SCO
link is established, the following response is asynchronously sent to the host.
Response: <cr,lf>AUDIO ON<cr,lf>
Or if the SCO failed to be established.
Response: <cr,lf>AUDIO FAIL<cr,lf>
On the peer device, the host will asynchronously get ….
Response: <cr,lf>AUDIO ON<cr,lf>
23. AT+BTC<devclass> {Set Device Class Code}
This command is used to set the device class code which will be sent in subsequent inquiry responses.
It can be read back using the AT+BTC? Command, as described below.
<devclass> is a 6 digit hexadecimal number derived as per section “1.2 The Class of
Device/Service Field” of the Bluetooth speci cation “Bluetooth Assigned Numbers”.
The 24 bits are made of 4 elds brie y described as follows (bit 0 corresponds to the least signi cant bit):-
Laird Technologies devices do not map to any prede ned Major Service Class or Major Device Class
and so the default devclass as shipped is 001F00, which means no Major Service Class and “Unclassi ed”
Major Device class.
Other examples of device class codes are follows:-
Response: <cr,lf>OK<cr,lf>
Or for an invalid <devclass> value (usually a value which is not 6 hexadecimal characters long).
Response: <cr,lf>ERROR 08<cr,lf>
24. AT+BTC? {Read Device Class Code}
This command is used to read the current device class code.
Response: <cr,lf>123456
<cr,lf>OK<cr,lf>
+BTA0 Switch off the channel.
+BTA1 Switch on the channel.
Bits 0-1 Format Type. This eld currently only has a value of 00 (i.e. format type 1)
Bits 2-7 These 6 bits de ne the Minor Device Class and the value is interpreted differently
based on the Major Device class stored in the next 5 bits.
Bits 8-12 These 5 bits de ne the Major Device Class as per Table 1.3 in
“Bluetooth Assigned Numbers”
Bits 13-23 This is an 11 bit eld used as a mask to de ne the Major Service Class, as per Table 1.2 in
“Bluetooth Assigned Number”
CODE (HEXADECIMAL) NAME MAJOR SERVICE MAJOR DEVICE MINOR DEVICE
001F00 Unclassi ed None Unclassi ed n/a
200404 Headset Audio Audio Headset
CONFIGURING
THE BTM410/411