最新消息: USBMI致力于为网友们分享Windows、安卓、IOS等主流手机系统相关的资讯以及评测、同时提供相关教程、应用、软件下载等服务。

BTM510 511 开发套件 – A2DP 和 AVRCP 快速入门指南说明书

IT圈 admin 27浏览 0评论

2024年10月27日发(作者:东方莎莉)

BTM510/511 Development Kit – A2DP and AVRCP

Quick Start Guide

v1.0

A2DP

S

INK

AVRCP

C

ONTROL

E

XAMPLE

Introduction

This example will demonstrate how to use the BTM511 as an A2DP stereo audio sink and AVRCP controller.

An A2DP source is required. Most smartphones are able to act as a source but please check with your device

manufacturer for information on your specific device.

Requirements

BTM511 development board

USB cable (A-B)

Windows computer

Terminal software such as Ezurio Terminal

Bluetooth A2DP source (such as a Bluetooth mobile phone or PC with media player software)

Speakers or headphones with 3.5 mm jack

FTDI VCP driver

BTM51x firmware 18.1.3.0 or above

Note: Not all phones and computers support Bluetooth A2DP. Check with the manufacturer for A2DP

support.

The development board USB connector provides both power to and serial communications with the module.

You can use the Laird-provided terminal program (Ezurio Terminal) or your own preferred terminal program.

A set of stereo speakers or headphones should be plugged into the stereo out socket on the development

board using a 3.5 mm audio jack.

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

1 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Device Setup

To set up the device, follow these steps:

1. Install the FTDI VCP drivers on your PC.

2. If not already installed, install your preferred terminal program.

3. Connect the USB cable to the computer and development board. Ensure that the development

board switch is set to USB. Windows should find and install the development board as new

hardware.

4. Identify the virtual com port used by the development board using the device manager on a

Windows computer.

5. Connect the speakers to the development board 3.5 mm Stereo Out socket.

6. Open the terminal program and select the virtual com port (9600 8N1) identified earlier.

7. Check to be sure you can communicate by sending “at”. Once you press Enter, you should see OK.

8. Send the commands as shown in Figure 1 to configure the BTM511. Refer to the user manual for

detailed command explanations.

Notes: Commands are shown in lower case, responses from the BTM511 in upper case.

If you power cycle the BTM511, the at+btp command must be resent. All other settings are stored

in non-volatile memory.

Figure 1: BTM511 Configuration Commands

You may need to experiment with the ats515 setting depending on the device acting as a source; this is the

Bluetooth Class of Device (COD) which describes the general characteristics and capabilities of a device. The

COD does not reliably indicate which profiles or services are actually available. There are numerous possible

combinations but typical values of ats515 could include $200400 (generic audio), $200414 (loudspeaker),

and $200418 (headphones).

Discovery and Pairing

The BTM511 is now ready to be discovered by your Bluetooth A2DP source device.

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

2 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Because different devices handle pairing in different ways, it is not possible to provide step-by-step

instructions for a specific device. Typically, you need to go to the device’s settings screen and select

Bluetooth; this should allow you to search for and pair with the module.

If your source device uses legacy pairing, you must enter the pairing PIN as 1234 on your source device when

prompted. This PIN was previously setup on the BTM511 with the at+btk= command.

Source devices that support Bluetooth 2.1 (most recent smartphones do) use simple secure pairing (SSP). For

these devices, you receive a prompt on both the source device and from the BTM511 as shown in Figure 2:

Figure 2: SSP Prompts

PAIR ?

BCB1F3781D4F

Galaxy Nexus

056029

Indicates an incoming pair request

BT address of the source device

Its ‘friendly name’

A random six-digit number displayed on both devices

Accept the pairing request on the source device and then accept the pairing request on the BTM511 by

sending at+btby, if required. Some devices may pair automatically without prompting depending on their

security settings. The BTM511 pairing settings can be configured with various levels of security and user

