docs(docs):Fixes that prettier does not handle well (#27212)

This commit is contained in:
Hamish Willee
2026-04-26 14:30:02 +10:00
committed by GitHub
parent 5fcd9043f3
commit 323c623e34
7 changed files with 171 additions and 170 deletions
@@ -35,7 +35,8 @@ Then adjust the sliders (as discussed below) to improve the tracking of the resp
- Use [Position mode](../flight_modes_mc/position.md) to tune the _Velocity Controller_ and the _Position Controller_.
Make sure to switch to the _Simple position control_ mode so you can generate step inputs.
![QGC PID tuning: Simple control selector](../../assets/mc_pid_tuning/qgc_mc_pid_tuning_simple_control.png)
:::
:::
## Preconditions
@@ -65,11 +66,11 @@ Make sure to have assigned a [Kill switch](../config/safety.md#emergency-switche
The tuning procedure is:
1. Arm the vehicle, takeoff, and hover (typically in [Position mode](../flight_modes_mc/position.md)).
1. Open _QGroundControl_ **Vehicle Setup > PID Tuning**
2. Open _QGroundControl_ **Vehicle Setup > PID Tuning**
![QGC Rate Controller Tuning UI](../../assets/mc_pid_tuning/qgc_mc_pid_tuning_rate_controller.png)
1. Select the **Rate Controller** tab.
1. Confirm that the airmode selector is set to **Disabled**
1. Set the _Thrust curve_ value to: 0.3 (PWM, power-based controllers) or 1 (RPM-based ESCs)
3. Select the **Rate Controller** tab.
4. Confirm that the airmode selector is set to **Disabled**
5. Set the _Thrust curve_ value to: 0.3 (PWM, power-based controllers) or 1 (RPM-based ESCs)
::: info
For PWM, power-based and (some) UAVCAN speed controllers, the control signal to thrust relationship may not be linear.
@@ -82,46 +83,49 @@ The tuning procedure is:
For more information see the [detailed PID tuning guide](../config_mc/pid_tuning_guide_multicopter.md#thrust-curve).
:::
1. Set the _Select Tuning_ radio button to: **Roll**.
1. (Optionally) Select the **Automatic Flight Mode Switching** checkbox.
6. Set the _Select Tuning_ radio button to: **Roll**.
7. (Optionally) Select the **Automatic Flight Mode Switching** checkbox.
This will _automatically_ switch from [Position mode](../flight_modes_mc/position.md) to [Stabilised mode](../flight_modes_mc/manual_stabilized.md) when you press the **Start** button
1. For rate controller tuning switch to _Acro mode_, _Stabilized mode_ or _Altitude mode_ (unless automatic switching is enabled).
1. Select the **Start** button in order to start tracking the setpoint and response curves.
1. Rapidly move the _roll stick_ full range and observe the step response on the plots.
:::tip
Stop tracking to enable easier inspection of the plots.
This happens automatically when you zoom/pan.
Use the **Start** button to restart the plots, and **Clear** to reset them.
:::
1. Modify the three PID values using the sliders (for roll rate-tuning these affect `MC_ROLLRATE_K`, `MC_ROLLRATE_I`, `MC_ROLLRATE_D`) and observe the step response again.
The values are saved to the vehicle as soon as the sliders are moved.
::: info
The goal is for the _Response_ curve to match the _Setpoint_ curve as closely as possible (i.e. a fast response without overshoots).
:::
The PID values can be adjusted as follows:
- P (proportional) or K gain:
- increase this for more responsiveness
- reduce if the response is overshooting and/or oscillating (up to a certain point increasing the D gain also helps).
- D (derivative) gain:
- this can be increased to dampen overshoots and oscillations
- increase this only as much as needed, as it amplifies noise (and can lead to hot motors)
- I (integral) gain:
- used to reduce steady-state error
- if too low, the response might never reach the setpoint (e.g. in wind)
- if too high, slow oscillations can occur
1. Repeat the tuning process above for the pitch and yaw:
- Use _Select Tuning_ radio button to select the axis to tune
- Move the appropriate sticks (i.e. pitch stick for pitch, yaw stick for yaw).
- For pitch tuning, start with the same values as for roll.
:::tip
Use the **Save to Clipboard** and **Reset from Clipboard** buttons to copy the roll settings for initial pitch settings.
:::
1. Repeat the tuning process for the attitude controller on all the axes.
1. Repeat the tuning process for the velocity and positions controllers (on all the axes).
- Use Position mode when tuning these controllers
- Select the **Simple position control** option in the _Position control mode ..._ selector (this allows direct control for the generation of step inputs)
8. For rate controller tuning switch to _Acro mode_, _Stabilized mode_ or _Altitude mode_ (unless automatic switching is enabled).
9. Select the **Start** button in order to start tracking the setpoint and response curves.
10. Rapidly move the _roll stick_ full range and observe the step response on the plots.
:::tip
Stop tracking to enable easier inspection of the plots.
This happens automatically when you zoom/pan.
Use the **Start** button to restart the plots, and **Clear** to reset them.
:::
11. Modify the three PID values using the sliders (for roll rate-tuning these affect `MC_ROLLRATE_K`, `MC_ROLLRATE_I`, `MC_ROLLRATE_D`) and observe the step response again.
The values are saved to the vehicle as soon as the sliders are moved.
![QGC PID tuning: Simple control selector](../../assets/mc_pid_tuning/qgc_mc_pid_tuning_simple_control.png)
::: info
The goal is for the _Response_ curve to match the _Setpoint_ curve as closely as possible (i.e. a fast response without overshoots).
:::
The PID values can be adjusted as follows:
- P (proportional) or K gain:
- increase this for more responsiveness
- reduce if the response is overshooting and/or oscillating (up to a certain point increasing the D gain also helps).
- D (derivative) gain:
- this can be increased to dampen overshoots and oscillations
- increase this only as much as needed, as it amplifies noise (and can lead to hot motors)
- I (integral) gain:
- used to reduce steady-state error
- if too low, the response might never reach the setpoint (e.g. in wind)
- if too high, slow oscillations can occur
12. Repeat the tuning process above for the pitch and yaw:
- Use _Select Tuning_ radio button to select the axis to tune
- Move the appropriate sticks (i.e. pitch stick for pitch, yaw stick for yaw).
- For pitch tuning, start with the same values as for roll.
:::tip
Use the **Save to Clipboard** and **Reset from Clipboard** buttons to copy the roll settings for initial pitch settings.
:::
13. Repeat the tuning process for the attitude controller on all the axes.
14. Repeat the tuning process for the velocity and positions controllers (on all the axes).
- Use Position mode when tuning these controllers
- Select the **Simple position control** option in the _Position control mode ..._ selector (this allows direct control for the generation of step inputs)
![QGC PID tuning: Simple control selector](../../assets/mc_pid_tuning/qgc_mc_pid_tuning_simple_control.png)
All done!
Remember to re-enable airmode before leaving the setup.
+26 -26
View File
@@ -22,8 +22,8 @@ Setup PX4 by following the normal guidelines:
To install _Eclipse_:
1. Download [Eclipse CDT for C/C++ Developers](https://github.com/eclipse-embed-cdt/org.eclipse.epp.packages/releases) (MCU GitHub).
1. Extract the Eclipse folder and copy it anywhere (there is no need to run any install scripts).
1. Run _Eclipse_ and choose a location for your initial workbench.
2. Extract the Eclipse folder and copy it anywhere (there is no need to run any install scripts).
3. Run _Eclipse_ and choose a location for your initial workbench.
### Segger Jlink Tools
@@ -37,15 +37,15 @@ For more information, see: [https://gnu-mcu-eclipse.github.io/debug/jlink/instal
## First Use
1. Connect the _Segger JLink_ to the host computer and the [flight controller debug port](../debug/swd_debug.md) (via an adapter).
1. Power the flight controller.
1. Run _Eclipse_.
1. Add a source by choosing **File > Import > C/C++ > Existing Code as Makefile Project** and click **Next**.
1. Point it to the **PX4-Autopilot** folder and give it a name, then select _ARM Cross GCC_ in the _Toolchain for Indexer Settings_ and click **Finish**.
2. Power the flight controller.
3. Run _Eclipse_.
4. Add a source by choosing **File > Import > C/C++ > Existing Code as Makefile Project** and click **Next**.
5. Point it to the **PX4-Autopilot** folder and give it a name, then select _ARM Cross GCC_ in the _Toolchain for Indexer Settings_ and click **Finish**.
Import takes a while, wait for it to complete.
1. Set the MCU settings: right-click on the top-level project in the Project Explorer, select _Properties_ then under MCU choose _SEGGER J-Link Path_.
6. Set the MCU settings: right-click on the top-level project in the Project Explorer, select _Properties_ then under MCU choose _SEGGER J-Link Path_.
Set it as shown in the screenshot below.
![Eclipse: Segger J-Link Path](../../assets/debug/eclipse_segger_jlink_path.png)
1. Update packs:
7. Update packs:
- Click the small icon on the top right called _Open Perspective_ and open the _Packs_ perspective.
![Eclipse: Workspace](../../assets/debug/eclipse_workspace_perspective.png)
- Click the **update all** button.
@@ -59,31 +59,31 @@ For more information, see: [https://gnu-mcu-eclipse.github.io/debug/jlink/instal
- The STM32Fxx devices are found in the Keil folder, install by right-clicking and then selecting **install** on the according device for F4 and F7.
1. Setup debug configuration for target:
8. Setup debug configuration for target:
- Right click project and open the _Settings_ (menu: **C/C++ Build > Settings**)
- Choose the _Devices_ Tab, _Devices_ section (Not _Boards_).
- Find the FMU chip you wish to debug.
![Eclipse: Select FMU in settings](../../assets/debug/eclipse_settings_devices_fmu.png)
1. Select debug configurations with the small drop-down next to the bug symbol:
9. Select debug configurations with the small drop-down next to the bug symbol:
![Eclipse: Debug config](../../assets/debug/eclipse_settings_debug_config.png)
1. Then select _GDB SEGGER J-Link Debugging_ and then the **New config** button on the top left.
![Eclipse: GDB Segger Debug config](../../assets/debug/eclipse_settings_debug_config_gdb_segger.png)
1. Setup build config:
- Give it a name and set the _C/C++ Application_ to the corresponding **.elf** file.
- Choose _Disable Auto build_
10. Then select _GDB SEGGER J-Link Debugging_ and then the **New config** button on the top left.
![Eclipse: GDB Segger Debug config](../../assets/debug/eclipse_settings_debug_config_gdb_segger.png)
11. Setup build config:
- Give it a name and set the _C/C++ Application_ to the corresponding **.elf** file.
- Choose _Disable Auto build_
::: info
Remember that you must build the target from the command line before starting a debug session.
:::
::: info
Remember that you must build the target from the command line before starting a debug session.
:::
![Eclipse: GDB Segger Debug config](../../assets/debug/eclipse_settings_debug_config_gdb_segger_build_config.png)
![Eclipse: GDB Segger Debug config](../../assets/debug/eclipse_settings_debug_config_gdb_segger_build_config.png)
1. The _Debugger_ and _Startup_ tabs shouldnt need any modifications (just verify your settings with the screenshots below)
12. The _Debugger_ and _Startup_ tabs shouldnt need any modifications (just verify your settings with the screenshots below)
![Eclipse: GDB Segger Debug config: debugger tab](../../assets/debug/eclipse_settings_debug_config_gdb_segger_build_config_debugger_tab.png)
![Eclipse: GDB Segger Debug config: startup tab](../../assets/debug/eclipse_settings_debug_config_gdb_segger_build_config_startup_tab.png)
![Eclipse: GDB Segger Debug config: debugger tab](../../assets/debug/eclipse_settings_debug_config_gdb_segger_build_config_debugger_tab.png)
![Eclipse: GDB Segger Debug config: startup tab](../../assets/debug/eclipse_settings_debug_config_gdb_segger_build_config_startup_tab.png)
## SEGGER Task-aware debugging
@@ -101,18 +101,18 @@ To enable this feature for use in Eclipse:
make px4_fmu-v5_default boardguiconfig
```
(See [PX4 Menuconfig Setup](../hardware/porting_guide_config.md#px4-menuconfig-setup) for more information) on using the config tools).
(See [PX4 Menuconfig Setup](../hardware/porting_guide_config.md#px4-menuconfig-setup) for more information on using the config tools).
- Ensure that the _Enable TCBinfo struct for debug_ is selected as shown:
![NuttX: Menuconfig: CONFIG_DEBUG_TCBINFO](../../assets/debug/nuttx_tcb_task_aware.png)
1. Compile the **jlink-nuttx.so** library in the terminal by running the following command in the terminal: `make jlink-nuttx`
1. Modify Eclipse to use this library.
2. Compile the **jlink-nuttx.so** library in the terminal by running the following command in the terminal: `make jlink-nuttx`
3. Modify Eclipse to use this library.
In the _J-Link GDB Server Setup_ configuration, update **Other options** to include `-rtos /home/<PX4 path>/Tools/jlink-nuttx.so`, as shown in the image below.
![Eclipse: GDB Segger Debug config RTOS aware: debugger tab](../../assets/debug/eclipse_settings_debug_config_gdb_segger_task_aware.png)
1. When running the debugger you should see now multiple threads instead of just one:
4. When running the debugger you should see now multiple threads instead of just one:
![Eclipse: GDB Segger Debug config RTOS aware: debug session](../../assets/debug/eclipse_settings_debug_config_gdb_segger_task_aware_tasks.png)
@@ -32,7 +32,7 @@ Omissions:
You can also install the environment using shell scripts in the Github project.
1. Make sure you have [Git for Windows](https://git-scm.com/download/win) installed.
1. Clone the repository https://github.com/PX4/windows-toolchain to the location you want to install the toolchain. Default location and naming is achieved by opening the `Git Bash` and executing:
1. Clone the repository <https://github.com/PX4/windows-toolchain> to the location you want to install the toolchain. Default location and naming is achieved by opening the `Git Bash` and executing:
```sh
cd /c/
@@ -51,11 +51,11 @@ The result should be the same as using the scripts or MSI installer.
The toolchain gets maintained and hence these instructions might not cover every detail of all the future changes.
:::
1. Create the _folders_: **C:\PX4\*\*, **C:\PX4\toolchain\*\* and \*\*C:\PX4\home\*\*
1. Download the _Cygwin installer_ file [setup-x86_64.exe](https://cygwin.com/setup-x86_64.exe) from the [official Cygwin website](https://cygwin.com/install.html)
1. Run the downloaded setup file
1. In the wizard choose to install into the folder: \*\*C:\PX4\toolchain\cygwin64\*\*
1. Select to install the default Cygwin base and the newest available version of the following additional packages:
1. Create the _folders_: **C:\PX4**, **C:\PX4\toolchain** and **C:\PX4\home**
2. Download the _Cygwin installer_ file [setup-x86_64.exe](https://cygwin.com/setup-x86_64.exe) from the [official Cygwin website](https://cygwin.com/install.html)
3. Run the downloaded setup file
4. In the wizard choose to install into the folder: **C:\PX4\toolchain\cygwin64**
5. Select to install the default Cygwin base and the newest available version of the following additional packages:
- **Category:Packagename**
- Devel:cmake (3.3.2 gives no deprecated warnings, 3.6.2 works but has the warnings)
- Devel:gcc-g++
@@ -85,14 +85,14 @@ The toolchain gets maintained and hence these instructions might not cover every
That's what [cygwin64/install-cygwin-px4.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/cygwin64/install-cygwin-px4.bat) does.
:::
1. Write up or copy the **batch scripts** [`run-console.bat`](https://github.com/PX4/PX4-windows-toolchain/blob/master/run-console.bat) and [`setup-environment.bat`](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/scripts/setup-environment.bat).
6. Write up or copy the **batch scripts** [`run-console.bat`](https://github.com/PX4/PX4-windows-toolchain/blob/master/run-console.bat) and [`setup-environment.bat`](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/scripts/setup-environment.bat).
The reason to start all the development tools through the prepared batch script is they preconfigure the starting program to use the local, portable Cygwin environment inside the toolchain's folder.
This is done by always first calling the script [**setup-environment.bat**](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/scripts/setup-environment.bat) and the desired application like the console after that.
The script [setup-environment.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/scripts/setup-environment.bat) locally sets environmental variables for the workspace root directory `PX4_DIR`, all binary locations `PATH`, and the home directory of the unix environment `HOME`.
1. Add necessary **python packages** to your setup by opening the Cygwin toolchain console (double clicking **run-console.bat**) and executing
7. Add necessary **python packages** to your setup by opening the Cygwin toolchain console (double clicking **run-console.bat**) and executing
```sh
pip2 install toml
@@ -104,13 +104,13 @@ The toolchain gets maintained and hence these instructions might not cover every
That's what [cygwin64/install-cygwin-python-packages.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/cygwin64/install-cygwin-python-packages.bat) does.
:::
1. Download the [**ARM GCC compiler**](https://developer.arm.com/Tools%20and%20Software/GNU%20Toolchain) as zip archive of the binaries for Windows and unpack the content to the folder `C:\PX4\toolchain\gcc-arm`.
8. Download the [**ARM GCC compiler**](https://developer.arm.com/Tools%20and%20Software/GNU%20Toolchain) as zip archive of the binaries for Windows and unpack the content to the folder `C:\PX4\toolchain\gcc-arm`.
::: info
This is what the toolchain does in: [gcc-arm/install-gcc-arm.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/gcc-arm/install-gcc-arm.bat).
:::
1. Install the JDK:
9. Install the JDK:
- Download Java 14 from [Oracle](https://www.oracle.com/java/technologies/downloads/)
- Because sadly there is no portable archive containing the binaries directly you have to install it.
- Find the binaries and move/copy them to **C:\PX4\toolchain\jdk**.
@@ -120,31 +120,31 @@ The toolchain gets maintained and hence these instructions might not cover every
This is what the toolchain does in: [jdk/install-jdk.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/jdk/install-jdk.bat).
:::
1. Download [**Apache Ant**](https://ant.apache.org/bindownload.cgi) as zip archive of the binaries for Windows and unpack the content to the folder `C:\PX4\toolchain\apache-ant`.
10. Download [**Apache Ant**](https://ant.apache.org/bindownload.cgi) as zip archive of the binaries for Windows and unpack the content to the folder `C:\PX4\toolchain\apache-ant`.
:::tip
Make sure you don't have an additional folder layer from the folder which is inside the downloaded archive.
:::
:::tip
Make sure you don't have an additional folder layer from the folder which is inside the downloaded archive.
:::
::: info
This is what the toolchain does in: [apache-ant/install-apache-ant.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/apache-ant/install-apache-ant.bat).
:::
::: info
This is what the toolchain does in: [apache-ant/install-apache-ant.bat](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/apache-ant/install-apache-ant.bat).
:::
1. Download, build and add _genromfs_ to the path:
- Clone the source code to the folder **C:\PX4\toolchain\genromfs\genromfs-src** with
11. Download, build and add _genromfs_ to the path:
- Clone the source code to the folder **C:\PX4\toolchain\genromfs\genromfs-src** with
```sh
cd /c/toolchain/genromfs
git clone https://github.com/chexum/genromfs.git genromfs-src
```
```sh
cd /c/toolchain/genromfs
git clone https://github.com/chexum/genromfs.git genromfs-src
```
- Compile it with:
- Compile it with:
```sh
cd genromfs-src
make all
```
```sh
cd genromfs-src
make all
```
- Copy the resulting binary **genromfs.exe** one folder level out to: **C:\PX4\toolchain\genromfs**
- Copy the resulting binary **genromfs.exe** one folder level out to: **C:\PX4\toolchain\genromfs**
1. Make sure all the binary folders of all the installed components are correctly listed in the `PATH` variable configured by [**setup-environment.bat**](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/scripts/setup-environment.bat).
12. Make sure all the binary folders of all the installed components are correctly listed in the `PATH` variable configured by [**setup-environment.bat**](https://github.com/PX4/PX4-windows-toolchain/blob/master/toolchain/scripts/setup-environment.bat).
+23 -22
View File
@@ -13,9 +13,9 @@ After setting up the virtual machine, the installation and setup of PX4 within t
While using a VM is a very easy way to set up and test an environment for building firmware, users should be aware:
1. Firmware building will be slower than native building on Linux.
1. The JMAVSim simulation, frame rate be much slower than on native Linux.
2. The JMAVSim simulation, frame rate be much slower than on native Linux.
In some cases the vehicle may crash due to issues related to insufficient VM resources.
1. Gazebo and ROS can be installed, but are unusably slow.
3. Gazebo and ROS can be installed, but are unusably slow.
:::tip
Allocate as many CPU cores and memory resources to the VM as possible.
@@ -30,32 +30,33 @@ There is also an incomplete section for VirtualBox at the end (we'd welcome expa
VMWare performance is acceptable for basic usage (building Firmware) but not for running ROS or Gazebo Classic.
1. Download [VMWare Workstation Pro](https://www.vmware.com/products/desktop-hypervisor/workstation-and-fusion) (the free player has been discontinued)
1. Install it on your Windows system
1. Download the desired version of [Ubuntu Desktop ISO Image](https://ubuntu.com/download/desktop).
2. Install it on your Windows system
3. Download the desired version of [Ubuntu Desktop ISO Image](https://ubuntu.com/download/desktop).
(see [Linux Instructions Page](../dev_setup/dev_env_linux.md) for recommended Ubuntu version).
1. Open _Workstation Pro_.
1. Enable 3D acceleration in the VM's settings: **VM > Settings > Hardware > Display > Accelerate 3D graphics**
4. Open _Workstation Pro_.
5. Enable 3D acceleration in the VM's settings: **VM > Settings > Hardware > Display > Accelerate 3D graphics**
::: info
This option is required to properly run 3D simulation environments like jMAVSim and Gazebo Classic.
We recommend this is done before installing Linux in the virtual environment.
:::
1. Select the option to create a new virtual machine.
1. In the VM creation wizard choose the downloaded Ubuntu ISO image as your installation medium and will automatically detect the operating system you want to use.
1. Also in the wizard, select the resources you want to allocate to your virtual machine while it is running.
6. Select the option to create a new virtual machine.
7. In the VM creation wizard choose the downloaded Ubuntu ISO image as your installation medium and will automatically detect the operating system you want to use.
8. Also in the wizard, select the resources you want to allocate to your virtual machine while it is running.
Allocate as much memory and as many CPU cores as you can without rendering your host Windows system unusable.
1. Run your new VM at the end of the wizard and let it install Ubuntu following the setup instructions.
9. Run your new VM at the end of the wizard and let it install Ubuntu following the setup instructions.
Remember all settings are only for within your host operating system usage and hence you can disable any screen saver and local workstation security features which do not increase risk of a network attack.
1. Once the new VM is booted up make sure you install _VMWare tools drivers and tools extension_ inside your guest system.
This will enhance performance and usability of your VM usage:
- Significantly enhanced graphics performance
- Proper support for hardware device usage like USB port allocation (important for target upload), proper mouse wheel scrolling, sound support
- Guest display resolution adaption to the window size
- Clipboard sharing to host system
- File sharing to host system
10. Once the new VM is booted up make sure you install _VMWare tools drivers and tools extension_ inside your guest system.
1. Continue with [PX4 environment setup for Linux](../dev_setup/dev_env_linux.md)
This will enhance performance and usability of your VM usage:
- Significantly enhanced graphics performance
- Proper support for hardware device usage like USB port allocation (important for target upload), proper mouse wheel scrolling, sound support
- Guest display resolution adaption to the window size
- Clipboard sharing to host system
- File sharing to host system
11. Continue with [PX4 environment setup for Linux](../dev_setup/dev_env_linux.md)
## VirtualBox 7 Setup
@@ -81,9 +82,9 @@ To allow this, you need to configure USB passthrough settings:
Then restart Ubuntu in the virtual machine.
1. Enable serial port(s) in VM: **VirtualBox > Settings > Serial Ports 1/2/3/etc...**
1. Enable USB controller in VM: **VirtualBox > Settings > USB**
1. Add USB filters for the bootloader in VM: **VirtualBox > Settings > USB > Add new USB filter**.
2. Enable serial port(s) in VM: **VirtualBox > Settings > Serial Ports 1/2/3/etc...**
3. Enable USB controller in VM: **VirtualBox > Settings > USB**
4. Add USB filters for the bootloader in VM: **VirtualBox > Settings > USB > Add new USB filter**.
- Open the menu and plug in the USB cable connected to your autopilot.
Select the `...Bootloader` device when it appears in the UI.
@@ -94,7 +95,7 @@ To allow this, you need to configure USB passthrough settings:
- Select the `...Autopilot` device when it appears (this happens after the bootloader completes).
1. Select the device in the VM instance's dropdown menu **VirtualBox > Devices > your_device**
5. Select the device in the VM instance's dropdown menu **VirtualBox > Devices > your_device**
If successful, your device will show up with `lsusb` and QGroundControl will connect to the device automatically.
You should also be able to build and upload firmware using a command like:
+1 -1
View File
@@ -358,7 +358,7 @@ _Offboard mode_ is affected by the following parameters:
| Parameter | Description |
| -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| <a id="COM_OF_LOSS_T"></a>[COM_OF_LOSS_T](../advanced_config/parameter_reference.md#COM_OF_LOSS_T) | Time-out (in seconds) to wait when offboard connection is lost before triggering offboard lost failsafe (`COM_OBL_RC_ACT`) |
| <a id="COM_OBL_RC_ACT"></a>[COM_OBL_RC_ACT](../advanced_config/parameter_reference.md#COM_OBL_RC_ACT) | Flight mode to switch to if offboard control is lost (Values are - `0`: _Position_, `1`: _Altitude_, `2`: _Manual_, `3`: *Return, `4`: *Land\*). |
| <a id="COM_OBL_RC_ACT"></a>[COM_OBL_RC_ACT](../advanced_config/parameter_reference.md#COM_OBL_RC_ACT) | Flight mode to switch to if offboard control is lost (Values are - `0`: _Position_, `1`: _Altitude_, `2`: _Manual_, `3`: _Return_, `4`: _Land_). |
| <a id="COM_RC_OVERRIDE"></a>[COM_RC_OVERRIDE](../advanced_config/parameter_reference.md#COM_RC_OVERRIDE) | Controls whether stick movement on a multicopter (or VTOL in MC mode) causes a mode change to [Position mode](../flight_modes_mc/position.md). This is not enabled for offboard mode by default. |
| <a id="COM_RC_STICK_OV"></a>[COM_RC_STICK_OV](../advanced_config/parameter_reference.md#COM_RC_STICK_OV) | The amount of stick movement that causes a transition to [Position mode](../flight_modes_mc/position.md) (if [COM_RC_OVERRIDE](#COM_RC_OVERRIDE) is enabled). |
| <a id="COM_RCL_EXCEPT"></a>[COM_RCL_EXCEPT](../advanced_config/parameter_reference.md#COM_RCL_EXCEPT) | Specify modes in which RC loss is ignored and the failsafe action not triggered. Set bit `2` to ignore RC loss in Offboard mode. |
@@ -105,66 +105,66 @@ The following tools are used in this assembly:
![QAV250 Add arms to button plate](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/1_button_plate_add_arms.jpg)
1. Put the short plate over the arms
2. Put the short plate over the arms
![QAV250 Add short plate over arms](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/2_short_plate_over_arms.jpg)
1. Put the nuts on the 15mm screws (shown next step)
1. Insert the plastic screws into the indicated holes (note that this part of the frame faces down when the vehicle is complete).
3. Put the nuts on the 15mm screws (shown next step)
4. Insert the plastic screws into the indicated holes (note that this part of the frame faces down when the vehicle is complete).
![QAV250 Add nuts to 15mm screws and put plastic nuts in holes](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/3_nuts_screws_holes.jpg)
1. Add the plastic nuts to the screws (turn over, as shown)
5. Add the plastic nuts to the screws (turn over, as shown)
![QAV250 Plastic nuts onto screws](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/4_plastic_nuts_on_screws.jpg)
1. Lower the power module over the plastic screws and then add the plastics standoffs
6. Lower the power module over the plastic screws and then add the plastics standoffs
![QAV250 Add power module and standoffs](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/5_power_module_on_screws.jpg)
1. Put the flight controller plate on the standoffs (over the power module)
7. Put the flight controller plate on the standoffs (over the power module)
![QAV250 Add flight controller plate](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/6_flight_controller_plate.jpg)
1. Attach the motors. The motors have an arrow indicating the direction of rotation.
8. Attach the motors. The motors have an arrow indicating the direction of rotation.
![QAV250 Add motors](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/7_motors.jpg)
1. Use double sided tape from kit to attach the _Pixhawk 4 Mini_ to the flight controller plate.
9. Use double sided tape from kit to attach the _Pixhawk 4 Mini_ to the flight controller plate.
![QAV250 Add doublesided tape](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/8_double_sided_tape_controller.jpg)
1. Connect the power module's "power" cable to _Pixhawk 4 mini_.
![QAV250 Power Pixhawk](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/9_power_module_power_pixhawk.jpg)
1. Attach the aluminium standoffs to the button plate
![QAV250 Aluminium standoffs](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/10_aluminium_standoffs.jpg)
1. Connect the Escs with the motors and hold. In this image shown the order of the motors and direction of the rotation.
![QAV250 Connect ESCs](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/11_escs.jpg)
10. Connect the power module's "power" cable to _Pixhawk 4 mini_.
![QAV250 Power Pixhawk](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/9_power_module_power_pixhawk.jpg)
11. Attach the aluminium standoffs to the button plate
![QAV250 Aluminium standoffs](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/10_aluminium_standoffs.jpg)
12. Connect the Escs with the motors and hold. In this image shown the order of the motors and direction of the rotation.
![QAV250 Connect ESCs](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/11_escs.jpg)
Connect the motors on the ESCs, make sure the motors turns to the correct side, if the motor turns of the opposite side change the cable A to the pad C and C to the pad A of the ESC.
Connect the motors on the ESCs, make sure the motors turns to the correct side, if the motor turns of the opposite side change the cable A to the pad C and C to the pad A of the ESC.
:::warning
Test motor directions with propellers removed.
:::
:::warning
Test motor directions with propellers removed.
:::
![QAV250 Connect ESCs to Power](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/11b_escs.jpg)
![QAV250 Connect ESCs to Power](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/11b_escs.jpg)
1. Connect the signal ESC cables to the PWM outputs of the Pixhawk in the correct order (see previous image)
13. Connect the signal ESC cables to the PWM outputs of the Pixhawk in the correct order (see previous image)
![QAV250 Connect ESCs to Pixhawk PWM](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/12_escs_pixhawk.jpg)
![QAV250 Connect ESCs to Pixhawk PWM](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/12_escs_pixhawk.jpg)
1. Connect the receiver.
- If using a PPM receiver connect to the PPM port.
14. Connect the receiver.
- If using a PPM receiver connect to the PPM port.
![QAV250 Connect Receiver PPM](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/13_rc_receiver_ppm.jpg)
![QAV250 Connect Receiver PPM](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/13_rc_receiver_ppm.jpg)
- If using the SBUS receiver connect to the RC IN port
- If using the SBUS receiver connect to the RC IN port
![QAV250 Connect Receiver SBUS](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/13_rc_receiver_sbus.jpg)
![QAV250 Connect Receiver SBUS](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/13_rc_receiver_sbus.jpg)
1. Connect the telemetry module. Paste the module with double tape and connect on the port of the telemetry.
15. Connect the telemetry module. Paste the module with double tape and connect on the port of the telemetry.
![QAV250 Telemetry module](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/14_telemetry.jpg)
![QAV250 Telemetry module](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/14_telemetry.jpg)
1. Connect the GPS module
16. Connect the GPS module
![QAV250 Connect GPS](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/15a_connect_gps.jpg)
![QAV250 Connect GPS](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/15a_connect_gps.jpg)
Attach the module on the top plate (using provided 3M tape, or paste). Then put the top plate on the standoffs as shown
Attach the module on the top plate (using provided 3M tape, or paste). Then put the top plate on the standoffs as shown
![QAV250 Connect GPS](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/15b_attach_gps.jpg)
![QAV250 Connect GPS](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/15b_attach_gps.jpg)
1. The last "mandatory" assembly step is to add the velcro to hold the battery
17. The last "mandatory" assembly step is to add the velcro to hold the battery
![QAV250 Velcro battery strap](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/16_velcro_strap.jpg)
![QAV250 Velcro battery strap](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/16_velcro_strap.jpg)
The "basic" frame build is now complete (though if you need them, you can find more information about connecting components in the [Pixhawk 4 Wiring Quickstart](../assembly/quick_start_pixhawk4.md)).
@@ -180,9 +180,9 @@ The steps to install the kit are:
1. Install the camera bracket on the frame
![Camera Connection](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/fpv_camera_bracket.jpg)
1. Install the camera on the bracket
2. Install the camera on the bracket
![Camera on Bracket](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/fpv_camera_on_bracket.jpg)
1. The power module on the complete kit comes with wiring ready to connect the Video Transmitter and Camera:
3. The power module on the complete kit comes with wiring ready to connect the Video Transmitter and Camera:
![Connecting FPV](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/fpv_connection_board.jpg)
- Attach the camera connector
![Camera Connection](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/fpv_camera_connection.jpg)
@@ -190,7 +190,7 @@ The steps to install the kit are:
- Connect the Video Transmitter (VTX) connector
![Video Transmitter Connection](../../assets/airframes/multicopter/qav250_holybro_pixhawk4_mini/fpv_video_transmitter_connection.jpg)
The wires are: yellow=video out, black=ground, red=+voltage.
1. Secure the Video Transmitter and OSD board to the frame using tape.
4. Secure the Video Transmitter and OSD board to the frame using tape.
::: info
If you have to wire the system yourself, the diagram below shows all the connections between camera, VTX and power module:
+7 -11
View File
@@ -19,25 +19,21 @@ If so, proceed as follows:
Go to your catkin workspace (e.g. ~/ros_catkin_ws) and change the name of the packages.
```sh
$ cd ~/ros_catkin_ws
$ rosinstall_generator ros_tutorials --rosdistro indigo --deps --wet-only --exclude roslisp --tar > indigo-custom_ros.rosinstall
cd ~/ros_catkin_ws
rosinstall_generator ros_tutorials --rosdistro indigo --deps --wet-only --exclude roslisp --tar > indigo-custom_ros.rosinstall
```
Next, update your workspace with wstool.
```sh
$ wstool merge -t src indigo-custom_ros.rosinstall
$ wstool update -t src
wstool merge -t src indigo-custom_ros.rosinstall
wstool update -t src
```
Next (still in your workspace folder), source and make your files.
```sh
$ source /opt/ros/indigo/setup.bash
$ source devel/setup.bash
$ catkin_make
source /opt/ros/indigo/setup.bash
source devel/setup.bash
catkin_make
```