Machine-Centric Robotics – Motion ST Programming
Introduction
Machine-Centric Robotics (MCR) with Motion ST Programming provides a structured and flexible approach to robot motion control within B&R Automation Studio. This article explains the differences between ST application and robot programs, demonstrates a minimalistic demo project, introduces robotic path planning concepts, and provides detailed examples of ST commands and diagnostic tools.
Agenda
- ST Application Program vs. ST Robot Program
- Demo Project
- Robotic Path Planning Basics
- Examples and Diagnosis
1. ST Application Program vs. ST Robot Program
ST Application Program
- Used to operate the robot.
- Inserted via toolbox into Automation Studio logical view.
- Assigned to a CPU task class → runs in cyclic context.
- Structure:
- Type file: variable definitions, function blocks, parameter types, user-defined structures.
- Init program: executed at PLC startup for initialization.
- Cyclic part: typically contains a state machine (e.g., powering, homing, waiting, moving).
- Stored in Logical View and compiled into binary with the Automation Studio project.
ST Robot Program
- Contains motion instructions the robot shall perform.
- Inserted via toolbox; executed by Interpreter module of Motion Chain.
- Can include variable declarations (constants, PLC variables).
- Main part executed by interpreter.
- Stored on a file device (e.g.,
CNC_PrgDir) and can be updated during runtime. - Executed via:
-
Function blocks (e.g.,
MC_BR_MoveProgram) -
mapp Cockpit.
-
Comparison Table
| ST Application Program | ST Robot Program |
|---|---|
| Contains the application logic e.g., used to operate a robot | Contains the (motion) instructions the robot shall perform |
| Cyclic execution | Function block or mapp Cockpit |
| Init/cyclic/exit parts | Interpreter-based |
| Logical View storage | File device storage(CNC_PrgDir) |
| Compiled with AS project | Runtime updates possible |
2. Demo Project
A minimalistic Automation Studio project was created for demonstration:
- Hardware: APC3100 PLC with Powerlink interface.
- Robot: Codian D4 1100 inserted via MCR template.
- Required ACOPOS hardware.
- Auto-generated Scene Viewer visualization.
- Two file devices:
VisualizationCNC_PrgDirfor motion programs.
Scene Viewer
- Standalone Windows application shipped with Automation Studio.
- Connects via OPC UA to ArSim or hardware.
- Visualizes robot motion.
- Added manually:
- Path Tracker: shows TCP trajectory.
- Positioner: displays TCP position (and optionally orientation).
Frames
- Object hierarchy and frame hierarchy define coordinate systems.
- For this training: robot programmed in base frame coordinates.
Executing ST Robot Program
- Specialized function blocks:
MC_BR_MoveProgramMC_BR_GroupPowerMC_BR_GroupHome
- Program name is referenced from the file device.
3. Robotic Path Planning
Motion Chain Basics
The motion chain consists of:
-
Interpreter: Reads ST program, generates motion commands.
-
Geometric Path Planning: Calculates TCP path.
-
Dynamic Path Planning: Applies speed profiles and axis limits.
-
Set Value Sampler: Generates cyclic setpoints for axes.
Execution Context:
-
Set Value Sampler → cyclic task.
-
Other modules → background tasks.
Buffer Time
- Buffer compensates for CPU load variations.
- Robot starts moving when buffer reaches minimum fill level.
- Dynamic planning maintains lookahead.
- If CPU load is high, buffer may drop → possible motion slowdown.
4. ST Commands – Overview and Examples
Available ST commands are documented in Automation Studio Help under:
Motion Control → mapp Motion → mapp Robotics/CNC → Programming → G-code and ST overview.
Example 1: Absolute Positioning and Circular Interpolation

Example 2: Relative Positioning
Example 3: Joint Space Motion
Example 4: Feedrate and Rapid Motion
Example 5: Rounding Edges
Timing and Synchronization Commands
- Wait time
- wait end move
-
wait ALAP
-
wait until
- wait until flash
- do path synch
5. Diagnosis Tools
- Scene Viewer: Visualize robot motion.
- Logger: Check for errors or unexpected behavior.
- Block Monitor: Shows which program part is currently sampled.
- Interpreter Monitor: Indicates which part was processed.
- Override: Execute program slowly for debugging.
Summary
Motion ST Programming provides a structured approach to robot control in Automation Studio:
- ST Application Programs handle robot operation logic.
- ST Robot Programs define motion sequences and can be updated at runtime.
- Robotic path planning uses a motion chain with buffering for smooth execution.
- A wide range of ST commands enables precise control of motion and timing.
- Diagnostic tools simplify troubleshooting and commissioning.
























