UAV Control Applications
This section mainly explains how to control the UAV with Prometheus Ground Station Pro.
18 min read · English documentationThis section mainly explains how to control the UAV with Prometheus Ground Station Pro.
By default, connecting Prometheus Ground Station Pro successfully also starts the uav_control node automatically. To use trajectory tracking, restart the trajectory tracking node separately.
You can familiarize yourself with the Prometheus control interfaces in advance. For details, see Introduction to the Prometheus Control Node.
1. Before using the following control interfaces, set the positioning source to RTK (outdoors) or MID360 (indoors and outdoors). See Positioning Source Switching for the operating procedure.
2. Check the relevant data carefully.
- Power on the UAV before performing the following operations.
Connection Process
Disconnect
Before connecting, use the ground station to close the connection. For details, see Starting and Connecting Prometheus Ground Station Pro.
Disconnecting kills all nodes run by the previous function and does not affect new nodes. If no function nodes were run previously, you can skip the disconnect operation.
Reconnect
After closing the connection, reconnect. For details, see Starting and Connecting Prometheus Ground Station Pro.
Check Whether the UAV Status Is Normal
Start MID360 Positioning
- Connect to the UAV in Connection Settings (the positioning source must be switched to MID360 positioning).
- Under Function Scripts, click
P600_MID360 Positioning.
- The onboard command is:
/home/amov/p600_experiment/src/p600_experiment/scripts/mid360_location.sh
- The status bar displays the current UAV status (whether the UAV flight controller is connected, the current flight mode, control status, MID360 positioning status, whether the UAV is armed, etc.).
- A red Prometheus status indicator means that the status is abnormal. The figure below shows a normal status.
- The x, y, and z positions should be around 0, indicating that the positioning data is normal.

RTK Positioning
- Connect to the UAV in Connection Settings (the positioning source must be switched to RTK positioning).
- The status bar displays the current UAV status (whether the UAV flight controller is connected, the current flight mode, control status, RTK positioning status, whether the UAV is armed, etc.).
- The x, y, and z positions should be around 0, indicating that the positioning data is normal.
- A red Prometheus status indicator means that the status is abnormal. The figure below shows a normal status.

Check the Data
Handling Abnormal Data
- It is normal for the initial position data to be close to 0.
- If the initial position data has an excessive error greater than 0.5, it is abnormal. Perform the EKF2 reset below (this is usually caused by an initial data-fusion error or accumulated error after multiple flights).
MID360 positioning is normal

RTK positioning is normal

1. The following two scripts, ekf2 stop and ekf2 start, reinitialize EKF2 fusion for the flight controller's position data when the initial data is abnormal or the error is excessive under RTK/MID360 positioning.
2. Run these scripts while checking the data before takeoff. Do not click or use them during flight, as doing so may cause loss of positioning and a crash. (This will be updated later to prevent accidental activation; refer to the official release notes for the applicable behavior.)
Initial Data
- Click Function Scripts in the ground station.
- Click ekf2 stop.
- Click ekf2 start.

Remote Controller Operation
| Name | Toggle Switch | Top Position | Middle Position | Bottom Position |
|---|---|---|---|---|
| H16 Remote Controller | SW1 | Disarm the UAV | Not enabled | Arm the UAV |
| SW2 | POSCTL remote-controller position-hold mode in the INIT control state; the coordinate frame is based on the UAV's body frame |
Remote-controller control mode in OFFBOARD mode under the RC_POS_CONTROL control state; the coordinate frame is based on the ENU inertial frame |
Autonomous control mode in OFFBOARD mode under the COMMAND_CONTROL control state |
|
| SW3 | Disable emergency landing | Not enabled | Enable emergency landing (the propellers stop immediately) | |
| SW4 | Disable landing | Not enabled | Enable landing (slow descent) |
First move SW2 to the middle position to enter RC_POS mode, and then move it to the bottom position to enter COMMAND mode. In an emergency, quickly move SW2 to the top position to enter INIT manual position-hold mode and control the UAV. (RC_POS_CONTROL is offboard manual control and can also control the UAV, but direct throttle landing may not be possible.) In an emergency, moving SW3 to the bottom position stops the propellers immediately; this is not recommended except under exceptional circumstances.
Autonomous Control in COMMAND_CONTROL
Return to the main interface to send UAV control commands. To control the UAV using Prometheus Ground Station Pro as described below, move SW2 on the H16 controller to the bottom position. The UAV control state then switches to COMMAND_CONTROL.

