-

Using Position Compensation Tables

Overview

Some applications require ultra precision. For each machine assembled, a separate metrology device records the real positions at many locations while referencing the motor's encoder position. The machine builder can store the resulting position compensation data files on the controller for each machine.

File Format

Use a simple csv file that relates commanded position and compensation values. All values are in user units.

Example Position Compensation File

0.00 0.001
0.25 0.001
0.50 0.001
1.00 0.002
5.00 0.002
7.00 0.001
8.00 0.000
9.00 -0.001
9.25 -0.002
10.00 0.001


The format of the CSV file is the same as a cam table file. Headers are optional: if omitted the file will be interpreted as above. The data in the file must be strictly monotonic (increasing or decreasing). Both the uncompensated 'master' position (column 1) as well as the compensated result (column 1 + column 2) must be monotonic. Data which does not follow this rule will cause error 4900 (invalid compensation file format).

File size limitations

Files must fit into the memory available on the flash file system; thus in practice they should be less than 1 MB total to allow for programs to be stored on the controller.

General Behavior

The controller will do a linear interpolation between the points; compensation values are added to the command position at each motion network update interval. The compensation file path can be specified in a field in axis.xml. If the file is not specified in axis.xml, it will be read from a default location. The file name will be "Axis1PosComp.CSV" where "Axis1" is the name of the [axis] and the default path is the permanent memory file location defined inMemory area available for user files in ic92xx .

The post-compensation command position value is available in parameter 1020, Processed Command Position. Input positions outside the domain of the table data will use the offset specified at the upper/lower limit of the table domain. For example, in the above table,

• An input position of 17.0 would use an offset of 0.001 (for a final output position of 17.001)

• An input position of -4.00 would use an offset of 0.00 (for a final output position of -4.00) The file is not read until the feature is enabled via MC_WriteBoolParameter. Each time the feature is re-enabled, the file is re-parsed. (This is normally only required once per power up of the controller.) If this feature is used with a rotary mode axis (continuous wrap), the table data domain must match the rotary wrap range exactly, and the start and end offset of the table data must be identical, to prevent discontinuity. Failure to do this will cause error 4902. Note that this requirement precludes input data outside the domain of the table data and the preceding section cannot apply.

Interaction with function blocks

Compensation is initially off by default at controller startup. The user can enable and disable compensation with MC_Read/WriteBoolParameter. Compensation can only be enabled/disabled while servo off. The parameter file is read from disk and parsed when the enable parameter is set to true. If an error occurs, it will be reported in the output of MC_WriteBoolParameter and the parameter setting will not take effect. Each time the parameter is changed from false to true, the file is reloaded.

Interaction with feedback position

Feedback position is not run through reverse compensation. Thus, when compensation is enabled the command position (1010) will not be equal to feedback position (1006). Use parameter 1020 : this is the compensated command position for comparison purposes instead.

Parameter numbers

1308 : Enable position compensation (bool)

Error codes

4409: Parameter write in progress

4899: Axis position compensation file not found

4900: Invalid axis position compensation file format

4901: Cannot enable/disable axis position compensation while servo on

4902: Invalid compensation table wrap range

 


This help information is valid for iCube Engineer Online Help 2025.6

Copyright © 2025 YASKAWA EUROPE GmbH and © 2025 YASKAWA America, Inc.