Integration examples

In this section, a series of examples will be presented so that the user knows how to perform certain customizations in the 1x PDI Builder. In addition, some examples of integration between the Autopilot 1x and external devices are presented.

AP communication with PC

Since Veronte Autopilot 1x can be connected to a computer via a USB or serial interface, the configuration for both connections is already set by default in 1x PDI Builder.

However, users should check that this configuration has not been modified to ensure a correct communication via both ways in case one of them is lost. For this:

Go to Input/Output menu \(\rightarrow\) I/O Setup panel. Each USB, RS232 and RS485 Producers must be bidirectionally connected to a Commgr port:

Important

Users should also check that the Commgr ports to which USB and serial ports are connected are not routed. For more information on Routing, see Ports - Communications section of this manual.

../_images/ap_communication_pc.png

USB/RS232/RS485 \(\leftrightarrow\) Commgr port

ArcTrim Button

The ArcTrim button allows the user to trim the stick signal directly from the stick position, before the operation, by simply clicking on it. In addition, this button is considered as an ‘action button’ that can be embedded in the Veronte Panel.

To do this, the following steps should be followed:

  1. Go to Block Programs menu.

    • Create a program to make the necessary connection to the Arc Trim block.

      Usually the user has a Stick program where the blocks that are related to the stick are implemented.

    • Add the Arc Trim block and connect the input and output variables to it.

      Usually the input variables are Stick Input u1-u4 and the output variables Stick Input d1-d4.

    • Finally, enable the block to be commandeded by simply clicking on the wifi icon.

    ../_images/arctrim_block.png

    ArcTrim Button - Block

  2. Configure the trim vector of the Arc Trim block.

    Depending on the range of the signal, the following values are recommended:

    • If the signal ranges from 0 to 1 \(\Rightarrow\) 0.5.

    • If the signal ranges from -1 to 1 \(\Rightarrow\) 0.

    In this example, since the signal is in the range 0-1, 0.5 is set:

    ../_images/arctrim_block_configuration.png

    ArcTrim Button - Block configuration

  3. Go to Automations menu \(\rightarrow\) create a New Automation \(\rightarrow\) go to Events.

    Select the Button option and choose the desired icon for this button.

    In addition, it is recommended to activate the Confirmation checkbox, to avoid trimming the stick by mistake.

    ../_images/arctrim_automation_event.png

    ArcTrim Button - Events

  4. In the created automation, go to Actions.

    • Add the Command block action.

    • Select ArcTrim block to command and choose the commandable Id.

    • Finally, it is recommended to activate both checkboxes:

    ../_images/arctrim_automation_action.png

    ArcTrim Button - Actions

  5. In Veronte Ops, this button will appear embedded in the Veronte Panel.

    Note

    This action button will only appear on the Veronte Panel if the action buttons have been enabled to be shown on it. For more information on this, see Veronte Panel - Main widgets section on the Veronte Ops user manual.

    ../_images/arctrim_veronte_panel.png

    ArcTrim Button - Veronte Panel

    When clicking on it, the following confirmation message will be displayed (as the confirmation checkbox has been activated in the automation):

    ../_images/arctrim_veronte_panel_confirmation_message.png

    ArcTrim Button - Confirmation message

    Now, the stick is trimmed.

CAN communication

Here are described the steps to be followed in order to correctly receive and transmit CAN messages:

CAN messages reception

../_images/can_messages_reception_diagram.png

CAN messages reception diagram

  1. Go to Input/Output menu \(\rightarrow\) CAN Setup panel \(\rightarrow\) Mailboxes tab.

    Configure the mailbox to receive a message with the appropiate ID (in this example ID 28 has been configured):

    ../_images/can_messages_reception_mailbox.png

    CAN messages reception - Mailboxes configuration

  2. Go to Input/Output menu \(\rightarrow\) CAN Setup panel \(\rightarrow\) Configuration tab.

    Connect an Input filter with the right CAN ID to a Custom message consumer:

    ../_images/can_messages_reception_input_filter.png

    CAN messages reception - CAN Setup configuration

    ../_images/can_messages_reception_input_filter_configuration.png

    CAN messages reception - Input filter configuration

  3. Go to Input/Output menu \(\rightarrow\) CAN Setup panel \(\rightarrow\) Custom message 1 tab (as Custom Message 1 has been selected as consumer).

    Configure the message reading as desired in RX by setting the correct CAN ID.

    The different options and parameters to be configured are explained in the RX Messages (Custom Messages) - Input/Output section of this manual.

    ../_images/can_messages_reception_custom_message.png

    CAN messages reception - Custom message configuration

CAN messages transmission

../_images/can_messages_transmission_diagram.png

