1syntax = "proto2";
2
3package wireless.android.platform.testing.bluetooth.metrics;
4
5message BluetoothTestDevice {
6  optional string device_class = 1;
7  optional string device_model = 2;
8  optional string hardware_version = 3;
9  optional string software_version = 4;
10  optional string android_build_type = 5;
11  optional string android_branch_name = 6;
12  optional string android_build_number = 7;
13  optional string android_release_id = 8;
14}
15
16message BluetoothContinuousTestResultHeader {
17  optional int64 test_date_time = 1;
18  optional BluetoothTestDevice primary_device = 2;
19  optional BluetoothTestDevice connected_device = 3;
20}
21
22message BluetoothReconnectTestResult {
23  optional BluetoothContinuousTestResultHeader configuration_data = 1;
24  optional int32 connection_attempt_count = 2;
25  optional int32 connection_successful_count = 3;
26  optional int32 connection_failed_count = 4;
27  optional int32 connection_max_time_millis = 5;
28  optional int32 connection_min_time_millis = 6;
29  optional int32 connection_avg_time_millis = 7;
30  optional int32 acl_connection_max_time_millis = 8;
31  optional int32 acl_connection_min_time_millis = 9;
32  optional int32 acl_connection_avg_time_millis = 10;
33}
34
35message BluetoothPairAndConnectTestResult {
36  optional BluetoothContinuousTestResultHeader configuration_data = 1;
37  optional int32 pair_attempt_count = 2;
38  optional int32 pair_successful_count = 3;
39  optional int32 pair_failed_count = 4;
40  optional int32 pair_max_time_millis = 5;
41  optional int32 pair_min_time_millis = 6;
42  optional int32 pair_avg_time_millis = 7;
43  optional int32 first_connection_max_time_millis = 8;
44  optional int32 first_connection_min_time_millis = 9;
45  optional int32 first_connection_avg_time_millis = 10;
46}
47
48message BluetoothA2dpCodecConfig {
49  enum BluetoothA2dpCodec {
50    SBC = 0;
51    AAC = 1;
52    APTX = 2;
53    APTX_HD = 3;
54    LDAC = 4;
55  }
56  optional BluetoothA2dpCodec codec_type = 1;
57  optional int32 sample_rate = 2;
58  optional int32 bits_per_sample = 3;
59  optional int32 channel_mode = 4;
60}
61
62message AudioTestDataPoint {
63  optional int64 timestamp_since_beginning_of_test_millis = 1;
64  optional int64 audio_streaming_duration_millis = 2;
65  optional int32 attenuation_db = 3;
66  optional float total_harmonic_distortion_plus_noise_percent = 4;
67  optional int32 audio_glitches_count = 5;
68}
69
70message BluetoothAudioTestResult {
71  optional BluetoothContinuousTestResultHeader configuration_data = 1;
72  enum AudioProfile {
73    A2DP = 0;
74    HFP = 1;
75    HAP = 2;
76  }
77  optional AudioProfile audio_profile = 2;
78  optional int32 audio_latency_min_millis = 3;
79  optional int32 audio_latency_max_millis = 4;
80  optional int32 audio_latency_avg_millis = 5;
81  optional int32 audio_glitches_count = 6;
82  optional int32 audio_missed_packets_count = 7;
83  optional float total_harmonic_distortion_plus_noise = 8;
84  optional int64 audio_streaming_duration_millis = 9;
85  optional BluetoothA2dpCodecConfig a2dp_codec_config = 10;
86  repeated AudioTestDataPoint data_points = 11;
87}
88
89message BluetoothDataTestResult {
90  optional BluetoothContinuousTestResultHeader configuration_data = 1;
91  enum DataTransferProtocol {
92    RFCOMM = 0;
93    L2CAP = 1;
94    LE_COC = 2;
95  }
96  optional DataTransferProtocol data_transfer_protocol = 2;
97  optional int32 data_latency_min_millis = 3;
98  optional int32 data_latency_max_millis = 4;
99  optional int32 data_latency_avg_millis = 5;
100  optional int32 data_throughput_min_bytes_per_second = 6;
101  optional int32 data_throughput_max_bytes_per_second = 7;
102  optional int32 data_throughput_avg_bytes_per_second = 8;
103  optional int32 data_packet_size = 9;
104}