二维码检测:添加了判断顺逆时针的规则和发布内容;临时修改发布话题到了vlm中

This commit is contained in:
2026-07-22 17:32:00 +08:00
parent fc6e796c28
commit 691e9c80bd
5 changed files with 36 additions and 27 deletions

View File

@@ -6,6 +6,7 @@
3 - 到达任务二起始阶段,执行顺/逆时针绕圈(可集成图生文)
4 - 减速拍照图像传入图生文节点随后回到3备用
5 - 完整走完一圈,执行任务三
6 - 到达终点,停止
2. 全部流程
启动小车->slamtoolbox开始建图并开始发布导航命令这时候小车还不能动->打开电机开关,小车开始行动->走到一半扫到二维码,发布在/qr_results上->停掉二维码节点sign=5和导航1同时开始导航2到任务二入口并顺逆时针转圈->到达指定位置触发一次vlm请求->开始语音播报同时完成任务二、三
*/
@@ -17,16 +18,13 @@ static int ENTRY = 2;
static int CIRCLE = 3;
static int VLM = 4;
static int TASK3 = 5;
static int END = 6;
class RacingControl : public rclcpp::Node
{
public:
RacingControl() : Node("racing_control")
{
// 初始化状态指令
state_command_ = QR_SEARCHING;
}
RacingControl();
private:
// 状态指令变量
int state_command_;

View File

@@ -0,0 +1,7 @@
#include "racing_control/racing_control.hpp"
RacingControl : Node("racing_control")
{
// 初始化状态指令
state_command_ = QR_SEARCHING;
}