Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
eb2acda
添加ROV测试
donghaiwang Oct 9, 2026
3ea2130
将ROV测试添加到CI/CD
donghaiwang Oct 9, 2026
5aa08c4
Merge branch 'hutb' into rov
donghaiwang Oct 10, 2026
bfbfe3d
打包ROV配置文件
donghaiwang Oct 10, 2026
c835938
打包低空示例
donghaiwang Oct 12, 2026
cd9a574
Merge branch 'hutb' into rov
donghaiwang Oct 18, 2026
ec7916e
Merge branch 'hutb' into rov
donghaiwang Oct 19, 2026
5f2e288
Merge branch 'hutb' into rov
donghaiwang Oct 23, 2026
f7a2e1b
Merge branch 'hutb' into rov
donghaiwang Nov 2, 2026
98a9f47
fix(rov): resolve CarlaAir launcher paths, test ports and verificatio…
Syysean Nov 3, 2026
1333fef
feat(rov): 增强 settings_rov.json 水动力与双目相机配置,完善 airsim_rov.py 浮力与深度安全网自检
Syysean Nov 3, 2026
9c30edf
feat(holocean): Runtime 化并新增水下传感器子系统
Syysean Nov 4, 2026
1a40e93
feat(holocean): 声呐通路打通,ImagingSonar 在 Town10HD 出回波
Syysean Nov 4, 2026
eeffb4f
fix(URLab): 补 Blutility 私有 include 路径,修复 UE4.26 下编译失败
Syysean Nov 4, 2026
03dd45a
fix(package): 修复 Windows 打包失败,产出可运行的 Shipping 包
Syysean Nov 4, 2026
f901ed2
fix(rov): 修正非法的 AirSim ViewMode,解除打包版启动阻塞
Syysean Nov 4, 2026
35f780e
feat(URLab): 用 UE4.26 API 重写网格导出,打通 ROV 模型编译
Syysean Nov 4, 2026
7df37af
test(URLab): 增加夹爪抓取物理连通性验证
Syysean Nov 4, 2026
9738d2c
chore: 忽略水下仿真运行时产物,补 URLab 测试数据
Syysean Nov 5, 2026
4c7904e
feat(project): 启用 URLab 与 RoadRunnerMaterials,切换 AirSim 到 ROV 模式
Syysean Nov 5, 2026
af6c02b
docs(rov): 补充本地水下 ROV 快速上手脚本与说明
Syysean Nov 5, 2026
6a36178
perf(URLab): 物理线程改用休眠+短自旋,避免吃满一个 CPU 核
Syysean Nov 5, 2026
dd86f98
test(URLab): 新增 ROV 桥接跟随者测试,验证 Pawn 跟随 MuJoCo
Syysean Nov 5, 2026
c50268a
feat(AirSim): ROV Pawn 改造为 MuJoCo 纯跟随者,消除双所有权
Syysean Nov 5, 2026
2d6e3c9
build: OceanPlugin 改为脚本拉取,不入库
Syysean Nov 5, 2026
66f701b
build: 补上 OceanPlugin 拉取脚本(放到 Plugins 下)
Syysean Nov 5, 2026
8b00eea
fix(AirSim): 桥接改为惰性解析 + 自动启动 MuJoCo 仿真,Pawn 跟随实测通过
Syysean Nov 5, 2026
c42a1e8
feat(UnderwaterScene): 新增水下场景辅助插件,支持程序化放置海底/水面/后处理
Syysean Nov 5, 2026
eddb724
fix(URLab): 恢复材质实例落盘,修复 ROV 模型灰白/无材质
Syysean Nov 5, 2026
f9c0044
feat(underwater): 半淹城市 demo 打包支持 + 水下雾载体
Syysean Nov 5, 2026
109e861
fix(package): 把 /Game/MuJoCoImports 加入 cook 列表
Syysean Nov 5, 2026
75194db
docs(package): 记录 Shipping 日志开关,排查打包版崩溃用
Syysean Nov 5, 2026
a195901
feat(AirSim): ROV 键盘推进(WASD + PageUp/PageDown)
Syysean Nov 6, 2026
bd66e15
feat(physics): 接入 MuJoCo 原生椭球流体模型 + 受力分解
Syysean Nov 6, 2026
15c84d9
feat(physics): 洋流三层级联 + PID 定深 + 附加角阻尼
Syysean Nov 6, 2026
787cdc9
tune(physics): 角阻尼提到 6.5,P7 达标
Syysean Nov 6, 2026
c84f621
fix(physics): 修正单位约定与浮力配平,P6 通过
Syysean Nov 6, 2026
c9c8ead
fix(current): 洋流加速度上限 + 命令行开关,仍默认关闭
Syysean Nov 6, 2026
ae35b6c
fix(current): 洋流默认开启并验证通过(P8)
Syysean Nov 6, 2026
85fb811
feat(physics): 施力通道改为 qfrc_applied + 被动稳定 + 机械臂阻尼
Syysean Nov 6, 2026
9501449
feat(attitude): 姿态保持控制器(四元数 PD + 积分)—— 未收敛,待修轴系
Syysean Nov 6, 2026
8902fa4
test(physics): 加力矩轴自检,定位 qfrc_applied 角向分量的坐标系
Syysean Nov 6, 2026
907999d
refactor(physics): 施力改用 mj_applyFT,消除布局与轴系歧义
Syysean Nov 6, 2026
592e82d
fix(attitude): 按 body_iquat 计算机体轴等效惯量(此前增益缩放错了 1.8 倍)
Syysean Nov 6, 2026
a8c4111
chore(attitude): 机械臂刚度/重力补偿做成可选开关,默认关闭
Syysean Nov 6, 2026
a2f0feb
fix(attitude): 改用自由关节 6x6 质量阵的复合惯量,姿态控制器终于收敛
Syysean Nov 6, 2026
faebc0c
feat(current): 洋流平均流速 0.5 -> 0.15 m/s(S4)
Syysean Nov 6, 2026
2e88a8e
fix(damping): 角阻尼的 Kd 也改用复合惯量,P7 大幅改善
Syysean Nov 6, 2026
85dd8d7
tune(damping): 角阻尼 6.5 -> 10.0,P7 达标时刻提前到 2.5s
Syysean Nov 6, 2026
d55fb3d
fix(arm): 机械臂关节阻尼 1000 -> 20000,P7 达标
Syysean Nov 6, 2026
464aaf8
fix(carla): 端口被占用时不再 Fatal,降级为不启动 Carla 服务器
Syysean Nov 6, 2026
a0ca002
fix(carla): 打包版启动即崩的根因 —— Shaders 目录 check() 断言
Syysean Nov 6, 2026
8e0978a
fix(urlab): 打包版启动崩溃的根因 —— cooked 包索引缓冲无 CPU 副本导致越界
Syysean Nov 6, 2026
b9980aa
fix(urlab): 打包版网格未注册时退化为包围盒,保证 MuJoCo 模型能编译
Syysean Nov 6, 2026
14d7974
Merge upstream/hutb into feat/holocean-runtime
Syysean Nov 7, 2026
9d523c5
fix(review): 清理形式问题并让 setup.bat -l 可用
Syysean Nov 7, 2026
2696b88
feat(rov): 航向控制(←/→)+ 水面高度对齐地图海面
Syysean Nov 7, 2026
2b8716f
feat(rov): 出生自动锁定深度
Syysean Nov 7, 2026
79318b8
fix(rov): 姿态控制改为机体系级联控制,修复静置自转发散
Syysean Nov 8, 2026
623603f
fix(rov): 修正 ←/→ 航向方向并加角速度前馈,消除转满一圈回弹
Syysean Nov 8, 2026
59725ef
fix(rov): 修复夹爪网格单位错误导致的 150 kg 错挂,按真实排水体积加臂浮力
Syysean Nov 8, 2026
dd9dfd2
fix(rov): 修复打包版启动卡顿导致的姿态甩翻(跨线程指令冻结)
Syysean Nov 8, 2026
2b1269b
fix(build): 补齐 AirSim ROV 源文件,修复 setup.bat -l 编译失败
Syysean Nov 9, 2026
b82363e
fix(build): 补入 SimHUD / SimWorldGameMode 的 ROV 挂载点
Syysean Nov 9, 2026
361d52b
fix(config): 默认 settings.json 恢复为无人机(Multirotor),ROV 改为显式配置
Syysean Nov 9, 2026
fab1e54
fix(build): 修复 URLabEditor 引用 AirSim 头文件失败,并精简 ROV 代码注释
Syysean Nov 9, 2026
b26f64d
feat(rov): 补齐参数配置、状态显示与接触日志,修复姿态失衡
Syysean Nov 9, 2026
1d8802b
fix(rov): 对齐障碍物与碰撞体,修复回调遍历崩溃
Syysean Nov 9, 2026
39e6368
fix(build): 补入 ROV 接口头文件,修复键盘 PWM 接口缺失导致的编译失败
Syysean Nov 10, 2026
b91d97f
style(rov): 同步 clang-format 格式化结果
Syysean Nov 10, 2026
de9c426
fix(build): 修复 uproject 的 UTF-8 BOM 导致构建脚本 JSON 解析失败
Syysean Nov 11, 2026
c40f9d2
fix(map): 水下场景合并回 Town10HD,去掉重复地图副本
Syysean Nov 11, 2026
226c562
fix(build): 限制打包构建的并行编译进程数,避免编译器 OOM
Syysean Nov 11, 2026
5fd8bd9
fix(build): Linux 构建前自动拉取 OceanPlugin
Syysean Nov 12, 2026
147a125
fix(build): 移除跨模块的 ROV 桥接测试,修复编辑器构建失败
Syysean Nov 13, 2026
5ed6806
fix(package): 恢复 RoadRunner/Cesium 插件启用,修复 cook 失败
Syysean Nov 13, 2026
3ab612e
fix(build): 修复 Windows 找不到 MuJoCo 头文件,恢复中电软件园 cook 配置
Syysean Nov 14, 2026
d80635a
fix(build): 打包构建并发降到 4,规避链接阶段的静默失败
Syysean Nov 14, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/build_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ jobs:
make check.smoke
make check.air
make check.vr
make check.water
make check.python
shell: cmd

