How to use 6DOF Plant Model while flying obstacle avoidance in a photorealistic simulation environment?

1 view (last 30 days)
This question is linked to my earlier post. I am using the UAV Package Delivery Example to explore different variables (e.g., mass, inertia, diameter, velocity, altitude) that could affect the total mission time (simulation time) by conducting test simulations with different missions.
I found out that these parameters were used in the 6DOF plant model (see image below).
I tried using the 'Adding a High Fidelity Plant' script while engaging the QGroundControl (QGC).
useQGC = 1;
However, instead of avoiding the obstacles, the UAV just bashes through the buildings and has a very noisy flight path (see images below).
Is this possible in the first place? If so, what are other parameters should I tweak to make this work?

Answers (1)

Jianxin Sun
Jianxin Sun on 8 Feb 2022
Hi Robert,
After you used the "add high fidelity plant" short cut, you can use the following parameters:
useQGC = 1 % takes mission items from QGC
useQGC = 0 % use default mission items
useHeading = 0 % not force align the UAV's yaw and course angle
guidanceType = 1 % fly mission from waypoint to waypoint
guidanceType = 2 % use obstacle avoidance when flying to 2nd user specified waypoint
To enable high fidelity plant with obstacle avoidance flying default mission, use "add high fidelity plant" short cut then:
useHeading = 0 % not force align the UAV's yaw and course angle
guidanceType = 2 % use obstacle avoidance when flying to 2nd user specified waypoint
useQGC = 0 % use default mission items
The high fidelity plant's position controller is more sensitive to directional changes than the low fidelity plant. So the obstacle avoidance behavior could cause a lot oscillations. In this case, a more stable obstacle avoidance controller would be required. A place to look at would be in the "uavPackageDelivery/Multirotor (MultirotorModel)/Guidance Logic/Obstacle Avoidance" subsystem that computes the next target position based on obstacle free driection from 2D lidar readings.
Thanks,
Jianxin

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by