If you are a device manufacturer or a developer developing applications that work with specific devices (such as wearables or IoT applications), using Fast Pair can help you reduce your workload when you and your end users Pair your device with an Android phone.

In fact, you don’t need to code to enable Fast Pairing, unless you want to handle Pairing in your own companion app rather than having the API do it for you.

There are only three steps in the matching process:

  1. Make sure your peripheral meets all registration requirements.
  2. The device model has been registered with Google.
  3. When users need to pair up, your device will appear on their phone. (As shown in Figure 1, the information collected in Step 1 is presented to the user).

△ Figure 1: Fast Pair connection notification

Once the user sets your peripheral to pair mode, a dialog pops up at the bottom of their Android phone’s interface showing the device name, photo of the device, and a Connect button (see Figure 1).

All your users need to do is click the button to pair their devices, and then they can have a fun and relaxing experience.

The Fast Pair service will also allow users to locate misplaced devices from their phones and even display the battery level of real wireless stereo headphones (TWS).

Finally, Fast Pair can prompt users to install any application that works with the device.

Prerequisites for registration

To ensure that your device can correctly run Fast Pair and provide better user experience, the following conditions must be met:

Personal Privacy & Bluetooth Low Power (BLE)

To protect your user’s privacy and prevent tracking, we require bluetooth Low Power (BLE) with a random resolvable private address (RPA).

The address needs to be updated every 15 minutes and at the beginning of every Advertisement Session. Do not switch the address in pair mode. Switching addresses prevents connections from being established and maintained because the connection is broken when the address is invalid.

Key account

Fast pairs use different account keys (Acount keys) to represent different individual users of peripheral devices. The account key can be mapped to a Gmail address.

Your peripheral needs to store at least five account keys to allow multiple people to use the same device at the same time. For example, parents and children in a family could share a car, and each person would use their Gmail address as the key to their account.

As an added feature, a person using the same Gmail account on multiple Android phones or tablets will also be treated as an account key by Fast Pair. So, if ten different Android devices share the same Gmail account, for Fast Pair, your peripheral doesn’t make any distinction; it recognizes them as the same user.

BLE GATT

Your device should support BLE GATT configuration files with Services and Characteristics.

To use the Fast Pair, you need to define a service whose UUID is 0xFE2C and the following custom Characteristics:

  • Model ID
  • Key-based Pairing
  • Passkey
  • Account Key

The above are in addition to standard Characteristics and any custom Characteristics that can be used to communicate with supporting applications.

If you have a companion application and have installed it on a central device, your custom data will be forwarded to the application. Otherwise, the custom data is ignored.

You can choose to register in the application of the ACTION for the com. Google. Android. GMS. Basis. Fastpair. ACTION_LOG_BUFFER_FULL BroadcastReceiver. This is optional because to use this feature, your peripheral needs to tell the central device that the data buffer is full — which means that the peripheral’s firmware and companion applications need to do some work to perform arbitrary processing on the data.

The headset device

Fast Pair is usually used for headphone devices, which need to support A2DP or HFP. As long as the device supports one of these specifications, Fast Pair will try to connect A2DP first, followed by HFP, after the device binding is complete.

For TWS earphones, the following conditions must be met:

  • The broadcast contains information about the device’s power level.
  • You can customize the device name.

While these conditions are not required for other peripherals, Fast Pair also supports and strongly recommends these conditions.

Have equipment for supporting applications

Fast Pair provides a more general application startup process to support various ancillary devices. In this process, Fast Pair can only discover the nearest device, check the application of the device (if no application has been installed, prompt the user to install it), and guide the user to the specified page of the application. This process does not involve BT binding.

FitBit uses this process to simplify their device configuration. Another example of a device using this process could be a smart scale or an electric toothbrush, which could be used to showcase its companion applications and simplify the out-of-the-box experience.

△ Figure 2: Guide for setting up supporting equipment

Two-way communication

While broadcasting is one-way communication, once your device is successfully connected to a hub device, such as an Android phone, two-way communication becomes possible.

Fast Pair provides an RFCOMM channel for your peripherals to maintain continuous communication with your hub devices. Once connected, switching to classic Bluetooth for two-way communication is perfectly fine.

registered

You need to register the device model with Google as the Fast Pair Provider.

A Fast Pair Provider is a peripheral device (such as a Pair of headphones) that sends pairable broadcasts.

By contrast, Fast Pair Seeker is a hub device — an Android phone or tablet, for example — that looks for other devices to Pair with. The Google Play services framework handles this and doesn’t require any other modules to do anything, so I won’t cover it here.

To register your peripherals, you only need to provide the following:

  • Device name
  • Equipment pictures
  • Equipment transmitted power (TxPower)Measured value

While the name and picture of the device are simple, measuring power takes a little more effort. We recommend that you measure the signal strength of your Bluetooth device at a distance of one meter from your Android phone, and then add 41dBm to your test results.

  • See here for eddystone-UID information.

Submitting TxPower has two options: you can submit it manually at registration, or your device can use it as part of the load data during device broadcasts.

If you provide TxPower for your device during registration, all device units you submit are calibrated to the exact TxPower rating. On the other hand, if you decide to include TxPower information as part of the broadcast record, TxPower levels will be processed on a per-unit basis.

Once registered, we will provide you with a Model ID and an encrypted public/private key pair. As with any asymmetric encryption system, we strongly recommend that you store your private key in a security element (SE) on your device so that an attacker cannot access it.

  • For asymmetric keys, see: Secure Your Application’s Communications from Encryption to Authentication

Your device’s Advertisement Record during the broadcast should include the Model ID provided by Google and the TxPower rating of the device (if not provided at the time of registration).

conclusion

Fast Pair is a service provided by Google as part of the Google Play service to simplify device pairing for Android users. In addition to making matching easier, Fast Pair also offers some other great features, including helping users locate misplaced devices and prompting them to install companion apps. In order to provide the best user experience, the registration process itself is simple, although there are some prerequisites, as it only requires the device name and picture.

Please click here to submit your feedback to us, or share your favorite content or questions. Your feedback is very important to us, thank you for your support!