Saturday, August 17, 2019

Bluetooth device address for BLE devices


BLE Device Address

BLE devices are identified by 48 bit device address. This address could either be a public device address or random device address. A device shall  have at-least one address however  it can have both.


Public Address

Public device shall be created according to IEEE standard and should have following format:

Random Address  

Random address could be of following sub types :
  1. Static Address
  2. Private Address
The term random address  refers to both static and random address.

Static Address 

A static device address is randomly generated 48 bit address with following requirements :

  • 2 most significant bits of the address shall be equal to 1 .
  • All bits of the random address shall not be equal to 1.
  • All bits of random address shall not be equal to 0.
This is the format for static address:

  •  A device may choose to initialize its static address to new value at power cycle. A device shall not change its static address once its initialized till its power cycled again.

Private Address

Private Address could be of  2 types:
  • Resolvable Private Address(RPA)
  • Non Resolvable Private Address (Non RPA)

Resolvable Private Address

 Resolvable private address format is as shown below :



To generate a resolvable private address , device must either have the Local Identity Resolving key or peer Identity Resolving Key. Resolvable Private Address shall be generated with IRK and 24 bit random number known as prand. The hash is generated with random address function.

 Non Resolvable Private Address

Format of non resolvable private address format is as shown below:

 

Non Resolvable Private Address should meet following requirements
  • Two most significant bytes should be equal to zero.
  • all bits of random part of the address shall not be equal to 1.
  • All bits of random part of the address shall not e equal to 0.
  • The address shall not be equal to public address.