When programming for any Aerotech controller, any programs you create and run will operate on a task. This article seeks to demystify tasks for both the engineer and the machine operator.

Overview

Each task can be thought of as a separate program thread. Most Aerotech software will install with four tasks available by default; depending on your controller version, more tasks may be available.

Each task has the following properties:

  • Ability to run one AeroBasic/AeroScript program at a time
  • Task-specific variables (Automation1 2.7.0+, and all A3200 versions) which are only available to programs that run on this task
    • Task variable values persist between programs.
    • Task variables are only cleared when the controller resets.
  • Task-specific settings:
    • Motion modes
      • Task modes include Incremental vs Absolute coordinate programming, velocity blending, time and distance units, etc.
      • Additional task modes such as tool offsets are available in the Automation1 and A3200 software, including advanced CNC features.
    • Velocities and accelerations
      • Task velocities and accelerations apply to coordinated motion such as LINEAR/G1/MoveLinear commands.
    • These values are loaded from the defaults stored in the parameter file or MCD when the controller powers on.
    • These values persist between programs.
    • These values are only restored to the parameter defaults when the controller resets. Best practices are to set all of your task modes and speeds at the top of each program.

Managing Tasks

All of the above information, with the exception of task variables, can be polled using:

  • The Status Utility and the Task Status programming commands (Automation1, A3200); or
  • Via the TASKSTATE and GETMODE programming commands (Ensemble, Soloist).

You can use these commands to retrieve default speeds, the program line a task is running, what task modes are active, and more.

It's also possible to call between tasks and manage & run programs on other tasks.

  • Automation1: The Automation1 software offers advanced task management and program flow options, including calling subroutines on other tasks and transferring program execution to other tasks. Please see the Task and Program Functions documentation for complete information.
  • A3200: The A3200 offers similar functionality to Automation1. Refer to the Program Control Command Category and Program Flow Command Category articles in the A3200 Help files for details.
  • Ensemble and Soloist: You can perform basic task management using the PROGRAM commands to run and handle programs on other tasks. Calling subroutines on other tasks is not possible with these controller architectures. See the Tasks Command Category and the Program Flow Command Category articles in the Help documentation for details.

Example Use Case

Customers may find the following common configuration useful, especially on A3200 and Automation1:

  • Use Task 1 for running motion programs, controlled by the machine operator.
  • Dedicate Task 2 to a "Safety"/"Watcher" program that handles faults and errors from Task 1.
  • Use Task 3 to run any setup functions using the Program Automation features; for example, a program that runs on startup to Enable and Home the axes.
  • Use Task 4 to communicate between the tasks if necessary.

One of these tasks may also be replaced by a library program that runs transformations; for example, when using normalcy to a surface or when programming a hexapod.