Our website is under construction. Please stay tuned!

leaps_mac_addr_get

Get the MAC address list used by the device. The device uses either the address specified by the user or the default address. The default MAC address for each interface can be changed only once by calling leaps_mac_addr_set_once in which case it is written to OTP memory and becomes a new default MAC address. The user can set a custom MAC address by calling leaps_mac_addr_set. The default MAC address can be recovered by factory reset (see leaps_factory_reset) after being modified by the user. The device uses fixed mapping of the MAC address in list to the particular interface as follows:

  1. UWB

  2. BL

  3. Ethernet

  4. Wi-Fi

The BLE address can be Random BLE address or Public BLE address. If a particular interface is not supported, the corresponding MAC address in the list is empty.


Input
  • (none)

Output
  • err_code

  • type_0: ? 8-bit unsigned integer ? (type describing the MAC address at index 0 in the list)

  • mac_addr_0: ? 48-bits value ? (little endian)


SPI/UART example

TLV request

type

length

0x83

0x00

Type 0x83 (131 dec) means command leaps_mac_addr_get

TLV response

Type

Length

Value (see error codes)

Type

Length

Value

(byte 0-4) flags of the MAC address list in little endian
(byte 5-10) MAC address 0 in little endian
(byte 11-16) MAC address 1 in little endian
(byte 17-22) AC address 2 in little endian
(byte 23-28) MAC address 3 in little endian

0x40

0x01

0x00

0x41

0x0D

Type 0x40 means err_code of the previous command

Type 0xC1(193 dec) means MAC address list

MAC address flags encoding

flags of the MAC address list

byte 0

byte 1

byte 2

byte 3

bits 2-7

bits 0-1

bits 11-15

bits 10

bits 8-9

bits 18-23

bits 16-17

bits 26-31

bits 24-25

R

S_0

R

P_1

S_1

R

S_2

R

S_3

T_0, T_1, T_2, T_3 describe the MAC address status.

  • 0 - Empty MAC address

  • 1 - Default MAC address from OTP memory.

  • 2 - User specified MAC address

  • 3 - Mutable default MAC address which can be rewritten only once using leaps_mac_addr_set_once.

P_1 is set if the BLE address is the Public BLE address. The flag is cleared if the BLE MAC address is random, refer to BLE specification for more information on BLE address types.