Expand Down
19 changes: 18 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,21 @@ profiler.csv
.venv
devcontainer.json
CarlaUE4.xcworkspace
OptionalModules.ini
OptionalModules.ini
CesiumForUnreal*
Unreal/CarlaUE4/Plugins/AirSim/

# --- 水下仿真整合(2026-11)---
# HoloOcean 八叉树运行时缓存,由插件在运行时生成
Unreal/CarlaUE4/Octrees/
# Cook 阶段生成的材质清单
materials.csv
# 修改 .uproject 前留的备份
*.uproject.bak*
# 本地调参用的 AirSim 配置副本(正式配置在 Unreal/<project>/settings.json)
/settings.json
/settings_rov.json

# OceanPlugin(UE4.26 原生海洋/水下材质库,234 MB)
# 体积大且是第三方仓库,不入库;用 Unreal/CarlaUE4/Plugins/setup_ocean_plugin.ps1 拉取
Unreal/CarlaUE4/Plugins/OceanPlugin/
134 changes: 125 additions & 9 deletions CarlaAir.ps1
Original file line number Diff line number Diff line change
@@ -1,10 +1,48 @@
<#
.SYNOPSIS
CarlaAir 联合仿真一键启动与自动化调试器 (Windows Launcher)

.DESCRIPTION
本脚本是面向开发者在本地开发与算法调试阶段的一键启动工具,用于自动化拉起 CARLA 与 AirSim 联合仿真环境。

