diff --git a/README.md b/README.md index 43bac6c..787a88b 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ Create animation in [Blender](https://www.blender.org/), convert it to drone pat * [Server side](server/) for making the drone show with ability of tuning drones, animation and music * [Blender 2.8 addon](blender-addon/) for exporting animation to drone paths * [Raspberry Pi image](https://github.com/CopterExpress/clever-show/releases/latest) for quick launch software on the drones -* [Documentation](docs/ru/SUMMARY.md) (only in Russian for now) +* [Documentation](docs/en/SUMMARY.md) ## Positioning systems supported diff --git a/docs/en/SUMMARY.md b/docs/en/SUMMARY.md index 568f828..9c1cc77 100644 --- a/docs/en/SUMMARY.md +++ b/docs/en/SUMMARY.md @@ -1,9 +1,9 @@ # Clever-show documentation -* [Quick start](start-tutorial.md) - translation in progress -* [Клиент clever-show](client.md) -* [Сервер clever-show](server.md) -* [Настройка систем позиционирования](positioning.md) -* [Модуль анимации](animation.md) -* [Экспорт анимации из Blender](blender-addon.md) -* [Сборка модифицированного образа](image-building.md) +* [Quick start](start-tutorial.md) +* [clever-show client](client.md) +* [clever-show server](server.md) +* [Show positioning setup](positioning.md) +* [Animation module](animation.md) +* [Exporting animations from Blender](blender-addon.md) +* [Building modified image](image-building.md) diff --git a/docs/en/animation.md b/docs/en/animation.md new file mode 100644 index 0000000..d5fa0f6 --- /dev/null +++ b/docs/en/animation.md @@ -0,0 +1,73 @@ +# Animation module + +A separate module [animation](../../drone/modules/animation.py) is responsible for animation processing. When animation is loaded on the copter, the module divides the sequence of animation frames into 5 key stages: + +1. The copter is stationary at the beginning of the animation - `static_begin`. +2. Copter takes off - `takeoff'. +3. The copter follows the route of animation - `route`. +4. Copter performs landing - `land`. +5. The copter is stationary until the animation file - `static_end` is finished. + +An animation frame is a set of data needed to position the copter and determine its LED strip color. In the current version of the software the animation frame is represented by a sequence of numbers `x y zaw r g b` in the lines of the `.csv` animation file where: + +* `x`, `y`, `z` - copter coordinates in the current frame, in meters +* `yaw` - copter yaw, in radians +* `r`, `g`, `b` - сopter LED strip color components, integers from 0 to 255 + +After splitting the animation into key stages, the module generates an output sequence of frames defining the position of the copter and its lED strip color as well as the sequence of actions during the flight to the first point of the animation. + +You can configure the module in the [ANIMATION](client.md#раздел-animation) section. + +Preliminary selection of frames is carried out using a set of [[OUTPUT]] flags, which set which frame sequences out of 5 key stages will be used in flight and which will not. + +The key parameter that defines the logic of animation playback is the `start_action` parameter that defines the first action when the animation playback starts. Available options of its values: + +* `auto` - automatic choice of action between `takeoff` (take-off) or `fly` (instantaneous flight along points) based on the current level of altitude of the copter. If (`z` at the initial point of animation) > (take-off_level), the value is set to `takeoff`, otherwise the value is set to `fly`. +* `fly` - executing *the logic of immediate flight* +* `takeoff` - execution of *the logic of flight to the first point* + +f the copter takes off from the ground in the animation file, at the start of the animation, the instantaneous playback logic (fly)** will be applied: the copter with the motors turned off plays the color from the animation as long as it is stationary, turns the motors on before the moment of takeoff, then after `arming_time` starts to follow the points specified in the animation. + + If in the animation file the copter starts to fly in the air, at the start of the animation will be applied **flight logic to the first point (takeoff)**: The copter with the motors turned off plays the color from the animation as long as it is stationary, turns the motors on before takeoff, then takes off in `takeoff_height` time, then moves to the first point in `reach_first_point_time` and then starts to follow the points specified in the animation. + +If the `start_action` parameter is set to `takeoff` and the `takeoff` flag in the [[OUTPUT]] section is set to `True`, the sequence of frames with the copter taking off by points is replaced by 2 consecutive actions: + +* takeoff relative to the current position to the height of `takeoff_height` for `takeoff_time` +* flying in a straight line to the starting point of the copter route frame sequence (`route`) during `reach_first_point_time`. + +## Animation preparation and upload + +Create object animations in [Blender](https://www.blender.org) or use [examples](.../../examples/animations). + +The copter can be represented by any three-dimensional object (e.g., a cube or a ball), and the LED strip color will be extracted from the object color property. Consider the following facts and recommendations when creating an animation: + +* For easy conversion and uploading of animation to copters, objects corresponding to copters should have names corresponding to the names of these copters. +* Blender distance units are converted into meters +* The default delay between frames in [Copter settings](.../../drone/config/spec/configspec_client.ini) is 0.1 seconds (parameter `frame_delay` in ANIMATION section), pay attention when setting the frame rate in Blender animation. +* Make sure that the speed of the copters is not too high ( maximum of 3 m/s for the room, maximum of 5 m/s for the street): the addon will give a warning but will still convert the animation. + +Convert the animation with [Blender addon](blender-addon.md). + +If there are several objects in the animation and their names match the names of the copters, load the animation folder on the selected copters in the table using the [server](server.md#selected-drones section) command `Send -> Animations`. + +Also any animation file can be loaded separately on all selected copters in the table with the command `Send -> Animation`. + +## Animation analysis + +If you need information about which points the copter will fly to as a result of loading the animation on the current client parameters, use the [animation_info](../../tools/animation_info.py) utility . + +```cmd +usage: python animation_info.py [-h] [--config] [animation] + +Get animation info + +positional arguments: + animation Path to animation. Default is + ../examples/animations/basic/basic.csv. + +optional arguments: + -h, --help show this help message and exit + --config Set this option to print config info. +``` + +This utility displays full information about the client's animation and configuration settings (optional), as well as both possible playback options for the animation, which allows to analyze the actions of the copters before a real flight. \ No newline at end of file diff --git a/docs/en/blender-addon.md b/docs/en/blender-addon.md index b127e2c..b94f316 100644 --- a/docs/en/blender-addon.md +++ b/docs/en/blender-addon.md @@ -1,4 +1,4 @@ -# Addon to export animations from Blender +# Animation export Blender addon The Addon for Blender is designed to convert Blender's copters flight animations into flight paths for each copter of the animation, including the color of objects at any given time. diff --git a/docs/en/client.md b/docs/en/client.md index 3f39f14..30dcf0e 100644 --- a/docs/en/client.md +++ b/docs/en/client.md @@ -71,7 +71,7 @@ This section configures the telemetry stream to the server. This section contains settings affecting copter flight. -* `frame_id` - the name of the coordinate system, in relation to which the coordinates of the points for animation playback will be published. If value is `floor` - then the client publishes the static coordinate system with the name `floor` and the settings from [FLOOR_FRAME](#floor-frame-section). **Attention!** Make sure that the copter holds a position in this coordinate system. For this you can use the [Takeoff] (server.md# test commands) command from the server application. The copter will take off at an altitude of `takeoff_height` relative to the current one. +* `frame_id` - the name of the coordinate system, in relation to which the coordinates of the points for animation playback will be published. If value is `floor` - then the client publishes the static coordinate system with the name `floor` and the settings from [FLOOR_FRAME](#floor-frame-section). **Warning!** Make sure that the copter holds a position in this coordinate system. For this you can use the [Takeoff] (server.md# test commands) command from the server application. The copter will take off at an altitude of `takeoff_height` relative to the current one. * `takeoff_height` - take-off height of the copter, in meters. Used at the beginning of animation playback or when testing the copter from the server. * `takeoff_time` - maximum copter take-off time, in seconds. * `reach_first_point_time` - maximum flight time to reach the first point of the animation, in seconds. @@ -87,7 +87,7 @@ This section describes the offset of the coordinate system with the name `floor` * `translation` - offset of the `floor` coordinate system along the axes (x, y, z) from the `parent` coordinate system, in meters. * `rotation` - rotation of `floor` coordinate system by angles (roll, pitch, yaw) around axes (x, y, z) relative to `parent` coordinate system, in degrees. -**Attention!** Rotations `roll`, `pitch`, `yaw` are made sequentially in the stated order. +**Warning!** Rotations `roll`, `pitch`, `yaw` are made sequentially in the stated order. #### GPS FRAME section @@ -120,12 +120,12 @@ After splitting the animation into key stages, the module generates an output se * `auto` - automatic choice of action between `takeoff` (take-off) or `fly` (instantaneous flight along points) based on the current level of altitude of the copter. If (`z` at the initial point of animation) > (take-off_level), the value is set to `takeoff`, otherwise the value is set to `fly`. * `fly` - executing *the logic of immediate flight* -* `takeoff` - execution of *the logic of flight to the first point* - + * `takeoff` - execution of *the logic of flight to the first point* + If the copter takes off from the ground in the animation file, at the start of the animation, the instantaneous playback logic (fly)** will be applied: the copter with the motors turned off plays the color from the animation as long as it is stationary, turns the motors on before the moment of takeoff, then after `arming_time` starts to follow the points specified in the animation. - + If in the animation file the copter starts to fly in the air, at the start of the animation will be applied **flight logic to the first point (takeoff)**: The copter with the motors turned off plays the color from the animation as long as it is stationary, turns the motors on before takeoff, then takes off in `takeoff_height` time, then moves to the first point in `reach_first_point_time` and then starts to follow the points specified in the animation. - + * `takeoff_level` - takeoff level to automatically detect the first action of the copter when the animation starts * `ground_level` - ground level, used to check if the copter will try to fly underground when playing the animation. Available settings: @@ -171,7 +171,7 @@ This section configures the program of emergency protection of the copter from a Settings of emergency landing parameters in case of `emergency_land` emergency protection action or when calling the `/emergency_land` ROS service. -* `thrust` - the initial power supplied to the motors in the event of a `emergency_land` action when the emergency protection is triggered. Measurementless value, from 0 (no thrust) to 1 (full thrust). For a guaranteed fit it is recommended to set it to a value 5-10 percent lower than the hanging gas (parameter `MPC_THR_HOVER` in px4). **Attention!** Incorrect configuration of this option may cause the copter to rise up instead of landing! +* `thrust` - the initial power supplied to the motors in the event of a `emergency_land` action when the emergency protection is triggered. Measurementless value, from 0 (no thrust) to 1 (full thrust). For a guaranteed fit it is recommended to set it to a value 5-10 percent lower than the hanging gas (parameter `MPC_THR_HOVER` in px4). **Warning!** Incorrect configuration of this option may cause the copter to rise up instead of landing! * `decrease_thrust_after` - the time after which the power on the motors slowly begins to decrease (in seconds) if the action `emergency_land` is selected when the emergency protection is triggered. #### SYSTEM section diff --git a/docs/en/positioning.md b/docs/en/positioning.md new file mode 100644 index 0000000..3952a15 --- /dev/null +++ b/docs/en/positioning.md @@ -0,0 +1,176 @@ +# Positioning systems setup + +The `clover` software officially supports the following [positioning systems](https://clover.coex.tech/en/programming.html#positioning) : + +* [optical flow](https://clover.coex.tech/en/optical_flow.html) +* [aruco](https://clover.coex.tech/en/aruco.html) +* [gps](https://clover.coex.tech/en/gps.html) + +The `clever-show` software supports all positioning systems supporte by`clover`. + +**Following configuration examples are for the Clover 4 copter, assembled and configured according to the [documentation](https://clover.coex.tech)**. + +It is recommended to set up and check one copter from the group and reproduce its settings for the rest of the copters before starting the group. + +Configure one copter to work with any of listed above positioning systems. Setup may include the following steps: + +* Editing `.launch` files of ROS package `clover`. These files are located in the directory `/home/pi/catkin_ws/src/clover/clover/launch` on the copter (on Raspberry Pi). +* Configuring the flight controller parameters. +* Editing [client](client.md) `clever-show` configuration file. +* Editing [сервера](server.md) `clever-show` configuration file. +* [Calibrating camera](https://clover.coex.tech/en/camera_calibration.html). + +Make sure that the copter holds the position autonomously: mark the checkbox near the name of the copter and press the "Takeoff" button in the right panel of the server interface. The copter should take off at the height specified in the `takeoff_height` parameter of the "FLIGHT" section in the [client configuration](.../drone/config/spec/configspec_client.ini). By default, this height is 1 meter. If the copter takes off and holds a position at 1 meter height, the check is passed. Put the copter on the ground by pressing the `Land` or `Land All` button. **Warning!** For your safety it is recommended to perform a test of autonomous takeoff with the remote control turned on and ability to intercept the copter into the manual mode. + +If the takeoff was successful, reproduce the client configuration, positioning settings and flight controller parameters to the other copters. Select the successfully configured copter in the table and upload the necessary configuration files from the selected copter to your computer: + +* `.launch` files for `clover` configuration can be saved with the command `Selected drones -> Retrieve file` in the server application. In the dialog box that opens, enter the path to the file on the copter: `launch` files of `clover` are located in `/home/pi/catkin_ws/src/clover/clover/launch/`, to this path you need to add the desired name of the `.launch` file, e.g. `/home/pi/catkin_ws/src/clover/launch/clover.launch`. After clicking the `OK` button, a new dialog box will open with the choice of the path for saving the specified file on your computer. +* The copter configuration file (`.ini`) can be saved by right-clicking on the row with the configured copter, selecting `Edit config` from the drop-down menu and then clicking the button `Save as`. You can also drag a cell from the `configuration` column to the file manager of your system - the server will automatically copy the configuration file to the open directory of the file manager. +* The server configuration file (`.ini`) can be saved by selecting `Server -> Edit server config` from the top menu and then clicking the button `Save as`. +* The flight controller configuration file can be saved by connecting to the flight controller through [QGroundControl](http://qgroundcontrol.com) application. It is possible to connect directly to the flight controller [via USB port](https://clover.coex.tech/en/connection.html) or [via TCP or UDP bridge](https://clover.coex.tech/en/gcs_bridge.html) (the TCP bridge is configured in the `clever-show` image by default, in the `Host Address` field you can enter the name of the copter instead of the ip address with the addition of .local at the end, e.g. clover-1.local). After connection you should go to [section](https://docs.px4.io/master/en/advanced_config/parameters.html#tools) `Parameters -> Tools -> Save to file...` and choose the path to save the parameter file. +* * The camera calibration file is useful for refinement of visual positioning. The name of the calibration file should consist of the id of the copter, for which the calibration was made, with the addition of the extension `.yaml', e.g. `clover-1.yaml'. To get the calibration files, use the [manual](https://clover.coex.tech/ru/camera_calibration.html). + +After loading the necessary files from the configured copter, copy these files to the other copters: select the necessary copters in the table and use the commands `Send -> Configuration`, `Send -> Launch files folder`, `Send -> FCU parameters file`, `Send -> Camera calibrations` from the `Selected drones` section of the [server](server.md#Selected-drones) application . + +## Settings of clever-show server and client + +The `clever-show' software suite includes many status checks of the copters to minimize the number of failed launches as well as a set of parameters to configure the positioning systems. All settings are stored in client and server application configuration files. Each positioning system has its own features that need to be taken into account when configuring the server-client interaction. Below are the settings that you need to pay attention to when configuring the client and server: + +* Server: + * [CHECKS](server.md#checks) section - server side copter telemetry checks + +* Client: + * [FLIGHT](client.md#flight-section) section - name of the frame_id reference coordinate system, flight parameters + * [FLOOR FRAME](client.md#floor-frame section) section - allows to create a new coordinate system with the name `floor` in relation to any existing coordinate system: + * `map` - matches the starting position of the copter when using optical flow or gps + * `aruco_map` - matches the origin of ArUco marker map coordinates + * `gps` - the origin of coordinates is in the specified GPS coordinate with rotation by the specified angle relative to the north, it is adjusted in [GPS FRAME] (client.md#gps-frame-section) and allows to set the coordinate system with a common origin for all copters. + * [FAILSAFE](client.md#failsafe-section) section - disabled by default, but allows you to configure emergency landing conditions of the copter: + * at loss of visual position - useful for ArUco marker positioning system. + * if there is a large distance between the current position and the point where the copter should be - with the help of this check it is possible to avoid unexpected behavior of copters during collisions or any physical problems + * [EMERGENCY LAND](client.md#emergency-land-section) section - configures emergency landing of the copter: the parameter `thrust` sets the throttle of motors to start landing, after the time `decrease_thrust_after` the copter starts to gradually reduce the throttle level to 0. **Attention!** The default gas level of the emergency landing is 45% - this setting works for the Clover 4 copter with a 3S battery. If your configuration is different, you should first determine the hovering throttle and then set the `thrust` parameter to 5% less than the hovering throttle. If the emergency landing throttle exceeds the hovering throttle of the copter, the copter may fly up for the first 3 seconds (the default value of `decrease_thrust_after`) and only then will start to smoothly reduce the motor throttle to 0. + +## Optical flow + +Optical flow - a method of positioning by computation of camera movement speed by calculation of pixel shift between adjacent frames. + +`Optical flow` is suitable for a demonstration flight of one copter or for a synchronous flight of several copters following the same indoor trajectory. But it is necessary to take into account, that this coordinate system doesn't set general origin for all copters - the origin of coordinates is the start position of each particular copter. Also it is necessary to note that this method calculates the position of the copter by speed of moving of its camera - it means, that an error constantly accumulates in the copter position and the position becomes more inaccurate with time. Therefore, it is not recommended to use this coordinate system for complex and long group flights. + +The `clever-show` image for the copter is set by default for flight on this positioning system (as well as the `clover` image) - the copter should have a laser rangefinder mounted on it and the camera should be tilted down by the plume back. + +Clover ROS package, configured by default, provides autonomous flight using `optical flow`. The parameters loaded by default when loading the firmware adapted for clover 4 involves positioning with `optical flow`. The default client and server configuration files also do not need to be modified to fly through this positioning system. + +However, if you need to switch to 'optical flow' positioning system from another previously configured system or to change the settings of this system, the information below could help. + +All the configuration files for `optical flow` configuration are located in the [examples/positioning/optical flow](../../examples/positioning/optical flow/) folder. + +### Clover ROS package configuration + +Configuring `optical flow` positioning system is described in the `clover` [documentation](https://clover.coex.tech/en/optical_flow.html). + +An example of a `.launch` configuration file: [clover.launch](../../examples/positioning/optical flow/launch/clover.launch). + +### Flight controller configuration + +Параметры, настраивающие полётный контроллер на возможность полёта по `optical flow`: [optical_flow.params](../../examples/positioning/optical%20flow/optical_flow.params). + +Для загрузки параметров на выделенные в таблице коптеры воспользуйтесь командой `Selected drones -> Send -> FCU parameters file` из верхнего меню и укажите путь к файлу с параметрами полётного контроллера. + +### Client configuration + +#### Option 1: Loading relevant parameters from the configuration example + +Client configuration with values applicable to work with `optical flow`: [client.ini](../../examples/positioning/optical%20flow/client.ini). + +To upload, use the command `Selected drones -> Send -> Configuration` from the top menu of the server. In the opened dialog box, select the option `Modify` and specify the path to the file `client.ini`. + +#### Option 2. Reset all client configurations + +In order to configure the client configuration for positioning by optical flow, you can reset the configuration data to default values. To do this, you need to delete the generated configuration files on the clients: + +* Select in the table the copter or copters which configuration you want to reset. +* Execute the command to delete the configurations on the selected copters by selecting `Selected drones -> Send -> Command`. In the dialog box that opens, type the command `rm config/client.ini` and press `OK`. + +### Server configuration + +#### Option 1: Loading relevant parameters from the configuration example + +Server configuration with values applicable to work with `optical flow`: [server.ini](../../examples/positioning/optical%20flow/server.ini). + +To set the parameters manually, use the command `Server -> Edit config` from the top menu of the server. + +#### Option 2. Reset all server configuration settings + +In order to configure the server configuration for positioning by optical flow, you can reset the configuration data to default values. To do this, delete the generated configuration file on the server: + +* Execute the command `rm config/server.ini` from the directory with the location of the application `server.py`. +* Restart the server by selecting the command `Server -> Restart server` from the top menu item. + +## Aruco + +ArUco-Markers is a popular technology for positioning robotic systems using computer vision. Positioning is performed by obtaining information about the location of special visual markers. + +This positioning system is flexible: markers can be placed on the floor, on the ceiling or on the walls. The main condition for positioning is to correctly enter coordinates in a special map of markers and mark its inclination relative to the floor. + +If the marker map is located on the floor, there are some nuances: right after switching on the copter does not know its position until the camera sees the marker map. Therefore, some checks on the copter position and flight safety become irrelevant: + +* It makes no sense to check the current position of the copter, as it is not defined immediately after loading, but the copter still has the take-off mechanism. +* It does not make sense to check the maximum distance of the animation start point to the current copter position, because it would never match at the start. +* The start action `fly` of the animation in the coordinate system `aruco_map` will have unpredictable consequences, because at the start the real position of the copter will be very different from the position calculated by the flight controller. Therefore, the only option for the parameter `start_action` in the [ANIMATION] section is `takeoff`: the ascent to the altitude defined by `takeoff_height` the parameter from the [FLIGHT] section relative to the current position of the copter. + +### clover ROS package configuration + +Setting up the positioning system by ArUco markers is described in the `clover` [documentation](https://clover.coex.tech/ru/aruco_map.html) . + +Examples of `.launch` files for setting up a marker map on the floor: + +* [clover.launch](../../examples/positioning/aruco%20floor/launch/clover.launch) +* [aruco.launch](../../examples/positioning/aruco%20floor/launch/aruco.launch) + +### Flight controller configuration + +Parameters adjusting the flight controller to allow flight by `ArUco`: [aruco.params](../../examples/positioning/aruco%20floor/aruco.params). + +To upload parameters to the selected copters in the table, use the command `Selected drones -> Send -> FCU parameters file` from the server top menu and specify the path to the flight controller parameters file. + +### Client configuration + +Configuration of the client with the values suitable to work with `ArUco`: [client.ini](../../examples/positioning/aruco%20floor/client.ini). + +To upload, use the command `Selected drones -> Send -> Configuration` from the server top menu. In the opened dialog box, select the option `Modify` and specify the path to the file `client.ini`. + +### Server configuration + +Configuration of the server with the values suitable to work with `ArUco`: [server.ini](../../examples/positioning/aruco%20floor/server.ini). + +To set the parameters manually, use the command `Server -> Edit config` from the server top menu. + +## GPS + +Satellite positioning is the preferred method of positioning for outdoor flights. GPS positioning requires [one of the officially supported modules for PX4](https://docs.px4.io/v1.9.0/en/gps_compass/). The accuracy of GPS positioning is about one meter. Using a ground correction station [GPS RTK](https://docs.px4.io/v1.9.0/en/gps_compass/rtk_gps.html) and special GPS RTK modules allows to achieve decimeter positioning accuracy. + +### clover ROS package configuration + +Setting up the positioning system by ArUco markers is described in the `clover` [documentation](https://clover.coex.tech/ru/gps.html). + +Example `.launch` file: [clover.launch](../../examples/positioning/gps/launch/clover.launch). + +### Flight controller configuration + +Parameters adjusting the flight controller to allow flight by `gps`: [gps.params](../../examples/positioning/gps/gps.params). + +To upload parameters to the selected copters in the table, use the command `Selected drones -> Send -> FCU parameters file` from the server top menu and specify the path to the flight controller parameters file. + +### Client configuration + +Warning! The initial positioning point of the frame `gps` must be changed before starting the client. For example, the test flight zone point on the territory of Technopolis Moscow is selected. + +Configuration of the client with the values suitable to work with `GPS`: [client.ini](../../examples/positioning/gps/client.ini). + +To upload, use the command `Selected drones -> Send -> Configuration` from the server top menu. In the opened dialog box, select the option `Modify` and specify the path to the file `client.ini`. + +### Server configuration + +Configuration of the server with the values suitable to work with `GPS`: [server.ini](../../examples/positioning/gps/server.ini). + +To set the parameters manually, use the command `Server -> Edit config` from the server top menu. diff --git a/docs/en/server.md b/docs/en/server.md new file mode 100644 index 0000000..f2374a0 --- /dev/null +++ b/docs/en/server.md @@ -0,0 +1,345 @@ +# Server + +Application for creating and running shows, configuring drones, animation and music. + +* [Installation and startup](start-tutorial.md#server-installation-and-startup) +* [Interface](#server-interface) +* [Setup](#server-setup) +* [Additional operations](#additional-operations-and-windows) + +## Server Interface + +The server has a visual graphical interface for user-friendly interaction. + +![Интерфейс сервера](../assets/server-gui.png) + +### Copter status table + +When a client connects to the server for the first time, a line is added to the table to display the client state, containing only the client name (`copter ID`). If the clients are configured to transmit telemetry automatically, the data in the table will be updated regularly. It is also possible to request telemetry of selected clients using the [Preflight check](#control) button . + +Rows can be sorted in ascending or descending order by clicking on the header of any of the columns. + +Columns can be swapped and their width can be changed: all changes are saved in the server configuration file when the server is shut down properly. Right-clicking on the table header will open a context menu with [built-in configurator](#column-preset-editor), where you can hide or display the columns, change their order, load a certain set of settings. When you start the server, the last used settings will be loaded and applied. + +The cells of the table are highlighted: + +* *in yellow*, if the required value is missing +* *in red*, if the data in the cell has not passed the check +* *in green*, if the data in the cell has passed the check + +The copter is considered **ready for animation playback** when all cells in a row are checked and highlighted in green. + +The copter is considered **ready to fly** if all cells in the row except `animation ID` and `dt` are checked and highlighted in green. + +#### Table columns + +* `copter ID` - the client name. Can be configured on the client side. Displayed immediately when the client is connected. Next to each Copter ID there is a checkbox - Copters whose ID is marked with a positive checkbox (tick) are considered * selected*. Cells in this column are always pass the check. + * By double-clicking on this field you can enter a new `copter ID` of the client and rename it. As a name, combinations of Latin letters, digits and dashes (A-Z, a-z, 0-9, '-') not longer than 63 characters are permitted. The dash cannot be the first character. +* `version` - a hash code of the current git version of the client. Cells in this column are checked when [check_git_version](#checks section) is enabled (value `true`) in the server settings. A cell in this column passes the check if the hash code of the git version of the given client and the server match (if the server is not located in the git repository, the check is passed out automatically). +* `configuration` - a user-defined version of the client configuration. Cells in this column are always pass the check. + * Cells of this column supports *drag-and-drop*. When you drag and drop a cell to any third-party application that supports files (e.g. "Explorer"), the client configuration file will be copied to the specified location. When a cell is dragged to another cell, the configuration file will be copied from one cell to another. When a file is dragged to a cell, it will be written to the client as a configuration (subject to validation). When the configuration is transferred to the client, the `PRIVATE` section will not be sent. +* `animation ID` - an internal name of the animation file loaded by the client. A cell in this column does not pass the check if there is no animation (value `No animation`). In other cases, if a cell is not empty, it will be checked. ** Attention!** Check if the names of the animation files correspond to the copters before starting. +* `battery` - a value of voltage on the copter battery in volts and charge in percent according to the flight controller. A cell in this column passes the check if the battery charge value is higher than [battery_percentage_min](#section-checks) specified in the server settings. In other cases, if a cell is not empty, it does not pass the check. +* `system` - a flight controller status. A cell in this column passes the check if its value is `STANDBY`. In other cases, if a cell is not empty, it does not pass the check. +* `sensors` - calibration status of the flight controller compass, accelerometer and gyroscope. A cell in this column passes the check if its value is `OK`. In other cases, if a cell is not empty, it does not pass the check. +* `mode` - flight controller mode. A cell in this column does not pass the check if its value `NO_FCU` or contains `CMODE`. In other cases, if a cell is not empty, it passes the check. +* `checks` - copter self-test state. A cell in this column passes the check if its value is `OK`. In other cases, if a cell is not empty, it does not pass the check. + * Double-clicking on a cell if there are errors will show a dialog box with full detailed information about all errors. +* `current x y z yaw frame_id` - current copter position with the coordinate system name. The cell is automatically passes the check if [check_current_position](#section-checks) is set to `false'. Otherwise, a cell in this column does not pass the check if its value is `NO_POS' or contains `nan'. Otherwise, if a cell is not empty, it passes the check. +* `start x y z action delay` - start position of the copter for playback of the animation, the first action during playback of the animation and the time after which the first action will be performed after the start of the animation. A cell in this column does not pass the check if its value `NO_POS`, the distance between the current and the starting position of the copter is greater than [start_pos_delta_max](#section-checks) or the client's animation module generates an error when processing the animation and checking that all points of the animation are above ground level. Otherwise, if a cell is not empty, it passes the check. +* `dt` - the delay between the time on the server and the client in seconds, including network latency. A cell in this column passes the check if its value is less than [time_delta_max](#checks-section) specified in the server configuration. In other cases, if a cell is not empty, it does not pass the check. If the values are too high, it signals that there is no time synchronization between the copter and the client. + +### Menu + +#### Selected drones section + +![Скриншот раздела Selected drones - Send](../assets/server-drone-send.png) + +This section contains several utilities to send various data and commands to *selected* clients. **Warning!** Do not use these commands during the flight of copters! + +* `Send` subsection + + `` - location of the `clever-show` software on the client. + + `` - location of `clover` ROS package on the client. + + * `Animations` - sends animation files, which were exported by the Blender addon, to selected copters. In the dialog box, you must select a *folder* containing the animation files. Each animation file will be sent to the client with the name corresponding to the file name without an extension. On the client, the file will be saved as `/drone/animation.csv`. + + * `Camera calibrations` - sends yaml files of camera calibration for `clover` service. In the dialog box, select *folder*, containing configuration files with extension `.yaml`. Each calibration file will be sent to the client with the name (copter ID) corresponding to the file name without extension. On the client, the file will be saved as `/camera_info/calibration.yaml`. **Warning!** An existing calibration file on the copter will be overwritten. + + --- + + * `Aruco map` - sends *single* aruco marker map file to all selected clients. In the dialog box, select *one* card file in the specified format. File on client will be overwritten and saved as `/.../aruco_pose/map/animation_map.txt`. Once the file is received and written, the client will automatically restart the `clover` service. In order to resume flight functions and to receive some telemetry values *it is necessary to wait* some time until the service is fully started. + + * `Animation` - sends *a single* animation file to all selected clients. In the dialog box you need to select *one* animation file. On the client, the file will be saved as `/drone/animation.csv`. This is a useful feature to quickly test multiple drones when used in combination with `Set start X Y to current position`. + + * `Configuration` - sends *a single* client configuration file to all selected clients. In the dialog box you need to select *one* configuration file in the set format. The configuration file may be incomplete, in this case only the parameters specified in the file will be overwritten. **Warning!** It is not recommended to use this action for mass overwriting of `copter ID`, except for the `/hostname` value. **Warning!** DO NOT send the server configuration file to clients. + + * `Launch files folder` - sends `.launch` files of `clover` service configuration. In the dialog box, select *folder*, which contains configuration files with extension `.launch` and `.yaml`. All files with this extension will be sent * to each* of the clients in the directory `/launch`. ** Warning!** Existing configuration files on copters will be overwritten, but files not sent by the server will not be deleted or modified. + + * `FCU parameters file` - sends and records *single* flight controller (FCU) configuration file to all selected clients. In the dialog box you need to select the *one* parameter file in the set format. The parameters on the flight controller will be overwritten. + + --- + + * `File` - sends *one* any file to all selected clients. In the dialog box, select *one* file. Then, specify the path, where this file will be saved to the clients (not including the file name). + + * `Command` - sends and executes any terminal command on all selected clients. In the dialog box, you need to enter the required command. The commands *may* use `sudo` rights. + +--- + +* `Retrive file` - downloads any file from clients to the selected directory in the server file system. If more than one client was selected during the download, its ID will be added to the file name from each client. In the dialog box, first enter the path to the required file on the client. Then, in the dialog box, specify the path, where this file will be saved on the server. + +--- + +* `Restart Service` subsection + + ![Скриншот раздела Selected drones - Restart](../assets/server-drone-restart.png) + + * `chrony` - restarts the `chrony` time synchronization service on selected clients. Use it for manual synchronization if time between server and clients is not synchronized. + * `clever` - restarts the `clover` service on selected clients. In order to resume flight functions and to get some telemetry values *it is necessary to wait* some time until the service is fully started. + * `clever-show` - restarts `clever-show` service on selected clients. During the restart the clients will be disconnected. + +--- + +* `Set start X Y to current position` - sets the animation start point of the selected clients to the values of the current X Y position. + +* `Reset start position` -sets the starting point of the animation of the selected clients to `0.0`, `0.0`. + +* `Set Z offfset to ground` - sets individual Z offset on each of the selected clients to a value equal to the current Z coordinate position. It can be used to equalize the common height of the copter flight. +* `Reset Z offfset` - sets its individual Z offset on each of the selected clients to `0`. + +--- + +* `Developer mode` subsection: **Warning!** Use these actions with great caution. +* `Update clever-show git` - updates the `clever-show` repository folder on selected clients. The client configuration files * will not be overwritten*. ** Warning!** For the changes to take effect, the `clever-show` service needs to be restarted*. + +--- + +* `Reboot` - fully reboots the flight controller and the onboard computer on the selected copters. During the restart, clients will be disconnected. + +#### Server section + +* `Music` subsection + + ![Скриншот раздела Server - music](../assets/server-music.png) + + * `Select music file` - loads the selected music file for further manual playback or after a certain time after the start of the animation. Supported extensions: `.mp3` and`.wav`. + * `Play music` - plays the loaded music. + * `Stop music` - stops the music playback. + +--- + +* `Edit server config` - opens [built-in configuration file editor](#config-editor) with the current server configuration for editing. The checkbox `Restart` is available - if checked, the server will be restarted when the configuration is saved. **Warning!** The changed configuration parameters will be applied to the server only after its restart (manual or automatic). + +* `Edit any config` - opens [built-in configuration file editor](#config-editor) and allows you to choose in the file system any configuration file with `.ini` extension for editing, or open a configuration specification file to create a configuration file based on it. + +--- + +* `Restart server` - completely restarts the server. **Warning!** After the restart the server will no longer be connected to the console it was originally started from, if the server was originally started from the console. + +#### Раздел Table + +![Скриншот раздела Table](../assets/server-table.png) + +* `Toggle select` (`Ctrl+A`) - selects all copters or deselects all copters. If not all copters are selected in the table, then *selects all* copters. Otherwise (if all the copters have been selected) *deselects* all the copters. +* `Select all` - selects all copters in the table. +* `Deselect all` - deselects all copters in the table. + +--- + +* `Remove selected drones` - removes selected copters from the table. **Warning!** In case the client was connected, the disconnection will be performed. If the client deleted in this manner was functioning properly, it will be reconnected as soon as possible. + +--- + +* `Configure columns` - opens the [built-in configurator](#column-preset-editor) of table column presets. + +### Боковая панель команд + +![Скриншот боковой панели](../assets/server-sidemenu.png) + +#### Control + +This section of commands is intended for high-level control of the drone swarm. + +* `Start after` spinbox - sets the delay time for synchronous start of animation by copters after pressing the 'Start animation' button. It is recommended to use values greater than zero for busy, interfered or pinged networks. +* `Music after` spinbox - sets the delay time for starting music after pressing the `Start animation` button. +* `Play music` checkbox - determines whether the music will be played when the animation starts. +* `Preflight check` button - all selected clients perform self-diagnostics and preflight check. The results, along with other client parameters, will be displayed in the table as the data arrives. This button is necessary if automatic transmission of telemetry is not configured on the client. +* `Start animation`button - sends the start time of the animation to all selected copters based on the time specified in the `Start after` spinbox. All selected copters start synchronous playback of the animation after pressing this button and after the time specified in the `Start after` spinbox. After the animation is finished, all copters will land. The button is active only if all copters are ready for playback of the animation. When clicked, an additional confirmation is requested. +* `Pause/Resume` button - pauses and resumes flight tasks. After each press, the button changes the state to the opposite. + * `Pause` state - pauses the task queue of all selected copters: any flight task is paused. It is recommended to use in emergency situations to detect a malfunctioning copter. **Warning!** This command does NOT interrupt the flight of the copter to a specified point (e.g.: elements of takeoff, landing; following to the initial animation point, etc.). + * `Resume` state - all selected copters *synchronously* will continue executing their task queues (for example, animation playback). + +#### Emergency Interception Tools + +* `Land selected` Button - all the selected copters stop their flight tasks, clear the task queue and immediately switch to AUTO.LAND landing mode. **Use it as one of the interception tools in case of emergency.** +* `Land ALL`button - ALL the copters stop their flight tasks, clear the task queue and immediately switch to AUTO.LAND landing mode. **Use it as one of the interception tools in case of emergency.** +* `Emergency land` button - all the selected copters stop their flight tasks, clear the task queue and immediately switch to emergency landing mode - all the motors are powered with small throttle, which decreases to zero after a certain time. **Use it as one of the interception tools in case of emergency.** +* `Visual-land` button - opens [dialog box](#visual-land) of the malfunctioning copters visual landing module. +* `Disarm selected` button - all the selected copters stop performing their flight tasks, clear the task queue and immediately turn off the motors. This may cause the copters to fall down and get damaged. +* `Disarm ALL` button - ALL the copters stop performing their flight tasks, clear the task queue and immediately turn off the motors. This may cause the copters to fall down and get damaged. **Use as the last resort in extreme cases as an interception tool.** + +#### Test commands + +This section contains commands to directly control the copters in order to check them. + +* `Test leds` button - all the selected copters perform two-second animation (running dots) with LED strip (white color). The command is *safe* and can be used to check the operation of LED strips, quality and delay of connection to the server or to find out if the copter and its `copter ID` in the table match. +* `Takeoff` button - all the selected copters take off vertically, and then hover over the takeoff point. The button is active only * if all selected copters are ready to fly. ** Warning!** Use it carefully, follow the safety procedures. Do not use it while performing other flight functions! + * `Z`checkbox - if the checkbox is active, the copter will take off to the specified `z` value. Otherwise, the copters will use their default values specified in their configurations, and the takeoff will be performed relative to the current height. + * `Z` spinbox - sets the `z` coordinate value of takeoff of the copters, in meters. Active only when the `Z` checkbox is enabled. +* `Flip` button - all the selected copters **make a flip ** - a 360 degree flip around one of the *horizontal* axes. **Warning!** Use with care, follow the safety procedure. **Warning!** To execute a flip, the copter must have a minimum height of more than 2m. **Warning!** Do not use during other flight functions! + +This section contains commands that are executed directly on the copter flight controller. + +* `Reboot FCU` button - restarts flight controllers of all selected copters. You can use it to update the rotation of the copter when it is determined only by the inertial copter system, e.g. when flying through the Pozyx positioning system or using Optical Flow. To resume flight functions and get some telemetry values * you need to wait* some time before rebooting the flight controller. +* `Calibrate gyro` button - switches flight controllers of all selected copters to the gyroscope calibration mode. **Warning!** The copters must be stationary during the calibration. +* `Calibrate gyro` button - switches flight controllers of all selected copters to the gyroscope calibration mode. **Warning!** The copters must be stationary during the calibration. + +## Server configuration + +### Configuration file + +The server configuration is created according to the [specification](../../Server/config/spec/configspec_server.ini), you can see the default values for any parameter after the `default` keyword. All changes are saved in the `server.ini` configuration file in the `clever-show/server/config` folder. + +Server configuration editing is available via `Config editor` GUI module through menu `Server -> Edit server configuration`. + +The default configuration is fully functional and does not require changes to quickly start the server. + +### Parameter description + +#### Root section + +* `config_name` - Arbitrary line, the name of the configuration file for ease of storage and to quick distinction of one configuration file from another. +* `config_version` - Arbitrary fractional number, configuration file version for ease of storage and quick distinction of one configuration file from another. + +#### SERVER section + +In this section, you can set the parameters of the server network communications. The following options are available: + +* `port` -TCP port that will accept incoming connections from clients. When using broadcast, this port will be automatically configured at the client. *It is recommended to change the default value for security reasons* (any five+ digit number if other software does not use the selected port). +* `buffer_size` - buffer size during data transfer. *No changes are recommended. It is recommended to use the same value for the server and clients.* + +#### CHECKS section + +In this section, you specify the parameters of copter checks which are being performed on the server side. The following options are available: + +* `check_git_version` - Whether there will be a check of conformity of git versions of the client and a server for indication in cells of the `version` column. +* `check_current_position` - Whether the current copter coordinates will be checked for errors in cells of the `current x y zaw frame_id` column. +* `battery_percentage_min` - Minimal battery charge of the copter, allowed for takeoff. Specified *in percent* (fractional value from 0 to 100). A value in the `battery` column less than the specified one will not pass the check in the `battery` column. +* `start_pos_delta_max` - Maximum distance between the current position of the copter and its point of takeoff in the animation file, allowable for takeoff. It is specified *in meters* (fractional value from 0 to `inf`). A distance greater than the specified one will not pass the check in ` start x y z` column. T It is allowed to use the string `inf` for any valid distance. +* `time_delta_max` - Maximal time (including network delay) difference (absolute value) between server and client, allowable for takeoff. Specified *in seconds* (fractional value from 0 to `inf`). A difference greater than the specified one will not pass the check in the `dt` column. + +#### BROADCAST section + +The server can use UDP broadcast to send clients actual information about the server configuration. Thus, it is possible to automatically connect clients to the server without the need for additional manual configuration. In this section the parameters of this mechanism are defined: + +* `send` - whether or not broadcasts will be used for data transmission (if `False` value, broadcasts will NOT be sent). Use `False` in case of increased security requirements, network overload or inability to broadcast (due to firewall or network configuration). +* `listen` - whether the server will listen to the broadcast port in order to automatically shut down to avoid having multiple servers on the same network. +* `port` - UDP port on which to send messages. *It is recommended to change the default value for security reasons.* **Warning!** When changing this option, clients will NOT be able to receive autoconfiguration messages before changing (manually) the corresponding parameter in the client configuration to the same value. +* `delay` - The frequency (in seconds, fractional value) at which broadcast messages will be sent. Increase delay to reduce network load. Reduce the delay to reduce the response and connection time when clients start up for the first time. + +#### NTP section + +In addition to time synchronization (with millisecond precision) using the chrony package, there is an alternative - the ability to use external (in the presence of a local network connection to the Internet) or intranet NTP-servers. **Warning!** For proper system operation, both **the server and the clients** must use a single method of time synchronization (set of parameters in this section). This section is fully unified for both server and clients. + +* `use` - determines whether time synchronization using NTP will be used. (if `False', the local OS time will be used (synchronized automatically when using chrony). *It is recommended to use chrony instead of NTP*. +* `host` - host name or IP address of the NTP server (local or remote) +* `port` - port used by the NTP server + +#### TABLE section + +* `remove_disconnected` - Defines the behavior when the connection to the client is terminated. If `True`, all information about the client *will be deleted* both from internal memory and *from the table*. *This may lead to 'jumps' of the table when clients are disconnected.* When `False` is set, disconnected clients *will not be* deleted from the table, but will be displayed with the cell highlighted in red in the `copter ID` column. All data will be saved. When a client is reconnected, it will be associated with the same row in the table, and the cell with the value of `copter ID` will be green again. + +##### PRESETS subsection + +It is not recommended to change this section manually - you can interact with the table to edit these parameters or using the built-in table configuration dialog. + +* `current` - Name of the currently selected set of table columns settings +* `` + * `` - the value is a list ( through ",") of the boolean value (whether the column is displayed in the table) and an integer number greater than 0 (column width in pixels). + +## Additional operations and windows + +### Visual land + +Visual Emergency Landing Module, designed for quick search by the operator of a visually malfunctioning copter using the binary search method. All copters must be equipped with LED strip for proper usage. + +#### Interface + +![LED Visual Land](../assets/server-led-emergency-land.png) + +When you click the `Visual land` button, all copters are divided into two equal groups arranged in the order shown in the table. The first half of the copters lights the LED strip green, the second half lights it red. At pressing the green or red button the group corresponding to the color of the pressed button is selected. The copters of the selected color are again divided into two halves, and each half lights the LED strip with green and red color respectively. The other copters turn off the LED strip. + +By pressing the buttons corresponding to the color of the group where the malfunctioning copter is located, you can determine its number and perform an emergency landing within a logarithmic number of steps relative to the number of copters, which is much faster than going through the copters one by one. + +At any step you can land or turn off the motors of all copters with LED strip on by pressing the `Land` or `Disarm` button. + +### Config editor + +Built-in configuration editor allows you to open and intuitively edit server and client configuration files, as well as third-party configuration files in `.ini` format. The editor can be invoked using the context menu in the copter table in the server, from the server menu, or it can be launched as a separate application. + +The value of each column can be edited by double-clicking on it. + +The `Option` column values (names of sections and options) cannot be repeated within the same tree level - the names of sections and options will be automatically changed with the addition of numbering when names are repeated. + +For `Value` column values (actual option values) the corresponding built-in value editor will be used (for integer, fractional and boolean values). Values of arrays of any type will also be displayed as tree elements. Each of these values can be edited, moved, deleted and added independently. + +When editing a option without a value you can specify a value `` or as a list in the form of `[1, 2, 3]` or `(1, 2, 3)` - this automatically converts the value into a list. + +![Config editor](../assets/server-config-editor.png) + +The configuration file is displayed as a tree in the editor. Each "line" in the view is a section or a configuration option. Sections of the configuration can be minimized. Each line can be moved using drag-n-drop to change the order of parameters and the structure of the partitions (it is possible to drag-n-drop a line *to* a configuration section to move another section or option into it). If you hold down the `alt` key while dragging, the option or section will be copied. + +* `Color Indication` checkbox turns on or off the color indication of line status: + * *Blue* - This option *were not present* in the configuration file when it was loaded and its value was taken from the configuration specification. Changing this option will add it to the current configuration file. + * *Turquoise* - This option is located in the configuration file, but its value is the same as the default value in the configuration specification. + * *Yellow* - The value of this option was changed by the user in the current editing session. + * *Green* - This option was added during the current editing session. + * *Red* - This option was excluded from the configuration during the current editing session. It will not be saved in the configuration. +* `Restart` checkbox - available only when editing server or client configurations. Automatically restarts the server or client after saving the configuration. +* `Save as` button - Allows you to save a copy of the configuration file to your computer. In the dialog box, select the location and file name. **Warning!** Configuration *will not be* checked for specification compliance! +* `Save` button - Saves the configuration file. Before saving, the file will be checked for compliance with the current configuration specification. If errors occur, a detailed report on them will be displayed and you will be prompted to continue editing. When saving a configuration generated from the specification, you will be offered to choose a new path to save the file. +* `Cancel` button - Cancels the changes made to the configuration and closes the configuration editor dialog box. + +#### Context menu and configuration editor commands + +![Cconfig editor context menu](../assets/server-config-editor-menu.png) + +* `Duplicate` (`Shift+D`) - makes a copy of an option or a section (with all the options it contains). Numbering will be added to the option or section name to avoid repeating names. +* `Toggle exclude` (`Alt+Del`) - excludes an option or a section from the configuration. The option or section *not* will be deleted, but *not* will be written when you save it. Repeatedly applying this command to already excluded options or sections will return them to normal state. +* `Remove from config` (`Del`) - *removes* an option or a section from the configuration. **Warning!** This action is irreversible! +* `Clear item value` (`Shift+R`) - *clears* the *value* of an option or of all the section options (if used on a section). It also resets the option value type, and it will be restored from the next text input when editing the value. **Warning!** This action is irreversible! +* `Reset value to default` (`Ctrl+R`) - brings to the default value (from the configuration specification) the value of the option or all the options of the section (if used on the section). It also resets the option value type, and it will be restored from the next text input when editing the value. **Warning!** This action is irreversible! + * `Reset all changes` (`Alt+R`) - restores an option or all the options of the section (if used on the section) to its original state. **Warning!** This action is irreversible! +* `Add option` (`Shift+A`) - adds an option with an empty value, the first editing of the value will determine its type. +* `Add section`(`Ctrl+A`) - adds section. + +### Column preset editor + +Allows you to edit, delete and add presets for column display in the table. + +The window of the table column editor has two appearances: + +#### Context menu + +![Column preset editor context menu](../assets/server-column-popup.png) + +Can be opened by right-clicking on a table header. + +* `Column list` By drag-and-drop, you can change the order of columns. The changes will be applied instantly and automatically saved to the server configuration. +* `Drop-down preset list` - Allows to load and automatically apply any of the preset recorded in the server configuration file. +* `Manage presets button` - opens a preset editing dialog box (see below). + +#### Dialog box + +![Column preset editor dialog](../assets/server-column-editor.png) + +Can be opened from the server context menu or from the server menu in the `Table` section. + +* `Column list` - By using checkboxes you can hide or display columns in the table. By drag-and-drop, the column order can be changed. *The changes will only be applied or saved after `Save` or `Apply` .* buttons are pressed. +* `Drop-down preset list` - Allows you to select any of the presets recorded in the configuration file for editing. + * ` item` - Creates a new preset. In the appeared dialog box, enter a name for the preset. The new preset will be based on the default preset (`DEFAULT`). +* `Add` button - Creates a new preset. In the appeared dialog box, enter a name for the preset. The new preset will be based on the default preset (`DEFAULT`). +* `Remove` button - Removes a selected preset. **Warning!** This action is irreversible! +* `Save` button - Saves the preset in the configuration file. +* `Apply` button - Saves the preset in the configuration file and applies it to the table. diff --git a/docs/en/start-tutorial.md b/docs/en/start-tutorial.md index 9340e51..54da95e 100644 --- a/docs/en/start-tutorial.md +++ b/docs/en/start-tutorial.md @@ -94,7 +94,7 @@ For autonomous animation playback, all copters must have a configured positionin Before checking the autonomous takeoff, perform an automatic check of the copter configuration according to [article](https://clover.coex.tech/en/selfcheck.html). -Make sure that the copter holds the position autonomously: mark the checkbox near the name of the copter and press the "Takeoff" button in the right panel of the server interface. The copter should take off at the height specified in the `takeoff_height` parameter of the "FLIGHT" section in the [client configuration](.../drone/config/spec/configspec_client.ini). By default, this height is 1 meter. If the copter takes off and holds a position at 1 meter height, the check is passed. Put the copter on the ground by pressing the `Land` or `Land All` button. **Attention!** For your safety it is recommended to perform a test of autonomous takeoff with the remote control turned on and ability to intercept the copter into the manual mode. +Make sure that the copter holds the position autonomously: mark the checkbox near the name of the copter and press the "Takeoff" button in the right panel of the server interface. The copter should take off at the height specified in the `takeoff_height` parameter of the "FLIGHT" section in the [client configuration](.../drone/config/spec/configspec_client.ini). By default, this height is 1 meter. If the copter takes off and holds a position at 1 meter height, the check is passed. Put the copter on the ground by pressing the `Land` or `Land All` button. **Warning!** For your safety it is recommended to perform a test of autonomous takeoff with the remote control turned on and ability to intercept the copter into the manual mode. You can configure the copter to utilize a different positioning system. The following [positioning systems](https://clover.coex.tech/en/programming.html#positioning) are officially supported: @@ -114,13 +114,13 @@ You can find a description of setup and operation of the LED strip in `clover` [ Time synchronization between all copters involved in the animation and the server is very important for correct playback of the animation. The more precisely the time is synchronized, the more coordinated the flight of the copter group will be. It is recommended to use [chrony](https://chrony.tuxfamily.org) service as a time synchronization tool. The process of installation and setup of this service for the server PC is described [above](#server-installation-and-startup), this service is already installed in the `clever-show` image. -After the first copter connection to the server, the `chrony` service on the copter is automatically configured to connect to the ip address of the server and rebooted. However, the `chrony` service in the server may stop sending packets of time synchronization when the wifi network changes and the time between the copters and the server will stop being synchronized. The difference between the time from the copter and the server time is displayed in the `dt` column of the server table. Normal time difference should be **not more than 0.1 second** (about 0.01 second), but it may be more due to network latency when transmitting telemetry from the copter. If the time difference is greater than 0.1 second it is recommended to restart the `chrony` service with the command from the top menu of the server `Selected drones -> Restart service -> chrony`. This command restarts the service `chrony` on the server (you will need to enter the user password) and on the copters. +After the first copter connection to the server, the `chrony` service on the copter is automatically configured to connect to the ip address of the server and rebooted. However, the `chrony` service in the server may stop sending packets of time synchronization when the wifi network changes and the time between the copters and the server will stop being synchronized. The difference between the time from the copter and the server time is displayed in the `dt` column of the server table. Normal time difference should be **no more than 0.1 second** (about 0.01 second), but it may be more due to network latency when transmitting telemetry from the copter. If the time difference is greater than 0.1 second it is recommended to restart the `chrony` service with the command from the top menu of the server `Selected drones -> Restart service -> chrony`. This command restarts the service `chrony` on the server (you will need to enter the user password) and on the copters. ## Animation preparation and execution By default [basic](.../examples/animations/basic/basic.csv) animation is already uploaded to the client: -basic animation +basic animation The red line is x axis, the green line is y axis. The cube in the animation moves in a positive direction along the x axis. The animation playback module will draw the copter along the points specified in the animation file relative to the coordinate system specified in the `frame_id` option in the FLIGHT [client configuration](.../../drone/config/spec/configspec_client.ini) (`map` by default). The copter will start the motors before takeoff and turn them off after landing. The moments of takeoff and landing of the copter are determined automatically. @@ -130,6 +130,6 @@ Check the playback of the animation by pressing the `Start animation` button: th The result of the animation should look like this (up to the accuracy of PID tuning): -basic animation +basic animation **The detailed information on the animation module is located [here](animation.md).** \ No newline at end of file