16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-22 16:19:19 +02:00

Command order fix

This commit is contained in:
2025-03-16 17:06:37 +01:00
parent 5ad3789d27
commit d5c89e365c
2 changed files with 977 additions and 975 deletions

View File

@@ -120,6 +120,8 @@ commanddescription_sequence Commands_descriptions = {
{"universalrelayreset3", command_target::vehicle, command_mode::oneoff},
{"notchingrelaytoggle", command_target::vehicle, command_mode::oneoff},
{"epbrakecontroltoggle", command_target::vehicle, command_mode::oneoff},
{"epbrakecontrolenable", command_target::vehicle, command_mode::oneoff},
{"epbrakecontroldisable", command_target::vehicle, command_mode::oneoff},
{"trainbrakeoperationmodeincrease", command_target::vehicle, command_mode::oneoff},
{"trainbrakeoperationmodedecrease", command_target::vehicle, command_mode::oneoff},
{"brakeactingspeedincrease", command_target::vehicle, command_mode::oneoff},
@@ -378,8 +380,7 @@ commanddescription_sequence Commands_descriptions = {
};
// Maps of command and coresponding strings
std::unordered_map<std::string, user_command> commandMap = {
{"aidriverdisable", user_command::aidriverdisable},
std::unordered_map<std::string, user_command> commandMap = {{"aidriverdisable", user_command::aidriverdisable},
{"jointcontrollerset", user_command::jointcontrollerset},
{"mastercontrollerincrease", user_command::mastercontrollerincrease},
{"mastercontrollerincreasefast", user_command::mastercontrollerincreasefast},
@@ -733,7 +734,7 @@ std::unordered_map<std::string, user_command> commandMap = {
{"wiperswitchdecrease", user_command::wiperswitchdecrease},
{"none", user_command::none}};
} // simulation
} // namespace simulation
void command_queue::update()
{

View File

@@ -13,7 +13,8 @@ http://mozilla.org/MPL/2.0/.
#include <queue>
#include <unordered_set>
enum class user_command {
enum class user_command
{
aidriverenable = 0,
aidriverdisable,