【与 StartOpenHUTB.bat / CarlaUE4.exe 的区别与工作流定位】:
- StartOpenHUTB.bat / CarlaUE4.exe:
面向最终发布/打包(Package)版本用户的标准启动方式。主要用于部署后直接运行打包好的二进制文件,并自动检查 VC++ 运行库。
- CarlaAir.ps1:
面向开发人员与算法测试人员的 PowerShell 自动化启动脚本。具备以下高级特性:
1. 自动定位本地 Carla 可执行文件(支持 Editor 模式、开发构建与 WindowsNoEditor 打包模式);
2. 灵活指定仿真地图(默认 Town10HD)、窗口分辨率、画质等级;
3. 支持载具视角快速切换(通过 --vehicle 参数在空中无人机 drone 与水下机器人 rov 之间自动切换);
4. 自动分发对应的 AirSim 配置文件到 ~/Documents/AirSim/settings.json;
5. 自动检测 CARLA (2000) 和 AirSim (41451) 端口连通性,并在就绪后自动拉起背景交通流进程 (auto_traffic.py);
6. 支持实例健康监控、日志追踪 (--log) 与一键清理停止 (--kill)。

.EXAMPLE
# 启动水下机器人 ROV 仿真(默认地图 Town10HD)
.\CarlaAir.ps1 --vehicle rov