interaction. Please refer to the user manual for more details.

A successful pairing is indicated by a PAIR 0 message.

Connecting

At this point you may see two connect messages: one for A2DP (UUID:0x110D) and one for AVRCP

(UUID:0x110E). If the connect messages do not appear, you must manually connect from your source device;

please refer to the manufacturer’s instructions if this issue occurs. Most smartphones will automatically

connect.

From your source device, begin audio streaming by opening the media player and playing a music track. You

should hear the track from the speakers/headphones connected to the development board rather than from

the source devices own internal speaker.

Once the audio is streaming you will receive a message indicating the current sampling frequency (Figure 3).

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

3 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Figure 3: Current sampling frequency

In this example:

44100

INT

Refers to 44100 khz

Indicates that an internal codec is being used

Figure 4: Audio output gain and connection status

at+god

at+gou

ati61

1

Control the audio output gain

Sent to determine the status of the connection

Indicates that A2DP is connected

Remote Control

AVRCP can be used to control the source device media player from the BTM511. See Figure 5.

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

4 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Figure 5: AVRCP Commands

at+avc45

at+avc44

Stop media playback

Start playback

Figure 6: Skip back and playback commands

at+avc4c

at+avc46

Skip back

Pause playback

Note: Not all commands may be supported by all devices.

Disconnecting

The command ath* can be used to drop the all current Bluetooth connections. As each connection drops, a

corresponding No Carrier message displays (Figure 7).

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

5 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Figure 7: Disconnection commands

Resources

FTDI Driver: /Drivers/

Ezurio terminal: /zips/Bluetooth%20Terminal%

Support: /Products/Wireless-M2M-and-Telematics-Solutions/Bluetooth-Module/

BTM511 User Manual: /WorkArea/?LinkIdentifier=id&ItemID=5114

R

EVISION

H

ISTORY

Revision

1.0

Date

20 June 2013

Description

Initial Release

Initiated By

Jonathan Kaye

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

6 Laird Technologies

2024年10月27日发(作者:东方莎莉)

BTM510/511 Development Kit – A2DP and AVRCP

Quick Start Guide

v1.0

A2DP

S

INK

AVRCP

C

ONTROL

E

XAMPLE

Introduction

This example will demonstrate how to use the BTM511 as an A2DP stereo audio sink and AVRCP controller.

An A2DP source is required. Most smartphones are able to act as a source but please check with your device

manufacturer for information on your specific device.

Requirements

BTM511 development board

USB cable (A-B)

Windows computer

Terminal software such as Ezurio Terminal

Bluetooth A2DP source (such as a Bluetooth mobile phone or PC with media player software)

Speakers or headphones with 3.5 mm jack

FTDI VCP driver

BTM51x firmware 18.1.3.0 or above

Note: Not all phones and computers support Bluetooth A2DP. Check with the manufacturer for A2DP

support.

The development board USB connector provides both power to and serial communications with the module.

You can use the Laird-provided terminal program (Ezurio Terminal) or your own preferred terminal program.

A set of stereo speakers or headphones should be plugged into the stereo out socket on the development

board using a 3.5 mm audio jack.

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

1 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Device Setup

To set up the device, follow these steps:

1. Install the FTDI VCP drivers on your PC.

2. If not already installed, install your preferred terminal program.

3. Connect the USB cable to the computer and development board. Ensure that the development

board switch is set to USB. Windows should find and install the development board as new

hardware.

4. Identify the virtual com port used by the development board using the device manager on a

Windows computer.

5. Connect the speakers to the development board 3.5 mm Stereo Out socket.

6. Open the terminal program and select the virtual com port (9600 8N1) identified earlier.

7. Check to be sure you can communicate by sending “at”. Once you press Enter, you should see OK.

8. Send the commands as shown in Figure 1 to configure the BTM511. Refer to the user manual for

detailed command explanations.

Notes: Commands are shown in lower case, responses from the BTM511 in upper case.

