mirror of
https://github.com/CopterExpress/clover.git
synced 2026-05-26 21:19:35 +00:00
* docs: minor fix * docs: update PX4 docs links * docs: info on no mags found error * docs: some updates in setup section * docs: use enumerated list for consistency * docs: update firmware flashing section * docs: update * selfcheck.py: remove timestamps from selfcheck reports * selfcheck.py: add gzclient and gzserver to cpu eaters whitelist * selfcheck.py: make not finding vcgencmd not a failure * selfcheck.py: fix and simplify firmware version parsing, remove Clover firmware warning * docs: some updates to optical flow article * ci: cancel previous docs builds to avoid publishing old site * vpe_publisher: rename parameter publish_zero to force_init * genmap.py: use -p flag in example * selfcheck.py: add checking map=>body transform * selfcheck.py: bring back info about non-Clover firmware * docs: reduce qgc-params.png file size * docs: reduce size of some images * docs: rephrase firmware flashing section to continue recommending COEX firmware * docs: update PX4 docs links * docs: rename px4_parameters.md article to parameters.md * docs: add note about possible unintended switching out of LAND mode * docs: remove obsolete notes and simplify titles in autonomous flight article * clover.launch: add force_init argument PX4 1.12.3 doesn’t init by flow without mag force_init runs vpe_publisher to force init using vpe * docs: rework parameters article, make summary parameters table * docs: remove unused asset
129 lines
5.2 KiB
Markdown
129 lines
5.2 KiB
Markdown
# Initial setup
|
|
|
|
## Installing QGroundControl
|
|
|
|
**QGroundControl** is a software package that can be used to flash, configure and calibrate the flight controller.
|
|
|
|
<img src="../assets/qgc.png" alt="QGroundControl" class="zoom">
|
|
|
|
Download and install the version for your operating system [from the official QGroundControl website](https://docs.qgroundcontrol.com/en/getting_started/download_and_install.html). When asked, agree to install additional drivers.
|
|
|
|
Consult the [official QGroundControl user guide](https://docs.qgroundcontrol.com/en/) if anything goes wrong.
|
|
|
|
## Preparing the MicroSD card
|
|
|
|
Prepare the MicroSD card for your flight controller.
|
|
|
|
<img src="../assets/pix-sd.png" alt="Pixracer and MicroSD-card" class="zoom center" width=400>
|
|
|
|
* Put the card into your computer (use an adapter if necessary).
|
|
* Format the card to FAT32 filesystem. Right click on the SD card icon in Windows Explorer and select "Format". Use the Disk Utility in macOS.
|
|
* Use "Safely Remove Hardware" and unplug the card.
|
|
* Put the card into your flight controller.
|
|
|
|
## Flashing the flight controller
|
|
|
|
Main article: https://docs.qgroundcontrol.com/en/SetupView/Firmware.html
|
|
|
|
> **Note** Do not connect your flight controller prior to flashing.
|
|
|
|
We recommend using the modified version of [PX4 with COEX patches](firmware.md) for the Clover drone, especially for autonomous flights. Download the latest stable version **<a class="latest-firmware v4" href="https://github.com/CopterExpress/Firmware/releases">from our GitHub</a>**.
|
|
|
|
To use all the most recent PX4 functions you also can use the latest official firmware version (experimentally).
|
|
|
|
Flash the flight controller with this firmware:
|
|
|
|
<img src="../assets/qgc-firmware.png" alt="QGroundControl firmware upload" class="zoom">
|
|
|
|
1. Disconnect the flight controller from computer (if connected).
|
|
2. Launch QGroundControl software.
|
|
3. Go to *Vehicle Setup* panel (click on the QGroundControl logo in the top-left corner) and select *Firmware* menu.
|
|
4. Connect your flight controller to your PC over USB.
|
|
5. Select *PX4 Flight Stack* in the right bar appeared.
|
|
|
|
<img src="../assets/qgc-firmware.png" alt="QGroundControl firmware upload" class="zoom">
|
|
|
|
6. To use **COEX patched firmware**:
|
|
|
|
* Check *Advanced Settings* checkbox.
|
|
* Select *Custom firmware file...* from the dropdown list.
|
|
* Press *OK* and select the file that you've downloaded.
|
|
|
|
To use the latest **official stable firmware** just press *OK*.
|
|
|
|
Wait for QGroundControl to finish flashing the flight controller.
|
|
|
|
> **Warning** Do not unplug the flight controller during the flashing process.
|
|
|
|
Read more about the firmware in the "[Pixhawk Firmware](firmware.md)" article.
|
|
|
|
## Configuring the flight controller
|
|
|
|
> **Hint** You can use the [Raspberry Pi to access the flight controller over Wi-Fi](gcs_bridge.md) for the rest of the setup process.
|
|
|
|
This is how the main QGroundControl settings window will look like:
|
|
|
|
<img src="../assets/qgc-requires-setup.png" alt="QGroundControl overview" class="zoom">
|
|
|
|
1. Parameters that require setup: *Airframe*, *Radio*, *Sensors*, *Flight Modes*.
|
|
2. Current firmware version.
|
|
3. Current flight mode.
|
|
4. Error messages.
|
|
|
|
### Selecting the airframe
|
|
|
|
<img src="../assets/qgc-frame-apply-clover4.png" alt="QGroundControl frame selection" class="zoom">
|
|
|
|
1. Open the *Vehicle Setup* tab.
|
|
2. Select the *Airframe* menu.
|
|
3. Select the *Quadrotor X* airframe type.
|
|
4. For Clover 4 select *COEX Clover 4* from the dropdown menu. Otherwise select *Generic Quadrotor X*.
|
|
5. Return to the top of the list and press *Apply and Restart* button, confirm by pressing *Apply*.
|
|
6. Wait for the settings to be applied and for the flight controller to restart.
|
|
|
|
### Setting parameters
|
|
|
|
Open the *Vehicle Setup* tab and select the *Parameters* menu. You can use the *Search* field to find parameters by name. Recommended parameters values are given in the further documentation and also in the [parameters summary article](parameters.md).
|
|
|
|
<img src="../assets/qgc-parameters.png" alt="QGroundControl parameters" class="zoom">
|
|
|
|
Press the *Save* button to save the changed value to the flight controller. Changing some parameters require rebooting the flight controller. You can do that by pressing the *Tools* button and selecting the *Reboot vehicle* option.
|
|
|
|
#### Configuring PID regulators
|
|
|
|
> **Info** Selecting *COEX Clover 4* frame subtype doesn't require setting PID coefficients.
|
|
|
|
##### Averaged PID coefficients for the Clover 4 drone
|
|
|
|
* `MC_PITCHRATE_P` = 0.087
|
|
* `MC_PITCHRATE_I` = 0.037
|
|
* `MC_PITCHRATE_D` = 0.0044
|
|
* `MC_PITCH_P` = 8.5
|
|
* `MC_ROLLRATE_P` = 0.087
|
|
* `MC_ROLLRATE_I` = 0.037
|
|
* `MC_ROLLRATE_D` = 0.0044
|
|
* `MC_ROLL_P` = 8.5
|
|
* `MPC_XY_VEL_P` = 0.11
|
|
* `MPC_XY_VEL_D` = 0.013
|
|
* `MPC_XY_P` = 1.1
|
|
* `MPC_Z_VEL_P` = 0.24
|
|
* `MPC_Z_P` = 1.2
|
|
|
|
##### Averaged PID coefficients for the Clover 3 drone
|
|
|
|
* `MC_PITCHRATE_P` = 0.145
|
|
* `MC_PITCHRATE_I` = 0.050
|
|
* `MC_PITCHRATE_D` = 0.0025
|
|
* `MC_ROLLRATE_P` = 0.145
|
|
* `MC_ROLLRATE_I` = 0.050
|
|
* `MC_ROLLRATE_D` = 0.0025
|
|
|
|
> **Hint** Note that you should fine-tune the PID parameters for each drone individually. <!-- TODO: add PID article link -->
|
|
|
|
#### Circuit breaker parameters
|
|
|
|
1. Set `CBRK_USB_CHK` to 197848 to allow flights with the USB cable connected.
|
|
2. Disable safety switch check: `CBRK_IO_SAFETY` = 22027.
|
|
|
|
**Next**: [Sensor calibration](calibration.md).
|