Exposure Notifications BLE RSSI calibration procedure

This topic shares the Exposure Notifications calibration procedure that uses the BLE RSSI Calibration Tool app (the calibration app, for short) to calibrate as many devices as possible, generating a per-device TX_power and RSSI_correction.

Background

To accurately determine how close users have been to each other and whether there may have been a risk of exposure, an app needs to estimate the distance between two devices, using Bluetooth Low Energy (BLE) received signal strength indicator (RSSI) measurements. Many factors affect an RSSI measurement, including antenna sensitivity, device orientation, and environmental conditions.

This document describes the Exposure Notifications framework’s calibration methodology, which includes collecting data with phones in different orientations. This data is then used to estimate calibration values. In earlier versions of the calibration procedure, most measurements were done with the devices in portrait mode, placed back to back and one meter apart.

Data collected

To gather the data necessary for TX_power calculations, the app collects the uncalibrated RSSI that a stationary reference device (a Pixel 4) measures when the device under test (DUT) emits packets at ULTRA_LOW_POWER, LOW_POWER, MEDIUM_POWER, and HIGH_POWER. The DUT and the reference device are placed 1 meter apart. The calibration app takes the median of 10 RSSI measurements at each power level. Similarly, to calculate the RSSI_correction, the app takes the median of 10 uncalibrated RSSI measurements that a DUT measures when the reference device emits packets at a given power level.

Those measurements are collected for both the DUT and a reference DUT (another Pixel 4), so that the transmit power and the receive sensitivity of the DUT and the reference DUT can be compared.

The calibration app collects each of these measurements at 12 device orientations, as described in the next section.

Device orientation and setup illustrations

Because RSSI readings can vary about 10 dB based only on device orientation, it’s important to get enough readings at different orientations to calculate a good overall correction. We are requesting calibrations at 12 different orientations per DUT. The next section illustrates the details of the different orientations and angles.

Photo that shows the tripods used to test devices
Figure 1. Testing configuration.

Photo that shows device at various degrees of rotation (portrait)
Figure 2. Device orientations in portrait mode.

Photo that shows device at various degrees of rotation (landscape)
Figure 3. Device orientation in landscape mode.

Photo that shows device at various degrees of rotation (facing skyward)
Figure 4. Device orientation when facing skyward.

Periodic reference calibrations

After you test five devices, use a Pixel 4 as the next DUT. Then you can test five more devices before testing a Pixel 4 again, and so on. Using a Pixel 4 as the DUT every six tests helps ensure that we can adjust for any changes in the test setup.

A flowchart showing frequency of calibration tests
Figure 5. Performing reference calibrations.

Detailed instructions

Hardware prerequisites

  • Two Pixel 4 devices:

    • One as the stationary reference device.
    • The other as the DUT every sixth time between your regular DUTs.

    Important: Use the Pixel 4, not the larger Pixel 4 XL.

  • The DUTs to be calibrated

  • Two tripods to hold the devices

    • Use stationary, non-reflective tripods to avoid affecting RF measurements.
    • Important: Don’t hold the devices. Do configure the setup so that it’s repeatable.

To ensure the tests are valid, make sure your reference device and all of your DUTs have the following:

  • Production hardware and software; that is, the hardware and software that users will have in the field
  • A full charge

Software prerequisites

Download the RSSI Calibration app and install the APK on all of the DUTs and the reference device.

Environment requirements

  • Calibrate these devices in a radio-frequency (RF) anechoic chamber to prevent electromagnetic interference.
  • If an RF anechoic chamber isn’t available, then we recommend testing outdoors in a dry environment, far away from objects (buildings, cars, trees, heavy vegetation, and so on).
  • Stand a few meters away from the test setup while the calibrations are running. To ensure a consistent reading, stand in the same position each time so that the impact of your body is identical between tests.

