CN117784637A - Universal semi-physical simulation platform and method for planning and controlling multiple robots - Google Patents
Universal semi-physical simulation platform and method for planning and controlling multiple robots Download PDFInfo
- Publication number
- CN117784637A CN117784637A CN202410066776.7A CN202410066776A CN117784637A CN 117784637 A CN117784637 A CN 117784637A CN 202410066776 A CN202410066776 A CN 202410066776A CN 117784637 A CN117784637 A CN 117784637A
- Authority
- CN
- China
- Prior art keywords
- robot
- module
- simulation
- information
- physical
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/02—Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]
Landscapes
- Control Of Position, Course, Altitude, Or Attitude Of Moving Bodies (AREA)
Abstract
本申请涉及一种多机器人规划与控制的通用半实物仿真平台及方法。所述通用半实物仿真平台采用小型全向移动机器人实物设计结合试验场景虚拟呈现的方式,能够支持用户自定义任务环境、任务类型、团队规模及多机器人物理特性等初始参数,并提供友好的人机交互接口,方便使用者随时对试验过程实施干预;可输出详尽的过程数据,提升试验效果展示度,减少实物机器人损耗,同时加速算法的更新迭代过程。
This application relates to a universal semi-physical simulation platform and method for multi-robot planning and control. The universal semi-physical simulation platform adopts the physical design of a small omnidirectional mobile robot combined with the virtual presentation of test scenarios. It can support users to customize initial parameters such as task environment, task type, team size, and multi-robot physical characteristics, and provide friendly human interface. The computer interactive interface allows users to intervene in the test process at any time; it can output detailed process data, improve the display of test results, reduce the loss of physical robots, and accelerate the update and iteration process of the algorithm.
Description
技术领域Technical field
本申请涉及机器人技术领域,特别是涉及一种多机器人规划与控制的通用半实物仿真平台及方法。This application relates to the field of robotics technology, and in particular to a universal semi-physical simulation platform and method for multi-robot planning and control.
背景技术Background technique
近几十年间,多机器人系统,尤其是分布式多机器人系统以其相对于单机器人系统的先天优势而备受关注。得益于没有集中式的控制机制,每台机器人基于本地感知信息和控制器独立运行,相应的工作环境可以更加广阔且动态。正是由于其系统本身及其运行环境的复杂多样性,目前主流的多机器人规划与控制算法测试平台及方法可分为两种,即仿真验证系统与实物验证系统,以上两种平台可支撑部分简单的多机器人算法试验,但仍存在以下不足:In recent decades, multi-robot systems, especially distributed multi-robot systems, have attracted much attention due to their inherent advantages over single-robot systems. Thanks to the absence of a centralized control mechanism, each robot operates independently based on local sensing information and controllers, and the corresponding working environment can be broader and more dynamic. Precisely due to the complexity and diversity of the system itself and its operating environment, the current mainstream multi-robot planning and control algorithm testing platforms and methods can be divided into two types, namely simulation verification systems and physical verification systems. The above two platforms can support some Simple multi-robot algorithm experiment, but still has the following shortcomings:
1)仿真验证系统算法测试效果不佳,目前已有的算法测试系统多为数值仿真或简化机器人模型(如质点模型)的二维平面仿真,即不构建机器人的运动学模型或动力学模型,同时不考虑机器人的异构特性,环境中的碰撞体积,感知噪声和通信延迟等实际环境中固有的不利因素,是在极度理想化的仿真环境中测试算法的实施效果。导致仿真试验设置与真实环境之间存在较大的差异,算法测试结果无法在实物试验中复现,从而失去进行算法测试的意义。1) The algorithm testing effect of the simulation verification system is not good. Most of the existing algorithm testing systems are numerical simulations or two-dimensional plane simulations of simplified robot models (such as particle models), that is, they do not build the kinematics model or dynamics model of the robot. At the same time, unfavorable factors inherent in the actual environment such as the heterogeneous characteristics of the robot, the collision volume in the environment, perceived noise and communication delays are not taken into account, and the implementation effect of the algorithm is tested in an extremely ideal simulation environment. As a result, there is a large difference between the simulation test setup and the real environment, and the algorithm test results cannot be reproduced in the physical test, thus losing the significance of algorithm testing.
2)实物验证系统仍有一定局限性,首先由于个体体积较大且成本较高,一次试验可用的机器人数量普遍较少,而且对试验场地有着较高的要求,不利于扩展;同时实物机器人的软硬件设计复杂,为保证试验的正常进行,一般需提前进行传感器标定、电机整定等准备工作,导致每次试验耗时较长,不利于进行多次重复实验;另外,试验效果展示度较低,需针对不同算法的应用背景预先设置试验环境,通常是对实验室进行临时改造,任务环境构建困难。2) The physical verification system still has certain limitations. First, due to the large size and high cost of each robot, the number of robots available for a test is generally small, and there are high requirements for the test site, which is not conducive to expansion. At the same time, the hardware and software design of the physical robot is complex. In order to ensure the normal progress of the test, it is generally necessary to carry out sensor calibration, motor adjustment and other preparatory work in advance, which makes each test time-consuming and not conducive to repeated experiments. In addition, the experimental effect display is low, and the test environment needs to be pre-set according to the application background of different algorithms, which usually requires temporary modification of the laboratory, and the task environment is difficult to build.
发明内容Summary of the invention
基于此,有必要针对上述技术问题,提供一种稳定、快速且易操作的多机器人规划与控制的通用半实物仿真平台及方法。Based on this, it is necessary to provide a stable, fast and easy-to-operate universal physical-in-the-loop simulation platform and method for multi-robot planning and control in response to the above technical problems.
一种多机器人规划与控制的通用半实物仿真平台,平台包括:若干个底部粘贴有Apriltag标记的机器人、试验场景仿真系统以及工作站。A universal semi-physical simulation platform for multi-robot planning and control. The platform includes: several robots with Apriltag tags pasted on the bottom, a test scene simulation system and a workstation.
试验场景仿真系统包括支持无限多点同时触控的试验场景显示模块,用于显示工作站设计的试验场景图像,模拟试验场景,在仿真过程中根据任务需要增加虚拟障碍物或实物障碍物;还用于获取试验环境信息和机器人运动信息,并将环境信息和机器人信息传送至工作站;试验环境信息包括障碍物的类别、位置、外形尺寸;机器人运动信息包括机器人的位置、朝向、速度以及加速度。The test scene simulation system includes a test scene display module that supports unlimited multi-point simultaneous touch. It is used to display the test scene image designed by the workstation and simulate the test scene. During the simulation process, virtual obstacles or physical obstacles are added according to the task needs; it is also used It is used to obtain the test environment information and robot motion information, and transmit the environment information and robot information to the workstation; the test environment information includes the type, location, and dimensions of obstacles; the robot motion information includes the robot's position, orientation, speed, and acceleration.
工作站,用于根据预设任务基于虚幻引擎设计试验场景图像,并将试验场景图像发送至试验场景显示模块;还用于接收试验环境信息、机器人运动信息以及机器人状态信息,并根据试验环境信息、机器人运动信息、机器人状态信息以及预设控制算法,确定每个机器人的运动控制指令,并将每个运动控制指令发送至对应的机器人。The workstation is used to design test scene images based on Unreal Engine according to preset tasks, and send the test scene images to the test scene display module; it is also used to receive test environment information, robot motion information, and robot status information, and based on the test environment information, Robot motion information, robot status information and preset control algorithms determine the motion control instructions of each robot and send each motion control instruction to the corresponding robot.
机器人是小型全向移动机器人,用于根据接收的运动控制指令在试验场景显示模块的上表面运动,并将自身的机器人状态信息回传至工作站。The robot is a small omnidirectional mobile robot, used to move on the upper surface of the test scene display module according to the received motion control instructions, and transmit its own robot status information back to the workstation.
在其中一个实施例中,机器人采用双层结构设计,上层包括电池、传感器模组以及通信主板,下层包括轮系、电机模组以及电机驱动板。In one embodiment, the robot adopts a double-layer structure design. The upper layer includes a battery, a sensor module, and a communication motherboard, and the lower layer includes a gear train, a motor module, and a motor drive board.
传感器模组与通信主板连接,通信主板与工作站之间采用WiFi进行数据传输,电机模组和电机驱动板连接,电机驱动板与通信主板通过I2C总线进行数据传输;电机模组与轮系配合安装。The sensor module is connected to the communication motherboard. WiFi is used for data transmission between the communication motherboard and the workstation. The motor module is connected to the motor drive board. The motor drive board and the communication motherboard transmit data through the I2C bus. The motor module is installed in conjunction with the wheel train. .
通信主板用于接收工作站发送的运动控制指令,并将运动控制指令发送至电机驱动板;还用于将传感器模组获取的机器人状态信息回传至工作站。The communication mainboard is used to receive motion control instructions sent by the workstation and send the motion control instructions to the motor drive board; it is also used to transmit the robot status information obtained by the sensor module back to the workstation.
电机驱动板用于接收通信主板发送的运动控制指令,并根据运动控制指令对电机模组进行闭环控制。The motor driver board is used to receive motion control instructions sent by the communication motherboard, and perform closed-loop control of the motor module according to the motion control instructions.
电池用于给传感器模组、通信主板、电机模组以及驱动板提供电源。The battery is used to provide power to the sensor module, communication motherboard, motor module and driver board.
在其中一个实施例中,通信主板包括供电模块,主芯片模块、USB转化模块以及WiFi天线。In one embodiment, the communication mainboard includes a power supply module, a main chip module, a USB conversion module and a WiFi antenna.
供电模块包括两个降压单元,第一个降压单元的输入端与电池的输出端连接,第一个降压单元的第一个输出端与第二降压单元的输入端连接,第二降压单元的输出端与主芯片模块连接,第一个降压单元的第二个输出端与电机驱动板连接。The power supply module includes two voltage-reduction units. The input terminal of the first voltage-reduction unit is connected to the output terminal of the battery. The first output terminal of the first voltage-reduction unit is connected to the input terminal of the second voltage-reduction unit. The output terminal of the buck unit is connected to the main chip module, and the second output terminal of the first buck unit is connected to the motor drive board.
主控芯片模块通过I2C总线与电机驱动板进行数据传输,主控芯片模块通过UART接口与USB转化模块连接;WiFi天线与主控芯片模块连接。The main control chip module transmits data with the motor driver board through the I2C bus. The main control chip module is connected to the USB conversion module through the UART interface; the WiFi antenna is connected to the main control chip module.
在其中一个实施例中,电机驱动板包括电机驱动板主芯片、两个电机驱动芯片。In one embodiment, the motor driving board includes a motor driving board main chip and two motor driving chips.
电机驱动板主芯片与通信主板通过I2C总线进行数据传输,电机驱动板主芯片与电机驱动芯片连接,电机驱动芯片与电机模组连接。The main chip of the motor driving board and the communication main board transmit data through the I2C bus. The main chip of the motor driving board is connected to the motor driving chip, and the motor driving chip is connected to the motor module.
电机驱动板主芯片用于接收通信主板传输的工作站发送的机器人控制指令,并将机器人控制指令进行处理后转化为PWM信号传输至电机驱动芯片;并接收来自电机霍尔编码器的信息并进行处理,将处理后的信息转化为I2C信号传输至通信主板。The main chip of the motor driver board is used to receive the robot control instructions sent by the workstation transmitted by the communication mainboard, and convert the robot control instructions into PWM signals after processing and transmit them to the motor driver chip; and receive and process the information from the motor Hall encoder, and convert the processed information into I2C signals and transmit them to the communication mainboard.
在其中一个实施例中,轮系采用6辊子结构的双层正交全向轮设计,机器人的体速度与3个轮子轮速的关系为:In one embodiment, the wheel system adopts a double-layer orthogonal omnidirectional wheel design with a 6-roller structure, and the relationship between the robot's body speed and the wheel speeds of the three wheels is:
其中,Va、Vb、Vc分别为3个轮子的轮速,vx、vy分别为机器人在x方向和y方向的体速度,ω为机器人的旋转速度。Among them, Va, Vb, and Vc are the wheel speeds of the three wheels respectively, v x and v y are the body speeds of the robot in the x direction and y direction respectively, and ω is the rotation speed of the robot.
在其中一个实施例中,试验场景显示模块包括:若干块采用无边框设计的触控屏,所述触控屏拼接为触屏阵列;所述触控屏为全高清液晶多点触控屏;In one embodiment, the test scene display module includes: several touch screens with a borderless design, the touch screens are spliced into a touch screen array; the touch screen is a full high-definition liquid crystal multi-touch screen;
虚拟障碍物是通过人机交互的方式在触控屏上直接绘制的障碍物;虚拟障碍物具有实际的位置和外形尺寸;触控屏将虚拟障碍物的类别、位置以及外形尺寸转换为TUIO格式信息,将得到的TUIO格式信息传输至工作站。The virtual obstacle is an obstacle directly drawn on the touch screen through human-computer interaction; the virtual obstacle has an actual position and size; the touch screen converts the category, position and size of the virtual obstacle into TUIO format information, and transmits the obtained TUIO format information to the workstation.
实物障碍物是通过实物放置的方式在触控屏的屏幕上布置的底部粘贴标识障碍物类型的Apriltag标记的障碍物微缩模型。Physical obstacles are miniature obstacle models that are placed at the bottom of the touch screen and pasted with Apriltag marking the type of obstacle.
触控屏通过内置的计算机系统捕捉其上方的实物二维码、触控点信息以及物体外形,然后将捕捉的信息转换为TUIO格式信息,将得到的TUIO格式信息传输至工作站。The touch screen captures the physical QR code, touch point information and object shape above it through the built-in computer system, then converts the captured information into TUIO format information, and transmits the obtained TUIO format information to the workstation.
在其中一个实施例中,工作站中运行的仿真软件是基于机器人开源操作系统设计的,工作站与机器人通过MQTT协议进行通信,工作站与试验场景显示模块通过TUIO协议进行通信。In one embodiment, the simulation software running in the workstation is designed based on the robot's open source operating system. The workstation and the robot communicate through the MQTT protocol, and the workstation and the test scene display module communicate through the TUIO protocol.
仿真软件包括数据采集模块、控制模块以及信号传输模块。The simulation software includes data acquisition module, control module and signal transmission module.
数据采集模块用于接收触控屏的TUIO格式的环境信息和机器人运动信息,并将接收的TUIO格式信息转为ROS消息,并传输至控制模块。The data acquisition module is used to receive environmental information and robot motion information in TUIO format from the touch screen, convert the received TUIO format information into ROS messages, and transmit them to the control module.
控制模块用于在接收到ROS消息后采用预设控制算法进行处理,确定每个机器人的运动控制指令,并将每个运动控制指令传输至信号传输模块。The control module is used to process the ROS message using a preset control algorithm, determine the motion control instructions of each robot, and transmit each motion control instruction to the signal transmission module.
信号传输模块用于将控制模块下发的ROS格式的运动控制指令转换为MQTT消息格式,并下发至对应的小型全向移动机器人;还用于接收机器人上传的MQTT格式的机器人状态信息,并将MQTT格式的机器人状态信息转换为ROS格式后传输至控制模块。The signal transmission module is used to convert the motion control instructions in ROS format issued by the control module into MQTT message format, and send them to the corresponding small omnidirectional mobile robot; it is also used to receive the robot status information in MQTT format uploaded by the robot, and Convert the robot status information in MQTT format to ROS format and then transmit it to the control module.
在其中一个实施例中,控制模块还用于通过基于Qt设计的仿真控制终端实现对半实物仿真流程的监视和控制。In one of the embodiments, the control module is also used to monitor and control the semi-physical simulation process through a simulation control terminal designed based on Qt.
仿真控制终端包括仿真界面、physical H-MRS选择区、初始化区、动态参数调节区、环境设置区。The simulation control terminal includes the simulation interface, physical H-MRS selection area, initialization area, dynamic parameter adjustment area, and environment setting area.
仿真界面用于显示构造的半实物仿真环境,实时显示实物机器人的运动方法和运动轨迹;还用于与虚幻引擎的显示相对应,至触控屏上进行动画展示。The simulation interface is used to display the constructed semi-physical simulation environment and display the movement method and trajectory of the physical robot in real time; it is also used to correspond to the display of the Unreal Engine and display animations on the touch screen.
动态参数调节区用于根据测试算法设计调节机器人的算法参数。The dynamic parameter adjustment area is used to adjust the algorithm parameters of the robot according to the test algorithm design.
初始化区用于初始化机器人数量、初始化机器人位置、初始化机器人编队连接;环境设置区,用于用户根据预设任务需求通过添加或删除不同类型的障碍物和目标构造虚拟场景。The initialization area is used to initialize the number of robots, initialize the robot positions, and initialize the robot formation connections; the environment setting area is used for users to construct virtual scenes by adding or deleting different types of obstacles and targets according to preset task requirements.
当仿真模式未选择physical H-MRS模式时,则通过仿真控制终端进行纯仿真实验。When the simulation mode does not select the physical H-MRS mode, a pure simulation experiment is performed through the simulation control terminal.
当仿真模式选择physical H-MRS模式时,仿真界面与实物机器人在触控屏上的位置相对应,通过仿真控制终端对机器人下发指令,并实现动态参数调整;对仿真界面中的虚拟机器人进行拖拽、引导时直接影响实物机器人。When the physical H-MRS mode is selected as the simulation mode, the simulation interface corresponds to the position of the physical robot on the touch screen. Instructions are issued to the robot through the simulation control terminal and dynamic parameter adjustment is realized; the virtual robot in the simulation interface is Directly affects the physical robot when dragging and guiding.
在其中一个实施例中,平台还用于模拟随机动态障碍物,模拟随机动态障碍物是通过手持实物在触控屏上滑动实现的。In one of the embodiments, the platform is also used to simulate random dynamic obstacles, and the simulation of random dynamic obstacles is achieved by sliding a handheld object on the touch screen.
平台还用于模拟在仿真过程中施加外部干扰,施加外部干扰是通过拖拽或阻挡实体机器人实现的。The platform is also used to simulate external interference during the simulation process. External interference is achieved by dragging or blocking the physical robot.
平台还用于模拟在仿真过程中加入或撤走编队中任意机器人的过程。The platform is also used to simulate the process of adding or removing any robot from the formation during the simulation.
一种多机器人规划与控制的通用半实物仿真方法,方法适用于采用上述任一多机器人规划与控制的通用半实物仿真平台进行仿真实验;方法包括:A universal hardware-in-the-loop simulation method for multi-robot planning and control. The method is suitable for conducting simulation experiments using any of the above-mentioned universal hardware-in-the-loop simulation platforms for multi-robot planning and control; the method includes:
在工作站中根据预设任务基于虚幻引擎设计试验场景图像。Design experimental scene images based on Unreal Engine according to preset tasks in the workstation.
在试验场景显示模块中显示试验场景图像,模拟试验场景,在仿真过程中根据任务需要增加虚拟障碍物或实物障碍物。Display the test scene image in the test scene display module to simulate the test scene, and add virtual obstacles or physical obstacles according to task needs during the simulation process.
将若干个底部粘贴有Apriltag标记的机器人置于试验场景显示模块的显示屏上;试验场景显示模块支持无限多点同时触控。Place several robots with Apriltag tags pasted on the bottom on the display screen of the test scene display module; the test scene display module supports unlimited simultaneous touches.
试验场景显示模块获取试验环境信息和机器人运动信息;试验环境信息包括障碍物的类别、位置、外形尺寸;机器人运动信息包括机器人的位置、朝向、速度以及加速度。The test scene display module obtains test environment information and robot motion information; test environment information includes the type, location, and dimensions of obstacles; robot motion information includes the robot's position, orientation, speed, and acceleration.
在工作站中根据试验环境信息、机器人运动信息、机器人状态信息以及预设控制算法,确定每个机器人的运动控制指令。In the workstation, the motion control instructions of each robot are determined based on the test environment information, robot motion information, robot status information and preset control algorithms.
机器人根据对应的运动控制指令在试验场景显示模块的上表面运动,并将自身的机器人状态信息回传至工作站。The robot moves on the upper surface of the test scene display module according to the corresponding motion control instructions, and transmits its own robot status information back to the workstation.
上述多机器人规划与控制的通用半实物仿真平台及方法,所述通用半实物仿真平台采用小型全向移动机器人实物设计结合试验场景虚拟呈现的方式,能够支持用户自定义任务环境、任务类型、团队规模及多机器人物理特性等初始参数,并提供友好的人机交互接口,方便使用者随时对试验过程实施干预;可输出详尽的过程数据,提升试验效果展示度,减少实物机器人损耗,同时加速算法的更新迭代过程。The above-mentioned universal semi-physical simulation platform and method for multi-robot planning and control. The universal semi-physical simulation platform adopts the physical design of small omnidirectional mobile robots combined with the virtual presentation of test scenarios, and can support users to customize task environments, task types, and teams. Initial parameters such as scale and multi-robot physical characteristics are provided, and a friendly human-computer interaction interface is provided to facilitate users to intervene in the test process at any time; detailed process data can be output to improve the display of test results, reduce physical robot losses, and accelerate algorithms. update iterative process.
附图说明Description of drawings
图1为一个实施例中多机器人规划与控制的通用半实物仿真平台组成框图;Figure 1 is a block diagram of a general semi-physical simulation platform for multi-robot planning and control in one embodiment;
图2为一个实施例中多机器人规划与控制的通用半实物仿真平台组成示意图;Figure 2 is a schematic diagram of the composition of a general semi-physical simulation platform for multi-robot planning and control in one embodiment;
图3为另一个实施例中小型全向移动机器人结构图及多视角图,其中(a)为小型全向移动机器人结构图,(b)为主视图,(c)为俯视图,(d)为左视图,(e)为后视图;Figure 3 is a structural diagram and a multi-view view of a small omnidirectional mobile robot in another embodiment, in which (a) is a structural diagram of a small omnidirectional mobile robot, (b) is a main view, (c) is a top view, and (d) is Left view, (e) is the rear view;
图4为另一个实施例中小型全向移动机器人速度分解;Figure 4 shows the speed decomposition of a small omnidirectional mobile robot in another embodiment;
图5为另一个实施例中机器人电气系统原理框图;Figure 5 is a schematic block diagram of the electrical system of the robot in another embodiment;
图6为另一个实施例中识别多台机器人的位置及方向;Figure 6 shows the identification of the positions and directions of multiple robots in another embodiment;
图7为另一个实施例中2×2多屏拼接效果;Figure 7 shows the 2×2 multi-screen splicing effect in another embodiment;
图8为另一个实施例中室内火情环境;Figure 8 shows an indoor fire environment in another embodiment;
图9为另一个实施例中软件框架及节点组成;Figure 9 shows the software framework and node composition in another embodiment;
图10为另一个实施例中基于Qt实现的仿真控制终端;FIG10 is a simulation control terminal implemented based on Qt in another embodiment;
图11为另一个实施例中多机器人规划与控制的通用半实物仿真方法。Figure 11 shows a general physical-in-the-loop simulation method for multi-robot planning and control in another embodiment.
具体实施方式Detailed ways
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clear, the present application will be further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described here are only used to explain the present application and are not used to limit the present application.
在一个实施例中,如图1、图2所示,提供了一种多机器人规划与控制的通用半实物仿真平台,该平台包括:若干个底部粘贴有Apriltag标记的机器人10、试验场景仿真系统20以及工作站30。In one embodiment, as shown in Figures 1 and 2, a general semi-physical simulation platform for multi-robot planning and control is provided. The platform includes: several robots with Apriltag tags pasted on the bottom 10. A test scene simulation system 20 and workstation 30.
试验场景仿真系统20包括支持无限多点同时触控的试验场景显示模块,用于显示工作站30设计的试验场景图像,模拟试验场景,在仿真过程中根据任务需要增加虚拟障碍物或实物障碍物;还用于获取试验环境信息和机器人运动信息,并将环境信息和机器人信息传送至工作站;试验环境信息包括障碍物的类别、位置、外形尺寸;机器人运动信息包括机器人20的位置、朝向、速度以及加速度。The test scene simulation system 20 includes a test scene display module that supports unlimited multi-point simultaneous touch, and is used to display the test scene image designed by the workstation 30, simulate the test scene, and add virtual obstacles or physical obstacles according to task needs during the simulation process; It is also used to obtain test environment information and robot motion information, and transmit the environment information and robot information to the workstation; the test environment information includes the type, location, and dimensions of obstacles; the robot motion information includes the position, orientation, speed, and acceleration.
具体的,作为半实物仿真平台,所使用的试验场景为仿真环境,试验场景仿真系统20采用具有自带计算机系统、并能捕捉在其上方的二维码/物体外形/触控点信息的全高清液晶触控屏。Specifically, as a semi-physical simulation platform, the test scene used is a simulation environment. The test scene simulation system 20 adopts a comprehensive computer system that has its own computer system and can capture the QR code/object shape/touch point information above it. HD LCD touch screen.
试验场景的虚拟化呈现能够降低不同任务环境的搭建成本,提升试验效率加速算法迭代,增强系统的通用性。同时配合实物机器人、微缩模型的使用,大幅提升试验过程的可展示度。支持丰富的人机交互方式,使用者能够以触摸、拖拽等手段直接干预试验过程,充分体现多机器人规划与控制算法中的人类因素。工作站30,用于根据预设任务基于虚幻引擎设计试验场景图像,并将试验场景图像发送至试验场景显示模块;还用于接收试验环境信息、机器人运动信息以及机器人状态信息,并根据试验环境信息、机器人运动信息、机器人状态信息以及预设控制算法,确定每个机器人20的运动控制指令,并将每个运动控制指令发送至对应的动机器人20。The virtual presentation of test scenarios can reduce the cost of setting up different task environments, improve test efficiency, accelerate algorithm iteration, and enhance the versatility of the system. At the same time, combined with the use of physical robots and miniature models, the displayability of the test process is greatly improved. It supports a variety of human-computer interaction methods. Users can directly intervene in the test process by touching, dragging, etc., fully embodying the human factor in multi-robot planning and control algorithms. The workstation 30 is used to design test scene images based on Unreal Engine according to preset tasks, and send the test scene images to the test scene display module; it is also used to receive test environment information, robot motion information, and robot status information, and according to the test environment information , robot motion information, robot status information and preset control algorithms, determine the motion control instructions of each robot 20, and send each motion control instruction to the corresponding mobile robot 20.
机器人20是小型全向移动机器人,用于根据接收的运动控制指令在试验场景显示模块的上表面运动,并将自身的机器人状态信息回传至工作站30。The robot 20 is a small omnidirectional mobile robot, used to move on the upper surface of the test scene display module according to the received motion control instructions, and transmit its own robot status information back to the workstation 30 .
具体的,作为半实物仿真平台,所使用的机器人采用实物设计,保留机器人本身的物理特性,使运行效果更加贴近真实场景。在试验环境范围有限的前提下,为支持较大规模的多机器人系统同时开展试验(数量>30台),所使用的机器人应满足的需求包括体积小,成本低,易维护/更换,且具备通信,控制,规划及运动等个体能力。Specifically, as a semi-physical simulation platform, the robot used adopts physical design, retains the physical characteristics of the robot itself, and makes the operation effect closer to the real scene. Under the premise of limited test environment, in order to support large-scale multi-robot system to carry out tests at the same time (number>30), the robots used should meet the requirements of small size, low cost, easy maintenance/replacement, and individual capabilities such as communication, control, planning and movement.
保留了机器人试验中最基本的物理学特性,能够反映真实环境下的碰撞体积,感知噪声以及通信延迟等不利因素对试验效果的影响,使算法测试结果更加可信。同时小型化的设计也降低了单台机器人的制造成本及周期,在有限的场景范围中可支持更大规模的多机器人试验The most basic physical characteristics of robot experiments are retained, and the impact of adverse factors such as collision volume, perception noise, and communication delay on the test results in real environments can be reflected, making the algorithm test results more reliable. At the same time, the miniaturized design also reduces the manufacturing cost and cycle of a single robot, and can support larger-scale multi-robot experiments in a limited range of scenarios.
上述多机器人规划与控制的通用半实物仿真平台,所述通用半实物仿真平台采用小型全向移动机器人实物设计结合试验场景虚拟呈现的方式,能够支持用户自定义任务环境、任务类型、团队规模及多机器人物理特性等初始参数,并提供友好的人机交互接口,方便使用者随时对试验过程实施干预;可输出详尽的过程数据,提升试验效果展示度,减少实物机器人损耗,同时加速算法的更新迭代过程。The above-mentioned universal semi-physical simulation platform for multi-robot planning and control. The universal semi-physical simulation platform adopts the physical design of small omnidirectional mobile robots combined with the virtual presentation of test scenarios, and can support users to customize the task environment, task type, team size and Initial parameters such as the physical characteristics of multiple robots are provided, and a friendly human-computer interaction interface is provided to facilitate users to intervene in the test process at any time; detailed process data can be output to improve the display of test results, reduce the loss of physical robots, and accelerate algorithm updates. Iteration process.
在其中一个实施例中,机器人采用双层结构设计,上层包括电池、传感器模组以及通信主板,下层包括轮系、电机模组以及电机驱动板。In one embodiment, the robot adopts a double-layer structure design, the upper layer includes a battery, a sensor module and a communication main board, and the lower layer includes a wheel system, a motor module and a motor drive board.
传感器模组与通信主板连接,通信主板与工作站之间采用WiFi进行数据传输,电机模组和电机驱动板连接,电机驱动板与通信主板通过I2C总线进行数据传输;电机模组与轮系配合安装。The sensor module is connected to the communication motherboard. WiFi is used for data transmission between the communication motherboard and the workstation. The motor module is connected to the motor drive board. The motor drive board and the communication motherboard transmit data through the I2C bus. The motor module is installed in conjunction with the wheel train. .
通信主板用于接收工作站发送的运动控制指令,并将运动控制指令发送至电机驱动板;还用于将传感器模组获取的机器人状态信息回传至工作站。The communication main board is used to receive motion control instructions sent by the workstation and send the motion control instructions to the motor drive board; it is also used to transmit the robot status information obtained by the sensor module back to the workstation.
电机驱动板用于接收通信主板发送的运动控制指令,并根据运动控制指令对电机模组进行闭环控制。The motor driver board is used to receive motion control instructions sent by the communication motherboard, and perform closed-loop control of the motor module according to the motion control instructions.
电池用于给传感器模组、通信主板、电机模组以及驱动板提供电源。The battery is used to provide power to the sensor module, communication motherboard, motor module and driver board.
在其中一个实施例中,通信主板包括供电模块,主芯片模块、USB转化模块以及WiFi天线。In one embodiment, the communication mainboard includes a power supply module, a main chip module, a USB conversion module and a WiFi antenna.
供电模块包括两个降压单元,第一个降压单元的输入端与电池的输出端连接,第一个降压单元的第一个输出端与第二降压单元的输入端连接,第二降压单元的输出端与主芯片模块连接,第一个降压单元的第二个输出端与电机驱动板连接。The power supply module includes two voltage-reduction units. The input terminal of the first voltage-reduction unit is connected to the output terminal of the battery. The first output terminal of the first voltage-reduction unit is connected to the input terminal of the second voltage-reduction unit. The output terminal of the buck unit is connected to the main chip module, and the second output terminal of the first buck unit is connected to the motor drive board.
主控芯片模块通过I2C总线与电机驱动板进行数据传输,主控芯片模块通过UART接口与USB转化模块连接;WiFi天线与主控芯片模块连接。The main control chip module transmits data with the motor driver board through the I2C bus. The main control chip module is connected to the USB conversion module through the UART interface; the WiFi antenna is connected to the main control chip module.
在其中一个实施例中,电机驱动板包括电机驱动板主芯片、两个电机驱动芯片。In one embodiment, the motor driving board includes a motor driving board main chip and two motor driving chips.
电机驱动板主芯片与通信主板通过I2C总线进行数据传输,电机驱动板主芯片与电机驱动芯片连接,电机驱动芯片与电机模组连接。The main chip of the motor driving board and the communication main board transmit data through the I2C bus. The main chip of the motor driving board is connected to the motor driving chip, and the motor driving chip is connected to the motor module.
电机驱动板主芯片用于接收通信主板传输的工作站发送的机器人控制指令,并将机器人控制指令进行处理后转化为PWM信号传输至电机驱动芯片;并接收来自电机霍尔编码器的信息并进行处理,将处理后的信息转化为I2C信号传输至通信主板。The main chip of the motor driver board is used to receive the robot control instructions sent by the workstation transmitted by the communication main board, process the robot control instructions and convert them into PWM signals and transmit them to the motor driver chip; and receive and process the information from the motor Hall encoder. , convert the processed information into I2C signals and transmit them to the communication main board.
在其中一个实施例中,轮系采用6辊子结构的双层正交全向轮设计,机器人的体速度与3个轮子轮速的关系为:In one embodiment, the wheel system adopts a double-layer orthogonal omnidirectional wheel design with a 6-roller structure, and the relationship between the robot's body speed and the wheel speeds of the three wheels is:
其中,Va、Vb、Vc分别为3个轮子的轮速,vx、vy分别为机器人在x方向和y方向的体速度,ω为机器人的旋转速度。Among them, Va, Vb, and Vc are the wheel speeds of the three wheels respectively, vx and vy are the body speeds of the robot in the x and y directions respectively, and ω is the rotation speed of the robot.
在一个实施例中,小型全向移动机器人整体采用双层结构设计,上层为电池及传感器模组搭配控制及通信主板,下层为轮系及电机模组搭配驱动板。整体尺寸控制在半径50mm,高度55mm以内,结构简单,利于批量生产。小型全向移动机器人结构如图3中(a)所示,主视图、俯视图、左视图和后视图分别如图(3)中(b)、(c)、(d)、(e)所示。In one embodiment, the small omnidirectional mobile robot adopts a double-layer structure design. The upper layer is a battery and sensor module with a control and communication motherboard, and the lower layer is a gear train and motor module with a drive board. The overall size is controlled within a radius of 50mm and a height of 55mm. The structure is simple and is conducive to mass production. The structure of the small omnidirectional mobile robot is shown in (a) in Figure 3. The front view, top view, left view and rear view are shown in (b), (c), (d) and (e) in Figure (3) respectively. .
小型全向移动机器人的具体设计方案如下:The specific design plan of the small omnidirectional mobile robot is as follows:
①供电方式:全向移动机器人主要功耗包括驱动电机与WIFI芯片,其中电机在额定电压电流下理论最大功耗为2.4W,WIFI芯片在WIFI打开情况为1.2W。假设3电机及WIFI芯片均以最大功耗运行情况下的机器人总功耗为9W,则选用3S航模电池(550mAh)在不考虑过放情况可使用40min。① Power supply method: The main power consumption of the omnidirectional mobile robot includes the drive motor and WIFI chip. The theoretical maximum power consumption of the motor is 2.4W under the rated voltage and current, and the WIFI chip is 1.2W when WIFI is turned on. Assuming that the total power consumption of the robot is 9W when both the 3 motors and the WIFI chip are running at maximum power consumption, the 3S model aircraft battery (550mAh) can be used for 40 minutes without considering over-discharge.
②数据连接方式:无线连接方式中,蓝牙传输速度较慢,故本方案采用2.4GHzWIFI进行数据传输。另在移动机器人上添加USB模块用于调试过程中的程序烧录及串口监测。②Data connection method: In the wireless connection method, Bluetooth transmission speed is slow, so this solution uses 2.4GHz WIFI for data transmission. In addition, a USB module is added to the mobile robot for program burning and serial port monitoring during debugging.
为简化机器人的运动控制难度,提高其灵活性,采用三轮全向的运动机构设计,以下是轮系布置及驱动电机选型方案:In order to simplify the robot's motion control difficulty and improve its flexibility, a three-wheel omnidirectional motion mechanism design is adopted. The following is the wheel arrangement and drive motor selection scheme:
①轮系布置:为实现机器人的全向运动,采用6辊子结构的双层正交全向轮设计,提升机器人运动的灵活性。其体速度vx和vy与轮速v1,v2和v3的关系如图4所示,计算公式如下列线性方程组:① Wheel train arrangement: In order to realize the omnidirectional movement of the robot, a double-layer orthogonal omnidirectional wheel design with a 6-roller structure is used to improve the flexibility of the robot's movement. The relationship between the body speed v x and v y and the wheel speed v 1 , v 2 and v 3 is shown in Figure 4. The calculation formula is as follows:
v1=vx+ωLv 1 =v x +ωL
v2=-vxcosθ1-vysinθ1+ωLv 2 =-v x cosθ 1 -v y sinθ 1 +ωL
v3=-vxsinθ2+vycosθ2+ωLv 3 =-v x sinθ 2 +v y cosθ 2 +ωL
其矩阵形式为:Its matrix form is:
②驱动电机选型:在已选定3S电池的基础上选择12V电机,合理选择减速比,获取较大转矩,保证全向移动机器人能够以较快速度运动。电机转矩从功率角度进行分析,其最小转矩需支持全向移动机器人实现运动,假设只有一个轮子处于转动状态,此时有:② Drive motor selection: Select a 12V motor based on the selected 3S battery, and reasonably select the reduction ratio to obtain greater torque and ensure that the omnidirectional mobile robot can move at a faster speed. The motor torque is analyzed from the perspective of power. Its minimum torque needs to support the movement of the omnidirectional mobile robot. Assume that only one wheel is rotating. At this time, there are:
功率=扭矩×转速Power=torque×speed
又有:Also:
转速=速度/(π×轮子直径)Rotation speed = speed/(π×wheel diameter)
使机器人运动,即摩擦力做功,此时有:To make the robot move, that is, the friction force does work. At this time, there is:
功率=摩擦力×速度Power = Friction × Speed
本实施例中机器人重量约为200g,轮子直径为21mm,橡胶轮胎和玻璃之间的滚动摩擦系数通常在0.1到0.3之间,假设取最大值0.3,故单个轮子驱动机器人运动的情况下,扭矩需满足:In this embodiment, the robot weighs about 200g, the wheel diameter is 21mm, and the rolling friction coefficient between the rubber tire and the glass is usually between 0.1 and 0.3. Assuming the maximum value of 0.3, when a single wheel drives the robot to move, the torque must satisfy:
扭矩=0.3×200×10-3×9.8×π×21≈38.8mN*mTorque=0.3×200×10 -3 ×9.8×π×21≈38.8mN*m
立足成熟可靠的同时兼容最新设计方案,降低制造成本,提高可靠性与可生产性,满足试验技术需求。系统的电气电路分为两块,中间使用数据线整合I2C信号线及供电线进行连接,如图5所示。两块电路板功能分别为上层WIFI板(ESP32_A)及下层电机驱动板(ESP32_B)。Based on mature and reliable, it is compatible with the latest design scheme, reduces manufacturing costs, improves reliability and manufacturability, and meets the test technology requirements. The electrical circuit of the system is divided into two parts, and the data line is used to integrate the I2C signal line and the power supply line for connection, as shown in Figure 5. The functions of the two circuit boards are the upper WIFI board (ESP32_A) and the lower motor driver board (ESP32_B).
其中WIFI板(ESP32_A)的电路模块方案主要分为供电模块,主芯片模块以及USB转化模块,按模块进行描述:The circuit module scheme of the WIFI board (ESP32_A) is mainly divided into power supply module, main chip module and USB conversion module, which are described as follows:
①供电模块:主要功能为将来自3S航模电池的12V电压进行降压处理,转化为5V,再将5V转化为3.3V。因12V至5V降压范围较大,若采用LDO进行降压会导致发热严重,故5V降压模块采用DCDC降压方式,3.3V降压模块采用LDO降压方式。另外供电模块预留外置电源开关接口(开关嵌入机器人外壳)以及电量显示模块接口;① Power supply module: The main function is to step down the 12V voltage from the 3S aircraft model battery, convert it into 5V, and then convert 5V into 3.3V. Because the voltage step-down range from 12V to 5V is large, using LDO for voltage step-down will cause severe heating, so the 5V step-down module uses the DCDC step-down method, and the 3.3V step-down module uses the LDO step-down method. In addition, the power supply module reserves an external power switch interface (the switch is embedded in the robot shell) and a power display module interface;
②主芯片模块:WIFI板主芯片采用ESP32-MINI-1U,主要功能为接收来自主机的WIFI信号,传输I2C信号给电机驱动板(ESP32_B),传输UART信号给USB转化模块,LED灯的控制(LED为预留接口,嵌入机器人外壳上);②Main chip module: The main chip of the WIFI board adopts ESP32-MINI-1U. Its main functions are to receive WIFI signals from the host, transmit I2C signals to the motor driver board (ESP32_B), transmit UART signals to the USB conversion module, and control LED lights ( LED is a reserved interface and is embedded in the robot shell);
③USB转化模块:通过转化芯片CP2102将来自ESP32-MINI-1U主芯片的UART信号转化为USB信号,用于代码烧录以及串口查看。③USB conversion module: The UART signal from the ESP32-MINI-1U main chip is converted into a USB signal through the conversion chip CP2102, which is used for code burning and serial port viewing.
电机驱动板(ESP32_B)的电路模块方案设计主要分为主芯片模块以及电机驱动模块,按模块进行描述:The circuit module design of the motor driver board (ESP32_B) is mainly divided into the main chip module and the motor driver module, which are described by module:
①主芯片模块:电机驱动板的主芯片采用ATMEGA328,主要功能为接收来自WIFI电路板ESP32_A的I2C信号,处理信息后转化为PWM信号传输给电机驱动芯片,并接收来自电机霍尔编码器的信息,处理信息后转化为I2C信号传输回WIFI板ESP32_A;① Main chip module: The main chip of the motor driver board adopts ATMEGA328, whose main function is to receive the I2C signal from the WIFI circuit board ESP32_A, convert it into PWM signal after processing and transmit it to the motor driver chip, and receive the information from the motor Hall encoder, convert it into I2C signal after processing and transmit it back to the WIFI board ESP32_A;
②电机驱动模块:采用两块L293DD,供电来自两块电路板间的数据线,其中12V用于驱动电机,5V用于电机驱动芯片供电。② Motor drive module: Two L293DDs are used. The power supply comes from the data line between the two circuit boards. 12V is used to drive the motor and 5V is used to power the motor drive chip.
表1关键器部件选型Table 1 Selection of key components
在其中一个实施例中,试验场景显示模块包括:若干块采用无边框设计的触控屏,所述触控屏拼接为触屏阵列;触控屏为全高清液晶多点触控屏。In one embodiment, the test scene display module includes: several touch screens with a frameless design, the touch screens are spliced into a touch screen array; the touch screen is a full high-definition liquid crystal multi-touch screen.
虚拟障碍物是通过人机交互的方式在触控屏上直接绘制的障碍物;虚拟障碍物具有实际的位置和外形尺寸;触控屏将虚拟障碍物的类别、位置以及外形尺寸转换为TUIO格式信息,将得到的TUIO格式信息传输至工作站。Virtual obstacles are obstacles drawn directly on the touch screen through human-computer interaction; virtual obstacles have actual positions and dimensions; the touch screen converts the categories, positions and dimensions of virtual obstacles into TUIO format information, and transmit the obtained TUIO format information to the workstation.
实物障碍物是通过实物放置的方式在触控屏的屏幕上布置的底部粘贴标识障碍物类型的Apriltag标记的障碍物微缩模型。Physical obstacles are miniature obstacle models that are placed at the bottom of the touch screen and pasted with Apriltag marking the type of obstacle.
触控屏通过内置的计算机系统捕捉其上方的实物二维码、触控点信息以及物体外形,然后将捕捉的信息转换为TUIO格式信息,将得到的TUIO格式信息传输至工作站。The touch screen captures the physical QR code, touch point information and object shape above it through the built-in computer system, then converts the captured information into TUIO format information, and transmits the obtained TUIO format information to the workstation.
TUIO(Table-Top User Interfaces Objects)是一种简单通用的协议,用于触控屏设备人机交互界面。TUIO (Table-Top User Interfaces Objects) is a simple and universal protocol used for the human-computer interaction interface of touch screen devices.
触控屏的数量可以是但不限于4块,还可以是6块、8块、9块、10块等,触屏阵列可以是但不限于正方形触屏阵列,还可以是长方形触屏阵列。The number of touch screens may be, but is not limited to, 4, and may also be 6, 8, 9, 10, etc. The touch screen array may be, but is not limited to, a square touch screen array or a rectangular touch screen array.
在一个具体实施例中,采用4块MultiTraction MT557D全高清液晶多点触控屏拼接的方式,作为基本的试验场景显示手段。该设备基于Clearsight技术触控引擎,可支持无限多点同时触控,触摸延时约为10毫秒,达到亚像素精度。可通过物体底部粘贴的Apriltag标记快速识别放置其上的实物位置与朝向信息,并计算出物体的速度以及加速度,编号后以多种格式跟踪输出,以上述小型全向移动机器人为例,识别效果如图6所示。In a specific embodiment, four MultiTraction MT557D full-HD LCD multi-touch screens are spliced together as the basic test scene display means. The device is based on the Clearsight technology touch engine and can support unlimited multiple points of simultaneous touch. The touch delay is about 10 milliseconds and reaches sub-pixel accuracy. The Apriltag mark attached to the bottom of the object can quickly identify the position and orientation information of the physical object placed on it, and calculate the speed and acceleration of the object. After numbering, it can be tracked and output in multiple formats. Taking the above-mentioned small omnidirectional mobile robot as an example, the recognition effect As shown in Figure 6.
作为通用半实物仿真平台,该系统利用MultiTraction出色的显示效果,可快速搭建多种试验环境。如图7所示,本实施例采用4块全高清液晶多点触控屏以2×2的方式拼接,屏幕采用无边框设计,允许机器人跨屏幕运动。结合较小的实物机器人尺寸,可支持数量规模>30台的多机器人系统开展算法试验。As a general-purpose semi-physical simulation platform, this system uses MultiTraction's excellent display effects to quickly build a variety of test environments. As shown in Figure 7, this embodiment uses four full-HD LCD multi-touch screens to be spliced in a 2×2 manner. The screen adopts a borderless design, allowing the robot to move across the screen. Combined with the smaller physical robot size, it can support multi-robot systems with a number of >30 units to carry out algorithm experiments.
根据任务类型,可基于虚幻引擎(UE,Unreal Engine)设计屏幕显示图像,模拟试验环境,并可根据需要增加虚拟障碍物或实物障碍物,以多机器人系统在室内环境遂行火源扑灭并搜寻幸存者的任务为例,如图8所示。可通过屏幕设置条形障碍物(墙面,柜体等),圆形障碍物(座椅等),这些障碍物以虚拟图像显示,但具有实际的位置及尺寸信息,并由屏幕反馈给临近的机器人,进而被机器人所“探测”到。还可以采用实物放置的方式布置所需试验环境,通过在微缩模型底部粘贴Apriltag(区别于机器人,不能复用)使屏幕可以检测到该物体放置的位置及朝向。依托虚拟及实物障碍物,试验场景布置灵活,可随时调整障碍物位置,且无需重新编程,进一步突出本系统的半实物仿真特性。According to the task type, the screen display image can be designed based on Unreal Engine (UE) to simulate the test environment, and virtual obstacles or physical obstacles can be added as needed. Take the task of a multi-robot system to extinguish a fire and search for survivors in an indoor environment as an example, as shown in Figure 8. Bar obstacles (walls, cabinets, etc.) and circular obstacles (seats, etc.) can be set on the screen. These obstacles are displayed as virtual images, but have actual position and size information, and are fed back to the nearby robots by the screen, and then "detected" by the robots. The required test environment can also be arranged by placing physical objects. By pasting Apriltag (different from the robot and cannot be reused) at the bottom of the miniature model, the screen can detect the position and direction of the object. Relying on virtual and physical obstacles, the test scene can be arranged flexibly, and the position of the obstacles can be adjusted at any time without reprogramming, further highlighting the semi-physical simulation characteristics of this system.
得益于以上半实物仿真平台的设计,还可实现丰富的人机交互过程,增加对多机器人规划与控制算法的人类干预。使用者可通过触摸屏幕直接绘制虚拟障碍物、感兴趣目标等环境信息,还可手持实物在屏幕上滑动,以模拟随机动态障碍物等。也可通过拖拽或阻挡实物机器人直接对其施加控制干预,甚至可以随时加入或撤走编队中的任意机器人。以上交互可以模拟多种规划或控制算法中的复杂因素,提供更多样化的算法测试需求。Thanks to the design of the above semi-physical simulation platform, it can also realize rich human-computer interaction processes and increase human intervention in multi-robot planning and control algorithms. Users can directly draw virtual obstacles, objects of interest and other environmental information by touching the screen, and can also hold real objects and slide them on the screen to simulate random dynamic obstacles. You can also directly control and intervene the physical robot by dragging or blocking it, and you can even join or remove any robot in the formation at any time. The above interactions can simulate complex factors in a variety of planning or control algorithms, providing more diverse algorithm testing requirements.
在其中一个实施例中,工作站中运行的仿真软件是基于机器人开源操作系统设计的,工作站与机器人通过MQTT协议进行通信,工作站与试验场景显示模块通过TUIO协议进行通信。In one embodiment, the simulation software running in the workstation is designed based on the robot open source operating system, the workstation communicates with the robot through the MQTT protocol, and the workstation communicates with the test scene display module through the TUIO protocol.
仿真软件包括数据采集模块、控制模块以及信号传输模块。The simulation software includes data acquisition module, control module and signal transmission module.
数据采集模块用于接收触控屏的TUIO格式的环境信息和机器人运动信息,并将接收的TUIO格式信息转为ROS消息,并传输至控制模块。The data acquisition module is used to receive the TUIO format environmental information and robot motion information from the touch screen, convert the received TUIO format information into ROS messages, and transmit them to the control module.
控制模块用于在接收到ROS消息后采用预设控制算法进行处理,确定每个机器人的运动控制指令,并将每个运动控制指令传输至信号传输模块。The control module is used to process the ROS message using a preset control algorithm, determine the motion control instructions of each robot, and transmit each motion control instruction to the signal transmission module.
信号传输模块用于将控制模块下发的ROS格式的运动控制指令转换为MQTT消息格式,并下发至对应的小型全向移动机器人;还用于接收机器人上传的MQTT格式的机器人状态信息,并将MQTT格式的机器人状态信息转换为ROS格式后传输至控制模块。The signal transmission module is used to convert the motion control instructions in ROS format issued by the control module into MQTT message format, and send them to the corresponding small omnidirectional mobile robot; it is also used to receive the robot status information in MQTT format uploaded by the robot, and Convert the robot status information in MQTT format to ROS format and then transmit it to the control module.
MQTT(Message Queuing Telemetry Transport,消息队列遥测传输协议),是一种基于发布/订阅(publish/subscribe)模式的“轻量级”通讯协议。MQTT (Message Queuing Telemetry Transport, Message Queuing Telemetry Transport Protocol) is a "lightweight" communication protocol based on the publish/subscribe (publish/subscribe) mode.
在其中一个实施例中,控制模块还用于通过基于Qt设计的仿真控制终端实现对半实物仿真流程的监视和控制。In one of the embodiments, the control module is also used to monitor and control the hardware-in-the-loop simulation process through a simulation control terminal designed based on Qt.
仿真控制终端包括仿真界面、physical H-MRS选择区、初始化区、动态参数调节区、环境设置区。The simulation control terminal includes the simulation interface, physical H-MRS selection area, initialization area, dynamic parameter adjustment area, and environment setting area.
仿真界面用于显示构造的半实物仿真环境,实时显示实物机器人的运动方法和运动轨迹;还用于与虚幻引擎的显示相对应,至触控屏上进行动画展示。The simulation interface is used to display the constructed semi-physical simulation environment and to display the movement method and trajectory of the physical robot in real time. It is also used to correspond to the display of the Unreal Engine and to perform animation display on the touch screen.
动态参数调节区用于根据测试算法设计调节机器人的算法参数(如:机器人的意图场、混合策略以及引导向量场)。The dynamic parameter adjustment area is used to adjust the robot's algorithm parameters (such as the robot's intention field, hybrid strategy, and guidance vector field) according to the test algorithm design.
初始化区用于初始化机器人数量、初始化机器人位置、初始化机器人编队连接;环境设置区,用于用户根据预设任务需求通过添加或删除不同类型的障碍物和目标构造虚拟场景。The initialization area is used to initialize the number of robots, initialize robot positions, and initialize robot formation connections; the environment setting area is used for users to construct virtual scenes by adding or deleting different types of obstacles and targets according to preset task requirements.
当仿真模式未选择physical H-MRS模式时,则通过仿真控制终端进行纯仿真实验。When the physical H-MRS mode is not selected in the simulation mode, pure simulation experiments are performed through the simulation control terminal.
当仿真模式选择physical H-MRS模式时,仿真界面与实物机器人在触控屏上的位置相对应,通过仿真控制终端对机器人下发指令,并实现动态参数调整;对仿真界面中的虚拟机器人进行拖拽、引导时直接影响实物机器人。When the physical H-MRS mode is selected as the simulation mode, the simulation interface corresponds to the position of the physical robot on the touch screen. Instructions are issued to the robot through the simulation control terminal and dynamic parameter adjustment is realized; the virtual robot in the simulation interface is Directly affects the physical robot when dragging and guiding.
在一个实施例中,利用机器人开源操作系统(ROS,Robot Operating System)完成仿真软件框架的搭建,主要分为三个部分,包括获取屏幕消息的tuio.launch,控制算法节点shared_control_node,以及用于下发机器人消息的mqtt_bridge.launch,如图9所示。图9中方形代表ROS话题(ROS Topic),包括/tuio和/vs,节点间ROS消息的通信依靠话题实现发布与订阅;椭圆形代表ROS节点,其中节点/tuio1、/tuio2、/tuio3和/tuio4代表消息格式的转换节点(用于分别将4个屏幕获取的TUIO消息格式转成ROS消息格式),节点shared_control_node代表控制算法节点(该节点只能处理ROS消息格式),节点/mqtt_bridge代表消息格式的转换节点(用于实现ROS消息格式和MQTT消息格式的互转)。In one embodiment, the robot open source operating system (ROS, Robot Operating System) is used to complete the construction of the simulation software framework, which is mainly divided into three parts, including tuio.launch to obtain screen messages, the control algorithm node shared_control_node, and the mqtt_bridge.launch that sends robot messages, as shown in Figure 9. The squares in Figure 9 represent ROS topics, including /tuio and /vs. The communication of ROS messages between nodes relies on topics to implement publishing and subscription; the ovals represent ROS nodes, among which the nodes /tuio1, /tuio2, /tuio3 and / tuio4 represents the message format conversion node (used to convert the TUIO message format obtained by 4 screens into ROS message format), the node shared_control_node represents the control algorithm node (this node can only process ROS message format), and the node /mqtt_bridge represents the message format. The conversion node (used to realize the mutual conversion between ROS message format and MQTT message format).
①其中tuio.launch(tuio.launch是启动器,因为试验场景显示模块由四块屏幕拼接,相当同时启动四个消息转换节点)用以将TUIO消息转为ROS消息格式,从而获取到屏幕上的基础信息,并发送给工作站进行处理。MultiTraction MT557D自带的计算机系统能捕捉在其上方的二维码/物体外形/触控点信息,并将其转为TUIO信息格式。TUIO是一个开放式框架,为有形多点触控表面定义了通用协议和应用程序接口。TUIO协议允许传输交互式表面的抽象描述,包括触摸事件和有形物体状态。TUIO主要包括了Object、Cursor、Blob信息,其中Object主要用于识别屏幕上二维码信息,Cursor主要用于识别屏幕上的触控点信息,Blob主要用于识别屏幕上放置物体的外形信息,三种消息格式为:① Among them, tuio.launch (tuio.launch is the launcher, because the test scene display module is spliced by four screens, which means four message conversion nodes are started at the same time) is used to convert TUIO messages into ROS message format, thereby obtaining the information on the screen. Basic information and sent to the workstation for processing. The built-in computer system of MultiTraction MT557D can capture the QR code/object shape/touch point information above it and convert it into TUIO information format. TUIO is an open framework that defines common protocols and application programming interfaces for tangible multi-touch surfaces. The TUIO protocol allows the transmission of abstract descriptions of interactive surfaces, including touch events and tangible object states. TUIO mainly includes Object, Cursor, and Blob information. Object is mainly used to identify QR code information on the screen. Cursor is mainly used to identify touch point information on the screen. Blob is mainly used to identify the shape information of objects placed on the screen. The three message formats are:
(1)Object消息格式:(1)Object message format:
object->getsymbolID();object->getsymbolID();
object->getx();object->getY();object->getx(); object->getY();
object->getAngle();object->getAngle();
object->getMotionSpeed();object->getMotionSpeed();
object->getRotationSpeed();object->getRotationSpeed();
object->getMotionAccel();object->getMotionAccel();
object->getRotationAccel();object->getRotationAccel();
(2)Cursor消息格式:(2)Cursor message format:
cursor->getCursorID();cursor->getCursorID();
cursor->getX();cursor->getY();cursor->getX(); cursor->getY();
cursor->getMotionSpeed();cursor->getMotionSpeed();
cursor->getMotionAccel();cursor->getMotionAccel();
(3)Blob消息格式:(3)Blob message format:
blob->getBlobID()blob->getx();blob->getBlobID() blob->getx();
blob->getY()blob->getAngle();blob->getY()blob->getAngle();
blob->getwidth()blob->getHeight();blob->getwidth()blob->getHeight();
blob->getArea()。blob->getArea().
与此对应,定义ROS消息格式object.msg,cursor.msg与blob.msg用于接收由屏幕获取的TUIO消息。Correspondingly, the ROS message formats object.msg, cursor.msg and blob.msg are defined to receive TUIO messages obtained by the screen.
②shared_control_node接收到相应的ROS消息后进行算法处理,可以使用C++语言或者python语言定义相应的接口并编写代码,支持深度学习等多种算法。同时为监视和控制半实物仿真流程,本发明开发了基于Qt的仿真控制终端。②The shared_control_node performs algorithm processing after receiving the corresponding ROS message. It can use C++ language or python language to define the corresponding interface and write code, and supports multiple algorithms such as deep learning. At the same time, in order to monitor and control the semi-physical simulation process, the present invention develops a Qt-based simulation control terminal.
如图10所示,当physical H-MRS未被选择时,基于仿真控制终端首先进行纯仿真实验,便于算法初期调试,避免恶性Bug对实物机器人的损坏。当physical H-MRS被选择时,该仿真界面与实物机器人在屏幕上的位置相对应,通过控制终端,可以对机器人下达开始/停止等命令,并实现动态参数调整。在终端界面中对机器人进行的拖拽、引导等动作可以直接影响实物机器人。As shown in Figure 10, when the physical H-MRS is not selected, pure simulation experiments are first performed based on the simulation control terminal to facilitate initial debugging of the algorithm and avoid damage to the physical robot by malignant bugs. When physical H-MRS is selected, the simulation interface corresponds to the position of the physical robot on the screen. Through the control terminal, commands such as start/stop can be issued to the robot and dynamic parameter adjustments can be realized. Actions such as dragging and guiding the robot in the terminal interface can directly affect the physical robot.
同时,该控制终端支持使用者对半实物仿真环境进行多种场景构造,可以添加或删除机器人,建立机器人编队连接,给予机器人路径引导。并且支持多种元素的加入,例如多种形状的虚拟障碍物或任务目标,允许实时显示实物机器人的运动方向以及轨迹等信息,更加有利于算法的试验验证。除此之外,该仿真控制终端还可以与UE的显示相对应,能够直接在MultiTraction上进行动画展示,增强试验的展示效果。At the same time, the control terminal supports users to construct various scenarios for the semi-physical simulation environment. They can add or delete robots, establish robot formation connections, and provide robot path guidance. It also supports the addition of multiple elements, such as virtual obstacles or task targets of various shapes, allowing real-time display of the movement direction and trajectory of the physical robot, which is more conducive to experimental verification of the algorithm. In addition, the simulation control terminal can also correspond to the display of the UE and can directly perform animation display on MultiTraction to enhance the display effect of the test.
③Mqtt.launch用于启动mqtt_bridge节点,将控制节点发送的ROS消息转换为MQTT消息格式。MQTT是一种基于发布/订阅模式的“轻量级”通讯协议,因其低协议开销和低功耗特点,能够满足小型全向移动机器人之间的消息传输需求。mqtt_bridge参数配置伪代码为:③Mqtt.launch is used to start the mqtt_bridge node and convert the ROS message sent by the control node into the MQTT message format. MQTT is a "lightweight" communication protocol based on the publish/subscribe model. Due to its low protocol overhead and low power consumption, it can meet the message transmission needs between small omnidirectional mobile robots. The pseudo code for mqtt_bridge parameter configuration is:
1mqtt:1mqtt:
2client:2client:
3protocol:4#MQTTv3113protocol:4#MQTTv311
4connection:4connections:
5 host:localhost5host:localhost
6 port:18836 port:1883
7 keepalive:607 keepalive:60
8private_path:device/0018private_path:device/001
9#serializer:msgpack:dumps9#serializer:msgpack:dumps
10#deserializer:msgpack:loads10#deserializer:msgpack:loads
11bridge:11bridge:
12#tuio mgtt12#tuio mgtt
13-factory:mqtt_bridge.bridge:RosToMqttBridge13-factory:mqtt_bridge.bridge:RosToMqttBridge
14msg_type:vs.msg14msg_type:vs.msg
15topic from:/vs15topic from:/vs
16topic to:mgtt vs16topic to:mgtt vs
17-factory:mqtt bridge.bridge:MgttToRosBridge17-factory:mqtt bridge.bridge:MgttToRosBridge
18msg_type:robot.msg18msg_type:robot.msg
19topic_from:mgtt_robot19topic_from:mgtt_robot
20topic to:/robot20topic to:/robot
该协议基于bridge文件完成ROS和MQTT消息的互相转换,配置相应的参数和消息格式,机器人通过mqtt_bridge接收shared_control_node发送的运动指令,并且可以额外获取机器人上搭载的传感器信息回传给shared_control_node。This protocol completes the mutual conversion of ROS and MQTT messages based on the bridge file, and configures the corresponding parameters and message format. The robot receives the movement instructions sent by the shared_control_node through mqtt_bridge, and can additionally obtain the sensor information carried on the robot and send it back to the shared_control_node.
在其中一个实施例中,平台还用于模拟随机动态障碍物,模拟随机动态障碍物是通过手持实物在触控屏上滑动实现的;平台还用于模拟在仿真过程中施加外部干扰,施加外部干扰是通过拖拽或阻挡实体机器人实现的;平台还用于模拟在仿真过程中加入或撤走编队中任意机器人的过程。In one of the embodiments, the platform is also used to simulate random dynamic obstacles, which is achieved by sliding a physical object on a touch screen; the platform is also used to simulate external interference during the simulation process, which is achieved by dragging or blocking a physical robot; the platform is also used to simulate the process of adding or withdrawing any robot in the formation during the simulation.
在一个实施例中,如图11所示,提供了一种多机器人规划与控制的通用半实物仿真方法,方法适用于采用上述任一多机器人规划与控制的通用半实物仿真平台进行仿真实验;方法包括如下步骤::In one embodiment, as shown in Figure 11, a universal hardware-in-the-loop simulation method for multi-robot planning and control is provided. The method is suitable for conducting simulation experiments using any of the above-mentioned universal hardware-in-the-loop simulation platforms for multi-robot planning and control; The method includes the following steps::
步骤400:在工作站中根据预设任务基于虚幻引擎设计试验场景图像。Step 400: Design a test scene image based on Unreal Engine according to the preset task on the workstation.
步骤402:在试验场景显示模块中显示试验场景图像,模拟试验场景,在仿真过程中根据任务需要增加虚拟障碍物或实物障碍物。Step 402: Display the test scene image in the test scene display module to simulate the test scene, and add virtual obstacles or physical obstacles according to task requirements during the simulation process.
步骤404:将若干个底部粘贴有Apriltag标记的机器人置于试验场景显示模块的显示屏上;试验场景显示模块支持无限多点同时触控。Step 404: Place several robots with Apriltag tags pasted on their bottoms on the display screen of the test scene display module; the test scene display module supports unlimited multi-point simultaneous touch.
步骤406:试验场景显示模块获取试验环境信息和机器人运动信息;试验环境信息包括障碍物的类别、位置、外形尺寸;机器人运动信息包括机器人的位置、朝向、速度以及加速度。Step 406: The test scene display module obtains test environment information and robot motion information; the test environment information includes the type, position, and size of obstacles; the robot motion information includes the position, orientation, speed, and acceleration of the robot.
步骤408:在工作站中根据试验环境信息、机器人运动信息、机器人状态信息以及预设控制算法,确定每个机器人的运动控制指令。Step 408: Determine the motion control instructions of each robot in the workstation based on the test environment information, robot motion information, robot status information and preset control algorithm.
步骤410:机器人根据对应的运动控制指令在试验场景显示模块的上表面运动,并将自身的机器人状态信息回传至工作站。Step 410: The robot moves on the upper surface of the test scene display module according to the corresponding motion control instructions, and transmits its own robot status information back to the workstation.
应该理解的是,虽然图11的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,图11中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些子步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that, although the various steps in the flowchart of Figure 11 are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a portion of the steps in Figure 11 may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请的保护范围应以所附权利要求为准。The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims (10)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202410066776.7A CN117784637A (en) | 2024-01-16 | 2024-01-16 | Universal semi-physical simulation platform and method for planning and controlling multiple robots |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202410066776.7A CN117784637A (en) | 2024-01-16 | 2024-01-16 | Universal semi-physical simulation platform and method for planning and controlling multiple robots |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN117784637A true CN117784637A (en) | 2024-03-29 |
Family
ID=90391129
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202410066776.7A Pending CN117784637A (en) | 2024-01-16 | 2024-01-16 | Universal semi-physical simulation platform and method for planning and controlling multiple robots |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN117784637A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119249720A (en) * | 2024-09-19 | 2025-01-03 | 江淮前沿技术协同创新中心 | Multi-engine collaborative robot simulation system and method |
-
2024
- 2024-01-16 CN CN202410066776.7A patent/CN117784637A/en active Pending
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119249720A (en) * | 2024-09-19 | 2025-01-03 | 江淮前沿技术协同创新中心 | Multi-engine collaborative robot simulation system and method |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN103324100B (en) | A kind of emotion on-vehicle machines people of information-driven | |
| CN103192390B (en) | Control system of humanoid robot | |
| CN103365214A (en) | Single rotor wing unmanned aerial vehicle three-freedom degree semi-physical simulation platform and experimental method | |
| CN107671857A (en) | For service robot operation demonstration and the three-dimensional artificial platform of proof of algorithm | |
| CN101977240A (en) | IPhone smart phone based robot human-machine interactive system | |
| CN103149846A (en) | Flying robot control system semi-physical simulation platform | |
| CN110174891A (en) | A kind of AGV cluster control system and method based on WIFI wireless communication | |
| CN103412648B (en) | The in-vehicle device interaction control device pointed to based on mobile device and method | |
| CN102354464A (en) | Remotely operated vehicle-simulating trainer | |
| CN110328663A (en) | Robot hard real-time control system based on virtual emulation and (SuSE) Linux OS | |
| CN104732835A (en) | Stadium intelligent microscopic vehicle teaching device | |
| EP4089490B1 (en) | Robot control method, control system, and modular robot | |
| CN106020179A (en) | Novel multimachine coordinated control system and method for spherical amphibious robot | |
| CN115956500A (en) | Distributed automatic pepper pollination device and method based on deep learning | |
| CN110977981A (en) | Robot virtual reality synchronization system and synchronization method | |
| CN108406798A (en) | A kind of man-machine interactive system of Service Robots | |
| CN204856222U (en) | Omnidirectional movement platform control system based on internet of things | |
| CN117784637A (en) | Universal semi-physical simulation platform and method for planning and controlling multiple robots | |
| Sun et al. | A remote controlled mobile robot based on wireless transmission | |
| Zou et al. | Design of smart car control system for gesture recognition based on Arduino | |
| KR20210123586A (en) | Method and Apparatus for Automatic Control through imitation Learning | |
| CN115640754A (en) | A Visual UUV Target Tracking Path Planning Training System | |
| CN202453676U (en) | Semi-physical simulation platform of flying robot control system | |
| Sadrollah et al. | A distributed framework for supporting 3D swarming applications | |
| CN115065718A (en) | Multi-agent cooperative control algorithm verification system based on optical indoor positioning |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination |