diff --git a/RaceCommand.proto b/RaceCommand.proto new file mode 100644 index 0000000..30a7d47 --- /dev/null +++ b/RaceCommand.proto @@ -0,0 +1,20 @@ +syntax = "proto3"; + +package ScStw; + +message StartCommand {} + +message DisableCommand { uint32 laneNumber = 1; } + +message FallCommand { uint32 laneNumber = 1; } + +message ResetCommand {} + +message Command { + oneof Command { + StartCommand start = 1; + DisableCommand disable = 2; + FallCommand fall = 3; + ResetCommand reset = 4; + } +} \ No newline at end of file diff --git a/RaceState.proto b/RaceState.proto new file mode 100644 index 0000000..f48ffc2 --- /dev/null +++ b/RaceState.proto @@ -0,0 +1,37 @@ +syntax = "proto3"; + +package ScStw; + +message LaneFullState { + enum State { + IDLE = 0; + IDLE_FOOT_DOWN = 1; + READY_FOOT_DOWN = 2; + RUNNING_FOOT_DOWN = 3; + RUNNING = 4; + FALSE_START = 5; + FALSE_START_TIE = 6; + WILDCARD = 7; + FINISHED = 8; + FINISHED_WINNER = 9; + FINISHED_TIE = 10; + FALL = 11; + DISABLED = 12; + } + State state = 1; + uint32 reactionTime = 2; + uint32 climbingTime = 3; +} + +message RaceFullState { + enum State { + IDLE = 0; + IDLE_CLEAR_TO_START = 1; + STARTING = 2; + RUNNING = 3; + FINISHED = 4; + FINISHED_MUTED = 5; + } + State state = 1; + repeated LaneFullState laneStates = 2; +} \ No newline at end of file