目录
UI-xml设计
Python:基于采样的运动规划算法RRT路径规划主程序
Lua脚本注释
仿真界面
Coppeliasim加载RRT路径规划结果
交互UI
1. UI-xml设计
xml = [[<ui closeable="false" on-close="closeEventHandler" resizable="true">
<tabs>
<tab title="CSV Playback">
<group layout="vbox">
<label text="<big> Enter the folder path, ending with a slash/backslash:</big>" id="1000" wordwrap="false" style="font-weight: bold;"/>
<group layout="hbox">
<edit value="" id="1001" />
<button text="Open Files" on-click="parseCSVFile" id="2000" />
</group>
<label text="<big> Controls</big>" id="1005" wordwrap="false" style="font-weight: bold;"/>
<group layout="grid">
<button text="Play" on-click="playPressed" />
<button text="Pause" on-click="pausePressed" />
<button text="Stop" on-click="stopPressed" />
<button text="Step" on-click="stepPressed" />
<br/>
<label text="Time Multiplier" />
<button text="Increase" on-click="increaseSpeed" />
<button text="Decrease" on-click="decreaseSpeed" />
<edit id="1006" value="0.1" oneditingfinished="parseEnteredSpeed" />
</group>
<label text="Time" />
<hslider id="4000" tick-position="below" tick-interval="500" minimum="0" maximum="10000" on-change="timeSliderChange"/>
<label text="<big> Messages:</big>" id="1002" wordwrap="false" style="font-weight: bold;"/>
<group layout="vbox">
<label value="" id="1003" wordwrap="true" />
</group>
</group>
<stretch />
</tab>
</tabs>
</ui>]]
ui=simUI.create(xml)--创建UI
2. Python:基于采样的运动规划算法RRT路径规划主程序
RRT算法伪代码
Python主程序注释: