29 lines
642 B
Protocol Buffer
29 lines
642 B
Protocol Buffer
|
syntax = "proto3";
|
||
|
import "google/protobuf/empty.proto";
|
||
|
|
||
|
package NucuCarSensorsProto;
|
||
|
|
||
|
// General
|
||
|
|
||
|
enum SensorStateEnum {
|
||
|
Error = 0;
|
||
|
Uninitialized = 1;
|
||
|
Initialized = 2;
|
||
|
}
|
||
|
|
||
|
// Environment Sensor
|
||
|
service EnvironmentSensorGrpcService {
|
||
|
rpc GetSensorState(google.protobuf.Empty) returns (NucuCarSensorState) {}
|
||
|
rpc GetSensorMeasurement(google.protobuf.Empty) returns (EnvironmentSensorMeasurement) {}
|
||
|
}
|
||
|
|
||
|
message EnvironmentSensorMeasurement {
|
||
|
double Temperature = 1;
|
||
|
double Pressure = 2;
|
||
|
double Humidity = 3;
|
||
|
double VolatileOrganicCompound = 4;
|
||
|
}
|
||
|
|
||
|
message NucuCarSensorState {
|
||
|
SensorStateEnum state = 1;
|
||
|
}
|