refactor(config): 移除未使用的MQTT主题和安全设置
清理不再使用的MQTT主题配置(心跳、响应、错误)和命令超时设置,简化配置结构
This commit is contained in:
@@ -28,10 +28,6 @@ constexpr std::string_view MQTT_PASSWORD = "Lzwc@4187.";
|
||||
// MQTT Topics
|
||||
constexpr const char* TOPIC_PREFIX = "unitree/go2";
|
||||
constexpr const char* TOPIC_CMD = "cmd";
|
||||
constexpr const char* TOPIC_STATE = "state";
|
||||
constexpr const char* TOPIC_HEARTBEAT = "heartbeat";
|
||||
constexpr const char* TOPIC_RESPONSE = "response";
|
||||
constexpr const char* TOPIC_ERROR = "error";
|
||||
|
||||
// Safety settings
|
||||
constexpr double MAX_LINEAR_VELOCITY = 1.5; // m/s
|
||||
|
||||
@@ -14,15 +14,11 @@ void CustomConfig::loadDefaults() {
|
||||
topic_prefix = TOPIC_PREFIX;
|
||||
topic_cmd = TOPIC_CMD;
|
||||
topic_state = TOPIC_STATE;
|
||||
topic_heartbeat = TOPIC_HEARTBEAT;
|
||||
topic_response = TOPIC_RESPONSE;
|
||||
topic_error = TOPIC_ERROR;
|
||||
|
||||
// Robot control settings
|
||||
control_frequency = CONTROL_FREQUENCY;
|
||||
|
||||
// Safety settings
|
||||
command_timeout = COMMAND_TIMEOUT;
|
||||
max_linear_velocity = MAX_LINEAR_VELOCITY;
|
||||
max_angular_velocity = MAX_ANGULAR_VELOCITY;
|
||||
emergency_stop_timeout = EMERGENCY_STOP_TIMEOUT;
|
||||
|
||||
Reference in New Issue
Block a user