1syntax = "proto2"; 2 3package chre_stress_test; 4 5option java_package = "com.google.android.chre.nanoapp.proto"; 6option java_outer_classname = "ChreStressTest"; 7 8// Nanoapp message type can be either host to chre (H2C) or chre to host (C2H) 9enum MessageType { 10 // Reserved for corrupted messages 11 UNDEFINED = 0; 12 13 // H2C: A message to start/stop the test. 14 // Payload must be TestCommand. 15 TEST_COMMAND = 1; 16 17 // C2H: A message indicating the test result. The nanoapp will only use this 18 // message to report a failure. 19 // Payload must be chre_test_common.TestResult. 20 TEST_RESULT = 2; 21 22 // C2H: A message indicating that the stress test nanoapp has received a 23 // WiFi scan while enabling scan monitoring. This can be used for the host 24 // to verify that the scan monitoring feature is working. 25 // No payload. 26 TEST_WIFI_SCAN_MONITOR_TRIGGERED = 3; 27 28 // H2C: A message indicating that the host client has restarted. The nanoapp 29 // should use this message to update its host endpoint tracking when sending 30 // unicast messages. 31 // No payload. 32 TEST_HOST_RESTARTED = 4; 33 34 // H2C: Request Capabilities. 35 // No payload. 36 GET_CAPABILITIES = 5; 37 38 // C2H: Capabilities (response to a GET_CAPABILITIES request). 39 CAPABILITIES = 6; 40} 41 42// A message to start the test. 43message TestCommand { 44 enum Feature { 45 FEATURE_UNDEFINED = 0; 46 // WiFi stress testing, no scan monitoring. 47 WIFI_ON_DEMAND_SCAN = 1; 48 GNSS_LOCATION = 2; 49 GNSS_MEASUREMENT = 3; 50 WWAN = 4; 51 // Enables WiFi scan monitoring only. 52 WIFI_SCAN_MONITOR = 5; 53 // Enables sensor test (accel/gyro/instant motion) only. 54 SENSORS = 6; 55 // Audio stress testing. 56 AUDIO = 7; 57 // Enables BLE test only. 58 BLE = 8; 59 } 60 61 // The feature to test. 62 optional Feature feature = 1; 63 64 // True to start the test, false to stop. 65 optional bool start = 2; 66} 67 68/* 69 * CHRE capabilities 70 */ 71message Capabilities { 72 // Wifi capabilities 73 // see //system/chre/chre_api/include/chre_api/chre/wifi.h 74 optional uint32 wifi = 1; 75} 76