forked from RoboCup-Humanoid-TC/hlvs_webots
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmessages.proto
125 lines (105 loc) · 3.16 KB
/
messages.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
syntax = "proto3";
message Vector3 {
double X = 1;
double Y = 2;
double Z = 3;
}
message PositionSensorMeasurement {
string name = 1;
double value = 2;
}
message AccelerometerMeasurement {
string name = 1;
Vector3 value = 2; // [m/sˆ2], x-axis, y-axis, z-axis
}
message GyroMeasurement {
string name = 1;
Vector3 value = 2; // [rad/s], x-axis, y-axis, z-axis
}
message BumperMeasurement {
string name = 1;
bool value = 2;
}
message ForceMeasurement {
string name = 1;
double value = 2; // [N]
}
message Force3DMeasurement {
string name = 1;
Vector3 value = 2; // [N], x-axis, y-axis, z-axis
}
message Force6DMeasurement { // not yet implemented
string name = 1;
Vector3 force = 2; // [N], x-axis, y-axis, z-axis
Vector3 torque = 3; // [N.m], x-axis, y-axis, z-axis
}
message CameraMeasurement {
string name = 1;
uint32 width = 2;
uint32 height = 3;
sint32 quality = 4; // -1 = raw image, 100 = no compression, 0 = high compression
bytes image = 5; // RAW or JPEG encoded data (note: JPEG is not yet implemented)
}
message Message {
enum MessageType {
ERROR_MESSAGE = 0;
WARNING_MESSAGE = 1;
}
MessageType message_type = 1;
string text = 2;
}
message SensorMeasurements {
uint32 time = 1; // time stamp at which the measurements were performed expressed in [ms]
uint64 real_time = 2; // real unix time stamp at which the measurements were performed in [ms]
repeated Message messages = 3;
repeated AccelerometerMeasurement accelerometers = 4;
repeated BumperMeasurement bumpers = 5;
repeated CameraMeasurement cameras = 6;
repeated ForceMeasurement forces = 7;
repeated Force3DMeasurement force3ds = 8;
repeated Force6DMeasurement force6ds = 9;
repeated GyroMeasurement gyros = 10;
repeated PositionSensorMeasurement position_sensors = 11;
}
message MotorPosition {
string name = 1;
double position = 2; // linear or angular target position expressed in [m] or [rad]
}
message MotorVelocity {
string name = 1;
double velocity = 2; // linear or angular target velocity expressed in [m/s] or [rad/s]
}
message MotorForce {
string name = 1;
double force = 2; // target force expressed in [N]
}
message MotorTorque {
string name = 1;
double torque = 2; // target torque expressed in [N.m]
}
message MotorPID {
string name = 1;
Vector3 PID = 2; // PID controller values
}
message SensorTimeStep { // apply to all sensors: Accelerometer, Camera, Gyro, PositionSensor and TouchSensor
string name = 1;
uint32 timeStep = 2; // time between two measurements expressed in [ms], disabled if 0
}
message CameraQuality {
string name = 1;
sint32 quality = 2; // JPEG quality
}
message CameraExposure {
string name = 1;
double exposure = 2; // photometric exposure of the scene in joule per square meter [J/m^2]
}
message ActuatorRequests {
repeated MotorPosition motor_positions = 1;
repeated MotorVelocity motor_velocities = 2;
repeated MotorForce motor_forces = 3;
repeated MotorTorque motor_torques = 4;
repeated MotorPID motor_pids = 5;
repeated SensorTimeStep sensor_time_steps = 6;
repeated CameraQuality camera_qualities = 7;
repeated CameraExposure camera_exposures = 8;
}