nRF Connect SDK API 2.8.99
Loading...
Searching...
No Matches
ras.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2024 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5 */
6
7#ifndef BT_RAS_H_
8#define BT_RAS_H_
9
10#include <stdint.h>
11#include <zephyr/kernel.h>
12#include <zephyr/bluetooth/conn.h>
13#include <zephyr/bluetooth/uuid.h>
14
21#ifdef __cplusplus
22extern "C" {
23#endif
24
26#define BT_UUID_RANGING_SERVICE_VAL (0x185B)
27
29#define BT_UUID_RAS_FEATURES_VAL (0x2C14)
30
32#define BT_UUID_RAS_REALTIME_RD_VAL (0x2C15)
33
35#define BT_UUID_RAS_ONDEMAND_RD_VAL (0x2C16)
36
38#define BT_UUID_RAS_CP_VAL (0x2C17)
39
41#define BT_UUID_RAS_RD_READY_VAL (0x2C18)
42
44#define BT_UUID_RAS_RD_OVERWRITTEN_VAL (0x2C19)
45
46#define BT_UUID_RANGING_SERVICE BT_UUID_DECLARE_16(BT_UUID_RANGING_SERVICE_VAL)
47#define BT_UUID_RAS_FEATURES BT_UUID_DECLARE_16(BT_UUID_RAS_FEATURES_VAL)
48#define BT_UUID_RAS_REALTIME_RD BT_UUID_DECLARE_16(BT_UUID_RAS_REALTIME_RD_VAL)
49#define BT_UUID_RAS_ONDEMAND_RD BT_UUID_DECLARE_16(BT_UUID_RAS_ONDEMAND_RD_VAL)
50#define BT_UUID_RAS_CP BT_UUID_DECLARE_16(BT_UUID_RAS_CP_VAL)
51#define BT_UUID_RAS_RD_READY BT_UUID_DECLARE_16(BT_UUID_RAS_RD_READY_VAL)
52#define BT_UUID_RAS_RD_OVERWRITTEN BT_UUID_DECLARE_16(BT_UUID_RAS_RD_OVERWRITTEN_VAL)
53
54#define BT_RAS_RANGING_HEADER_LEN 4
55#define BT_RAS_SUBEVENT_HEADER_LEN 8
56#define BT_RAS_STEP_MODE_LEN 1
57#define BT_RAS_MAX_STEP_DATA_LEN 35
58
64 uint16_t ranging_counter : 12;
66 uint8_t config_id : 4;
77} __packed;
78BUILD_ASSERT(sizeof(struct ras_ranging_header) == BT_RAS_RANGING_HEADER_LEN);
79
131BUILD_ASSERT(sizeof(struct ras_subevent_header) == BT_RAS_SUBEVENT_HEADER_LEN);
132
133#ifdef __cplusplus
134}
135#endif
136
141#endif /* BT_RAS_H_ */
#define BT_RAS_SUBEVENT_HEADER_LEN
Definition ras.h:55
#define BT_RAS_RANGING_HEADER_LEN
Definition ras.h:54
uint16_t ranging_counter
Definition ras.h:64
uint8_t antenna_paths_mask
Definition ras.h:76
uint8_t config_id
Definition ras.h:66
int8_t selected_tx_power
Definition ras.h:68
Ranging Header structure as defined in RAS Specification, Table 3.7.
Definition ras.h:60
uint8_t subevent_abort_reason
Definition ras.h:123
uint8_t ranging_abort_reason
Definition ras.h:112
int8_t ref_power_level
Definition ras.h:125
uint8_t subevent_done_status
Definition ras.h:101
uint8_t ranging_done_status
Definition ras.h:95
uint16_t freq_compensation
Definition ras.h:88
uint8_t num_steps_reported
Definition ras.h:129
uint16_t start_acl_conn_event
Definition ras.h:83
Subevent Header structure as defined in RAS Specification, Table 3.8.
Definition ras.h:81