Actuators/Servos

The user can configure any actuator compatible with the communication interfaces.

CAN

Ultramotion

1x PDI Builder configuration

Follow these steps to configure Veronte Autopilot 1x to command the Ultramotion servo using CAN2.0B protocol.

  1. (optional) Connect the Ultramotion servo to the PC to adjust its configuration.

    Important

    This example uses the default device settings.

    For custom configurations, please refer to the manufacturer’s CAN communication protocol.

  2. Connect the servo to the Autopilot 1x via CAN. Detailed information on this connection can be found in the Ultramotion - Integration examples section of the 1x Hardware Manual.

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

    Connect a CAN custom message producer (in this case CAN custom message 0 is used) to an Output filter consumer, in this example Output filter 1.

    And, configure this Output filter with the correct CAN bus, corresponding to the physical connection of the device.

    ../../_images/ultramotion_can_configuration.png

    Ultramotion - CAN Setup configuration

  4. Go to Input/Output menu \(\rightarrow\) CAN Setup panel \(\rightarrow\) Custom message 0 tab (since the producer CAN custom message 0 has been connected to the output filter).

    • Add a new message in TX (as it is for transmission) and configure the parameters as follows:

      • Extended: Enabled

      • CAN ID: 3

      • Endianness: Little endian

      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.

      ../../_images/ultramotion_custom_message.png

      Ultramotion - TX message

    • Next, click on edit_list to access the message configuration.

      Configure the message to be sent with the variable that users want to use for commanding. This variable should be set to compressed unsigned 16-bit. In addition, users must send values from 0 to the maximum position of the Servo Cylinder.

      To do this, it is recommended to control the variable internally as a throttle, for this set the Encode from 0 to 1. And to decode it to position values, the Decode parameter must be set from 0 to the maximum position:

      ../../_images/ultramotion_edit_message.png

      Ultramotion - TX message configuration

      For more information on configuring CAN custom messages, refer to the Custom Messages types - Input/Output section of this manual.

Servo custom configuration

When connecting the Ultramotion servo to the PC, a folder named “UltraMotion” will automatically open containing two text configuration files: CONFIG.TXT and HARDWARE.TXT.

../../_images/Ultramotion_usb_connection.png

These files define the servo configuration parameters, which should be adjusted according to the user’s specific requirements.

Note

It is recommended to create a backup of the default configuration files before making any changes. This backup can be used if necessary.

Danger

Before modifying the HARDWARE.TXT file, please refer to the manufacturer’s product manual. Altering this file may result in product damage.

Modification of the CONFIG.TXT file is necessary if more than one servo is to be integrated into the setup.

This section explains how to configure the key parameters of the CONFIG.TXT file.

When opening the CONFIG.TXT file, the user will see a layout similar to the following, where each line corresponds to a specific configuration parameter.

../../_images/ultramotion_config_file.png

Ultramotion - CONFIG.TXT file

  • opMode. Operating Mode: 0 for RS-485 command line interface and 1 for commands via CAN bus.

  • kp, ki, and kd. Gains values for the proportional, integral, and derivative terms, respectively, of the position PID control loop.

  • spMin. This configuration variable sets the minimum allowable position of the Servo Cylinder.

    Important

    This value must be greater than rPos, defined in the HARDWARE.TXT file.

  • spMax. This setting sets the maximum allowable position of the Servo Cylinder.

    Important

    This value must be less than ePos, defined in the HARDWARE.TXT file.

    Explanation

    ePos and rPos define the physical limits of the actuator. For safety reasons, it is necessary to set more restrictive operating limits (spMin and spMax) to prevent the actuator from reaching or exceeding these physical limits.

  • CANspd. This defines the baudrate of the CAN interface. There are 6 options designated by the integers 0 to 5:

    Integer

    0

    1

    2

    3

    4

    5

    Baud Rate

    1 Mbps

    500 Kbps

    250 Kbps

    125 Kbps

    100 Kbps

    50 Kbps

  • CANext. CAN Message Type: CANext = 0 configures standard message type (11-bit identifiers), and CANext ≠ 0 sets the actuator to extended message type (29-bit identifiers).

  • unitID. Actuator’s network address and is used along with IDmask to filter incoming CAN command messages.

    Since there are multiple servos integrated into the system, it is essential to assign a unique CAN ID to each one.

    This configuration allows Autopilot 1x to send CAN messages to each actuator individually, ensuring precise and independent control of each unit. Proper CAN ID assignment is critical to avoid communication conflicts and ensuring smooth operation within the network.

  • IDmask. Mask for CAN Identifier used along with unitID to filter incoming CAN command messages.

    For acceptance, the message identifier must match unitID, where each corresponding bit in IDmask is set to ‘1’.

    If a bit in IDmask is set to ‘0’, the corresponding bit of an incoming can message is matched for acceptance regardless of its value.

    Note

    • If IDmask is set to 0x00000000, CAN messages with any identifier will be accepted.

    • If IDmask is set to 0x1FFFFFFF, only CAN messages with an identifier that exactly matches the relevant bits of unitID will be accepted.

    • If CANext = 0, only the lower 11 bits of unitID and IDmask are examined (standard message type).

    • If CANext ≠ 0, the lower 29 bits of unitID and IDmask are examined (extended message type).

  • pMin and pMax. These variables define the valid range of position commands that will be sent to the actuator via CAN messages. The value of pMin/pMax will be mapped to the actuator travel range spMin/spMax.

  • SUact. Startup Action: Defines the behavior of the actuator at startup before receiving a valid CAN command message.

    • SUact = 0 \(\Rightarrow\) Actuator holds position.

    • SUact = 1 \(\Rightarrow\) Actuator executes a trajectory movement to defPos (default position).

  • defPos. This is the absolute encoder value of the default position. Depending on the values of the SUact and TOact variables:

    • SUact \(\rightarrow\) Actuator may move to defPos upon startup if no valid position command messages have been received.

    • TOact \(\rightarrow\) Actuator can move to defPos in case no position command message is received within the rxTO timeout period.

  • rxTO. Defines the interpolation timeout period in increments of 800 \(\mu s\).

  • TOact. Timeout Action: Defines the behavior of the actuator after not receiving a valid CAN position command message within the configurable reception timeout period rxTO.

    • TOact = 0 \(\Rightarrow\) Actuator holds position.

    • TOact = 1 \(\Rightarrow\) Actuator executes a trajectory movement to defPos (default position).

  • txData. This configuration variable is a character string that selects the specific telemetry data bytes to be broadcast.

    This string may have a length from 1 to 8 characters, which will determine how many bytes of data are included in the telemetry message. Each character in txData designates one byte in the telemetry message.

  • txID. CAN Message ID: Represents the destination address of the telemetry message.

    It can be 29-bit or 11-bit CAN 2.0B identifier, however, if CANext = 0, only the lower 11 bits are used.