Control Interface Introduction
-
- Control-interface panel
-
- Hover at Current Point: Keep the UAV hovering at its current position (generally used after Move mode).
-
- Hover at Initial Point: The UAV flies back to the initial COMMAND_CONTROL position. (The initial position is the UAV's initial takeoff position; the altitude can be configured with the initial takeoff altitude parameter.)
-
- Land: Land the UAV and enter LAND_CONTROL mode.
-
- Move mode: Select among its submodes and enter control values matching the selected submode. (The default submode is XYZ_POS inertial-frame position control.)
-
- Control-value entry: Enter control values matching the selected submode.
- x: East in the inertial ENU coordinate frame, or forward along the nose in the body coordinate frame. Unit: m.
- y: North in the inertial ENU coordinate frame, or left of the nose in the body coordinate frame. Unit: m.
- z: Upward in the inertial ENU coordinate frame, or upward in the body coordinate frame. Unit: m.
- yaw: Desired heading in the inertial ENU coordinate frame. Unit: degrees. (The ground station interface uses degrees; the source-code interface reserved for secondary development uses radians.)
-
- Upload button: After entering the desired data, click Upload to send it to the UAV.
Move-Mode Submodes
Reference 1: Prometheus Ground Station Pro Move Mode Introduction
Reference 2: Prometheus Source-Code msg Definition
-
- Inertial-frame position control (XYZ_POS)
-
- Inertial-frame altitude-hold velocity control (XY_VEL_Z_POS)
-
- Inertial-frame velocity control (XYZ_VEL)
-
- Body-frame position control (XYZ_POS_BODY)
-
- Body-frame velocity control (XYZ_VEL_BODY)
-
- Body-frame altitude-hold velocity control (XY_VEL_Z_POS_BODY)
-
- Trajectory control (TRAJETCORY)
-
- Attitude control (XYZ_ATT)
-
- Latitude, longitude, and altitude control (LAT_LON_ALT)
Test Flight
The following test assumes that video push/pull streaming is enabled, the UAV has just been connected, the H16 remote controller is configured, and SW1, SW2, SW3, and SW4 are all in the top position.
- Move SW1 to the bottom position to arm the UAV. Immediately raise the throttle and manually take off to an altitude of about 0.5 m. SW2, SW3, and SW4 should be in the top position.
- The current Prometheus control status is INIT, which corresponds to the flight controller's POSITION mode.
- Move SW2 to the middle position.
- The current Prometheus control status is RC_POS_CONTROL, which is also the flight controller's OFFBOARD mode.
- Move SW2 to the bottom position. SW3 and SW4 should be in the top position at this time.
- The current Prometheus control status is COMMAND_CONTROL, which is also the flight controller's OFFBOARD mode.
- The UAV hovers at the initial point (0, 0, 1.5) with its nose facing due east.
1. After entering Prometheus-controlled COMMAND_CONTROL mode, the UAV responds to control commands from the onboard computer. You do not need to operate the remote controller at this time and can set it aside while continuing to monitor the flight.
2. If the UAV status becomes abnormal, take manual control with the remote controller, move SW2 to the top position, and land the UAV manually.
Land the UAV
Land Using Prometheus Control
Landing Method 1: Send a Landing Command from the Prometheus Ground Station
- Check the current UAV status.
- Click Data Monitoring.
- Click Land.
- The Prometheus-controlled landing begins.
Landing Method 2: Send a Landing Command with the H16 Remote Controller
- After the ground station is connected to the UAV and its status is normal, move
SW4to the bottom position to perform a Prometheus-controlled landing.
Landing Method 3: Land Manually
- Move
SW2to the top position to enter flight-controller-controlled POSITION mode. The UAV now responds to the remote controller.
- Slowly move the left stick all the way down to control the UAV's landing manually.
- After the UAV lands, wait for it to disarm automatically, or move SW3 to the bottom position to stop the propellers with one switch action.
Ground Station Virtual-Joystick Control
The virtual joystick mainly uses the body-frame velocity control (XYZ_VEL_BODY) interface, so the UAV's nose direction is the positive X-axis direction.
- Move SW1 to arm the UAV.
- Move SW2 to the bottom position. The control state changes to COMMAND_CONTROL and the mode changes to OFFBOARD. The UAV automatically flies to the preset location, altitude, and direction, as shown below. From this point, control operations are performed on the computer.

- Click System Settings.
- Click Basic Settings.
- Click Virtual Joystick Settings.
- Enter the maximum X, Y, Z, and yaw speeds.
- Click Save for each setting.
- Check whether the current speeds were saved successfully.
- The current speeds have changed to the entered values.
- Click this icon. It is currently disabled.
- The virtual joystick is enabled successfully and appears as follows.
Mouse-Drag Control
- After the virtual joystick is enabled, its control icon appears in the Video Monitoring area of the main interface.
- Press and hold the left mouse button, then drag up, down, left, or right to move the UAV forward, backward, left, or right.
- Press and hold the right mouse button. Drag up or down to control the UAV's Z-axis altitude, or left or right to control the UAV's yaw.
- Release the mouse button to stop the UAV.
- Check the current UAV status.
- Left-click the cyan circle, keep holding the left button, and drag upward to move the UAV forward.
- The desired X speed under virtual-joystick control is 0.64 m/s.
- Left-click the cyan circle, keep holding the left button, and drag downward to move the UAV backward.
- The desired X speed under virtual-joystick control is -0.75 m/s.
- Left-click the cyan circle, keep holding the left button, and drag left to move the UAV left.
- The desired Y speed under virtual-joystick control is 0.82 m/s.
- Left-click the cyan circle, keep holding the left button, and drag right to move the UAV right.
- The desired Y speed under virtual-joystick control is -0.92 m/s.
- Right-click the cyan circle, keep holding the right button, and drag upward to move the UAV upward.
- The desired Z speed under virtual-joystick control is 0.45 m/s.
- Right-click the cyan circle, keep holding the right button, and drag downward to move the UAV downward.
- The desired Z speed under virtual-joystick control is -0.73 m/s.
- Right-click the cyan circle, keep holding the right button, and drag left to turn the UAV left.
- Right-click the cyan circle, keep holding the right button, and drag right to turn the UAV right.
Keyboard Control
- Use the keyboard arrow keys to move the UAV forward, backward, left, and right, equivalent to left-clicking and dragging the virtual joystick.
- Use Shift+Up/Down to control the UAV's Z-axis altitude and Shift+Left/Right to control its yaw, equivalent to right-clicking and dragging the virtual joystick.
- Press the Home key to return to the initial point and hover.
Before performing the following operations, understand how the UAV will fly after the command is sent, and only then click Upload. If the UAV position data in the upper-right corner does not match the actual position, land the UAV and reset the EKF2 positioning data in QGC.
XYZ_POS
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select XYZ_POS.
- Enter
1to move the UAV to the position 1 m in the positive X-axis direction in the ENU coordinate frame. - Enter
0to move the UAV to Y = 0, the origin, in the ENU coordinate frame. - Enter
1.5to move the UAV to the position 1.5 m in the positive Z-axis direction in the ENU coordinate frame. - Enter
0to leave the UAV's yaw unchanged. - Click Upload. The UAV moves to (1, -0, 1.5) in the inertial frame. (0, 0, 0) is the position where the UAV was powered on.
- The UAV's current position in the ENU coordinate frame is displayed.
- The UAV's current desired position in the ENU coordinate frame is displayed.
- The UAV reaches the uploaded target point.
XY_VEL_Z_POS
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select XY_VEL_Z_POS.
- Enter
1to make the UAV move continuously at 1 m/s in the positive X-axis direction in the ENU coordinate frame. - Enter
1to make the UAV move continuously at 1 m/s in the positive Y-axis direction in the ENU coordinate frame. - Enter
1.5to move the UAV to the position 1.5 m in the positive Z-axis direction in the ENU coordinate frame. - Enter
0to leave the UAV's yaw unchanged.
When controlling the UAV's velocity, the UAV continues to move.
Click Hover at Current Point to hover at the UAV's current position, or move SW2 to the top position to take manual control.
- Click Upload.
- The UAV's current position in the ENU coordinate frame is displayed.
- The UAV's current desired position in the ENU coordinate frame is displayed.
- The UAV begins responding to the uploaded velocity control.
XYZ_VEL
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select XYZ_VEL.
- Enter
1to make the UAV move continuously at 1 m/s in the positive X-axis direction in the ENU coordinate frame. - Enter
1to make the UAV move continuously at 1 m/s in the positive Y-axis direction in the ENU coordinate frame. - Enter
1to make the UAV move continuously at 1 m/s in the positive Z-axis direction in the ENU coordinate frame. - Enter
0to leave the UAV's direction unchanged.
When controlling the UAV's velocity, the UAV continues to move.
Click Hover at Current Point to hover at the UAV's current position, or move SW2 to the top position to take manual control.
- Click Upload.
- The UAV's current desired position in the ENU coordinate frame is displayed.
- Click Hover at Current Point.
- The UAV begins responding to the uploaded velocity control.
XYZ_POS_BODY
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select XYZ_POS_BODY.
- Enter
1to move the UAV forward by 1 m in the body frame. - Enter
0so that the UAV does not change position in the body frame. - Enter
0so that the UAV does not change position in the body frame. - Enter
0to leave the UAV's direction unchanged. - Click Upload.
- Click Hover at Current Point to hover at the UAV's current position.
- The UAV's current desired position is (8.8, 8.56, 1.92).
- The UAV begins responding to the uploaded position control. The current desired position is (9.8, 8.56, 1.92).
XYZ_VEL_BODY
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select XYZ_VEL_BODY.
- Enter
-1to make the UAV move continuously at 1 m/s in the negative X-axis direction in the body coordinate frame. - Enter
0to leave the UAV's Y-axis speed unchanged in the body coordinate frame. - Enter
0to leave the UAV's Z-axis speed unchanged in the body coordinate frame. - Enter
0to leave the UAV's direction unchanged.
When controlling the UAV's velocity, the UAV continues to move.
Click Hover at Current Point to hover at the UAV's current position, or move SW2 to the top position to take manual control.
- Click Upload.
- Click Hover at Current Point.
- The UAV's current desired velocity is displayed.
- The UAV begins responding to the uploaded velocity control.
XY_VEL_Z_POS_BODY
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select XY_VEL_Z_POS_BODY.
- Enter
1to make the UAV move continuously at 1 m/s in the positive X-axis direction in the body coordinate frame. - Enter
1to make the UAV move continuously at 1 m/s in the positive Y-axis direction in the body coordinate frame. - Enter
0to leave the UAV's Z-axis position unchanged in the body coordinate frame. - Enter
0to leave the UAV's direction unchanged.
When controlling the UAV's velocity, the UAV continues to move.
Click Hover at Current Point to hover at the UAV's current position, or move SW2 to the top position to take manual control.
- Click Upload.
- Click Hover at Current Point.
- The UAV's current desired position and velocity are displayed.
- The UAV begins responding to the uploaded velocity control.
LAT_LON_ALT
1. The UAV flies quickly when using this function. Fly in an open, unoccupied area and pay close attention to safety!!
2. Latitude, longitude, and altitude control is not available on the MID360 version.
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Select LAT_LON_ALT.
- Click Map Monitoring.
- Click Baidu Map.
- Select Offline Map. (If offline map data is unavailable, download it and place it in the ground station's configuration-file path.)
- Click Update Position.
- Click the icon. The cursor changes to a crosshair. Click the map to display the latitude and longitude of the selected location.
- Click the target position.
- A red marker appears after you click the target point.
- The latitude and longitude of the selected target point are populated automatically.
- Enter the flight altitude for this latitude, longitude, and altitude point-selection demo.
- Enter the yaw angle during flight.
- After confirmation, upload the target-position data.
- Hover at Current Point button
- Click the icon. The cursor changes to a hand. Left-click and drag on the map to move it.
- Enter
1.5to move the UAV to the position 1.5 m in the positive Z-axis direction in the ENU coordinate frame. - Enter
0to leave the UAV's direction unchanged. - Click Upload.
- The UAV's current position is displayed.
- The UAV responds to the control command and flies toward the target point.
- Click this icon to continue publishing target points.
Prometheus-Controlled Waypoint Planning
- Move SW1 to the bottom position to arm the UAV, and move SW2 to the bottom position. The UAV flies to the initial takeoff position.
- Click Main Interface.
- Click Map Monitoring.
- Click Baidu Map.
- Click Satellite.
- Select Offline Map. (If offline map data is unavailable, download it and place it in the ground station's configuration-file path.)
- Click Update Position.
- Click Clear Obstacles.
- Click this icon to plan multiple irregular waypoints.
- After clicking the waypoint icon in the previous step, the cursor changes as shown below. Left-click each target point in sequence to plan the route.
- Start point for the first point
- Second waypoint
- Third waypoint
- Fourth waypoint. To finish setting waypoints, double-click the left mouse button in the map.
- The completed waypoint setup is shown below.
- The four waypoints just created
- Modify the altitude of the corresponding waypoint.
- Save the changes.
- Click Function Scripts.
- Click the custom message containing the waypoints that you just created.
- Return to the map interface. The UAV begins following the waypoint plan.
TRAJETCORY
Confirm Trajectory-Control Parameters
- Click System Settings.
- Click Parameter Settings.
- Select Trajectory Control.
- Click Load.
- View the trajectory-control parameters.
Modify Trajectory-Control Parameters
- Circle and figure-eight center parameters take effect when trajectory-control parameters are next uploaded, so modify them before uploading trajectory control. (A change made now takes effect on the next upload.)
- Radius- and speed-related parameters take effect immediately after modification.
-
Double-click the corresponding value, enter a floating-point number, and press Enter.
-
Eight/omega: Angular velocity. A larger value makes tracking more difficult. Unit: rad/s.
- The default value of 0.3 can be used. The angular velocity does not need to be changed regardless of how the figure-eight radius changes.
-
Eight/radial: Radius. A smaller value makes tracking more difficult. Unit: m.
- The larger the radius, the higher the UAV speed.
- A message confirms that the parameters were modified and saved successfully.
Run Trajectory Control
- Click Main Interface.
- Click Map Monitoring.
- Move SW1 to the bottom position to arm the UAV. Push the left stick upward to take off to a certain altitude.
- Slowly move SW2 to the bottom position to enter Prometheus-controlled COMMAND_CONTROL mode.
- After entering COMMAND_CONTROL mode in the previous step, the UAV flies to the initial point and hovers.
- Click to switch the function mode.
- Select TRAJETCORY.
- Click Planar Map.
- Click to switch the function mode.
- Select Circle.
- Enter the total duration of the circular flight.
- In this example, the circle center is (8, 0, 3), the radius is 2 m, and the resultant speed is 0.5 m/s.
- Click Upload to begin.
- The UAV begins trajectory control, and the UAV trajectory is displayed on the planar map.
