add voice srv and ActionInfo.msg
This commit is contained in:
@@ -31,6 +31,7 @@ set(msg_files
|
||||
msg/ArmMotionParams.msg
|
||||
msg/ArmError.msg
|
||||
msg/GripperStatus.msg
|
||||
msg/ActionInfo.msg
|
||||
)
|
||||
set(action_files
|
||||
action/MoveToPosition.action
|
||||
@@ -59,6 +60,10 @@ set(srv_files
|
||||
srv/MotorInfo.srv
|
||||
srv/ClearArmError.srv
|
||||
srv/InverseKinematics.srv
|
||||
srv/ASRRecognize.srv
|
||||
srv/AudioData.srv
|
||||
srv/TTSSynthesize.srv
|
||||
srv/VADEvent.srv
|
||||
)
|
||||
|
||||
include_directories(include)
|
||||
|
||||
8
src/msg/ActionInfo.msg
Normal file
8
src/msg/ActionInfo.msg
Normal file
@@ -0,0 +1,8 @@
|
||||
# ActionInfo.msg 执行的技能动作信息
|
||||
|
||||
builtin_interfaces/Time stamp # 时间戳
|
||||
string skill # 当前执行动作所属的技能 (例如: MoveWaist)
|
||||
string action_name # 当前动作名称 (例如: s1_waist_bend_down)
|
||||
string params # 实例参数
|
||||
string execution # 节点并发模式 [serial, parallel]
|
||||
string state # 执行状态
|
||||
@@ -2,17 +2,15 @@
|
||||
# 机器人工作状态汇总信息
|
||||
|
||||
int64 msg_id # 消息序列号
|
||||
builtin_interfaces/Time stamp # 时间戳
|
||||
string working_state # 工作状态 [Standby, Working, Fault]
|
||||
int8 battery_capacity # 电池电量 [0-100] %
|
||||
float32 working_time # 累计工作时间 [h] (例如 1.5)
|
||||
string nav_state # 导航模块状态 [Normal, Fault]
|
||||
string comm_quality # 通信质量 [Excellent, Good, Fair, Poor, NoSignal]
|
||||
string[] task # 任务队列信息 [last_task, next_task, current_task] (例如: StockIn, StockOut, None)
|
||||
string expt_completion_time # 预计完成时间 (格式: 2025-11-11 12:34:56)
|
||||
string work_log # 工作日志摘要
|
||||
string skill # 当前执行的技能 (例如: MoveWaist)
|
||||
string action_name # 当前动作名称 (例如: s1_waist_bend_down)
|
||||
string instance_params # 实例参数
|
||||
string bt_node_status # 行为树节点状态 [IDLE, RUNNING, SUCCESS, FAILURE, SKIPPED]
|
||||
string smacc_state # 状态机状态 [StIdle, StExecuting, StCompleted, StFailed, StEmergency]
|
||||
string[] task # 任务队列信息 [last_task, next_task, current_task] (例如: StockIn, StockOut, None)
|
||||
string bt_xml # 行为树XML
|
||||
ActionInfo[] action # 执行的技能动作信息
|
||||
|
||||
18
src/srv/ASRRecognize.srv
Normal file
18
src/srv/ASRRecognize.srv
Normal file
@@ -0,0 +1,18 @@
|
||||
# 请求:启动识别
|
||||
string command # "start" (默认), "stop", "reset"
|
||||
---
|
||||
# 响应:识别结果
|
||||
bool success
|
||||
string text # 识别文本(空字符串表示未识别到)
|
||||
string message # 状态消息
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
20
src/srv/AudioData.srv
Normal file
20
src/srv/AudioData.srv
Normal file
@@ -0,0 +1,20 @@
|
||||
# 请求:获取音频数据
|
||||
string command # "start" (开始录音), "stop" (停止并返回), "get" (获取当前缓冲区)
|
||||
int32 duration_ms # 录音时长(毫秒),仅用于start命令
|
||||
---
|
||||
# 响应:音频数据
|
||||
bool success
|
||||
uint8[] audio_data # PCM音频数据(int16格式)
|
||||
int32 sample_rate
|
||||
int32 channels
|
||||
int32 samples # 样本数
|
||||
string message
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
14
src/srv/TTSSynthesize.srv
Normal file
14
src/srv/TTSSynthesize.srv
Normal file
@@ -0,0 +1,14 @@
|
||||
# 请求:合成文本或中断命令
|
||||
string command # "synthesize" (默认), "interrupt"
|
||||
string text
|
||||
string voice # 可选,默认使用配置
|
||||
---
|
||||
# 响应:合成状态
|
||||
bool success
|
||||
string message
|
||||
string status # "playing", "completed", "interrupted"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
17
src/srv/VADEvent.srv
Normal file
17
src/srv/VADEvent.srv
Normal file
@@ -0,0 +1,17 @@
|
||||
# 请求:等待VAD事件
|
||||
string command # "wait" (等待下一个事件)
|
||||
int32 timeout_ms # 超时时间(毫秒),0表示无限等待
|
||||
---
|
||||
# 响应:VAD事件
|
||||
bool success
|
||||
string event # "speech_started", "speech_stopped", "none"
|
||||
string message
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user