# 启动空中多旋翼无人机仿真
.\CarlaAir.ps1 --vehicle drone

# 在 Town10HD 上启动 ROV,禁用背景交通流,并挂接控制台查看输出
.\CarlaAir.ps1 Town10HD --vehicle rov --no-traffic --fg

# 停止当前运行的 CarlaAir 实例
.\CarlaAir.ps1 --kill
#>

$ErrorActionPreference = "Stop"

function Show-Usage {
@"
Usage: .\CarlaAir.ps1 [MAP] [OPTIONS]

Workflow Note:
- For packaged end-user deployments: Use StartOpenHUTB.bat or CarlaUE4.exe.
- For development & automated co-simulation testing: Use .\CarlaAir.ps1.

Options:
--vehicle TYPE Vehicle type to spawn: 'rov' (default) or 'drone'
--res WxH Window resolution (default: 1280x720)
--port PORT CARLA RPC port (default: 2000)
--quality LEVEL Quality level: Low, Medium, High, Epic
Expand Down Expand Up @@ -149,6 +187,25 @@ function Resolve-CarlaBinary {
}
}

$editorCandidates = @()
if ($env:UE4_ROOT) {
$p = Join-Path $env:UE4_ROOT "Engine\Binaries\Win64\UE4Editor.exe"
if (Test-Path $p) { $editorCandidates += $p }
}
$defaultEditor = "E:\Projects\hutb_editor\hutb_editor\unreal\Engine\Binaries\Win64\UE4Editor.exe"
if (Test-Path $defaultEditor) { $editorCandidates += $defaultEditor }

$uproject = Join-Path $RepoRoot "Unreal\CarlaUE4\CarlaUE4.uproject"
if (($editorCandidates.Count -gt 0) -and (Test-Path $uproject)) {
return @{
Binary = (Resolve-Path $editorCandidates[0]).Path
WorkingDirectory = Split-Path -Parent $uproject
NeedsProjectArg = $false
IsEditor = $true
ProjectFile = (Resolve-Path $uproject).Path
}
}

throw "No Windows Carla binary found. Build the project first with .\BuildWindows.ps1."
}