Device setup

  • Set up the two tripods holding the DUT and reference device 1 meter apart, with the devices 1.5 meters from the ground.
  • Make sure the reference device and all DUTs are charged.
    • Both the reference device and the current DUT must be unplugged during testing.
    • Both the reference device and the current DUT must have at least 20% charge throughout testing.
  • Make sure the reference device and the DUTs have no cases, no attached wires, and nothing else attached that might affect RF performance.
  • Orient the reference device (Pixel 4) in portrait mode with the back of the device facing the DUT.
  • When running the test, you will orient the DUT using the following sequence (which is illustrated in figure 2):
    1. Portrait 0o (screen facing the reference device)
    2. Portrait 90o (rotated 90 degrees counterclockwise from previous orientation)
    3. Portrait 180o
    4. Portrait 270o
    5. Landscape 0o (screen facing the reference device)
    6. Landscape 90o
    7. Landscape 180o
    8. Landscape 270o
    9. Sky facing 0o (left of the screen pointing to the reference device)
    10. Sky facing 90o
    11. Sky facing 180o
    12. Sky facing 270o (final test for this DUT)

Collect calibration data

  1. Ensure that the batteries of the reference device (Pixel 4) and the DUT are full or nearly full. (At a minimum, the battery levels should be above 20% throughout the calibration tests.)

  2. Launch the BLE RSSI Calibration Tool app on both devices. Important: Begin the calibrations with a Pixel 4-to-Pixel 4 configuration, in addition to calibrating with Pixel 4 after every five unique DUT calibrations.

  3. If prompted, allow the app to access the device’s location; this permission is necessary for BLE scans.

  4. On the reference device: go to the Settings tab, enable Set as reference device.


    Figure 6: Reference device set.

  5. On each device, go to the Calibration tab. The user interface on each device should look like this:


    Figure 7: Calibration screen.

  6. DUT: Make sure BLE ON/OFF is enabled (as in figure 7).

  7. Reference device: Tap the Scan button. Wait for the reference device to find the DUT.


    Figure 8: Reference device has found the DUT.

  8. If you minimize the scan window by clicking on the magnifying glass icon, the device shows the orientation for the current calibration.


    Figure 9: Calibration is complete.

  9. Reference device: Tap the Calibrate button.

    • During the calibration, you can stop the calibration by tapping the Stop button. Resume calibrating by tapping the Calibrate button.
    • The calibration goes through four power levels. Each power level takes around 10 seconds for a total calibration time for each orientation, equaling 40 seconds (4 x 10). A counter on the bottom left shows the calibration progress.
    • Once the calibration is complete, Complete with a checkbox next to it appears.
  10. Tap Next to move to the next device orientation calibration. You can revisit previous calibrations by tapping Previous.


    Figure 10: Working through the orientations.

    After completing the calibrations for all 12 orientations, you may set up and restart the calibration process for a new device. The app automatically appends the results for the next device.

  11. When you have completed calibrating all of your devices, tap the Submit tab. This displays a row showing the DUT(s) you measured.


    Figure 11: Submit tab tapped after completed calibration.

  12. Tap the Submit button and choose an email option in the Android Sharesheet.

    The calibration app generates an email with a file named reports.csv attached.


    Figure 12: Email generated by the system.

  13. Send the email to yourself so that you can collect the reports to submit to us. If email isn't an option, the Sharesheet also presents an option to upload the reports.csv to a Google Drive account to access later.

  14. DUT: In the Calibration tab, disable BLE ON/OFF to ensure that this device isn't found when you calibrate the next device.

Submitting data to Google

When you’ve finished calibrating the devices, create a zip archive containing the reports.csv files that the calibration app generated and photos of your calibration setup from your first device calibration. Either submit this zip file to the RSSI calibration Buganizer issue filed by Google, or, if you don't have a Buganizer issue, email the zip file to project-apollo-calibration@google.com. If it's not clear from your photos, let us know the environment in which you performed calibrations: indoor, outdoor, or anechoic chamber.