PWM

The following steps explain how to configure a PWM servo in Veronte Autopilot 1x.

  1. Connect the servo according to the manufacturer’s documentation and follow the PWM - Integration examples section of the 1x Hardware Manual to connect it to the Autopilot 1x.

  2. Go to Connections menu \(\rightarrow\) PWM panel.

    • Select and configure the PWM pins where the servos are connected. Set the frequency according to the manufacturer’s specifications.

      ../../_images/servo_pwm_connections.png

      PWM - Connections configuration

    Caution

    If there is no PWM tab or the PWM pin where the servo is connected is not shown on the interface, it must be because it is configured as GPIO. For more information on this, refer to PWM - Connections section of this manual.

  3. Go to Block Programs menu.

    • Create a program to make the necessary connection to the servo blocks.

      Usually the user has a Control to servo program where the servo blocks are implemented.

    • Configure the Actuator block connecting PWM block as Pulse and Actuator Outputs as Servo:

      ../../_images/servo_pwm_program.png

      PWM - Block Programs connection

    • Assign a given PWM to a given actuator output.

      The assignment is done automatically in the order in which they are configured in the blocks. That is, the first PWM (the one with Id 0) will relate to the first actuator output, which does not necessarily mean that PWM 0 is assigned to Actuator Output s0.

      In this example, the PWMs are assigned to the actuator outputs as shown in the following figure:

      ../../_images/servo_pwm_blocks.png

      PWM - Block Programs configuration

      Note

      For instance, PWM 5 (with id 2) is assigned to Actuator Output s2.

    For more information on Actuator and PWM blocks, see Actuator - Servos blocks and PWM - Servos blocks of Block Programs section.

Serial

Serial servos are configured differently than PWM servos as the protocol of a serial device must be defined with serial custom messages.

In this case a PWM variable must be sent through a serial interface.

Volz DA26 - RS485

First, users can find the recommended wiring connection for RS485 connection between Volz DA26 servos and Veronte Autopilot 1x in the Volz DA26 - RS485 - Integration examples section of the 1x Hardware Manual.

Then, follow the steps below to configure a Volz DA26 servo via RS-485.

  1. Go to Input/Output menu \(\rightarrow\) I/O Setup panel.

    Bidirectionally connect the RS485 port to a RS custom message, in this example RS custom message 0 is used:

    ../../_images/servo_volz_io_setup.png

    RS485 \(\leftrightarrow\) RS custom message 0

  2. Click on gears to configure the RS custom message 0 producer. Users must setup it by defining the protocol specified by the manufacturer:

    Note

    As the RS-485 is a Half Full duplex serial port, Veronte Autopilot 1x needs to leave this serial bus free for a certain time in order to receive the servo response. This is done by setting the Delay parameter.

    ../../_images/servo_volz_rs_custom_message.png

    Volz DA26 - RS custom message 0 configuration

    • Endianness: Big endian

    • Period: 0.035

    • Delay: 0.0015

      • Matcher x77: Silent mode command (0x77).

        • Value: 119

        • Bits: 8

        • Mask: 255

      • Matcher x1: Servo interface Id = 1. The Id will be different for each servo and/or interface.

        • Value: 1

        • Bits: 8

        • Mask: 255

      • PWM 1: PWM is the variable that carries the information that has to be applied to the servo. Therefore, it must be included in the message.

        • Variable: PWM 1

        • Compression: Compress - Bits Unsigned

        • Encode: 0 / 1

        • Decode: 3050 / 5070

      • CRC (Custom): A Checksum is needed to complete the communication protocol.

        • Type: Polynomial

        • Bits: 16

        • Endianness: Big endian

        • CRC - Preset: Custom

        • BackFrom: 4

        • BackTo: 0

        • Polynomial: 32773

        • Start Value: 65535

        • Final XOR: 0

        Note

        For more information on checksum, see Checksum (CRC) explanation - Input/Output section of this manual.