Expand Down Expand Up @@ -221,6 +278,7 @@ function Stop-CarlaAirProcess {

$repoRoot = Split-Path -Parent $MyInvocation.MyCommand.Path
$mapName = "Town10HD"
$vehicleType = "rov"
$resX = 1280
$resY = 720
$carlaPort = 2000
Expand All @@ -239,6 +297,7 @@ for ($i = 0; $i -lt $args.Count; $i++) {
$arg = [string]$args[$i]
switch -Regex ($arg) {
'^--help$|^-h$' { Show-Usage; exit 0 }
'^--vehicle$' { $i++; $vehicleType = ([string]$args[$i]).ToLower(); continue }
'^--fg$' { $foreground = $true; continue }
'^--kill$' { $killOnly = $true; continue }
'^--log$' { $showLog = $true; continue }
Expand Down Expand Up @@ -287,23 +346,63 @@ if ($showLog) {
$binaryInfo = Resolve-CarlaBinary -RepoRoot $repoRoot -ExplicitPackageRoot $explicitPackageRoot
$trafficPython = if ($autoTraffic) { Resolve-TrafficPython -ExplicitPath $explicitPython } else { $null }

$airsimSettingsSource = Join-Path $repoRoot "AirSimConfig\settings.json"
if (-not (Test-Path $airsimSettingsSource)) {
throw "AirSim settings template not found: $airsimSettingsSource"
$settingsFileName = if ($vehicleType -eq "drone" -or $vehicleType -eq "multirotor") {
"settings_drone.json"
} else {
"settings_rov.json"
}

$candidateSources = @(
(Join-Path $repoRoot "Unreal\CarlaUE4\$settingsFileName"),
(Join-Path $repoRoot $settingsFileName),
(Join-Path $repoRoot "AirSimConfig\$settingsFileName")
)

$airsimSettingsSource = $null
foreach ($cand in $candidateSources) {
if (Test-Path $cand) {
$airsimSettingsSource = $cand
break
}
}

if (-not $airsimSettingsSource) {
$fallbackSources = @(
(Join-Path $repoRoot "Unreal\CarlaUE4\settings.json"),
(Join-Path $repoRoot "settings.json"),
(Join-Path $repoRoot "AirSimConfig\settings.json")
)
foreach ($fb in $fallbackSources) {
if (Test-Path $fb) {
$airsimSettingsSource = $fb
break
}
}
}

if (-not $airsimSettingsSource) {
throw "AirSim settings template not found: $settingsFileName. Checked paths: $($candidateSources -join ', ')"
}

$airsimSettingsDir = Join-Path $env:USERPROFILE "Documents\AirSim"
$airsimSettingsTarget = Join-Path $airsimSettingsDir "settings.json"
New-Item -ItemType Directory -Force -Path $airsimSettingsDir | Out-Null
Copy-Item $airsimSettingsSource $airsimSettingsTarget -Force
Write-Host "AirSim Settings: Dispatched $settingsFileName -> $airsimSettingsTarget"

Stop-CarlaAirProcess -RepoRoot $repoRoot

$launchArgs = New-Object System.Collections.Generic.List[string]
if ($binaryInfo.NeedsProjectArg) {
if ($binaryInfo.IsEditor) {
$launchArgs.Add("`"$($binaryInfo.ProjectFile)`"")
$launchArgs.Add($mapName)
$launchArgs.Add("-game")
} elseif ($binaryInfo.NeedsProjectArg) {
$launchArgs.Add("CarlaUE4")
$launchArgs.Add($mapName)
} else {
$launchArgs.Add($mapName)
}
$launchArgs.Add($mapName)
$launchArgs.Add("-windowed")
$launchArgs.Add("-ResX=$resX")
$launchArgs.Add("-ResY=$resY")
Expand All @@ -319,6 +418,7 @@ Write-Host "============================================"
Write-Host " CarlaAir - Windows Launcher"
Write-Host "============================================"
Write-Host " Map: $mapName"
Write-Host " Vehicle: $vehicleType ($settingsFileName)"
Write-Host " Resolution: ${resX}x${resY}"
Write-Host " CARLA Port: $carlaPort"
Write-Host " AirSim Port: $airsimPort"
Expand All @@ -344,7 +444,8 @@ Set-Content -Path $pidFile -Value $process.Id

Write-Host "Waiting for CARLA port..."
$carlaReady = $false
for ($attempt = 0; $attempt -lt 120; $attempt++) {
$maxAttemptsCarla = if ($binaryInfo.IsEditor) { 900 } else { 120 }
for ($attempt = 0; $attempt -lt $maxAttemptsCarla; $attempt++) {
Start-Sleep -Seconds 2
if ($process.HasExited) {
throw "CarlaAir exited early. Check $logFile"
Expand All @@ -354,20 +455,27 @@ for ($attempt = 0; $attempt -lt 120; $attempt++) {
$carlaReady = $true
break
}
if ($attempt % 10 -eq 0 -and $attempt -gt 0) {
Write-Host " Still waiting for CARLA port ($($attempt * 2)s / $($maxAttemptsCarla * 2)s)..."
}
}
if (-not $carlaReady) {
throw "CARLA port $carlaPort did not become ready within 240 seconds. Check $logFile"
throw "CARLA port $carlaPort did not become ready within $($maxAttemptsCarla * 2) seconds. Check $logFile"
}

Write-Host "Waiting for AirSim port..."
$airsimReady = $false
for ($attempt = 0; $attempt -lt 60; $attempt++) {
$maxAttemptsAirSim = if ($binaryInfo.IsEditor) { 300 } else { 60 }
for ($attempt = 0; $attempt -lt $maxAttemptsAirSim; $attempt++) {
Start-Sleep -Seconds 2
if (Test-Port -Port $airsimPort) {
Write-Host " AirSim (port $airsimPort): Ready"
$airsimReady = $true
break
}
if ($attempt % 10 -eq 0 -and $attempt -gt 0) {
Write-Host " Still waiting for AirSim port ($($attempt * 2)s / $($maxAttemptsAirSim * 2)s)..."
}
}
if (-not $airsimReady) {
throw "AirSim port $airsimPort did not become ready within 120 seconds. Check $logFile"
Expand All @@ -377,8 +485,12 @@ if ($autoTraffic) {
if (($trafficVehicles -eq 0) -and ($trafficWalkers -eq 0)) {
Write-Host "Traffic disabled by count (0 vehicles + 0 walkers)."
} elseif ($trafficPython) {
$autoTrafficScript = Join-Path $repoRoot "PythonAPI\examples\air\auto_traffic.py"
if (-not (Test-Path $autoTrafficScript)) {
$autoTrafficScript = Join-Path $repoRoot "auto_traffic.py"
}
$trafficArgs = @(
(Join-Path $repoRoot "auto_traffic.py"),
$autoTrafficScript,
"--vehicles", [string]$trafficVehicles,
"--walkers", [string]$trafficWalkers,
"--port", [string]$carlaPort
Expand All @@ -394,3 +506,7 @@ if ($autoTraffic) {
Write-Host ""
Write-Host "CarlaAir is ready."
Write-Host "Log: $logFile"

if (-not $foreground) {
Wait-Process -Id $process.Id
}
10 changes: 5 additions & 5 deletions PythonAPI/carla/README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
这是 HUTB Python API 的 Python 包,用于控制和与 [HUTB](https://github.com/OpenHUTB/hutb)(用于人车研究的开源模拟器)进行通信。
这是 OpenHUTB 模拟器 的 Python API 包,用于控制和与 [OpenHUTB](https://github.com/OpenHUTB/hutb)(用于人车研究的开源模拟器)进行通信。

此包允许您控制 HUTB 模拟器并通过 Python API 检索模拟数据。例如,您可以控制模拟中的任何参与者(人、车、无人机、交通信号灯等),将传感器连接到参与者,并读取传感器数据等。
此包允许您控制 OpenHUTB 模拟器并通过 Python API 检索模拟数据。例如,您可以控制模拟中的任何参与者(人、车、无人机、交通信号灯等),将传感器连接到参与者,并读取传感器数据等。

## 开发

```shell
cd hutb/PythonAPI/carla
# 实现编辑模式安装
# 实现编辑模式安装(注意关闭代理)
# 修改 setup.py 后需要再次运行才会生效
pip install -e .
# 测试 API
python ../util/config.py -l
python ../examples/holoocean/getting_started.py
python ../examples/water/getting_started.py
```

更多信息,请参阅 [HUTB 文档](https://openhutb.github.io/) 。
更多信息,请参阅 [OpenHUTB 文档](https://openhutb.github.io/) 。
102 changes: 101 additions & 1 deletion PythonAPI/carla/source/airsim/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1618,4 +1618,104 @@ def getCarControls(self, vehicle_name=''):
CarControls:
"""
controls_raw = self.client.call('getCarControls', vehicle_name)
return CarControls.from_msgpack(controls_raw)
return CarControls.from_msgpack(controls_raw)

#----------------------------------- ROV APIs ---------------------------------------------
class RovClient(VehicleClient, object):
def __init__(self, ip = "", port = 41451, timeout_value = 3600):
super(RovClient, self).__init__(ip, port, timeout_value)

def takeoffAsync(self, timeout_sec = 20, vehicle_name = ''):
return self.client.call_async('takeoff', timeout_sec, vehicle_name)

def landAsync(self, timeout_sec = 60, vehicle_name = ''):
return self.client.call_async('land', timeout_sec, vehicle_name)

def goHomeAsync(self, timeout_sec = 3e+38, vehicle_name = ''):
return self.client.call_async('goHome', timeout_sec, vehicle_name)

def hoverAsync(self, vehicle_name = ''):
return self.client.call_async('hover', vehicle_name)

def moveByVelocityBodyFrameAsync(self, vx, vy, vz, duration, drivetrain = DrivetrainType.MaxDegreeOfFreedom, yaw_mode = YawMode(), vehicle_name = ''):
return self.client.call_async('moveByVelocityBodyFrame', vx, vy, vz, duration, drivetrain, yaw_mode, vehicle_name)

def moveByVelocityZBodyFrameAsync(self, vx, vy, z, duration, drivetrain = DrivetrainType.MaxDegreeOfFreedom, yaw_mode = YawMode(), vehicle_name = ''):
return self.client.call_async('moveByVelocityZBodyFrame', vx, vy, z, duration, drivetrain, yaw_mode, vehicle_name)

def moveByMotorPWMsAsync(self, pwm_values, duration, vehicle_name = ''):
return self.client.call_async('moveByMotorPWMs', pwm_values, duration, vehicle_name)

def moveByRollPitchYawZAsync(self, roll, pitch, yaw, z, duration, vehicle_name = ''):
return self.client.call_async('moveByRollPitchYawZ', roll, pitch, yaw, z, duration, vehicle_name)

def moveByRollPitchYawThrottleAsync(self, roll, pitch, yaw, throttle, duration, vehicle_name = ''):
return self.client.call_async('moveByRollPitchYawThrottle', roll, pitch, yaw, throttle, duration, vehicle_name)

def moveByRollPitchYawrateThrottleAsync(self, roll, pitch, yaw_rate, throttle, duration, vehicle_name = ''):
return self.client.call_async('moveByRollPitchYawrateThrottle', roll, pitch, yaw_rate, throttle, duration, vehicle_name)

def moveByRollPitchYawrateZAsync(self, roll, pitch, yaw_rate, z, duration, vehicle_name = ''):
return self.client.call_async('moveByRollPitchYawrateZ', roll, pitch, yaw_rate, z, duration, vehicle_name)

def moveByAngleRatesZAsync(self, roll_rate, pitch_rate, yaw_rate, z, duration, vehicle_name = ''):
return self.client.call_async('moveByAngleRatesZ', roll_rate, pitch_rate, yaw_rate, z, duration, vehicle_name)

def moveByAngleRatesThrottleAsync(self, roll_rate, pitch_rate, yaw_rate, throttle, duration, vehicle_name = ''):
return self.client.call_async('moveByAngleRatesThrottle', roll_rate, pitch_rate, yaw_rate, throttle, duration, vehicle_name)

def moveByVelocityAsync(self, vx, vy, vz, duration, drivetrain = DrivetrainType.MaxDegreeOfFreedom, yaw_mode = YawMode(), vehicle_name = ''):
return self.client.call_async('moveByVelocity', vx, vy, vz, duration, drivetrain, yaw_mode, vehicle_name)

def moveByVelocityZAsync(self, vx, vy, z, duration, drivetrain = DrivetrainType.MaxDegreeOfFreedom, yaw_mode = YawMode(), vehicle_name = ''):
return self.client.call_async('moveByVelocityZ', vx, vy, z, duration, drivetrain, yaw_mode, vehicle_name)

def moveOnPathAsync(self, path, velocity, timeout_sec = 3e+38, drivetrain = DrivetrainType.MaxDegreeOfFreedom, yaw_mode = YawMode(),
lookahead = -1, adaptive_lookahead = 1, vehicle_name = ''):
return self.client.call_async('moveOnPath', path, velocity, timeout_sec, drivetrain, yaw_mode, lookahead, adaptive_lookahead, vehicle_name)

def moveToGPSAsync(self, latitude, longitude, altitude, velocity, timeout_sec = 3e+38, drivetrain = DrivetrainType.MaxDegreeOfFreedom,
yaw_mode = YawMode(), lookahead = -1, adaptive_lookahead = 1, vehicle_name = ''):
return self.client.call_async('moveToGPS', latitude, longitude, altitude, velocity, timeout_sec, drivetrain, yaw_mode, lookahead, adaptive_lookahead, vehicle_name)

def moveToPositionAsync(self, x, y, z, velocity, timeout_sec = 3e+38, drivetrain = DrivetrainType.MaxDegreeOfFreedom,
yaw_mode = YawMode(), lookahead = -1, adaptive_lookahead = 1, vehicle_name = ''):
return self.client.call_async('moveToPosition', x, y, z, velocity, timeout_sec, drivetrain, yaw_mode, lookahead, adaptive_lookahead, vehicle_name)

def moveToZAsync(self, z, velocity, timeout_sec = 3e+38, yaw_mode = YawMode(), lookahead = -1, adaptive_lookahead = 1, vehicle_name = ''):
return self.client.call_async('moveToZ', z, velocity, timeout_sec, yaw_mode, lookahead, adaptive_lookahead, vehicle_name)

def moveByManualAsync(self, vx_max, vy_max, z_min, duration, drivetrain = DrivetrainType.MaxDegreeOfFreedom, yaw_mode = YawMode(), vehicle_name = ''):
return self.client.call_async('moveByManual', vx_max, vy_max, z_min, duration, drivetrain, yaw_mode, vehicle_name)

def rotateToYawAsync(self, yaw, timeout_sec = 3e+38, margin = 5, vehicle_name = ''):
return self.client.call_async('rotateToYaw', yaw, timeout_sec, margin, vehicle_name)

def rotateByYawRateAsync(self, yaw_rate, duration, vehicle_name = ''):
return self.client.call_async('rotateByYawRate', yaw_rate, duration, vehicle_name)

def setAngleLevelControllerGains(self, kp, ki, kd, vehicle_name = ''):
self.client.call('setAngleLevelControllerGains', kp, ki, kd, vehicle_name)

def setAngleRateControllerGains(self, kp, ki, kd, vehicle_name = ''):
self.client.call('setAngleRateControllerGains', kp, ki, kd, vehicle_name)

def setVelocityControllerGains(self, kp, ki, kd, vehicle_name = ''):
self.client.call('setVelocityControllerGains', kp, ki, kd, vehicle_name)

def setPositionControllerGains(self, kp, ki, kd, vehicle_name = ''):
self.client.call('setPositionControllerGains', kp, ki, kd, vehicle_name)

def moveByRC(self, rc_data, vehicle_name = ''):
self.client.call('moveByRC', rc_data, vehicle_name)

def simSetRovPose(self, pose, tilt_angles, ignore_collision = True, spin_props = False, vehicle_name = ''):
self.client.call('simSetRovPose', pose, tilt_angles, ignore_collision, spin_props, vehicle_name)

def getRotorStates(self, vehicle_name = ''):
return RotorTiltableStates.from_msgpack(self.client.call('getRotorStates', vehicle_name))
getRotorStates.__annotations__ = {'return': RotorTiltableStates}

def getRovState(self, vehicle_name = ''):
return RovState.from_msgpack(self.client.call('getRovState', vehicle_name))
getRovState.__annotations__ = {'return': RovState}
Loading
Loading