Home

BTM510/511 Multimedia Module User Guide

image

Contents

1. i frequency and audio interface 5309 1 0 1 pes ia nter tace Disable 1 Enable Default Configure PASS THROUGH PT Response AVRCP 0 Enable automatic PT response response type is read 310 f oe TG from 311 Default 1 Host is required to respond to PT indication See AT AVR Set automatic PT response type This value is queried for automatic PT Response see e eI n AVRCP Table 2 30 Default value is accepted 1w 9r TG Note if this value is set to reject 2w 10r then incoming Pass Through commands are not forwarded to the host processor no AVPTI message is sent to the host Set A2DP Sink supported features Bitmask 0 Headphone Default AJDP 1 Speaker 312 1 1 15 SNK 2 Recorder 3 Amplifier Subsequent AT amp W plus ATZ required for a new value to become effective Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 oy Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module A2DP 313 1 1 15 SRC Set A2DP Source supported features bit mask Bit O Player Default Bit 1 Microphone Bit 2 Tuner Bit 3 Mixer Subsequent AT amp W plus ATZ required for a new value to become effective 314 0 0 2 A2DP A2DP audio interface select O Analogue on board audio codec 1 12S master
2. ATI44 Current power mode active sniff passive and sniff interval of SPP HSP HFP Response format lt power_mode gt lt sniff_interval_in_slots_decimal gt O Active highest power consumption lowest latency responsiveness 1 Sniff mode power consumption and latency depend on sniff interval 2 Passive the device does not initiate a change of the power mode ATI45 Current sniff sub rating SSR parameters of SPP HSP HFP link in slots 1 slot 0 625 ms Response format lt flag gt lt li gt lt ri gt lt lto gt lt rto gt 1 SSR active lt flag gt a 0 SSR not active lt li gt Local SSR interval decimal integer slots lt ri gt Remote SSR interval decimal integer slots Local timeout decimal integer slots lt Ito gt Time before changing from sniff mode to SSR when no data is being transmitted Remote timeout decimal integer slots lt rto gt Time before changing from sniff mode to SSR when no data is being transmitted ATI46 Current link policy power table Response for each row lt index gt lt mode gt lt time gt lt min_int gt lt max_int gt lt attempt gt lt timeout gt lt index gt Row index starting with 0 Power mode O Active 1 Sniff 2 Passive lt mode gt Duration of current row in seconds switching to the next row after lt time gt this timeout lt min_int gt Sniff mode intervals
3. AT AVQBP Query browsed player AT AVQPI Query TG player ID AT AVQPA Query TG player application setting attributes AT AVQPV Query TG player application setting values for all attributes AT AVQPE Query TG player application setting attribute value s text AT AVQPF Query TG player features AT AVQPP Query TG play status of addressed selected player AT AVQPT Query TG player application settings attribute text AT AVQPR Query TG player application settings attribute range AT AVS Command family set AVRCP related data player browsing path etc Refer to Table 2 33 for more details on set commanas Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 71 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 33 AVRCP1 5 Set commands AT AVSAI Add item to now playing list AT AVSBP set browsed player AT AVSG set remote gain AT AVSSP set addressed selected player AT AVSPU set path upwards one level AT AVSPUQ set path upwards one level and query AT AVSPRQ set path upwards to root and query AT AVSPR set path upwards to root AT AVSPI play item selected by browsing AT AVSPQ set path downwards and query AT AVSP set path downwards AT AVSV set player application value e g repeat shuffle etc Messages
4. 2 12S slave 315 0 0 SCO eSCO SCO audio interface select Analogue on board audio codec 12S master 12S slave WinNn oO PCM master PCM_M 4 PCM slave PCM_S 316 63 1 63 A2DP 12S sampling rate capability for A2DP values can be added for all sampling frequencies supported Register is referenced if S314 gt 0 at boot time requires AT amp W and ATZ for new values to become effective 48 kHz 44 1 kHz 32 kHz oO RIN 24 kHz 22 05 kHz OV 32 16 kHz 1 A2DP Source at least one of the sampling frequencies 48kHz 44 1kHz must be supported A2DP Sink both 48 kHz and 44 1 kHz must be supported at least 2 values ignored as they are not supported by SBC or APTX 318 4 X1M 0 4 CVC SCO DSP image select O Disable CVC DSP is not used on an SCO link 1 CVC Headset one microphone Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 218 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 CVC Headset two microphones 3 CVC Hands free one microphone X1M DSP application for resampling WBS one j microphone input no CVC For details on CVC refer to the application note CVC on BTM5xx 0 provided by Laird Technologies under ND
5. Disconnect timeout in seconds This timer specifies how long to wait for confirmation from the peer device and or the underlying stack that the connection has 560 15 15 120 n a been successfully torn down In the event that a confirmation never arrives this timer closes off the procedure and puts the machine back into a proper mode for new operations Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 239 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Time is specified with 15 seconds intervals S561 0 0 1000 n a Sniff Attempt Time in units of milliseconds 0 means disable See Sniff Mode and Figure 2 42 S562 0 0 1000 n a Sniff Timeout Time in units of milliseconds 0 means disable See Sniff Mode and Figure 2 42 563 0 0 1000 n a Sniff Minimum Interval in units of milliseconds 0 means disable See Sniff Mode and Figure 2 42 S564 0 0 1000 n a Sniff Maximum Interval in units of milliseconds 0 means disable See Sniff Mode and Figure 2 42 565 0 n a If set to 1 RI Ring Indicate line is configured as an input and forces the start up mode SReg512 and post timeout on Start up mode SReg555 to be dependent on the state of RI The RI conditional modes are defined by S Registers 566 to 569 inclusive S56
6. The parameter lt string gt is any string not more than 29 characters long whereby a non printable character nh see below counts 3 characters This restriction results from the maximum AT command length which is 34 query by ATI15 The difference of 5 is caused by ATX 3 characters and the enclosing quotation marks 2 characters If the maximum string length is exceeded this generates ERROR 05 syntax error If a non visual character is to be sent then insert the escape sequence hh where hh is two hexadecimal digits The 3 character sequence hh is converted into a single byte before transmission to the peer Response lt cr lf gt OK lt cr If gt Or lt cr lf gt ERROR O5 lt cr If gt e g lt string gt too long 25 9 2 AlY lt string gt Send Data in Local Command and Connected Mode This command is similar to ATX in syntax and functionality except that the string is only copied to the output RF buffer When an empty string is presented all pending data in the output RF buffer is flushed The parameter lt string gt is any string not more than 29 characters long whereby a non printable character nh see below counts 3 characters This restriction results from the maximum AT command length which is 34 query by ATI15 The difference of 5 is caused by ATX 3 characters and the enclosing quotation marks 2 characters If the maximum string length is exceeded ERROR 05 syntax error occurs If a non visual character i
7. BTM510 511 User Guide Bluetooth Multimedia Module Missing profile mask in S102 at least one profile flag contained in the ACR table is not set in 108 S102 109 Command not allowed when AC service is running Stop service to enable full parser 110 ACS precondition failed module is discoverable and or connectable 111 ACS precondition failed inquiry in progress 112 ACS precondition failed pairing in progress 113 ACS precondition failed legacy SPP auto connect AT BTR is enabled 114 ACR option flags wrong 115 Tuple length doesn t match DREG 116 Internal error code DREG 117 Non volatile memory for dynamic register exhausted DREG 118 Maximum number of tuples exceeded DREG 119 Maximum dynamic register data length exceeded DREG 120 Internal error code DREG 121 Internal error code DREG 122 Operation not enabled in HF HFG supported features Check 581 S596 123 Internal error code 124 Internal error code 125 Operation timeout 126 Requested operation not enabled in remote device s supported features HF HFG 127 Call records are empty 128 No call is currently waiting 129 Invalid remote gain cache 130 Internal error code 131 AVRCP reserved 132 AVRCP reserved 133 AVRCP requested action or feature not supported by remote device 134 AVRCP operation failed internal issue 135 AVRCP received AVRCP status code not successful 136 AVRCP browsing not supported
8. BTM510 511 User Guide Bluetooth Multimedia Module The second method is to reset the device and ensure that the text string AT BT amp BISM amp lt cr gt is sent where lt cr gt is the carriage return character There is special code which waits for this command and then terminates the autoconnect cycle This function then sends an OK response Response lt cr lf gt OK lt cr f gt 2 5 10 8 AT BTR Delete Outgoing Peer Address This command deletes the peer address previously stored using AT BTR lt bd_addr gt Response lt cr lf gt OK lt cr lf gt 2 5 10 9 AT BTR Read Outgoing Peer Address This command displays the peer address stored in non volatile memory for placing the device in pure cable replacement mode Response lt cr lf gt 12346789012 lt cr lf gt OK lt cr lf gt If the location is empty the response is as follows Response lt cr lf gt O00000000000 lt cr lf gt OK lt cr lf gt 2 6 Bluetooth Profiles This section covers S Registers and AT Commands related to supported Bluetooth Profiles on BTM 2 6 1 Profile Activation To activate available profiles and advertise them to potential clients S102 is used Per default only SPP is activated value 1 Other supported profiles can be activated by setting the appropriate Flag in S102 Once 102 is written the value must be saved to non volatile memory AT amp W Subsequently a reset ATZ or power cycle is required AT amp W saves all S Regis
9. BTM511 Development Kit Schematics Version 4 Development Kit Documentation BTM511 Development Kit Quick Start A2DP and AVRCP Version 2 BTM511 Development Kit Quick Start HFP Version 2 BTM511 Development Kit Quick Start SPP Version 2 BTM511 Audio Development Kit ADK User Manual Version 4 The following download is also available from the Embedded Wireless Solutions Support Center https laird ews support desk com b_id 1957 Laird EZURiO Terminal v6 9 0 zip Product information can also be accessed from the BTM51x product page on the Laird website http Awww lairdtech com products btm5 1x series Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 258 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Laird global solutions local support USA 1 800 492 2320 Europe 44 1628 858 940 Asia 852 2268 6567 wireless support lairdtech com www lairdtech com wireless Laird Technologies is the world leader in the design and manufacture of customized performance critical products for wireless and other advanced electronics applications Laird Technologies partners with its customers to find solutions for applications in various industries such as Network Equipment Telecommunications Data Communications Automotive Electronics Computers Aerospace Military Medi
10. Message AVPC 0002 AVPV 02 Repeat 02 Single track AVPV 03 Shuffle 01 Off AVPC OK mode e g repeat track Change repeat Player application settings AVPC lt n gt Changed followed by lt n gt att val items AVPV Attribute value pairs of player application settings AVPC OK End tag Command AT AVQFS Response AVFSL 0007 00 AVFSI 0 lt UID gt 05 Playlists 0 AVFSI 1 lt UID gt 03 Artists 0 AVFSI 2 lt UID gt 01 Titles 0 Query folder items Initial path should be root Start tag of file system list avrs Seven items in this list lt start offset gt lt end offset gt lt total items in folder gt File system item n AVFSI UidCachelndex lt n gt Hint strings after folder type Playlists Artists AVFSL OK List s end tag OK OK Command terminator Command Change path to item indicated by AT AVSPQ2 UidCachlIndex 2 in previous list Should be Response list of Titles UidCachelndex of Titles AVFSL 0008 AVMEI 0 lt UID gt 00 Audio 01 AVMEI 1 lt UID gt 00 Audio 01 AVFSL OK OK depends on TG and may differ on TG devices In addition query the new path like AT AVQFS combined command File system start tag eight items in this list AVFSL lt start offset gt lt end offset gt lt total items in folder gt Media element item Amalen n UidCache
11. Open the music player application Message AVPS 01 Playing AVNPT 0007 AVNPAO 01 Title 006A 000F lt title_name gt Chose a track and start playing Playback Status changed AVPS New status 1 hint string Playing which can be disabled by 390 bitO 0 Now Playing track attributes AVNPT presented as list with start end tag AVNPT Track attribute items packet AVNPA iA AVNPT OK 0 ae Hint strings for attribute type AVVC Volume Changed message which Message AVVC 4F 09 Change volume on phone indicates that absolute volume is received and corresponding output gain which is applied immediately Can be double checked using AT GO Message AVTC lt UID gt AVNPT 0007 AVNPAO 01 Title 006A 000F lt title_name gt AVNPT OK Jump to next track Track Changed indication AIE with UID of new track AVNPT Start end tag for Now Playing Track attributes AVNPA Attribute items 0 Hint strings for attribute type packet type 0 Message AVPS 02 Paused Stop playback AVPS Playback Status changed new status 2 hint string Paused can be disabled by S390 bit0 0 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 74 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module
12. U Up Increments of one 1 D Down Increments of one 1 Indicates that a cached gain value is not available This can happen if HS does not support the ERROR 129 a poe remote volume control feature missing notifications Examples AT HSGGOU increment speaker gain of connected HS AT HSGGI query current cached microphone gain of connected HS AT HSGGI13 set microphone gain of connected HS to 13 2 6 7 2 12 Headset gateway audio routing Audio in the headset profile is always referred to as a SCO connection which is used for bidirectional transmission of speech On a BTM5xx SCO audio is routed to the internal codec by default S315 can select the 12S interface in master or slave mode for SCO connections Refer to Routing audio streams over 125 2 6 7 2 13 Receiving commands from SLC There are two taps to display incoming SLC ACL data The first is before the SLC ACL parser and the second is the one after the parser if the command is not recognized The first tap should be used for debugging or learning purposes the second should be used for customer commands See Figure xx The following explains how to enable the asynchronous tap messages Temporary valid until power cycle or until reverted AT RX1 Enable all SLC RX messages first tap AT_UC1 Enable all unknown command messages second tap Permanently valid as of next power cycle 379 1 Enable all SLC RX messages first tap
13. 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module lt cr f gt OK lt cr lf gt If the SDP database is corrupt or invalid then it returns Response lt cr lf gt 3 lt cr f gt OK lt cr lf gt If the device is not in idle mode then it returns Response lt cr lf gt 4 lt cr f gt OK lt cr lf gt In this case the command AT BTX may put the device into the correct idle mode 2 5 1 15 ATin Information This returns the information about the Laird Technologies device and its status Refer to Table 3 2 Appendix for a complete list of supported ATIn parameters For recognised values of n Response lt cr lf gt As Appropriate lt cr lf gt OK lt cr lf gt For unrecognised values of n Response lt cr lf gt Laird Technologies Inc UK 2014 lt cr If gt 25 1 16 AT SIT lt n gt play a pre defined tone lt n gt index of tone 1 94 dec volume of tone is controlled by 387 Response lt cr lf gt OK lt cr lf gt 2 5 1 17 AT UC lt x gt enable disable query unrecognised command notification message UC lt x gt 1 0 corresponding to enable disable query 2 5 1 18 AT RC lt x gt f enable disable query SLC ACL spy message RX lt x gt 1 0 corresponding to enable disable query 2 5 2 AT Commands for S Registers As with modems the Bluetooth module employs a concept of registers which are used to store parameters such as escape sequence character or inquiry delay time
14. Send AG indicator status to HF CIEV AT HFGl lt indicator_id lt value gt dec gt dec For lt indicator_id gt and lt value gt see Table 2 59 Command is recommended only with indicator IDs 1 service 5 signal 6 roam and 7 battery charge level For all other indicators 2 call 3 call setup 4 call held Laird recommends you use the appropriate call managing AT commands These commands send the indicators automatically Send network operator string to HF AT HFGO lt operator_string gt Command used to respond to HFGOP Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 145 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Send error to HF AT HFGE Sends ERROR to HF Needed on HFG D gt mmm if memory location is invalid or on HFGL if last dialled number not available Send extended error AT HFGE lt cme_code gt result code to HF CME ERROR lt cme_code gt is sent to HF if HF did enable this feature earlier Otherwise a simple ERROR is sent to HF Disable Enable AT HFGBO 1 In Band ring tone BSIR 0 or BSIR 1 is sent to HF SLC must exist and Bit 3 of S596 HFG supported features must have been set at boot time Ringtone signal must be provided by external circuit Send custom data on HFG instance SLC AT HF
15. packet type bitmask recommended 7 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 191 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 16kHz sampling rate 1 EV3 similar WBS only between two BTM51x EVA 4 EV5 Release SCO eSCO link AT BTAO AT BTA Initiate SCO eSCO link AT BTA8 Link type SCO eSCO and packet types defined by S584 Enable WBS 16kHz S376 0 1 O Disable WBS 8kHz applies also to incoming 1 Enable WBS 16kHz default SPP SCO requests Set SCO eSCO link type 584 0 2 O SCO HV1 HV2 HV3 enabled ii Hessel requests and 1 eSCO EV3 EV4 EV5 enabled eee SPP SCO incoming audio 2 request accept requested packet type SCO eSCO Only one link type can be enabled at one time Initiate SCO eSCO link 532 0 7 The recommended value to enable this feature is 7 automatically on each SPP link Value bitmask for packet type The link type SCO eSCO is defined by 584 O Feature disabled 1 HV1 S584 0 or EV3 S584 1 2 HV2 S584 0 or EV4 S584 1 3 HV3 S584 0 or EV5 S584 1 Check link type of current ATI37 0 unknown no SCO link SCO connection 1 SCO SCO eSCO 2 eSCO 2 9 2 1 SCO eSCO Asynchronous Messages The following asynchronous messages apply to SCO eSCO
16. 0201 0 fff n a This register specifies in each 4 bit nibble how the DTR DCD and RI output pins are controlled when NOT in a Bluetooth connection Nibble 0 3 Specifies the source for DTR Nibble 4 7 Specifies the source for DCD Nibble 8 11 Specifies the source for RI In addition it also refers to S Register 552 to see if the relevant pin is an input or not to be touched If the nibble in 552 is O then the relevant pin is an input Each nibble can take the following value O Always de assert 1 Always assert 2 Assert if RING is being sent to the host S554 0 0 900 n a Post Reset Window If S Register 512 gt 2 and lt 7 then this register specifies a time in seconds for which the device stays in the 512 mode after power up or reset On timeout it aborts the discoverable and or Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 238 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module connectable and fall back into 512 1 mode when it is not connectable or discoverable Note that if AT BTR has been used to specify a peer device then on reverting to mode 1 it attempts to make a connection to that peer device A power cycle reset via BREAK or ATZ is required to see the effects of change Granularity 4 If value is lt 60 r
17. 380 1 Enable all unknown command messages second tap plus subsequent AT W and ATZ HSRX lt data gt HSGRX lt data gt Display any data received on HSP ACL HFRX lt data gt HFGRX lt data gt Display any data received on HFP SLC HSUC lt data gt HSGUC lt data gt Display unknown command received on HSP ACL HFUC lt data gt HFGUC lt data gt Display unknown command received on HSP ACL 2 6 7 2 14 AG status ATI64 Returns the status of the Audio Gateway HSP instance 0 Not connected 1 ACL connected Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 114 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 Audio connected Alerting HS by sending RING 2 6 7 2 15 AG asynchronous messages CONNECT lt bd_addr gt lt uuid hex hex Alerting HS by in band ringing gt lt dir gt An ACL connection to headset has been established lt bd_addr gt Bluetooth address of headset device Aus 1112 Incoming connection i 1108 Outgoing connection lt gt 0 optionally indicates the lt dir gt fet ee direction incoming outgoing Refer to 331 and UUIDs in CONNECT NO CARRIER Messages The internal codec is configured for a sampling ee frequency of 8000 Hz HSG AU1 Aud
18. 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 5 9 4 11 Enter Remote Command Mode When in data and connected mode the host can force the remote device into connected command mode so that AT Commands can be remotely issued to the device The escape sequence guard time is specified by S Register 12 and is the same as per the 44 escape sequence By default the guard time is set to 100 milliseconds The remote device issues ATO as normal to return to data mode Refer to 0 For this command to be effective S Register 536 must be set to 1 Response lt cr lf gt OK lt cr lf gt 25 9 5 ATO Enter Data Mode letter o Returns to data mode This command assumes that the module is in data mode after OK is received It responds with an error if there is no Bluetooth SSO connection Response lt cr lf gt CONNECT 123456789012 lt lt cr If gt incoming connection lt cr lf gt CONNECT 123456789012 gt lt cr f gt outgoing connection Or Response lt cr lf gt ERROR nn lt cr lf gt 2 5 9 6 Dropping SSO Connections In a conventional telephony modem a call is normally terminated by first sending a character sequence It is enveloped by an escape sequence guard time between 100 to 1000 milliseconds This places the receiving device into local command and connected mode whereupon the sender issues the ATH command The Laird modules provide multipl
19. A profile compliant disconnection is initiated from Headset by sending AT CKPD 200 use AT HSB to the audio gateway This command exists for the sake of completeness and is for testing purposes only Response On audio disconnection optional lt cr If gt HS AUO lt cr f gt On ACL disconnection lt cr lf gt NO CARRIER 1108 lt cr f gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 108 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 7 1 5 Headset status ATI63 Returns the status of the Headset HSP instance 0 not connected 1 ACL connected 2 Audio connected 2 6 7 1 6 Headset audio routing Audio in the headset profile is always referred to as a SCO connection for bidirectional speech transmission On a BTM5xx SCO audio is routed by default to the internal codec 315 selects the I2S interface in master or slave mode for SCO connections Refer to Routing audio streams over 25 2 6 7 1 7 Headset asynchronous messages CONNECT lt bd_addr An ACL connection to headset has been established gt lt dir gt hex gt lt uuid hex lt bd_addr gt Bluetooth address of headset device hex lt uuid gt 1108 incoming connection 1112 outgoing connection lt dir gt lt gt V O optionally indicates the dire
20. AT AVSVC lt nVal gt Scan nAtt 4 dec lt nAtt With lt nAtt gt attribute ID see Table 2 44 ger lt NVal gt Parameters lt nVal gt value see Table 2 44 Option lt nAtt gt can be replaced by E R S C as outlined above Success AVSV OK Response Failure AVSV ERROR lt asc q gt With lt asc gt avrcp status code see Table 2 50 Terminator OK ERROR nnn 2 6 6 5 Item lists A number of different lists has been implemented in the BTM51x in order to present AVRCP1 5 data to a host controller via UART Available players AT AVQAP Current play list AT AVQCL virtual File system AT AVQFS Now playing track AT AVQNP Player application settings AT AVQPV Each list begins with a start tag followed by a variable number if items and is terminated by another end tag Start and end tags allow the module to identify the context of a list in cases where item tags can be ambiguous such as AVME Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 92 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 41 AVRCP1 5 list tags overview List Type Available Current Play File System Now Playing Player Application gt Players List Track Settings AVAPL AVCPL AVFSL AVNPT lt nAtt gt AVPL lt
21. Figure 2 11 Open a player e g Windows Media Player to play some music 8 Connect a Headphone Speaker to the Audio Output of the BTM device Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 39 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Troubleshooting If there is no audio ensure that a Bluetooth Audio Device has appeared in the Device Manager Also check that the Bluetooth Audio Device is selected as speaker in your player application Sometimes a player needs to be closed and restarted in order to send its audio output to a new speaker device which is the Bluetooth Audio Device here Connected n a Audio can be heard on the speakers headphones Adjust AT GOU Increment volume audio output gain by one Volume BIM5xx AT GOD Decrement volume audio output gain by one Disconnect AT APH Response NO CARRIER 110D disconnection confirmed 10 x Bluetooth View Help Bluetooth f ee Detail Delete N Ce ten Figure 2 7 A2DP example 1 PC Bluetooth settings Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 40 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Add New Connection Wizard This
22. For 12S normally used for stereo audio ensure the sampling rate is configured to 8 kHz if used with SCO Otherwise the sampling rate mismatch produces distorted audio If the fixed sampling rate feature is enabled for 12S then the above requirement is obsolete Please refer to Fixed sampling rate PCM I2S S419 mapping Table 2 76 SCO audio routing options Internal Codec S315 0 4 4 4 PCM S315 3 y y y I2S S315 1 2 y y y 8kHz 8kHz 8kHz SPDIF 1 SPDIF not supported currently but seems feasible Internal Codec Analogue all other interfaces are digital external audio interfaces Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 178 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 8 4 SCO Input Output Channel If SCO which is mono is routed over an audio interface which normally supports stereo the left channel is selected for the input signal Internal Codec A left A and B left and right I2S Left Left and Right Note On previous versions of the BTM51x mini dev kit the stereo input connector left and right channels are swapped tip right ring left sleeve ground The correct assignment for the jack is tip left ring right sleeve ground This issue is resolved as of the BTM511 DVK V04 2 8 5 Audio Loopback Mode
23. Glossary A2DP Advanced Audio Distribution Profile unidirectional stereo audio ACL Asynchronous Connection Oriented Link ACR Auto Connect Record ACS Auto Connect Service ADC Analogue to Digital Converter AGHFP Audio Gateway Hands Free Profile AT Command prefix Attention AVRCP Audio Video Remote Control Profile BISM Bluetooth Intelligent Serial Module CoD Class Of Device also referred to as device class Codec Device capable of encoding decoding an analogue digital signal DAC Digital to Analogue Converter DREG Dynamic Register DSP Digital Signal Processor DUN Dialup Network Profile EIR Extended Inquiry Response eSCO Enhanced Synchronous Connection Oriented Link bidirectional mono audio for speech Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 7 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module transmission FTP File Transfer Profile GOEP Generic Object Access Exchange Profile GPIO General Purpose Input Output HCI Host Controller Interface HF Hands free Role of Hands free Profile Hands free Unit HFG Audio Gateway Role of Hands free Profile Hands free Gateway HFP Hands Free Profile HID Human Interface Device Profile HS Headset Role of Headset Profile Headset HSG Audio Gateway Role of Headset Profile Headset
24. assuming devA HF and devB HFG default parameters SLC established 1 Create audio AT HFA HF AU1 FS16000 WBS 2 Listen to the audio link 3 Close audio AT HFR HF AUO 4 Disable WBS AT HFWO 5 Re create audio AT HFA HF AU1 FS8000 narrowband 6 Listen to the audio link 7 Close audio AT HFR HF AUO 8 Re enable WBS AT HFW1 9 Create audio AT HFA HF AU1 FS16000 WBS and so on Note The above if for demonstration purposes only In practice WBS should not be disabled unless there are good reasons for doing so 2 6 8 4 Remote volume control HFP Remote volume control feature for HFP allows the audio gateway HFG to control microphone and speaker gains of HF unit In addition HF unit notifies the audio gateway HFG about local changes of microphone or speaker gain When an SLC is established HF is sending the current gain settings to the HFG synchronisation For HFP this feature is enabled by Bit 4 0x10 of HF supported features S581 enabled by default From HF a volume change notification is sent to HFG whenever the analogue gains are changed at HF i e on AT GO or assignments of S Registers 589 590 689 690 An incoming microphone speaker volume control message VGM lt gain gt VGS lt gain gt immediately affects analogue input or output gain of HF From HFG a remote volume change notification can be sent by AT HFGG command family It is
25. command family Write AT BTE lt data gt AT BTE lt data gt Delete ATIBTE tO en et TE en mmm LEBTED K Query AT BTE AT BTE copy EIR Buffer RAM EIR Persistent Store Baseband copy AT BTE AT BTEW boot time copy Figure 2 2 Extended Inquiry Response command overview 2 5 5 1 EIR Data Format When passing EIR data lt data gt to AT commands AT BTE lt data gt AT BTE lt data gt each byte should be presented by its ASCII representation whenever it is a printable character Each non printable ASCII character must be presented as 2 hex digits with a preceding V For example a byte of decimal value 5 would be presented as 05 because the ASCII character of 05d is not printable A decimal value of 43 should be presented as because is the ASCII character representing 43d The module would also accept 2B the hexadecimal presentation of 43d but at the price of two redundant characters Exceptions quotation mark must be presented as 22 Y backslash must be presented as 5C When querying the content of any buffer Baseband RAM Persistent Store non printable ASCII characters is presented by 2 hex digits with preceding Exceptions quotation mark is presented as 22 Y backslash is presented as 5C comma is presented as 2C Data passed to the baseband must match the format defined in the Bluetooth Specif
26. lt ci gt lt Or gt ERROR 66 lt cr gt lt lIf gt Record with requested index lt n gt not available lt cr gt lt lIf gt ERROR 05 lt cr gt lt lf gt Syntax error Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 137 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 8 2 14 HFG Call Waiting Notification CCWA 11_4 21 12_4 22 1 Call waiting notification is a mandatory feature for the HFG and is therefore supported on the BTM510 511 If call waiting notification was enabled by the HF 4 21 when a call is waiting the call waiting notification CCWA and the appropriate call setup indicator CIEV callsetup 1 are sent automatically as specified in section 4 22 1 of the HFP specification 5 2 6 8 2 15 Enable disable query toggle voice recognition 15_ 4 25 AT HFGV lt x gt lt x gt 1 0 T Voice recognition activation VRA is a HFP feature which is intended to be used with applications such as Siri iPhone or other voice recognition applications Once an SLC connection is established from a HFG unit the easiest command to start this is the toggle function AT HFGVT This switches VRA on if it is off and vice versa The toggle function can also be controlled by a push button GPIO FMC 0x13 2 6 8 2 16 Query Set Increment Decrement remote ga
27. lt cr If gt HSG AUO cr f gt On SLC disconnection lt cr lf gt NO CARRIER 1112 lt cr f gt 2 6 7 2 8 Enable automatic alerting on SLC establishment 345 S Register 345 enables automatic alerting on ACL establishment It contains a bitrnask where bit O corresponds to outgoing ACL connections and bit 1 corresponds to incoming ACL connections If automatic alerting is disabled S345 0 it can be initiated manually by AT HSGC 2 6 7 2 9 Enable in band ringing S346 In band ringing is enabled by S Register 346 value 1 If disabled S346 0 the RING message is send instead to alert the HS 2 6 7 2 10 Enable automatic SLC release 347 If the HSG is in Audio connected state and the HS initiates an audio release by AT CKPD 200 Button pressed the ACL is released too if S Register 347 1 If S347 0 it is up to the user to release the ACL manually by AT HSGH or retain the ACL by doing nothing 2 6 7 2 11 Query Set Increment Decrement remote gain of HS AT HSGG Syntax AT HSGG lt I O gt lt n U D gt with Input microphone VO O Output speaker Query current cached remote gain value Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 172 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module aes Set remote gain value Valid range 0 15 dec
28. lt cr gt lt If gt ERROR O5 lt cr gt lt lf gt syntax or value range error OR lt cr gt lt If gt ERROR 67 lt cr gt lt lf gt maximum number of subscriber number records reached AT HFGS This command returns a list of currently available subscriber number records which are sent to the HF unit via AT CNUM issued by HF on the SLC Response For each subscriber number record if at least one is available lt cr gt lt lf gt lt index gt lt number_string gt lt type gt lt service gt And finally lt cr gt lt lf gt OK lt cr gt lt lf gt command finished With lt index gt current index of the record required as parameter n for AT HFGSD lt n gt lt number_string gt subscriber number string lt type gt specifies the format of lt number_string gt Refer to AT HFGS above lt service gt service of this subscriber number 4 voice 5 fax AT HFGSD Delete all subscriber number records in the HFG Response lt cr gt lt lf gt OK lt cr gt lt lf gt AT HFGSD lt n gt Delete subscriber number record with index lt n gt in the HFG lt n gt refers to the index that is displayed on HFGS The value of lt n gt is assumed to be one digit The index is not fixed to a record If there are higher numbered indexes than the one deleted the remaining records get a new index assigned dynamically on HFGS Response lt cr gt lt lf gt OK lt cr gt lt lf gt Or
29. see S390 bits 4 5 7 Queries for now playing track attributes can also be carried out by AT command at any time AT AVQNP 2 6 5 7 UID cache In the virtual file system folders and media element items track are uniquely identified by a 64 bit UID unique identifier This UID is always contained in relevant UART messages list items Given that handling 64bit values may be inconvenient for resource constrained host microcontrollers or for human beings during evaluation BTM51x can cache up to 10 UIDs of an item list in an internal array For a subsequent command a listed item can then be referred by its UidCachelndex which is between 0 and 9 rather than the UID which is 16 characters long Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 78 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module UID cache feature is enabled by default and can be disabled by setting S391 0 The quick start example above also covers this feature 26 5 8 Browsing The browsing feature allows a CT device to navigate view and launch media content on the TG A browsing channel is created automatically on top of an existing AVRCP link when needed After five seconds of no browsing activity the browsing channel is closed by BTM51x This browsing channel handling happens in the background invisible to the user or host c
30. see Table 2 66 For lt Patternid gt see Table 2 66 Table 2 66 LED blink pattern IDs LED off LED on Blink fast Blink medium 0 1 2 3 4 Blink slowly 5 Flash fast 6 7 8 9 Flash medium Flash slowly Pulse fast Pulse medium 0 Pulse slowly 2 7 44 AT SiLx y Test LED blink pattern AT SILx y test LED blink pattern x Led ID O zero LEDO 1 LED1 y blink pattern ID see Table 2 67 This command can evaluate and find a suitable blink pattern Example AT SILO 9 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth pulse medium for LEDO 160 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 27 4 5 LED indication example When not discoverable not connectable the LED should flash slowly just to indicate that the module is powered When any scanning is enabled discoverable only 2 or connectable only 4 or both 8 the LED should blink fast 2 Note that scanning status IDs can be added in order to cover multiple scanning states in one tuple For this example the value is 2 4 8 14 Finally when any profile is connected 16 the LED shall pulse slowly 10 and when AudioOn 17 the LED shall be permanently on 1 The resulting tuples are summarised in the following table Table 2 67 LED sta
31. 0091 Terminator OK ERROR 135 AT AVSG lt n gt Set absolute volume lt n gt volume decimal hex with prefix on TG Range of lt n gt 0 127 Parameters The local volume is adjusted appropriately similar to AT GO lt m gt with lt m gt in 0 15 Note This was not tested due to lack of support on test TG AT AVSSP lt n gt Set addressed Parameters lt n gt player ID decimal hex with prefix selected player Success AVSBP lt plid gt lt nltems gt Failure AVSBP ERROR lt asc gt With lt plid gt browsed player ID confirmation Response lt nitems gt number of items in root folder lt asc gt avrcp status code see Table 2 50 Examples AVSBP 0001 0007 AVSBP ERROR 0091 Terminator OK ERROR 135 AT AVSPUQ Set path upwards one Parameters None level and query Success AVFSL AVFSI Table 2 41 and Table 2 42 Response _ Failure AVFC ERROR lt asc gt With lt asc gt avrcp status code see Table 2 50 Terminator OK ERROR 135 AT AVSPU Set path upwards one Parameters None level Success AVFSL AVFSI Table 2 41 and Table 2 42 Response Failure AVFC ERROR lt asc gt With lt asc gt avrcp status code see Table 2 50 Terminator OK ERROR 135 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 90 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Gui
32. 025 kHz 2 16 kHz 16 kHz 3 22 05 kHz 22 05 kHz 4 24 kHz 24 kHz 5 32 kHz HORNE 32 kHz 6 44 1 kHz S419 0 Gof I ee K 7 aa ie 48 kHz 1 Only for path 12S_IN gt analogue_out DAC Analogue in ADC does not support a 48 kHz sampling rate 0 Disabled Disabled Disabled T2 16 kHz 3 5 32 kHz 44 1 kHz 6 TOR 44 1 kHz 7 48 kHz 48 kHz 589 12 0 22 Codec output gain level index of gain table 590 12 0 22 Codec input gain level index of gain table Set codec output gain in dBr 10 apop 9 SAE applies to sink default 0 Set codec input gain in dBr 10 5620 roe aial ta applies to source default O Set LEDO mode O LED_OFF 335 0 0 3 1 LED_ON 2 LED_PWM 3 LED_PULSE Set LED 0 Duty Cycle 2926 aa Oe referenced if LED mode LED_PWM or LED_PULSE 337 0 0 15 Set LED O PWM Period referenced if LED mode LED_PWM 338 5 0 15 Set LED O Pulse Rate referenced if LED mode LED_PULSE Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 182 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set LED1 mode O LED_OFF 340 0 0 3 1 LED_ON 2 LED_PWM 3 LED_PULSE Set LED 1 Duty Cycle SPA Aoa Pa referenced if ees LED_PWM or LED_PULSE 342 0 0 15 Set LED 1 PWM Period referenced if LED mode LED_PWM 343 5 0 15 Set LED 1 Pulse Rate referen
33. 0x20 Call setup indicator 0x40 Call held indicator Bitmask Bit O Echo cancellation and or noise reduction Call waiting notification capability and three way calling it2 CLIP presentation capability it3 Voice recognition activation Bit 1 it4 Remote volume control B B B Set HF supported B features 5581 it 5 Enhanced call status Enhanced call control currently not supported Bit7 Codec negotiation Note Bit 0 through Bit 4 are advertised in the Service Record of the HF Only CLIP presentation capability Bit 2 0x04 is currently supported in the BTM module After setting a new value to this S register the commands AT amp W and ATZ are required to commit the value Bit 6 SCO audio interface select O Internal codec default Select SCO audio 1 12S master interface BTM5xx 315 2 12S slave only 3 PCM master PCM_M 4 PCM slave PCM_S Refer to Routing audio streams over 12S Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 130 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Not connected SLC connected Audio connected In call SLC In call audio BlWIN oO Inquire HF status ATI65 In call setup incoming dialling alerting SLC In call setup inc
34. 137 AVRCP not connected 138 AVRCP parameter mismatch or out of range e g start offset gt end offset Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 254 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 3 4 Status IDs Automation Table 3 4 lists status IDs These are used with D Regs 744 745 Table 3 4 Status IDs 1 Not connectable Not discoverable 2 Discoverable 4 Connectable 8 Discoverable Connectable 16 Connected any profile 17 AudioOn any audio type 3 5 LED Blink Pattern IDs Status Indication Table 3 5 lists blink pattern IDs These are used with AT SILx y or D Regs 744 745 Table 3 5 Blink Pattern IDs 0 LED off 1 LED on 2 Blink fast 3 Blink medium 4 Blink slowly 5 Flash fast 6 Flash medium 7 Flash slowly 8 Pulse fast 9 Pulse medium 10 Pulse slowly 3 6 List of UUIDs Table 3 6 provides a list of selected UUIDs For a complete list refer to the Assigned Numbers Service Discovery SDP document 8 by the Bluetooth SIG Table 3 6 Selected UUIDs 0x1101 Serial Port Profile SPP 0x1102 LAN access using PPP Embedded Wireless Solutions Support Center http ews support lairdtech com 255 www lairdtech com bluetooth Americas 1 800 492 2320 Europe 44
35. 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0x1103 Dialup Networking DUN 0x1105 OBEX Object Push 7 0x1106 OBEX File Transfer 0x1108 Headset Profile HSP Headset 0x110A A2DP Audio Source 0x110B A2DP Audio Sink 0x110C AVRCP Remote Target 0x110D A2DP Ox110E AVRCP 0x110F AVRCP Remote Controller 0x1112 Headset Profile Audio Gateway 0x111E Hands free Profile HFP Hands free unit 0x111F Hands free Profile HFP Audio Gateway 3 7 Profile Mask as per 102 Table 3 7 below lists the profile mask as defined per 102 Table 3 7 Profile mask as per S102 SPP 0001 HS 0002 HSG 0008 HF 0010 HFG 0040 A2DP 0080 AVRCP 0100 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 256 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 3 8 References 1 2 3 4 5 7 8 9 10 11 12 13 14 15 16 17 Bluetooth Specification Version 2 1 EDR vol3 26 July 2007 https Awww bluetooth org Technical Specifications adopted htm click on Core Specification v2 1 EDR Advanced Audio Distribution Profile Specification Rev V12 16 04 2007 https Awww bluetooth org Technical Specifications adopted htm scroll down to sect
36. 2 indicator to HF If an audio connection is not present yet it is initiated A call record with status dialling is created and can be checked by AT HFGC The optional parameters lt number_string gt and lt type gt is stored in the call record Their format is described in Signal incoming call from AG to HF 4_4 13 For HFG Dnnn AT HFGC1 is the only possible response the HFG can issue If the HFG wants to cancel the HF s call request it shall issue AT HFGC1 first followed by AT HFCH which terminates the call process AT HFGC2 Signal to HF that remote party is reached and is being alerted during an outgoing call setup procedure CIEV 3 3 callsetup 3 indicator is sent to HF If the telephone network does not provide an indication of alerting the remote party the HFG may not send this indication The status of the appropriate call record is changed from dialling to alerting AT HFGC3 Signal to HF that remote party has answered the call CIEV 2 1 call 1 and CIEV 3 0 callsetup 0 indicators is sent to HF subsequently The status of the appropriate call record is changed from dialling or alerting to active Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 133 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT HFGC4 lt number_string gt lt typ
37. 3 2 6 4 4 1 Incoming AVRCP Connection Request An incoming AVRCP connection request is accepted automatically if a valid link key for the paging device exists If no link key is available Secure Simple Pairing SSP BT2 1 or legacy pairing BT2 0 or earlier is carried out depending on the Bluetooth Version of the paging device After an AVRCP connection has been established the module remains in AT command mode S Register 531 is ignored for AVRCP connections 2 6 4 4 2 UNIT INFO Response It is mandatory to respond to a UNIT INFO command if configured as AVRCP target Required response parameters are IEEE Company ID and a Unit Type The IEEE Company ID is a 24 bit integer which can be set via S Register 303 The response is sent automatically with the company ID as per 303 and a fixed unit type of 0x09 Panel 2 6 4 4 3 SUBUNIT INFO Response It is mandatory to respond to a SUBUNIT INFO command if configured as AVRCP target Required response parameters are Subunit type and MaxSubUnitld The response is sent automatically with a fixed value of 0x09 Panel for parameter Subunit type and a fixed value of 0x00 for parameter MaxSubUnitld only one subunit exists which is panel 2 6 4 4 4 PASS THROUGH Indication An incoming PASS THROUGH command is indicated by an unsolicited message AVPTI lt subunit_id gt lt operation_id gt lt button_state gt Embedded Wireless Solutions Support Laird Center http
38. 3 Audio Connection handling M Yes M Yes 4 Accept an incoming voice call M Yes M Yes 5 Reject an incoming voice call M Yes O Yes 6 Terminate a call M Yes M Yes 7 Audio Connection transfer M Yes M Yes during an ongoing call 8 Place a call with a phone number supplied by the HF 9 T M ves 9 Place a call using memory O Yes M Ves dialing 10 Place a call to the last number o Yes M Yes dialed 11 Call waiting notification O Yes M Yes 12 Three way calling O 2 O 2 13 Calling Line Identification CLI O Yes M Yes 14 Echo cancellation EC and noise reduction NR g 65 2 15 Voice recognition activation O Yes O Yes Embedded Wireless Solutions Support Laird Center http ews support lairdtech com www lairdtech com bluetooth 118 Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 16 fone Phone number to a O 5 o 5 17 Ability to transmit DTMF codes O 5 M 4 18 Remote audio volume control O Yes O Yes 19 Respond and Hold O 2 O 2 20 Subscriber Number Information O Yes M Yes 21a Enhanced Call Status O 2 M Yes 21b Enhanced Call Controls O 2 O 2 22 Individual Indicator Activation O Yes M Yes 23 Wideband Speech O Yes O Yes 24 Codec Negotiation O Yes O Yes M Mandatory O Optional 1 support planned for future AT firmware release 2 support planned for future AT firmware release but with lo
39. 4 reject O cap requests Force man in the middle protection MITM 0 disabled 2 0 0 1 e 1 enabled referenced only if security level S320 lt 3 Disable BT2 1 Pairing 5323 0 0 1 isable egacy pre Pairing 0 legacy pairing enabled Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 33 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 1 legacy pairing disabled Secure Simple Pairing timeout in s 324 90 1 255 This value must be at least 60 in order to meet the recommendation of BT2 1 specification 2 5 6 9 Asynchronous SSP messages Table 2 13 lists asynchronous messages which occur if MITM is enabled The sent message depends on the combination of the IO capabilities of both ends The combination of IO capabilities of both devices may be insufficient for MITM protection In that case the pairing fails PAIR 2 lt BdAddr gt Refer to Table 5 6 in BT2 1 EDR specification 1 vol3 Generic Access Profile for sufficient combinations of lO capabilities for MITM authenticated link key Table 2 13 Asynchronous messages for SSP PAIR lt BdAddr gt lt friendlyname gt lt Passkey gt Passkey compare request Prompts the user to Example compare the passkey displayed on both ends and PAIR 0016A4000002 Laird BTM to confirm a match by AT BTBY at both ends
40. 445200 n a 4800 9600 19200 28800 38400 57600 115200 If S register 525 1 then the maximum baud rate is limited to 115200 Change baud rate to non standard value BTM modules support any baud rate The only limitation is the integer arithmetic involved which may adjust the applied rate slightly If the internally computed baud rate is more 1200 than 2 offset from the desired input value then an 521 9521 921600 n a ERROR is returned and the old baud rate will prevail To inspect the actual baud rate use ATS521 S521 should only be used for non standard baud rates For standard baud rates use S520 The effect is immediate and in fact the OK is sent at the Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 233 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module new baud rate If S Register 525 1 then the max baud rate is limited to 115200 In the event that a non standard baud rate is requested it is entirely possible that the host is not capable of generating such a baud rate In this case the module cannot be communicated with If this happens there is a procedure to recover from this situation which is described in Factory Default UART Baud Rate Number of Stop bits 523 1 1 2 n a l See S Register 526 for further information Parity O None 1 Odd S524 0 0 2 n
41. 4_4 13 4 AT HFGBO AT HFGB1 As a prerequisite for this command the in band ring flag 0x08 must have been set in S596 HFG supported features at boot time and a service level connection to the HF shall be established Use AT HFGBO to indicate to the HF that the HFG will not provide in band ring tones subsequently BSIR 0 is sent over the SLC Use AT HFGB1 to indicate to the HF that the HFG will provide in band ring tones subsequently BSIR 1 is sent over the SLC The BTM module does not create ring tones The actual ringtone signal must be provided by an external circuit and injected to the analogue audio input port of the BTM module Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 135 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Response lt cr f gt OK lt cr f gt Or lt cr If gt ERROR 68 lt cr lf gt If no SLC present Or lt cr lf gt ERROR 69 lt cr If gt If in band ring flag was not set in the HFG supported features S596 at boot time 2 6 8 2 13 Subscriber number records CNUM 20_4 30 AT HFGS lt number_string gt lt type gt lt service gt This command adds a subscriber number record to the HFG The subscriber number is the telephone number of the HFG It may have more than one subscriber numbers All subscriber numbers available should be stored in the HFG
42. 511 User Guide Bluetooth Multimedia Module 1 OFF 2 Single Track repeat 0x02 Repeat Mode status 3 All track repeat 4 Group repeat 1 OFF 2 All tracks shuffle 0x03 Shuffle Mode status 3 Group shuffle 1 0FF 2 All tracks scan 0x04 Scan Mode status 3 Group scan Note See also AVRCP1 5 spec p 133 Table 2 45 Folder types 0x00 Mixed 0x01 Titles 0x02 Albums 0x03 Artists 0x04 Genres 0x05 Playlists 0x06 Years Note See also AVRCP1 5 spec p 70 Table 2 46 Media element types 0x00 Audio 0x01 Video Note See also AVRCP1 5 spec p 71 Table 2 47 Play status 0x00 Stopped 0x01 Playing Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 102 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0x02 Paused 0x03 Fwd Seek 0x04 Rev Seek Note See also AVRCP1 5 spec p 67 Table 2 48 Event IDs for notification 0x0001 Playback status changed 0x0002 Track changed 0x0004 Track reached end 0x0008 Track reached start 0x0010 Playback position changed 0x0020 Battery status changed 0x0040 System status changed 0x0080 Player application setting changed 0x0100 Now playing content changed 0x0200 Available players changed 0x0400 Addressed player change
43. 6 this state can be cancelled by AT HSGCH If in band ringing is active ATI64 6 the audio connection is released 2 6 7 2 4 Release audio from HSG side transfer audio from HS to HSG AT HSGR When in Audio connected state the AG can transfer the audio connection from the headset to itself with AT HSGR This releases the audio connection but the ACL connection is retained In ACL connected state the headset HS is able to transfer the audio connection back to the HS by sending AT CKPD 200 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 172 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 7 2 5 Initiate audio from HSG side transfer audio from HSG to HS AT HSGA When in ACL connected state the AG can transfer the audio connection from itself to the headset by AT HSGA This establishes an SCO based audio connection 2 6 7 2 6 Send custom data over ACL HSG AT HSGX lt data gt Send custom data lt data gt over ACL from HSG instance Please refer to section 2 9 24 for details on utilizing ACL for custom data 2 6 7 2 7 Connection release from AG AT HSGH Release existing connection to a HS If the HS is alerted alerting is cancelled If an audio connection exists it is released first ACL is released in either case Response On audio disconnection optional
44. 7 SCK cycles SD_ IN OUT Ase PS Mode Figure 2 33 BTM5 1x 12S data format This standard 12S data format can be modified to customer needs per S register S384 In contrast to earlier f w versions as of v22 2 5 0 it is not required any longer to use a PSKEY for 2S data format modification All settings of PSKEY_DIGITAL_AUDIO_COMFIG are now replaced by 384 Please refer to the S Registers Appendix for details on 384 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 169 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 8 2 1 6 12S Cross Loopback I2S functions can be tested by a feature called 12S Cross Loopback mode In this mode analogue audio input stereo is routed to SD_OUT and at the same time SD_IN is routed to analogue audio output stereo 12S cross loopback mode is enabled by AT BTL3 I2S master role or by AT BTL4 12S slave role Figure 2 34 and Figure 2 35 show a block diagram of I2S cross loopback mode The sampling frequency for this mode can be changed by S Register 419 as outlined inTable 2 77 analogue 12S digital audio z audio stereo ner SD_IN audioin Ca PCM_IN a audio out lt pcm_ouT S2 OUT BTM5xx in 12S ws cross loopback PCM_SYNC _ gt mode master SCK AT BTL3 ooo h6
45. AT BTE lt data gt Accumulate data in RAM buffer for more information Response lt cr f gt OK lt cr f gt 2 5 5 5 AT BTEW Copy RAM buffer to EIR persistent store This command copies all data from the RAM buffer to the non volatile persistent store If the EIR persistent store contains any data at boot time this data is copied to the baseband at boot time automatically Therefore copying data to the EIR persistent store makes it visible to inquiring devices from next power cycle onwards Data passed to the baseband must match the EIR data format as specified in the BT2 1 specification page 1305 in the pdf file See AT BTE lt data gt Accumulate data in RAM buffer for more information Response lt cr f gt OK lt cr lf gt 25 5 6 AT BTE Query data from RAM buffer This command prints the data that is currently stored in the RAM buffer Response lt cr f gt lt data gt lt cr lf gt OK lt cr lf gt 2 5 5 7 AT BTE Query outgoing EIR data from baseband This command prints the outgoing EIR data that is currently set up in the local baseband Some interpretation on the EIR data format is done here If the leading byte of a data block contains information of the wrong length then some unexpected output may appear e g 00 is appended Response lt cr f gt lt EIR data gt lt cr f gt OK lt cr lf gt 2 5 5 8 AT BTEW Query data from RAM buffer This command prints the data that is currently stored in the EIR persist
46. AT HFGCA answered at HFG to HF Intelligently answers a call based on the following situations If acall is incoming ringing answer the incoming call and change status to active Else if a call is waiting incoming call while another call is active the active call is put on hold and the waiting call is answered becoming active Else if a call is held the held call is activated If an active call exists it is put on hold swap If none of the above condition is met then ERROR 063 is returned Signal outgoing call AT HFGC1 lt number_string Outgoing call is being initiated by AG as result of a HF request Use this AT command in response to one of the following asynchronous messages at HFG HFG Dnnn or 1 HFG D gt mmm or 2 HFG L 2 OK is sent to the HF A call record in state ola ling is created lt number_string gt and lt type gt are optional and is be stored in the call record if given lt type gt must be in range 128 175 Refer to Signal incoming call from AG to HF 4 _4 13 Outgoing call Remote party has been reached and is being alerted may not be used if the telephone network does not provide this information Call record state is changed to alerting status to HF update call gt lt type gt record AT HFGC2 AT HFGC3 Outgoing call Remote party has answered the call state of call record is changed to active Embedded Wireless Sol
47. After an SLC connection is established the module remains in AT command mode S Register 531 is ignored for HFP connections Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 131 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 8 2 2 Initiate audio connection from AG 3_4 11 AT HFGA Initiate audio connection from local audio gateway instance An existing service level connection is required This command is not permitted to be issued in a call setup state incoming dialling alerting ATI66 5 or 6 and returns with ERROR 63 in that case Response Audio on lt cr f gt HFG AU1 lt cr lf gt 2 6 8 2 3 Release audio connection from AG 3_4 12 AT HFGR Release audio connection only The service level connection is retained This command is not permitted to be issued in a call setup state incoming dialling alerting ATI66 5 or 6 and returns with ERROR 63 in that case Response Audio off lt cr f gt HFG AUO lt cr lf gt 2 6 8 2 4 Release entire connection from AG 1_ 4 3 AT HFGH Release connection from local audio gateway instance An audio connection is released if existing SLC is released anyway This command is not permitted during a call setup state incoming dialling alerting ATI66 5 or 6 and returns with ERROR 63 in that case Response On audio
48. C S Figure 2 34 BTM5 1x 12S cross loopback master EF 12S digital o audio stereo gt audioin E prsa PCM_IN SD_IN audio out lt PCM_OUT BTM5xx in 12S cross loopback PCM_SYNC mode slave AT BTL4 eMac Figure 2 35 BTM5 1x 12S cross loopback slave 2 8 2 1 7 12S Use case Wave File Player Recorder One of the use cases for I2S is the wave file player recorder In this use case a wave file is the digital source player scenario which is being played back with its recording sampling rate If the recording sampling rate of the file is different to the playing sampling rate a sampling rate conversion must be performed by the player entity before data is put on the 12S bus Play in this context means data is shifted out to the I2S bus SD with clock timing controlled by only WS and SCK Similarly in the wave file recorder scenario an incoming audio bit stream is recorded to memory and the timing is controlled only by SCK and WS In this use case the SCK and WS signal are fully sufficient to synchronize between the two devices Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 170 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 8 2 1 8 12S Use case External Audio CODEC A second use case for I2S is th
49. For testing purposes an audio loopback mode is available Audio loopback mode is controlled by the AT command AT BTLm with m mode 0 4 In mode 1 audio input ADC and audio output DAC are connected directly In mode 2 the stereo audio input signal is fed through the Kalimba DSP with SBC codec running encoder decoder and is directed back to the audio stereo output Table 2 77 BTM51x Audio Loopback AT commands and S Registers Set audio loopback mode AT BTL lt Mode gt Mode O Off 1 On ADC gt DAC 3 On I2S cross loopback master A On 12S cross loopback slave 7 On PCM cross loopback master 8 On PCM cross loopback slave analogue audio stereo gt audio in lt 4 audio out 4 BTM5xx in audio loopback mode AT BTL1 Figure 2 39 BTM5 1x Audio Loopback Modes 1 and 2 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 179 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 8 6 LED Control The module provides two dedicated output pins for LEDs LEDO LED1 The following modes are supported LED_OFF LED_ON LED_PWM and LED_PULSE In LED_PWM mode the parameters Duty Cycle and PWM Period can be specified via S Registers This enables either to dim the brightness of an LED PWM Period 0 o
50. GPIO S Registers av_operation_id Table 2 83 BTM51x GPIO S Registers Mode for GPIO Config Registers S650 0 0 1 0 No mask 1 Enable I O pin state mask S651 GPIO1 a 5652 GPIO2 GPIO Configuration Registers S653 GPIO3 Depending S650 must be set to 0 to enable configuration access S654 GPIO4 o alternative 0 0xFFFF Configures pin state pin direction pin inversion S655 GPIO5 Gpig ee usage notification enable function mapping select and S656 GPIO6 and wiring function mapping code av_operation_id a a See Table 2 82 S658 GPIO8 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 185 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Enable strong bias strong pull up strong pull down mask if GPIO is configured as input 0x0001 GPIO1 Ox0002 GPIO2 0x0004 GPIO3 0x0008 GPIO4 0x0010 GPIO5 0x0020 GPIO6 0x0040 GPIO7 0x0080 GPIO8 Read Write all GPIOs in one atomic step Write operation only affects GPIOs configured as outputs 0x0001 GPIO1 0x0002 GPIO2 S670 GPIO1 8 0x0000 0 0xFF 0x0004 GPIO3 0x0008 GPIO4 0x0010 GPIO5 0x0020 GPIO6 0x0040 GPIO7 0x0080 GPIO8 S669 GPIO1 8 0x0000 0 OXFF 28 8 1 GPIO function mapping codes FMC By using f
51. Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 0x04 Redundant AVTC Track changed notification On reception of redundant track changed event 0 Print AVTC message to UART 1 Suppress AVTC message Note An AVTC message is regarded as redundant if the UID parameters of precedent and current AVTC events are identical We observed redundant AVTC messages during regression test phase 3 0x08 AVNPC Now playing content changed notification On reception of now playing content changed event 0 Print AVNPC message to UART 1 Suppress AVNPC message default We observed multiple redundant occurrences of this message during regression test phase Querying now playing track automatically based on this event did not lead to meaningful results Showing the old track In nearly all cases AVNPC notification was accompanied by AVTC event Querying now playing track based on AVTC event led to meaningful results showing the new track Based on these observations we recommend that you ignore AVNPC However there may be other AVRCP1 5 TG devices which may show a different behavior 4 0x10 AVVC Absolute volume changed on TG notification On reception of absolute volume changed event 0 Print AVVC message to UART 1 Suppress AVVC message default Analogue output gain of the BTM51x is always adjusted on this event regardless of whether or not t
52. Module 3 NEN Notification enable sends a notification to the host via UART on each status change if the GPIO is configured as input If changed AT amp W and ATZ are required for the new setting to become effective Notification format nGPIOx y r n With x GPIO index 1 8 y new pin state 0 1 with INV flag applied O Disable notification 1 Enable notification 4 5 FMS Function Mapping Select Select function mapping code FMC or av_operation_id see Table 2 28 FMC or av_operation_id is set in bit fields 8 15 0 FMS_NONE Function mapping disabled Use GPIO as modem control line Read only Table 2 81 2 FMS_AVRCP_OP Bits 8 15 specify AVRCP operation ID Table 2 28 Bits 8 15 specify Function Mapping Code Table 2 84 and Table 2 85 1 FMS_MODEMCTRL 3 FMS_MAPCODE 6 7 Reserved A Function Mapping Code FMC Table 2 84 and Table 2 85 or an av_operation_id Table 8 15 2 28 is set in this bit field The pin is mapped to a profile specific function A2DP HFP or to function an AVRCP remote control operation and it carries out the assigned operation A mapped mapping code function does not affect any other flag of the GPIO configuration register So e g DIR and INV must be set manually according to the selected function and hardware requirements Valid only if FMS gt 2 FMS selects function mapping code or av_operation_id See also Table 2 53 BTM51x
53. Multimedia External Data Sheet Cambridge Silicon Radio CSR http Awww csrsupport com log in or new account required Bluecore 4 External Data Sheet Cambridge Silicon Radio CSR http Awww csrsupport com log in or new account required RFCOMM with TS 07 10 specification http Awww bluetooth com Specification 20Documents rfcomm pdf CVC on BTM5xx application note provided by Laird Technologies under NDA FW_ReleaseNote_Btm51x_v18 1 3 0 Doc No BTM51xv18 1 3 0 Information guide for Production and Engineering releases of firmware for part BTM510 BTM511 BTM511 Development Kit Quick Start HFPv2 BTM511 Development Kit Quick Start A2DP and AVRCP v2 BTM511 Development Kit Quick Start SPP v2 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 257 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 4 RELATED DOCUMENTS AND FILES The following additional BTM510 511 technical documents are available from the Embedded Wireless Solutions Support Center https laird ews support desk com b_id 1957 BTM510 511 Product Brief BTM510 511 User Manual Firmware BTM510 511 Firmware Files BTM510 511 Firmware Release Notes Version 18 1 4 0 Development Kit Schematics _BTM510 Development Kit Schematics BTM511 Development Kit Schematics
54. S Registers 520 and 521 set the baud rate As long as BAUDRATE 0 004096 produces an integer there is 0 error in clocking for that baud rate It is possible to set a baud rate that a PC can t utilize rendering it nearly incommunicable To cater for this the module comes out of reset using 9600 N 8 1 comms settings for exactly 750 ms and then reverts to the communication parameters as per its S Registers If the host sends the string lt BISM gt lt cr gt where lt cr gt is the carriage return character within that 750ms period then the module remains at 9600 N 8 1 and also configures itself using factory default S Register values If connected to a PC using Ezurio Terminal the module can be reset to the factory default baud rate as follows Right click in the Ezurio Terminal window then click Factory Default gt Via BREAK CMD 9600 Tested with version 6 7 2 of Ezurio Terminal 2 9 16 Rl Dependent Start up Mode The UART_RI line can be configured as an input and on power up its state can force the device into one of two modes defining discoverability and connectability See description for S Registers 565 to 569 inclusive for more details For example the feature may allow a device to make an outgoing connection if RI is in one state and await an incoming connection in the other state 2 9 17 Reset via BREAK The module can be reset by sending a BREAK signal A BREAK signal exists when the module s UART_RX input is
55. Sink default Set A2DP role 300 0 2 2 A2DP Source Needs subsequent AT amp W and ATZ to become effective CONNECT 0123456789012 110D gt Response if rejected NO CARRIER 110D Initiate outgoing Response if accepted A2DP connection AT APD lt bd_addr gt Response u a If connection has existed and close only A2DP AT APH or 5329 0 NO CARRIER 110D connection ATH110D i TEA E connection has not existe and 5329 0 NO CARRIER Response For each profile that was previously connected See Disconnecting Profiles close all connections ATH NO CARRIER lt profileUUID gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 63 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set gain level 589 0 22 default 12 or AT GO lt n gt Set codec output gain level applies to sink Range for lt n gt 0 15 dec 590 0 22 default 12 Or AT Gl lt n gt Set codec input gain level applies to source Range for lt n gt 0 15 dec Set overall gain dBr 10 S689 450 215 Set codec output gain in dBr 10 applies to sink Default 0 690 450 215 Set codec input gain in dBr 10 applies to source Default O Increment Gain AT GOU Increment codec output gain by 1 step in ga
56. StrinG srasni asrnane en E a Padan aaa a 205 2 9 17 Bl etooth VErSION rsrsrs sexetanseesceacsnenvheenttmad shnezetscedenthdd daaseh bnemeeensbossdentaneiepeat 205 2 9 18 Legacy Issues BT2 0 ccccccccccccccccscceccsececesseeeeceseeeecsaeescsaeescesesecscsaeesesateseseeeestaeeeens 205 2 9 19 Factory Default UART Baud Rate ceccceccccecceeeeeeeeeeeeeeceeeeeeeeeeeeeeneeeeteeeeteeenieeentteess 206 2 9 20 Rl Dependent Start Up MOde eececceccececeeeeeee eee cneeeeeceeeeeseeeeeeceeeeseteeeseneeeenteeeeees 206 2 912 1 Reset Via BREAK esi se decsseaahee oat a ea aaieeh cau eaa aaa aioe heehee sean dienes 206 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 4 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 9 22 Append Bluetooth Address to Friendly Name c cccccceeeeeeeeeeteeeeeeneeeeeeneeeeetteteeenes 207 2 9 23 Three Digit Error RESPONSES ccccececeeeeeeceeeceeeeceeeeeecceeeeeeceeesccaeeeseceeeesieeeenseeeeees 207 2 9 24 ATI 54 55 56 status information for all profiles 0 0 ccc cccccccccsceeesseeeeestseeeseteeeeens 207 2 9 25 Management of Persistent Store cccccccecceceeeeeeeeeeeeeeeceeeeneeeeeeeeeneeeseeeeeeetieeeneeens 208 2 9 26 AT SR lt role gt lt pm gt Setting HCI role master slave oo ccccccccccesceccssateeessseeesetseeeens 209 2927 E
57. User Guide Bluetooth Multimedia Module S509 page scan interval ms 11 160 320 S510 inq scan interval ms 2500 640 640 S511 ing scan window ms 11 160 320 Sniff Mode SSR Power Setting Minimum Medium Maximum S348 SSR max remote latency 0 1s 7 3 S349 SSR remote timeout 0 1 10 20 O disabled S350 SSR local timeout 0 1 10 20 S561 SM attempt ms 2 2 S562 SM menut ms 2 30 0 disabled S563 SM min interval ms 50 30 S564 SM max interval ms 100 50 25 25 AT amp F Clear Non volatile Memory The AT amp F variant of the command installs values in S registers as per command AT amp F1 and then erases all user parameters in non volatile memory The trusted device database is cleared as are parameters related to AT BTR AT BTN and AT BTS Response lt cr lf gt OK lt cr lf gt Or Response lt cr lf gt ERROR nn lt cr lf gt 2 5 26 AT amp F Clear Non volatile Memory This command erases all user parameters in non volatile memory except S Registers 520 to 525 This means that the trusted device database is cleared as are parameters related to AT BTR AT BTN and AT BTS Response lt cr If gt OK lt cr f gt Or Response lt cr If gt ERROR nn lt cr f gt 25 2 7 AT amp W Write S Registers to Non volatile Memory Writes current S Register values to non volatile memory so that they are retained over a power cycle Response lt cr lf gt OK lt cr f gt Or Response lt
58. Yes Background operation 5 AV C Info commands O partly See table in BTM51x UM 6 Category 1 Player Recorder C3 Yes 7 Category 2 Monitor Amplifier C3 Yes abs volume TG role 8 Category 3 Tuner C3 untested Not evaluated 9 Category 4 Menu C3 untested Not evaluated 10 Capabilities O Yes 11 Player Application Settings O Yes 12 Metadata Attributes for Current Media o Ves Item 13 Notifications C2 Yes 14 Continuation C2 Yes o ETS Only DOLDY 15 Basic Group Navigation O No 16 Absolute Volume C4 Yes Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 105 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 17 Media Player Selection O Yes 17 1 Supports Multiple Players O Yes 18 Browsing O Yes 18 1 Database Aware Players O Yes UID changed notification 19 Search O No 20 Now Playing C6 Yes 20 1 Playable Folders O Yes untested ee partal 21 Error Response X n a PASSTHROUGH operation supporting press and hold 9 ie 22 Note TG role is still supported on BTM51x with AVRCP version 1 0 features which is not covered by this table Please refer to section AVRCP 1 0 of this document 2 6 7 HSP Headset Profile The Headset Profile provides full duplex audio capability combined with minimal device control commanas Audio bandwidth is limited and deemed t
59. an invalid lt devclass gt value usually a value which is not 6 hexadecimal characters long Response lt cr If gt ERROR O8 lt cr f gt 25 1 5 AT 515 lt devclass gt Set Device Class Code Permanently S Register 515 sets the device class code permanently Use AT amp W to save the setting to non volatile memory The new value becomes visible on next power cycle which can be initiated by ATZ Refer to AT BTC lt devclasshex gt Set Device Class Code Temporarily for more about the device class code Response lt cr lf gt OK lt cr lf gt 2 5 1 6 AT BTC Read Device Class Code This command reads the current device class code Response lt cr lf gt 123456 lt cr f gt OK lt cr lf gt 25 1 7 AT BTF s lt string gt Set Friendly Name Temporarily This sets the friendly name of this device as seen by other devices The new name becomes immediately visible Any name set by this command is lost on next power cycle Refer to S Register Table 3 1 Response lt cr lf gt OK lt cr lf gt 25 1 8 AT BIN lt string gt Set Friendly Name Permanently This sets the default friendly name of this device as seen by other devices It is stored in non volatile memory The new name becomes visible to other devices on next power cycle Use AT BTF to make the name visible immediately Use AT BTN To read it back An empty string deletes the string from non volatile memory which enables the default name Laird BTM 789012
60. as TRUE whenever the audio circuit is turned on regardless of audio type or direction See Table 2 65 for a summary Table 2 65 ACS Status Summary 1 Not connectable Not discoverable 2 Discoverable 4 Connectable 8 Discoverable Connectable 16 Connected any profile 17 AudioOn any audio type 18 Voice recognition on any audio type 2 7 4 2 Status priority The need for simplification also requires definition of a priority scheme The following illustrates the states we want to indicate over time for a typical use case status AudioOn Connected Scanning time other profiles scan status may connect may change or disconnect at any time at any time Figure 2 28 Connection States At first the module is scanning meaning it is discoverable and or connectable A fast blinking LED is often used to indicate this status Then a connection is established for example an A2DP link initiated from a smartphone This status is often indicated by a pulsing LED or flashing at long intervals Later on the user starts audio streaming by playing music from the smartphone This could be indicated by an LED which is permanently on Now while streaming audio AudioOn state another profile could connect or disconnect or the scanning status could change While audio is still on we don t want to indicate the new Connected blink pattern neither a new scanning state blink pattern Instead it is
61. available Secure Simple Pairing SSP BT2 1 or legacy pairing BT2 0 or earlier is carried out depending on the Bluetooth version of the paging device After A2DP connection is established the module remains in AT Command mode S Register 531 is ignored for A2DP connections Version 1 2 of A2DP is supported The A2DP service record contains an optional field which indicates the A2DP supported features of a device This feature field can be set by 312 for a sink and by 313 for a source Refer to Table 2 24 for details Table 2 18 provides an overview on supported A2DP features on a module Table 2 19 lists supported A2DP codec types Table 2 18 A2DP Supported Features on BTM5xx Audio Streaming M mandatory Table 2 19 A2DP Supported Codec Types on BTM5xx Spec oo ose 1 SBC M Yes M Yes 2 MPEG 1 2 Audio O No O No 3 MPEG 2 4 AAC O No O No 4 ATRAC family O No O No M Mandatory O Optional Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 38 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 3 1 A2DP Example 1 This section gives an example of an A2DP connection between a Laird module as Audio Sink wireless speaker wireless headphones and a PC with a built in Bluetooth device and Toshiba Bluetooth Stack 2 1 as Audio Source The PC must
62. be at least 60 in order to meet the recommendation of BT2 1 specification Store link key automatically on dedicated bonding 325 1 0 1 n a outgoing DBO Store link key automatically on general bonding S326 1 0 1 n a outgoing GBO Store link key automatically on dedicated bonding S327 1 0 1 n a incoming DBI Store link key automatically on general bonding 328 1 0 1 n a incoming GBI 329 0 0 1 n a Enable legacy BISM2 response format Configure inquiry response of AT BTI Bitmask O Show device address 1 Show class of device 330 1 1 31 n a 4 Show friendly name 8 Show extended inquiry data Values can be ORed Direction indication style for CONNECT messages O Disabled Character style Append I to incoming and O to 1 outgoing CONNECT message Separated by a comma 331 2 0 2 n a Symbol style Append lt to incoming and gt to 2 outgoing CONNECT message Separated by a comma Applies only to role indicating UUID e g HSP HFP and if 329 0 Enable HS disconnection ATH1108 and ATH O Disabled 1 Enable Default 332 1 0 1 HSP Should only be enabled for test purposes because disconnection initiated by HS other than sending AT CKPD 200 to gateway is not defined in HSP specification 333 1 0 1 HFP Enable verbose indicators Embedded Wireless Solutions Support Laird Center http ews sup
63. called scratch record This section describes appropriate AT commands AT AC Query auto connect scratch record See ATI72 for syntax definition AT ACC Clear auto connect scratch record Set all fields to zero AT ACA lt BdAddr gt Set BdAddr lt BdAddr gt remote device Bluetooth address 12 hex characters AT ACP lt profile_mask gt Set profile mask lt profile_mask gt as defined by S102 See section 14 3 AT ACl lt interval gt Set reconnect attempt interval in seconds lt interval gt decimal number 0 127 AT ACO lt option gt Set option flags lt option gt bitmask see ATI72 lt flags gt for definition Note When using AT ACW to write the scratch record to persistent ACR table it is inserted at the top and obtain highest priority in the ACS processing order Refer to Example for Host less Operation for more details 27 1 3 AT AC ACR table in persistent store non volatile memory This section describes AT commands for passing the ACR scratch record to persistent memory and vice versa as well as how to delete ACR table entries AT ACW Write scratch record to persistent store insert at top prepend highest priority AT ACRn Replace record in persistent store by scratch record n index of record to be replaced in ACR table select from ATI72 response AT ACLn Load copy record from persistent store to scratch record n index of record to be loaded from ACR table select f
64. case It demonstrates the following automation features automatic ACR ACS mode making discoverable connectable by GPIO status indication by LED dynamic registers AT amp F Factory default ATS515 200400 Set class of device ATS370 7 Start AC service at boot time Stop ACS by DSR Auto add new connections to persistent ACR table ATS651 113C Use GPIO1 to make module discoverable and connectable BTM51x mini dev kit all revisions ATS371 32 Set discoverable connectable window to 32 seconds AT amp W Store settings ATS744 1 7 14 2 16 10 17 1 Set LEDO blink patterns ATZ Reset module AT72 Check ACR table Now scanning states can be triggered using GPIO_1 button on BTM511 DVK V04 When in discoverable and connectable state connect to the module from a smartphone Once the connection is established LEDO should start pulsing slowly When audio is transmitted from the phone e g by starting playback of music the LED should turn on permanently as long as audio is activated If you press the GPIO_1 button again the blink pattern should not change because a status with higher priority than scanning is being indicated currently Similarly you may test an incoming SPP connection Connecting or disconnecting SPP should not change the blinking pattern as long as audio is on or another connection exists A2DP AVRCP here After audio playback stops some phones leave the A2DP in streaming mode for a few seconds be
65. class made of ASCII characters 0 to 9 A to F and a to f n A positive integer value m An integer value which could be positive or negative which is a decimal value or in hexadecimal if preceded by the character E g the value 1234 can also be entered as 4D2 lt string gt A string delimited by double quotes E g Hello World The character must be supplied as delimiters lt uuid gt A 4 character UUID number consisting of ASCII characters 0 to 9 A to F and a to f Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 9 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 5 Module Configuration 2 5 1 General AT Commands 25 11 AT Used to check if the module is available Response lt cr lf gt OK lt cr If gt 2 5 1 2 ATEn Enable Disable Echo This command enables or disables the echo of characters to the screen A valid parameter value is written to S Register 506 EO Disable echo E1 Enable echo All other values of n generate an error Response lt cr lf gt OK lt cr If gt Or Response lt cr lf gt ERROR nn lt cr f gt 25 1 3 ATZ lt n gt Hardware Reset and emerge into boot mode n Forces the device through a hardware reset so that it eventually comes alive in local co
66. command interface that simplifies application development including support for audio and headset functionality Access to GPIO pins allows mapping for direct connection to actuator buttons on headsets Combined with a low cost development kit Laird Technologies Bluetooth modules provide faster time to market 1 1 Features 9 Roxs 1 2 Application Areas Fully featured Bluetooth multimedia module High quality stereo headsets Bluetooth v3 0 EDR Mono voice headsets Supports mono and stereo headset applications Hands free devices Adaptive Frequency Hopping to cope with interference Wireless audio cable replacement from other wireless devices MP3 and music players 32 bit Kalimba DSP for enhanced audio applications Phone accessories Support for Secure Simple Pairing VoIP products External or internal antenna options Cordless headsets HSP HFP A2DP and AVRCP audio profiles Automotive 16 bit stereo codec and microphone input Integrated audio amplifiers for driving stereo speaker Comprehensive AT interface for simple programming Bluetooth END product qualified Compact size Class 2 output 4 dBm Low power operation Wi Fi co existence hardware support Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 6 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedi
67. complex settings configuration by AT commands Whereas classic S Registers allow storage of only one value per register BTM51x dynamic registers are organized as a dynamic array meaning that multiple values can be stored In addition array elements are not just single values but tuples of values instead Dynamic registers can be regarded as a two dimensional array with fixed inner length tuple and a variable outer length This structure Is visualised by Figure 2 27 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 156 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module fixed tuple length defined per register Z O OS H 3 E oe Oro 28 i i TIE Figure 2 27 Structure of a dynamic register These registers exist due to automation requirements for host less operation It is increasingly necessary to assign conditional actions to events triggered by a status a profile etc The first dynamic registers implemented are 744 and S745 which assign LED blink patterns to module states The tuple length is defined per register and can vary from one register to another The meaning of the particular tuple values and their range is described in the register documentation 2 7 3 1 Write and Read Syntax For writing values to dynamic registers the existing co
68. connection Auto BTX Bit Description 0 Make the module not discoverable and not connectable when entering a connection When exiting an A2DP connection restore 1 discoverable and connectable state according to 512 Multi profile policy 5308 11 ote Dral ee profiles 00b A2DP only Bits O and 1 apply only for A2DP connections backward compatible O1b Enter auto BTX when all profiles of 3 2 S102 are connected Restore to 512 when one profile is disconnected 10b Enter auto BTX when one profile is connected Restore to 512 when all profiles are disconnected default 11b Enter auto BTX when all profiles of Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 3416 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module S102 are connected Restore 512 when all profiles are disconnected Note The default value of S308 11 makes the BTM51x not discoverable and not connectable after the first profile is connected If more than one incoming connection is expected then S308 must be changed appropriately Refer to section 20 4 8 Default value 11 1011b multi profile policy 10b The current scanning state discoverable connectable can be queried by ATI27 Also refer to Release A2DP Connection Enable asynchronous FS message presenting sampling
69. ews support lairdtech com Americas 1 800 492 2320 63 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module subunit_id should always be zero as a BTM supports only one subunit For operation_id see Table 2 28 hex lt button_state gt 0 is Button pushed 1 is Button released 2 6 4 4 5 PASS THROUGH Response AT AVR lt avrc_response_type gt If S register 310 0 a Pass Through PT response is required from the host The response is sent using the command AT AVR lt avrc_response_type gt Parameter lt avrc_response_type gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 64 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 31 write value If S register 310 1 a Pass Through response is sent automatically with an lt avrc_response_type gt defined by S register 311 In this case the host is not required to respond Table 2 27 AVRCP S Registers and AT Commands Enable AVRCP 256 AVRCP Error 47 if AVRCP role has not been profile set see 301 Error 48 if S301 2 and Category has not been set 102 see 302 Needs subsequent AT amp W and ATZ to become effective Set AVRCP role O Disabled 1 Control CT 2 T
70. friendly than human friendly 1 print ASCII strings surrounded by double ASCII quotes non printable 2 0x04 presentati characters are presented on of hexadecimal as xx A strings character is regarded non printable if it is gt 128 or double quote or backslash or space or comma More human friendly than machine friendly but also more exceptions e g character set On automatic requests for now playing track attributes query Attributes O full set of attributes Title E 0x08 query Artist Album Track no basic full Total tracks Genre Playing time 1 only basic set of attributes Title Artist Album On reception of AVPS Action on ph it notification play status Play changed and if new status is 4 0x10 status playing 0x01 changed notif 0 automatically query now AVPS playing track attributes 1 do nothing Action on On reception of AVTC Track notification track changed 5 0x20 changed 0 automatically query now notif playing track attributes AVTC 1 do nothing Ignored No automatic query Action on of now playing track is Now initiated on reception of playing AVNPC It has turned out 6 0x40 content that this was A not useful changed and B confusing due to notif multiple redundant AVNPC AVNPC notifications up to four observed Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Am
71. gt lt If gt ERROR 58 lt cr gt lt lf gt Minimum gain level reached S register 589 can set the output gain level directly Alternatively S register 689 may set the required overall output gain in dBr multiplied by 10 Refer to Onboard Codec Gain When a DSP application is running typically for audio links the maximum output gain is 15 This is due to DSP operation applying to all audio links 26 3 8 Input Gain Settings A2DP Source AT GIU AT GID AT Gl lt n gt AT GIU Increment audio input gain AT GID Decrement audio input gain AT Gl lt n gt Set absolute input gain lt n gt range 0 15 dec Response lt cr gt lt lf gt OK lt cr gt lt lf gt lt cr gt lt lf gt ERROR 57 lt cr gt lt lf gt Maximum gain level reached lt cr gt lt lf gt ERROR 58 lt cr gt lt lf gt Minimum gain level reached S Register 590 can set the input gain level directly Alternatively S register 690 can set the required overall input gain in dBr multiplied by 10 Refer to Onboard Codec Gain 2 6 3 9 Release A2DP Connection AT APH ATH110D Release an A2DP connection by AT APH Alternatively you may use ATH110D 110D presents the UUID for the A2DP profile Refer to Disconnecting Profiles for more information 2 6 3 10 Suspend A2DP Stream AT APU When creating an A2DP link the module enters the streaming state normally Streaming can be manually suspended using AT APU The A2DP link is retained The asynchronou
72. high power consumption for the slave In general a slave draws about 5 times the current of a master This problem was identified very early in the evolution of Bluetooth especially since headsets are always slaves in a Bluetooth connection and it is solved with Sniff mode with appropriate lower layer negotiating protocol Sniff mode during connection is basically an agreement between the slave and its master that data packets are only be exchanged for N timeslots every M slots The slave can then assume that it will never be contacted during M N slots and so can switch its power hungry circuitry off The specification further specifies a third parameter called timeout T which specifies extra timeslots that the slave agrees to listen for after receiving a valid data packet If a data packet is received by the slave then it knows that it MUST carry on listening for at least T more slots If within that T slot time period another data packet is received the timer is restarted This ensures low idle power consumption at the expense of latency When there is a lot of data to be transferred it acts as if sniff mode were not enabled During sniff mode a slave listens for N slots every M slots The Bluetooth specification states that a master can have up to 7 slaves attached with all slaves having requested varying sniff parameters It may be impossible to guarantee that each slave has its M parameter granted In light of this the protocol
73. http ews support lairdtech com Americas 1 800 492 2320 154 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module No inquiry in progress No pairing in progress Legacy SPP auto connect disabled AT BTR ACR table not empty except automatic host less mode by 370 Bit2 1 An appropriate error message identifies if a condition is not met ATI73 or AT ACS return the status of ACS Refer to description of ATI73 for values 2 7 2 1 ACS parser limitation Once ACS is running a limited number of AT commands is available All ATI commands AT AC ATO AT HSB Any other command returns ERROR 109 To re enable parser functions ACS must be stopped 27 2 2 5370 ACS configuration S370 allows configuration of auto connect service as follows 370 Auto Connect Service mode bitmask Bit O Start AC service at boot time Bit 1 Stop AC service by de asserting DSR Auto add new connections to ACR table reconnect interval 5s auto hostless Bit 2 ACR mode 370 range 0 7 default value 0 unit bitmask 2 7 23 AT ACSn Start Stop ACS AT ACSn start stop auto connect service ACS n 0 Stop service n 1 Start service If n is missing n 0 is assumed hence AT ACS Stop service In order to stop ACS one can either enter AT ACSO or de assert DSR provided Bit1 in S370 is set The latter option ha
74. if AVRCP is not used for its primary purpose or with a non BTM5xx module GPIOs on the AVRCP controller are configured as inputs and GPIOs on the AVRCP target are configured as outputs An AVRCP operation ID is selected on the controller side and on target side for each GPIO This allows a free assignment of inputs and outputs not fixed to the index of a GPIO pin Even identical AVRCP operation IDs are allowed for different GPIOs enabling e g one GPIO input on the controller to drive two or more outputs on the target or vice versa An SPP link is not required but an AVRCP link is Furthermore it may be confirmed on the UART if a transition was successfully received by the target See the AVRCP section for details If an additional SPP connection is required for serial data transmission beside the GPIO this is possible with the GPIO AVRCP approach GPIOs mapped to the alternative function modem contro cannot be used for this variant of digital I O cable replacement See Digital Cable Replacement by RFC Modem Control Signals 2 9 3 3 Digital Cable Replacement by RFC Modem Control Signals This digital O cable replacement variant uses signals defined in the RFCOMM specification O RTC RTR IC DV The primary purpose of these signals is the transmission of digital I O signals simultaneously with serial data over the same wireless link These digital I O signals can be categorized as handshaking signals managing send and receive buffers of serial da
75. in slots S563 S564 M lt mas_int gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 www lairdtech com bluetooth 247 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Number of active slots at the beginning of the sniff interval S561 N lt timeout gt Number of additional active slots S562 T if data is exchanged ATI54 Query remote Bluetooth device addresses of all connected profiles Response per profile line lt profile_mask gt lt BdAddr gt ATI55 Query RSSI value for all connected profiles Response per profile line lt profile_Mask 19 pe gt lt RSSI lt attempt gt _ 102_hex _signed_decimal_with variable_length gt ATI56 Query local HCI role master slave for all connected profiles Response per profile line lt profile_Mask s102 pe gt i lt M S gt ATI57 Query profile flags of current connections same format as S register 102 ATI58 Query number of current connections total sum of ATI60 ATI67 ATI59 Returns 1 if a pre set PIN code by AT BTK is available legacy pairing Returns 0 otherwise The PIN code is not displayed for security reasons ATI60 SPP connection status 0 Not connected 1 Connected Identical with AT19 ATI61 A2DP connection status 0 Not connected 1 Connected and streaming 2 C
76. input gain level AT Gl lt n gt Range for lt n gt 0 15 dec Query current input gain AT Gl level Restore current input gain AT GIR level from S590 Save current input gain AT GIS level to S590 2 8 1 2 Onboard Mic Input Gain S Register 415 controls a microphone preamplifier which adds extra 24 dB to input gain The amplifier is enabled by ATS415 1 and disabled by ATS415 0 Refer to Table 2 72 The first amplifier in Figure 2 31 represents the microphone preamplifier and the second amplifier represents the analogue component of the programmable audio input gain refer to Table 2 73 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 16s Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Switches shown for Line Mode S415 0 Bypass or 24dB gain 3dB to 18dB gain o EROE p 2 2 3 gt gt T5777 Line Mode Mic Mode Gain 0 7 Microphone Mode input impedance 6kQ Line mode input impedance 6kQ to 30kQ Figure 2 31 BTM5 1x ADC Analogue Amplifier Block Diagram 2 8 2 Digital Audio Interface Bluecore BCO5 allows audio streams to be routed to a digital audio interface instead of the internal codec These sections describe details of the digital audio interface 28 2 1 12 Inter Integrated Circuit Sound 12S is a digital interface to transmit st
77. interval parameter differs across multiple ACRs without all profiles connected yet the smallest interval applies and is displayed If not applicable e g no ACRs exist response is 0 ATI75 Current incoming peer address regardless of how it was set AT BTM lt bd_addr gt or AT BTG P lt bd_addr gt If not set response is 000000000000 ATI80 AVRCP 1 5 diagnostics lt extensions gt lt features gt lt event_caps gt lt registered_evts gt lt player_features gt Intended for issue tracking ATI101 The RSSI value in dBm If a connection does NOT exist then a value of 32786 is returned A value of 0 means the RSSI is within the golden range this is quite a large band therefore RSSI is not always a useful indicator Use ATI111 instead which returns the bit error rate Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 249 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module ATI111 Returns LinkQual which in the CSR chipset is defined as BER bit error rate This returns a value which is the number of erroneous bits out of 1 million Hence a value of O is best and larger values are worse A value near 1000 BER 0 1 indicates bad link quality with a high number of lost Bluetooth packets ATI200 Manufacturing data e g module serial number manufacturing
78. is invalid for A2DP 2 6 3 4 Select A2DP Role The A2DP role is selected by S register 300 as follows 0 No role selected 1 A2DP Sink default 2 A2DP Source The setting must be saved by AT amp W and takes effect on next power cycle ATZ CAUTION If S300 0 at boot no role selected 102 is set with the A2DP flag 0x80 the A2DP flag is cleared automatically A2DP cannot be enabled without a role selected 2 6 3 5 Set A2DP Device Class A1TS515 lt device_class gt AT amp W ATZ hex For compliance with the A2DP specification 2 and hence for successful interoperability to other devices you must set up a valid device class code The default device class code of a module is 0x001F00 which is invalid for A2DP The A2DP specification 2 mandates the following requirements for the device class of an A2DP device Mandatory to set the Rendering bit for the SNK and the Capturing bit for the SRC in the Service Class field Recommended to set Audio Video as Major Device class both for the SNK and the SRC Select the appropriate Minor Device class as defined in the Bluetooth Assigned Numbers 8 There is a tool available online named Class of Device generator made for creating a particular device class code refer to 9 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 45 Europe 44 1628 858 940 www lairdtech com bluetooth Ho
79. lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVNPA Now playing track AVNPA lt pt gt lt attid gt lt cs gt lt VI gt Pt packet type P O single 1 Start attribute saa 2 Continue 3 End see section 2 6 5 10 p attid attribute ID UI8 hex Options see Table 2 43 S390 cs character set UI16 hex Hint string inserted after lt attid gt eno ouneae value UI16 hex lt av gt printed in hexadecimal aouta volest format without av attribute value string of indicated character set non printable characters presented as xx optionally hexadecimal format see S390 16h Examples AVNPAO 02 Artist 006A 000B Barry White AVNPAO 02 006A 000B 4261727279205 768697465 AVTC Track changed AVTC lt uid gt uid UID of new track notification Ul64 hex if S390 bits 0 automatically query and display attributes of now playing track like AT AVQNP AVPV Player application AVPV lt nAttld gt lt nVal gt nAttld attribute ID UI8 setting attribute hex see Table 2 44 value pair nVal attribute value Ul8 Option hex see Table 2 44 S390 bitO 1 Hint strings inserted after lt nAttld gt and after lt nVal gt AVPA Player application AVPA lt nAttld gt nAttld attribute ID UIS setting attribute hex see Table 2 44 only Option 390 bitO 1 Hint strings inserted after lt nAttld
80. link key 40 Invalid link key 41 Link loss not working as expected for SPP 42 No service level connection SLC 43 Invalid parameters A2DP 44 Remote link key missing not working as expected for SPP Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 244 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 255 Unknown reason ATI12 The last ERROR response number ATI13 The Sniff status is returned as follows Response lt cr f gt a b c d e lt cr lf gt OK lt cr lf gt a O when not online and 1 when online and sniff has been enabled b Sniff Attempt parameter c Sniff timeout parameter d Minimum sniff interval e Maximum sniff interval All parameters b c d and e are given as Bluetooth slots which are 625 ms long converted from values of S Registers 561 562 563 and 564 respectively ATI14 The current boot mode ATI15 The maximum length of an AT command not including the terminating carriage return ATI16 Codec Output Maximum Gain Range ATI17 Codec Input Maximum Gain Range ATI18 Bluetooth version ATI19 Audio connection status O Off 1 On ATI20 Returns the number of pending bytes in the RF buffer during a connection ATI21 The index of the profile instance owning an active SCO co
81. monitoring disconnect events 27 2 6 ATI74 Query current ACS interval in seconds ATI74 returns actual current reconnect attempt interval in seconds In scenarios where the interval parameter varies across multiple ACRs which have some disconnected profiles the smallest value of those ACRs applies and displays 2 7 2 7 Attempt cycle order rules When ACS attempts connections it starts with ACR entries with the lowest index the highest priority If not all of the profiles specified are connected the connection attempt starts attempting to connect all profiles in this record After connection attempt to one or all profiles fails or after successfully connecting ACS updates the status of the ACR entry and proceeds with the next ACR entry in the order of increasing index If a record is found whose profile mask overlaps with a higher priority lower index record and if the higher priority record is at least partly connected the current lower priority record is not processed by ACS The duration of an attempt cycle can vary significantly depending on the number of parameters such as number of profiles number of ACR entries and connection result success or failure The reconnect interval timer starts when ACS finishes a attempt cycle If the reconnect interval varies across multiple ACR entries the lowest interval applies ATI74 returns the actual current interval in seconds 2 7 3 Dynamic Registers Dynamic registers allow
82. of a connected pair In a message NO CARRIER lt UUID gt UUID represents the local profile role UUID Hence for an asynchronous profile role indicating UUIDs differ on both ends of a previously connected pair Table 2 93 provides an overview of currently used UUIDs on BTM devices Table 2 93 UUIDs used in BTM5xx CONNECT NO CARRIER messages 1101 SPP No Synchronous profile 1108 1 HSP HS Yes Headset role Headset profile 110D A2DP No Common UUID for source and sink role 110E AVRCP No ee UUID for controller and target 1112 HSP AG Yes Audio gateway role Headset profile 111E HFP HF Yes Hands free role Hands free profile 111F HFP AG Yes Audio gateway role Hands free profile There is an option to append a direction indicator to a connect message This enables the host to distinguish an incoming connection from an outgoing connection based on the CONNECT message The direction indicator only applies to role indicating UUIDs if 329 0 The direction indicator is configured by S register 331 refer to Table 2 94 Table 2 94 Examples for direction indication in CONNECT messages Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 198 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module i Disabled CONNECT CONNECT 0123456789AB 1108 0123456
83. on inquiry result 0 do not display friendly name on inquiry result If any further bit is set a comma is inserted as separator 3 RSSI Receiver signal strength indicator RSSI 1 display RSSI value on inquiry result 0 do not display RSSI value on inquiry result If any further bit is set a comma is inserted as separator 4 EIRD Extended inquiry response data 1 display EIRD on inquiry result 0 do not display EIRD on inquiry result 2 5 42 Inquiry Response format The format of an inquiry result is lt cr lf gt lt bd_addr gt lt dev_class gt lt friendly_name gt lt rssi gt lt eir_data gt lt cr lf gt lt bd_addr gt 12 digit hexadecimal lt dev_class gt 6 digit hexadecimal lt friendly_name gt printable ASCII character enclosed by lt rssi gt signed 2 digits decimal lt eir_data gt printable ASCII character whenever possible otherwise a byte is displayed pug as 2 digit hexadecimal with preceding enclosed by For example the hexadecimal data block 01 41 42 43 44 02 03 34 35 36 040A OD is presented as 01ABCD 02 03456 04 0A 0D No validation is performed on incoming EIR data If a higher significant flag is set and a lower significant bit is not set in 330 for each disabled item a comma is printed Example 330 9 ADDR enabled COD and FN disabled RSSI enabled Inquiry Response lt cr lf gt 123456789012 54 lt cr lf gt 123456789
84. particular UID cache index always refers to the last printed list Response Success AVFSL AVFS AVMEI Table 2 41 and Table 2 42 Failure AVFC ERROR lt asc gt With lt asc gt avrcp status code see Table 2 50 plus subsequent automatic queries due to track changed event play status changed etc depending on S390 Terminator OK ERROR 135 AT AVSP lt n gt set path downward Parameters lt n gt UidCachelndex 0 9 or UID 16 hex Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 91 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module characters prefix not required The parameter is expected to be chosen from an earlier file system such as AT AVOQFS In particular UID cache index always refers to the last printed list Success AVFC lt nitems gt See also Error Reference source ot found Response Failure AVFC ERROR lt asc gt With lt nitems gt number of items in new path lt asc gt avrcp status code see Table 2 50 Terminator OK ERROR 135 AT AVSV set player application AT AVSV lt nAtt gt lt nVal gt ee e g repeat AT AVSVE lt nVa gt Equaliser nAtt 1 shufileete Syntax AT AVSVR lt nVal gt Repeat nAtt 2 AT AVSVS lt nVal gt Shuffle nAtt 3 dec
85. possible to change the remote gains with an absolute value or incrementally Incoming notifications about HF gain changes are displayed by UART message and are also cached internally at HFG The latter allows to query current remote gain settings plus incremental change of the values up down 2 6 9 MPS compatibility layer MPS multi profile specification defines procedures which devices must follow if multiple profiles are supported simultaneously For BTM51x this concerns A2DP AVRCP and HFP One typical use case is a stereo headset hands free device A2DP SNK AVRCP CT and HF unit and another one the opposite a stereo audio source HF gateway A2DP SRC AVRCP TG HFG typical use case ofa phone but also supported by BTM51x Ina MPSD multi profile single device scenario all profiles are connected from the local device to one single remote device Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 149 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module In MPMD multi profile multi device scenarios profile A e g HFP connects to remote device1 profile B e g A2DP AVRCP connect to remote device2 and so forth MPS addresses use cases in which an active A2DP stream is temporarily suspended in order to serve a call process of HFP This involves managing audio resources an
86. preferred mode for a host microcontroller 2 6 8 2 25 Call status vs HFG status Table 2 60 maps the call states to HFG states For more information about HFG status refer to section HFG audio routing Table 2 60 Mapping of call status and HFG status incoming ringing 5 6 8 dialling 5 6 8 alerting 5 6 8 active waiting 5 6 8 alerting 3 4 8 held 3 8 2 6 8 2 26 Audio Gateway HFP Asynchronous Messages CONNECT lt bd_addr gt lt uuid gt lt dir gt A Service level connection to headset is established and initialized lt bd_addr gt Headset device Bluetooth address lt uuid gt 111F Incoming connection 111E Outgoing connection lt dir gt lt gt 0 Refer to 331 and UUIDs in CONNECT NO CARRIER Messages HFG VGS lt n gt Speaker gain setting message was received from HF VGS lt n gt with n gain 0 15 Note lt n gt now displays two digits padding with a leading O if the n value is lt 9 HFG VGM lt n gt Microphone gain setting message was received from HF VGM lt n gt with n gain 0 15 Note lt n gt now displays two digits padding with a leading O if the n value is lt 9 FS8000 INT Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 141 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Mod
87. profile or service the Android device does not require an authenticated link key and that an unauthenticated link key is sufficient which is contrary to requirements of the initial pairing If the actual profile connection or services do not require an authenticated link key then initial pairing should not set such requirement either because it rules out devices which strictly adhere to the Bluetooth specification v2 1 EDR with regards to Secure Simple Pairing In order to work around this a feature has been added which allows BTM51x to tolerate and continue a pairing process even if I O capabilities are insufficient to create an authenticated link key MITM protection Obviously the resulting link key type will be unauthenticated 3 rather than authenticated 4 The link key type can be double checked using AT BTT It is appended to the list of paired devices BTM51x s tolerant pairing policy feature is enabled by 382 1 It is not enabled by default because from Laird s point of view although tolerant pairing may not break the Bluetooth specification it is weakening the approach to security measures introduced by Secure Simple pairing BT Core Spec V2 1 EDR Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 213 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 3 APPENDIX 3 1 S Registe
88. remote device is expected to initiate the connection or pairing during this time window LED blink patterns can be configured to indicate the connectable discoverable status as described in previous sections 2 7 4 7 Input FMC 0x11 5371 enter discoverable connectable mode with time window For input FMC 0x11 the following rules apply A time window can be set by 371 in seconds If 371 is zero the module remains discoverable and connectable until changed by another AT command Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 161 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module f S371 is greater than zero the module reverts automatically to not discoverable and not connectable on timeout f auto connect service ACS is running while FMC 0x11 is performed button pressed ACS is suspended before turning connectable discoverable On subsequent window timeout 371 gt 0 ACS is resumed 371 range 0 900 default value 0 unit seconds Granularity of this 371 4 if value is lt 60 round up 60 if value is gt 60 round down See GPIO function mapping codes FMC for details on how to configure GPIO function mapping codes 2 7 5 Example for Host less Operation This section gives an example for host less operation of a typical headset or wireless speaker use
89. response is 1 1 then VRA should be working Enable Disable Query for Wideband Speech status AT HFW lt x gt lt x gt 1 0 As a precondition for this command WBS codec negotiation bit 7 must be enabled in HF supported features S581 at boot time 2 6 8 1 21 Disable noise reduction echo cancellation in HFG 14_4 24 AT HFZ Disable NR EC in HFG AT NREC 0 sent on SLC Feature 14_4 24 of HFP1 5 spec This command is only allowed if both HF and HFG have declared NREC support in their HF HFG supported features see 581 HF and S596 HFG Otherwise ERROR 89 is returned AT HFF and AT HFFN allow to query currently supported HFP features 2 6 8 1 22 Query supported features locally and remote AT HFF Query local HF and remote HFG supported features SF HFP SLC is required Response lt HF_SF gt lt HFG_SF gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 124 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Refer to S581 for a definition of local HF supported features Refer to S596 for a definition remote HFG supported features 2 6 8 1 23 Query NREC flag locally and remote AT HFFN Query NREC noise reduction echo cancellation flag of local HF and remote HFG supported features HFP SLC is required Response lt HF_NREC gt lt HFG_NREC gt
90. support A2DP If it is a different stack the procedure must be similar and follow these steps 1 Device discovery 2 Device Selection 3 Pairing 4 Connection establishment e g initiated by PC If you have a Bluetooth 2 0 or earlier stack on your PC legacy pairing with PIN occurs In that case use AT BTK lt PIN gt to enter the PIN on the module This assumes the BTM5xx device is connected to a terminal program e g Ezurio Terminal on a PC The sequence of AT commands and the instructions for the PC side are listed in Table 2 20 Figure 2 7 through Figure 2 12 are screenshots of the process Table 2 20 A2DP Example 1 Command Sequence Preparation AT amp F Restore factory default settings A2DP profile is enabled per default in 102 Audio Sink role is enabled per default in S300 ATS515 04040 Set A2DP device class BTM5xx 0 ATS512 4 Make device connectable and discoverable permanent setting AT amp W Store settings ATZ Reset Preparation PC n a 1 Open Bluetooth Settings from the taskbar Connection icon Figure 2 7 A2DP example 1 PC setup Bluetooth settings 2 Click on New Connection Figure 2 7 A2DP example 1 PC Bluetooth settings 3 Click Next Discover BT Devices Figure 2 8 Select Laird BTMM if not listed click Refresh Figure 2 9 5 Click Yes on Allow this Device to connect Figure 2 10 Connection is initiated by PC
91. that a fixed rate is configured by 419 which will apply if the air rate changes After releasing the audio from device A AT HFR we disable WBS on device B so that any subsequent SCO link will be at 8kHz narrow band Initiating audio again on device A shows indeed an air rate of 8kHz FS8000 PCM M 16000 Now the difference between air rate 8kHz and PCM rate 16kHz indicates that the relevant up sampling is taking place Finally we close audio and SLC The screenshot below shows both FS messages Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 177 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Ezurio Terminal Ver 6 8 0 CTS DSR OCD AI RTS DTRM BRKI CAP COM38 9600 N 8 1 al FS8000 PCM_M 16200 HF AU1 Ki 2 8 3 Audio Routing Options for SCO Table 2 76 provides an overview of combinations between profiles and audio interfaces that are supported SCO audio refers to bidirectional mono audio for transmission of speech with 8 kHz or 16 kHz sampling rate The PCM pins of the BTM51x share support for PCM I2S and SPDIF 315 selects one of these interfaces or the internal codec internal codec refers to the on board audio ADC DAC clock generator and antialiasing filters hence the onboard analogue interface SPDIF is currently not supported but seems feasible 1
92. the requested operation was not successful i e memory location invalid or last dialled number not available 2 6 8 3 Wideband Speech Wideband speech uses a 16 kHz audio sampling rate and a modified SBC codec mSBC to compress the voice data for bi directional transmission over a limited bandwidth eSCO link The higher sampling rate compared to 8 kHz for legacy narrowband CVSD leads to a more natural sound of the voice If WBS is supported both HFP parties must also support the Codec Negotiation feature During the codec negotiation WBS support availability is checked If either end indicates that WBS is enabled it is used for subsequent audio links WBS can be temporarily disabled by any of the following AT HFWO AT HFGWO ATS376 0 Use one of the following to check the current status of WBS support AT HFW or AT HFGW AT HFGW returns the status for both local HFG and remote HF separated by a comma Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 148 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module By default WBS is enabled When entering an HFP audio link with FS16000 the sampling frequency of 16 kHz is a strong indication that WBS is in use The difference between narrowband and wideband speech can be demonstrated by the following setup sequence
93. their alternative functions Table 2 81 BTM51x GPIO Alternative Functions GPIO1 BT_Active GPIO2 DCD GPIO3 DSR GPIO4 RI GPIO5 BT_State BT_Priority GPIO6 Wlan_Active GPIO7 Rf_Active GPIO8 DTR 1 Alternate function for modem control lines is fixed A modem control line cannot function as GPIO 2 Recommended pin assignment not configurable by S Registers Contact Laird if coexistence is required 3 BT_Active RxEnable OR TxEnable Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 function mapping code reserved FMS NEN INV DIR PS av_operation_id Default 0 0 0 0 O0 0 0 0 0 0 0 0 0 0 0 0 Figure 2 40 BTM5 1x GPIO configuration register Table 2 82 BTM5 1x GPIO Configuration Register Field Descriptions O PS I O Pin State returns the current state of the I O pin 0 1 when read A write affects the I 0 pin directly if DIR 1 and FMS 0 FMS_NONE 1 DIR Direction controls if the I O pin is an input or an output O Input 1 Output 2 INV Inversion controls if the I O pin is inverted or not Applies to both pin directions read and write 0 Not inverted 1 Inverted Embedded Wireless Solutions Support Center http ews support lairdtech com 184 www lairdtech com bluetooth Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia
94. which explains plenty of details about sniff mode SM and sniff sub rating SSR SM SSR registers of BTM51x were designed to be identical to relevant BTM41x registers BTM41x low power application note is highly recommended for reference This section only covers the most important facts briefly In f w version v22 2 5 0 sniff mode can be configured to be actively initiated for SPP HSP and HFP Previously only passive mode was supported i e remote requests for sniff mode were accepted but not actively requested When sniff mode is enabled the same parameters will apply for all of the three profiles SPP HSP HFP and to all remote devices connected if multiple A differentiation on a per device basis is currently not supported Sniff mode configuration S Registers 561 S564 have been re worked for v22 2 5 0 resulting in a mapping between milliseconds and slots as outlined in Table lt please insert cross reference gt below When writing to S Registers 561 to 564 begin with 564 sniff interval in order to prevent ERROR 037 internal plausibility checker Further new S registers related to sniff mode S364 Delayed Sniff mode experimental Refer to the BTM41x Low Power Application Note for additional information It can be accessed from the Laird Embedded Wireless Support Site BTM41x product page under the Documentation tab S365 Set first row of LP_power_table active Refer to the BTM41x Low Power Application Note for add
95. wizard will create the settings for Bluetooth device connection Add New Connection Wizard Select a device DRE Cara et Me oooo04 Figure 2 9 A2DP example 1 Select Bluetooth device Click Refresh if Laird BTMM is not listed Bluetooth Manager Bluetooth Security Figure 2 10 A2DP example 1 Confirm pairing here Secure Simple Pairing no PIN required Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 41 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Bluetooth Settings x Bluetooth View Help Bluetooth Laird BTMM 000004 CE Figure 2 11 A2DP example 1 Connection established a Device Manager File Action View Help e m Erea emala DB DYD CD ROM drives 5 Human Interface Devices IDE ATA ATAPI controllers 4 IEEE 1394 Bus host controllers gt Keyboards j Mice and other pointing devices i Modems Monitors E9 Network adapters p PCMCIA adapters 3 Ports COM amp LPT a Processors X Smart card readers E E E e Audio Device a gt D Legacy Audio Drivers Legacy Video Capture Devices b Media Control Devices b SigmaTel High Definition Audio CODEC Video Codecs System devices Universal Serial Bus controllers Figure 2 12 A2DP example 1 New Bluetooth Audio Device in the Devic
96. 0 BTM510 511 User Guide Bluetooth Multimedia Module 2 7 2 Auto Connect Service ACS ooeccccccccccccccccccccccccceeeeceeeeeecesensennnnsnnneenvaeeeeeeeeeeeeeeenenenenees 154 2 13 Dynamic REISTE Seesen renna a a a Ea detente 156 2 7 4 Status INGICAtION cece cece eee e ee cneeeeeeeee eee ceeeeeeceeeeeeeeescneeeeeceeeeseneeeseseeeentieeeeees 158 2 7 5 Example for Host less Operation ccccccceeeeceeeeeeeeeeeeeeeeeeeeeeeeeeeeeeneeesseeeteeenieeeneeens 162 2 8 Hardware Units BTM510 511 ccecceceecccceeeceeessnenssseseeeeeeeeeeeesesseeeeeeeeeeseeestnnnnnnnnnnaas 162 2 8 1 Analogue Audio INtert aCe esinsin aenea haen Eai aa 163 2 8 2 Digital Audio Interface ce ccceccccccececeeceeeeeeeeeeeeeeseeeeeeceeecuseeeeeeeeteeeteeeneeeteeenteees 166 2 8 3 Audio ROUTING Options f r SCQessseieri ireann ann N eE Ea AEREE EEE FE 178 2 8 4 SCO IMp tOutput Channel a cc set cncsnnnsdse aiora aa ai ianea aaa aan rE EEAS 179 2 8 5 Audio L ophack MOd isriarssesselirstherisaanisisnnen idonea E dhdepedeetanate 179 29 60 TED COMTO siiret a e A aaan 180 2 8 7 Hardware Units S Registers ccccccceeeseeceeeeneeeeceeeeeeceeseeeaeeeecnaeeeseneeeesceeeeseeeeteas 180 2 8 8 GPIO General Purpose Input Output ee eee eeeeceeeeeeteeeeeeeeeeeeeeteeeeteeeeteeeteeenteeess 183 229 MiscellaNe OU Sisenen eea a OEA EEA EN ETENEE ESE 188 2 9 1 CVC Noise Reduction and Echo Cancellation ccccccccceeeeeceeeeeeeee
97. 001 M master in the link with device of SPP device B 0080 S slave in the link with device of A2DP device C 0100 S slave in the link with device of AVRCP device C If no profile connected response is O zero 2 9 21 Management of Persistent Store Extensive use of the persistent store non volatile memory can lead some AT commands or functions to unsuccessfully finish and causing an error message This section explains the background of persistent store and suggests strategies to avoid these scenarios 2 9 21 1 Persistent store characteristic The persistent store of BTM51x is made of flash memory which has the typical characteristic that a single bit can be written only once For deletion of data a larger area a so called segment must be deleted in common This means that all data of the segment would be lost So in order to delete a small amount of data but retaining all other data of the segment the data to be deleted is not actually deleted but is invalidated by internal flash memory pointers Similarly overwriting does not actually delete old data but stores the new data in the remaining space of the segment and declares the old location invalid by pointing to the new location The flash segment fills up with each write or delete operation to persistent store At some point the segment becomes full and write delete operations fail causing error messages e g ERROR 011 or ERROR 102 The firmware has a built in mechani
98. 014 54 lt cr lf gt OK lt cr lf gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 17 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 25 4 3 AT BTIV lt devclass gt Inquire As per AT BTI but the response comprises for all inquiry responses Bluetooth device address Device class code S register 330 is not referenced 2 5 44 AT BTIN lt devclass gt Inquire As per AT BTI but the response comprises for all inquiry responses Bluetooth device address Device class code Friendly name S register 330 is not referenced 2 5 4 5 AT BTIR lt devclass gt Inquire As per AT BTI but the response comprises for all inquiry responses Bluetooth device address Device class code Friendly name RSSI receiver signal strength indicator S register 330 is not referenced 2 5 4 6 AT BTlE lt devclass gt Inquire As per AT BTI but the response comprises for all inquiry responses Bluetooth device address Device class code Friendly name RSSI receiver signal strength indicator Extended inquiry data S register 330 is not referenced 2 5 5 AT Commands for Extended Inquiry Response Data Bluetooth 2 1 specification allows up to 240 Bytes of extended inquiry data On BTM5xx modules this data is limited to a maximum length of 112 Bytes due to int
99. 1108 is still used as identifier for the Headset role in CONNECT and NO CARRIER messages In HSP1 0 headset role Ox1108 was assigned to both ServiceClassO and ProfileO i e it appeared twice in the service record of a HS unit and once in the service record of the audio gateway Predecessors of the BTM510 511 e g BISM2 have used 0x1108 as identifier for the Headset role This is inherited on BTM510 511 and is the reason why 0x1108 is still used in BTM510 511 CONNECT and NO CARRIER messages Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 199 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module The logically correct UUID for the HS role would be 0x1131 When using the AT BTIV lt BdAddr gt UUID to query UUIDs of a remote device in order to determine supported profile and roles the user must be aware of the circumstances described here E g do not assume the remote device supports the headset role if UUID 0x1108 is found in the service records Check for UUID 0x1112 2 9 10 Low Power Operation In order to decrease power consumption a couple of options should be considered Page inquiry scanning When not connected but in page scanning connectable or inquiry scanning discoverable mode then the scanning windows can be reduced and scan intervals can be increased in order to l
100. 11ms gives 11 25 ms refer to Page Scan Inquiry Scan Interval and Window Page Scan Window in milliseconds Minimum is 11 25 509 160 11 2550 n a ms so 10 11ms gives 11 25 ms refer to Page Scan Inquiry Scan Interval and Window Inquiry Scan Interval in milliseconds Minimum is 11 25 510 640 11 2550 n a ms so 10 11ms gives 11 25 ms refer to Page Scan Inquiry Scan Interval and Window Inquiry Scan Window in milliseconds Minimum is 11 25 511 160 11 2550 n a ms so 10 11ms gives 11 25 ms refer to Page Scan Inquiry Scan Interval and Window Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 231 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Specify power up state 512 1 0 7 n a When set to 0 AT BTO is required to open the device for Bluetooth activity When set to 1 It proceeds to a state as if AT BTO was entered When set to 2 It is discoverable only similar to issuing AT BTQ When set to 3 It is connectable but not discoverable e g AT BTG When set to 4 It is connectable and discoverable e g AT BTP When set to 5 It is like 2 but all UART RX traffic is discarded in absence of a connection while DSR is asserted If DSR is not asserted then it behaves exactly as per mode 2 When set to 6 It is like 3 but al
101. 123456789012 1112 gt lt cr If gt gt hex gt The remote hex Or lt cr lf gt NO CARRIER lt cr f gt Or lt cr f gt ERROR 59 lt cr lf gt Or lt cr If gt ERROR 63 lt cr f gt After an ACL connection has been established the module remains in AT command mode S Register 531 is ignored for HSP connections An audio connection should be established within short time The command is AT HSB 2 6 7 1 2 Send AT CKPD 200 AT HSB Send AT CKPD 200 to connected audio gateway This indicates a user action on the gateway e g a button press Depending on the audio connection state the audio gateway either establishes or releases the audio connection subsequently Refer to Figure 2 26 Table 2 53 Outcome of AT HSB ACL connected ATI63 1 Audio link is to be initiated by AG Referred to as Audio Connection Transfer from AG to HS in HSPv1 2 Audio connected Audio link and ACL should be released by the AG actual outcome ATI63 2 depends on AG 2 6 7 1 3 Send custom data over ACL HS AT HSX lt data gt Send custom data lt data gt over ACL from HS instance Please refer to section 2 9 24 for details on utilizing ACL for custom data 2 6 7 1 4 Release connection from headset AT HSH Release connection from local Headset instance Audio connection is released if existing ACL is released regardless A connection release initiated by the Headset is not defined in the Headset Profile specification 4
102. 20 is less than 3 For security level S320 3 MITM protection is always enabled and this S 322 is ignored Anew value written to 322 applies immediately No power cycle is required A link key created with MITM protection is named authenticated link key A link key created without MITM protection is named unauthenticated link key 25 6 4 Disable Legacy Pairing 323 If the remote device is a legacy device BT2 0 or earlier legacy pairing with usage of PIN codes is used Legacy Pairing can be disabled by S Register 323 1 but then pairing with legacy devices always fails 2 5 6 5 SSP Timeout 5324 The SSP timeout s is defined by S Register 324 The timeout must be at least 60 s to meet the BT specification requirements 1 This time must be long enough for the user to compare or read and input a 6 digit number A time of 90 seconds is recommended which is the default value Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 22 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 5 6 6 SSP Input commands Table 2 11 lists all AT commands related to SSP input operations Table 2 11 SSP Input commands AT BTBY Accept pairing request Representing yes input AT BTBN Reject pairing request Representing no input AT BTB012345 Enter 6 digit passkey displayed by rem
103. 320 125 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Not connected SLC connected Audio connected In call audio connected In call setup incoming dialling alerting SLC connected 0 1 2 3 In call SLC connected 4 5 6 In call setup incoming dialling alerting audio connected 2 6 8 1 28 Hands free asynchronous messages CONNECT lt bd_addr A Service level connection to gt lt dir gt headset has been established and initialized ra gt lt UUId lt bd_addr gt Bluetooth address of headset device siud gt 111E If it is an incoming connection nes 111F If it is an outgoing connection lt dir gt lt gt 0 Optionally indicates the direction incoming outgoing Refer to S331 and UUIDs in CONNECT NO CARRIER Messages HF has received a RING indication from the connected audio gateway HF RING HF is expected to respond with ATA answer see AT HFCA or AT CHUP see AT HFCH HF has received ERROR from the connected audio gateway This can be 7 n due to a request for memory dialling with invalid memory location HF ERROR AT HFC gt mmm or a request to redial the last number AT HFDL There is no last number available in the AG if this error appears The internal codec is configured for a sampling frequency of 8000 Hz FS8000 INT narr
104. 3A Indicate voice recognition status for HFG FMC out 8 GPIO7 ATS657 083A 2 8 8 2 GPIO AVRCP operation ID Another GPIO option particularly for AVRCP is the assignment of AVRCP operation IDs e g play stop pause etc to GPIOs This allows a module in AVRCP controller role to send a pass through command triggered by a push button instead of an AT command and respectively an AVRCP target can signalize incoming pass through commands on GPIO outputs If AVRCP functionality is not required in the application it can alternatively serve as a digital IO cable replacement As an advantage it does not need an SPP link and does not require a confirmation on the UART about the success or failure of a pass through command See Cable Replacement for this purpose Table 2 84 BTM51x GPIO Function Mapping Codes Input 0x00 Cable Replacement TX Cable replacement via SPP data 0x01 RFC_RTC_TX Cable replacement via RFC control signals 0x02 RFC_RTR_TX Cable replacement via RFC control signals 0x03 RFC_IC_TX Cable replacement via RFC control signals 0x04 RFC_DV_TX Cable replacement via RFC control signals 0x05 Volume down single step Decrease output gain by one see AT GOD 0x06 Volume up single step Increase output gain by one see AT GOU 0x07 Volume down multiple after short press AT GOD S411 0x08 Volume up multiple after short press AT GOU S411 0x09 Volume down mult
105. 4 90 14400 9 8 8 1280 0 8 95 104 100 16000 10 9 9 1440 0 9 105 114 110 17600 11 10 12 10 1600 1 115 124 120 19200 12 13 17 15 2400 1 5 125 134 130 20800 13 18 22 20 3200 2 135 144 140 22400 14 23 27 25 4000 2 5 145 154 150 24000 15 28 32 30 4800 3 155 164 160 25600 16 33 37 35 5600 3 5 165 170 170 27200 17 2 9 11 Maximum RF Tx Power Level 541 and S542 control the maximum RF transmit power level for all operation states inquiring connecting in connection 2 9 12 Manufacturing Info String A string with manufacturing information can be retrieved by ATI200 2 9 13 Bluetooth Version The Bluetooth version can be queried by ATI18 2 9 14 Legacy Issues BT2 0 There are some special cases if a legacy device BT2 0 or earlier e g BISM2 requests a connection to a module BT2 1 General bonding does not work if initiated by the legacy device Instead the legacy device must initiate dedicated bonding first pairing BISM2 AT BTW lt BdAddr gt After successful pairing the connection can be initiated by the legacy device BISM2 ATD lt BdAddr gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 205 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 9 15 Factory Default UART Baud Rate BTM devices may operate at a very wide range of baud rates
106. 4 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module PAIR 3 lt BdAddr gt Pairing failed too many repeat attempts PAIR 4 lt BdAddr gt Pairing rejected by remote device PAIR 5 lt BdAddr gt Pairing failed unit keys not supported PAIR 6 lt BdAddr gt Pairing failed SSP not supported PAIR 7 lt BdAddr gt Pairing failed already busy with pairing 1 If both devices have a KeyboardOnly capability no pass key can be displayed In that case the user is required to invent and enter the identical 6 digit numeric passkey at both ends 2 it was observed that scenarios which would have returned PAIR 2 pairing failed with f w v18 1 4 0 do return PAIR 1 pairing timeout with f w v22 2 5 0 It may be necessary to review existing host controller source code to avoid issues due to f w upgrade 2 5 7 AT Commands for Legacy Pairing 25 7 1 AT BTW lt bd_addr gt Initiate Pairing Provided the remote device is a Bluetooth 2 0 device or earlier and legacy pairing is not disabled S323 0 this command initiates legacy pairing with the device with lt bd_addr gt Legacy pairing refers to the mechanism of entering an identical PIN key on both ends If the PIN is required if not set earlier by AT BTK lt PIN gt asynchronous indications are sent to the host in the form PIN lt bd_addr gt The address confirms t
107. 40 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module lt button_state gt represents Button pushed 0 or Button released 1 If lt button_state gt is not specified two PASS THROUGH commands each with button_state 0 and button_state 1 are consecutively created and sent The OK response is sent immediately on receipt of AT AVC command On completion an unsolicited message is sent to the host in the form AVPTC lt n gt lt bd_addr gt lt button_state gt AVPTC means AVrcp Pass Through Confirmation Parameter n indicates the command s status n 0 successful command confirmation received from target n 1 timeout target has not sent confirmation within the specified maximum time n 2 all other unsuccessful outcomes Parameters lt operation_id gt mandatory see Table 2 27 lt button_state gt optional O Button pushed 1 Button released Response lt cr f gt OK lt cr lf gt immediately And lt cr lf gt AVPTC lt n gt lt operation_id gt lt button_state gt lt cr f gt after command completion If status n indicates an unsuccessful outcome lt operation_id hex gt and lt button_state gt are omitted hex 2 6 4 4 AVRCP Target TG This section describes AT Commands and S registers for when BTM5xx is configured as an AVRCP Target S301 2 In this mode BTM5xx supports one subunit PANEL see
108. 510 511 User Guide Bluetooth Multimedia Module 2 6 8 1 16 DTMF tone request 17_4 27 AT HFM lt x gt with lt x gt 0 9 A D Request a DTMF tone to be created by a connected HFG e g mobile phone The command AT VTS lt x gt is sent on the SLC Refer to HFP 1 5 specification feature 17 section 4 27 This command has been tested with an iPhone COD 515 200404 and a Samsung E250 2 6 8 1 17 Enable disable call waiting notification AT HFN lt x gt lt x gt 1 0 Causes the HF unit to send AT CCWA 1 or AT CCWA 0 across to HFG over SLC 2 6 8 1 18 Query support for Voice Recognition Activation AT HFFV Query support for Voice Recognition Activation on local HF and remote HFG end based on HFP supported features 2 6 8 1 19 Enable disable query toggle Voice Recognition Activation 15_ 4 25 AT HFV lt x gt lt x gt 1 0 T Enable disable query toggle voice recognition activation Voice recognition activation VRA is a HFP feature which is intended to be used with applications such as Siri iPhone or other voice recognition applications Once an SLC connection is established from a HF unit the easiest command to start this is the toggle function AT HFVT This switches VRA on if it is off and vice versa The toggle function can also be controlled by a push button GPIO FMC 0x1 2 2 6 8 1 20 As a precondition both ends must support VRA feature AT HFFV Allows to double check this If the
109. 52 2923 0610 Center http ews support lairdtech com www lairdtech com bluetooth BTM510 511 User Guide Bluetooth Multimedia Module AT HSGH ATH1112 Response If HSG instance was connected response NO CARRIER 1112 NO CARRIER If HSG instance was not connected response NO CARRIER AT HFH ATH111E Response If HF instance was connected response NO CARRIER 111E NO CARRIER If HF instance was not connected response NO CARRIER AT HFGH ATH111F Response If HFG instance was connected response NO CARRIER 111F NO CARRIER If HFG instance was not connected response NO CARRIER 2 9 8 UUIDs in CONNECT NO CARRIER Messages In profiles where functionality and command set differs between both possible roles asynchronous profiles role indicating UUIDs are used in the CONNECT and NO CARRIER messages HSP and HFP are asynchronous profiles A2DP and AVRCP are treated as synchronous profiles because only one profile instance with one role selected can be initialised currently Therefore a common UUID is used indicating the profile only but not the role In a message CONNECT lt bd_addr gt lt UUID gt UUID is the profile role the connection is made to Hence for an outgoing connection UUID indicates the remote device s profile role If it is an incoming connection UUID indicates the local device s profile role UUID Hence role indicating UUIDs presented in a CONNECT message are equal on both ends
110. 6 1 n a If SS65 1 and RI is asserted then the device boots into this mode S567 1 n a If S565 1 and RI is de asserted then the device boots into this mode S568 1 n a If S565 1 and RI is asserted then the device assume this mode after the post start up timeout SReg 554 instead of mode defined in SReg555 S569 1 n a If S565 1 and RI is de asserted the device boots into this mode after the post start up timeout SReg 554 instead of the mode defined in SReg555 581 Ox9C 0 OXFF Set HF supported features Bitmask Bit O Echo cancellation and or noise reduction Call waiting notification capability and three way Bit 1 calling Bit 2 CLIP presentation capability Bit 3 Voice recognition activation Bit 4 Remote volume control Bit 5 Enhanced call status Bit 6 Enhanced call control not currently supported Bit 7 Codec negotiation Default value Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 240 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Codec negotiation 0x80 Remote volume control 0x10 Voice recognition 0x08 CLI presentation 0x04 Note Bit 0 Bit 4 of these settings are advertised in the Service Record of the HF Only CLIP presentation capab
111. 6 44 1 kHz 44 1 kHz 7 48 kHz 1 Only for path I2S_in gt analogue_out DAC BTM51x analogue in ADC does not support 48 kHz sampling rate 2 8 2 4 1 Fixed Sampling Rate Example A In this first example we assume the following Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 174 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module External codec with 12S interface Fixed sampling rate 48 kHz Use for A2DP sink and for SCO HF AT amp F Restore factory default settings ATS102 90 Enable profiles A2DP HF ATS314 1 Configure I2S master for A2DP ATS315 1 Configure I2S master for SCO ATS419 7 Configure fixed sampling rate for A2DP and SCO 48kHz ATS512 4 Make discoverable and connectable at boot time ATS515 200400 Set device class to be found by A2DP sources AT amp W Save settings ATZ Reset After this configuration we use an iPhone to find the BTM51x and connect to it Pairing should automatically occur and A2DP and HF will connect Next we start playing music on the iPhone The audio output is routed to the connected BTM51x A2DP and we can see the FS message from FS44100 12S M 48000 This shows that the air rate is 44 1 kHz audio being routed to 12S in master role 25_M and the output rate is 48 kHz The fact that air rate and 12
112. 6 8 1 6 Reject incoming call from HF Terminate call from HF 5_4 14 6_4 15 AT HFCH Rejects incoming call terminate ongoing call AT CHUP is sent to the AG In return the audio gateway updates its indicator call O and sends the appropriate CIEV message to the HF HF notifies its host by a HFl lt indicator gt lt value gt message Refer to Refer to DTMF tone request 17_4 27 2 6 8 1 7 Place call with number provided by HF 8_4 18 AT HFC nnn Initiates a new call from HF to the number specified by the number string nnn This command sends ATDnnn to the audio gateway 2 6 8 1 8 Memory dialling from the HF 9_4 19 AT HFCM mmm Initiates a new call from HF to the number stored in memory location mmm of the AG This command sends ATD gt mmm to the audio gateway Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 121 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 8 1 9 Re Dial last number from HF 10_ 4 20 AT HFCL Initiates a new call from HF to the number last dialled by AG AT BLDN is sent to the AG In return the audio gateway updates its indicator callsetup 2 and sends the appropriate CIEV message to the HF HF notifies its host by a HFl lt indicator gt lt value gt message Refer to DTMF tone request 17_4 27 2 6 8 1 10 Enable Caller Line Identification P
113. 6789012 1101 gt lt cr f gt Or lt cr If gt NO CARRIER lt cr lf gt Due to a known issue in the Bluetooth RFCOMM stack it is not possible to make more than 65525 outgoing connections in a single power up session Therefore if that number is exceeded then the connection attempt fails with the following response Response lt cr lf gt CALL LIMIT Or lt cr If gt NO CARRIER lt cr f gt In that case issuing ATZ to reset the device resets the count to 0 More connections are made available 2 6 2 4 AT SPDL Remake Connection Make a SPP connection with the same device as that specified in the most recent AT SPD command An error is returned if the L modifier AND a Bluetooth address are specified For backward compatibility the following command fulfils the same purpose ATDL Response lt cr If gt CONNECT 123456789012 gt lt cr lf gt Or lt cr If gt NO CARRIER lt cr f gt 2 6 25 AT SPDR Make SPP Connection to peer specified in AT BTR Make a SPP connection with the device address specified in the most recent AT BTR command An error is returned if the R modifier AND a Bluetooth address are specified For backward compatibility the following command fulfils the same purpose ATDR Response lt cr If gt CONNECT 123456789012 gt lt cr lf gt Or lt cr If gt NO CARRIER lt cr lf gt 2 6 2 6 AT SPH Drop SPP Connection Drop an existing SPP connection or reject an incoming connection indicated by unsolicited RING m
114. 7 Bit Description O STD 1 BEX 2 WBS Note For a detailed list of CVC available images see ATI318 ATI36 Status of boot time CVC license check applies if S318 gt 0 ATI37 Query SCO link type O unknown no SCO link 1 SCO 2 eSCO ATI38 Display Type SysID BuildNo FriendlyName and CSR SDK of all available A2DP decoders capable of post processing Syntax lt CodecTypeString gt lt Sysld gt lt BuildNo gt lt PostProcFriendlyName gt lt ADK version gt hex hex Note ATI38 only works when the BTM51x does not have any connection If A2DP is in streaming mode sink role the current decoder can be queried by ATI26 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 246 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module ATI39 Query current DSP image plus short string descriptor lt DsplmagelD gt lt ImageName gt lt ScoType gt Examples 13 x1mw eSCO wideband speech 11 x1m eSCO narrowband CVSD 00 n a no SCO audio link nor DSP image currently active ATI42 State information The response values are as follows 13 NotOpen 14 Openidle 15 Ringing 16 OnlineCommand 172 to 177 indicate waiting for connectable and or discoverable where the third digit equates to the value stored in S Register 512 or 555
115. 7 Device Class could not be stored 008 Invalid Device Class Code 009 Invalid Bluetooth Address 010 Could not set Service or Friendly name 011 PS Store Write 012 PS Store Read 013 Not Idle 014 Incorrect Mode 015 Already Scanning 016 Pairing is already in progress 017 Not USED 018 Not USED 019 Not USED 020 Not safe to write to Non volatile Store Ongoing Bluetooth Connection 021 Link Key Cache is Empty 022 Link Key Database is Full 023 Malloc returned NULL Resource Issue 024 Remote Address same as Local Address 025 Connection Setup Fail DSR Not asserted 026 Unauthenticated licence 027 Max Responses too high See S Register 518 Memory allocation error 028 Pin in AT BTK is too long 029 Invalid Ring count for S Register O or 100 If S0 lt gt 0 and S100 lt gt 0 then SO must be lt 100 030 ADC Error 031 Analogue Value cannot be read It is set for output 032 Analogue Value cannot be written It is set for input 033 S Register Value is invalid 034 Both L and R modifier cannot be specified in ATD command 035 Invalid Major Device Class valid value in range 0x00 to Ox1F inclusive Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 251 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 036 Pairing in progress Command cannot be actioned try again later Invalid
116. 789AB 1108 Character style CONNECT CONNECT 0123456789AB 1108 0 lor O 0123456789AB 1108 2 default SYTO style CONNECT CONNECT 0123456789AB 1108 gt crau zors 0123456789AB 1108 lt 2 9 9 UUIDs in Service Records of HSP This section provides some background information on UUIDs and their usage in service record of the Headset profile In the Bluetooth Assigned Numbers document 8 in the table Service classes there are three UUIDs assigned for the HSP Table 2 95 Bluetooth Assigned Numbers for HSP HSP uuid16 0x1108 See Headset Profile Bluetooth SIG Headset AG uuid16 0x1112 See Headset Profile Bluetooth SIG Headset HS 0x1131 Bluetooth Headset Profile Bluetooth SIG In the service record for HSP 1 2 Headset role 4 page 21 the following values are assigned Table 2 96 Selected items of HSP headset role service record ServiceClassO Headset 0x1131 Profiled Headset Profile 0x1108 In the service record for HSP 1 2 Audio gateway role 4 page 22 the following values are assigned Table 2 97 Selected items of HSP audio gateway role service record ServiceClassO Headset Audio Gateway 0x1112 Profiled Headset Profile 0x1108 The tables above show that UUID 0x1108 identifies the Headset profile whereas the role is explicitly identified by the ServiceClassO UUID 0x1131 HS 0x1112 HSG Although UUID 0x1108 appears in the service records of both Headset unit AND Audio Gateway 0x
117. 9s ATI412 3 re dial after long button press S411 S412 S413 default 4 9s ATI413 1 currently v22 2 5 0 not available reserved for future Table 2 85 BTM5 1x GPIO Function Mapping Codes Output 0x00 Cable Replacement RX Cable replacement via SPP data 0x01 RFC_RTC_RX Cable replacement via RFC control signals 0x02 RFC_RTR_RX Cable replacement via RFC control signals 0x03 RFC_IC_RX Cable replacement via RFC control signals 0x04 RFC_DV_RX Cable replacement via RFC control signals 0x05 Indicate status Audio On Active whenever the audio circuit is enabled 0x06 Indicate status Connected Rete ene Pieler 0x07 Indicate voice recognition status HF 0x08 Indicate voice recognition status HFG 1 currently v22 2 5 0 not available reserved for future 2 9 Miscellaneous 2 9 1 CVC Noise Reduction and Echo Cancellation Clear Voice Capture CVC is a technology provided by Cambridge Silicon Radio CSR which utilises the BCO5 internal DSP in order to improve the audio quality of SCO links speech This includes noise reduction and echo cancellation Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 188 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module CVC is supported by BTM5xx from firmware version 18 1 2 3 onwards CS
118. A SPP smart disconnect 0 Disable Default 1 Enabled With this setting BTM51x detects if there is any data pending in its internal buffers on an incoming disconnect 319 0 0 1 Misc notification If so then BTM51x delays the disconnection until all pending data has been delivered to the UART first and then signals the disconnection on UART NO CARRIER and on DCD line This is an experimental feature which may have side effects in certain situations It was ported from BTM41x as the result of fixing bug Ref 3 21 285 Security Level see 1 vol3 Generic Access Profile Table 5 7Z SA20 g we nae Needs subsequent AT amp W and power cycle to take effect value 3 overwrites 322 Set IO capability O Display only 321 1 0 4 SSP 1 Display yes no 2 Keyboard only 3 No input no output 4 Reject lO cap requests Force man in the middle protection MITM O Disabled 322 0 0 1 SSP 1 Enabled Referenced only if security level S320 lt 3 Disable legacy pre BT2 1 Pairing 323 0 0 1 SSP O Legacy pairing enabled 1 Legacy pairing disabled 324 90 1 255 SSP Secure Simple Pairing timeout in s Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 219 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module This value must
119. AT GOU or o indication of Change BTM51x local output gain AT GOD or i changed volume lt n gt absolute output gain range 0 15 AT GO lt n gt e g slider OK command terminator Response E position OK Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 26 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Command AT AVSVR Change repeat mode to 3 Make sure that All tracks set player AT AVSVR3 slayer a application setting Response ae Player application setting AVSV OK application is AVSV OK change success displayed on confirmation Of OK c d terminat a seraanand ommand terminator ubsequent messages aime List of current player AVPC 0002 l AVPC application settings repeat Change of shuffle etc triggered b AVPV 02 Repeat 03 All tracks g i P 0 PPE repeat mode to AVPV 03 Shuffle 01 Off 0002 Two items to follow Repeat All AVPC OK oi Attribute value pair of or similar AVPV player application setting with hint strings AVPC OK List end 2 6 5 3 AVRCP1 5 Application Notes In contrast to previously supported AVRCP1 0 AVRCP1 5 introduces a number of advanced features for control of a remote audio player such as Browsing the virtual file system on the TG media player change path select a media element item i e a track
120. AVRCP category 0 Feature disabled 1 Player recorder Default 302 1 0 4 AVRCP 2 Monitor amplifier 3 Tuner 4 Menu Needs subsequent AT amp W and ATZ to become effective Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 Sit Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set Company Id 5303 FFFFFF 000000 AVRCP IEEE Company ID 24bit hexadecimal required for UNIT FFFFFF TG INFO Response in AVRCP target mode default value is OxFFFFFF Enable Unit Info Response 305 ai AVRCP O Reject incoming Unit Info Requests TG Accept incoming Unit Info Requests and send 1 response automatically default with Company ID as per S303 and unit type 0x09 Panel fixed Enable Subunit Info Response 5306 i T AVRCP O Reject incoming Subunit Info Requests 7 TG Accept incoming Subunit Info Requests and send 1 response automatically default with Subunit type 0x09 Panel fixed and MaxSubUnitld 0x00 fixed Enable optional A2DP codec 0 No optional codec Default 1 APTx Bit 0 307 0 0 3 A2DP 2 AAC Bit 1 sink only 3 Both APTx and AAC enabled Subsequent AT amp W plus ATZ required for a new value to become effective Automatic control of discoverable connectable mode when entering and exiting A2DP
121. AVSBP ERROR lt asc gt asc avrcp status code UI16 hex part of AT AVSBP response sent while AT parser is suspended and prior to OK AVBS Battery status of AVBS lt nBS gt nBS battery status remote TG changed notification Options if S390 bitO 1 Hint string inserted after lt nBS gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 99 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVSSP Set addressed Successful plid player ID UI16 hex selected player confirmation AVSSP lt plid gt asc avrcp status code Not successful UI16 hex AVSSP ERROR lt asc gt part of AT AVSSP response sent while AT parser is suspended and prior to OK AVFC Folder path Successful ni number of items in changed l new folder UI16 hex confirmation AVFC lt Ni en gt Not successful asc avrcp status code UI16 hex AVFC ERROR lt asc gt part of set path command family AT AVSP response sent while AT parser is suspended and prior to OK AVPI Play item Successful asc avrcp status code confirmation UI16 hex AVPI 0000 Not successful AVPI ERROR lt asc q gt part of AT AVSPI response sent while AT parser is suspended and prior to OK AVSS System status of AVSS lt nsS gt n
122. BTC lt devclasshex gt Set Device Class Code Temporarily 2 6 3 6 Initiate A2DP Connection AT APD lt bd_addr Initiate A2DP connection to Bluetooth address lt bd_addr gt The remote device must support the complementary role to the local device If link keys are missing in one or both devices pairing either occurs automatically or must be initiated by AT BTW lt bd_addr gt This depends on factors like the combination of local and remote IO capabilities or the Bluetooth version of the remote device gt hex Response lt cr gt lt lf gt PAIR 0 lt bd_addr gt 00 3 lt cr gt lt If gt first time only auto pairing without MITM authent lt cr gt lt If gt CONNECT lt bd_addr gt 110D gt lt cr gt lt lf gt Or lt cr gt lt lf gt NO CARRIER 110D lt cr gt lt lf gt not successful 2 6 3 7 Output Gain Settings A2DP Sink AT GOU AT GOD AT GO lt n gt AT GOU Increment audio output gain volume AT GOD Decrement audio output gain volume AT GO lt n gt Set absolute output gain lt n gt range 0 15 dec Response lt cr gt lt lf gt OK lt cr gt lt lf gt lt cr gt lt lf gt ERROR 57 lt cr gt lt lf gt Maximum gain level reached Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 46 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module lt cr
123. BTM51x AT commands or interaction with a remote device So whenever a BTM51x AT command exists for a particular purpose this command should be used rather than the direct method Only if a feature may be missing this command may be used However it is still possible that internal state issues may occur in such scenarios and such usage is entirely at the users risk Custom commands should be designed in a way that there is no ambiguity with existing AT commands as defined in the HFP specification One criteria is that the remote parser doesn t recognise the command and issues an UC message unknown command as explained in the following section Receiving commands from SLC There are two taps to display incoming SLC ACL data The first is before the SLC ACL parser and the second is the one after the parser if the command is not recognized The first tap should be used for debugging or learning purposes the second should be used for customer commands See Figure 2 44 The following explains how to enable the asynchronous tap messages Temporary valid until power cycle or until reverted AT RX1 Enable all SLC RX messages first tap AT UC1 Enable all unknown command messages second tap Permanently valid as of next power cycle 379 1 Enable all SLC RX messages first tap 380 1 Enable all unknown command messages second tap plus subsequent AT W and ATZ HSRX lt data gt HSGRX lt data gt Display any da
124. Bluetooth Multimedia Module in band ringing Cancel HSG must be in alerting state ATI64 5 or 6 alerting HSG stops sending RING message or release audio before AT HSGCH in band ringing answered by HS Initiate audio An existing SLC is required Transfer AT HSGA audio from AG to HS Release audio Response a PTE If successful OK and HSG AUO ransfer Audiofr i If wrong state ERROR 63 HS to AG If profile role disabled ERROR 59 Release audio Response and SLC from NO CARRIER 1112 AG Aneel If successful AG HSP was previously ATH1112 or connnected ATH If wrong state ERROR 63 If profile role disabled ERROR 59 Enable 0 Disable auto alerting automatic 7 alerting on 1 Auto alerting on outgoing ACL established ACL 5345 2 Auto alerting on incoming ACL established establishment 3 Auto alerting on outgoing and incoming ACL established Sie O Disable in band ringing in band S346 TEA ringing 1 Enable in band ringing Enable 0 Disable automatic S347 7 z ACL release 1 ACL is released automatically when audio is released by the HS Select SCO SCO audio interface select eae 0 Internal codec Defaul interface nternal codec Default BTM5xx 1 12S master only S315 2 125 slave 3 PCM master PCM_M 4 PCM slave PCM_S Refer to Routing audio streams over 12S Embedded Wireless Solutions Support Laird Center http
125. CNUM is sent to the HFG HFG sends the subscriber number information indicated on the HF by HF CNUM On termination OK is sent by HFG which is indicated by HF CNUM OK If the HFG does not support this feature it should send ERROR indicated as HF CNUM ERROR Refer to Hands free asynchronous messages Response Immediately BTM accepting command lt cr gt lt lf gt OK lt cr gt lt lf gt Plus one of the following lt cr gt lt If gt HF CNUM lt number gt lt type gt lt service gt lt cr gt lt lf gt refer to Hands free asynchronous messages lt cr gt lt If gt HF CNUM OK lt cr gt lt lf gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 122 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module OR lt cr gt lt lf gt HFX lt SLC_message gt lt cr gt lt lf gt original SLC response from HF gateway but response format not compliant to HFP specification lt cr gt lt If gt HF CNUM OK lt cr gt lt lf gt OR lt cr gt lt lf gt HF CNUM ERROR lt cr gt lt lf gt feature not supported by HF gateway OR Nothing if the HF gateway ignores this query for any reason 2 6 8 1 14 Query Operator Selection 2_4 8 AT HFO Query operator selection from HFG AT COPS is sent to the HFG HFG sends the operator selection information indica
126. DSR DCD RI ATS DTR BRK CAPTURE Echo Clear Data Transfer Test Open Samu COM15 9600 N 8 1 es io Terminal er 6 7 5 E loj x CTS DSR DCD RI ATS DTR BRKI CAPTURES Echo Clear Data Transfer Test Open COM15 9600 N 8 1 AT APD G16A4000004 PAIR 001644000004 00 CONNECT 901644000004 110D gt FS44100 INT APSTR gt AT APH NO CARRIER 110D Figure 2 15 A2DP Example 2 Initiate and Release Connection from Device B Source Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 44 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module EJezurio Terminal Yer 6 7 5 0 x CTS DSA DCD AI RTSY DTR BRKJ CAPTURES J Echo Clear Data Transfer Test Open COM4 9600 N 8 1 a PAIR 001644000003 20 CONNECT 001644000003 118D lt FS44100 INT APSTR lt AT GOU OK AT GOD OK NO CARRIER 110D Figure 2 16 A2DP Example 2 Accepting Connection and Volume Adjustment Device A Sink 2 6 3 3 Enable A2DP The advanced audio distribution profile A2DP is enabled by issuing ATS102 128 After verifying that a role is set S300 0 the S registers must be saved by AT amp W and then issue ATZ to make the new settings effective If the A2DP flag in S102 0x80 is not set after these steps then S300 was 0 at boot time which
127. E ATH See Disconnecting Profiles and UUIDs in CONNECT NO CARRIER Messages Send custom data on Maximum data length 26 characters lt data gt a string of printable ASCII characters or the two digit hexadecimal presentation of a non printable character preceded by AT HFX lt data gt r r must be used to terminate a command or block HF instance SLC of data This feature can be used to transmit short data sequences or commands but is not suitable for transmitting large amounts of data Refer to Figure xx 0 display indicator ID only in HFI asynchronous Enable verbose 5333 message refer to DIME tone request 17_4 27 indicators 1 display indicator string in HFI asynchronous message refer to DIME tone request 17_4 27 ENS eS One O Disable WBS 8kHz also applies to S376 incoming SPP SCO 1 Enable WBS 16kHz default Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 129 BTM510 511 User Guide Bluetooth Multimedia Module requests Bitmask HFP indicators enable 0x01 Service indicator mask Individual 0x02 Signal strength indicator indicator activation 5381 0 0x7f 0x04 Roaming status indicator See also HFP1 6 spec f 0x08 Battery charge indicator search for AT BIA y g command 0x10 Call indicator
128. Enter 0x2B F4 0x74 Clear Ox2C F5 0x75 Channel up 0x30 Vendor unique 0x7e Channel down 0x31 Table 2 29 AV C Unit Subunit Types Monitor 0x00 Reserved 0x08 Audio 0x01 Panel 0x09 Printer 0x02 Bulletin board Ox0A Disc 0x03 Camera storage OxO0B Tape recorder player 0x04 Vendor unique Ox1C Tuner 0x05 Reserved for all 0x1D CA 0x06 Extended 0x1E Camera 0x07 Unit Ox1F Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 aT Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 30 AVRC Respons Types Not implemented 8 0 Accepted 9 1 Rejected 10 2 Note Incoming pass through commands AVPTI are not displayed to the host if this is the value of 311 In transition 11 3 Stable 12 4 Changed 13 5 Interim 15 6 Bad profile 16 7 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 68 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 31 AVRCP Unsolicited Messages CONNECT 123456789012 110E gt Outgoing AVRCP connection established 123456789012 bd_addr of peer device 110E UUID indicating AVRCP CONNECT 123456789012 110E lt Incoming AVRCP connection established 123456789012 bd
129. For a list of general S registers refer to General S Registers and Table 3 1 S registers associated with a particular profile or specific functions are described in the appropriate profile section of this document The following AT commands edit the values of S registers 2 5 2 1 ATSn m Set S Register 4 The value part m can be entered as decimal or hexadecimal A hexadecimal value is specified via a leading character For example 1234 is a hexadecimal number When S register values are changed the changes are not stored in non volatile memory UNTIL the AT amp W command is used Note that AT amp W does not affect S registers 520 to 525 or 1000 to 1010 as they are updated in non volatile memory when the command is received Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 i3 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 25 2 2 ATSn Read S Register Value This returns the current value of register n For recognised values of n Response lt cr If gt As Appropriate lt cr lf gt OK lt cr f gt For unrecognised values of n Response lt cr lf gt ERROR nn lt cr lf gt 25 2 3 ATSn Read S Register Valid Range This returns the valid range of values for register n For recognised values of n Response lt cr lf gt Sn nnnn mmmm lt cr lf gt OK lt cr If gt For unrecogni
130. G role 102 0x40 AG role of HFP bitmask needs subsequent AT amp W and ATZ to activate Initiate SLC from HFG AT HFGD lt bd_addr gt hex Responses Successful CONNECT 123456789012 111F gt failed NO CARRIER profile disabled ERROR 59 incorrect state ERROR 63 Initiate audio AT HFGA Response connection from HFG AU1 AG Transfer Audio ERROR 63 is returned if this command is from AG to HF used during call setup incoming dialling alerting Release audio only from AT HFGR Response AG Transfer Audio HFG AUO from HF to AG ERROR 63 is returned if this command is used during call setup incoming dialling alerting Disconnect SLC from HFG and audio if exists AT HFGH ATH111F ATH See sections Disconnecting Profiles and UUIDs in CONNECT NO CARRIER Messages ERROR 63 is returned if this command is used during call setup incoming dialling alerting Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 143 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Signal incoming call to AT HFGC lt number_string gt HF lt type gt Sends RING and CLIP lt number_string gt lt type gt to HF lt type gt must be in range 128 175 Refer to Signal incoming call from AG to HF 4 4 13 Signal incoming call
131. GX lt data gt r Maximum data length 26 characters lt data gt a string of printable ASCII characters or the two digit hexadecimal presentation of a non printable character preceded by r must be used to terminate a command or block of data This feature can be used to transmit short data sequences or commands but is not suitable for transmitting large amounts of data Refer to Figure xx Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 146 Americas 1 800 492 Laird 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set HFG supported S596 Bitmask features BitO Three way calling Echo cancellation and or noise reduction function Bit 1 Bit 2 Voice recognition function Bit 3 In band ring tone capability Bit 4 Attach a number to voice tag Bit 5 Ability to reject calls Bit 6 Enhanced call status Bit 7 Enhanced call control Bit 8 Extended Error Result Codes Bit9 Codec negotiation Note Bit 0 Bit 4 of these settings are advertised in the Service Record of the HFG The default value is 0x026C Bit 2 Voice recognition 0x04 Bit 3 In band ring 0x08 Bit 5 Incoming call reject 0x20 Bit 6 Enhanced call status 0x40 Bit 9 Codec negotiation 0x200 After a new value was set the commands AT amp W and ATZ are requi
132. Gateway HSP Headset Profile 12S Inter IC integrated circuit Sound VO IO Input Output Mic Microphone MITM Man In The Middle OPP Object Push Profile PBAP Phone Book Access Profile PT PASSS THROUGH Command PWM Pulse Width Modulation SBC Sub Band Codec SCO Synchronous Connection Oriented Link for bidirectional mono audio for transmission of speech SLC Service Level Connection SPP Serial Port Profile SSO Serial Stream Oriented SSP Secure Simple Pairing SUI SUBUNIT INFO Command SXXX S Register No xxx TDL Trusted Device List UART Universal Asynchronous Receiver Transmitter UI UNIT INFO Command VRA Voice Recognition Activation WBS Wideband Speech 2 3 Overview of the BTM Product Family Table 2 3 BTM product family Chipset CSR BC4 Ext Bluetooth version 2 1 Features SSP EIR SCO 1 eSCO 1 4 GPIOs Profiles SPP 1 external codec required Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 8 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Chipset CSR BC5SMM Ext Bluetooth version 3 0 Features SSP EIR SCO eSCO 4 GPIOs APTx AAC sink CVC Profiles SPP A2DP AVRCP HSP HFP 2 4 BTM AT Command Set This section describes the AT Command S
133. However now that this feature has been added a number of possible issue cases were identified fixed and manually tested e g a disconnection occurs while an inquiry is running but there may be untested cases left which can cause internal state issues or merged prints at the UART This is why this feature is disabled per default and must be enabled by ATS383 1 plus subsequent AT amp W ATZ 2 6 2 9 SPP Asynchronous Messages RING This string is sent to the host when a remote device initiates a serial port connection The fully qualified string is in the form RING 012345678901 where 012345678901 is a 12 digit hexadecimal number corresponding to the remote device s Bluetooth address This response is sent to the host every 2 seconds until the host either accepts the connection with ATA or rejects it using ATH CONNECT 123456789012 1101 lt An SPP connection with Bluetooth device 123456789012 is established successfully The connection is initiated by the remote device incoming CONNECT 123456789012 1101 gt An SPP connection has with Bluetooth device 123456789012 is successfully established The connection is initiated by the local device outgoing 2 6 2 10 SPP S Registers S Registers for SPP are summarized in Table 2 17 Table 2 17 S Registers for SPP Number of RING indications before automatically answering an incoming connection A value of 0 disables autoanswer A value of 1 enables autoanswer on the first RING and disabl
134. I62 1 Connected Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 195 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Get connection status of HSP Headset ATI63 Not connected ACL connected Audio connected Get connection status of HSP AG ATI64 Not connected ACL connected Audio connected Get connection status of HFP HF ATI65 Not connected SLC connected Audio connected In call SLC In call audio In call setup incoming dialling alerting SLC In call setup incoming dialling alerting audio Get connection status of HFP AG ATI66 Not connected SLC connected Audio connected In call SLC In call audio In call setup incoming dialling alerting SLC In call setup incoming dialling alerting audio In call but no SLC OD WTB IWIN HO nD WB WN H OIN H OIN O 2 9 6 Disconnecting Profiles A connection to a profile can be released by ATH lt Profile UUID gt For A2DP and AVRCP this is a second way of disconnecting The response on a disconnect command is usually NO CARRIER lt profileUUID gt if a connection has existed and 329 0 If no connection has existed and 329 0 no profileUUID is appended If all connections are to be released ATH may be used
135. Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVPTC lt n gt lt operation_id gt lt state gt Confirmation of AT AVC Control Command Request 0 Success 1 Fail 4 Timeout i 7 Operation not supported Any value in range 1 9 Not successful lt operation_id gt See Table 2 27 hex lt n gt status 0 Button pushed 1 Button released lt state gt 2 6 4 5 AVRCP GPIO Mapping GPIOs can be mapped to AVRCP Commands operations with GPIO Configuration Registers S 651 to 658 If a GPIO is configured appropriately as input See GPIO General Purpose Input Output with a valid av_operation_id assigned see Table 2 27 AVRCP S Registers and AT Commands and if the module is configured as AVRCP Control S 301 a rising edge causes the appropriate command request to be sent to the connected AVRCP target This is as if AT AVC is issued with lt state gt 0 Button pushed A trailing edge on this GPIO causes the same command to be sent but with lt state gt 1 Button released The logical level of a GPIO can be inverted by setting the appropriate flag INV in the appropriate GPIO configuration register If configured as AVRCP Target the direction flag DIR in the GPIO Configuration Register must be set to 1 output in order to indicate received commands at a digital output A write operation to a GPIO has no effect if that GPIO is mapped to AVRCP T
136. Laird gt BTM510 511 MULTIMEDIA MODULE User Guide Version 6 4 global local Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 www lairdtech com bluetooth BTM510 511 User Guide Bluetooth Multimedia Module REVISION HISTORY 1 0 3 01 2012 Initial Release 2 0 3 30 2012 Updates and correct to firmware 3 0 4 13 2012 v18 1 3 0 General reformatting edits 4 0 10 16 2012 Fixed Search bug Fixed general formatting and hyperlink issues 5 0 1 10 2013 Update FCC and IC statements Updated mechanical drawings 6 0 3 22 2013 Updated document for new firmware v18 1 4 0 BTM51x 08 6 1 13 Jan 2014 Separated document into two documents Hardware Integration Guide and User Guide 6 2 25 Feb 2014 Removed references to BTM52x 6 3 09 Dec 2014 PSKEY_PCM_CONFIG32 updated to PSKEY_DIGITAL_AUDIO_CONFIG 6 4 02 Feb 2015 Updated guide for Firmware v22_2_5_0 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 www lairdtech com bluetooth 2 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Contents REVISION HISTO Voras eaae annn ne Aaa EE AA S EE otis aeo EE ENR detec 2 E WONGINIQW E E AE ATT AE TS T T AET ATA TAT 6 1 1 Features opier orane r r aE Eaa a ERE r A A a 6 T2 ApplicationATeaS ssnin a dia epi a A E ora 6 2i Al Command Set RefereNC Eun sss csdecccestbien act aati eased ace a
137. M query current A2DP decoder post processing mode Response 1 pass thru mode no post processing 2 full post processing mode CSR music example Music Manager ERROR 93 A2DP not in streaming state or not in A2DP sink role decoder ERROR 94 command not supported by current decoder plugin 2 6 3 24 AT APMx Set post processing mode AT APMx set current A2DP decoder post processing mode with x 0 5 1 pass thru mode no post processing 2 full post processing mode CSR music example Values other than listed above 0 3 4 5 should not be set because no useful function is assigned The command is only accepted in A2DP streaming state otherwise ERROR 93 is returned 26 3 25 363 Set default post processing mode 363 set decoder post processing default mode 1 3 Whenever A2DP enters the streaming state i e a decoder is loaded on the DSP the post processing mode is set automatically as per 363 Values 1 pass thru mode no post processing 2 full post processing mode CSR music example 3 reserved for custom post processing algorithms Default value 1 pass thru no post processing If a loaded A2DP decoder doesn t support post processing S363 is ignored As of v18 1 4 0 all A2DP decoders SBC AAC APTX support post processing 2 6 3 26 A2DP Asynchronous messages CONNECT 123456789012 110D lt An A2DP connection with Bluetooth device addre
138. NG OUlON ecek sates p e a a ea Maen had eos cuted esas 210 2 9 20 SECA FEU 1 tates itteatectacata tienegeaaatgeteckadetasatectcirhdtameneucsangta ste ARATAKE aSa AISEA 210 2 929 RINGON GS secs aneneen a coeds jis Hh led EN eis Maceo 212 2 9 30 Tolerant pairing policy Android compatibility 00cccceeceeeseeceeeeeeeeteeeenteeeetteeeeees 212 3 PADDOCK sererai aaaea samen uha see rvastlendutede Ea E a aA ENSA Esn 214 IN SREST ne aaa air eae a a eae EEEa E eens 214 32 AMN GOMMANGS vecspicicss i ocetszeeidceveriencig fececalgrsd ae a e aiaa iaa E E aa Eaa eaaa a RS 244 Bid Error RESPONSES ssiri a a a a T EE 251 3 4 Status IDs AUTOMATION seessssssessssssuuuuuiitkiikk kitki t tintanta entet EEEE EEEEEEEEEEEEEEEEEEEEEEEAEE EEEE E REEERE EEEE EEE 255 3 5 LED Blink Pattern IDs Status Indication 0 0 00 eeceeeeeeeessseseeeeeeeeeeeeeeeseeceeeeeeeeeeesseeennnnnnneas 255 BG StONUUD Se spr R 255 37 lProfil Mask asper S 102 resus a i A 256 BiB RefereNCES sensies a a a eked a Teapa annarai 257 4 Related DOCUMENTS ANG Fil S asss prorsiiieiminen nnen naaa a a a aa a i i ae 258 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 5 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 1 OVERVIEW The BTM510 and BTM511 are low power Bluetooth modules designed for adding robust audio an
139. NO CARRIER If profile disabled ERROR 59 If incorrect state ERROR 63 Initiate audio Responses connection from HF ATEREA HF AU1 Release audio only Responses AT HFR from HF Transfer i HF AUO Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 128 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Audio to AG Initiate call with number provided by HF AT HFC nnn nnn number string Initiate call with number provided by memory of AG AT HFCM mmm mmm memory location in AG of number requested to dial Response HFI callsetup 2 confirmation call setup in Initiate call to last progress dialled number ee OR HFG ERROR last dialled number not available in AG RUery suppan Returns supported features for local HF and features locally and AT HFF connected remote HFG remotely Query NREC flag Returns status of NREC flag for local HF and AT HFFN locally and remotely connected remote HFG spel AT HFZ Only works when NREC enabled in both local HF and connected remote HFG otherwise ERROR 89 cancellation of HFG with lt x gt 0 9 A D Request DTMF tone aon a AT HFM lt x gt Request a DTMF tone to be created by a from HFG connected HFG Disconnect SLC from HF and audio if exists AT HFH ATH111
140. OK lt cr f gt 2 5 9 AT Commands for Serial Stream Oriented Profiles SSO The Serial Port Profile SSP belongs to the group of Serial Stream Oriented profiles SSO When activated an SSO profile claims one UART for its data stream and assumes all data at the UART to be transmitted over or received from RF 1 1 Hence as there is only one UART available on a BTM device the UART is not available for other profiles services or module control purposes One approach to managing data and control over UART is to configure local command mode with 531 3 In this mode incoming RF data is presented by the asynchronous message RX lt string gt Outgoing data is sent by ATX lt string gt or ATY lt string gt With this approach you may manage several non SSO connections e g A2DP AVRCP and one SSO connection SSP An attempt to simultaneously connect a second SSO profile returns Error 65 Any incoming SSO connection request is also rejected if one SSO is already connected Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 a7 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module The following section describes AT commands related to SSO profiles 2 5 9 1 ATX lt string gt Send Data in Local Command and Connected Mode This command sends data to the remote device when in local command and connected mode
141. P ATI24 For values 0 22 refer to Table 2 68 output gain Query last A2DP ATI25 For values 0 22 refer to Table 2 68 Input gain Query current As of v18 1 4 0 for A2DP decoder SBC AAC APTX post processing AT APM mode in streaming state Set current Range x 0 6 AT APM se ale s For A2DP decoder in streaming state only Whenever an A2DP decoder capable of post Setdetaultnost processing modes is loaded the mode defined by p 363 1 3 363 is entered Refer to 363 Set default post processing mode processing mode Range 1 3 default value 1 Query available A2DP decoders capable of ATI38 post processing Display Type SysID BuildNo FriendlyName and CSR SDK of all available A2DP decoders capable of post processing Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 Ge Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 4 AVRCP 1 0 Audio Video Remote Control Profile The Audio Video Remote Control profile remotely controls audio or video streaming devices A device must be defined as either control CT or target TG Furthermore you must assign a device to one of four categories Player Recorder Monitor Amplifier Tuner Menu Version 1 0 of AVRCVP is supported for TG role CT role also supports AVRCP v1 5 which is backward compatib
142. PC Now playing AVNPC AVNPC notification can be content has supressed by 397 bit3 changed 1 0x08 notification No parameters AVPS Play status AVPS lt ps gt ps play status UI8 hex changed see Table 2 47 notification Options if 390 bitO 1 Hint string inserted after lt ps gt If S390 bit4 0 and new status is playing 0x01 automatically query and display attributes of now playing track like AT AVQNP Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 98 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVPP Play status and AVPP lt ps gt lt el gt lt len gt ps play status Ul8 hex parameters see Table 2 47 response to el elapsed time in ms AT AVQPP Options UI32 hex len song length in ms if S390 bitO 1 Hint string inserted UI32 hex after lt ps gt AVPPC Playback position AVPPC lt pos gt pos playback position in changed ms UI32 hex notification AVVC Absolute volume AVVC lt av gt lt G0 gt av absolute volume UI8 changed hex range 0 127 indication go corresponding output gain UI8 hex range 0 15 AVSBP Set browsed Successful plid player ID UI16 hex player ni number of items in confirmation AVSBP lt plid gt lt Ni e gt browsed player root path Not successful UI16 hex
143. R provide different CVC images for different usage scenarios which are incorporated in the firmware Headset 1 microphone Headset 2 microphones Hands free 1 microphone AT commands S Registers and asynchronous messages for CVC support are described in the application note CVC on BTM5xx 13 available from Laird Technologies under NDA 2 9 1 1 CVC 7 generation CVC algorithms in firmware v22 2 5 0 have been upgraded to version 7 generation which comes with CSR ADK2 5 1 For parameter tuning UFE of ADK2 5 1 is required 7 generation of CVC works with SPI2USB interface when tuning CVC parameters using UFE For previous CVC versions the only option for tuning parameters was an LPT parallel interface on PC side Still there is a known issue with garbling scrambling sound in the send path for the WBS variants For each of the three CVC flavours headset 1mic HS1M headset 2 mic HS2M hands free HF1M a variant exists for narrowband 8kHz and wide band 16kHz The 8kHz variant is referred to as standard STD the wide band variant as wide band speech WBS In addition a third variant exists the so called BEX or bandwidth expanded This variant is intended for 8kHz air rate with CVC processing at 16 kHz Therefore a sampling rate conversion takes place between the 8kHz air interface and 16 kHz CVC processing The CVC processing rate of 16 kHz is also the sampling rate for th
144. RIER 111E AT HFH If no HSP connection has existed response NO CARRIER Disconnect all ATH Response profiles listed in this NO CARRIER lt ProfileUUID gt for each previously connected table profile or NO CARRIER if no existing connection found or HS connected but 332 0 2 9 7 Legacy Response Format BISM2 Some BISM2 responses have been slightly changed on BTM modules to provide enhanced functionality If required a BISM2 compatible response format can be enabled by S Register 329 Table 2 91 and Table 2 92 shows the implications of enabled disabled legacy response format Table 2 91 Enabling Disabling legacy response format Enable legacy response format 0 Disabled default BISM2 compatible 329 0 1 1 Enabled Table 2 92 Implications of 329 AT SPH ATH1101 Response If SPP was connected response NO CARRIER 1101 NO CARRIER If SPP was not connected response NO CARRIER AT APH ATH110D Response If A2DP was connected response NO CARRIER 110D NO CARRIER If A2DP was not connected response NO CARRIER AT AVH ATH110E Response If AVRCP was connected response NO CARRIER 110E NO CARRIER If AVRCP was not connected response NO CARRIER AT HSH ATH1 108 Response If HS instance was connected response NO CARRIER 110E NO CARRIER If HS instance was not connected response NO CARRIER Embedded Wireless Solutions Support Laird Americas 1 800 492 2320 197 Europe 44 1628 858 940 Hong Kong 8
145. RM 0001 request local master for SPP profile Example AT SRS 0001 request local slave for SPP profile As the role change request can be rejected by the remote device there is no guarantee that the request will be successful Check the outcome by ATI56 100ms delay between AT SRx and ATI56 is recommended ERROR 04 profile is not connected ERROR 05 more than one flag is set in the profile mask or other syntax error Itis also possible to configure automatic request of master or slave role as soon as a profile has connected 368 set SLAVE role on connect Parameter profile mask like 102 For each profile enabled in S368 whenever the profile connects local slave role is requested regardless of the connection s direction incoming outgoing When writing 1 to a profile flag which is already set in S369 the flag is cleared in S369 Check local HCI role for each profile ATI56 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 209 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Range 0 1FF 369 set MASTER role on connect Parameter profile mask like 102 For each profile enabled in S369 whenever the profile connects master role for BTM51x is requested regardless of the connection s direction incoming outgoing When writing 1 to a profile flag which is alr
146. Right at the Display Position drop down menu Figure 2 20 6 Close each window by clicking OK w Initiate BTM5 AT AVD Response Figure 2 21 Connection xx lt BdAddr_PC gt If AVRCP is connected CONNECT lt BdAddr_PC gt 110E gt Connected BTM5 AT AVC44 Send Play Figure 2 22 Figure 2 23 send remote xXx Response control If the command is accepted OK commands If a confirmation is received from the PC AVPTC 0 44 0 If a confirmation is received from the PC AVPTC 0 44 1 Reception of command should be displayed in top right corner of PC screen Figure 2 23 Player should start playing AT AVC46 Send Pause Figure 2 22 Figure 2 23 Response If the command is accepted OK If a confirmation is received fr rm the PC AVPTC 0 46 0 If a confirmation is received from th PC AVPTC 0 46 1 Reception of command should be displayed in top right corner of PC screen Figure 2 23 Player should pause Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 58 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT AVC45 Send Stop Figure 2 23 Response If the command is accepted OK If a confirmation is received from the PC AVPTC 0 45 0 If a confirmation is received AVPTC 0 45 1 from the PC Reception of command should be displa
147. S rate are different shows that a sampling rate conversion is active Ezurio Terminal Ver 6 8 0 CTS DSR DCD AI RTSY DTRIV BRK Open COM38 9600 N 8 1 Ezurio Terminal Ver 6 8 0 CTS OSR DCD RI RTS DIRIV BRK Open Ss lt ti sC S sSCS COM 3B 9600 N 8 1 FS44100 IZ2S_M 48000 callsetup 2 call 1 APSTR lt APSUS lt callsetup FS16000 125_M 48000 HF AUL E Figure 2 36 FS Message Next we stop the playback on the phone After a few seconds the phone will suspend the A2DP stream APSUS lt Now we create a SCO link One option is to use Siri for this purpose keeping the phone main button pressed for a few seconds will launch Siri and create an eSCO link as shown in the second screenshot right with the following FS message FS16000 12S M 48000 This shows that a channel at 16kHz F576000 sampling rate has been created which must be wideband eSCO that audio is routed to 12S in master role 25_M and that the stream is being up sampled to 48 kHz 48000 Finally we disconnect iPhone e g by disabling Bluetooth on the phone Now we connect a different device which will negotiate an A2DP air rate of 48 kHz This can be achieved by a PC with Bluetooth and Windows 7 BTM51x should be visible when discovering adding a new device We need to confirm the 6 digit pass key on PC end On BTM51x we need to enter AT BTBY in response to the passkey compare request After windo
148. SCO links for all CVC variants and X1M S318 gt 0 for both narrow band 8 kHz and wide band 16 kHz Fixed sampling rate also applies to all A2DP decoders SBC APTX and AAC sink Fixed sampling rate does not apply to SCO links if S318 0 no DSP plugin Fixed sampling rate does not apply to A2DP encoders SBC APTX source Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 171 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module If a fixed sampling rate has been enabled then the fixed configured rate is appended to the FS message If the first FS value is different from the second then resampling routines are active on the DSP For example FS8000 I2S_M 441000 indicates a narrow band SCO link 8 kHz air rate with sampling rate converted up to 44 1 kHz for I2S interface 12S configured as master S register 419 allows enabling and configuring a fixed sampling rate Values of S419 are mapped to actual sampling rates depending on the context SCO A2DP PCM I2S as outlined by Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 172 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 74 Embedded Wireless Solutions Support Laird Center
149. SS system status remote TG changed notification Options if S390 bitO 1 Hint string inserted after lt nSS gt AVTE Track reached end AVTE No parameters notification Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 Europe 44 1628 858 940 100 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVTS Track reached AVTS start notification No parameters AVUC UIDs changed AVUC lt cnt gt notification cnt UID counter UI16 hex Notes All messages of this table are surrounded by lt CRLF gt Ox0D Ox0A BOOL Oori UI8 hex 2 hexadecimal digits UI16 hex 4 hexadecimal digits UI32 hex 8 hexadecimal digits Ul64 hex 16 hexadecimal digits lt asc gt avrcp status code see Table 2 50 Table 2 43 Media element attributes 0x01 Title 0x02 Artist Name 0x03 Album Name 0x04 Track Number 0x05 Total Number of Tracks 0x06 Genre 0x07 Playing Time ms Note See also AVRCP1 5 spec p 132 Table 2 44 Player application setting attributes 1 OFF 0x01 Equaliser ON OFF status 2 ON Embedded Wireless Solutions Support Center http ews support lairdtech com 101 www lairdtech com bluetooth Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510
150. See Table 2 90 Profile Release Commands Table 2 90 Profile release commands Disconnect SPP ATH1101 or Single ATH retained for backward compatibility response NO AT SPH or CARRIER or NO CARRIER 1101 depending on 329 and if a SPP ATH connection has existed previously Disconnect A2DP ATH110D or If A2DP connection released response NO CARRIER 110D If AT APH no A2DP connection has existed response NO CARRIER Disconnect AVRCP ATH110E or If AVRCP connection released response NO CARRIER 110E AT AVH If no AVRCP connection has existed response NO CARRIER Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 196 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Disconnect HSG ATH1112 or If AG HSP connection released response NO CARRIER 1112 AT HSGH If no HSP connection has existed response NO CARRIER Disconnect HS ATH1108 or Must be enabled by 332 otherwise it results in a behaviour AT HSH not defined in HSP specification If HS HSP connection released response NO CARRIER 1108 If no HSP connection has existed response NO CARRIER Disconnect HFG ATH111F or If AG HFP connection released response NO CARRIER 111F AT HFGH If no HSP connection has existed response NO CARRIER Disconnect HF ATH111E or If HF HFP connection released response NO CAR
151. Sniff parameter specified 037 E g new Attempt value greater than MinInterval Solution is to first increase MinInterval and re enter the Attempt value 038 Get Remote Friendly name Failed 039 Failed to change mode to Multipoint 040 7 Bit mode requires parity to be even or odd 041 Stream Error 042 Stream Pending Error 043 Unknown Audio Gateway Command 044 Busy try later 045 Command or operation not allowed 046 No A2DP role has been set see S register 300 047 No AVRCP role has been set see S register 301 048 No AVRCP category has been set see S register 302 049 No AVRCP control connection 050 No A2DP or AVRCP connection currently incoming 051 Invalid operation ID AVRCP 052 Wrong AVRCP role 053 Command disabled by S Register 310 054 No manufacturing information available 055 Audio resource error 056 Invalid UUID 057 Maximum gain level reached 058 Minimum gain level reached 059 Profile or role not enabled 060 Profile under construction 061 Unknown Headset command 062 Unknown Hands free command 063 Incorrect state 064 not used 065 UART resource error 066 Index of subscriber number record too large 067 Maximum number of subscriber number records reached 068 No SLC exists for AT HFGBO 1 069 In band ringing was not enabled in HFG supported features S596 0x08 at boot time 070 Invalid number type must be in range 128 lt number type lt 175 071 M
152. Stack with AVRCP target role support the setup should follow these steps 1 Identify the Bluetooth Device Address of the PC 2 Enable the AV Remote Control Service 3 Select the player and or setup display of incoming remote control commands The BTM5xx device is assumed to be connected to a terminal program e g Ezurio Terminal on a PC The sequence of AT commands and the instructions for the PC side are listed in Table 2 26 Figure 2 18 to Figure 2 23 show appropriate screenshots This example can be combined with the A2DP Example 1 A2DP Example 1 Then the AVRCP connection should be initiated after A2DP is connected Table 2 26 AVRCP Example 1 Command Sequence Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 57 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Preparation Preparation BTM5 AT amp F Restore factory default settings XX AVRCP profile is enabled per default in S102 AVRCP Control role is enabled per default in 301 ATZ Reset PC n a 1 Select Options from the Bluetooth icon in the taskbar Figure 2 18 2 Identify the PC s Bluetooth address lt BdAddr_PC gt in the General tab of Bluetooth Options Figure 2 18 Enable AV Remote Control Service Figure 2 18 4 Go to the Other tab of Bluetooth Options and click AV Player Figure 2 19 5 Select Top
153. The NREC flag is Bit O in the HF supported features S581 and Bit 1 in HFG supported features S596 2 6 8 1 24 Indicators from HFG CIEV 2 HFI lt indicator_string gt lt val gt S333 1 default HFl lt indicator_id gt lt val gt 333 0 Inform the HF host about a CIEV indicator message received from the connected audio gateway S Register 333 enables verbose mode for HFI indicators Possible indicators are listed in Table 2 30 Table 2 57 CIEV indicators in HFI message Service service 1 4 4 Call call 2 Call Setup callsetup 3 All call related sections Call held callheld 4 Signal signal 5 4 5 Roam roam 6 4 6 Battery Charge battchg 7 4 7 2 6 8 1 25 Hands free audio routing Audio in the Hands free profile is always referred to as a SCO connection which is used for bidirectional transmission of speech On a BTM5xx SCO audio is routed to the internal codec by default S315 can select the 12S or PCM interface in master or slave mode for SCO connections Refer to Routing audio streams over 125S 2 6 8 1 26 Send custom data over SLC HF AT HFX lt data gt Send custom data lt data gt over SLC from HF instance Please refer to section 2 9 24 for details on utilizing ACL for custom data 2 6 8 1 27 Hands free status ATI65 Returns the status of the Hands free HFP instance Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2
154. The digits in the default friendly name represent the last 6 digits of the local Bluetooth address Refer to 593 in Table 3 1 If a new value must be retained permanently save it to non volatile memory by AT amp W Response lt cr lf gt OK lt cr lf gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 11 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 5 1 9 AT BTN Read Friendly Name from Non volatile Memory Read the default friendly name from non volatile memory Response lt cr lf gt My Friendly Name lt cr lf gt lt cr f gt OK lt cr lf gt 2 5 1 10 AT BTF lt bd_addr gt Get Remote Friendly Name This command gets the remote friendly name of the peer specified Response lt cr lf gt lt bd_addr gt Friendly Name lt cr f gt OK lt lt cr lf gt 25 17 11 AT BTP Make Device Discoverable and Connectable Make the device discoverable and connectable and wait for a connection from any device The setting remains valid until next reset or power cycle unless not changed by any other AT command subsequently For permanent discoverable connectable settings refer to S Register 512 Response lt cr lf gt OK lt cr lf gt 2 5 1 12 AT BTQ Make Device Discoverable Make the device discoverable but not connectable Being discoverable implies that this device responds to inqui
155. The following table Table 2 34 lists all AVRCP1 5 messages in alphabetical order Table 2 34 AVRCP1 5 messages in alphabetical order AVAPC Available players changed notification AVAPI Available player item AVAPL Available players list start end AVBS Battery status of remote TG changed notification AVCPL Current play list start end AVFC Folder path changed confirmation AVFSI File system item folder AVFSL File system list start end AVMEA Media element attribute browsing AVMEI Media element item track AVNPA Now playing track attribute AVNPC Now playing content has changed notification AVNPT Now playing track attributes start end AVPA Player application setting attribute only AVPC Player application setting changed list start end indication of value change Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 www lairdtech com bluetooth 72 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVPE Player application setting attribute value text AVPI Play item confirmation AVPL Player application setting response list start end response to AT AVQPV A AVPP Playback status parameters response AT AVQPP AVPPC Playback position changed notification AVPS Play status changed notification AVPT Player attribute text AVPV Pla
156. UID 2 6 5 9 AVRCP sniff mode delay We have observed that responses to AVRCP requests AT commands are delayed in the range of about 0 5 to 1 second This is likely to be caused by sniff mode 2 6 5 10 AVRCP1 5 continuation This feature caters for the case that media element attributes may not fit into a single packet due to large size such as a long track name or similar This is why the AVRCP1 5 specification defines four different packet types Single 0 Start 1 Continue 2 End 3 If all attribute data fits into a single packet then the packet type is Single 0 If attribute data is spread over more than one packet then the first packet type is Start 1 followed by zero or more packets of type Continue 2 followed by a terminating packet of type End 3 On the BTM51x this becomes relevant for representation of now playing track attributes AVNPA message To cater for this feature the current packet type is appended immediately to AVNPA lt n gt as a single decimal character 0 3 Most cases are 0 however if the packet type is 1 then more AVNPA lt pt gt messages must be expected as described above pt 2 finally pt 3 For each packet received a separate AVNPA lt pt gt message is sent to UART This feature has only been tested against PTS profile tuning suite but not against a test TG due to lack of support on the latter not having a long enough track name Ref 4 46 Embedde
157. Verify by AT HFGC 354 1 Manual tests show that this command works well on the HFG when no SLC exists If this command is issued when an HF unit is connected SLC or SLC and audio it s not guaranteed that all signalling HFP indicators and automatic audio handling works correctly in all circumstances AT HFGCH Hang up all calls clearing all call records on HFG Verify by AT HFGC 354 1 Manual tests show that this command works well on the HFG when no SLC exists If this command is issued when an HF unit is connected SLC or SLC and audio it s not guaranteed that all signalling HFP indicators and automatic audio handling works correctly in all circumstances 2 6 8 2 9 Sending AG indicators to HF CIEV 2 AT HFGl lt indicator_id Send an AG indicator to HF in the form CIEV lt indicator_id gt lt value gt gt lt value gt dec dec Table 2 59 lists possible indicators and their value range If there is no SLC existing and indicator Service is set AT HFGI1 n the value is stored in volatile memory to be presented during a future SLC initialization procedure For all other indicators this command is valid only if a SLC exists Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 134 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT HFGI should onl
158. _addr of peer device 110E UUID indicating AVRCP NO CARRIER 110E AVRCP connection rejected or closed NO CARRIER All Connections closed AVUR 0 lt unit_id gt lt unit_type gt lt company_id gt Successful response to AT AVU UNIT INFO Request indicates completion of command lt unit_id gt Unit ID lt unit_type gt See Table 2 29 lt company_id gt IEEE Company ID AVUR lt n gt n gt 0 Unsuccessful response to AT AVU UNIT INFO Request indicates completion of command 1 Fail lt n gt status 4 Timeout dec AVSR 0 lt page gt lt pagedata gt dec Successful response to AT AVS SUBUNIT INFO Request Indicates completion of command lt page gt requested page 0 31 lt pagedata gt 1st word of requested page AVSR lt n gt n gt 0 Unsuccessful response to AT AVS SUBUNIT INFO Request indicates completion of command 1 Fail lt n gt Status 4 Timeout Ti u AVPTI lt subunit_id gt lt operation_id gt lt state gt hex hex Indication of incoming Pass Through command lt subunit_id gt Subunit id lt operation_id gt See Table 2 29 0 Button pushed lt state gt 1 Button pushed Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 69 Europe 44 1628 858 940 www lairdtech com bluetooth Hong
159. a 2 Even For the Go blue Activator variant of the module this register is read only See S Register 526 for further information Apply multiplier of 8 to baud rate internally This is set to O disabled by default If S Register 521 gt 115200 then 525 0 0 1 n a this register cannot be set to 1 See S Register 526 for further information This register specifies a 2 bit mask used to qualify how S Registers 520 to 525 are actioned The new communication parameters affect the UART immediately The new communication parameters are stored in non volatile memory If bit O is 1 If bit 1 is 1 S526 3 1 3 n a For example to change communication parameters but have them come into effect only after subsequent power cycles then this register should be set to 2 and likewise to affect immediately and yet not have it persist over a power cycle the value should be set to 1 Must be set before the baud rate change 100 Reconnect delay when configured as master in 530 1000 15000 n a pure cable replacement mode This value is rounded down to the nearest 100ms See S Register 505 also S531 0 0 4 n a On SPP connect mode specifies the mode on SPP connection establishment Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 234 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Blueto
160. a Module 2 AT COMMAND SET REFERENCE 2 1 Introduction This document describes the protocol used to control and configure the BTM Bluetooth device The protocol is similar to the industry standard Hayes AT protocol used in telephony modems It is appropriate for cable replacement scenarios as both types of devices are connection oriented Just like telephony modems the Laird Technologies device powers up in an unconnected state and only responds via the serial interface In this state the device does not even respond to Bluetooth Inquiries The host can then issue AT commands which map to various Bluetooth activities The configuration of the device can be saved so that on the next power up the device is automatically discoverable or connectable The device has a serial interface which can be configured for baud rates from 1200 up to 921600 default is 9600 and an RF communications end point The latter operates in terms of connected and unconnected modes and the former operates in command and data modes This leads to the matrix of states shown below Table 2 1 RF Communications end point states Local Command Mode OK OK Remote Command Mode ILLEGAL OK Data Mode ILLEGAL OK The combinations Data Mode RF Unconnected and Remote Command Mode RF Unconnected are invalid and are ignored Navigation between these states is done by issuing AT commands described in detail in subsequent sections 2 2 Glossary of Terms Table 2 2
161. able MPS 1 just enable MPS service record and set 355 1 The user is responsible to enable all required profiles S102 and roles S300 301 2 automatic configuration for A2DP SNK AVRCP CT HF 3 automatic configuration for A2DP SRC AVRCP TG HFG Note With S386 2 or 3 S Registers S102 S300 and S301 are modified at boot time according to Table 2 63 below Unrelated flags of S102 are not touched e g SPP Ox01 HS Ox02 HSG Ox08 Table 2 63 MPS boot time actions 0 disable None 1 enable S355 1 SCO priority over A2DP 2 SNK CT HF S102 set A2DP AVRCP HF 0x190 S102 clear HFG 0x40 S300 1 A2DP SNK S301 1 AVRCP CT 355 1 SCO priority over A2DP 3 SRC TG HFG S102 set A2DP AVRCP HFG 0x1C0 S102 clear HF 0x10 S300 2 A2DP SRC 301 2 AVRCP TG 355 1 SCO priority over A2DP Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 151 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 7 Automation As of v18 1 4 0 the BTM51x modules provide features that allow more automated or even hostless operation of the Bluetooth device across a number of profiles New features such as auto connect records auto connect service status indication and dynamic registers are described in this section As automation features are likely to make extensive usag
162. airdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module For SCO there are 3 packet types defined in the Bluetooth specification 1 HV1 HV2 HV3 Each occupies one slot They differ in the level of bit error checking Laird recommends you enable all three packet types for SCO links This passes the final decision down to the baseband There is no retransmission of erroneous SCO packets For eSCO and basic data rate there are 3 packet types defined in the Bluetooth specification 1 EV3 EV4 EV5 EV3 occupies one slot EV4 and EV5 can occupy up to three slots each They differ in the level of bit error checking It is recommended to enable all three packet types for eSCO links This passes the final decision down to the baseband eSCO packets involve a CRC code and retransmission of erroneous eSCO packets Packet types and link types SCO or eSCO are negotiated on link setup A BTM can accept either incoming SCO S584 0 or eSCO links S584 1 but not both SCO and eSCO at one time If the initiating side requests an unsupported link type the audio link fails The initiating BTM module is supposed to request the remaining link type in that case As of f w v22 2 5 0 S584 2 allows to accept an incoming SPP SCO request regardless of the SCO eSCO packet type being requested by the peer device A new request from the peer device is not needed because the first attempt should be successful Lik
163. arch for AT BIA command Bitmask 0x01 Service indicator 0x02 Signal strength indicator 0x04 Roaming status indicator 0x08 Battery charge indicator 0x10 Call indicator 0x20 Call setup indicator 0x40 Call held indicator S382 0 0 1 SSP Enable 0 tolerant pairing policy Android compatibility Disable default 1 Enable 383 0 0 1 SPP Enable 0 inquiry exception Disable default 1 Enable 384 0006 0 4 ff I2S 12S format configuration which corresponds to PSKEY_DIGITAL_AUDIO_CONFIG amp 01D9 Bit Name Description 0 Justify 0 Left justified Format 1 Right justified For left justified formats 0 MSB of SD data occurs in the first SCLK period following WS transition 1 MSB of SD data occurs in Left Justify Delay Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 595 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module the second SCLK period Channel Polarity For O SD data is left channel when WS is high For 1 SD data is right channel Audio Attenuation For 0 17 bit SD data is rounded down to 16 bits For 1 the audio attenuation defined in AUDIO_ATTEN_VALUE is applied over 24 bits wi
164. arget TG 5301 0 3 3 Controller and target enabling AVRCP1 5 CT default Needs subsequent AT amp W and ATZ to become effective Set AVRCP O Feature disabled category 1 Player recorder default 2 Monitor amplifier S302 0 4 3 Tuner 4 Menu Needs subsequent AT amp W and ATZ to become effective Initiate outgoing Response AVRCP control AT AVD lt bd_addr gt f accepted CONNECT 0123456789012 110E gt connection If rejected NO CARRIER 110E Close only AVRCP Response connection AT AVH or If a connection has existed NO CARRIER 110E ATH110E and 329 0 If a connection has not existed and S329 0 MARREN Close all Response ore ATH For each profile that was iq CARRIER lt profileUUID gt previously connected See Disconnecting Profiles Send remote lt operation_id gt see Table 2 27 control command lt state gt optional Control AT AVC lt operation O Button pushed id gt lt state gt 1 Button released hex Response on command completion AVPTC lt n gt lt operation_id gt lt state gt hex Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 65 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Send a Unit Info request Control Response on command completion AVUR AT AVU ae lt n gt lt u
165. as not been evaluated whether the feature of earlier f w version can be restored Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 106 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 52 Headset Profile supported features on BTM5xx 1 Incoming audio connection M Yes M Yes 2 Outgoing audio connection M Yes O Yes 3 Audio connection transfer M Yes M Yes 4 Remote audio volume control O Yes O Yes M Mandatory O Optional 2 6 7 1 Headset role HS Headset role is activated by setting flag 0x02 in 102 plus AT amp W followed by ATZ Figure 2 24 illustrates a HSP link and how a BTM5xx module is integrated in hosted operation mode 1 Button GPIO input FMC 0x0B Speaker Audio BTM5xx HS Microphone Figure 2 24 Headset block diagram Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 107 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 7 1 1 Initiate ACL connection from HS AT HSD lt bd_addr Initiate ACL connection from local headset instance to remote device with lt bd_addr device must support the audio gateway role AG of the headset profile HSP Response lt cr If gt CONNECT
166. attempt as a master Referenced by ATD In units of seconds See S Registers S505 10 2 120 n a 530 and 543 also Note that since disconnection times vary this register only guarantees the minimum delay Note that for invalid addresses specified in the ATD command the NO CARRIER response is immediate See S register 560 for specifying disconnect max timeout Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 230 BTM510 511 User Guide Bluetooth Multimedia Module Enable Disable echoes The ATEn command also affects 506 0 0 1 n a this A connection can be dropped using When set to 0 444 escape sequence only and the state of the DSR line is ignored A connection can be dropped using When set to 1 either the escape sequence or the DSR modem control line A connection can only be dropped using a de assertion of DSR Mode 2 provides for the highest data transfer rate S507 0 62 n a When set to 2 If the status of the DSR line is to be conveyed to the remote device as a low bandwidth signal then this register MUST be set to 0 otherwise a de assertion of DSR is seen as a request to drop the Bluetooth connection This register affects S Register 536 see details of 536 Page Scan Interval in milliseconds Minimum is 11 25 ms 508 640 11 2550 n a so 10
167. aximum number of calls reached 071 Call state issue Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 252 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 073 A second waiting call is not is not allowed 074 No call held 075 Invalid index lt idx gt 076 Memory allocation attempt was not successful 077 Incorrect A2DP state see ATI61 078 Request rejected due to priority settings S355 079 Writing to modem control line is not permitted by GPIO S register 080 Attempting to write the pin state of a GPIO that is configured as input 081 Maximum size of EIR data exceeded ATI29 082 No CVC license key stored or more than 5 words invalid length ATI32 083 CVC security failed on loading CVC image for a SCO connection 084 087 firmware internal CVC error codes should not occur with released firmware 088 CVC SYSID request timeout Can occur on ATI35 if UART baud rate is too low HF request to disable NREC in HFG failed because NREC feature is not supported 089 by both ends Support for both ends can be checked with AT HFF NREC mask for HF 1 NREC mask for HFG 2 of AT HFN CVC boot time check failed occurs if 318 gt 0 at boot time and selected CVC image does not have a valid license key HF ERROR was received from the HFG on a DTMF request AT HFMi on UART AT VTS i o
168. be suspended A2DP or closed SCO before accepting initiating the new link See Table 3 1 for details of 355 In an A2DP HFP simultaneous scenario it is likely that the user wants different gain settings for SCO and A2DP links ATI22 for output and ATI23 for input query the last gain settings used for a SCO connection of the internal codec ATI24 for output and ATI25 for input query the last gain settings used for an A2DP connection S register 356 restores last SCO gain settings when entering a SCO connection S register 357 restores the last A2DP gain settings when entering an A2DP connection Refer to Table 3 1 for details 2 6 3 19 1 Issue Workaround with Apple Devices When initiating A2DP from BTM51x with AAC enabled to an iPhone we have observed regular short drops that can be resolved by changing the HCI role so that the iPhone becomes master of the link The setting to request slave role for BTM51x on each A2DP and AVRCP connection is ATS368 0180 AT amp W ATZ See AT SR lt role gt lt pm gt Setting HCI role master slave for more details on HCI roles Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 50 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 3 20 A2DP decoder post processing MusicManager As of firmware v18 1 4 0 all A2DP decoders SBC AAC APTX su
169. cal Equipment Consumer Electronics Laird Technologies offers its customers unique product solutions dedication to research and development as well as a seamless network of manufacturing and customer support facilities across the globe LWS UM BTM510 511 0312 Copyright 2013 Laird Technologies Inc All rights reserved The information contained in this manual and the accompanying software programs are copyrighted and all rights are reserved by Laird Technologies Inc Laird Technologies Inc reserves the right to make periodic modifications of this product without obligation to notify any person or entity of such revision Copying duplicating selling or otherwise distributing any part of this product or accompanying documentation software without the prior consent of an authorized representative of Laird Technologies Inc is strictly prohibited All brands and product names in this publication are registered trademarks or trademarks of their respective holders This material is preliminary Information furnished by Laird Technologies in this specification is believed to be accurate Devices sold by Laird Technologies are covered by the warranty and patent indemnification provisions appearing in its Terms of Sale only Laird Technologies makes no warranty express statutory and implied or by description regarding the information set forth herein Laird Technologies reserves the right to change specifications at any time and without notice Lai
170. ced if LED mode LED_PULSE 2 8 8 GPIO General Purpose Input Output On a BTM module a number of digital I Os can be used for general purposes To each GPIO pin an S Register is assigned S651 to S658 which allows configuration of GPIO settings and single pin read write Configuration of a GPIO comprises pin direction input output inversion enable notification enable function mapping select and function mapping code av_operation_id Refer to Figure 2 40 BTM51x GPIO configuration register and Table 2 80 for details To enable single pin read write mode set S650 to 1 This disables write and read access to configuration bit fields but allows read write access to the pin state flag 0x01 To enable configuration mode set S650 to 0 This allows read write access to the full GPIO configuration register including the pin state flag All logical GPIO lines can be read written in one atomic step by new S Register 670 at any time When a GPIO is configured as input a weak internal pull up or pull down resistance is enabled by default A strong pull up down strong bias can be enabled by setting the appropriate flag for a GPIO in S669 The direction of the resistance up down is determined by the pin state flag of the configuration register For example if DIR 0 and PS 1 the input pin status is pulled up if DIR 0 and PS 0 then the input pin is pulled down There are no resistors switched inside the chipset but strong and weak bias are def
171. ces that match their major device class code to this value which can only be in the range 00 to 1F The response format to AT BTI is defined by 330 by bitmask This is device address device class friendly name receiver strength indicator and extended inquiry data Refer to Table 2 8 and Figure 2 1 For 330 1 Response lt cr lf gt 12346789012 lt cr lf gt 12345678914 lt cr lf gt OK lt cr f gt In the Bluetooth inquiry process a device could respond many times for a single inquiry request To ensure that an address is sent to the host only once for a particular AT BTI an array of addresses is created at the start of each AT BTI and is filled as responses come in This array of addresses is stored in dynamic memory If the memory allocation fails the inquiry procedure is aborted and an error response is sent to the host To clarify a single AT BTI does not return the same Bluetooth address more than once As long as the responding device is active all AT BTI commands always return it As the inquiry process is driven by randomness it is not guaranteed that each discoverable device is always found on the first attempt Sometimes more than one inquiry processes might be necessary to find a particular device The probability also depends on the inquiry scanning intervals of the device being searched for The inquiry process can be speed up if the friendly name is not required flag not set in S330 as part of the inquiry response or
172. commands AT HSX lt data gt 26 Send custom data on HS instance ACL AT HFX lt data gt 26 Send custom data on HF instance SLC AT HSGX lt data gt 26 Send custom data on HSG instance ACL AT HFGX lt data gt 26 Send custom data on HFG instance SLC lt data gt can be a string of printable ASCII characters or the two digit hexadecimal presentation of a non printable character preceded by V e g hello OD The maximum length of lt data gt is limited by the input buffer size for AT commands which is 36 including terminator r Please note that OD must be utilised to terminate a command or block of data Otherwise the data will be buffered on the remote end until OxOD is found Once the remote SLC parser finds the command terminator OxOD it will start parsing and eventually free the RF input buffer of the remote device Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 210 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module This shows that this feature can be used to transmit short data sequences or short commands But it is not suitable to transmit large amount of data Please refer also to Error Reference source not found Obviously these commands allow to send AT commands straight to the SLC which would normally be sent only by the BTM51x internal processing triggered by particular
173. confusing due to multiple redundant AVNPC notifications up to four were observed AVNPC On reception of AVAPC notification available players changed Action on Available 0 Automatically query available players list AT AVQAP players changed 7 0x80 1 Do nothing notif Note We observed AVAPC when switching forth and back AVAPC between the standard player Music and other streaming applications such as a web radio player or similar 2 6 6 2 397 AVRCP1 5 notification control S register 397 allows you to disable certain AVRCP1 5 notifications Disabling certain notifications can help to simplify requirements for the host controller s parser algorithm Messages that are currently not covered by S397 can only be suppressed by S504 1 which unfortunately generally prevents any output on the BTM51x UART silent mode 397 Range 0 FF 397 Default 0C 397 details are listed in Table 2 38 Table 2 38 S397 AVRCP1 5 notification control 0x01 AVPS On reception of play status changed event Play status changed notification O Print AVPS message to UART 1 Suppress AVPS message 1 0x02 AVTC On reception of track changed event Track changed notification O Print AVTC message to UART 1 Suppress AVTC message Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 82 Europe 44 1628 858 940 www lairdtech com bluetooth Hong
174. connections FS8000 INT The internal codec is configured for a sampling frequency of 8000 Hz 8 kHz if narrowband CVSD is used FS16000 INT The internal codec is configured for a sampling frequency of 16000 Hz 16 kHz when WBS is used SPP AU1 This response is sent to the host when a SCO eSCO channel has been established To check the actual type use ATI37 O unknown 1 SCO 2 eSCO SPP AUO This response is sent to the host when an existing SCO eSCO channel has been closed Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 192 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module SPP AU2 This response is sent to the host when a SCO channel setup fails This might be caused by the fact that the peer only accepts eSCO connections but a SCO connection was requested or vice versa Try to initiate the SCO connection with the remaining link type 2 9 22 SCO eSCO more information More information on SCO can be found in the following sections of this document BTM51x PCM Pulse code modulation interface SCO Input Output Channel 2 9 3 Cable Replacement There are different types and terms for cable replacement scenarios A distinction exists between serial cable replacement and digital I O cable replacement n serial cable replacement a serial RS232 cab
175. cr If gt ERROR nn lt cr f gt 2 5 3 General S Registers Refer to Appendix Table 3 1 for a list of supported S Registers The main purpose of S Registers is to make the device configuration persistent All S Registers can be saved to non volatile memory by AT amp W Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 15 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module In some cases an AT command and an S register exist for one and the same setting In the majority of those cases the AT command s setting is lost on next power cycle The S register can be saved and is still available after power cycle This rule applies to many but not all of those cases 2 5 4 AT Commands for Inquiry 2 5 4 1 AT BTl lt devclass gt Inquire This initiates an inquiry for delay seconds and max number of unique responses where delay is defined by S register 517 and max is specified by S register 518 The lt devclass gt is an optional parameter where the value specifies either a 6 digit device class code or a 2 digit major device class If it is not specified the value is taken from S register 516 When lt devclass gt is 6 hexadecimal characters long it specifies an AND mask which filters inquiry responses When lt devclass gt is 2 hexadecimal characters long it forces the inquiry to filter responses to devi
176. ction incoming outgoing Refer to 331 and UUIDs in CONNECT NO CARRIER Messages HS RING HS has received a RING indication from the connected audio gateway HS is expected to respond with AT CKPD 200 see AT HSB FS8000 INT The internal codec is configured for a sampling frequency of 8000 Hz HS AU1 Audio connection SCO has been established audio on HS AUO Audio connection SCO has been released audio off HSRX lt data gt Spy messages displaying incoming data on the ACL rfcomm of HSP link HSUC lt data gt Message displaying unrecognized command data from ACL rfcomm of HSP link NO CARRIER 1108 ACL connection to local HS instance has been released Note UUIDs in CONNECT NO CARRIER Messages as well Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 109 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 7 1 8 Headset Summary Table 2 54 Headset role HSP Summary of S Registers and AT Commands Enable HSP HS role 0x02 HS role of HSP bitmask a2 needs subsequent AT amp W and atz to activate Responses if ful CONNECT ee 123456789012 1112 gt iti If failed NO CARRIER Initiate ACL from AT HSD lt bd_adar gt headset a If profile ERROR 59 disabled If incorrect ERROR 63 state Send Butto
177. cy low throughput 1 High latency high throughput Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 236 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Bluetooth RFCOMM specification allows digital I O signals to be exchanged over an RFCOMM connection RTR RTC DV IC This register specifies in each 4 bit nibble how the outgoing modem status bits to the remote peer gets its value Specifies the source for RTC i e DSR DTR Nibble 4 7 Specifies the source for RTR i e RTS CTS Nibble 8 11 Specifies the source for DV i e DCD Nibble 12 15 Specifies the source for IC i e RI Nibble 0 3 Each nibble can take the following value 0 Always set to 0 1 Always set to 1 If DCD is output then always 1 f DCD is input S552 then follow DCD 1 if DCD is asserted otherwise 0 N 551 3211 0 ffff n a f RI is output then always O 3 If RI is input S552 then follow RI 1 if RI is asserted otherwise 0 4 If DSR is asserted then 1 Otherwise O In the event that a nibble specifies DSR as the source of its state be aware that if S Register 507 is anything other than 0 a de assertion of DSR causes the Bluetooth connection to be dropped If bits 0 3 and 4 7 are set to 0 then some Bluetooth devices may use tha
178. d 0x0800 UIDs changed 0x1000 Volume changed Note See also AVRCP1 5 spec p 135 Table 2 49 AVRCP TG features SDP record 0x0001 Category 1 0x0002 Category 2 0x0004 Category 3 0x0008 Category 4 0x0010 Player application settings 0x0020 Group navigation 0x0040 Supports browsing 0x0080 Supports media player applications Note See also AVRCP1 5 spec p 91 Table 2 50 AVRCP status codes Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 103 Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0000 Success 0001 Operation failed 0002 Not enough resources 0003 Request not supported in current state 0004 Time out 0005 Not connected 0006 Busy 0007 Request not supported 0008 Invalid sink 0009 Link loss occurred 000A Operation was rejected 000B General failure during browsing channel initialisation 000C Browsing channel not connected 000D Browsing not supported by remote device 000E Browsing timeout 000F Interim response success 0010 Link key missing in remote device 0080 Operation rejected due to invalid PDU 0081 Operation rejected due to invalid parameter 0082 Operation rejected due to invalid content 0083 Operatio
179. d Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 80 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 6 AVRCP1 5 AT Command Reference 2 6 6 1 390 AVRCP1 5 configuration The flags of S390 are designed so that cleared flags correspond to machine friendly automated and complete configuration whereas set flags except bits 4 5 7 correspond to a more human friendly configuration S390 Range 0 FF 390 Default 7F S390 details are listed in Table 2 37 Table 2 37 390 AVRCP1 5 configuration Do not append hint strings Append hint strings to Play status AVPS Player application settings AVPA AVPV O 0x01 Hint strings 1 Folder AVFSI Media type AVMEI Media element attribute AVMEA Now playing track attribute AVNPA Ignored Available attributes are not appended to media items AVMEI aadinclenienk On the test device extra attributes did not provide additional 1 0x02 information just the track name which is already provided attributes browsing Reason More importantly the extra attribute data was observed to overrun the UART Tx buffer due to an inflated data format for presentation start stop tags etc Print displayable names attribute values and other 0 strings in hexadecimal format more machine fri
180. d custom data over SLC HFG AT HFGX lt data gt Send custom data lt data gt over SLC from HFG instance Please refer to section 2 9 24 for details on utilizing ACL for custom data 2 6 8 2 23 HFG status ATI66 Returns the status of the HFG instance Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 139 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Not connected SLC connected Audio connected In call SLC connected In call audio connected In call audio connected In call setup incoming dialling alerting SLC connected In call no SLC ODO anim eAIwINJ oO 2 6 8 2 24 HFG Call Records The HFG maintains call records for all calls Even when no HF is attached to the HFG no SLC existing the HFG needs to be aware of all ongoing calls in order to send the correct HFP indicators as soon as an HF connects Also it is mandatory for the HFG to respond to a current call list request issued by the HF AT CLCC 21a_4 31 1 The HFG queries its internal list of current calls and replies automatically to AT CLCC The list of current calls is displayed to the host by AT HFGC AT commands beginning with AT HFGC change the state of a call record AT HFGC List all current calls S354 controls verbose mode and is detailed below The response for
181. d stream control A2DP stream vs HFP SCO MPS compatibility is enabled by S386 gt 0 Table 21 1 below compares MPS procedures with non MPS procedures for various scenarios In earlier versions when MPS was not supported yet streaming versus call scenarios have been addressed by 355 This S Register allows to assign priority to either A2DP or SCO or to set them equal A request of the lower priority entity for audio resources is rejected if at the same time the higher priority entity already owns the audio resource If audio resource is requested by an equal priority or higher priority entity the request is accepted audio of the active entity is suspended A2DP or closed SCO and audio resource is granted to the requesting entity The default setting S355 1 SCO priority effectuates that an A2DP stream is suspended if SCO audio is required e g for a HFP call If MPS is disabled then the existing 355 rules and related behaviour remains in place Table 2 62 MPS procedures A2DP signalling connect BTM51x initiates start of streaming if permitted by 355 no matter if BTM51x is SRC or SNK BTM5 1x initiates start of streaming only if the connection was initiated from local device and if configured as SRC S300 2 Streaming is initiated by AT APR from either end or by AVRCP PLAY command provided ARCP is connected AVRCP TG reception of pass through command PLAY 0x44 Notify host controller via UART m
182. d voice capabilities Based on the market leading Cambridge Silicon Radio BCO5 chipset these modules provide exceptionally low power consumption with outstanding range Supporting Bluetooth v2 1 EDR specification these modules provide the important advantage of secure simple pairing that improves security and enhances easy use At only 14 mm x 20 mm the compact size of the BTM510 is ideal for battery powered or headset form factor audio and voice devices With a 16 bit stereo codec and microphone inputs to support both stereo and mono applications these modules also contain a full integrated Bluetooth qualified stack along with SPP HFP 1 6 HSP AVRCP and A2DP profiles Customers using these modules may list and promote their products on the Bluetooth website The BTM510 511 modules include an embedded 32 bit 64 MIPS DSP core within the BCO5 This is integrated with the Bluetooth functionality which allows designers to add significant product enhancements including features such as echo cancellation noise reduction and audio enhancement using additional soft codecs The availability of the 16MB of flash memory in the module allows complex functionality to be included DSP routines can be licensed through a number of specialist partners Typical applications for these modules include Bluetooth stereo headsets VoIP phones and wireless audio links To speed product development and integration Laird Technologies has developed a comprehensive AT
183. dard navigation AT commands AT AVOQFS lt s gt lt e gt List folder items current path AT AVSP lt n gt set path downwards AT AVSPU set path upwards one level AT AVSPl lt n gt play item selected by browsing AT AVQMI lt n gt query media item attributes Arguments lt n gt UidCachelndex or UID lt s gt start_offset optional set to O if not passed lt e gt end_offset optional set to lt s gt 9 if not passed Beyond standard operations like list folder items set path up down etc defined in AVRCP1 5 specification the BTM51x provides a set of combined commands which facilitate more convenient navigation See Table 2 36 Table 2 36 BTM51x combined navigation AT commands Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 79 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module List folder items next window AT AVOQFS lt s gt with start offset lt s gt managed AT AVQFSN by BTM51x Set path upwards to root Multiple calls of AT AVSPU until root folder is AT AVSPR reached AT AVSPQ lt n gt _ Set path downwards and query AT AVSP lt n gt AT AVQFS AT AVSPUQ Set path upwards one level and query AT AVSPU AT AVQFS AT AVSPRQ Set path upwards to root and query AT AVSPR AT AVQFS Arguments lt n gt UidCachelndex or
184. date ATI318 Detailed list of available CVC images Format See ATI35 Variant IDs S Standard 8 kHz B Bandwidth extended BEX W WBS 16 kHz ATI333 Full AT firmware version number ATI350 detailed list of available CVC images duplicate of ATI318 ATI411 Short press duration in ms S411 ATI412 Medium press duration in ms S411 S412 ATl413 Long press duration in ms S411 S412 S413 ATI144 Power mode and sniff interval in milliseconds ms Like ATI44 but the sniff interval is in milliseconds instead of slots Rounding is indicated by ATI145 Like ATI45 but all values are in milliseconds instead of slots Rounding is indicated by ATI146 Like ATI46 but all values are in milliseconds instead of slots Rounding is indicated by Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 250 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 3 3 Error Responses As of firmware v18 1 4 0 three digit error codes are enabled by default Refer to section 2 9 19 Table 3 3 BTM Error Responses 001 Register not recognised 002 Value for register is out of range 003 Incoming call NOT pending 004 No call to connect to This error code has meaning for ATO only 005 Syntax Error 006 Empty String 00
185. ddr gt The module must be configured as AVRCP Control by S register 301 1 Furthermore a category must be selected in S register 302 Response lt cr lf gt CONNECT 123456789012 110E gt lt cr lf gt Or lt cr lf gt NO CARRIER 110E lt cr lf gt Or lt cr If gt ERROR 47 lt cr lf gt Or lt cr f gt ERROR 48 lt cr lf gt After an AVRCP connection has been established the module remains in AT command mode S Register 531 is ignored for AVRCP connections 2 6 4 2 2 Release AVRCP control connection AT AVH Release AVRCP control connection Response lt cr lf gt NO CARRIER 110E lt cr If gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 Bi Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 4 3 AVRCP Control CT This section describes AT Commands and S registers relevant to the BTM5xx as an AVRCP Controller S301 1 or 3 2 6 4 3 1 Send UNIT INFO Request AT AVU Send a Unit Info request to a connected AVRCP target Response immediately lt cr lf gt 0K lt cr If gt On command completion lt cr If gt AVUR lt n gt lt unit_id gt lt unit_type gt lt company_id gt lt cr lf gt lt n gt status O success 1 fail 4 timeout For unit_type see Table 2 29 If lt n gt is greater than zero unsuccessful outcome lt unit_type Examples of u
186. de Bluetooth Multimedia Module AT AVSPRQ Set path upwards to root and query Parameters None Response Success AVFSL AVFSI Table 2 41 and Table 2 42 Failure AVFC ERROR lt asc gt With lt asc gt avrcp status code see Table 2 50 Terminator OK ERROR 135 AT AVSPR Set path upwards to root Parameters None Response Success AVFC lt nitems gt See Table 2 42 Failure AVFC ERROR lt asc gt With lt nitems gt number of items in root folder lt asc gt avrcp status code see Table 2 50 Terminator OK ERROR 135 AT AVSPl lt n gt Play item selected by browsing Parameters lt n gt UidCachelndex 0 9 or UID 16 hex characters prefix not required The parameter is expected to be chosen from an earlier file system query such as AT AVOQFS In particular UID cache index always refers to the last printed list Response Success AVPI 0000 Failure AVPI ERROR lt asc gt With lt asc gt avrcp status code see Table 2 50 plus subsequent automatic queries due to track changed event play status changed etc depending on 390 Terminator OK ERROR 135 AT AVSPQ lt n gt Set path downwards and query Parameters lt n gt UidCachelndex 0 9 or UID 16 hex characters prefix not required The parameter is expected to be chosen from an earlier file system such as AT AVOQFS In
187. disconnection lt cr If gt HFG AUO lt cr lf gt only if audio connected On SLC disconnection lt cr If gt NO CARRIER 111F lt cr f gt Refer to UUIDs in CONNECT NO CARRIER Messages 2 6 8 2 5 Signal incoming call from AG to HF 4_ 4 13 AT HFGC lt number_string gt lt type gt Signal an incoming call by sending sending RING and CLIP lt number_string gt lt type gt to HF periodically The lt number_string gt field represents the phone number of the ringing party The type field specifies the format of the phone number and can be one of the following values Values 128 143 The phone number format may be a national or international format and may contain prefix and or escape digits No changes on the number presentation are required Values 144 159 The phone number format is an international number including the country code prefix If the plus sign is not included as part of the number and shall be added by the AG as needed Values 160 175 National number No prefix nor escape digits included Refer to the Hands free Profile Specification 5 The HF is now expected to answer or to reject the call Optionally an incoming call can be answered or rejected at the HFG side AT HFGCA AT HFGCH Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 132 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Gu
188. e lt dn gt st player sub type UI32 hex ps play status UI8 hex Options cs character set UI16 hex i nl length of displayable ak name UI16 hex Hint string inserted after lt ps gt dn displayable name string of indicated lt dn gt printed in hexadecimal format character set non printable characters presented as xx Example AVAPI 0001 01 00000000 02 006A 0005 Music AVFSI File system item AVFSI lt uid gt lt ft gt uid item UID Ul64 hex folder E E ft folder type UI8 hex lt IP gt lt CS gt lt Nl o gt lt dn gt soe Table 2 45 ip flag is_playable BOOL Options cs character set UI16 hex 390 nl length of displayable ag i i name UI16 hex Hint string inserted a ter lt t gt dn displayable name lt dn gt printed in hexadecimal string of indicated format character set non printable characters 391 presented as xx UidCache index n inserted optionally hexadecimal after AVES format see 390 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 95 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Biamples AVFSI 1 OF8BBB8D26804017 01 Titles 0 006A 000B Barry White AVFSI OF8BBB8D2680401 7 01 0 006A 000B 426172727920576869746 5 AVMEI Media element AVMEI lt uid gt lt met gt Hie itari PID GAS
189. e 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 315 0 0 3 SCO 0 audio interface select Internal codec default 1 12S master 2 12S slave 3 PCM master PCM_M 4 PCM slave PCM_S 316 63 1 63 12S sampling rate capability for A2DP values can be added for all sampling frequencies supported Register is referenced if S314 gt 0 at boot time requires AT amp W and ATZ for new values to become effective 1 48 kHz 2 44 1 kHz 4 32 kHz 8 24 kHz 16 22 05 kHz 32 1 A2 16 kHz DP Source at least one of these sampling frequencies 48kHz 44 1k A2DP 2 val Hz must be supported Sink both 48 kHz and 44 1 kHz must be supported at least ues ignored as they are not supported by SBC neither by APTx S415 Enable Microphone Input Gain adds extra 24 dB to input gain Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird 181 Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set sampling rate for Audio Loopback and Fixed sampling rate Loopback Mode Sampling Rate 0 8 kHz 8 kHz 1 11 025 kHz one 11
190. e gt dec This command is used if a call is initiated at the HFG and not at the HF OK is not sent to the HF in contrast to HFGC1 Signal an outgoing call status by sending CIEV 3 2 callsetup 2 indicator to HF If an audio connection does not exist it is initiated A call record with status dialling is created and can be checked by AT HFGC The optional parameters lt number_string gt and lt type gt are stored in the call record Their format is described in Signal incoming call from AG to HF 4 4 13 2 6 8 2 8 Signal termination or rejection of a call from AG to HF 6_4 15 AT HFGCH HFG call hang up Terminate or reject all calls in one of the following states active incoming waiting dialling alerting And signal termination of a call by sending CIEV 2 0 call 0 indicator to HF Ifa call is active the active call is terminated hang up Else if a call is incoming ringing the incoming call is rejected Else if an outgoing call is being set up dialling alerting the outgoing call is terminated Else if a call is held the held call is released hang up If none of the above conditions are met an ERROR 063 is returned According to the call status of the terminated or rejected call HFGT or HFGR is sent to the host AT HFGCHL Terminate all calls of status e a Terminate call signals by sending CIEV 4 0 callheld 0 indicator to HF The appropriate call record is deleted
191. e Manager Embedded Wireless Solutions Support Center http ews support lairdtech com 42 www lairdtech com bluetooth Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 3 2 A2DP Example 2 This section gives an example of an A2DP connection between a Laird BTM5xx device A as Audio Sink wireless speaker wireless headphones and another Laird BTM5xx device B as Audio source Both BTM5xx devices are assumed to be connected via UART to a terminal program e g Ezurio Terminal on a PC The required instructions along with the sequence of AT commands are listed in Table 2 21 Figure 2 13 through Figure 2 16 show appropriate screenshots Table 2 21 A2DP Example 2 Command Sequence and Instructions 1 Connect an audio source e g MP3 player ext audio to the stereo audio input line in of Device B Preparation equipment 2 Connect a headphone or a speaker to the stereo audio output line out of device A Restore factory default settings AT amp F A2DP profile is enabled per default in S102 Audio Sink role is enabled per default in 300 ATS515 040400 Set A2DP device class Sink Preparation A ATS512 4 Make device connectable and discoverable permanent setting AT amp W Store settings ATZ Reset ATI4 Query Bluetooth device address of Dev A lt BdAddr_DevA gt AT amp F Resto
192. e connected and if NVQ lt 300 Bit 1 Immediate reset on ERROR 102 Bit O See Management of Persistent Store for more detail 375 1 Misc Inhibit active encryption request for remote devices BT2 0 or earlier bitmask Disable encryption request for incoming By connections any profile Disable encryption request for outgoing pi connections any profile S376 1 WBS mSBC Enable WBS mSBC We don t recommend a change while HFP is connected but it works for demo purposes between two BTM51x modules 0 Disable 1 Enable default S377 1 Enable CVC BEX CVC support is not currently available this S register can be ignored until further notice Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 224 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Close audio on voice recognition stop 378 1 0 1 HSG HFG 0 Disable 1 Enable default 379 0 0 1 HFP HSP Enable RX message for HFP SLC spy and HSP ACL spy 0 Disable default 1 Enable 380 0 0 1 HFP HSP Enable UC unrecognized command message for HFP and HSP 0 Disable default 1 Enable 381 Ox7f 0 0x7f HFP HFP indicators enable mask Individual indicator activation See also HFP1 6 spec se
193. e discovery profile security level O is always assigned internally 2 5 6 2 10 capability 321 S Register 321 defines the O capability of the device The setting is used for O capability negotiations prior to SSP in order to identify whether the O capabilities of both devices are sufficient for MITM protection if required Table 2 10 displays possible values Table 2 10 IO capabilities 0 Display only The device is able to display communicate a six digit decimal number The device can display or communicate a six digit decimal number and has a mechanism that allows the user to indicate either yes or no pressing a single yes button before a timer expires or two buttons for yes and no The device has a numeric keyboard that can input numbers O through 9 and a confirmation The device has at least two buttons that can be 1 Display yes no 2 Keyboard only easily mapped to yes and no or a mechanism whereby the user can indicate either yes or no e g pressing a button within a certain time limit 3 No inputno The device does not have the ability to indicate yes or no and the output device cannot display or communicate a 6 digit decimal number 4 Reject lO Cap lO capability requests prior to SSP are rejected requests 2 5 6 3 Force Man in the middle protection MITM 322 322 can enable protection against MITM attacks This S Register only applies if the security level S3
194. e external audio codec scenario This may be needed for higher subjective sound quality granted by dedicated audio codecs with advanced DAC s ADCs and advanced audio filters A system with external audio codec typically requires a high frequency master clock signal in addition to the 12S synchronisation lines SCK and WS This clock drives the external CODEC s filter circuits and subsequent internal circuits with precise synchronisation to the master clock This high frequency master clock is typically in a range of 24 MHz or 12 MHz Because the BTM5xx cannot synchronise to an external clock as a slave for this purpose it would have to provide this master clock signal BTM51x cannot provide this high frequency master clock signal due to a hardware limitation When operating an external CODEC without synchronisation artefacts are audible in periodic intervals It has been observed that these artefacts appear at around 15 kHz in the audio spectrum and are audible as noise 2 8 22 PCM Pulse code modulation interface Audio data of a SCO link can be routed to from the PCM interface The PCM is intended to carry bidirectional voice data at typically 8 kHz sampling frequency but not stereo audio The PCM interface is composed of 4 signals as outlined in Table 2 70 PCM_IN PCM_OUT PCM_SYNC PCM_CLK These signals are shared with the 12S bus so either I2S or PCM can be used but not both simultaneously The PCM interface offers a wide range of confi
195. e is allowed to enter SSR in 0 1s Range 0 170 default 0 350 SSR minimum local timeout Minimum time with no data exchange in sniff mode before local device is allowed to enter SSR in 0 1s Range 0 170 default 0 For 348 S350 refer to Table 2 100 for a mapping between register value slots and seconds SSR parameters 348 and S349 can be understood as a permission to the remote device to be absent for whole numbered integer multiple of the current sniff interval Thus it only benefits the remote device in terms of decreased power consumption 350 gives control on the local SSR timeout if the remote device has given permission to enter SSR Refer to the BTM41x Low Power Application Note for additional information It can be accessed from the Laird Embedded Wireless Support Site BTM41x product page under the Documentation tab Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 204 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 100 Sniff sub rating SSR register mapping S 348 350 0 0 0 0 38 42 40 6400 4 1 1 160 0 1 43 47 45 7200 45 2 2 320 0 2 48 52 50 8000 5 3 3 480 0 3 53 57 55 8800 5 5 4 4 640 0 4 58 64 60 9600 6 5 5 800 0 5 65 74 70 11200 7 6 6 960 0 6 75 84 80 12800 8 7 7 1120 0 7 85 9
196. e of non volatile memory procedures described in Management of Persistent Store should be taken into account For a quick start Hostless operation provides an example for hostless operation demonstrating automation features on a BTM511 DVK V04 BTM51x audio development kit 2 7 1 Auto Connect Records ACR The auto connect feature of BTM51x addresses two use cases Automatic connection to known devices and profiles at boot time Automatic re connection following link loss when returning back into range Given that BTM51x supports multiple profiles and allows simultaneous connections to different devices with different profiles a database is required which defines values such as the Bluetooth device address profiles and the order of the automatic re connection attempts This database is composed of a list of up to five auto connect records ACR stored in persistent store and referred to as ACR table There are two options to populate or modify the ACR table which do not exclude each other Manual mode full control on each AC record by AT commands Automatic host less mode population of ACR table automatically based on established connections To cater for manual mode a new command family AT AC was created Description of these commands can be found below For automatic mode or host less mode a new ACR is added as soon as a connection with a new device is established If the device is already known in the ACR tab
197. e resumption of A2DP streaming The only user action required is to answer the call at the BTM5xx module by AT HFCA or an appropriate GPIO button assigned to the HF green button Asynchronous messages related to suspend resume actions are listed below HF messages are not shown here APSUS lt A2DP stream suspended initiated remotely FS8000 INT 8kHz sampling rate on internal codec HF AU1 SCO connection tia ongoing call HF AUO SCO disconnected FS44100 INT 44 1 kHz sampling rate on internal codec APSTR lt resuming A2DP stream initiated remotely In the second scenario where the audio source and the HF gateway are different devices you must take more precautions Neither device knows if the audio resource of the A2DP sink HF unit is in use when one requests an audio link For example if the mobile phone signals an incoming call and requests a SCO link while A2DP is being streamed from another device the mobile phone is unaware of A2DP stream and so cannot request its suspension In this case the audio stream must be suspended manually by a host microcontroller AT APU before accepting the call Once the call finishes the audio stream should be resumed manually by a host microcontroller AT APR S register 355 audio resource override helps to address and automate this scenario It controls whether incoming outgoing requests for A2DP or SCO connections are accepted by requiring that a link of another type
198. e selected audio interface S315 It has not been evaluated how far BEX provides benefits in terms of audio quality or similar It is provided in the hope to be useful and can be enabled by 377 1 It will then only be loaded for a narrow band 8kHz SCO link WBS disabled However BEX breaks the approach of controlling fixed sampling rate by S419 and therefore presents some kind of exception ATI318 and ATI35 allow to check availability of all CVC images All images flavours and its variants are being loaded to the DSP and the outcome is printed to the UART For ATI318 the outcome is printed in detail for each single image nine in total Variants are identified by an appended uppercase character s Standard narrow band B BEX W Wide band speech WBS Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 189 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Example for ATI318 Ezurio Terminal Ver 6 8 0 CTS DSR DCD RI RTSY DTR BRK CAPTURES T Open com38 9600 N 8 1 HHeHHHHHH H T I T o T T T T T gt wiwlwiw www AAA AAAA AA NNNNNNNNN CIUIOIUIUIUIUIVIOI al el alan el ae at COOL WOVw TwwM ATI35 in contrast is a compact presentation of available CVC images A group of variants is summarised in one line An extra decimal number appended to each line allows to
199. e the automatic storage of link keys in the trusted device list depending on incoming outgoing and general dedicated bonding See Table 2 88 Automatic storage of link keys Table 2 88 Automatic storage of link keys 0 Do not store cache only 325 0 1 1 Store automatically default Identical with 538 Automatic link key storage on dedicated bonding outgoing DBO Automatic link key storage on general bonding 326 0 1 0 Do not store cache only outgoing GBO 1 Store automatically default Automatic link key storage on dedicated bonding 327 0 1 0 Do not store cache only incoming DBI 7 1 Store automatically default Automatic link key storage on general bonding 328 0 1 0 Do not store cache only incoming GBI 1 Store automatically default 2 9 5 Profile Connection Status The connection status of a profile can be queried by an ATI Command This might be helpful in order to decide whether to disconnect all connected profiles via ATH or a specific one For details see Table 2 89 Table 2 89 Profile connection status O Not connected 1 Connected local command mode Get connection status of SPP ATI60 2 Connected remote command mode Identical with ATI9 O Not connected Get connection status of A2DP ATI61 1 Connected and streaming 2 Connected but not streaming suspended 0 Not connected Get connection status of AVRCP AT
200. e ways to drop a connection One method is similar to the above but instead a character sequence is used This is to eliminate ambiguity when a data call via a mobile phone is in progress when the call is established using the phone s Bluetooth AT modem The second method involves the host dropping the DTR DSR from the module s viewpoint modem control line Dropping a connection using the escape sequence severely impacts throughput reducing the data rate from about 300 kbps to around 85 kbps To cater for this performance hit the device s connection drop capability is configurable to be in one of two modes The first mode allows a connection to be dropped using either method This is the default The second allows only the DTR drop mode Enable this mode using the S507 register AppendixTable 3 1 The escape sequence is as follows lt Guard time gt lt Esc Chr gt lt Guard time gt lt Esc Chr gt lt Guard time gt lt Esc Chr gt lt Guard time gt When a file transfer is occurring which contains multiple lt Esc Chr gt characters the module does not drop into command mode Thi is because file transfer occurs quickly and the gap between characters gap is much shorter than the lt Guard time gt The lt Esc Chr gt character can be changed via the S2 register and the lt Guard time gt interval can be specified via the S12 register Appendix Table 3 1 2 5 9 7 SSO Asynchronous Messages RX lt string gt This response
201. each call record if it exists is as follows lt cr lf gt lt idx gt lt dir gt lt call_status gt lt call_mode gt lt fmultiparty gt lt number_string gt lt number_type gt With idx unique index of call 1 digit dir O gt for outgoing call 1 lt for incoming call Active Held Dialling outgoing Alerting outgoing Incoming incoming and ringing call_status Waiting incoming and waiting whilst another call is active Voice Data Fax Call is point to point p Call is part of multiparty m call_mode S 1 OIN oO UW BB WIN o fmultiparty number_string Calling or called line identification presentation Refer to HFG audio routing number_type Number type for CLIP refer to HFG audio routing Response at the end of list Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 140 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module lt cr f gt OK lt cr lf gt 354 Enable disable verbose presentation of call records S register 354 controls verbose presentation of call records AT HFGC Value 0 non verbose mode default Value 1 verbose mode Verbose mode gives better understanding of call states and call records in a human readable style whereas non verbose mode is the
202. eady set in S368 the flag is cleared in S368 Check local HCI role for each profile ATI56 Range 0 1FF 2 9 23 Encryption If the remote device is BT2 1 and later all connections except SDP service discovery profile are encrypted Encryption key length is 56 bit If the remote device is BT2 0 or earlier an encryption request is sent to the remote device once the connection is established regardless of the profile which has connected active encryption request by BTM51x If required this request can be disabled by 375 differentiated by connection direction incoming outgoing 2 9 23 1 375 disable active encryption request to BT2 0 devices 375 inhibit active encryption request for remote devices BT2 0 or earlier Bit O disable active request of encryption for incoming connections any profile Bit 1 disable active request of encryption for outgoing connections any profile Default value 1 Values can be ORed 2 9 24 SLC ACL Features Transmitting custom commands over SLC ACL Headset profile HSP and Hands free profile HFP are each based on an Rfcomm link to send and receive the AT commands defined in the appropriate profile specification For HSP the Rfcomm link is called ACL and for HFP the Rfcomm link is called SLC service level connection As of firmware version 22 2 5 0 some commands were added allowing to send and receive custom commands over the SLC ACL Sending SLC
203. eccceccceeceececeeeeeeeeeeeceseseeeeeeeestseeeteeenaees 31 2 6 Bluetooth Profiles oo cece eee c cece cence eee eeeeeeeeeeeceeeeceeeeseeeeceeeeeseeeteeeteeeneeeteeeteeeneeeteeeneee 33 2 61 Profil ACtiVATIOMN sesstessz ecole ees pec heten seeds a a E AARE AEE eed 33 2 6 2 SPP Serial Port Profile cece ccccecceccceceseceeeeeeecceccccceeeeeccessessessrensnnnrsnrrneaeeueeueeeeeeeeeeeeness 33 2 6 3 A2DP Advanced Audio Distribution Profile ccccccecceeceeeesssssesseeeeseeeeeeeeeeeeeeeenegs 38 2 6 4 AVRCP 1 0 Audio Video Remote Control Profile cece eceeeeeeeseseesseeeeeeeeeeeeeeeeeeees 57 2 6 5 AVRCP 1 5 Audio Video Remote Control Profile CT role 71 2 6 6 AVRCP1 5 AT Command Reference cccccccececceceseeeeeeceeeeceeeeeeeeeneescteeesneeeenseeeneeeeees 81 2 6 6 HSP Headset Profile cccccccccceccscccceeeeeeecccecceceeeeeecescessenensnnsnnrrasenaeeeeeeeeeeeeeeeeneeneeneees 106 2 6 7 HFP Hands free Profile oo ccccceccccccccccceeeecceccceceeeececescessnesnnnnrsnnraaeensaeeeeeeeeeeeeeeeneeneeeeees 117 2 6 8 MPS compatibility layette sag peceseceeni aae eaaa A AE EG 149 Zieh AOO saa E E E A sae 152 2 7 1 Auto Connect Records ACR sssssssseeesesttttttttt ttti tkk knna Enan EEE EREEREER EEE EEEEEEEEEE EEEE 152 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 5 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 061
204. edia Module 2 5 8 2 AT BIT Add Trusted Device This command stores the cached link key in the non volatile database If the database is full it responds with an ERROR If the device is already in the database then the key is replaced If the link key cache is empty a pairing has not been performed since powering this responds with an ERROR Response lt cr lf gt OK lt cr f gt Or Response lt cr lf gt ERROR lt cr f gt 25 83 AT BTD lt bd_addr gt Remove Trusted Device This command removes the specified device from the list of trusted devices in the non volatile database The response is OK even if the device is not in the database Response lt cr lf gt OK lt cr If gt 2 5 8 4 AT BTD Remove All Trusted Devices This command removes all devices from the trusted device list TDL in the non volatile database The device does not ask for confirmation Use with caution WARNING If you make a connection the link key gets cached in the underlying stack So if you subsequently delete the key using AT BTD and immediately request a connection to the same device then the connection is established To ensure this does not happen send ATZ after the AT BTD Response lt cr lf gt OK lt cr If gt 25 8 5 AT BTW List Cached Trusted Device This command lists the cached trusted device Response lt cr lf gt 12346789012 lt cr lf gt OK lt cr lf gt If the cache is empty the response is as follows Response lt cr If gt
205. eeeeteeeeetneeeeenes 188 2 9 2 SCO eSEO Audio Link SPP SCO serienn eaa E AE EA 190 2 9 3 Cable ReplacEMENtss ceciren aaa a a aa a AAA ETE 193 2 9 4 Link Key Management esseerseisresrenrererrnetrrecrtarinerrntriunreneseten rak traa tnra cttn enin ka ennea 194 2 9 5 Profile Connection Status ieiunia ia hia a ae iai aka 195 2 9 6 Disconnecting Profiles ccccccccccececeeceeceeeeeeeeeeeeeeeeeceneeeceeeseseeeteeeeteesseeeneeenieeeneeess 196 2 9 7 Legacy Response Format BISMZ2 cc cccececeeeeeeeeceeeeeeeeeeeeeceeseeeeeeceeesteeeteeeteeeenteens 197 2 9 8 UUIDs in CONNECT NO CARRIER Messages 0ccceeeceeeeeeeeeeeceereeeeneeeeeeteeeeentteeeees 198 2 919 UUIDS in Service Records Of ASP scsee esceccsecndstneersesssaonteaengh a i 199 2 9 10 Low Power Operation cccccceccceeeeeeeeecceeeeeeeeeeeceeeeeeceeeeeeeeeesetiieeeeeessntieeeeeesnenieeees 200 2 9 11 Page Scan Inquiry Scan Interval and WiINKOW cccceeeeeeeeeeeeeceeeeeeeteeeeetteetettteeenes 200 2 9 12 Multi profile Auto BTX S308 ccccceececceceeeeeeeeeeeeeeeeeeeeeeceeeeceeeeeeeeteescieeeseeesieeenteeess 201 29 T3 SITE IOC E eisene a an Desa sias once cat beh a ae a n 202 2 9 14 Sniff Sub rating SSR ccc cccccccccsccecssececesseeeeccseeeecsseeseseeeseeseeeestaeesesaeeseneeeessaeeeens 204 2 9 15 Maximum RF Tx Power Level c cccceeececeeeeceeeeceeeeeeeneeeeeceeeeceaeeeseceeeesiieeeeseeeeenas 205 2 9 16 Manufacturing INTO
206. egisters See Gain Table S689 is also affected Set output gain level Set output overall gain dBr Set input gain level Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 589 0 22 default 12 S689 450 215 default 90 590 0 22 default 12 164 S Ni WI AJAI OAOAININININININIJN OoO o o o o Toy o o yo See GainTable value must be entered and is returned multiplied by 10 S589 is also affected See Gain Table S690 is also affected Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set input overall gain dBr S690 450 215 See GainTable value must be entered and default 90 is returned multiplied by 10 S590 is also affected Increment current output AT GOU Error 57 appears if maximum gain level is gain level reached Decrement current output AT GOD Error 58 appears if minimum gain level is gain level reached Set current output gain AT GO lt n gt Range for lt n gt 0 15 dec level Query current output gain AT GO level Restore current output gain AT GOR level from S589 Save current output gain AT GOS level to 589 Increment current input AT GlU Error 57 appears if maximum gain level is gain level reached Decrement current input AT GID Error 58 appears if minimum gain level is gain level reached Set current
207. endly than human friendly ASCII presentation of Print ASCII strings surrounded by double quotes 2 0x04 i Non printable characters are presented hexadecimal as eum 1 xx A character is considered non printable if it is gt 128 double quote backslash space or comma More human friendly than machine friendly but also has more exceptions such as character set On automatic requests for now playing track attributes query 3 0x08 Attributes query basic 0 Full set of attributes title artist album track no total full tracks genre playing time 1 Basic set of attributes only title artist album Action on Play status On reception of AVPS notification play status changed and if new status is playing 0x01 4 0x10 changed notif Automatically query now playing track attributes AVPS 1 Do nothing Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 81 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Action on Track On reception of AVTC notification track changed 5 0x20 changed notif 0 Automatically query now playing track attributes AVTC 1 Do nothing Action on No automatic query of now playing track is initiated on 5 BAG Now playing content ignored the reception of AVNPC This was deemed not useful and changed notification
208. ent store Response lt cr f gt lt data gt lt cr f gt OK lt cr lf gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 20 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 5 5 9 AT BTE Delete EIR data from baseband This command deletes the EIR data in the baseband Response lt cr f gt OK lt cr f gt 2 5 5 10 AT BTE Delete EIR data from baseband and RAM buffer This command deletes the EIR data in the baseband and deletes any data from the RAM buffer Response lt cr f gt OK lt cr f gt 25 5 11 AT BTE Delete RAM buffer This command deletes all data from the RAM buffer Response lt cr f gt OK lt cr lf gt 2 5 5 12 AT BTEW Delete EIR persistent store This command deletes the EIR persistent store Response lt cr f gt OK lt cr f gt 2 5 6 Secure Simple Pairing SSP Secure Simple Pairing SSP has been introduced since Bluetooth 2 1 EDR It aims to increase the security provided by a Bluetooth link whilst making the pairing process more user friendly There are whitepapers about SSP available through the internet provided by the Bluetooth SIG and other companies explaining the background and mechanisms of SSP They can be found by searching the internet for topics such as B uetooth Secure Simple Pairing Read these to better understand SSP and the followin
209. er http ews support lairdtech com Americas 1 800 492 2320 166 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module SD_OUT PCM_OUT 4 7 12S Serial data out 12S Word select WS PCM_SYNC 5 6 right left ch SCK PCM_CLK 6 4 I2S clock GND 1 2 3 4 9 22 13 47 10 GND 2 8 2 1 1 12S MCLK In addition to the 12S signals mentioned above many external codec ICs require a high frequency master clock MCLK Typically this clock is a multiple integer of the sampling rate f e g 128 f 192 f 256 f 384 f 512 f and so forth Unfortunately BTM51x cannot provide such MCLK signal Laird recommends you select an external codec IC which has the capability of creating the MCLK internally from the bit clock signal SCK Such capability is referred to as PLL phase locked loop or FLL frequency locked loop functionality of the codec device 2 8 2 1 2 12S example This section describes an example where the 12S interface of a BTM5xx is used as digital stereo input of an A2DP source SD_IN Stereo PCM_IN Audio Out BTM5xx 12S slave I2S master device BTM5xx A2DP source A2DP sink WS __ Bem_SYNC SCK Bom OUT Figure 2 32 BTM51x I2S example block diagram Connect an 12S slave source as outlined in the block diagram Table 2 56 The SD_OUT connection is not needed for this example The pin mapping is listed in Table 2 70 A thi
210. ered multiple SSR is supported for BTM51x as of f w version v22 2 5 0 Baud rate even when no data being exchanged a high baud rate corresponds to higher static current consumption than a comparable low baud rate The cost of a lower baud rate is lower data throughput obviously 2 9 10 1 Page Scan Inquiry Scan Interval and Window Page scanning means the module is connectable Inquiry scanning means the module is discoverable With the following S registers the power consumption of the BTM can be influenced at the cost of longer connection establishment time and longer time until a BTM is discovered The page scan window defines the time for the module to look out for incoming connection requests paging The inquiry scan window defines the time for the module to look out for incoming inquiry requests device discovery If the module is both connectable and discoverable 512 4 or AT BTP issued it mutually performs page scanning and inquiry scanning as shown in Figure 2 41 If connectable only the module performs page scanning only repeatedly and if discoverable only then the module performs page scanning only S register 508 defines the page scan interval in ms range is 11 2250 S register 509 defines the page scan window in ms range is 11 2250 S register 510 defines the inquiry scan interval in ms range is 11 2250 S register 511 defines the inquiry scan window in ms range is 11 2250 Embedded Wireless Solutions Sup
211. ereo audio data between integrated circuits IC in embedded systems It connects an external audio CODEC or a wave file player recorder to a BTM module As most of audio media is available digitally these days there is no need to convert audio to analogue and then back to digital on the BTM5xx module Provided a digital medium is played over A2DP with a BTM5xx as A2DP source then a D A and subsequent A D conversion between the digital medium and the module A2DP source would lose signal quality due to non optimal settings of DAC ADC gains and noise picked up in the analogue path These issues can be eliminated by using the digital 12S interface rather than the analogue audio input An 125S interface consists of at least 3 signals bus clock SCK word select WS left right channel and serial data SD_IN SD_OUT On a BTM5xx module there are separate data lines for in input and output for a total of four I2S signals I2S signals are mapped to the PCM pins of a BTM51x as outlined in Table 2 70 When connecting two devices via 12S one must be the I2S master and the other must be the 12S slave The 12S master provides SCK and WS signals output and the 12S slave synchronises to these signals WS and SCK input S registers S314 A2DP and 315 SCO select the 12S role for a BTM51x I2S master I2S slave Table 2 70 BTM5 1x 12S signal pin mapping SD_IN PCM_IN 3 5 I2S Serial data in Embedded Wireless Solutions Support Laird Cent
212. ericas 1 800 492 2320 228 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module On reception of AVAPC notification available players changed 0 Automatically query Action on available players list Available AT AVQAA j 0x80 players 1 Do nothing changed Note AVAPC has been nen observed when switching AVAPC forth and back between the standard player Music and other streaming applications e g web radio player or similar 391 1 0 21 UID Enable UID cache UID cache is designed to facilitate the handling of 64 bit UIDs Up to 10 UIDs of a list AT AVQFS are cached when the list is printed 396 1 0 1 SPP Unregister SPP service record once connected Leave the SPP service record unchanged once SPP is connected Unregister the SPP record once SPP is connected default Note This S register is queried at boot time only In order to view the effect AT amp W and ATZ are also required 397 000C 0 ff AVRCP AVRCP1 5 notification control Allows the disabling of selected AVRCP1 5 notification messages S411 400 200 1600 GPIO Short press duration in milliseconds 200 ms granularity S412 2500 500 4000 GPIO Component of medium press duration in milliseconds 500 ms granularity actual value is this value plus S411 actual value is returned b
213. ernal codec default 1 12S master 2 12S slave 315 0 0 3 SCO audio interface select 0 internal codec default 1 12S master I2S_M 2 12S slave I2S_S 3 PCM master PCM_M 4 PCM slave PCM_S An asynchronous message indicating the current sampling rate and the audio interface is sent to the UART whenever entering a SCO or A2DP connection The format of this message is FSddddd lt interface gt ddddd sampling frequency in Hz 4 or 5 digits lt interface gt INT internal codec 12S_M 12S master 12S_S I2S slave 309 or S504 may disable this FS message 2 8 2 1 4 A2DP sampling rate capability When entering an A2DP connection a negotiation phase finds the best sampling frequency air rate that matches both ends Therefore each A2DP end must expose its supported sampling frequencies When using the BTM5xx internal codec the supported sampling frequencies are known so the user does not need to do anything Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 168 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module But when using the 12S interface the supported sampling rates of the external circuit are not known by the BTM5xx The user must specify all sampling rates supported by S Register 316 Check Table 2 72 for details on S316 The negotiated sampling fre
214. ernal memory restrictions Extended inquiry data may be utilised to transmit information such as the friendly name UUIDs of supported profiles or user defined data within the inquiry process and without creating a Bluetooth connection The architecture for managing EIR data is composed of three buffers and a set of AT commands around them Baseband EIR data visible to inquiring devices RAM buffer allows accumulation of data EIR persistent store non volatile buffer copied to baseband at boot time As the input buffer length for one AT command is limited there is a RAM buffer to accumulate several short data packets The accumulated data of the RAM buffer can be copied to the Baseband where it becomes Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 18 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module visible to other inquiring devices immediately The content of the RAM buffer can also be copied to the EIR persistent store If the EIR persistent store contains data it is copied to the Baseband automatically at boot time This allows a flexible usage of extended inquiry data For example data with a low data rate e g temperature can be transmitted without creating a Bluetooth connection This method sacrifices encryption and authentication Extended Inquiry Response AT BTE
215. es sending a RING CONNECT response to the host This emulates serial cable replacement Values gt 0 reset S Register 504 to 0 Values lt 0 set SO 0 1 15 S504 to 1 If SO lt gt 0 and S100 lt gt 0 then SO must be set to lt 100 If a value is entered which violates this rule ERROR 29 is sent in response If S504 1 this returns 1 regardless of the value in non volatile memory Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 37 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Number of RING indications before auto disconnection A value of 0 disables this feature If SO lt gt 0 and S100 lt gt 0 then SO must be lt Iau to Dele S100 If a value is entered that violates this rule ERROR 29 is sent in response 383 0 0 1 Enable inquiry exception for SPP link 2 6 3 A2DP Advanced Audio Distribution Profile The Advanced Audio Distribution Profile is used for unidirectional transmission of high quality stereo audio streams between two Bluetooth devices A2DP must be enabled by setting 102 128 Also an A2DP role must be assigned to either the source or sink module Lastly the settings must be stored by AT amp W followed by ATZ An incoming A2DP connection request is accepted automatically if a valid link key for the paging device exists If no link key is
216. essages AVPTI Notify host controller via UART messages AVPTI BTM51x A2DP SRC HFG initiate A2DP stream on reception of status button released AVRCP TG reception of pass through command PAUSE 0x46 Notify host controller via UART messages AVPTI Notify host controller via UART messages AVPTI BTM51x A2DP SRC HFG initiate suspension of A2DP stream on reception of status button released Incoming call while streaming A2DP If S355 1 or 3 suspend A2DP streaming accept the call SCO request route the SCO link to audio interface If S355 0 or 2 reject the SCO request retain A2DP stream BTM51x A2DP SRC HFG initiate suspension of A2DP route SCO link to audio interface as required for the call BTM51x A2DP SNK HF ignore Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 150 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Call finished No extra action is taken BTM51x A2DP SRC HFG if A2DP terminated or stream was suspended due to the rejected call then re start A2DP stream BTM51x A2DP SNK HF ignore MPS service record No change A service record according to MPS specification is registered and can be accessed from remote devices when connectable SDP 386 provides three options to en
217. essages For backward compatibility the command ATH fulfils the same purpose Response lt cr lf gt NO CARRIER lt cr f gt 2 6 2 7 SPP Incoming Connections The module can be configured using AT BTP or AT BTG to scan for incoming connections from other Bluetooth devices It can also be configured via 512 to enter this mode by default on power up Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 36 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module When the lower layers detect an SPP connection request a RING 123456789012 string is sent to the host every second The command ATA accepts the connection and ATH rejects the request On connection if the SO Register is gt 0 then confirmation to the host is in the form CONNECT 123456789012 1101 lt When SO is 1 neither RING nor CONNECT is sent to the host and the connection is silently accepted If the S 100 register is non zero after ring indications are sent to the host and the host fails to accept or reject the connection an automatic hangup is executed 26 2 8 SPP Inquiry exception Inquiry exception is a feature which allows to start an inquiry AT BTI if an SPP connection is established and in connected command mode or remote command mode Normally this would not be permitted because it can lead to internal state issues
218. et for a BTM module This section divides AT commands into functional groups including module configuration Bluetooth profiles hardware units and miscellaneous functions 2 4 1 Assumptions All commands are terminated by the carriage return character OxOD which is represented by the string lt cr gt in descriptions below This cannot be changed All responses from the module have carriage return and linefeed characters preceding and appending the response These dual character sequences have the values Ox0D and Ox0A respectively and shall be represented by the string lt cr f gt All Bluetooth addresses are represented by a fixed 12 digit hexadecimal string case insensitive All Bluetooth Device Class codes are represented by a fixed six digit hexadecimal string case insensitive All profile specific commands are identified by the prefix shown in Table 3 2 Table 2 4 AT command pretix for profiles Serial Port Profile SPP AT SP Advanced Audio Distribution Profile A2DP AT AP Audio Video Remote Control Profile AVRCP AT AV Headset Profile HSP AT HS Hands Free Profile HFP AT HF 2 4 2 Command Syntax The following syntax is used in this document to describe optional or mandatory parameters for AT commands lt bd_addr gt A 12 character Bluetooth address made of ASCII characters 0 to 9 A to F and a to f lt devclass gt A 6 character Bluetooth device
219. ettings ATZ Reset AT BTP Make device temporary connectable and discoverable ATl4 Query Bluetooth device address of local device lt BdAddr_DevB gt Initiate A AT SPD lt BdAddr_DevB gt Initiate SPP connection from device A to connection device B Asynchronous messages PAIR 0 pairing successful A and B RING B only CONNECT connected A and B Connected A B lt data gt Any character entered on one end is displayed at the other end Enter command AorB IES Response OK command mode mode confirmed now AT commands are expected at the UART UART data from host is not sent across to remote device Disconnect AT SPH Response NO CARRIER A and B disconnection confirmed Joxi CTS DSR DCD RI RTSY DTR BRK CAPTURE Echo Clear Data Transfer Test Open COM24 9600 N 8 1 Figure 2 3 SPP example Preparation of Device A Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 34 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module ioj x CTS DSA DCDO AI RTS DTRV BRK CAPTURES Echo Clear Data Transfer Test Open COM30 9600 N 8 1 14 1644000002 OOFrOrorord KOAK AKAAKA ve 4 Uv a Figure 2 4 SPP example Preparation of Device B ioi xi CTS DSR DCD RI RTS DIR BRKI CAPTURES Echo Clear Data Transfer Te
220. ewise as of f w v22 2 5 0 SPP SCO can work with 16kHz sampling frequency similar to WBS wideband speech Relevant commands work as follows AT BTA2000 2007 The range 2000 to 2007 indicates that 16kHz WBS shall be used On the remote device S376 must be enabled 1 Otherwise the audio attempt will fail no audio AT BTA8 this command queries internally S registers to decide which SCO link type SCO eSCO and packets to request Whereas in previous versions 584 was queried to determine if all eSCO packets should be requested S584 gt 0 now S376 is queried first This means if S376 1 eSCO will be requested and WBS codec will be loaded If S376 0 and 584 gt 0 then all eSCO packets will be requested and the narrowband DSP application will be loaded when the audio link is established If S584 0 then just SCO packets will be requested Please note that the result may be pure noise if this is feature is used with another device which doesn t implement this assumption Table 2 86 All AT commands and S Registers for SCO eSCO links 0 unknown no SCO link ATI37 1 SCO 2 eSCO Check link type of current SCO connection SCO eSCO Table 2 87 SCO eSCO AT commands and S Registers Initiate SCO link AT BTAx x packet type bitmask recommended 7 1 HV1 2 HV2 4 HV3 Initiate eSCO link AT BTA100x x packet type bitmask recommended 7 1 EV3 2 EV4 4 EV5 Initiate eSCO link with AT BTA200x x
221. ews support lairdtech com Americas 1 800 492 2320 116 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Query AG ATI64 status Not connected ACL connected Audio connected Ringing ACL connected alnINj oO In band ringing audio connected Maximum data length 25 characters lt data gt a string of printable ASCII characters or the Send custom two digit hexadecimal presentation of a non printable e AT HSGX lt data gt character preceded by ACL instarice r must be used to terminate a command or block of data This feature can be used to transmit short data sequences or commands but is not suitable for transmitting large amounts of data Refer to Figure xx 2 6 7 3 Remote volume control HSP Remote volume control feature for HSP allows the audio gateway HSG to control microphone and speaker gains of HS unit In addition HS unit notifies the audio gateway HSG about local changes of microphone or speaker gain When an ACL is established HS is sending the current gain settings to the HSG synchronisation For HSP the feature is always enabled From HS a volume change notification is sent to HSG whenever the analogue gains are changed at HS i e on AT GO or assignments of S Registers 589 590 689 690 An incoming microphone speaker volume control message VGM lt gain gt VGS lt gain
222. f items in current folder UI32 hex AVFSL OK end tag success AVFSL ERROR lt asc gt 16h end tag error asc avrcp status code UI16 hex AVNPT Now playing track attributes start end AVNPT lt nAtt gt 16h start tag nAtt number of attributes to follow UI16 hex AVNPT OK end tag success AVNPT ERROR lt asc q gt end tag error asc avrcp status code UI16 hex AVPL Player application setting response list AVPL lt nitem gt start tag nAtt number of items to follow UI16 hex AVPL OK end tag success Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 94 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module start end AVPL ERROR lt asc gt end tag error asc avrcp status code UI16 hex response to AT AVQPVW A AVPC Player application AVPC lt nAtt gt start tag indication setting changed nAtt number of attributes list to follow UI16 hex start end AVPC OK end tag success indication of value Between start and end message lt ni gt change items of AVPV attribute values messages are sent AVAPI Available player AVAPI lt id gt lt Mt gt id player id UITG hex item mt player major type UI8 SSH gt PS gt LCS n gt CNl n gt es
223. f last gain used for SCO O Disable gain restoring for SCO S356 3 0 3 SCO 1 Enable output gain restoring for SCO 2 Enable input gain restoring for SCO Enable input and output gain restoring for SCO 2 Default Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 332 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Enable restoring of last gain used for A2DP O Disable gain restoring for A2DP S357 3 0 3 A2DP 1 Enable output gain restoring for A2DP 2 Enable input gain restoring for A2DP Enable input and output gain restoring for A2DP Default Suppress AVRCP direction indicator 5362 0 0 1 AVRCP O AVRCP direction indicator enabled 1 AVRCP direction indicator suppressed Set default post processing mode 5363 1 1 3 A2DP 1 Pass through no post processing 2 Full processing 3 Custom mode Delayed sniff mode The delay in seconds before local S364 0 0 31 al sniff parameters S561 S564 are requested after entering a connection Initial power mode after entering a connection S365 0 0 1 O Passive default 1 Active Request HCI slave role on connect for profile flags set Profile mask as per 102 Table 3 7 368 0000 0 1FF Misc Request HCI master role on connect for profi
224. for enabling sniff mode specifies that a requesting peer specify the M parameter as a minimum and maximum value This allows the master to interleave the sniff modes for all slaves attached For this reason sniff parameters are specified in the BTM module via four S registers S Register 561 specifies N S Register 562 specifies T and S Registers 563 564 specify minimum M and maximum M respectively Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 202 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Although the specification defines these parameters in terms of timeslots the S register values must be specified in milliseconds and the firmware converts it to timeslots High Power Consumption ange Low Power Consumption Data Exch Data Exchange lt 4 Data Exchange lt T Slots 561 ms Data Exchange T Slots 561 ms Data Exchange lt ili lt T Slots S562 ms T Slots S562 ms T Slots S562 ms N Slots 561 ms N Slots 561 ms N Slots 561 ms gt i t M Slots Negotiated H M Slots Negotiated i gt 4 z gt M_min S563 ms f M_min S563 ms M_max S564 ms M_max S564 ms Figure 2 42 Sniff Mode Example A low power application note exists for BTM41x
225. for play back Query information from the TG data base media player such as track details attribute list list folder content Control of player application settings shuffle repeat etc Registration for reception of event notifications Absolute volume control If information of this document appears insufficient we recommend that you refer to the AVRCP1 5 specification document for clarification and more background information This initial implementation has been developed using a phone as TG for testing Some AVRCP1 5 features are not currently supported because they were either not supported by the test phone or could not be tested These include the following Search Add to now playing list Group navigation Battery status changed Note Only the CT role of AVRCP1 5 is supported by this firmware Details of the feature map are listed in Table 2 25 TG role should still be functional for AVRCP1 0 as in earlier versions Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 77 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 5 4 AVRCP1 5 Initialisation Role Configuration At boot time AVRCP functionality is initialised according to S Registers S301 AVRCP role In order to enable functionality of AVRCP1 5 S301 must be set to 3 new default value which corresp
226. fore suspending streaming to save power On streaming suspend audio circuitry is disabled and LEDO should fall back to indicate the connected state 2 8 Hardware Units BTM510 511 This section covers S Registers and AT Commands that are related to hardware units of a BTM510 or BTM511 device For this section refer to the Bluecore data sheet 10 for more detailed information Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 162 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 8 1 Analogue Audio Interface Bluecore BCO5 contains an onboard codec providing analogue input and output capabilities for audio signals The following sections describe details of this onboard codec 2 8 1 1 Onboard Codec Gain Analogue input and output gains Input Amplifier Output Amplifier Figure 2 30 can be set to one of 23 steps called Gain Level To each gain level an overall gain dBr is assigned according to Table 2 68 The overall gain is formed by an analogue and a digital component as outlined in Table 2 68 Gain values can be specified either as gain level or as overall gain by separate S Registers Note that a pair of such S Registers always updates the partner S Register e g S589 S689 and S590 S690 For S689 and S690 the value must be overall gain in dBr multiplied by ten If the i
227. g settings 2 5 6 1 Security Level 320 The security level is defined in the BT2 1 EDR specification 1 vol3 Generic Access Profile Table 5 7 The specification provides four levels of security shown in Table 2 9 Table 2 9 Security Levels MITM protection Man in the Middle attack Level 3 Encryption High security User interaction No MITM protection Level 2 Medium Security Encryption No MITM protection Level 1 No Encryption 1 Low Security Minimal user interaction No MITM protection Level O No Encryption Minimal user interaction 1 Although encryption is not necessary for security level one encryption is always enabled because this specification mandates encryption for all services other than SDP service discovery Permitted only for service discovery Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 21 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module The security level is defined by S Register 320 and is referenced at boot time only Hence the register must be saved by AT amp W and the module must be power cycled or ATZ subsequently S320 3 overrules the setting of S Register 322 enable MITM protection The security level remains the same until next power cycle and is valid for all profiles and services of the module For SDP servic
228. gain eons or SCO SCO 2 Enable input gain restoring for SCO 3 Enable input and output gain restoring for SCO default ae f 0 Disable gain restoring for A2DP nable restoring o last gaihused Tor 5357 0 3 1 Enable Suipul oam ene for A2DP A2DP 2 Enable input gain restoring for A2DP 3 Enable input and output gain restoring for A2DP default Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 cs Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Response Check codec in use ATI26 io MONE EUAFTA 0 None If S333 0 1 SBC 2 APTX 0 Not discoverable not connectable not Check current scanning discoverable connectable status ATI27 1 Discoverable inquiry scanning scan state 2 Connectable page scanning Discoverable and connectable inquiry and page scanning Query A2DP status ATI61 3 0 A2DP not connected 1 A2DP connected and streaming 2 A2DP connected but streaming suspended Query SCO token ATI21 Index of the profile instance owning an active SCO connection 0 None HS HSG HF HFG WM BR WIN SPP_BTA Query last SCO ATI22 For values 0 22 refer to Table 2 68 output gain naa last SCO input ATI23 For values 0 22 refer to Table 2 68 Query last A2D
229. gh commands are not forwarded to the host processor no AVPTI message is sent to the host Respond to lt avrc_response_type gt see incoming Pass AT AVR lt avrc_respo Through command nse_type gt Table 2 31 Target If S 310 1 response from host is not required Suppress AVRCP O AVRCP direction indicator enabled default direction indicator 362 0 1 1 AVRCP direction indicator suppressed Table 2 28 AVRCP Operation IDs for Remote Control Commands Select 0x00 Previous channel 0x32 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 66 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Up 0x01 Sound select 0x33 Down 0x02 Input select 0x34 Left 0x03 Display information 0x35 Right 0x04 Help 0x36 Right up 0x05 Page up 0x37 Right down 0x06 Page down 0x38 Left up 0x07 Power 0x40 Left down 0x08 Volume up 0x41 Root menu 0x09 Volume down 0x42 Setup menu Ox0A Mute 0x43 Contents menu Ox0B Play 0x44 Favourite menu Ox0C Stop 0x45 Exit Ox0D Pause 0x46 0 0x20 Record 0x47 1 0x21 Rewind 0x48 2 0x22 Fast forward 0x49 3 0x23 Eject 0x4A 4 0x24 Forward 0x4B 5 0x25 Backward Ox4C 6 0x26 Angle 0x50 7 0x27 Sub picture 0x51 8 0x28 F1 0x71 9 0x29 F2 0x72 Dot 0x2A F3 0x73
230. gt Response to an AT CNUM request received from HFG 1234567 Phone number in the format specified by ttt The format of the phone number provided Can be one of the following values Values 128 143 The phone number format may be a national or international format and may contain a prefix and or escape digits No change to the number presentation is required Values 144 159 The phone number format is an international number and includes a country code prefix The plus sign is not included as part of the number and is added by the HFG as needed Values 160 175 The phone number is a national number No prefix or escape digits are included HF CNUM 1234567 ttt s itt Indicates the service to which this phone number relates Is either 4 voice or 5 fax HFG has disabled in band ring tone capability BSIR 0 was received on HF BSIR 0 SLC HFG has enabled in band ring tone capability BSIR 1 was received on HF BSIR 1 SLC n 7 HFG has replied with OK to reception of AT CNUM subscriber number HF CNUM OK information query Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 127 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module HF CNUM ERROR HFG has replied with ERROR to reception of AT CNUM subscriber number information q
231. gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 97 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AVPT Player application AVPT lt nAttld gt lt nl gt lt at gt nAttid attribute ID UI8 setting attribute hex see Table 2 44 text nl length of displayable Option name UI8 hex at displayable name S390 bitO 1 Hint strings inserted string of indicated after lt nAttld gt character set non printable characters presented as xx optionally hexadecimal format see 390 AVPE Player application AVPE lt nAttld gt lt nValld gt nAttld attribute ID UI8 setting attribute hex see Table 2 44 value text lt nl gt lt vt gt nValld value ID UI8 hex nl length of displayable name UI8 hex Option vt value text string with 5390 bitO 1 Hint strings inserted 0N Printable characters presented as xx after lt nAttld gt and lt nValld8h gt optionally hexadecimal format see S390 AVAPC Available players AVAPC No parameters changed automatic query of notification available players list if 390 bit 7 0x80 0 message can be supressed by 397 bit 5 0x20 AVSPC Addressed AVSPC lt plid gt lt ucnt gt plid player ID UI16 hex selected player ucnt UID counter UI16 changed hex notification AVN
232. gt immediately affects analogue input or output gain of HS From HSG a remote volume change notification can be sent by AT HSGG command family It is possible to change the remote gains with an absolute value or incrementally Incoming notifications about HS gain changes are displayed by UART message and are also cached internally at HSG The latter allows to query current remote gain settings plus incremental change of the values up down 2 6 8 HFP Hands free Profile The Hands free profile HFP defines how two devices supporting HFP shall interact with each other on a point to point basis The use case for HFP is a hands free unit that is connected wirelessly to an audio gateway The audio gateway is typically a cellular phone The hands free unit acts as audio input and audio output of the cellular phone and allows control of typical telephony functions without access to the phone We recommend the BTM5xx module be controlled by a host processor using AT commands hosted operation mode BTM5xx HFP implementation supports both Hands free role and Audio gateway role An AT command beginning with AT HF indicates affiliation to Hands free role of HFP An AT command beginning with AT HFG indicates affiliation to Audio Gateway role of HFP As of f w version 22 2 5 0 it is not possible any longer to initiate or accept a connection from or to HFP if a link to the sister profile instance HSP already exists Embedded Wireless So
233. guration options described in the BCO5 EXT data sheet 10 chapter 10 page 50 Unfortunately this configuration cannot be accomplished by AT commands Instead use PSKEYs Laird Technologies provides the utility PSUpdate bat which allows certain PSKEYs to be downloaded to a BTM51x module over the UART The PSKEYS that apply for SCO configuration are PSKEY_PCM_CONFIG32 amp 01B3 Note For 12S only PSKEY_PCM_FORMAT amp 01B6 PSKEY_PCM_LOW_JITTER_CONFIG amp 01BA The values for these keys are passed to PsUpdate bat in a psr file For more on downloading PSKEYs over UART see CVC on BTM5xx provided by Laird Technologies under NDA 2 8 2 3 S PDIF Sony Philips Digital Interconnect Format not supported S PDIF is another digital audio interface for high quality stereo audio It is not supported by the current firmware version 22 2 5 0 2 8 2 4 Fixed sampling rate PCM 12S 419 mapping As of firmware v22 2 5 0 for PCM and 12S a fixed sampling rate can be configured This allows an external codec to run at a defined sampling rate regardless of the actually negotiated A2DP rate for example 44 1 kHz or 48 kHz or e SCO air rate With this feature reconfiguring an external codec is no longer required each time depending on the FS message from BTM51x s UART when entering an audio link The fixed sampling rate is achieved by utilising appropriate resampling functions on the internal DSP Fixed sampling rate applies to
234. gured for A2DP source the AAC bit is ignored Multiple optional codecs can be enabled e g S307 3 enables AAC and APTX S register 307 is queried by firmware at boot time For a new setting to become effective you must send AT amp W save SRegs and ATZ reset to the module APTx or AAC must be enabled on both ends of the A2DP link or it falls back to SBC After connection the current codec may be verified by ATI26 2 6 3 17 Discoverable Connectable while A2DP streaming In a scenario where both devices of an A2DP link are discoverable and connectable while streaming audio interrupts in the audio stream are likely to occur Bandwidth which would be required for the A2DP stream seems to be consumed by inquiry scanning discoverable and page scanning connectable processes Therefore the number of slots available for the A2DP link is too low and the audio stream is interrupted One workaround is to make the module neither discoverable nor connectable when in an A2DP connection using AT BTX It has been observed that sometimes only disabling either connectable or discoverable creates an interrupt free audio stream AT commands to achieve this are AT BTQ discoverable only and AT BTG connectable only 308 provides an automatic workaround solution whenever entering an A2DP connection it disables connectable and discoverable mode like AT BTX Whenever exiting an A2DP connection connectable and discoverable states are restored according to t
235. he inversion Flag INV of the GPIO configuration register also applies to AVRCP targets GPIOs which are mapped to an alternative function e g modem control line cannot be used for this purpose Refer to Table 2 83 and section GPIO AVRCP operation ID Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 70 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 5 AVRCP 1 5 Audio Video Remote Control Profile CT role This section contains updated documentation about AVRCP1 5 on the BTM51x 2 6 5 1 AVRCP1 5 AT Command Overview AT AVQ Command family query AVRCP related data parameters items attributes etc Refer to Table 2 32 for more details on query commanas Table 2 32 AVRCP1 5 Query commands AT AVQAP Query list of available media players of connected target TG AT AVQCL Query current play list AT AVQFS Browse virtual file system AT AVQFSN Browse virtual file system next window AT AVQMI Query media item attributes AT AVQNP Query now playing track attributes AT AVQRE Query registered events notification AT AVQRF Query remote device AVRCP features AT AVQXT Query remote device AVRCP extensions profile version metadata AT AVQEC Query remote device AVRCP event capabilities AT AVQSP Query addressed selected player
236. he pairing device To supply a PIN use AT BTK For a successful pairing the link key is stored in a volatile cache which is overwritten every time a new pairing is initiated using this command If S register 325 1 the link key is automatically saved to the non volatile trusted device list Otherwise S325 0 the link key can be added to the trusted device list by AT BTT Refer to AT Commands managing Trusted Devices for further AT commands related to trusted device list The OK response is sent immediately on receipt of the AT BTW command After pairing an unsolicited message is sent to the host in the form PAIR n lt bd_addr gt lt nn gt lt Iktype gt If AT BTI or AT BTP or AT BTG or AT BTQ or ATD is issued between the AT BTW command and the subsequent PAIR asynchronous response then an ERROR response is sent to those commands They cannot be executed in this mode Response lt cr lf gt OK lt cr lf gt 2 5 7 2 AT BTK s lt string gt Set Passkey This command provides a PIN passkey The PIN is stored in non volatile memory for future use If this command is used as response to a PIN 12345678 asynchronous message the PIN provided by this command is not stored in non volatile memory Specifying an empty string deletes the PIN from the non volatile memory The string length must be in the range 0 to 8 or an error is returned Response lt cr lf gt OK lt cr lf gt 25 7 3 Legacy Pairing Asynchronous Messages PIN This re
237. he value of 512 Each action can be enabled disabled in 308 refer to Table 3 1 2 6 3 18 A2DP streaming state When initiating an A2DP link successfully the streaming state is normally entered immediately to transmit audio But there are scenarios where the A2DP link should be retained but streaming should be suspended because the audio resources are temporarily needed for other purposes e g an incoming call over HFP A number of asynchronous messages indicate any change of the A2DP streaming state APSTR APSUS Refer to A2DP Asynchronous messages Query the status of an A2DP connection with ATI61 Refer to Table 3 2 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 49 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 3 19 Simultaneous A2DP and HFP One scenario of particular interest is a headset scenario with A2DP sink enabled for receiving stereo audio and HF unit enabled for receiving making calls The A2DP source and the HFP gateway can be combined in one device e g a mobile phone but they could also be different devices e g an MP3 player as A2DP source and a mobile phone as HFP gateway For the first case we assume that a mobile phone will suspend the A2DP stream before enabling the SCO connection for speech Once the call is finished the mobile phone is expected to initiat
238. his message is printed Current output gain can be queried anytime using AT GO 5 0x20 AVAPC AVSPC Available players changed selected addressed player changed notification On reception of available players changed event or selected addressed player changed event Print relevant message AVAPC or AVSPC to UART 1 Suppress relevant message AVAPC or AVSPC to UART 0 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 83 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 6 0x40 AVPC On reception of player application setting Player application setting changed Changed event notification o Print list of updated attribute value pairs AVPC to UART 1 Suppress AVPC list message 7 0x80 Other AVRCP1 5 notifications On reception of any of the following events AVPPC Playback position changed event AVBS TG battery status changed event AVSS a changed such AVTIE S Track reached end start event AVUC UIDs changed event 0 Print relevant message to UART 1 Suppress relevant message Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 84 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Mu
239. http ews support lairdtech com Americas 1 800 492 2320 173 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 74 S419 SCO A2DP fixed sampling rate SCO audio A2DP sink S419 PCM S315 3 4 12S S315 1 2 12S S314 1 2 0 Disabled Disabled Disabled 1 2 16 kHz 3 5 32 kHz 44 1 kHz 16 kHz 6 44 1 kHz 7 48 kHz 48 kHz If fixed sampling rate feature is disabled S419 0 then no resampling is applied The sampling rate at the digital interface corresponds to the air rate such as 8 16 kHz for SCO or 44 1 48 kHz for A2DP S419 is not only used to configure a fixed sampling rate for SCO or A2DP it also controls the sampling rate for audio loopback mode This loopback mode is intended for testing purposes and is mutual exclusive to SCO and A2DP audio Because of this the context dependent mapping of 419 should not present an issue In audio loopback mode analogue and 125S interface can be configured for a few more sampling rates than the fixed rates available The following table shows the sampling rate mapping of S419 in loopback mode Table 2 75 S419 loopback mode sampling rate Sia Analogue PCM cross LB I2S cross LB AT BTL1 AT BTL7 8 AT BTL3 4 0 8 kHz 8 kHz 8 kHz 1 11 025 kHz 11 025 kHz 2 16 kHz 16 kHz 3 22 05 kHz 22 05 kHz 4 24 kHz 24 kHz 16 kHz 5 32 kHz 32 kHz
240. ication Version 2 1 EDR 1 vol3 Part C Generic Access Profile 8 Extended Inquiry Response Data Format page 1305 in the pdf file The AT command interpreter does not perform any checks on the baseband data format Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 19 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 25 5 2 ATl BTE lt data gt Accumulate data in RAM buffer This command adds lt data gt to the content of the RAM buffer The maximum number of characters for lt data gt is 25 due to the limited AT command input buffer Response lt cr f gt OK lt cr lf gt Or lt cr If gt ERROR 05 lt cr f gt 2 5 5 3 AT BTE lt EIR data gt Write EIR data to baseband and RAM buffer This command writes EIR extended inquiry response data to the baseband and to the RAM buffer The maximum number of characters for lt EIR data gt is 25 due to the limited AT command input buffer See AT BTE lt data gt Accumulate data in RAM buffer for more information Response lt cr lf gt OK lt cr lf gt Or lt cr f gt ERROR 05 lt cr If gt 25 5 4 AT BTE Copy RAM buffer to baseband This command copies all data from the RAM buffer to the baseband The data passed to the baseband must match the EIR data format as specified in the BT2 1 specification page 1305 in the pdf file S See
241. ide Bluetooth Multimedia Module 2 6 8 2 6 Signal call answered at AG to HF 4_4 13 3 AT HFGCA AT HFGCA call answer intelligently performs actions based on one of the following situations If no call is active check with AT HFGC refer to HFG audio routing Signal from HFG to HF that an incoming call has been answered at the HFG On the SLC the indicators ClEV 2 1 call 1 and CIEV 3 0 callsetup 0 are sent to the HF subsequently The status of the incoming call is changed to active If one call is currently active and another is incoming AT HFGCA places the active call on hold and sets the incoming call to active If more than one call is on hold AT HFGCA places the active call on hold and makes the other call active The states of all current calls can be checked by AT HFGC If none of the above conditions is met an ERROR 063 is returned Response lt cr f gt OK lt cr lf gt 2 6 8 2 7 Signal outgoing call status from AG to HF 8_4 18 9_4 19 10_4 20 AT HFGC1 lt number_string gt lt type gt This command shall signal a successful response to a HF initiated call indicated by one of the following asynchronous messages HFG Dnnn dial number lt nnn gt given by HF unit HFG D gt nnn dial from AG memory location nnn HFG L redial last number OK is sent as successful response to the HF s request Signal an outgoing call status by sending CIEV 3 2 callsetup
242. if a lt dev_class gt filter is used Although it is very convenient to have the friendly name displayed in the inquiry response this option can significantly lengthen the inquiry process In areas with a large number of discoverable Bluetooth devices it might become nearly impossible to find a particular device An optimal solution would be a first inquiry scan without friendly name and lt dev_class gt filter In a second run the friendly name is queried by AT BTF lt BdAdar gt for each device found Bit 7 6 5 4 3 2 1 0 Reserved for future usage EIRD RSSI FN COD ADR Default 0 0 0 0 0 0 0 1 Figure 2 1 Register 330 controlling inquiry response format Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 16 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Table 2 8 Field Descriptions for S Register 330 0 ADR Bluetooth device address 1 display Bluetooth device address on inquiry result 0 do not display Bluetooth device address on inquiry result If any further bit is set a comma is inserted as separator 1 COD Class of device 1 display class of device on inquiry result 0 do not display class of device on inquiry result If any further bit is set a comma is inserted as separator 2 FN Friendly name 1 display friendly name
243. igure 2 19 AVRCP Example 1 Player Selection and Receiving Commands Display Setup Bluetooth Manager Bluetooth Security Allow this device to connect Request Device Bluetooth Device Address 00 16 44 00 00 04 Bluetooth Device Name Laird BTMM 000004 Com4 9600 N 8 1 AVDQ Q1E37FA2346 IR QB1E37FA2346 00 ONNECT 01E37FA2346 110E A 0 A P C Figure 2 21 AVRCP Example 1 BTM5xx Preparation and Connection Setup Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 60 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Tax CTS OSR DCO RI RTS DTRIV BRKI CAPTURE J Echo Clear Data Transfer Test COM4 9600 N 8 1 AVPTC 44 1 AT AVC46 OK AVPTC 0 46 AVPTC 46 1 AT NO CARRIER 11 E Figure 2 22 AVRCP Example 1 BTM5xx Sending Commands and Connection Release Bluetooth 4 Manager Bluetooth 4 Manager Bluetooth 4 Manager i Play i pause i Stop Figure 2 23 AVRCP Example 1 Incoming AVRCP commands top right corner of screen 2 6 4 2 AVRCP Control CT and Target TG This section describes AT Commands and S registers which are common to the BTM5xx AVRCP Controller and AVRCP Target roles 2 6 4 2 1 Initiate AVRCP connection AT AVD lt bd_addr gt Initiate AVRCP control connection to Bluetooth address lt bd_a
244. ile None system next block or window Note This command is like AT tAVQFS lt s gt whereby start offset lt s gt is calculated from a previous list so that the subsequent items are requested With this command a host controller is not needed to parse all Parameters Parameters from AVFSL start message If no previous list exists then lt s gt defaults to 0 The end offset lt e gt is always calculated as lt s gt 9 This command allows to cycle through an entire list of items iteratively A reset to lt s gt 0 can be accomplished by AT AVOQFS Response List of folder items See AVFSL AVFSI AVMEI P Table 2 41 Table 2 42 Terminator OK ERROR nnn AT AVQMI Query media item UID 64 bit hex or UidCachelndex UI8 track attributes Parameters 0 9 UID or UidCachelndex is retrieved from a previous folder list AT AVQFS Response Attribute list of item see AVME AVMEA P Table 2 42 Terminator OK ERROR nnn Examples AT AVQMI75E40538A0744A6A UID AT AVQMI2 UidCachelndex AT AVQNP Query now playing Parameters None Macatee R sp nse Now playing track attributes list see AVNPT P AVNPA Table 2 42 Terminator OK ERROR nnn Note This command queries all available attributes usually seven AT AVQRE Query registered Parameters None events for ae P UI16 hex value indicating all events which notification R have been registered with the connected esponse i a target in order to receive event notifications f
245. ility Bit 2 0x04 is supported in the BTM module After setting a new value to this S register the commands AT amp W and ATZ are required for new value to become effective Enable Disable SCO eSCO When changing the unit returns ERROR 014 the device is either in or waiting for a connection The new value cannot be accepted If in a connection drop it and then issue AT BTX and then set the new value If waiting issue AT BTX prior to setting the register 584 2 0 2 n a Value 0 enable SCO 1 enable eSCO 2 for SPP SCO incoming audio request accept requested packet type SCO eSCO 588 0 0 1 n a After a disconnection perform a cold reset 5589 12 0 22 Audie Set output gain level See Gain Table S689 is also affected 5590 12 0 22 eas Set input gain level See Gain Table S690 is also affected 591 0000 0 1ff Set this to 1 to reduce the trusted device database to just 592 0 0 1 n a one record when pairing auto save is enabled via S reg 538 Automatically append last six digits of local Bluetooth Sees Hel We address to the Friendly name set via AT BTN or AT BTF Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 241 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set HFG supported features Bitmask BitO Three way calling Bit 1 Ech
246. immediately after power up of the system When an SLC to a HF device is established the HF can query the HFG s subscriber numbers at any time by sending AT CNUM to the HFG on the SLC The available subscriber number records then transfer to the HF automatically Subscriber number records are stored in volatile memory and are lost on reset or power cycle At maximum 4 subscriber number records are allowed lt number_string gt subscriber number string characters allowed 0123456789 ABDCTP W lt type gt specifies the format of lt number_string gt provided can be one of the following values 128 143 The phone number format may be a national or international format and may contain prefix and or escape digits No changes on the number presentation are required 144 159 The phone number format is an international number including the country code prefix If the plus sign is not included it shall be added by the AG as needed 160 175 National number No prefix nor escape digits included lt service gt service of this subscriber number permitted values 4 voice 5 fax Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 136 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Response lt cr gt lt lf gt OK lt cr gt lt lIf gt command valid record added OR
247. in a non idle state Ov for more than 125 milliseconds Ezurio Terminal provides a BREAK capability which can reset a connected module by ticking and un ticking the BRK field See Figure 2 43 FJ Ezurio Terminal er 6 7 2 CTS DSR OCD AI RTS DTR ioj xj APTURE Echo Clear Data Transfer Test Open COMI5 4000 0 8 1 Figure 2 43 BREAK capability in Ezurio Terminal Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 206 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 9 18 Append Bluetooth Address to Friendly Name If S Reg 593 is set to 1 the last 6 hex digits of the Bluetooth address are automatically appended to the friendly name This differentiates multiple devices with the same name in a neighbourhood 2 9 19 Three Digit Error Responses As of firmware version 18 1 4 0 BTM51x 08 error codes are presented as 3 decimal digits with leading zeroes by default For backward compatibility clear bit 2 0x04 of S559 to use legacy two digit codes In this case ERROR codes gt 100 are presented as ERROR 99 and ATI12 retrieves the actual error code 2 9 20 ATI 54 55 56 status information for all profiles As of firmware v18 1 4 0 ATI commands are added to query status information such as remote Bluetooth device address RSSI receiver signal strength indicator and loca
248. in of HF 18_4 28 AT HFGG Syntax AT HFGG lt I O gt lt n U D gt with Input microphone O Output speaker Query current cached remote gain value Set remote gain value O aed Valid range 0 15 dec U Up Increments of one 1 D Down Increments of one 1 Indicates that a cached gain value is not available This can happen if HS does not support the ERROR 129 So ene remote volume control feature missing notifications Examples AT HFGGOU increment speaker gain of connected HF AT HFGGI query current cached microphone gain of connected HF AT HFGGI13 set microphone gain of connected HF to 13 2 6 8 2 17 Enable disable query wideband speech status AT HFGW lt x gt lt x gt 1 0 As a precondition for this command WBS codec negotiation bit 9 must be enabled in HFG supported features S596 at boot time For AT HFGW query WBS status the status for the local HFG and the remote HF unit is returned WBS is used on an HFP audio link only if enabled on either end for example A response to AT HFGW 1 1 2 6 8 2 18 Query HFP supported features for local HFG and remote HF end AT HFGF Response when HFG connected r n lt AAAA gt lt BBBB gt N nOK r n lt AAAA gt HFG supported features local hexadecimal Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 138 Europe 44 1628 858 940 www
249. in table refer to A2DP Example 1 AT GIU Increment codec input gain by 1 step in gain table refer to A2DP Example 1 Decrement Gain AT GOD Decrement codec output gain by 1 step in gain table refer to A2DP Example 1 AT GID Decrement codec input gain by 1 step in gain table refer to A2DP Example 1 Auto BTX Automatic control of discoverable connect able mode when entering and exiting various profiles Auto BTX 308 0 15 Make the module not discoverable and not connectable when entering a connection Restore discoverable connectable state as defined by S512 when exiting a connection Multi profile policy 00b A2DP only Bits O and 1 apply only for A2DP connections backward compatible 01b Enter auto BTX when ALL profiles of S102 are connected restore to S512 as soon as ONE profile is disconnected 10b Enter auto BTX when ONE profile is connected restore to 512 as soon as ALL profiles are disconnected default 11b Enter auto BTX when ALL profiles of S102 are connected restore 512 as soon as ALL profiles are disconnected Note The S308 default value of 11 makes the BTM51x not discoverable and not connectable after the first profile is connected If more than one incoming connection is expected then S308 must be changed appropriately Also refer to Discoverable Connectable while A2DP Streaming 0 3 2 Embedded Wireless Sol
250. ined by particular currents on the input pin refer to Table 2 80 BTM51x Bias Currents for GPIO inputs Note that an external real pull up pull down resistor can easily override the internal settings depending on its value To see the effects of internal pull up down clearly remove external resistors e g on a development kit Table 2 80 BTM5 1x Bias Currents for GPIO inputs Strong pull up 100 40 10 UA Strong pull down 10 40 100 UA Weak pull up 5 0 1 0 0 2 UA Weak pull down 0 2 1 0 5 0 HA Some GPIOs can have an alternative function assigned If the alternative function is enabled the appropriate O Pin is no longer available as GPIO Modem control functions DCD DSR RI DTR are assigned to GPIO pins as outlined in Table 2 81 This assignment is fixed and configuration settings are read only Hence IO pins of modem control lines cannot be configured as other GPIOs Wi Fi coexistence functions are not used Table 2 81 recommends which pins should be reserved when planning a new product with Wi Fi coexistence support Wi Fi coexistence functions cannot be configured by S Registers Therefore contact Laird if Wi Fi coexistence is required Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 183 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module The following table lists GPIOs and
251. ing occurs it is 538 1 0 1 Pairing automatically saved in the trusted device database if it has room to store it When set to 1 in idle mode S512 1 UART Rx oe el We characters are discarded if DSR is de asserted This sets the power level in dBm when inquiring or S541 20 43 20 n a paging Reading this register returns the value stored in non volatile memory 542 4 43 20 n a As per S541 however reading this register returns the Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 235 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module current power level as set in the base band The read can be different from S541because the actual power is set using a lookup table and the base band rounds down to the nearest value in the table If this is set to 1 then incoming pairing attempts are accepted if a pin code has been pre entered using AT BTK while in the wait phase of auto connect cycle initiated by the AT BTR command In addition to 543 0 0 1 n a accepting pairing attempts if the pairing is successful then the new device is automatically set as the peer address for automatic connections as if an explicit AT BTR command was entered See S Register 505 and 530 also Configure UART for either high throughput or low latency S544 1 0 1 UART Low laten
252. io connection SCO is established Audio on HSG AUO Audio connection SCO has been released Audio off HSG B AT CKPD 200 Button pressed was received from HS 7 i AT VGS nn was received from HS speaker gain Hee wath setting Valid range for nn 00 15 _ P AT VGM n was received from HS microphone gain Be vaN setting Valid range for n 00 15 HSGRX lt data gt Spy messages displaying incoming data on the ACL rfcomm of HSP link HSGUC lt data gt Message displaying unrecognized command data from ACL rfcomm of HSP link NO CARRIER 1112 2 6 7 2 16 AG HSP summary HSG Table 2 55 Audio gateway role HSP Summary of S Registers and AT Commands ACL connection to local AG instance has been released See UUIDs in CONNECT NO CARRIER Messages Enable 0x08 AG role of HSP bitmask HSP AG role ala Must issue AT amp W and atz to activate Initiate SLC Response from AG If successful CONNECT 123456789012 1108 gt hary AT HSGD lt bd_addr gt If failed NO CARRIER If wrong state ERROR 63 If profile disabled ERROR 59 Alert HS by AT HSGC An existing SLC is required RING in band ringing is RING or controlled by 346 Automatic alerting is set using 345 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Ts Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide
253. ion Traditional Profiles Qualifiable gt A2DP adopted version 1 2 Audio Video Remote Control Profile Revision 1 0 22 05 2003 https Awww bluetooth org Technical Specifications adopted htm scroll down to section Traditional Profiles Qualifiable gt AVRCP adopted version 1 0 Headset Profile Revision V12r00 18 12 2008 https Avww bluetooth org Technical Specifications adopted htm scroll down to section Traditional Profiles Qualifiable gt HSP adopted version 1 2 Hands free Profile 1 6 Revision V V16r00 10 052011 https Awww bluetooth org Technical Specifications adopted htm scroll down to section Traditional Profiles Qualifiable gt HFP adopted version 1 6 Serial Port Profile Specification https Awww bluetooth org Technical Specifications adopted htm scroll down to section Traditional Profiles Qualifiable gt SPP adopted version 1 1 Bluetooth Assigned Numbers https Awww bluetooth org Technical AssignedNumbers home htm Most interesting are the links Baseband and Service Discovery Protocol Class of Device Generator this link might be helpful for creating a particular CoD http bluetooth pentest narod ru software bluetooth_class_of_device service_generator html Caution this tool allows selection of more than one minor device classes so make sure that only one minor device class is select and verify the result with 8 Bluecore 5
254. iple after medium AT GOD S411 S412 press Ox0A Volume up multiple after medium press AT GOU 411 S412 Ox0B Headset Button AT HSB Headset profile HS unit Ox0C HF green button AT HFCA accept incoming calls HF unit Ox0D HF red button AT HFC H reject incoming call hang up call HF unit OxOE SSP YES button Equivalent to command AT BTBY positive confirmation of pairing request Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 187 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module OxOF SSP NO button Equivalent to command AT BTBN negative confirmation or cancellation of pairing request 0x10 Cancel inquiry Allows immediate cancellation of a running inquiry by GPIO button 0x11 Enter discoverable connectable state A time window can be set by 371 in seconds Refer to section 2 7 4 7 0x12 Toggle voice recognition activation Equivalent to AT HFVT HF 0x13 Toggle voice recognition activation Equivalent to AT HFGVT HFG 0x14 HF green button with redial Answer incoming call by pressing the button If no call is incoming and the button is pressed then re dial the last number Parameter S389 0 re dial immediately 1 re dial after short button press S411 default 0 4s_ ATI411 2 re dial after medium button press S411 S412 default 2
255. irdtech com Americas 1 800 492 2320 201 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 3 2 MPP Multi profile policy controls in which cases ENTER EXIT operations are carried out MPP 00b caters for backward compatibility i e only A2DP operation is covered Default 10b MPP j bin Cary out FATER OPSrauon wien Carry out EXIT operation when profile s of 102 is are l profile s is are disconnected 3 2 connected 00 Only A2DP Only A2DP 01 ALL ONE 10 ONE ALL 11 ALL ALL Note The new default MPP of 10b makes BTM51x not discoverable not connectable as soon as one profile has connected If more incoming connections are expected S308 must be modified appropriately 2 9 10 3 Sniff Mode Bluetooth connections are master slave in nature A master sends packets and a slave has to acknowledge that packet in the next timeslot Timeslots in Bluetooth are 625 microseconds wide This implies that a master always knows when packets are to be sent and received which further means it is able to optimise power usage by switching on power hungry circuitry only when needed A slave does not have prior knowledge of when a packet is to be received and assumes a packet is scheduled to arrive for each receive slot This means that it must sustain its receiving circuitry for most of the receive slot duration The result is
256. is sent to the host when the unit is in online command mode S Register 531 is set to 3 and data arrives from a peer Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 29 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module If the data from the string contains non visual characters for example ASCII 0 to 31 and ASCII 128 to 255 those characters are translated into a 3 character escape sequence starting with For example the embedded lt cr gt lt lf gt sequence would be sent as the 6 character string OD OA If the data contains the character then it is sent as 22 If the data contains the character then it is sent as 5C 25 9 8 SSO S Registers Table 2 15 lists S registers for SSO profiles Table 2 15 S Registers for SSO profiles S2 94 32 126 Escape sequence character It is not by default due to potential confusion when serial linked to a mobile phone which exposes an AT command set and also uses as default If both use there is confusion 94 is the character 4 12 100 40 5000 Escape sequence guard time in milliseconds with a granularity of 20 ms New values are rounded down to the nearest 20 ms multiple 507 0 0 2 When set to 0 a connection can be dropped using escape sequence only and the state of DSR
257. item track p z met media el type Ul8 item track lt Nag gt lt CS 9 gt lt N1 6 gt lt dn gt hax sek Table 246 na number of attributes i to follow UIS hex Options cs character set UI16 hex 390 nl length of displayable name UI16 hex dn displayable name string of indicated Hint string inserted after lt met gt lt dn gt printed in hexadecimal format character set attributes appended AVMEA in non printable characters subsequent line presented as xx 5391 optionally hexadecimal format see 390 UidCache index n inserted after AVMEI Examples AVMEI D75D439C1A32E511 00 01 006A 0012 Let The Music Play AVMEI 3 D75D439C1A32E511 00 Audio 01 006A 0012 Let The Music Play AVMEA Media element AVMEA lt attid p gt lt CS n gt lt Vl en gt attid attribute ID UI8 hex i see Table 2 43 attribute ay gt browsing 7 cs character set UI16 hex vl length of attribute value UI16 hex Options av attribute value string 390 of indicated character set a non printable characters Hint string inserted after lt attid gt presented as xx format without format see 390 Examples AVMEA 01 Title OO6A 0014 Just The Way You Are AVMEA 01 006A 0014 4A75737420546865205761 7920596F752041 726 5 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 96 Europe 44 1628 858 940 www
258. itional information It can be accessed from the Laird Embedded Wireless Support Site BTIM41x product page under the Documentation tab Table 2 99 Sniff register mapping S 561 564 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 203 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module o 1 0 0 0 95 149 100 160 100 2 3 2 4 2 5 150 249 200 320 200 4 6 5 8 5 250 349 300 480 300 7 8 7 12 7 5 350 449 400 640 400 9 11 10 16 10 450 549 500 800 500 12 13 12 20 12 5 550 649 600 960 600 14 16 15 24 15 650 749 700 1120 700 17 18 17 28 17 5 750 849 800 1280 800 19 24 20 32 20 850 949 900 1440 900 25 34 30 48 30 950 1000 1000 1600 1000 35 44 40 64 40 45 54 50 80 50 55 64 60 96 60 65 74 70 112 70 75 84 80 128 80 85 94 90 144 90 2 9 10 4 Sniff Sub rating SSR Like for sniff mode it is highly recommended to refer to BTM41x low power application note also for SSR Registers related to SSR S348 SSR maximum remote interval The maximum amount of time which the remote device is allowed to be absent in SSR mode in 0 1s Range 0 170 default 0 S349 SSR minimum remote timeout Minimum time with no data exchange in sniff mode before remote devic
259. itly in the ATD command Defines a set of bits masks for enabling profiles Values can be ORed A profile can be enabled only if it is supported by the BTM variant S102 0181 1 1ff n a l l Issue AT amp W and ATZ in order to make the new setting effective 0x001 Serial Port Profile SPP 0x002 Headset HS Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 214 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0x004 reserved 0x008 Audio Gateway Headset HSG 0x010 Hands free FH 0x020 OBEX FTP 0x040 Audio Gateway Hands free HFG 0x080 A2DP 0x100 AVRCP Boot Mode on cold boot Boot modes are required to configure some low level device settings which cannot be configured by S registers and AT commands Currently there are s193 l ie iid predefined settings defining the PCM data format to be used with certain codec ICs applies mainly to BC04 1 Normal 2 4 For future customization of the module Set A2DP role 0 Feature not set 300 1 0 2 A2DP 1 A2DP Sink default 2 A2DP Source Needs subsequent AT amp W and ATZ to become effective Set AVRCP role 0 Disabled 1 Control CT 3 Controller and target enabling AVRCP1 5 CT Default Needs subsequent AT amp W and ATZ to become effective Set
260. l HCI role for connected profiles ATI54 print remote device s Bluetooth addresses of connected profiles Response one line for per profile A hex digits lt BdAddr gt with lt BdAddr gt 12 hex digit Bluetooth device address lt profile_mask Example 0001 0016A40009C8 connection of SPP profile with device B 0080 C09F42934E02 connection of A2DP profile with device C 0100 CO9F42934E02 connection of AVRCP profile with device C If no profile is connected response is O zero ATI55 print RSSI receiver strength indicator for connected profiles Response one line for per profile lt profile_mask gt lt RSSI gt _4 hex_digits with lt RSSI gt signed decimal value of RSSI variable length Example 0001 11 RSSI of device with SPP connection device B 0080 4 RSSI of device with A2DP connection device C 0100 4 RSSI of device with AVRCP connection device C If no profile connected response is O zero ATI56 print local HCI role for connected profiles Response one line for per profile lt profile_mask gt M if master 4 hex_digits lt profile_mask gt S if slave _4_hex_digits Example Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 207 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0
261. l UART RX traffic is discarded in absence of a connection while DSR is asserted If DSR is not asserted then it behaves exactly as per mode 3 When set to 7 It is like 4 but all UART RX traffic is discarded in absence of a connection while DSR is asserted If DSR is not asserted then it behaves exactly as per mode 4 Note By implication a change to this can only be seen after a power cycle AND if AT amp W is sent to the module 514 10 1 60 n a Pairing Timeout in seconds This includes the time a host takes to supply the PIN number when PIN messages are indicated 000000 a FFFFFF 001F00 n a Default Device Class Code When queried the value is always printed as a hexadecimal number To change the device class of the module temporary and immediately without power cycle use the command AT BITC To change the device class of the module permanently write the new value to this S Register ATS515 lt devclass _ gt save the setting AT amp W and hex initiate a power cycle ATZ 5516 ae 5033164 n a 7 Default Device Class filter to be used with AT BTI when it is not explicitly specified When queried the value is Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 232 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module al
262. l headset and wireless speaker use cases 2 7 4 1 Status definition There are many states for the BTM51X module with different characteristics and possible parameters For example the four scanning states not connectable not discoverable discoverable only connectable only discoverable and connectable are mutually exclusive as only one of these states can be entered at a time Other states are characterised by particular parameters e g a profile mask The connected state for instance can be determined for each profile Audio on state can be refined by parameters audio type SCO A2DP or audio direction source sink for A2DP Furthermore there are transitional states such as inquiring pairing connecting ringing etc Hence a huge tree of possible states exists creating the need for simplifications in announcing status indication for ACS As a result only the following states were chosen for indication The four scanning states inquiry oage scanning discoverable connectable Connected any profile AudioOn any audio type direction Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 158 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Rather than specifying a profile the Connected state is regarded as TRUE when any profile is connected The AudioOn state is regarded
263. lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module lt BBBBB gt HF supported features remote hexadecimal Example response r n 026C 009C r nOK n n 2 6 8 2 19 Query support for Voice Recognition Activation on local HFG and remote HF end AT HFGFV Response is based on HFP supported features Response when HFG connected n n lt A gt lt B gt r nOK r n lt A gt Voice recognition act support on HFG local O not supported 1 supported lt B gt Voice recognition act support on HF remote O not supported 1 supported Example response indicating support on either end r n1 1 nOK r n 2 6 8 2 20 Query support for Noise Reduction Echo Cancellation on local HFG and remote HF end AT HFGFN Response is based on HFP supported features Response when HFG connected r n lt A gt lt B gt r nOK r n lt A gt NREC support on HFG local O not supported 1 supported lt B gt NREC support on HF remote O not supported 1 supported Example response indicating support on remote end only ANO 1 nN nOK r n 2 6 8 2 21 HFG audio routing Audio in the Hands free profile is always referred to as a SCO connection used for bidirectional transmission of speech On a BTM5xx SCO audio is routed to the internal codec by default 315 can select the 12S or PCM interface in master or slave mode for SCO connections Refer to Routing audio streams over 12S 2 6 8 2 22 Sen
264. le the appropriate ACR is updated if required e g profile flags On norma disconnect not link loss the ACR is deleted from the table to prevent automatic reconnection Only on link loss does the record remain in the table causing a reconnection when returning back into range Automatic host less mode is enabled by setting Bit 2 of 370 No matter which option is selected for population the ACR table can be queried by ATI72 27 1 1 Auto connect record fields An auto connect record is composed of the following fields BdAddr Bluetooth device address of the remote device ProfileMask Flags for all profiles to connect by this ACR multiple profiles allowed Interval Interval after which an attempt cycle is started if not all profiles are connected yet Status ACR status see ATI72 for definition ProfileMaskConnected Mask where only actually connected profiles are indicated OptionFlags Optional flags see ATI72 for definition Refer to the following sections for AT commands to modify the field values Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 152 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 7 1 2 AT AC Editing ACR scratch record manual mode Before an ACR is added to the ACR table non volatile memory it can be edited in RAM volatile memory in the so
265. le flags set Profile mask as per S102 Table 3 7 S369 0000 0 1FF Misc Configure Auto Connect Service mode Bitmask 370 0 0 7 ACS Bit O Start AC service at boot time Bit 1 Stop AC service by de asserting DSR Auto add new connections to ACR table pita automatic host less ACR mode Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 373 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 371 0 0 900 HLO Time window in seconds for connectable discoverable if entered by FMC 0x11 Granularity 4 If value is lt 60 round up 60 If value is gt 60 round down See Input FMC 0x11 S371 for details 372 0 Misc Control of automatic re pairing if link key missing on remote device but local link key is available O Automatic repairing occurs on connection attempt Automatic repairing is inhibited connection attempt fails 373 0 ACR Default ACR option flags for automatic host less mode bitmask Bit O Always reconnect 0x01 Bit 1 Always send AVRCP play 0x02 Bit 2 Never send AVRCP play 0x04 See 373 default ACR option flags for more detail 374 0 NVM Management of non volatile memory in host less operation bitmask Automatic reset on disconnect if no other profiles ar
266. le is replaced by a wireless SPP link In particular this context refers to TxD and RxD lines not to handshaking or modem control signals A stream of serial data is transmitted typically bidirectional with UARTs involved at both ends In digital I O cable replacement one or more wire s each transmitting a binary signal in one direction is replaced by a wireless link In mixed cable replacement digital I O data and serial data is being transmitted simultaneously This is needed to replace a real world RS232 cable by a wireless link Handshaking signals RTS CTS and modem control signals DSR DTR DCD RI i e O data need to be sent and received at the same time that serial data TxD RxD is being transmitted over the wireless link The RFCOMM specification O basis for SPP caters for this by defining the appropriate procedures In addition it assigns modem control signals to corresponding TS 07 10 Signals RTC RTR IC DV A BTM51x module allows creation of digital O cable replacement in a number of different ways The following sections describe the characteristics of available options 2 9 3 1 Digital Cable Replacement by GPIO FMC In this digital O cable replacement variant a GPIO x is configured as input with the function mapping code FMC Cable Replacement TX 0x00 and the corresponding GPIO x on the peer device is configured as output with FMC Cable Replacement RX 0x00 An SPP connection is required to transmit sta
267. le with version 1 0 All AT commands and messages for AVRCP v1 5 CT are described in the separate section lt AVRCP1 5 gt The AVRCP specification 3 adopts the AV C Digital Interface Command Set AV C command set defined by the 1394 Trade Association device model and control message format In this device model a remote control target consists of one or more subunits At least the subunit PANEL must exist Remote control commands are passed to a subunit with the PASS THROUGH command A BTM device configured as target supports one PANEL subunit Table 2 25 provides an overview on supported AVRCP features on a module Table 2 25 AVRCP Supported Features on BTM5xx 1 Connection establishment for control M Yes O Yes 2 Release connection for control M Yes M Yes 3 Sending UNIT INFO command O Yes X No 4 Receiving UNIT INFO command X No M Yes 5 Sending SUBUNIT INFO command O 1 X No 6 Receiving SUBUNIT INFO command X No M Yes 7 Sending VENDOR DEPENDENT command O No X No 8 Receiving VENDOR DEPENDENT command X No O No 9 Sending PASS THROUGH command M Yes X No 10 Receiving PASS THROUGH command X No M Yes M Mandatory O Optional X Excluded 1 Incomplete 2 6 4 1 AVRCP Example 1 This section illustrates an AVRCP connection between a Laird BTM5xx device as AVRCP Controller and a PC with a built in Bluetooth device and Toshiba Bluetooth Stack 2 1 as AVRCP Target For any other Bluetooth
268. line is ignored When set to 1 a connection can be dropped using EITHER the AA escape sequence OR the DSR modem control line When set to 2 a connection can only dropped by de asserting DSR Mode 2 provides for the highest data transfer rate If the DSR line s status is to be conveyed to the remote device as a low bandwidth signal this register MUST be set to O Otherwise de asserting DSR is seen as a request to drop the Bluetooth connection This register affects S Register 536 see details of 536 531 0 0 4 On SPP connect mode Specifies the mode on SPP connection establishment O Normal Data is exchanged between UART and RF LOCAL_COMMAND UART input is parsed by the AT interpreter and RF data is discarded REMOTE_COMMAND RF input is parsed by the AT 2 interpreter and UART data is discarded If S Reg 536 is not then this register cannot be set to 2 An ERROR is returnec LOCAL_COMMAND UART input is parsed by the AT 3 interpreter Incoming RF data is sent to the host using the RX lt string gt asynchronous response LOCAL_COMMAND On the RF side the GPIO is 4 automatically sent when there is a change in input digital O cable replacement mode 1 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 30 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multi
269. lndex AVFSL OK List s end tag OK Command terminator Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 75 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Command Play item identified by UID gt of previous list or by ATHAVSPE S701 ALE AVS SUID pot i UidCachelndex 1 of AT AVSPI1 previous list Response AVP 0000 Play item success confirmation AVEI ONBO OK Command terminator OK Now playing content Subsequent messages AVNPC changed triggers request as of now playing track event notifications may vary depending attributes if S390 Bit6 0 on TG status List of now playing track l AVNPT attributes triggered by AVNPC Observe AVNPC PUNE 0007 Now playing Track changed notification track change AVTC UID of new track triggers ID request of now playing AVNPT OK Playback status lt UID gt track attributes if S390 AVTC lt UID gt change Bit5 0 AVNPT 0007 List of now playing track AVNPT attributes triggered by AVTC AVNPT OK Playback status changed anai notification new status 01 AVPS 01 Playing AVPS playing Hint string for AVNPT 0007 01 Playing playing status This event triggers a now playing attributes request if S390 AVNPT OK Bit4 0 list of now playing track AVNPT attributes triggered by AVPS Command Observe
270. ltimedia Module 2 6 6 3 Query commands Table 2 39 AVRCP1 5 query commands AT AVQAP Query list of abl di Parameters None available media players of Response a players list See AVPL AVAP Table connected target Terminator OK ERROR nnn TG AT AVQCL Query current play Parameters None list Response Current play list See AVCPL AVMEI Table 2 42 Terminator OK ERROR nnn AT AVQFS Browse virtual file Syntax AT AVQFS lt s gt lt e gt system list items of lt s gt start offset UI16 decimal hex with current path p lt e gt end offset UI16 decimal hex with If no parameters are passed then lt s gt defaults to 0 and lt e gt defaults to lt 9 gt If Parameters only lt s gt is passed then lt e gt lt s gt 9 optional It can happen that actually less items than requested are returned This can be caused by a limited buffer size which is negotiated at beginning of an AVRCP connection AVRCP1 5 spec p 76 last paragraph describes these circumstances List of folder items See AVFSL AVFSI AVMEI Response Table 2 42 Terminator OK ERROR nnn Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 85 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT AVQFSN Browse virtual f
271. lutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 117 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Example if a link to a local HS profile instance exists no more links can be initiated accepted for the local HF profile Or if a link exists to a local HFG instance no more links can be made from to the local HSG instance and vice versa This is caused by the new underlying version of BT stack and library It has not been evaluated whether the feature of earlier f w version can be restored Version 1 6 of the hands free profile are supported Refer to the HFP 1 6 specification for more information 5 Table 2 56 shows the feature requirements for this profile and the level of support on BTM5xx We recommend you download the profile specification 5 in order to understand the procedures related to each AT command For quick navigation references to 5 are given in this section which follow the syntax lt Feature gt _ lt Section gt With lt Feature gt HFP feature no in Table 2 56 and Table 3 1 of 5 lt Section gt Appropriate Section in 5 Exam 3_4 featu ple 12 reno 3 section 4 12 Table 2 56 Hands free Profile supported features on BTM5xx lk Connection management M Yes M Yes 2 Phone status information M Yes M Yes
272. mainly used for BTM51x internal purposes such as rejecting unsupported requests Subsequently to this exchange BTM51x attempts to register as many event capabilities as possible in order to receive relevant notifications from TG The outcome of this can be checked using AT AVQRE which returns flags set for all events that have been successfully registered Typically the TG phone registers for notifications on local BTM51x volume change events In this case the volume change notification is sent each time the local output gain is changed by AT GOU AT GOD etc The phone uses this value for awareness of current output gain setting and also to update its display 2 6 5 6 AVRCP operation Once AVRCP has successfully connected and registered for events typical notification messages are forwarded to UART such as play status changed start pause now playing track changed player settings repeat shuffle etc changed available players and so forth For a number of notifications BTM51x subsequently and automatically queries more data related to the new status such as now playing track attributes Title Artist Album etc and prints it to UART We have observed that in some circumstances multiple events occurring virtually at the same time may cause multiple lists of now playing track attributes for example If this is interfering with a host controller S390 also allows the prevention of automatic queries for a number of notifications
273. mands Managing Trusted Devices There is a range of S Registers defining the behaviour of automatic link key storage on incoming outgoing and dedicated general bonding 2 9 4 1 Dedicated Bonding In BT2 1 specification dedicated bonding is defined as the exchange of link keys between two devices without the intention of establishing a connection immediately Dedicated bonding is initiated by AT BTW lt BdAddr gt initiation of pairing Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 194 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 9 4 2 General Bonding In BT2 1 specification general bonding is defined as the exchange of link keys between two devices with the intention of establishing a connection immediately This is the case if a device tries to connect to another device without existing link key Hence pairing authentication and exchange of link keys is initiated automatically prior to the connection General bonding is initiated by a connection requesting AT command if there is no link key for the peer device existing Such AT commands are AT SPD lt BdAddr gt AT APD lt BdAddr gt AT AVD lt BdAdadr gt AT HSD lt BdAddr gt AT HSGD lt BdAdadr gt AT HFD lt BdAddr gt AT HFGD lt BdAddr gt AT DUD lt BdAddr gt 2 9 4 3 Automatic storage of link keys Four S Registers defin
274. media Module When set to 1 a remote device can capture the AT parser of this unit by sending this module an escape sequence 536 0 0 1 Inter character timing is set via S Register 12 If S Register 507 is gt 2 reading this register always returns O Writing 1 results in ERROR 33 2 5 10 AT Commands for a Selected Peer Device This section describes AT commands to make the BTM Bluetooth device connectable for one specific remote device only or to automatically connect to one particular remote device on reset or power cycle Prior to firmware v18 1 3 9 the AT commands of this section applied to serial port profile SPP only Beginning with v18 1 3 9 including v18 1 4 0 and later these commands apply to all profiles supported by BTM51x 2 5 10 1 AT BTP lt bd_addr gt Make Device Discoverable and Selectively Connectable Make the module discoverable for all devices and connectable for only the device with the Bluetooth address lt bd_addr gt Connection requests from any other devices are rejected If lt bd_addr gt is 000000000000 incoming connections are accepted from any device This is as per AT BTP but without an address The setting is valid until the next reset or power cycle unless not changed by any other AT command subsequently For permanent discoverable connectable settings refer to 512 and AT BTM lt bd_addr gt Response lt cr lf gt OK lt cr lf gt 2 5 10 2 AT BTG lt bd_addr gt Make De
275. mmand ATSxx lt val gt is used with the following extension Separator for tuple values Separator for array elements In order to write three tuples 0 1 2 to dynamic register xx whereby register xx has a defined tuple length of two values the following command would be utilised ATSxx lt val_a0 gt lt val_b0 gt lt val_al gt lt val_bl gt lt val_a2 gt lt val_b2 gt It is also possible to append tuples to an existing dynamic register ATSxx lt val_a3 gt lt val_b3 gt It is also possible to enter a value in hexadecimal format by prefixing with ATSxx reads a dynamic register The response prints one tuple per line tuple values are separated by Tuples themselves array elements are separated by carriage return linefeed lt CRLF gt The response for the above example would look like this ATSXxX gt lt CRLF gt lt val_a0 gt lt val_b0 gt lt CRLF lt val_al gt lt val_b1 gt lt CRLF gt lt val_a2 gt lt val_b2 gt lt CRLF gt lt val_a3 gt lt val_b3 gt lt CRLF gt OK lt CRLF gt In contrast to a classic S register a dynamic register can be empty The response for an empty dynamic register is just OK ATSXX lt 1 lt CRLF gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 157 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia M
276. mmand and unconnected mode This allows changes to the non volatile memory to take effect After the reset is complete and the module is ready to receive commands it issues the OK response ATZ and ATZO initiate a reset followed by loading into the current boot mode see command ATI14 ATZ1 to ATZ4 instructs the module to reset and then emerge into their corresponding boot mode Note that S Register 103 specifies the boot mode from cold Boot modes are required to configure some low level device settings which cannot be configured by S registers and AT commands Currently there are predefined settings defining the PCM data format to be used with certain codec ICs applies mainly to BCO4 Response after reset lt cr If gt OK lt cr f gt 2 5 1 4 AT BTC lt devclass gt Set Device Class Code Temporarily This command sets the device class code which is sent in subsequent inquiry responses It can be read back using the AT BTC Command as described below lt devclass gt is a six digit hexadecimal number derived as per Bluetooth Assigned Numbers 8 The 24 bits are 4 fields briefly described as follows bit O corresponds to the least significant bit Bits 0 1 Format Type This field currently only has a value of 00 i e format type 1 Bits 2 7 Minor Device Class The value of these 6 bits is interpreted differently based on the Major Device Class stored in the next 5 bits Bits 8 12 Major Device Class 5 bits see Figu
277. n SLC AT BTAx is not permitted in current state Occurs if one of HF HFG HS HSG and SPP is 092 connected to one peer device A SCO audio link of HFP HSP has priority over SPP SCO so the BTM51x doesn t accept this command in this scenario 090 091 A2DP not in streaming state or not in A2DP sink role decoder The preconditions for AT APMx are to be in A2DP sink role S300 1 and in a streaming state 094 Command not supported by current A2DP decoder variant 095 DSP plugin doesn t support query mode 096 DSP busy 097 Profile is busy with a current request 099 Real error code is greater than 99 query ATI12 to obtain the detailed error code 100 ACR table not available in RAM 093 ACR a record for the same BdAdadr already exists in persistent store and at least one flag of 19 that record s profile mask overlaps with the profile mask of the scratch record 102 ACR write to persistent store was not successful 103 ACR the history index passed doesn t exist 104 ACR is invalid e g BdAddr 000000000000 or profile mask 0 105 AC service stopped by safety timeout in status attempt 106 ACR table empty AC service not started 107 AC service must be stopped for modification of ACR table Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 253 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610
278. n Sends AT CPKD 200 to the connected if AT HSB pressed HS gateway Disconnect from HS For test purposes only because disconnection AT HSH ATH1108 initiated by HS other than sending ATH AT CKPD 200 to gateway is not defined in HSP specification Send custom data on HS instance ACL Maximum data length 26 characters lt data gt a string of printable ASCII characters or the two digit hexadecimal presentation of a non printable character preceded by AT HSX lt data gt r r must be used to terminate a command or block of data This feature can be used to transmit short data sequences or commands but is not suitable for transmitting large amounts of data Refer to Figure xx Enable ATH for HS Enable HS disconnection ATH1108 and ATH 0 Disabled 1 Enabled default Should only be enabled for test purposes because disconnection initiated by HS other than sending AT CKPD 200 to gateway is not defined in HSP specification 332 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 110 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module SCO audio interface select Select SCO audio 0 Analogue on board audio codec interface BTM5xx Default only ate 1 12S master Catering for PCM 2 12S slave configura
279. n is established the module remains in AT command mode S Register 531 is ignored for HSP connections If S Register 345 1 the audio gateway alerts the headset immediately by sending RING or performing the in band ringing procedure depending on S Register 346 and waits for the response AT CKPD 200 If S Register 345 0 an incoming call must be signalized to the HS manually by issuing AT HSGC This either sends the RING message to the HS or performs the in band ringing procedure and waits for AT CKPD 200 to arrive from the HS If the headset does not respond the host must to terminate the connection by AT HSGH 2 6 7 2 2 Alert HS by sending RING message or in band ringing AT HSGC When in ACL connected state the command AT HSGC alerts the HS either by sending RING if S346 0 or by in band ringing if S346 1 In the latter the AG is assumed to create an in band ringtone which is audible on the HS through the SCO connection The in band ringtone is not created by BTM5xx itself If in band ringing is disabled then BTM5 1x is capable of playing a ringtone locally on incoming RING messages Refer to S388 and AT SIT lt n gt In band ringing is indicated by ATI64 returning 6 If ATI64 returns 5 alerts are indicated with the RING message In both cases the response AT CKDP 200 Button pressed is expected from the HS 2 6 7 2 3 Cancel an ongoing alert process AT HSGCH When the HSG is alerting the HS ATI64 5
280. n monitoring mode parameters are polled from the DSP at regular intervals This allows monitoring of MIPS performance of the decoder Decoder MIPS and MIPS of post processing functions Function MIPS In addition you may monitor signal peaks at four points Another function allows you to set the current mode 2 6 3 22 Post processing modes One out of five modes can be selected by UFE or by AT commands As outlined in Table 2 23 only Modes 1 Pass Thru and 2 Full are sensible to A2DP stereo applications highlighted in table 3 16 However modes 3 and 4 can be utilised for custom post processing algorithms Table 2 23 A2DP decoder post processing modes 0 Stand By Not useful for A2DP stereo application 1 PassThru Stereo post processing disabled default mode for SBC AAC decoder Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 51 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 Full Stereo post processing enabled such as PEQ parametric equalizer Stereo 3D enhancement Compander etc stereo 3 Mono Mono not useful for A2DP stereo application can be replaced by custom post processing algorithms 4 MonoPas Mono not useful for A2DP stereo application can be sThru replaced by custom post processing algorithms 2 6 3 23 AT ACS Query post processing mode AT AP
281. n rejected due to internal error 0085 Operation rejected due to UID changed 0087 Operation rejected due to invalid direction 0088 Operation rejected due to not a directory 0089 Operation rejected due to invalid UID 008A Operation rejected due to invalid scope 008B Operation rejected due to range out of bound 008C Operation rejected due to UID is a directory 008D Operation rejected due to media in use 008E Operation rejected due to now playing list is full 008F Operation rejected due to search not supported 0090 Operation rejected due to search in progress 0091 Operation rejected due to invalid player ID Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 104 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0092 Operation rejected due to player not browseable 0093 Operation rejected due to player not addressed 0094 Operation rejected due to no valid search results 0095 Operation rejected due to no available players 0096 Operation rejected due to addressed player changed Table 2 51 AVRCP1 5 supported features CT only 1 Connection establishment for control M Yes 2 Release connection for control M Yes 3 Connection establishment for browsing C6 Yes Background operation 4 Release connection for browsing C6
282. naa e e ly sated baat EE EE eee ENT 7 DA HMMOOU GU OM se icct acs scte tere e eee eaa veces teste a tener a a Maes iam atetene a tian sats 7 22 Glossary Of Trims serrera Aena AE teil teats E EAE R EREE dea aii 7 2 3 Overview of the BTM Product Family ss assenssissnisseisstiereististisstinttisrtattinrtrnrtrertinnrnnrrnrrnrre nnn 8 24 BIM AT Command SOE x esescec2e spnceg neniesan ia a A a e ai iiaae 9 24T ASSUIMAD TONS nee iaaea a adana a E E a aa aia 9 2 4 2 Command SYntaX sses rnn den n aan a a Eia ERE ROET AE E 9 25 M d l Configuratio Nesnenin anaa a r a a i E ERa 10 25 1 G n ral AT COMIMANGS senisest paseis ninan a ea aaa aaa aE cals RE ERRE a 10 2 5 2 AT Commands for S ReQiSters ccccccececeeceeeeeceeeeeeeeeeeeceeeeceeeeseeeceeseeeesteeeeneeeeteeeeaees 13 2 5 3 General S REJIS Sonini E E eA E AE AA 15 2 54 AT Commands for MAUI yisi aaae AEE EEEN REE ENEN EAEE E Ea 16 2 5 5 AT Commands for Extended Inquiry Response Data 0 0 cccceccseeeseeeeeeeeeeeeteeeneeenees 18 2 56 Secure Simple Pairing SSP riren iaaea oa a iaa 21 2 5 7 AT Commands for Legacy Pairing cccccccececeeceeeeeeeeceeeeceeeeceeeceeeseeeseeeeenseeeneeeenees 25 2 5 8 AT Commands Managing Trusted Devices 00ccccecceceeeeeeeeceeeeeneeeeeteeeeeeceeeeeeneeeeenaes 26 2 5 9 AT Commands for Serial Stream Oriented Profiles SSO cccccecceeessesessesseeeeeeeeeeeeeeeeees 27 2 5 10 AT Commands for a Selected Peer Device c
283. nd ringing In this case the tone selected by 388 gt 0 is played Note GPIO function mapping code FMC AudioOn 0x05 is currently not working for tones See the Release Notes Known Issues for more information If AT SIT lt n gt is issued during an active A2DP or SCO link with audio routed to I2S or PCM interface then the tone is played back to the active audio interface In all other cases the tone is played back to the analogue audio output For A2DP sink with 2S interface at fixed rate of 48kHz S419 7 a strange sound of some ring tones was observed It is suspected that this is caused by the internal resampling process 2 9 26 Tolerant pairing policy Android compatibility It has been observed that during initial pairing Android devices require an authenticated link key MITM protection If BTM51x I O capabilities are set to no input no output 32 1 3 then a confirmation of the 6 digit passkey is not possible and hence the pairing is rejected by BTM51x In other words a link key is not created because combined I O capabilities of Android device and BTM51x are insufficient to create an authenticated link key Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 542 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module It has further been observed that for the actual connection to a
284. nds The following table lists all ATIn parameters supported by the modules ATI commands provide general information about the modules and status information Table 3 2 BTM ATI Commands ATIO The product name variant ATI1 The CSR firmware build number ATI2 The AT firmware build number For internal use only ATI3 The AT firmware revision ATl4 A 12 digit hexadecimal number corresponding to the Bluetooth address of the module ATI5 The manufacturer of this device ATI6 The maximum size of trusted device database ATI7 The manufacturer of the Bluetooth chipset ATI8 The chipset format ATI9 SPP connection status O Not connected 1 Connected in local command mode 2 Connected in remote command mode ATI11 The reason why a NO CARRIER resulted in the most recent attempt at making an outgoing connection The response values are as follows O No prior connection Connection timeout 2 Connection attempt cancelled 3 Normal disconnection 4 Peer device has refused connection 5 Service profile lt uuid gt requested not available on remote device 6 Connection has failed 32 ATH was entered 33 Incoming connection aborted because of too many rings 34 Unexpected incoming connection 35 Invalid address 36 DSR is not asserted 37 Call limit of 65531 connections has been reached 38 Pairing in progress 39 No
285. ng Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module With the assumptions above Major Device class Audio Video Table 8 in 8 gives the complete list of codes for the minor device class If you are not sure about the minor device class use the row marked with n a for the minor device e g 0x040400 for sink or 0x080400 for source Table 2 22 provides examples of device class codes for A2DP devices Table 2 22 A2DP device class code examples 0x040400 Rendering Audio Video n a Sink 0x040414 Rendering Audio Video Loudspeaker Sink 0x040418 Rendering Audio Video Headphones Sink 0x04041C Rendering Audio Video Portable Audio Sink 0x040420 Rendering Audio Video Car audio Sink 0x080400 Capturing Audio Video n a Source 0x080410 Capturing Audio Video Microphone Source 0x080428 Capturing Audio Video Hi Fi Audio Device Source 1 the rendering flag Ox040000 is mandatory for an A2DP SNK 2 the capturing flag Ox080000 is mandatory for an A2DP SRC 3 Audio Video major device class Ox000400 is recommended for an A2DP device Refer to A2DP 1 2 specification section 5 5 1 2 The device class is written to the module using ATS515 lt device_class gt where lt device_class gt is the 6 character device class code without leading Ox Use subsequent AT amp W and ATZ to commit the new value Also refer to AT
286. nit_id gt lt unit_type gt lt company_id gt Successful if lt n gt 0 Send a Subunit Info Response on command completion request Control Aree AVSR lt n gt lt page gt lt pagedata gt lt cr f gt incomplete Successful if lt n gt 0 Only the first word of the pagedata is being displayed in the AVSR response message Set Company Id Target 303 0 OXFFFFFF IEEE Company ID 24bit hexadecimal Required for UNIT INFO Response in AVRCP target mode default value is OxFFFFFF Enable Unit Info Response Target O Reject incoming Unit Info Requests Accept incoming Unit Info Requests and send 305 0 1 el 1 response automatically default with Company ID as per 303 and unit type 0x09 Panel fixed Enable Subunit Info O Reject incoming Subunit Info Requests Response Accept incoming Subunit Info Requests and send Target 306 0 1 q response automatically default with Subunit type 0x09 Panel fixed and MaxSubUnitld 0x00 fixed Configure PASS 0 Host is required to respond to PT Indication see THROUGH PT 5310 0 1 AT AVR Response i 1 Enable automatic PT response response type is Target read from 311 default Set automatic PT This value is queried for automatic PT Response see response type Target Table 2 31 5311 0 7 Default value is accepted ay 9r Note If this value is set to reject 2w 10r then incoming Pass Throu
287. nltems gt or Start Tag lt nitems gt lt nitems gt AVPC lt nltems gt AVAPI AVMEL AVFSI or AVNPA AVPV or Item Tag AVMEI AVPA OF AVPR AVAPL OK or AVCPL OK or AVFSL OK or AVNPT OK or AVPL OK or End Tag AVAPL ERROR AVCPL AVFSL AVNPT ERROR AVPL ERROR or ERROR ERROR AVPC OK Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 93 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 6 6 AVRCP1 5 message syntax Table 2 42 AVRCP1 5 message syntax AVAPL Available players list start end AVAPL lt nitems gt 16h start tag nitems number of items to follow UI16 hex AVAPL OK end tag success AVAPL ERROR lt asc gt 16h end tag error asc avrcp status code UI16 hex AVCPL Current play list start end AVCPL lt nltems gt start tag nitems number of items to follow UI16 hex AVCPL OK end tag success AVCPL ERROR lt asc gt 16h end tag error asc avrcp status code UI16 hex AVFSL File system list start end AVFSL lt nItems gt lt nStartOffs gt lt nEndOffs gt lt nTotalltems gt start tag nitems number of items to follow UI16 hex nStartOffs index of first item UI32 hex nEndOffs index of last item UI32 hex nTotalltems total number o
288. nnection Q None 1 HS 2 HSG 3 HF 4 HFG 5 SPP_BTA ATI22 Last SCO output gain ATI23 Last SCO input gain ATI24 Last A2DP output gain ATI25 Last A2DP input gain Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 245 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module ATI26 Display current A2DP decoder info if 333 1 lt CodecTypeString gt lt Sysldhex gt lt BuildNohex gt lt PostProcFriendlyName gt lt SdkName gt CodecTypeString SBC AAC APTX Sysld BuildNo 4 hex digits Example SBC E006 0101 Music ADK2 0 When A2DP is connected but not streaming the extended data is not available Only the CodecTypeString e g SBC is printed in this case If S333 0 only the ID of current decoder type is printed Q None 1 SBC 2 APTX 3 AAC ATI27 Current scan state O0 Not discoverable and not discoverable not scanning 1 Discoverable inquiry scanning 2 Connectable page scanning 3 Discoverable and connectable inquiry and page scanning ATI28 Current audio sampling rate for input and output in Hz ATI29 Maximum EIR data size in bytes ATI30 RAM buffer length in bytes ATI31 Length of EIR baseband buffer ATI32 Query CVC license key ATI35 Compact list of available CVC images Appended variant flags should always be
289. nnections only HF profile AT amp F AT amp F Restore factory default settings ATS102 10 ATS102 40 Enable profiles HF for DevA HFG for DevB Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 176 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module ATS315 3 Configure PCM master for SCO on DevA ATS419 2 Configure fixed sampling rate for SCO 16 kHz ATS512 4 Make discoverable and connectable at boot time AT amp W AT amp W Save settings ATZ ATZ Reset ATI4 Query BdAddr of device A AT HFGD lt BdAddrA Initiate connection from device B AT HFA Initiate audio from device A AT HFR Release audio from device A AT HFGWO Disable WBS on device B next SCO is narrow band 8 kHz AT HFA Initiate audio from device A AT HFH Release audio and SLC from device A We use two BTM51x which are configured as HF device A and HFG device B helper device After configuration according to the above table we initiate the connection from device B On the first AT HFA we see the following FS message FS16000 PCM M 16000 meaning that this is a WBS eSCO link FS16000 which is routed to PCM master role at 16kHZ 76000 Although in this case sampling rate conversion is not required virtual air rate is identical to PCM rate the second 76000 still indicates
290. nput value doesn t match a gain table entry the nearest possible value is set The actual value can be checked by reading S689 S690 The value of S689 S690 is printed out multiplied by ten to avoid non integer numbers The command class AT G enables incremental and decremental gain settings The increment decrement command corresponds to one row up down in the gain table Table 2 68 The Gain level registers S589 S689 and S590 S690 are not affected by increment decrement commands Instead the current gain level is cached and can be retrieved by AT G I O There are two further commands to restore the cached gain level from S 589 S590 They are AT G I O R and AT G I O S The latter saves the currently cached gain level to 589 S590 Output Amplifier O Digital Circuitry Output Amplifier D Figure 2 30 BTM5 1x Stereo Audio Codec Block Diagram Table 2 68 BTM51x Gain Table 22 21 5 7 7 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 J g Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module O NIWY BR oO nD N o 18 0 15 5 12 0 9 5 6 0 3 5 0 3 0 6 0 9 0 12 0 15 0 18 0 21 0 23 5 27 0 29 5 33 0 35 5 39 0 41 5 45 0 S NIU AJA Orolo rolko 15 14 13 12 11 10 Table 2 69 BTM5 1x Gain Settings AT commands and S R
291. ns of automatic reset controlled by flags of 374 Bit O Automatic reset on disconnect if no more profile is connected and if NVQ lt 300 This is preventive but the conditions may not be met before ERROR 102 occurs Bit 1 Immediate reset on ERROR 102 This is a robust recovery method but it may lose existing connections Combining both flags S374 3 seems ideal but it is up to the user to select the best solution for the application 2 9 22 AT SR lt role gt lt pm gt Setting HCI role master slave Usually the Bluetooth device which initiates a connection becomes master of the link and the accepting device becomes slave Some devices initiate a role change swapping master and slave role once a connection is established This is observed when initiating an SPP link from BTM51x to a PC Windows 7 reading back the local HCI role ATI56 has indicated slave for SPP Normally the application doesn t need to address the HCI role However in some cases changing HCI role can resolve issues Such a scenario is an A2DP AVRCP connection initiated by BTM51x to an iPhone with AAC enabled If BTM51x remains master regular drops in the audio stream are observed After requesting slave role for BTM51x the issue is solved The following AT command allows control of HCI role AT SR lt role gt lt profile_mask gt request local HCI role for one given profile lt role gt M for master S for slave Example AT S
292. nse lt cr f gt O000000000000 lt cr lf gt OK lt cr lf gt AT BTR lt bd_addr gt Set Outgoing Peer Address for SPP legacy SPP auto connect This command stores a peer address for outbound SPP connections in non volatile memory This command sets up a module in pure cable replacement mode If S512 1 and the peer address is NOT 000000000000 then it periodically time specified via S505 attempts to connect to the specified peer address All data from the host are then buffered in the receive buffer until a Bluetooth connects and then sends the buffer across This means if the peer device is not and will not be available and S507 1 or 2 the module effectively becomes useless and does not listen for commands arriving on the UART If this happens two recovery methods are available The first assumes that the DTR from the host is connected to the DSR line of the module and 507 1 The second assumes that this connection is absent and 507 1 or 2 In the first method deasserting the DTR line from the host aborts the autoconnect cycle No OK is sent in response The host must send a character regularly e g one per second until the module echoes all buffered characters to the host provided echo is enabled signifying it is in command mode Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 Ey Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610
293. nsuccessful responses are lt cr If gt AVUR 1 lt cr lf gt or lt cr lf gt AVUR 4 lt cr If gt gt and lt company_id gt is not sent hex hex 2 6 4 3 2 Send SUBUNIT INFO Request incomplete AT AVS lt page gt Send a Subunit Info request to a connected AVRCP target Response lt cr lf gt OK lt cr lf gt immediately And lt cr If gt AVSR lt n gt lt page gt lt pagedata gt lt cr lf gt after command completion dec hex lt n gt status O success 1 fail 4 timeout lt page gt requested page 0 31 lt pagedata ex 1 word of requested page If lt n gt is greater than zero unsuccessful outcome lt page for unsuccessful response are lt cr If gt AVSR 1 lt cr lf gt or lt cr f gt AVSR 4 lt cr lf gt gt and lt pagedata gt is not sent Examples dec hex incomplete because only the first word of the requested page is being displayed in the AVSR asynchronous message 2 6 4 3 3 Send remote control command AT AVC lt operation_id gt lt button_state gt hex Send a remote control command to a connected AVRCP target Internally a PASS THROUGH command is created and sent to the PANEL subunit of the AVRCP target lt operation_id gt is the value for the remote control command Values are specified in Table 2 27 hex Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 62 Europe 44 1628 858 9
294. nternal codec in terms of analogue to digital conversion or digital to analogue conversion of an audio stream Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 48 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module and decode an audio stream Due to this SBC is not ideal for applications that require synchronised audio e g wireless headphones for TV However there are optional codecs to overcome this limitation of SBC such as APTx APTx claims low latency and much better audio transparency than SBC This may of course be evaluated by measurements but the judgment is ultimately subjective and up to the listener Another optional codec is AAC AAC is implemented for an A2DP sink only decoder It has the preferred codec for the iPhone An optional codec must be supported by both ends of an A2DP link At the beginning of each A2DP link a negotiation takes place In the result of this negotiation both devices agree on the codec and the sampling rate to be used for the time of the connection If no optional codec matches on both ends SBC is used Multiple optional codecs can be enabled 2 6 3 16 Enabling optional codecs APTX AAC 307 S307 enables optional codecs Bit O val 1 enables APTX source or sink and bit 1 val 2 enables AAC sink only If AAC is enabled but the module is confi
295. o be sufficient for voice links Table 2 52 lists the feature requirements of the HSP specification 4 and the level of support by BTM5xx Version 1 2 of the Headset Profile specification is supported In most cases it is preferable to use the more advanced Hands Free Profile HFP HSP defines the role of the headset HS and the role of the audio gateway AG which are both supported on BTM5xx They are enabled by setting the appropriate flag in S Register 102 plus subsequent AT amp W and atz An HSP connection has two states ACL connected or audio connected The ACL is initiated by either HS or AG The audio connection a SCO link is always initiated and released by the AG A host processor is required using AT commands to control the BTM5xx module hosted operation mode An AT command beginning with AT HS indicates affiliation to the Headset role of HSP An AT command beginning with AT HSG indicates affiliation to the Audio Gateway role of HSP As of f w version 22 2 5 0 it is not possible any longer to initiate or accept a connection from or to HSP if a link to the sister profile instance HFP already exists Example if a link to a local HS profile instance exists no more links can be initiated accepted for the local HF profile Or if a link exists to a local HFG instance no more links can be made from to the local HSG instance and vice versa This is caused by the new underlying version of BT stack and library It h
296. o cancellation and or noise reduction function Bit 2 Voice recognition function Bit 3 In band ring tone capability Bit 4 Attach a number to voice tag Bit 5 Ability to reject call Bit 6 Enhanced call status Bit 7 Enhanced call control Bit 8 Extended Error Result codes HFP 596 0x026C 0 3FF HFG Default value Codec negotiation 0x200 Enhanced call status 0x40 Incoming call reject 0x20 In band ring 0x08 Voice recognition 0x04 Note Bit 0 Bit 4 of these settings are advertised in the Service Record of the HFG The default value is 0x68 Bit 3 Bit 5 and Bit 6 set After setting a new value the commands AT amp W and ATZ are required for the new value to become effective Ensure Bit 6 is always set This is mandatory for HFP1 5 AG GPIO pin state mask S650 0 0 1 GPIO 0 No mask enable configuration bit fields 1 Enable I O pin state Mask disable configuration bit fields S651 GPIO1 S652 GPIO2 S653 GPIO3 GPIO Configuration Register S650 must be set to 0 to enable configuration access sea openoing on GPIO4 oe alternative 0 ffff Controls pin state pin direction pin inversion GPIO usage BTM51x notification enable function mapping select and S655 at GPIO5 a and wiring function mapping code av_operation_id S656 GPIO6 See Table 2 82 S657 GPIO7 one GPIO8 Embedded Wireless Solutions Support Center http ews suppo
297. ode If automatic mode is enabled Bit2 of 370 is set new records are automatically created and inserted at top of the ACR table All field values of the new ACR are retrieved from the new connection except reconnect interval and option flags The default reconnect interval is fixed to 5s and option flags are copied from 373 27 1 6 5373 default ACR option flags These flags populate the ACR option field when the auto add flag is enabled in 370 Range 0 7 Bit 0 always re connect 0x01 Bit 1 always send AVRCP play 0x02 Bit 2 never send AVRCP play 0x04 f neither Bit1 nor Bit2 is set AVRCP play is sent intelligently on auto reconnect depending on certain conditions AVRCP version 1 0 doesn t support updating the play status at the controller end Therefore sending AVRCP play may be unexpected in some cases This feature is experimental and can be disabled by setting Bit2 2 7 2 Auto Connect Service ACS Auto connects service is a prerequisite for the auto connect feature Auto connect service ACS is an entity in firmware which caters to required actions such as initiating attempt cycles monitoring connect disconnect events updating the ACR table and more ACS can be started by AT command AT ACS1 or at boot time by setting BitO of 370 There are preconditions which must be met before ACS may start Not discoverable not connectable Embedded Wireless Solutions Support Laird Center
298. odule OK lt CRLF gt 2 7 3 2 Dynamic register versus classic S register The table below compares significant differences between dynamic and classic S registers Table 2 64 Dynamic S Registers vs Classic S Registers Register number range 744 808 0 743 Storage to persistent Automatically whenever written Command AT amp W memory Delete or restore default ATSxx deletes all tuples of the specified AT amp F deletes all tuples of all value dynamic register dynamic registers and reverts AT amp F deletes all tuples of all dynamic all classic S registers to registers and reverts all S registers to factory default factory default value Maximum array length Maximum number of tuples 31 or limited n a by persistent store Response to ATSxx Sxx lt range val_a gt lt range _val_b gt Sxx lt range_val gt query range Example Example S744 1 18 0 10 5122 0 7 2 7 4 Status Indication Status indication means the automatic indication of module states by suitable indicators Currently firmware v18 1 4 0 the LEDs of BTM51x are supported as indicators A number of LED blink patterns exist LED blink patterns can be tested by AT SILO lt PatternID gt for LEDO and AT SIL1 lt PatternID gt for LED1 Blink pattern IDs are listed in Table 3 5 For AudioOn status indication is also possible by a GPIO output refer to section 16 4 Motivation for status indication is to achieve host less operation for typica
299. oming dialling alerting audio 2 6 8 2 Audio gateway role AG HFP HFG Audio gateway role is activated by setting flag 0x40 in S102 plus AT amp W plus atz Refer to Figure 2 25 Audio Gateway block diagram for a block diagram of an audio gateway with a BTM5xx in hosted operation mode Table 2 56 shows the feature requirements for this profile and the support level on BTM5xx Laird highly recommends you download the profile specification 5 order to understand the procedures related to specific AT commands For quick navigation references to 5 are given in this section with the syntax lt Feature gt _ lt Section gt With lt Feature gt HFP feature no in Table 2 56 and Table 3 1 of 5 lt Section gt Appropriate Section in 5 Example 3_4 12 feature no 3 section 4 12 Many of the HFG commands refer to call states These can be queried by AT HFGC A description can be found in HFG audio routing 2 6 8 2 1 Initiate service level connection SLC from AG 1_ 4 2 AT HFGD lt bd_addr gt Initiate service level connection from local audio gateway instance to device with lt bd_addr remote device must support the Hands free role HF of the Hands free profile HFP gt The hex Response SLC established lt cr If gt CONNECT 123456789012 111E gt lt cr If gt Failed lt cr f gt NO CARRIER lt cr f gt Or lt cr If gt ERROR 59 lt cr lf gt Or lt cr If gt ERROR 63 lt cr lf gt
300. on period by polling the NVQ value regularly This should give an idea on the persistent store consumption of an application Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 208 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Persistent memory is automatically defragmented on a reset if the NVQ value is less than 300 Although this seems to work well an additional AT NVF is always recommended before a reset for the purpose of defragmentation as a precaution To prevent write operation errors e g ERROR 011 or ERROR 102 Laird recommends you first analyse the persistent store consumption of the application If in the course of the application it is likely that no reset will occur over long time and that the NVQ value will decrement down to a critical level then the host controller should foresee flooding AT NVF and reset ATZ in situations where it doesn t interfere e g no connection and when the NVQ value is getting too low 2 9 21 5 5374 Host less operation In a hostless operation scenario no host controller is available which can monitor the NVQ value and reset the module if needed In addition with automatic ACR mode persistent store consumption depends largely on the number of connections to different devices and is difficult to predict For this scenario BTM51x provides two optio
301. onds to target and controller role The only target functionality required here is to receive volume change commands from the remote device phone When volume is changed at the phone then the relevant message causes the BTM51x s audio output gain to be set accordingly providing an A2DP link exists with the same device and the BTM51x is audio sink This is the only scenario where the phone acts as CT and BTM51x is acting as TG Given that in all other scenarios BTM51x is acting as CT and a phone is acting as TG the volume case is neglected when stating that only AVRCP1 5 CT role is supported In addition for the volume case to be functional BTM51x TG features are set to category 2 internally which is hardcoded We observed during development that 302 must be set to 1 category 1 If S301 3 target and controller then S302 value stands for CT functionality If S302 has a different value while S301 3 then features may not work as described or not work at all Category 1 is the focused upon use case for this release The new default values for S301 3 and 302 1 reflect these findings 2 6 5 5 AVRCP connection setup When the BTM51x connects to a remote TG device by AVRCP1 5 information is exchanged in the background between TG and CT For example AVRCP features profile extensions beyond AVRCP1 0 and event capabilities These TG characteristics are buffered in BTM51x and can be queried using AT AVQRF AT AVQXT AT AVQEC These are
302. onnected but not streaming suspended ATI62 AVRCP connection status 0 not connected 1 connected ATI63 HSP Headset connection status O not connected 1 ACL connected 2 audio connected ATI64 HSP Gateway connection status O not connected 1 ACL connected 2 audio connected ATI65 HF connection status O Not connected 1 SLC connected 2 Audio connected 3 In call SLC 4 In call audio 5 In call setup incoming dialling alerting SLC 6 In call setup incoming dialling alerting audio ATI66 HFG connection status O Not connected 1 SLC connected 2 Audio connected 3 incall SLC 4 incall audio 5 In call setup incoming dialling alerting SLC 6 In call setup incoming dialling alerting audio 8 In call but not SLC Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 248 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module ATI72 Table of Auto Connect Records persistent store Syntax is as follows lt index gt lt BdAddr gt lt pm gt lt interval gt lt state gt lt pm_cnct gt lt flags gt With lt index gt Index of the entry starting with 1 lt BdAddr gt Bluetooth device address of remote device lt pm gt Profile mask as per 102 four hexadecimal characte
303. ontroller no messages concerning browsing channels are sent to UART Media content on the target is structured in a tree oriented virtual file system BTM51x provides AT commands to change the current path and to list items in the current path folder When listing folder items AT AVQFS the number of items being returned may be limited by AVRCP packet size This means that only a partial window of the entire folder list is returned by one command Because of this a start offset parameter lt s gt can be appended to AT AVQFS lt s gt it must be less than or equal to the total number of items in the current folder If omitted then lt s gt defaults to zero meaning that the list is returned from top first item The total number of items is indicated in the change path folder confirmation AVFC lt nltems gt and also in the start tag of a file system list AVFSL lt nItems gt lt nStartOffs gt lt nEndOffs gt lt nTotalltems gt AT AVQFSN N next permits it to list the next window of folder items by calculating the following start offset dynamically from the last printed list start_offset nltems actually returned Hence multiple calls of AVQFSN print all chunks of an item list without having to manage start offsets for each window by the host controller Table 2 35 provides an overview of AT commands for navigating the virtual file system More detail about each command can be found in Table 2 39 and Table 2 40 Table 2 35 Stan
304. ooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Note AT BTM lt BdAddr gt only makes sense if also ATS512 3 4 6 or 7 plus AT amp W and ATZ is set If the BTM51x is not discoverable and not connectable at boot time ATS512 1 then AT BTP or AT BTG would clear the current incoming peer address Response lt cr lf gt OK lt cr If gt 2 5 10 4 AT BTM Delete Incoming Peer Address non vol mem This command deletes the peer address previously stored using AT BTM lt bd_adar gt If the module is connectable for the selected device before this command it is connectable for any device afterward Response lt cr lf gt OK lt cr If gt 2 5 10 5 AT BTM Read Incoming Peer Address non vol mem This command displays the peer address stored in non volatile memory placing the module in pure cable replacement mode Response lt cr lf gt 123456789012 lt cr lf gt OK lt cr lf gt If the location is empty the response is as follows Response lt cr lf gt 00000000000 lt cr lf gt OK lt cr f gt 2 5 10 6 ATI75 Read Current Incoming Peer Address 2 5 10 7 ATI75 displays the currently valid incoming peer address It may originate from non volatile memory at boot time AT BTM lt bd_addr gt 512 gt 3 or be set by AT BTG P lt bd_addr gt Response lt cr lf gt 123456789012 lt cr lf gt OK lt cr lf gt If no incoming peer address is currently set the response is as follows Respo
305. or 000002 863611 reject by AT BTBN to deny a match PASSKEY lt BdAddr gt lt friendlyname gt Passkey request Prompts the user to enter the Example passkey displayed by the remote device Use PASSKEY 0016A4000001 Laird BTM AT BTB lt passkey gt 000001 example AT BTB0O12345 see 1 below PAIR N lt BdAddr gt lt friendlyname gt lt Passkey gt Passkey notification Display BdAddr friendly Example name and passkey to user Prompts the user to PASSKEY N 0016A4000002 Laird BTM enter the passkey from this message at the 000002 164585 remote device s numeric keyboard PAIR O lt BdAddr gt lt nn gt lt Iktype gt Successfully paired with device of lt BdAddr gt lt nn gt optional indicates the status of automatic storage to trusted device list Value O success Settings are controlled by S325 to 328 Refer to Automatic storage of link keys lt lktype gt indicates the link key type 0 no link key 1 legacy link key BT2 0 and earlier 2 debug link key should never occur in practice 3 unauthenticated link key no protection against MITM attack 4 authenticated link key protection against MITM attack 5 link key changed In practice only values of 1 3 4 should play a role PAIR 1 lt BdAddr gt Pairing timeout see 2 PAIR 2 lt BdAddr gt Pairing failed see 2 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 2
306. ored for HFP connections 2 6 8 1 2 Initiate audio connection from HF 3_ 4 11 AT HFA Initiates audio connection from local Hands free instance An existing service level connection is required Response Audio on lt cr f gt HF AU1 lt cr If gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 120 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 8 1 3 Release audio connection from HF 3_ 4 12 AT HFR Releases audio connection only The service level connection is retained Response Audio on lt cr f gt HF AUO lt cr If gt 2 6 8 1 4 Release entire connection from HF 1_4 3 AT HFH Releases connection from local Hands free instance Audio connection is released if existing SLC is released anyway Response On audio disconnection lt cr lf gt HF AUO lt cr f gt only if audio connection exists On SLC disconnection lt cr lf gt NO CARRIER 111E lt cr lf gt 2 6 8 1 5 Answer incoming call from HF 4_4 13 AT HFCA Answers an incoming call ATA is sent to the AG In return the audio gateway updates its CIEV indicators call 1 and callsetup 0 and sends appropriate messages to the HF Upon receipt of a CIEV message HF notifies its host by a HFl lt indicator gt lt value gt message Refer to DIMF tone request 17_4 27 2
307. ort Laird Center http ews support lairdtech com Americas 1 800 492 2320 221 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module released by the HS SSR maximum remote interval The maximum amount of time that the remote device is allowed to be absent in mete i nee oh SSR mode Applies to SLC ACL only i e no audio link being present SSR minimum remote timeout The minimum time with no data exchange in sniff mode before a remote aa 9 a179 SaR device is allowed to enter SSR Applies to SLC ACL only i e no audio link being present SSR minimum local timeout The minimum time with no data exchange in sniff mode before a local device is sao 9 ae oh allowed to enter SSR Applies to SLC ACL only i e no audio link being present Enable disable verbose mode for call record presentation 354 0 0 1 HFG 0 Non verbose mode for AT HFGC Default 1 Verbose mode for AT HFGC Configure audio resource override 0 No override allowed Incoming outgoing SCO request is accepted while 1 A2DP is streaming The module initiates A2DP 6355 i acs A2DP HF suspend automatically Default 7 P HSP Incoming outgoing A2DP start resume request is 2 accepted while SCO is active The module releases the SCO link automatically 3 Both 1 and 2 enabled Refer to Simultaneous A2DP and HFP as well Enable restoring o
308. ote device Representing keyboard input 2 5 6 7 AT BTW lt bd_addr gt Initiate SSP This command initiates secure simple pairing dedicated bonding with a device whose Bluetooth address is lt bd_addr gt The Bluetooth 2 1 EDR specification s term for this is Dedicated Bonding Dedicated bonding means the exchange of link keys pairing without creating a connection to a particular profile or service immediately The remote device must have Bluetooth 2 1 or later otherwise legacy pairing occurs automatically if 323 0 For legacy pairing refer to AT Commands for Legacy Pairing The module immediately sends OK on receipt of AT BTW Depending on the devices collective l O capabilities an asynchronous message may appear during pairing See Table 2 13 for the required actions On pairing completion an unsolicited message in the form PAIR n lt bd_addr gt lt nn gt lt lktype gt is sent to the host 25 6 8 S Registers for Secure Simple Pairing Table 2 12 lists all S Registers for Secure Simple Pairing For details on the S Registers refer to their descriptions above Table 2 12 S Registers for Secure Simple Pairing SSP Security Level see 1 vol3 Generic Access Profile Table 5 7 S320 2 1 3 needs subsequent AT amp W and power cycle to take effect value 3 overwrites 322 Set IO capability 0 display only 1 display yes no el l ea 2 keyboard only 3 no input no output
309. oth Multimedia Module 0 Normal Data is exchanged between UART and RF LOCAL_COMMAND UART input is parsed by the AT interpreter and RF data is discarded REMOTE_COMMAND RF input is parsed by the AT interpreter and UART data is discarded If S Register 536 is not 1 then this register cannot be set to 2 and an ERROR is returned LOCAL_COMMAND UART input is parsed by the 3 AT interpreter and incoming RF data is sent to the host using the RX lt string gt asynchronous response LOCAL_COMMAND and on the RF side the GPIO 4 is automatically sent when there is a change in input digital O cable replacement mode If non zero then on every connection a SCO channel audio is initiated BitO HV1 532 0 0 7 n a Bit1 HV2 Bit2 HV3 When the connection is lost the SCO channel disappears along with it Link Supervision Timeout If units go out of range then a NO CARRIER message is sent to the host after the time 535 5 0 41 n a specified here as of v18 1 4 0 changed default value from 20 gt 5 applies to outgoing connections of all profiles When set to 1 a remote device can capture the AT parser of this unit by it sending this module an escape IIE sequence The inter character timing is set via S 536 0 0 1 n a Register 12 If S Register 507 is gt 2 then reading this register always returns 0 Writing 1 results in ERROR 33 If 1 then when a successful pair
310. ound up 60 If value is gt 60 round down If S Register 554 is nonzero after the post reset window expires defined by S554 the mode reverts to the mode specified in this register This allows for example the device to be discoverable and connectable on power up mode 4 or 7 and on window timer expiry to revert to connectable only mode 3 or 6 555 1 1 7 n a A power cycle reset via BREAK or ATZ is required to see effects of a change In some firmware builds S Registers 565 to 569 inclusive are visible which allows the start up mode to depend on the state of RI line Setting S Reg 565 forces the RI pin to be configured as an input For this feature to be active set SReg 565 to 1 In that case if RI is asserted on start up the start up mode is defined by S Reg 568 and if de asserted then S Reg 569 When 1 RING NO CARRIER and CONNECT responses are replaced by BTIN BTDOWN and BTUP respectively This eliminates ambiguity when the module is connected to an AT modem which also gives these responses S558 0 0 1 n a This specifies a mask When Bit 0 is 1 the response word ERROR is replaced by BTERR and OK is replaced by ok When Bit 1 is 1 error responses do not include the error number and instead the error number can be retrieved using ATI12 As of firmware v18 1 4 0 when Bit 2 0x04 is set three digit error code presentation is enabled which is the new default setting S559 4 0 7 n a
311. owband CVSD The internal codec is configured for a sampling frequency of 16000 Hz FS16000 INT WBS HF AU1 Audio connection SCO is established Audio On HF AUO Audio connection SCO is released Audio Off HF CLIP OK HFG replied with OK to reception of AT CLIP 1 or AT CLIP 0 HF CLIP ERROR HFG replied with ERROR to reception of AT CLIP lt gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 126 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module A Calling Line Identification Notification CLIP 1234567 lt type gt was received from the HFG This message is sent by the HFG on incoming HF CLIP n m 1234567 calls together with HF RING The HFG and telephone network must support this feature and the according flag Bit 2 value 4 in the HF supported features S register 581 must be set at boot time n Type of number derived from the lt type gt in SLC messages not the original value 0 Unknown 1 International number 2 National number 3 Network specific number 4 Dedicated access short code m Length of caller number number of characters 1234567 Caller number HF CCWA OK HFG replied with OK to reception of AT CCWA 1 or AT CCWA 0 HF CCWA ERROR HFG replied with ERROR to reception of AT CCWA lt
312. ower current consumption at the cost of probably longer time to find the device and longer time to initiate a connection Entering a connection When in a connection and not expecting any more incoming connections for any remaining profile then page scanning being connectable and inquiry scanning being discoverable should be disabled This leads to lower power and lower bandwidth consumption As of this firmware version BTM51x provides a feature to change the scanning modes automatically upon connection of one or all profiles and restoring scanning modes on disconnection of one or all profiles See Auto BTX 308 Sniff mode when connected but no data being exchanged then sniff mode helps to reduce power consumption at the cost of higher latency for the first data being transmitted after a longer idle time In sniff mode master and slave agree that the master will not poll the slave for a certain interval Thus the slave does not have to enable its power hungry radio circuit in each possible slot The same applies to the master provided there are no other slaves on the piconet which he controls Sniff mode is well suited for Rfcomm based profiles and is supported for SPP HSP and HFP as of this firmware version 22 1 4 2 Sniff sub rating SSR This sub mode of sniff mode has been introduced with BT2 1 EDR specification It can be understood as permission for the remote device to extend the current sniff interval by a whole numb
313. port Laird Center http ews support lairdtech com Americas 1 800 492 2320 200 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Page Scan Inquiry Scan Window Window i S509 i 6 S511 Page Scan Interval RD Inquiry Scan Interval Page Scan S508 S510 lt gt a Figure 2 41 Page and Inquiry Scan Intervals and Windows 2 9 10 2 Multi profile Auto BTX 308 S308 has been extended by a multi profile policy The term Auto BTX means the automatic change to not discoverable not connectable after entering a connection and restoring scanning mode according to 512 when leaving a connection The relevant AT command for this purpose would be AT BTX this is where the term Auto BTX comes from In previous firmware versions S308 had applied to A2DP only Two more bits were added to 308 for defining a ONE ALL multi profile policy 308 Bit 3 2 1 0 MPP EXIT ENTER Default 1 0 1 1 Table 2 98 5308 O ENTER When entering a connection 0 do not change discoverable connectable mode 1 make the module not discoverable and not connectable default 1 EXIT When leaving a connection 0 do not change discoverable connectable mode 1 restore discoverable connectable mode according to 512 default Embedded Wireless Solutions Support Laird Center http ews support la
314. port lairdtech com Americas 1 800 492 2320 220 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0 Display indicator ID only in HFI asynchronous message Refer to DIMF tone request 17_4 27 Display indicator string in HFI asynchronous message Refer to DIMF tone request 17_4 27 Enable Extended Sdp Error Codes S334 0 0 1 n a 0 Disabled 1 Enable LED 0 mode O LED_OFF 335 0 0 3 LED 1 LED_ON 2 LED_PWM 3 LED_PULSE 5336 2048 0 4095 LED LED 0 Duty Cycle Referenced in LED mode LED_PWM or LED_PULSE 5337 0 0 15 LED LED O PWM Period Referenced in LED mode LED_PWM 5338 5 0 15 LED nace Rate Referenced in LED mode 340 0 0 3 LED LED 1 mode see 335 341 2048 0 4095 LED LED 1 Duty Cycle see 336 342 0 0 15 LED LED 1 PWM Period see 337 343 5 0 15 LED LED 1 Pulse Rate see 338 Enable automatic alerting on ACL establishment 0 Disable auto alerting S345 1 0 3 HSG 1 Auto alerting on outgoing ACL established 2 Auto alerting on incoming ACL established Auto alerting on outgoing and incoming ACL established Enable in band ringing 346 0 0 1 HSG o Disable 1 Enable Enable automatic ACL release S347 0 0 1 HSG 0 Disable 1 ACL is released automatically when audio is Embedded Wireless Solutions Supp
315. pplication attribute value Response pairs See AVPL AVPE Table 2 41 and Table 2 42 Terminator OK ERROR nnn AT AVQPF Query TG player Parameters None features Octets 7 and 8 of Player Feature Bitmask of Response the last player listed in the available players p list AT AVQAP AVAPI See AVRCP1 5 Specification pages 68 69 Terminator OK ERROR nnn AT AVQPP Query play status Parameters None and parameters of addressed AUPE selected player Response lt play_status gt lt elapsed_ms gt lt song_len_ms gt Terminator OK ERROR nnn Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 88 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT AVQPT lt Attld Query TG player Syntax AT AVQPT lt Attld gt application setting gt attribute text lt Attld gt Attribute ID to query text for optional Parameters 2 oe If lt Attld gt is not specified then the text for all available attributes is returned List of player application attribute value Response pairs See AVPL AVPT Table 2 41 and Table 2 42 Terminator OK ERROR nnn Note This was not tested due to lack of support on test TG AT AVQPRI lt Attld Query TG player Syntax AT AVQPRI lt AttId gt gt eppleaonserng lt Attld gt Attribute ID to query possible value range
316. pport DSP post processing to set up parametric equalizers 3D stereo enhancement compander BassBoost etc CSR s tool UniversalFrontEnd UFE Music Manager GUI allows to set parameters and hearing changes immediately It requires an SPI connection to BTM51x via CSR s USB SPI interface or LPT port interface as well as the correct version of UFE Music Manager Check ATI38 to find the correct version Figure 2 17 The last part ADK2 0 indicates that the correct version of UFE Music Manager for these decoders is contained in CSR ADK2 0 Laird may provide this tool under certain conditions Ezurio Terminal Ver 6 8 0 lo0l x CTS DSR DCD AB RTS DIR BRK CAPTURES Echo Clear Data Transfer Test COM38 9600 N 8 1 ati38 C E007 C E007 TX E007 014 Figure 2 17 ATI38 2 6 3 21 Connecting to UFE Create an A2DP connection with BTM5xx as sink to start streaming e g playing music from a phone As soon as APSTR lt appears on the module s UART you may connect to the DSP application loaded UFE queries the SysID and BuildNo of the DSP application over SPI You may only connect if the Sysld is correct OxEO06 After UFE has successfully connected in the upper left corner MusicManager appears followed by Sysld vE006 hexadecimal BuildNo 6101 decimal and current sampling frequency Enable monitoring mode by either clicking Menu gt DSP gt Monitor DSP or the glasses button I
317. preferred to stick to indication of the AudioOn state as long as this state is true From this reasoning we derive the priority rule in the timeline of a usage scenario the innermost state has the highest priority the outermost state has the lowest priority In our example the innermost state is AudioOn and the outermost state is Scanning This leads to the following priority configuration Figure 2 29 States detined for indication Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 159 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 1 Not disc Not con no parameters for AT 27 0 1 low 2 Discoverable only scanning states ATI27 1 4 Connectable only mutual exclusive ATI27 2 8 Discoverable Connectable ATI27 3 Status regarded as TRUE 2 16 Connected none any profile whenever any profile is connected 3 18 Voice recognition on none tany Audio type l Status regarded as TRUE 4 high 17 AudioOn none any audig whenever the audio circuitry is type direction turned on 2 7 4 3 D Reg 744 745 status to blink pattern mapping Dynamic registers 744 gt LEDO and 745 gt LED1 assign an LED blink pattern to a status ID Tuple lt Statusld gt lt Patternid gt Range 1 17 0 10 Default none For lt Statusld gt
318. quency is displayed by the FSddddd lt interface gt asynchronous message see Routing audio streams over 2S S316 is referenced at boot time for building the sampling rate capability record if S314 gt 0 12S interface for enabled A2DP Before changed values of 316 or S314 become effective commands AT amp W and ATZ must be sent to the module Table 2 73 BTM5 1x A2DP supported sampling rates for I2S5 I2S sampling rate capability for A2DP values can be added for all sampling frequencies supported Register is referenced if S314 gt 0 at boot time requires AT amp W and ATZ for new values to become effective 1 48 kHz S316 63 1 63 5 aad kHz 4 32 kHz 8 24 kHz 16 22 05 kHz 32 16 kHz 1 A2DP Source at least one of these sampling frequencies 48kHz 44 1kHz must be supported A2DP Sink both 48 kHz and 44 1 kHz must be supported at least 2 values ignored as they are not supported by SBC neither by APTx 2 8 2 1 5 12S Data Format I2S data is transferred in so called I2S mode This means left justified mode with the MSB starting one SCK cycle delayed after transition of the WS signal The number of bits per sample is set to 24 24 SCK cycles between two WS transitions but the actual sampling bit length is only 16 bit Hence 8 SCK cycles are not used for data transmission Refer to Figure 2 33 k time 1 f_sampling WS La Channel le 24 cycles 16 bit
319. r to specify blinking with defined on time in a defined period PWM Period gt blinking visible for the eye In LED_PULSE mode the brightness of an LED is modulated Modulation speed is defined by parameter Pulse Rate and maximum brightness is defined by parameter Duty Cycle Table 2 78 BTM51x LED S Registers Set LED 0 mode 335 0 3 default 0 Mode O LED_OFF Set LED 1 mode 340 0 3 default 0 1 LED_ON 2 LED_PWM 3 LED_PULSE Set LED 0 Duty Cycle 336 0 4095 default 2048 referenced if LED mode LED_PWM or Set LED 1 Duty Cycle S341 0 4095 default LED_PULSE 2048 Set LED O PWM Period 337 0 15 default 0 Set LED 1 PWM Period 342 0 15 default 0 Set LED O Pulse Rate 338 0 15 default 0 Set LED 1 Pulse Rate 343 0 15 default 0 referenced if LED mode LED_PWM referenced if LED mode LED_PULSE 2 8 7 Hardware Units S Registers Table 2 79 provides an overview on S Registers for hardware units except GPIO For GPIO Registers refer to Table 2 83 Table 2 79 BTM5 1x S Registers for Hardware Units Enable asynchronous FS message presenting sampling frequency and audio interface 3309 1 cl O Disable 1 Enable default A2DP audio interface select 0 internal codec default PH i oe 1 12S master 2 12S slave Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 180 Europ
320. rce 313 Use S Register 313 to set the A2DP source supported features that are to be advertised in the A2DP service record Refer to Table 2 24 The S register must be saved AT amp W and the module must be power cycled ATZ for a new value to become effective 2 6 3 14 A2DP Audio Stream Routing 314 By default A2DP audio is routed to the internal codec of the BTM5xx module i e its onboard analogue audio inputs or outputs 314 permits you to use a digital audio bus such as 12S for A2DP audio as follows 314 O internal default 1 I2S master 2 2S slave Refer to Table 2 24 and Digital Audio Interface including important information regarding sampling rate capabilities of devices connected to the 12S bus 2 6 3 15 A2DP Codecs SBC vs APTx AAC The standard codec for A2DP is the Sub Band Codec SBC Here codec refers to DSP algorithms which encode an audio stream for transmission over a limited bandwidth link and which decode the compressed data on the receiver side 1 One advantage of SBC is wide support by all A2DP devices because SBC is a mandatory feature of the A2DP specification One disadvantage is the significant latency around 1s needed to encode transmit 1 A different definition of the term Codecis an integrated circuit IC composed of ADC and or DAC combined with a sampling rate clock and anti aliasing filters This definition is referred to when talking about external audio codec or i
321. rd BTM5xx device configured in 12S cross loopback mode AT BTL4 may be the 12S slave device It then acts as analogue to I2S converter Table 2 71 shows the required AT command sequence Table 2 71 BTM5 1x I2S example AT command sequence AT amp F AT amp F AT amp F Restore factory default settings AT BTL4 Configure 12S slave source 1 B Select 12S master interface at ARAIA A2DP source Embedded Wireless Solutions Support Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 Center http ews support lairdtech com www lairdtech com bluetooth 167 BTM510 511 User Guide Bluetooth Multimedia Module ATS300 2 Enable Source role Make connectable and ASIAA discoverable AT amp W AT amp W Store S Register configuration ATZ ATZ Reset Initiate connection Get AT APD lt Bluetooth Bluetooth address of other end Address Source gt by ATI4 on other end or by inquiry AT BTI 1 For demonstration purposes or if no other 12S source is available a 3 BTM5xx can be used as analogue to I2S converter in I2S cross loopback mode 2 8 2 1 3 Routing audio streams over 12S S314 selects the audio interface to use when entering an A2DP connection 315 selects the audio interface for entering an SCO connection Available options for both 314 and 315 are 0 internal codec 1 12S master and 2 I2S slave Table 2 72 BTM51x S Registers Audio Routing 314 0 0 2 A2DP audio interface select 0 int
322. rd Technologies products are intended for use in normal commercial and industrial applications Applications requiring unusual environmental requirements such as military medical life support or life sustaining equipment are specifically not recommended without additional testing for such application Limited Warranty Disclaimer Limitation of Liability Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 259 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610
323. re 1 and Table 3 in Bluetooth Assigned Numbers 8 Bits 13 23 Major Service Class 11 bit field used as a mask to define service classes refer to Figure 1 and Table 2 in Bluetooth Assigned Numbers 8 Laird Technologies devices do not map to any predefined Major Service Class or Major Device Class and so the default devclass as shipped is 001F00 which means no Major Service Class and Unclassified Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 10 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Major Device class Profile specifications define certain mandatory flags to be set in the device class code These can usually be found in the section named Link Controller LC Interoperability Requirements in the appropriate profile specification Other examples of device class codes are listed in Table 2 5 Table 2 5 Device class codes 0x001F00 Unclassified None Unclassified n a 0x200404 Headset Audio Audio Video Wearable Headset Device 0x200408 Hands free device Audio Audio Video Hands free Device A free tool Class of Device Generator is available online to create a particular device class code see 9 A device class set by AT BTC becomes visible immediately but is lost on the next power cycle Response lt cr lf gt OK lt cr lf gt Or for
324. re factory default settings A2DP profile is enabled per default in S102 s i P ATS300 2 Enable Audio Source role eet ATS515 080400 Set A2DP device class source AT amp W Store settings ATZ Reset ar Response Pade B pelea anes PAIR O pairing successful A and B CONNECT connected A and B Play music from the audio source Music should be audible on the headphones Connected speakers If not check the audio output device e g connect headphones directly to audio source for a test AT GOU Increment volume audio output gain by one D t volume audio output gain b Adjust AT GOD ecrement volume audio output gain by Volume one AT GIU Increment volume audio input gain by one AT GID Decrement volume audio input gain by one Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 43 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Note the audio input gain A2DP source is a critical setting because the optimal setting cannot be verified by the module objectively Response NO CARRIER 110D disconnection Disconnect A B AT APH i confirmed zix CTS DSR DCD AB RTS DTR BRK CAPTURED Echo Clear Data Transfer Test Open COM4 9600 N 8 1 Z BH OL A4Q00004 0 A 0 A 2 0 Figure 2 13 A2DP Example 2 Preparation of Device A Sink iojxi CTS
325. red for the new value to become effective Make sure that Bit 6 is always set this is a mandatory feature for HFP1 5 AG and HFP1 6 AG Select SCO audio 315 SCO audio interface select interface BTM5xx only O Internal codec default 1 I2S master 2 I2S slave 3 PCM master PCM_M 4 PCM slave PCM_S Refer tol2S Inter Integrated Circuit sound Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 147 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Inquire HFG status ATI66 0 Not connected 1 SLC connected 2 Audio connected 3 In call SLC 4 In call audio Call setup ringing 5 incoming call dialling or alerting outgoing call SLC Call setup ringing 6 incoming call dialling or alerting outgoing call audio 8 In call but no SLC Enable WBS 16kHz S376 0 1 0 Disable WBS 8kHz applies also to 1 Enable WBS 16kHz default incoming SPP SCO requests Close audio on voice 378 0 1 0 Disable recognition stop 1 Enable default 1 AT HFGC1 is the only possible response to HFG Dnnn To reject this call attempt from the HF the HFG must issue AT HFGC1 first and subsequently AT HFGCH 2 HFGE instead may respond to HFG D gt mmm and HFGL to confirm that
326. resentation CLIP 13_4 23 The CLIP feature is enabled by setting Bit 2 value 4 in the HF supported features S register 581 Subsequent AT amp W and ATZ is required to take effect If this bit is set at boot time the following actions are carried out automatically 1 The appropriate flag is set in the HF service record 2 The appropriate flag is set in the BRSF message on Service Level Connection establishment 3 The SLC message AT CLIP 1 is sent automatically once the SLC is established Response to action no 3 is indicated by either HF CLIP OK or HF CLIP ERROR after the CONNECT message 2 6 8 1 11 Enable Call Waiting Notification CCWA 11_4 21 The CCWA feature is enabled by setting Bit 1 value 2 in 581 HF supported features Subsequent AT amp W and ATZ is required to take effect If this bit is set at boot time the following actions are carried out automatically 1 The appropriate flag is set in the HF service record 2 The appropriate flag is set in the BRSF message on Service Level Connection establishment 3 The SLC message AT CCWA 1 is sent automatically once the SLC is established Response to action no 3 is indicated by either HF CCWA OK or HF CCWA ERROR after the CONNECT message 2 6 8 1 12 Enable Disable Query Toggle Voice Recognition Activation 15_ 4 25 AT HFV lt x gt with lt x gt 1 0 2 T 2 6 8 1 13 Query subscriber number from HFG 20_4 30 AT HFS Query subscriber numbers from HFG AT
327. ries from other devices inquiry scans enabled The setting remains valid until next reset or power cycle unless not changed by any other AT command subsequently For permanent discoverable connectable settings refer to S Register 512 Use AT BTX to make the device not discoverable Response lt cr lf gt OK lt cr lf gt 2 5 1 13 AT BTG Make Device Connectable Make the device connectable but not discoverable and wait for a connection from any device The setting remains valid until next reset or power cycle unless not changed by any other AT command subsequently For permanent discoverable connectable settings refer to S Register 512 Response lt cr lf gt OK lt cr lf gt 2 5 1 14 AT B1V lt bd_addr gt lt uuid gt SDP Query for Service This command interrogates the SDP database of the peer device lt bd_addr gt for the service lt uuid gt It results in an ACL connection and then an SDP transaction If the lt uuid gt service is present then it returns Response lt cr lf gt 0 lt cr f gt OK lt cr lf gt If the lt uuid gt service is not present then it returns Response lt cr f gt 1 lt cr f gt OK lt cr lf gt If the device lt bd_addr gt cannot be reached or is in non connectable mode then it returns Response lt cr lf gt 2 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 12 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong
328. rom ATI72 response AT ACDn Delete one record from persistent store n index of record to be deleted in ACR table select from ATI72 response AT ACD Delete all records from persistent store To modify an existing ACR table entry with index n copy it to the scratch record first using AT ACLn In the scratch record the index will be set to zero Modify it then copy it back to persistent store Use AT ACRn to replace the existing record with index n Use AT ACW to insert the scratch record at top of the ACR table The new index is 1 and all subsequent ACR table entries indices are incremented by one Up to five ACRs can be stored in the table One record can contain multiple profiles When adding a new record to the top of the table index 1 the index of all other existing records are increased This can be interpreted like the index representing the age or history of a record The oldest record index 5 is deleted when adding a new record to the complete list 2 7 1 4 ATI72 Query ACR table persistent store ATI72 allows to query the current ACR table from persistent store non volatile memory Each line presents one entry If the ACR table contains zero items response is 0 more precisely lt cr lf gt O0 lt cr lf gt OK lt cr If gt ATI72 response syntax lt index gt lt BdAddr gt lt pm gt lt interval gt lt state gt lt pm_cnct gt lt flags gt With lt index gt Index of the entry starting
329. rom TG See Table 2 48 Terminator OK ERROR nnn Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 86 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT AVQRF Query remote Parameters None device AVRCP a ae a UI16 hex value indicating features of remote Response device Value corresponds to SDP record of remote device See Table 2 49 Terminator OK ERROR nnn AT AVQXT Query remote Parameters None mane aie UI16 hex value indicating profile version and extensions profile versioni metadata metadata support of local device Currently Response 0007 is returned which indicates the following AVRCP1 4 browsing supported Terminator OK ERROR nnn AT AVQEC Query remote Parameters None Ay UI16 hex value indicating all events the R sbone connected remote device TG offers the p local device CT to register for to receive event notifications See Table 2 48 Terminator OK ERROR nnn AT AVQSP Query addressed Parameters None selected pl aseieciect playar UI16 hex value player ID of addressed Response selected player Terminator OK ERROR nnn AT AVQBP Query browsed Parameters None ID p ayer UI16 hex value player ID of browsed player Response If FFFF is returned then no command has P been issued
330. rs The following table lists all S Registers Table 3 1 BTM General S Registers Number of RING indication before automatically answering an incoming connection A value of O disables autoanswer If 1 then autoanswer on one RING and do NOT send RING CONNECT response to the host This emulates a serial cable replacement situation Setting values gt 0 resets S Register 504 to 0 and lt 0 forces 504 SO 0 1 15 SPP to 1 If SO lt gt 0 and S100 lt gt 0 then SO must be lt 100 If a value is entered which violates this rule then ERROR 29 is sent in response If S504 1 then this register returns 1 regardless of the actual value stored in non volatile memory Escape sequence character It is not by default as a serial link to a mobile phone exposes the phone s AT command set which uses as default If both use there is confusion Ox5e is the character 4 S2 94 32 126 n a Escape sequence guard time in milliseconds with a 12 100 40 5000 n a granularity of 20ms New values are rounded down to the nearest 20ms multiple Number of RING indications before an auto disconnection is initiated A value of 0 disables this S100 15 0 15 SPP feature If SO lt gt 0 and S100 lt gt 0 then SO must be lt S100 If a value is entered which violates this rule then ERROR 29 is sent in response UUID of default SPP based profile when not specified PGI s1101 i ta explic
331. rs with leading lt interval gt Interval of reconnection attempts in seconds Status of the ACR O Attempting connection at every interval seconds lt state gt 1 Partly connected at least one profile of pm connected at least one profile of pm not connected attempting to connect the remaining profiles 2 Fully connected all profiles of the ACR connected Profile mask of actually connected profiles As with 102 this value is four lt pm_cnct gt hexadecimal characters with leading Option flags two hexadecimal characters with leading bitmask Always reconnect If this bit is set a normal disconnection yields Bit 0 reconnect attempts If bit is cleared the record is deleted from the lt flags gt ACR table on normal disconnect Link loss leaves the entry in the ACR table yielding reconnect attempts Bit 1 Always send AVRCP play Bit 2 Never send AVRCP play ATI73 Auto Connect Service ACS status O Service disabled not running Service enabled paused between connection attempts interval timer running 2 Attempting initiates connections as defined by ACR table Attempt repeat resumes connection attempts after a profile with transitional state was found and the transitional state was finished 4 All profiles of ACR table are connected monitors disconnect events 1 3 ATI74 Auto connect attempt interval in seconds If the
332. rt lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 242 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module S669 0000 0 ff GPIO Enable strong bias strong pull up pull down mask if GPIO is configured as input 0x0001 GPIO1 0x0002 GPIO2 0x0004 GPIO3 Ox0008 GPIO4 0x0010 GPIO5 0x0020 GPIO6 0x0040 GPIO7 0x0080 GPIO8 5670 000A 0 ff GPIO Read Write all GPIOs in one atomic step Write operation only affects GPIOs configured as outputs 0x0001 GPIO1 0x0002 GPIO2 0x0004 GPIO3 0x0008 GPIO4 0x0010 GPIO5 0x0020 GPIO6 0x0040 GPIO7 0x0080 GPIO8 689 20 450 Audio Set output overall gain dBr See Gain Table value must 215 be entered and is returned multiplied by 10 S589 is also affected 5690 20 450 Audio Set input overall gain dBr See Gain Table value must 215 be entered and is returned multiplied by 10 S590 is also affected 730 0 0 1 S731 0 0 255 S744 OK 1 18 0 10 S745 OK 1 18 0 10 een to 0 0 2 32 ma Ten General Purpose 32 bit Registers for use by host These are stored in non volatile memory Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 243 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 3 2 ATI Comma
333. s message APSUS gt confirms that streaming is suspended and that it was initiated locally gt Refer to A2DP streaming state Response lt cr gt lt lf gt OK lt cr gt lt lf gt command accepted lt cr gt lt lf gt APSUS gt lt cr gt lt lf gt A2DP stream suspended locally initiated or lt cr gt lt lf gt ERROR 77 lt cr gt lt lf gt wrong A2DP state Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 47 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 3 11 Resume A2ZDP Stream AT APR A suspended A2DP stream can be resumed manually by AT APR The asynchronous message APSTR gt confirms that streaming is resumed and that it was initiated locally gt Refer to A2DP streaming state Response lt cr gt lt lf gt OK lt cr gt lt lf gt command accepted lt cr gt lt If gt APSTR gt lt cr gt lt lf gt resuming A2DP stream locally initiated or lt cr gt lt If gt ERROR 77 lt cr gt lt lf gt wrong A2DP state 2 6 3 12 Supported Features A2DP Sink 312 Use S Register 312 to set supported features in the A2DP sink that are advertised in the A2DP service record Refer to Table 2 24 The S register needs to be saved AT amp W and the module needs to be power cycled ATZ for a new value to become effective 2 6 3 13 Supported Features A2DP Sou
334. s the link key type For legacy pairing the value should be 1 2 5 8 AT Commands Managing Trusted Devices 2 5 8 1 AT BIT List Trusted Device This command lists the contents of the trusted device database The link key is NOT displayed but the link key type is appended to each line of the response as shown below If the list is empty then just the OK response is sent Otherwise an OK terminates the list Use the command ATI6 to read the maximum size of the trusted device database Response lt cr lf gt 12346789012 4 lt cr lf gt 123456789013 3 lt cr lf gt 123456789014 3 lt cr lf gt OK lt cr If gt lt bdaddr gt lt Iktype gt Possible values for lt Iktype gt are displayed in Table 2 14 Table 2 14 Link key type values No link key Legacy link key BT 2 0 and earlier Debug link key should never occur in practice Unauthenticated link key no MITM protection Authenticated link key MITM protection Link key changed mW Bi WIN O Note In practice only the values of 1 3 and 4 should play a role Examples for pairing messages with link key type appended Unauthenticated link key PAIR O 0016A4000001 00 3 Authenticated link key PAIR O 0016A4000001 00 4 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 a6 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multim
335. s to be sent then insert the escape sequence hh where hh are two hexadecimal digits The 3 character sequence hh is converted into a single byte before transmission to the peer Response lt cr lf gt OK lt cr lf gt Or lt cr lf gt ERROR O5 lt cr If gt e g lt string gt too long 25 9 3 Enter Local Command Mode When in data and connected mode and when S 507 is set to O or 1 the host can force the device into a command and connected mode so that AT Commands can be issued to the device The character in this escape sequence is specified in the S2 register which may be changed In addition the escape sequence guard time is specified by S 12 By default the guard time is set to 100 milliseconds Leaving data mode using 44 severe impacts data throughput because each incoming character needs to be checked for 4 with respect to the guard time Alternatively a de assertion of the DTR DSR line can be used as the only trigger to leave data mode S507 2 This gives a significant higher data throughput because data is passed directly between UART and RF without character checking Refer to Dropping SSO Connections for more information In modems this escape sequence is usually AAA is specified to avoid confusion when the module is providing access to a modem Response lt cr lf gt OK lt cr If gt Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 228 Europe
336. s turned out to be more convenient when exploring the auto connect feature Stopping ACS by DSR is confirmed by OK If ACS must be stopped when in an attempt cycle the confirmation can be delayed by ACS waiting for the attempt outcome In inconvenient circumstances e g pairing is triggered by connect attempt and experiences significant delay or multiple profiles are enabled in the ACR a safety timeout is triggered after 10s which forces ACS to stop and return ERROR 105 The error notes the unclean stop of ACS but guarantees ACS is fully stopped and the parser is functional 27 2 4 AT ACS Query ACS status AT ACS query status of auto connect service ACS Response is identical to ATI73 see ATI73 Query ACS status for ACS status definition Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 155 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 27 2 5 ATI73 Query ACS status ATI73 query auto connect service ACS status O Service disabled not running 1 Service enabled paused between connection attempts interval timer running 2 Attempting initiating connections as defined by ACR table Attempt repeat resuming connection attempts after a profile with transitional 3 state was found and the transitional state was finished 4 All profiles of ACR table are connected
337. sed values of n Response lt cr lf gt ERROR nn lt cr f gt 25 24 AT amp Fn Set S Register Defaults AT amp Fn n 0 8 allows you to set pre defined configurations for maximum medium and low power consumption This allows you to set up the trade off between power consumption and data latency without having to deal with details of the various parameters and S registers This command only works when the device is in local command and unconnected mode Legal values of n are as per Table 2 6 All other values of n generate a syntax error response If n is not specified a default value of 0 is assumed and the baud rate is not changed Table 2 6 Pre detined power settings O default Unchanged Medium Maximum 1 9600 Minimum Minimum 2 38400 Minimum Minimum 3 115200 Minimum Minimum 4 115200 Medium Medium 5 115200 Maximum Maximum 6 115200 Maximum Maximum 7 Unchanged Medium Medium 8 Unchanged Minimum Minimum The new values are not updated in non volatile memory until the AT amp W command is sent to the device Response lt cr lf gt OK lt cr If gt Or Response lt cr lf gt ERROR nn lt cr f gt Table 2 7 Pre detined Min Med Max power setting parameters S508 page scan interval ms 2500 640 640 Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 14 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511
338. sm to recover from this state on a power cycle reset ATZ If the remaining free space of the current segment is below a certain limit the flash segment is defragmented and copied to a free segment Due to this defragmentation which clears out all invalidated data free space in the segment becomes available From now on the new segment is being used for all operations read write delete Finally the old segment is deleted to prepare for the next defragmentation copy cycle 2 9 21 2 AT NVQ F commands to manage persistent store BTM5 1x firmware provides AT commands allowing management of persistent store AT NVQ query the remaining space in current segment AT NVF flood the remaining space of current segment On next power cycle ATZ a defragmentation cycle occurs 2 9 21 3 Commands implying persistent store usage The following operations and commands use persistent store Write delete auto connect records AT ACW AT ACRn AT ACDn AT ACD Write dynamic registers S744 S745 Write EIR data AT BTEW Save S Registers AT amp W 2 9 21 4 Strategy to prevent persistent store write errors If an application makes extensive use of persistent store PS operations then the PS consumption of the application should be considered and evaluated AT NVQ helps to analyse the consumption of each relevant operation by querying the free space before and after It also helps monitor the free space over a longer applicati
339. sponse is sent to the host during a pairing negotiation Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 25 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module The fully qualified string is PIN 012345678901 where 012345678901 is the Bluetooth address of the peer device In response the host must supply a pin code which is entered using the AT BTK command If the peer does not supply the address in the message exchange then the address is specified as 000000000000 and the paring proceeds as normal PAIR n lt bd_addr gt lt Iktype gt This response is sent to the host on termination of a pairing process If pairing is successful then n 0 If a timeout occurs then n 1 For all other unsuccessful outcomes n gt 2 The parameter lt bd_addr gt is the address of the peer device if available lt Iktype gt indicates the link key type For legacy pairing the value should be 1 PAIR O lt bd_addr gt lt nn gt lt Iktype gt This response is sent to the host on termination of a successful pairing process The optional lt nn gt is sent only if the according S Register 325 328 is set to 1 automatically saving the link key The value lt nn gt indicates the result of the save operation A value of 00 implies success otherwise lt nn gt is an error code lt lktype gt indicate
340. ss 123456789012 is established The connection was initiated by the remote device incoming Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 52 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module CONNECT 123456789012 110D gt An A2DP connection with Bluetooth device address 123456789012 is established The connection was initiated by the local device outgoing FS44100 INT The internal codec is configured with a sampling frequency of 44100 Hz FS44100 I2S_M The 2S bus is configured as 12S master with a sampling frequency of 44100 Hz FS44100 I2S_S The 2S bus is configured as 12S slave with a sampling frequency of 44100 Hz APSUS lt Transition to A2DP suspended state initiated by remote device incoming APSUS gt Transition to A2DP suspended state initiated by local device outgoing APSTR lt Transition to A2DP streaming state initiated by remote device incoming APSTR gt Transition to A2DP streaming state initiated by local device outgoing NO CARRIER 110D An existing A2DP connection has been terminated or an A2DP connection attempt has failed Table 2 24 A2DP S Registers and AT Commands 128 A2DP Error 46 if A2DP role has not been set Enable A2DP profile S102 see S300 Needs subsequent AT amp W and ATZ to become effective 0 Feature not set 1 A2DP
341. st Open COM24 9600 N 8 1 AT SPDO016A4000002 PAIR 001644000002 20 CONNECT 001644000002 1101 gt 67890 OK AT SPH NO CARRIER 1101 Figure 2 5 SPP example Device A initiate connection receiving data command mode disconnect inii CTS DSR DCD RI RTSY DTR BRK CAPTUREJ Echo Clear Data Transfer Test Open COM30 9600 N 8 1 Se PAIR 016A4000001 20 RING 01644020001 1101 CONNECT 001644000001 1101 lt 345444 NO CARRIER 1101 Figure 2 6 SPP example Device B incoming connection receiving data disconnection Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 35 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 2 2 ATA Accept incoming SPP connection request Accept an incoming connection which is indicated by the unsolicited string lt cr lf gt RING 123456789012 lt cr If gt every second 123456789012 is the Bluetooth address of the connecting device Response lt cr If gt CONNECT 123456789012 1101 lt lt cr If gt 2 6 2 3 Al SPD lt bd_addr gt Make Outgoing SPP Connection Initiate a SPP connection to device with Bluetooth address lt bd_addr gt and SPP profile The timeout is specified by S register 505 For backward compatibility the following command fulfils the same purpose ATD lt bd_addr gt Response lt cr If gt CONNECT 12345
342. t as a signal to stop sending any data For example Nokia 6310 stops responding If this register is changed while in command and connected mode then on going back online using the ATO command a fresh signal is sent to the peer to update the bits Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 237 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 552 0122 0 tff n a This register specifies in each 4 bit nibble how the DTR DCD and RI output pins are controlled by RRCOMM control bits RTC RTR DV IC when in a Bluetooth connection Nibble 0 3 Specifies the source for DTR Nibble 4 7 Specifies the source for DCD Nibble 8 11 Specifies the source for RI Each nibble can take the following value Do NOT touch the I O Configure DCD or RI as input at boot time 1 Always de assert 2 Always assert If RTC bit in CONTROL_IND is 1 then assert Otherwise de assert If RTR bit in CONTROL_IND is 1 then assert Otherwise de assert f DV bit in CONTROL_IND is 1 then assert Otherwise de assert If IC bith in CONTROL_IND is 1 then assert Otherwise de assert 6 If this register is changed while in command and connected mode then on going back online using the ATO command the modem output lines are refreshed 553
343. ta RTS CTS and modem control signals managing the status of a modem DTR DSR DCD RI The handshaking signals should not be touched but modem control signals can be used for digital I O cable replacement if not otherwise needed In fact modem control signals already control or signal many states on a BTM module particularly in SPP connections These uses include changing from connected to command mode dropping an SPP link by DSR or indicating an SPP connection by DCD see 507 If features like these are not needed for the application RFC control signals can be used for cable replacement Configuration takes place by 551 and S552 Refer to the S Register reference table in 3 1 An SPP link is required for this to be working and the SPP link can still transmit serial data 2 9 3 4 Digital Cable Replacement by mixed variants The fixed mapping of modem control lines to GPIOs reduces the number of free configurable GPIOs by four But it is possible to mix the RFC approach with GPIO AVRCP or GPIO FMC to achieve a higher number of GPIOs to be utilized for digital cable replacement 2 9 3 5 Pure Cable Replacement The term pure cable replacement used in this document refers to automatic creation of an SPP link to a pre defined peer device whenever the local module is powered up Refer to the AT BTR command 2 9 4 Link Key Management On a BTM device link keys are managed by the AT firmware Appropriate AT commands are described in AT Com
344. ta received on HSP ACL HFRX lt data gt HFGRX lt data gt Display any data received on HFP SLC HSUC lt data gt HSGUC lt data gt Display unknown command received on HSP ACL HFUC lt data gt HFGUC lt data gt Display unknown command received on HSP ACL Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 517 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module C New data in SLC input buffer D if S379 1 A Received SLC data print entire or AT RX1 4 accumulated SLC input buffer HFRX lt SLC input buffer gt SLC Parser Command Terminator 0xD Found No Remove command from x SLC input buffer Accumulate data in SLC input buffer Is Command Recognised if S380 1 B Unregognized or AT UC1 SLC command i Y HFUC lt SLC cmd gt Figure 2 44 Receiving commands from SLC 2 9 25 Ringtones A set of 94 pre defined tones has been added which can be played at any time using AT SIT lt n gt whereby lt n gt specifies the index 1 94 Tone volume is controlled by S387 0 15 Some tones are suitable as ring tones others are preferred for status indications The only automatic trigger occurs when HF or HS receive the RING message on SLC ACL and if HFG has disabled in ba
345. ted on the HF by HF COPS An OK is sent by HFG on termination indicated on HF by the asynchronous message HF COPS OK If the HFG does not support this feature it should send ERROR indicated on HF as HF COPS ERROR Refer to Hands free asynchronous messages Response Immediately BTM accepting command lt cr gt lt lf gt OK lt cr gt lt lf gt Plus one of the following lt cr gt lt lf gt HF COPS lt mode gt lt operator_size gt lt operator gt lt cr gt lt lf gt refer to Hands free asynchronous messages lt cr gt lt If gt HF COPS OK lt cr gt lt lf gt OR lt cr gt lt If gt HF COPS ERROR lt cr gt lt lf gt 2 6 8 1 15 Enable Extended Error Codes in HFG CMEE 2_ 4 9 AT HFE1 Enable extended error result codes in HFG AT CMEE 1 is sent to the HFG HFG responds with OK indicated at the HF by HF CMEE OK or ERROR indicated at the HF by HF CMEE ERROR Response Immediately BTM accepting command lt cr gt lt lf gt OK lt cr gt lt lf gt Plus one of the following lt cr gt lt If gt HF CMEE OK lt cr gt lt lf gt confirmation from HFG OR lt cr gt lt If gt HF CMEE ERROR lt cr gt lt If gt error e g not supported by HFG Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 123 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM
346. ters to non volatile memory 2 6 2 SPP Serial Port Profile The serial port profile SPP enables bidirectional serial data transmission with a remote device like a wireless replacement for a serial cable SSP belongs to the group of serial stream oriented profiles SSO so refer to AT Commands for Serial Stream Oriented profiles SSO as well In order to use SPP enable the profile in S102 value If it is not enabled prior set S102 and then issue AT amp W followed by ATZ 2 6 2 1 SPP example This section explains how to make an SPP connection between two Laird BTM devices This assumes devices A and B are connected to a terminal program e g Ezurio Terminal on a PC The example sequence of AT commands is listed in Table 2 16 Figure 2 3 SPP example Preparation of Device A Figure 2 6 show the Ezurio Terminal Table 2 16 SPP Example Command Sequence Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 33 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Preparation A AT amp F Restore factory default settings ATS102 1 Enable Serial Port Profile SPP AT amp W Store settings ATZ Reset Preparation B AT amp F Restore factory default settings ATS102 1 Enable Serial Port Profile SPP ATSO 1 Automatic response after one RING AT amp W Store s
347. th saturated rounding Requires 16_BIT_CROP_EN bit 10 to be 0 7 4 Justify Resolution Attenuation in 6 dB steps 9 8 Justify Resolution Resolution of data on SD_IN 00 16 bit 01 20 bit 10 24 bit 11 Reserved This is required for right justified format and with left justified LSB first 16 bit Crop Enable For O 17 bit SD_IN data is rounded down to 16 bits For 1 only the most significant 16 bits of data are received Append channel information to unsolicited FS INT message 0 Do not change FS INT message 385 0 0 1 Append _L left _R right and _D dual stereo according to current configuration Example FS16000 INT_D S386 provides three options for enabling MPS O Disable Enable MPS service record and set 355 to 1 1 The user is responsible for enabling all required 5386 0 0 3 MPS profiles S102 and roles S300 301 2 Automatic configuration for A2DP SNK AVRCP CT HF 3 Automatic configuration for A2DP SRC AVRCP TG HFG Set tone volume analogue output only 387 15 0 15 For HF HS ringtone or AT SIT lt n gt Embedded Wireless Solutions Support Center http ews support lairdtech com 226 www lairdtech com bluetooth Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Ringtone select 0 Disable HF HS pla
348. tion as 3 PCM master PCM_M master or slave 4 PCM slave PCM_S Refer to Routing audio streams over 25 0 not connected Query HS status ATI63 1 ACL connected 2 Audio connected 2 6 7 2 Audio gateway role AG HSP HSG Audio gateway role for HSP is activated by setting flag 0x08 in S102 plus AT amp W plus atz Figure 2 25 outlines a block diagram of an audio gateway with a BTM5xx in hosted operation mode Local speaker Local microphone BTM5xx HSG or Audio routing control Mobile Termination Network HFG Host controller AT command interface f Telephone control set of buttons keypad display Figure 2 25 Audio Gateway block diagram Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 111 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 6 7 2 1 Initiate ACL connection from AG HSP AT HSGD lt bd_addr Initiates an ACL connection from local headset gateway instance to a remote device lt bd_addr remote device must support the headset role HS of the headset profile HSP gt hex gt The hex Response lt cr f gt CONNECT 123456789012 1108 gt lt cr If gt Or lt cr f gt NO CARRIER lt cr f gt Or lt cr If gt ERROR 59 lt cr lf gt Or lt cr If gt ERROR 63 lt cr lf gt After an ACL connectio
349. to set the browsed player AT AVSPB lt n gt since power cycle Terminator OK ERROR nnn AT AVQPI Query addressed Parameters None Player 1D Response UI16 hex value player ID of browsed player Terminator OK ERROR nnn AT AVQPA Query TG player Parameters None application setti 7 T ao PERS List of player application attributes but not Response values See AVPL AVPA Table 2 41 and Table 2 42 Terminator OK ERROR nnn Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 87 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT AVQPV Query TG player Parameters None application setting values for all List of player application attribute value Response pairs See AVPL AVPA Table 2 41 and ibut attributes Table 2 42 Terminator OK ERROR nnn AT AVOQPE peat TG player Syntax AT AVQPE lt Attld gt lt nValld gt application setting 3 3 attribute value text lt Attld gt Attribute ID to query text for optional lt nValld gt Value ID to query text for optional If neither lt Attld gt nor lt nValld gt are Parameters specified then the value texts for all possible value IDs of all available attributes are returned If only lt Attld gt is specified then value texts for all possible value IDs of lt Attld gt are returned List of player a
350. tus changes of GPIO inputs to the peer device For this purpose 531 must be set to 4 before creating the SPP link and S506 must be 0 The SPP connection cannot be used for serial data and the module remains in local command mode The GPIO index must be within 1 12 There is no confirmation available if a status change was transmitted successfully to the peer Ensure that the devices are not at the end of the maximum distance range The direction of several GPIOs can be mixed but one GPIO is always unidirectional For example GPIO1 direction is input on device A and output on device B Then GPIO2 could be output on device A and input on device B Note Due to inherent latency of Bluetooth transmission expect the change of a state to be delayed This value is typically 100ms and can be much more if the link quality is bad and requires many retries GPIOs mapped to the alternative function modem contro cannot be used for this variant of digital I O cable replacement See Digital Cable Replacement by RFC Modem Control Signals Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 193 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 2 9 3 2 Digital Cable Replacement by GPIO AVRCP This digital I O cable replacement variant uses the AVRCP profile It is suitable if all GPIOs have the same direction and
351. tus indication example Not connectable not discoverable 1 Flash slowly 7 1 7 Discoverable Connectable Both 14 Blink fast 2 14 2 Connected 16 Pulse slowly 10 16 10 AudioOn 17 On permanently 1 17 1 The resulting command for LEDO is ATS744 1 7 14 2 16 10 17 1 The complete AT script AT amp F Factory default ATS744 1 7 14 2 16 10 17 1 Set LEDO status blink pattern assignment ATZ Reset module note dynamic registers are immediately stored to persistent store AT amp W is not needed Verify that LEDO is flashing slowly AT BTQ AT BTG AT BTP Enter various scanning states LEDO is blinking fast AT BTX Enter not discoverable not connectable LEDO is flashing slowly For testing connected and AudioOn states see section Hostless operation 2 7 4 6 Hostless Operation Hostless operation means that no external host microcontroller is needed to control the module Any input is realized by push buttons and any output is realized by indicators such as LEDs or GPIO outputs For hostless operation ACS is typically started at boot time The first condition requires the module to be neither discoverable nor connectable at boot time S512 1 This is why in host less operation a GPIO input function mapping code FMC 0x11 turns the module in discoverable connectable mode for a time window specified by 371 This is realized by pressing a button connected to the GPIO input The
352. uery This may be because this feature is not supported by the HFG z HF COPS m ss Operator Response to an AT COPS request received from HFG Contains the current mode and contains no information m regarding the name of the operator SS Number of characters in the operator name Operator The name of the network operator in alohanumeric format HF COPS OK HFG replied with OK to reception of AT COPS HF COPS ERROR HFG replied with ERROR to reception of AT COPS HF CMEE OK HFG replied with OK to reception of AT CMEE 1 HF CMEE ERROR HFG replied with ERROR to reception of AT CMEE 1 Indicator CIEV from audio gateway was received Refer to UUIDs in HFl lt gt CONNECT NO CARRIER Messages Spy message displaying incoming data on the SLC rfcomm of the HFP HFRX lt data gt link Message displaying unrecognized command data from the SLC rfcomm HFUC lt data gt of the HFP link NO CARRIER 111E 2 6 8 1 29 Hands free summary Service level connection to local HF instance has been released See UUIDs in CONNECT NO CARRIER Messages as well Table 2 58 Hands free role HFP Summary of S Registers and AT Commands Enable HFP HF role S102 0x10 HF role of HFP bitmask needs subsequent AT amp W and ATZ to activate Initiate SLC from HF AT HFD lt bd_addrnex gt Responses If successful ONNELI 123456789012 111F gt If failed
353. uest from HF to generate DTMF code lt n gt towards the telephony network HFG NRECO Request from HF to disable noise reduction and echo cancellation This message only appears if noise reduction echo cancellation was enabled in S596 at boot time Bit1 The HFG is supposed to disable noise reduction and echo cancellation and respond with an OK If noise reduction echo cancellation was not enabled at boot time no message is displayed and ERROR is sent to the HF silently HFG CLIP1 Request to activate caller line identification notification in the AG Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 142 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module HFG CCWA1 Request to activate call waiting notification in the AG HFG CMEE1 Request to activate extended AG error result codes in the form CME ERROR lt err gt HFGRX lt data gt Spy message displaying incoming data on SLC rfcomm of the HFP link HFGUC lt data gt Message displaying unrecognized command data from SLC rfcomm of the HFP link NO CARRIER 111F Service level connection to local HFG instance has been released See UUIDs in CONNECT NO CARRIER Messages as well 2 6 8 2 27 AG HFP summary HFG Table 2 61 AG HFP HFG Summary of Registers and AT Commands Enable HFP A
354. ule The internal codec is configured for a sampling frequency of 8000 Hz narrowband CVSD FS16000 INT The internal codec is configured for a sampling frequency of 16000 Hz WBS HFG AU1 Audio connection SCO has been established audio on HFG AUO Audio connection SCO has been released audio off HFG C A call has been established and is ongoing HFG T A call has been terminated HFG R Incoming call was rejected HFG OP Request for network operator string AT COPS received from HF AG is expected to reply with COPS 0 0 lt operator_string gt on SLC Use AT HFGO lt operator_string gt HFG Dnnn Request from HF to place an outgoing call to phone number provided by HF with lt nnn gt number string The AG is expected to confirm the outgoing call with the command AT HFGC1 If the call request is not accepted by the HFG it must send AT HFGC1 first and then AT HFGCH HFG D gt nnn Request from HF to place an outgoing call using memory dialling with lt nnn gt memory location The AG is expected to either confirm the outgoing call with the command AT HFGC1 or to respond with AT HFGE if the memory location is invalid HFG L Request from HF to place an outgoing call using the last number dialled The AG is expected to either confirm the outgoing call with the command AT HFGC1 or to respond with AT HFGE if the last number dialled is unavailable HFG Mn Req
355. unction mapping codes GPIOs may trigger certain functions by a push button where normally an AT command would be required Examples include Volume Up Down answer a call HFP reject a call HFP etc Also you may use a GPIO for digital cable replacement Refer to section 2 9 3 Table 2 84 and Table 2 85 both list available function mapping codes Examples for input FMCs inversion enabled to work on BTM511 DVK V04 Volume down multiple after short press GPIO6 notification enabled ATS656 073C Volume up multiple after short press GPIO7 notification disabled ATS657 0834 Headset button HS must be enabled GPIO5 notification enabled ATS655 0B3C Button to toggle voice recognition activation from HF GPIO1 ATS651 123C Button to toggle voice recognition activation from HFG GPIO1 ATSS651 133C Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 186 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Examples for output FMCs Indicate status AudioOn GPIO7 notification enabled e g control of external audio amplifier ATS657 053A Indicate status Connected GPIO7 notification disabled ATS657 0632 Subsequent AT amp W and ATZ are required before new settings work as expected Indicate voice recognition status for HF FMC out 7 GPIO7 ATS657 07
356. utions Support Center http ews support lairdtech com www lairdtech com bluetooth 144 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT HFGC4 lt number_string gt lt type gt Outgoing call use if a call is initiated on the HFG and was not requested by HF OK is not sent to the HF A call record in state ala ling is created lt number_string gt and lt type gt are optional and is be stored in the call record if given lt type gt must be in range 128 175 Refer to Signal incoming call from AG to HF 4 4 13 Signal termination of a AT HFGCH Intelligently hangs up call based on the call or a call setup current situation procedure to HF If a call is active the active call is terminated hang up Else if a call is incoming ringing the incoming call is rejected Else if an outgoing call is being set up dialing alerting the outgoing call is terminated Else if a call is held the held call is released hang up If none of the above condition is met then ERROR 063 is returned Release all held calls AT HFGCHL Release was initiated either locally or remotely Query list of current AT HFGC Returns the list of current calls calls of HFG Enable disable verbose 354 0 1 Value mode for call record O non verbose mode for AT HFGC presentation default 1 verbose mode for AT HFGC
357. utions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 54 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Set A2DP Sink supported features bit mask 312 1 Bitmask sink supported features 0 Headphone 1 Speaker default 2 Recorder 3 Amplifier Subsequent AT amp W plus ATZ required for a new value to become effective Set A2DP Source supported features 313 1 bit mask Bitmask source supported features 0 Player 1 Microphone default 2 Tuner 3 Mixer Subsequent AT amp W plus ATZ required to commit value Enable optional A2DP 0 No optional codec default 1 APTx Bit 0 codet 307 0 3 2 AAC Bit 1 sink only 3 Both APTx and AAC enabled Subsequent AT amp W plus ATZ required to commit value 0 No override allowed Incoming outgoing SCO request is accepted 1 while A2DP is streaming The module initiates Configure audio A2DP suspend automatically default 355 0 3 resource override Incoming outgoing A2DP start resume request 2 is accepted while SCO is active The module automatically releases the SCO link 3 Both 1 and 2 are enabled Refer to Simultaneous A2DP and HFP as well m 0 Disable gain restoring for SCO nable restoring o 1 Enabl f jast gain used for 5356 0 3 nable Suit
358. value IDs for optional Parameters If lt Attld gt is not specified then all possible value IDs for all available attributes is returned List of player application attribute value Response pairs See AVPL AVPR Table 2 41 and Table 2 42 Terminator OK ERROR nnn 2 6 6 4 Set commands Table 2 40 AVRCP1 5 set commands AT AVSAl lt n gt Add media item to now playing list lt n gt UidCachelndex 0 9 or UID 16 hex characters prefix not required Parameters The parameter is expected to be chosen from an earlier file system such as AT AVOQFS In particular the UID cache index always refers to the last printed list Note This was tested against PTS only and not against test TG due to lack of support on test TG Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 89 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module AT AVSBP lt n gt Set browsed player Parameters lt n gt player ID decimal hex with prefix Success AVSBP lt plid gt lt nltems gt Failure AVSBP ERROR lt asc gt With lt plid gt browsed player ID confirmation Response lt nitems gt number of items in root folder lt asc gt avrcp status code see Table 2 50 Examples AVSBP 0001 0007 AVSBP ERROR
359. verify that each variant of a group flavour has been loaded and released successfully represented by its appropriate flag BitO STD 01d Bit1 BEX 02d Bit2 WBS 04d So in order to verify success the extra number should always be 7 Example for ATI35 Ezurio Terminal Ver 6 8 0 CTS DSR DCO AI RIS DIR BRK CAPTURES J Open COM38 9600 N 8 1 H5481 ADK2 5 1 HS561 ADK2 5 1 008 HF461 ADK2 5 1 For more information on CVC refer to the application note CVC on BTM51x 2 9 2 SCO eSCO Audio Link SPP SCO BTM modules provide an AT command to establish an SCO eSCO audio connection between a pair of BTM modules or BISM2 This enables the user to create bidirectional audio links independently from a particular Bluetooth profile The only prerequisite is the existence of a Rfcomm link serial port profile SPP between the modules If the SPP link doesn t exist it can be created using AT SPD lt BdAddr gt Refer to SPP Serial Port Profile A SCO eSCO link is intended for bidirectional transmission of speech The sampling rate is normally fixed to 8 kHz meaning a usable bandwidth of 3 5 kHz An exception to this is WBS wideband speech using a sampling rate of 16 kHz and therefore leading to a usable audio bandwidth of up to 7 5 kHz Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 190 Europe 44 1628 858 940 www l
360. vice Selectively Connectable Only Make the module connectable only to the device with the Bluetooth address lt bd_addr gt Connection requests from other devices are rejected If the specified address is 000000000000 incoming connections are accepted from any device This is as per AT BTP without an address The module is not discoverable The setting is valid until next reset or power cycle unless changed by any other AT command thereafter For permanent discoverable connectable settings refer to S Register 512 and AT BTM lt bd_addr gt Response lt cr lf gt OK lt cr lf gt 2 5 10 3 AT BTM lt bd_addr gt Set Incoming Peer Address non vol mem This command stores a peer address for incoming connections in non volatile memory Only the device with Bluetooth address lt bd_addr gt may connect to the module Other devices are rejected The new setting applies immediately and remains over a power cycle because it is copied from non volatile memory to the incoming peer address variable at boot time Any subsequent AT BTP G overwrites or clears the incoming peer address When S 512 3 4 6 or 7 then the module waits for an incoming connection from the peer address specified If lt bd_addr gt is 000000000000 then incoming connections from any devices are permitted Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 34 Europe 44 1628 858 940 www lairdtech com bluet
361. w priority 3 not planned to be supported for future AT firmware 4 service level signalization only 5 planned for future AT firmware release 2 6 8 1 Hands free unit role HF Hands free role is activated by setting flag 0x10 in 102 plus AT amp W plus atz Figure 2 26 is a block diagram of a BTM5xx in hosted operation mode Telephone control Host controller e g set of buttons keypad display Speaker Microphone BTM5xx HF AT command interface license fee applies for CVC algorithms CSR Figure 2 26 Hands free unit block diagram 2 6 8 1 1 Initiate service level connection SLC from HF 1_ 4 2 AT HFD lt bd_addr gt Initiates service level connection SLC from local hands free instance to remote device with lt bd_addr gt The remote device must support the audio gateway role AG of the Hands free profile HFP Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 119 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Response If SLC established lt cr If gt CONNECT 123456789012 111F gt lt cr lf gt lt cr If gt NO CARRIER lt cr lf gt If failed Or lt cr lf gt ERROR 59 lt cr If gt Or lt cr lf gt ERROR 63 lt cr If gt After a SLC connection has been established the module remains in AT command mode S Register 531 is ign
362. ways printed as a hex number The seventh most significant digit can be 0 1 or 2 and specifies the type of device class filter When 0 It specifies no filtering It specifies an AND mask and all 24 bits are relevant When 1 It specifies a filter to look for devices with matching major device class which When 2 occupies a 5 bit field from bits 8 to 12 inclusive assuming numbering starts at bit 0 All other 19 bits must be set to 0 Inquiry Length in units of seconds This parameter is S517 20 2 61 Me referenced by the AT BTI command Maximum number of responses from an inquiry request This parameter is reference by the AT BTI command If this number is set too high then AT BTI returns ERROR 27 For a particular firmware revision determine the 5518 8 0 255 n a effective maximum value by trial and error That is set to a high value send AT BTI and if ERROR 27 is returned then retry with a smaller value This effective max value remains unchanged for that particular firmware build When S507 gt 0 and in a connection DSR can move the module from data to command state by de asserting the ote a D me DSR line for less than the time specified in this register This value is rounded down to the nearest 100 ms Change to a standard baud rate The effect is immediate and in fact the OK is sent at the new baud rate Only one 1200 of the following baud rates are accepted 1200 2400 520 9600
363. with 1 lt BdAddr gt Bluetooth device address of remote device Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 153 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module lt pm gt Profile mask as per 102 four hexadecimal characters with leading lt interval gt Interval of reconnection attempts in seconds lt state gt Status of the ACR 1 Attempting connection at every interval seconds Partly connected at least one profile of pm connected at least one 2 profile of pm not connected attempting to connect the remaining profiles 3 Fully connected all profiles of the ACR connected lt pm_cnct gt Profile mask of actually connected profiles as per S102 four hexadecimal characters with leading lt flags gt Option flags two hexadecimal characters with leading bitmask Always reconnect If this bit is set a normal disconnection yields reconnect attempts If bit is cleared the record is deleted from the ACR table on normal disconnect Only a link loss leaves the entry in the ACR table and allows reconnect attempts Bit2 Always send AVRCP play Bit3 Never send AVRCP play Bit O Example for ATI72 response 1 0016A4001793 0001 005 3 0001 00 2 CO9F43887E15 0180 005 3 0180 00 27 1 5 370 4 Automatic host less ACR m
364. ws Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 125 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module has installed the drivers and has configured the new device we are offered to connect the Stereo Headset Operations as shown in Figure 2 37 Bluetooth Stereo Headset Operations and Settings i 0 3 LONDLR836CE7 Laird BTMM 000000 This computer Disconnected _ Stereo Headset Operations This computer is not connected to a Bluetooth headset Laird BTMM 000000 Connect i Configuration and Settings Figure 2 37 Connect under Stereo Headset Operations After doing so we can see the following FS message FS48000 12S M 48000 Ezurio Terminal Ver 6 8 0 CTS DSR DCD AI RTS DIR BRK CAPTURE Open COM38 9600 N 8 1 FS48000 1I2S_M 48000 APSTR lt Figure 2 38 FS message This shows that the A2DP air rate is 48 kHz audio being routed to 12S master role and 12S rate is 48 kHz Now that air rate and I2S rate are identical 48 kHz no resampling takes actually place The second 48000 still indicates that this fixed sampling rate has been configured by 419 7 2 8 2 4 2 Fixed Sampling Rate Example B In this second example we assume the following External codec with PCM interface Fixed sampling rate 16 kHz SCO co
365. y ATI412 S413 2000 500 4000 GPIO Component of long press duration in milliseconds 500 ms granularity actual value is this value plus S411 S412 actual value is returned by ATI413 S415 0 0 1 MicGain Enable Microphone Input Gain adds extra 24 dB to input gain S416 0 0 1 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 229 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 417 0 0 15 S418 0 0 15 Set sampling rate for Audio Loopback and Fixed sampling rate 0 8 kHz 8 kHz _ 11 025 kHz e 11 025 kHz 2 16 kHz 16 kHz 3 22 05 kHz 22 05 kHz 4 24 kHz 24 kHz 5 32 kHz Mane 32 kHz 6 44 1 kHz 44 1 kHz 1 S419 0 0 7 samping 7 48 Hz rates 1 Only for path I2S_IN gt analogue_out DAC Analogue in ADC does not support a 48 kHz sampling rate 0 Disabled Disabled Disabled _ 1 2 16 kHz 3 5 32 kHz 44 1 kHz 6 Tose 44 1 kHz 7 48 kHz 48 kHz 1 Enable silent operation Setting to 1 forces SO to 1 and suppresses messages arising from connections or pairing E g CONNECT NO aa Hsi Ma CARRIER RING PAIR etc Suppressing connection based messaged allows the device to be configured in cable replacement mode Minimum delay before abandoning connection
366. y be used with indicator IDs 1 service 5 network signal strength 6 roam and 7 battery charge level For call management purposes use the appropriate AT HFGCx command They send call related indicators call call setup call held automatically Table 2 59 AG indicators for AT HFGI Service 1 0 1 4 4 Call 2 0 1 Call setup 3 0 3 All call related sections Call held 4 0 2 Signal 5 0 5 4 5 Roam 6 0 1 4 6 Battery Charge 7 0 5 4 7 2 6 8 2 10 Send operator string to HF COPS 2_4 8 AT HFGO lt operator_string gt Send network operator string to HF by COPS 0 0 lt operator_string gt on SLC This command responds to a AT COPS request indicated by the asynchronous message HFGOP 2 6 8 2 11 Send ERROR or CME ERROR to HF AT HFGE lt cme_code gt Send ERROR to HF if no lt cme_code gt is given Required as optional response to HFG D gt nnn an HFGL to confirm that the dial request was not successful i e invalid memory location or last dialled number not available If the optional lt cme_code gt is appended and if extended AG error result codes were enabled by HF stored internally the appropriate extended error result code in the form of CME ERROR lt cme_code gt is sent to HF If lt cme_code gt is appended but extended error codes have not been enabled by HF lt cme_code gt is ignored and only ERROR is sent to HF 2 6 8 2 12 Change In band ring tone setting when SLC exists
367. y selected tone on incoming RING S388 31 0 94 1 94 messages on SLC ACL for HF only if HFG has disabled in band ringing Tones can be tested using AT SIT lt n gt Input function mapping codes parameter 389 0 0 31 FMC The value is interpreted depending on FMC Currently only input FMC 0x14 refers to this S Register 390 00F7 0 ff AVRCP AVRCP1 5 configuration 0 Do not append hint strings 1 Append hint strings to Play status AVPS Player application settings Hint AVPA AVPV strings Folder type AVFSI Media type AVMEI Media element attribute AVMEA Now playing track attribute AVNPA 0 0x01 Ignored available attributes are not appended to media items AVMEI Reason on the test device extra attributes did not provide Media additional information just element the track name which is attributes already provided but more browsing importantly the extra attribute data was observed to overrun the UART Tx Buffer due to inflated data format for presentation start stop tags etc 1 0x02 Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth Laird Americas 1 800 492 2320 327 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module 0 print displayable names attribute values and other strings in hexadecimal format more machine
368. yed in top right corner of PC screen Figure 2 23 Player should stop Refer to Table 2 28 for more operations Disconnect BTM5 AT AVH Response Figure 2 22 XX i i i If the disconnection is NO CARRIER 110E confirmed Other Diagnostics IT Admin General Security Bluetooth Information Exchanger M Device Information Device Name PCL Device Address 00 1E 37 FA 23 46 Device Type Detail M Tray Icon Bluetooth Radio Power Radio is enabled 6 C Hide Click Button to Disable M Enable Bluetooth Services IV Bluetooth Information Exchange Service J7 PAN Networking Service F Enable DHCP Service Figure 2 18 AVRCP Example 1 Bluetooth Address of PC and AV Remote Control Service Embedded Wireless Solutions Support Center http ews support lairdtech com www lairdtech com bluetooth 59 Laird Americas 1 800 492 2320 Europe 44 1628 858 940 Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module zjx Sii Security Bluetooth Information Exchanger Cather Diagnostics IT Admin F COM Auto Connect Settings COM port settings for fax transmission or dial up accesses Settings AY Player Selection Choose the application to be operated by the AY Remote Control feature AV Profile Copyright Protection Setting Connect only to a device which conform to the SCMS T copy protection method OK Cancel Apply F
369. yer application setting attribute value pair AVSBP Set browsed player confirmation AVSPC Addressed selected player changed notification AVSS System status of remote TG changed notification AVSSP Set addressed selected player confirmation AVTC Track changed notification AVTE Track reached end notification AVTS Track reached start notification AVUC UIDs changed notification AVVC Absolute volume changed indication 2 6 5 2 AVRCP1 5 Quick Start Example For this quick start example a TG device that supports AVRCP 1 4 or higher and A2DP SRC is required Note that AVRCP 1 4 or higher allows the absolute volume feature to work This example was tested against an iPhone as the TG but any recent smartphone that supports these Bluetooth profiles and versions should work AT amp F Factory default settings ATS515 200400 Set device class Make connectable and discoverable after ATS512 4 reset AT amp W Save settings ATZ Reset Embedded Wireless Solutions Support Laird Center http ews support lairdtech com Americas 1 800 492 2320 73 Europe 44 1628 858 940 www lairdtech com bluetooth Hong Kong 852 2923 0610 BTM510 511 User Guide Bluetooth Multimedia Module Search for BT device Laird BTMM and connect Pairing should occur followed by A2DP and AVRCP connection If pairing or connection fails ensure that any previous pairing with BTM51x is deleted i e ignore device and try again

Download Pdf Manuals

image

Related Search

Related Contents

取扱説明書 - シーアンドシー  DForD LuaCoding User`s Manual  b1-2041.  Silvercrest Model SM-09 Floor Plan  Samsung GT-E1105T User Manual  PicoScope 6 User`s Guide  Hotpoint G640 User's Manual      Utica Boilers TriFire TRB 3 Operation and Installation Manual  

Copyright © All rights reserved.
Failed to retrieve file