1/* 2 * Copyright (C) 2024 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 = "proto3"; 18 19package com.android.ranging.generic.proto; 20 21option java_package = "com.android.ranging.generic.proto"; 22option java_multiple_files = true; 23 24 // Next ID: 14 25 message Estimate { 26 enum Status { 27 UNSPECIFIED = 0; 28 // An estimate was successfully computed. 29 OK = 1; 30 // Could not produce an estimate. For example, no synchronized set of data 31 // is available. 32 ESTIMATE_NOT_AVAILABLE = 2; 33 // The filter has diverged and is attempting to recover. 34 RECOVERING = 3; 35 // Odometry failed and cannot recover. 36 ODOMETRY_ERROR = 4; 37 // The beacon is probably moving, and so cannot be tracked. 38 BEACON_MOVING_ERROR = 5; 39 // The configuration file contains an error and Finder can't be started. 40 CONFIGURATION_ERROR = 6; 41 // Permissions not granted to required sensors. 42 SENSOR_PERMISSION_DENIED = 7; 43 UNKNOWN_ERROR = 8; 44 // Tracking failed due to insufficient light. This can occur when using 45 // camera based odometry. The filter will automatically recover and produce 46 // an estimate when possible. 47 RECOVERING_FROM_FAILURE_DUE_TO_INSUFFICIENT_LIGHT = 9; 48 // Tracking failed due to excessive motion. The filter will automatically 49 // recover and produce an estimate when possible. 50 RECOVERING_FROM_FAILURE_DUE_TO_EXCESSIVE_MOTION = 10; 51 // Tracking failed due to insufficient features in the camera images. This 52 // can occur when using camera based odometry. The filter will automatically 53 // recover and produce an estimate when possible. 54 RECOVERING_FROM_FAILURE_DUE_TO_INSUFFICIENT_FEATURES = 11; 55 // Tracking failed because something else is using the camera. Tracking will 56 // recover automatically, but with a new origin. 57 RECOVERING_FROM_FAILURE_DUE_TO_CAMERA_UNAVAILABILITY = 12; 58 // Tracking failed due to a bad odometry state. The filter will 59 // automatically recover and produce an estimate when possible. 60 RECOVERING_FROM_FAILURE_DUE_TO_BAD_ODOMETRY_STATE = 13; 61 } 62 Status status = 1; 63 double range_m = 2; 64 double range_error_std_dev_m = 3; 65 // The bearing is with respect to the device Y-axis, positive ccw. 66 double bearing_rad = 4; 67 // This measure usually increases as you move closer to the beacon. 68 double bearing_error_std_dev_rad = 5; 69 // This measure does not vary with the distance to the beacon. 70 double estimated_beacon_position_error_std_dev_m = 7; 71 int64 timestamp_nanos = 6; 72 } 73