omron — Axis Definitions

PMAC Product Guide MOTION PROGRAMS PMAC can hold up to 256 motion programs at one time. Any coordinate system can run any of these programs at any time, even if another coordinate system is already executing the same program. PMAC can run as many motion programs simultaneously as there are coordinate systems defined on the card (up to eight). A motion program can call any other motion program as a subprogram, with or without arguments. PMAC’s motion program language is perhaps best described as a cross between a high-level computer language like BASIC or Pascal, and G-Code (RS-274) machine tool language.

In fact, it can accept straight G-Code programs directly (provided it has been set up properly). It has the calculational and logical constructs of a computer language and move specification constructs similar to machine tool languages. Numerical values in the program can be specified as constants or expressions. Motion or PLC programs are entered in any text file to be downloaded afterward to PMAC. PEWIN provides a built-in text editor for this purpose but any other text editor can be used conveniently. Once the code has been written, it can be downloaded to PMAC using PEWIN. All PMAC commands can be issued from any terminal window communicating with PMAC.

Online commands allow, for example, to jog motors, change variables, report variables values, start and stop programs, query for status information and even write short programs and PLCs. In fact, the downloading process is just a sequence of valid PMAC commands sent line by line from a particular text file. Coordinate Systems A coordinate system in PMAC is a grouping of one or more motors for the purpose of synchronizing movements. A coordinate system (even with only one motor) can run a motion program; a motor cannot. PMAC can have up to eight coordinate systems, addressed as &1 to &8, in a very flexible fashion (e.g.

eight coordinate systems of one motor each, one coordinate system of eight motors, four coordinate systems of two motors each, etc.). In general, to move certain motors in a coordinated fashion, put them in the same coordinate system. To move motors independently of each other, put them in separate coordinate systems. Different coordinate systems can run separate programs at different times (including overlapping times) or even run the same program at different (or overlapping) times. A coordinate system must be established first by assigning axes to motors in Axis Definition Statements.

A coordinate system must have at least one motor assigned to an axis within that system or it cannot run a motion program, even non-motion parts of it. When a program is written for a coordinate system and if simultaneous motions are wanted of multiple motors, their move commands are put on the same line and the moves will be coordinated. Axis Definitions An axis is an element of a coordinate system. It is similar to a motor, but not the same thing. An axis is referred to by letter. There can be up to eight axes in a coordinate system, selected from X, Y, Z, A, B, C, U, V, and W.

An axis is defined by assigning it to a motor with a scaling factor and an offset (X, Y, and Z may be defined as linear combinations of three motors, as may U, V, and W). The variables associated with an axis are scaled floating-point values. In the vast majority of cases, there will be a one-to-one correspondence between motors and axes. That is, a single motor is assigned to a single axis in a coordinate system. However, even when this is the case, the matching motor and axis are not completely synonymous. The axis is scaled into engineering units and deals only with commanded positions.

Except for the PMATCH function, calculations go only from axis commanded positions to motor commanded positions, not the other way around. Motion Programs 69