leaps_usr_data_read
Read user data from the node. To be notified on new user data received on the UART/SPI or BLE enable corresponding event by leaps_int_cfg_set and leaps_ble_evt_cfg_set respectively which will set dedicated flag in the status and also cause generation of an event on UART/SPI or BLE.
type: ? 2 bits ? (user data type)
‘0’ means read user data that has been written to UWB interface from other interfaces like BLE, SPI, UART
‘1’ means read user data that has been written to BLE interface from other interfaces like UWB, SPI, UART
‘2’ means read user data from non volatile memory
data: (the user data bytes up to 250 bytes depending on the type)
Example 1 (read UWB user data)
TLV Request |
||
---|---|---|
Type |
Length |
Value |
0x19 |
0x01 |
0x00 |
Type 0x19 (25 dec) means command leaps_usr_data_read
TLV response |
|||||
---|---|---|---|---|---|
Type |
Length |
Value |
Type |
Length |
Value |
max 34 bytes |
|||||
0x40 |
0x01 |
0x00 |
0x4B |
0x22 |
0x01 0x02 0x03 … 0x23 0x22 |
Type 0x4B means UWB user data
Example 2 (read BLE user data)
TLV Request |
||
---|---|---|
Type |
Length |
Value flags |
0x19 |
0x01 |
0x01 |
Type 0x19 (25 dec) means command leaps_usr_data_read
TLV response |
|||||
---|---|---|---|---|---|
Type |
Length |
Value |
Type |
Length |
Value |
max 128 bytes |
|||||
0x40 |
0x01 |
0x00 |
0x51 |
0x80 |
0x01 0x02 0x03 … 0x7F 0x80 |
Type 0x51 means BLE user data
Example 3 (read user data stored in non volatile memory)
TLV Request |
||
---|---|---|
Type |
Length |
Value flags |
0x19 |
0x01 |
0x02 |
Type 0x19 (25 dec) means command leaps_usr_data_read
TLV response |
|||||
---|---|---|---|---|---|
Type |
Length |
Value |
Type |
Length |
Value |
max 250 bytes |
|||||
0x40 |
0x01 |
0x00 |
0x58 |
0x80 |
0x01 0x02 0x03 … 0xFA |
Type 0x58 (88 dec) means user data stored in non-volatile memory