CAN messages transmission diagram

  1. Go to Input/Output menu \(\rightarrow\) CAN Setup panel \(\rightarrow\) Custom message 1 tab.

    Select the fields to send in TX or TX Ini, as it is a Producer. More information on the configuration of CAN messages can be found in the TX/TX Ini Messages (Custom Messages) - Input/Output section of this manual.

    For example, a CAN messsage set to ID 12:

    ../_images/can_messages_transmission_custom_message.png

    CAN messages transmission - Custom message configuration

  2. Go to Input/Output menu \(\rightarrow\) CAN Setup panel \(\rightarrow\) Configuration tab.

    Connect CAN custom message 1 producer (as the message has been configured in the Custom Message 1 tab) to an Output filter as follows:

    ../_images/can_messages_transmission_output_filter.png

    CAN messages transmission - CAN Setup configuration

Warning

Remember that it is necessary to have at least 1 free mailbox for TX messages.

Data transmission between Veronte Autopilots 1x

To establish a proper communication between the ground and air units, the telemetry and sniffer menus must be configured, respectively.

A simple example of use between a ground unit and an air unit is shown below:

In the 1x ground unit:

  1. Go to Telemetry menu \(\rightarrow\) Telemetry panel \(\rightarrow\) Data link to VApp tab (for more information about this, see Data vectors - Telemetry section of this manual).

  2. Add the variables: Absolute: UAV position, Yaw, Pitch and Roll.

  3. Set a Frequency, it is recommended to set it to 10 Hz.

  4. On Address, point to the 1x air unit (it is needed to have both units connected through the radio in order to be able to see them on the menu).

../_images/data_transmission_telemetry.png

1x ground unit - Telemetry

For the 1x air unit:

  1. Go to Telemetry menu \(\rightarrow\) Sniffer panel (for more information about this, see Sniffer - Telemetry section of this manual).

  2. Add a new Sniffer.

  3. Configure the same variables (keeping the same order) than in the ground unit.

  4. On Address, point to the 1x ground unit.

  5. In the gear next to it, configure the 4 incoming variables as System Variables: assign UAV Position to Moving Object and the 3 variables from attitude to 3 different User Variables (keeping the same order as well).

../_images/data_transmission_sniffer.png

1x air unit - Sniffer

Flare and Decrab phase configuration

As flare and decrab guidance are not included in the landing algorithm, since the decrab is control dependent (yaw must be aligned with the runway direction), the following shows how to implement this guidance in a generic fixed wing configuration:

  1. First, it can be useful to create a program that computes the altitude above the touchpoint, the lateral error over the desired route and the heading error. If all conditions met, the flare phase is triggered:

    ../_images/flare_decrab_phases_auxiliar_program.png

    Flare and Decrab phase - Auxiliary program

  2. Flare and Decrab guidance definition

    In the Guidance program (where the guidances for all phases are defined), add the Flare phase to the Phase Switch block. Then, the flare and decrab guidance must be built as follows:

    • The desired vertical speed is overwritten to be a function of the height above the runway. In this case the height is calculated in an auxiliary program (Height Above Touchpoint variable calculated in step 1), but the AGL could be used.

    • The desired yaw is overwritten directly by the runway direction.

    • The desired roll is overwritten to 0º.

    • The desired IAS is overwritten to a speed slightly above the stall speed, in this example 15 m/s.

    ../_images/flare_decrab_phases_flare_guidance.png

    Flare and Decrab phase - Flare and decrab guidance definition

  3. Pitching control

    The desired vertical speed is used for pitch control as shown below:

    ../_images/flare_decrab_phases_pitching.png

    Flare and Decrab phase - Pitching control

  4. Thrusting control

    The throttle is used to maintain the IAS (slightly above stall) and when a height above touchpoint of 1 m is reached, the motor is cut off. Again, a user variable is used here (Height Above Touchpoint variable calculated in step 1), but the AGL could be used:

    ../_images/flare_decrab_phases_thrusting.png

    Flare and Decrab phase - Thrusting control

  5. Rolling control

    For the roll, simply try to maintain the desired roll (0º):

    ../_images/flare_decrab_phases_rolling.png

    Flare and Decrab phase - Rolling control

  6. Yawing control

    The yaw control (rudder) is based on the desired yaw:

    ../_images/flare_decrab_phases_yawing.png

    Flare and Decrab phase - Yawing control

    Important

    This algorithm requires a good yaw estimation if users want to have Decrab, so magnetometer or GNSS Compass is required.

Flare phase configuration

However, for a Flare phase without Decrab, the yaw control should be based on heading instead of being based on yaw. To do so, the Guidance and Yawing programs must look as shown below:

../_images/flare_decrab_phases_flare_guidance_without_decrab.png

Flare phase - Flare guidance definition

../_images/flare_decrab_phases_yawing_without_decrab.png

Flare phase - Yawing control

For more information on block programs, please refer to Block Programs section of this manual.

External devices

The step-by-step instructions for the following external devices will be explained in detail in the following sections: