Gazell Pairing

The Gazell pairing library enables applications to use the Gazell Link Layer to provide a secure wireless link between Gazell nodes. The library is customized for pairing a Device (for example, a mouse, keyboard, or remote control) with a Host (typically a USB dongle) using Gazell.

Overview

Gazell Pairing determines the channel set used by Gazell. See the Gazell Pairing user guide for more information, such as the features of this library.

This library is used in the Gazell Dynamic Pairing Host and Gazell Dynamic Pairing Device samples.’

Requirements

The Gazell Pairing library requires the same resources as the Gazell Link Layer.

In addition, the Gazell Pairing library also employs three nRF52 Series peripherals:

  • Random Number Generator, for generating keys and tokens.

  • AES Electronic Codebook (ECB), for encryption and decryption.

  • Non-Volatile Memory Controller (NVMC), for storing of pairing parameters.

In addition, Gazell Pairing requires the Gazell Link Layer resource of two pipes: one for pairing and one for encrypted data transmission.

Since Gazell Pairing requires exclusive access to pipes 0 and GZP_DATA_PIPE (default pipe 1), it must control the internal Gazell Link Layer variables base_address_0, base_address_1 and prefix_address_byte for pipes GZP_PAIRING_PIPE (always pipe 0) and GZP_DATA_PIPE (configurable).

  • The main application can use the pipes 2-7.

  • The base_address_1 applies to these pipes.

  • Gazell Pairing must also determine whether the RX pipes 0 and 1 are enabled.

Note

Make sure not to affect the rx_enabled status of these pipes.

Do not access the following:

  • nrf_gzll_set_base_address_0()

  • nrf_gzll_set_base_address_1()

  • nrf_gzll_set_address_prefix_byte() (not for pipes 0 and 1)

  • nrf_gzll_set_rx_pipes_enabled() (can be used but the enabled status of pipes 0 and 1 should not be modified)

  • nrf_gzll_set_channel_table()

Configuration

Complete the following steps for configuration:

  1. The prerequisite Gazell Link Layer should be enabled as described in the Gazell Link Layer Configuration section.

  2. Set the CONFIG_GAZELL_PAIRING Kconfig option to enable the Gazell Pairing.

  3. Select the role by either of the following Kconfig options:

    1. CONFIG_GAZELL_PAIRING_DEVICE - Device.

    2. CONFIG_GAZELL_PAIRING_HOST - Host.

To support persistent storage of pairing data, set the CONFIG_GAZELL_PAIRING_SETTINGS Kconfig option.

To support encryption, set the CONFIG_GAZELL_PAIRING_CRYPT Kconfig option.

API documentation

Header file: include/gzp.h and include/gzp_config.h
Source file: subsys/gazell/
Gazell Pairing