forked from RoboCup-SSL/ssl-game-controller
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ssl_game_controller_common.proto
72 lines (64 loc) · 2.33 KB
/
ssl_game_controller_common.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
syntax = "proto2";
// Team is either blue or yellow
enum Team {
// team not set
UNKNOWN = 0;
// yellow team
YELLOW = 1;
// blue team
BLUE = 2;
}
// BotId is the combination of a team and a robot id
message BotId {
// the robot id - a negative value indicates that the id is not set
optional int32 id = 1;
// the team that the robot belongs to
optional Team team = 2;
}
// Location is a 2d-coordinate on the field in ssl-vision coordinate system. Units are in meters.
message Location {
// the x-coordinate in [m] in the ssl-vision coordinate system
required float x = 1;
// the y-coordinate in [m] in the ssl-vision coordinate system
required float y = 2;
}
// a reply that is sent by the controller for each request from teams or autoRefs
message ControllerReply {
// status_code is an optional code that indicates the result of the last request
optional StatusCode status_code = 1;
// reason is an optional explanation of the status code
optional string reason = 2;
// next_token must be send with the next request, if secure communication is used
// the token is used to avoid replay attacks
// the token is always present in the very first message before the registration starts
// the token is not present, if secure communication is not used
optional string next_token = 3;
// verification indicates if the last request could be verified (secure communication)
optional Verification verification = 4;
enum StatusCode {
UNKNOWN_STATUS_CODE = 0;
OK = 1;
REJECTED = 2;
}
enum Verification {
UNKNOWN_VERIFICATION = 0;
VERIFIED = 1;
UNVERIFIED = 2;
}
}
// Signature can be added to a request to let it be verfied by the controller
message Signature {
// the token that was received with the last controller reply
required string token = 1;
// the PKCS1v15 signature of this message
required bytes pkcs1v15 = 2;
}
// BallSpeedMeasurement is a single measurement sample of the ball speed
message BallSpeedMeasurement {
// The UNIX timestamp [μs] when the measurement was taken.
required uint64 timestamp = 1;
// the ball speed measurement [m/s]
required float ball_speed = 2;
// the estimated initial ball speed (kick speed) [m/s]
optional float initial_ball_speed = 3;
}