1/*
2 * Copyright (C) 2021 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17syntax = "proto2";
18package android.uwb;
19
20option java_outer_classname = "UwbProtoEnums";
21option java_multiple_files = true;
22
23// UWB profiles
24enum Profile {
25    UNKNOWN = 0;
26    FIRA = 1;
27    CCC = 2;
28    CUSTOMIZED = 3;
29    ALIRO = 4;
30}
31// UWB scrambled timestamp sequence (STS) type
32enum Sts {
33    UNKNOWN_STS = 0;
34    STATIC = 1;
35    DYNAMIC = 2;
36    PROVISIONED = 3;
37}
38
39// UWB session status codes
40enum Status {
41    STATUS_UNKNOWN = 0;
42    SUCCESS = 1;
43    GENERAL_FAILURE = 2;
44    BAD_PARAMS = 3;
45    REJECTED = 4;
46    SESSION_DUPLICATE = 5;
47    SESSION_EXCEEDED = 6;
48    SERVICE_NOT_FOUND = 7;
49    PROVISION_FAILED = 8;
50}
51
52// UWB ranging session status codes
53enum RangingStatus {
54    RANGING_STATUS_UNKNOWN = 0;
55    RANGING_SUCCESS = 1;
56    RANGING_GENERAL_FAILURE = 2;
57    RANGING_REJECTED = 3;
58    RANGING_BAD_PARAMS = 4;
59    TX_FAILED = 5;
60    RX_PHY_DEC_FAILED = 6;
61    RX_PHY_TOA_FAILED = 7;
62    RX_PHY_STS_FAILED = 8;
63    RX_MAC_DEC_FAILED = 9;
64    RX_MAC_IE_DEC_FAILED = 10;
65    RX_MAC_IE_MISSING = 11;
66}
67
68// UWB session duration buckets
69enum DurationBucket {
70    DURATION_UNKNOWN = 0;
71    WITHIN_ONE_SEC = 1;
72    ONE_TO_TEN_SEC = 2;
73    TEN_SEC_TO_ONE_MIN = 3;
74    ONE_TO_TEN_MIN = 4;
75    TEN_MIN_TO_ONE_HOUR = 5;
76    MORE_THAN_ONE_HOUR = 6;
77}
78
79// UWB count buckets
80enum CountBucket {
81    COUNT_UNKNOWN = 0;
82    ZERO = 1;
83    ONE_TO_FIVE = 2;
84    FIVE_TO_TWENTY = 3;
85    TWENTY_TO_ONE_HUNDRED = 4;
86    ONE_HUNDRED_TO_FIVE_HUNDRED = 5;
87    MORE_THAN_FIVE_HUNDRED = 6;
88}
89
90// Non-Line-of-Sight indication
91enum Nlos {
92    NLOS_UNKNOWN = 0;
93    NLOS = 1;
94    LOS = 2;
95}
96
97// UWB ranging measurement types
98enum RangingType {
99    TYPE_UNKNOWN = 0;
100    ONE_WAY = 1;
101    TWO_WAY = 2;
102    DL_TDOA = 3;
103    OWR_AOA = 4;
104}
105