Windows下使用Airsim+QGC进行PX4硬件在环HITL
This tutorial will guide you through the installation of Airsim and QGC on Windows, so that the hardware-in-the-loop experiment can be conducted.
Hardware-in-the-Loop (HITL or HIL) is a simulation mode in which normal PX4 firmware is run on real flight controller hardware. This approach has the benefit of testing most of the actual flight code on the real hardware.
In 2017 Microsoft Research created AirSim (Aerial Informatics and Robotics Simulation) – an open-source robotics simulation platform. From ground vehicles, wheeled robotics, aerial drones, and even static IoT devices, AirSim enabled data capture data for models without costly field operations.
文章目录
- Windows下使用Airsim+QGC进行PX4硬件在环HITL
- (一)Required softwares
- (二)Preperation for HITL
- (三)HITL Testing
- 1, Launching order
- 2, HITL
- (四)Virtual flight in HITL
(一)Required softwares
Windows下使用Airsim+QGC进行PX4硬件在环HITL(一)
(二)Preperation for HITL
Windows下使用Airsim+QGC进行PX4硬件在环HITL(二)
(三)HITL Testing
1, Launching order
(1) Open QGC (Status: Disconnected)
(2) Connect Pixhawk
(3) Open Unreal Engine
2, HITL
Press the play button
If there is nothing wrong with the connection, you should see prompts like this:
QGC is connected too. Ignore the error reports. Status is Not Ready
. Click on the Not Ready
.
You will hear a voice reminder “Armed”, and the UAV in Airsim will rotate its propellers, preparing for flight. If there are no further actions in a few seconds, it will automatically disarm to stop the propellers rotating.
Send a takeoff command using QGC:
The drone will fly to the given height in Airsim.
To land the drone, you can click on the Land icon in QGC.
(四)Virtual flight in HITL
Windows下使用Airsim+QGC进行PX4硬件在环HITL(四)