If you power cycle the BTM511, the at+btp command must be resent. All other settings are stored

in non-volatile memory.

Figure 1: BTM511 Configuration Commands

You may need to experiment with the ats515 setting depending on the device acting as a source; this is the

Bluetooth Class of Device (COD) which describes the general characteristics and capabilities of a device. The

COD does not reliably indicate which profiles or services are actually available. There are numerous possible

combinations but typical values of ats515 could include $200400 (generic audio), $200414 (loudspeaker),

and $200418 (headphones).

Discovery and Pairing

The BTM511 is now ready to be discovered by your Bluetooth A2DP source device.

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

2 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Because different devices handle pairing in different ways, it is not possible to provide step-by-step

instructions for a specific device. Typically, you need to go to the device’s settings screen and select

Bluetooth; this should allow you to search for and pair with the module.

If your source device uses legacy pairing, you must enter the pairing PIN as 1234 on your source device when

prompted. This PIN was previously setup on the BTM511 with the at+btk= command.

Source devices that support Bluetooth 2.1 (most recent smartphones do) use simple secure pairing (SSP). For

these devices, you receive a prompt on both the source device and from the BTM511 as shown in Figure 2:

Figure 2: SSP Prompts

PAIR ?

BCB1F3781D4F

Galaxy Nexus

056029

Indicates an incoming pair request

BT address of the source device

Its ‘friendly name’

A random six-digit number displayed on both devices

Accept the pairing request on the source device and then accept the pairing request on the BTM511 by

sending at+btby, if required. Some devices may pair automatically without prompting depending on their

security settings. The BTM511 pairing settings can be configured with various levels of security and user

interaction. Please refer to the user manual for more details.

A successful pairing is indicated by a PAIR 0 message.

Connecting

At this point you may see two connect messages: one for A2DP (UUID:0x110D) and one for AVRCP

(UUID:0x110E). If the connect messages do not appear, you must manually connect from your source device;

please refer to the manufacturer’s instructions if this issue occurs. Most smartphones will automatically

connect.

From your source device, begin audio streaming by opening the media player and playing a music track. You

should hear the track from the speakers/headphones connected to the development board rather than from

the source devices own internal speaker.

Once the audio is streaming you will receive a message indicating the current sampling frequency (Figure 3).

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

3 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Figure 3: Current sampling frequency

In this example:

44100

INT

Refers to 44100 khz

Indicates that an internal codec is being used

Figure 4: Audio output gain and connection status

at+god

at+gou

ati61

1

Control the audio output gain

Sent to determine the status of the connection

Indicates that A2DP is connected

Remote Control

AVRCP can be used to control the source device media player from the BTM511. See Figure 5.

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

4 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Figure 5: AVRCP Commands

at+avc45

at+avc44

Stop media playback

Start playback

Figure 6: Skip back and playback commands

at+avc4c

at+avc46

Skip back

Pause playback

Note: Not all commands may be supported by all devices.

Disconnecting

The command ath* can be used to drop the all current Bluetooth connections. As each connection drops, a

corresponding No Carrier message displays (Figure 7).

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

5 Laird Technologies

BTM510/511 Development Kit – A2DP and AVRCP

Application Note

Figure 7: Disconnection commands

Resources

FTDI Driver: /Drivers/

Ezurio terminal: /zips/Bluetooth%20Terminal%

Support: /Products/Wireless-M2M-and-Telematics-Solutions/Bluetooth-Module/

BTM511 User Manual: /WorkArea/?LinkIdentifier=id&ItemID=5114

R

EVISION

H

ISTORY

Revision

1.0

Date

20 June 2013

Description

Initial Release

Initiated By

Jonathan Kaye

Americas: +1-800-492-2320 Option 3

Europe: +44-1628-858-940

Hong Kong: +852 2923 0610

/wireless

6 Laird Technologies

发布评论

评论列表 (0)

  1. 暂无评论