From 64cb0b70eb6759bb69dae38410aa6f13058d5cf8 Mon Sep 17 00:00:00 2001 From: Satoshi Ikari Date: Fri, 6 Oct 2023 09:47:19 +0200 Subject: [PATCH 1/3] Remove CMD_DB header info --- src/library/initialize/c2a_command_database.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/library/initialize/c2a_command_database.cpp b/src/library/initialize/c2a_command_database.cpp index cf3f2bb16..346d1d772 100644 --- a/src/library/initialize/c2a_command_database.cpp +++ b/src/library/initialize/c2a_command_database.cpp @@ -13,6 +13,7 @@ C2aCommandInformation::C2aCommandInformation(const std::string cmd_db_line) { if (cmd_db_line.find("*") == 0) return; + if (cmd_db_line.find(",") != 0) return; // CSV std::string token; From 0252e097a76adcc28f4f6304739ffcc24646397f Mon Sep 17 00:00:00 2001 From: Satoshi Ikari Date: Fri, 6 Oct 2023 10:05:55 +0200 Subject: [PATCH 2/3] Add command name empty check --- src/library/initialize/c2a_command_database.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/library/initialize/c2a_command_database.cpp b/src/library/initialize/c2a_command_database.cpp index 346d1d772..b31655166 100644 --- a/src/library/initialize/c2a_command_database.cpp +++ b/src/library/initialize/c2a_command_database.cpp @@ -25,6 +25,7 @@ C2aCommandInformation::C2aCommandInformation(const std::string cmd_db_line) { // Command name command_name_ = tokens[1]; + if (command_name_.empty()) return; // Command ID command_id_ = std::stoul(tokens[3], nullptr, 0); From cd3e49753d6e153d3d6b6c70211139562d73a116 Mon Sep 17 00:00:00 2001 From: Satoshi Ikari Date: Fri, 6 Oct 2023 10:07:38 +0200 Subject: [PATCH 3/3] Fix sample OPS file --- .../components/wings_command_sender_to_c2a/example.ops | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/data/sample/initialize_files/components/wings_command_sender_to_c2a/example.ops b/data/sample/initialize_files/components/wings_command_sender_to_c2a/example.ops index 16226c302..ba12659c7 100644 --- a/data/sample/initialize_files/components/wings_command_sender_to_c2a/example.ops +++ b/data/sample/initialize_files/components/wings_command_sender_to_c2a/example.ops @@ -2,11 +2,11 @@ .# .# コメントは読み飛ばされる .# -.MOBC_RT.Cmd_NOP +.MOBC_RT.NOP wait_sec 5 - MOBC_RT.Cmd_MM_START_TRANSITION 2 + MOBC_RT.MM_START_TRANSITION 2 wait_sec 3 check_value # check_valueは今は使えず読み飛ばされる let mode_id = 2 # letはいまはつかえない - AOBC_RT.Cmd_MM_START_TRANSITION {mode_id} # letを前提とした{}付きの引数があるとコマンドは送信されない + AOBC_RT.MM_START_TRANSITION {mode_id} # letを前提とした{}付きの引数があるとコマンドは送信されない .#