Axis Calibration

Axis calibration corrects the position of an axis based on the position of one or two reference axes and the values that you specify in a calibration table. To edit the calibration configuration in Studio, in the Configure workspace, under the Controller category, select Calibration. You can also load calibration without resetting the controller by using the CalibrationLoad() function. For more information, refer to Calibration Functions.

A calibration file includes one or more calibration tables that do the same type of calibration. Calibration files must use the UTF-8 encoding. A calibration table includes the calibration data (correction values) for one or two axes. A calibration table can be a 1D axis calibration table, a 2D axis calibration table, or a galvo 2D axis calibration table.

Axis calibration is additive. Each calibration table supplies a correction value for an axis independently of all other calibration tables, and the final correction value is the sum of all other correction values.

If the position of the reference axes is equal to the reference position of a calibration table entry, the correction value for that table entry is used as the active correction value. But, if the position of the reference axes is between two reference positions in the table, linear interpolation is used to find a correction value between the two correction values in the table. Finally, if the position of the reference axis is not within the values in the table (all positions in the table are either greater or less than the position of the reference axis), the nearest end point of the table is used to calculate the correction value.

IMPORTANT: All calibration tables follow the sign of the encoder. The ReverseMotionDirection Parameter has no effect on calibration values such as sample distances and correction.

1D Axis Calibration

IMPORTANT: Axis indices are usually specified as zero-based integers. But calibration files specify axis indices as one-based integers.

IMPORTANT: All corrections are bidirectional, which means that the correction value applied for a given position of the reference axis is the same regardless of the sign or value of its velocity.

Use 1D axis calibration to correct the position of an axis based on the position of another axis. You can use 1D axis calibration for accuracy correction, orthogonality correction, straightness correction, or ThermoComp. Axes must be homed before they are calibrated by the controller.

Accuracy Correction

Accuracy correction of mechanics compensates for errors within the mechanics, such as with a ball screw. It is the most common type of axis calibration. Accuracy correction precisely adjusts and improves the performance of the mechanics, but does not solve mechanical problems.

Use a precision reference source such as a laser interferometry system to map errors. Then use that data to create a calibration table to compensate for the errors. The axis that is corrected is the reference axis.

Orthogonality Correction

Orthogonality correction compensates for position errors that are caused by X Y axis pairs that are not perpendicular to each other. You only need one calibration table for each X Y pair. Usually, you can determine the errors by using a precision granite square. Measure the error in linear units over the length of the square and interpolate the measurement to calculate the total error over the maximum travel of the table.

You can measure the orthogonality error by aligning one side of a precision square with either the X or the Y axis of travel. Then measure the displacement of this axis as the other axis moves.

To measure orthogonality error, use the procedure that follows:

  1. To align one edge of the precision square with the Y axis of travel, use a dial indicator. Move the Y axis back and forth and rotate the square until the dial indicator position stays constant across the full travel of the square in the Y direction.
  2. Move the dial indicator to measure the surface of the square parallel to the X axis. Zero the position of the dial indicator near one of the ends of the precision square and note the X axis starting position.
  3. Move the X axis so that the dial indicator measures the other end of the precision square. Note the measurement on the dial indicator and the distance the X axis has moved from the starting position.
  4. Calculate the correction distance by dividing the dial indicator measurement by the X axis displacement and then multiplying by the maximum X axis travel.

For Example

Assume that you have an X axis with a total travel of 900 millimeters. The dial indicator shows +5 microns of error over a 200-millimeter move. The equation that follows shows the total error over the full 900 millimeters of travel.

You can create a table for this axis pair that includes two correction points, one for each end of travel of the X axis. The necessary correction is opposite in direction to the error. Thus, the correction for the full travel is -22.5 microns.

The table can have one of the formats that follow. Refer to 1D Axis Calibration File Format for a description of the correction table format.

Table: Home (zero) position is at one end of travel

Absolute Position Correction

0

0

900

-22.5

If the home (zero) position is in the middle of the travel, the table can have one of these two formats:

Table: Home (zero) position in the middle of the travel

Absolute Position Correction

-450

0

+450

-22.5

OR

Absolute Position Correction

-450

11.25

+450

-11.25

The orthogonality correction table that is created is added to a 1D axis calibration file. You must specify the axis_number argument to be the Y axis and the REFERENCEAXIS argument to be the X axis.

Straightness Correction

Straightness correction compensates for the changes of straightness in table travel. The axis that needs to be corrected must be mounted orthogonally to another table.

The errors are mapped with a precision reference source, such as a laser interferometry system. A calibration table is created and entered into the 1D axis calibration file.

For Example

You have an X Y axis pair. To correct the straightness of travel of the X axis:

  1. Specify the axis_number argument to be the Y axis.
  2. Specify the reference axis as the X axis (the axis you want to correct).

1D Axis Calibration File Format

1D axis calibration files are text files with *.cal extensions. Each 1D axis calibration file includes one or more 1D axis calibration tables. You can have a maximum of 100 calibration tables in the calibration file. You can have a maximum of eight calibration tables for each corrected axis.

A calibration table is delimited by the :START and :END tokens. A calibration table can have more than one :START line. If a calibration table has more than one :START line, only the first :START token should be followed by the axis index of the corrected axis. The axis index is followed by keywords that can take arguments. The SAMPLEDIST keyword is required. The other keywords are optional. The keywords are described in the table 1D Axis Calibration File Format Settings.

A single-line comment must start with a semicolon (;). All characters between the start of a comment and the next new line (or the end-of-file if the comment starts on the last line in the file) are ignored during calibration file processing. You can include single-line comments at the end of a line that contains calibration data.

The position of the reference axis of the nth table correction entry is calculated as the sample distance * n. The first table entry is for n = 0. If you enter a nonzero correction value for the 0 position, all of the correction values are offset so that the correction value at the 0 position of the reference axis is zero. The OFFSET keyword can be specified to shift the starting position of the reference axis of the calibration file. The table size is limited only by available memory.

Table: 1D Axis Calibration File Format Settings

Setting Description

axis_index

The index (1-32) of the axis to which the correction values in the calibration table are applied.

[REFERENCEAXIS=reference_axis_index]

Optional. The axis index (1-32) of the axis that causes the correction. Applies the correction values in the calibration table to the corrected axis (axis_index) based on the position of the reference axis.

If you do not specify this keyword, the controller uses the axis specified in axis_index as the reference axis.

[POSUNIT=unit]

Optional. Specifies the position units of the SAMPLEDIST and OFFSET keywords. Valid unit-based keywords are PRIMARY, SECONDARY, and COUNTS.

You can use the forward slash character (/) to include an optional divisor that lets you specify position units as microns, nanometers, or other units. If you use an optional divisor, make sure that you do not include white space before or after the forward slash character.

For Example

POSUNIT=PRIMARY/1000

If the primary units that you use are millimeters, then the units of the values in the calibration table are microns.

If you do not specify this POSUNIT, the controller uses encoder counts for the position units of the SAMPLEDIST and OFFSET keywords.

[CORUNIT=unit]

Optional. Specifies the correction units of the correction values in your calibration table, which show as CorrectionValue in 1D Axis Calibration File Format Example. Valid unit-based keywords are PRIMARY, SECONDARY, and COUNTS.

You can use the forward slash character (/) to include an optional divisor that lets you specify position units as microns, nanometers, or other units. If you use an optional divisor, make sure that you do not include white space before or after the forward slash character.

For Example

CORUNIT=PRIMARY/1000

If the primary units that you use are millimeters, then the units of the values in the calibration table are microns.

If you do not specify CORUNIT, the controller uses the units that you specify for POSUNIT = unit as the correction units. If POSUNIT = unit is not specified, the controller uses CORUNIT = COUNTS as the correction units.

SAMPLEDIST=dist

Specifies the fixed sample distance between correction values. The calibration table is assumed to start at the home position. This value is typically negative when the Home Position is CW (+).

The units of this keyword are specified by the POSUNIT keyword.

[OFFSET=offset]

Optional. Changes the starting location of the calibration table. If you do not specify this keyword, or if the offset argument is set to 0, the first entry in the table corresponds to the home position of the axis.

The offset value can be positive or negative and always follows the sign of the encoder. The ReverseMotionDirection Parameter parameter does not have an effect on the offset value.

The units of this keyword are specified by the POSUNIT keyword.

[EXPANDCOEFF=exponent]

Optional. Specifies the expansion coefficient of the material on which the encoder scale is mounted. Units: 1/°C.

[MATERIALTEMP=temperature]

Optional. Specifies the temperature at which the correction values were taken. Units: 1/°C.

[NEGPOS]

Optional. Changes the sign of all of the position values.

[NEGCOR]

Optional. Changes the sign of all of the correction values.

[ROLLOVER=rollover]

Optional. Specifies the distance, in counts, at which calibration rollover occurs. If you do not specify this keyword, calibration rollover will not occur.

[HOMEDIRECTION=direction]

Optional. Specifies the home direction that is used at the time the calibration table is created. Because the axis home is determined by the encoder direction, changing the axis home direction can change the home position. Refer to HomeSetup Parameter for more information. HOMEDIRECTION enables the HOMEOFFSET and FULLTRAVEL keywords. If HOMEDIRECTION is not specified, these values are ignored. If you specify HOMEDIRECTION, you should also specify HOMEOFFSET, otherwise the controller will assume the HOMEOFFSET keyword is zero. Possible values are CW and CCW (for example, HOMEDIRECTION=CW).

If you change the HomeSetup Parameter after the calibration table is created, the controller automatically adjusts the calibration table only if the HOMEDIRECTION keyword is specified.

[HOMEOFFSET=homeoffset]

Optional. Specifies the value of the HomeOffset Parameter that was active when you collected the data that you used to generate the calibration file. Because you specify this value in the calibration file, the controller can dynamically shift the calibration table if you change the value of the HomeOffset parameter at a different time.

Changes that you make to the HomeOffset parameter do not have an effect on calibration until you reset the controller.

[ABSOLUTEFEEDBACKOFFSET=absolutefeedbackoffset]

Optional. Specifies the value of the PrimaryAbsoluteFeedbackOffset Parameter that was active when you collected the data that you used to generate the calibration file.

Because you specify this value in the calibration file, the controller can dynamically shift the calibration table if you change the value of the PrimaryAbsoluteFeedbackOffset parameter at a different time. Changes that you make to the PrimaryAbsoluteFeedbackOffset parameter do not have an effect on calibration until you reset the controller.

[FULLTRAVEL=fulltravel]

Optional. Specifies the full travel of the stage. If the stage has only one marker signal, you do not have to specify this keyword because the home position is the same on every home, regardless of home direction. If the stage has more than one marker, use this keyword to specify the new home position in relation to the old home position when the home direction is changed, assuming that the value of the HomeOffset Parameter is not changed.

You can use this keyword with the HOMEOFFSET keyword to create a dynamic shift in the axis calibration table. This shift is required on rotary translational stages and rotary tables with gearboxes.

[SERIALNUMBER="serialnumber"]

Optional. Specifies the serial number of the Aerotech system on which the calibration file was created. This keyword is for reference only. Do not change the serial number in your calibration file.

2D Axis Calibration

IMPORTANT: Typically, axis indices are specified as zero-based integers. But calibration files specify axis indices as one-based integers.

Use 2D axis calibration to correct two or three axes based on the position of two other axes. Axes must be homed before they are calibrated by the controller.

2D Axis Calibration File Format

2D axis calibration files are text files with *.cal extensions. Each 2D axis calibration file contains one or more 2D axis calibration tables. You can specify a maximum of 10 calibration tables in the calibration file.

A calibration table is delimited by the :START2D and :END tokens. A calibration table can have more than one line with :START2D. If a calibration table has more than one :START2D line, only the first :START2D token should be followed by the required arguments in this order: RowAxis, ColumnAxis, OutputAxis1, OutputAxisB2, SampDistRow, SampDistCol, and NumCols.

A single-line comment must start with a semicolon (;). All characters between the start of a comment and the next new line (or the end-of-file if the comment starts on the last line in the file) are ignored during calibration file processing. You can include single-line comments at the end of a line that contains calibration data.

The first point in the calibration table corresponds to the home position (0,0) of the row and column input axes. You can shift the table with the OFFSETROW and OFFSETCOL keywords. The table size is limited only by available memory.

Table: 2D Axis Calibration File Format Settings

Setting Description

RowAxis

The index (1-32) of the row input axis. The axes are indexed vertically through the table.

ColumnAxis

The index (1-32) of the row input axis. The axes are indexed horizontally through the table.

OutputAxis1

The index (1-32) of the first output axis.

OutputAxis2

The index (1-32) of the second output axis.

SampDistRow

Distance between rows. This distance is added to every row after the first row, which is RowAxis Position = 0.

SampDistCol

Distance between columns. This distance is added to every column after the first column, which is ColumnnAxis Position = 0.

NumCols

Number of point pairs or triplets per row in the calibration table. One column is made up of two or three OutputAxis values.

CorrectionValue

Enter correction values in pairs or triplets. Refer to OUTAXIS3 for more information. The values are used to directly compensate the specified axis positions. Use the CORUNIT keyword to specify the units of the correction values.

[OUTAXIS3=outaxis3]

Optional. The index (1-32) of the third output axis. If you specify this keyword, there are three correction values per point. If you do not specify this keyword, there are only two correction values per point.

[POSUNIT=posunit]

Optional. Specifies the position units of the SampDistRow, SampDistCol, OFFSETROW, and OFFSETCOL keywords. Valid unit-based keywords are PRIMARY, SECONDARY, and COUNTS.

You can use the forward slash character (/) to include an optional divisor that lets you specify position units as microns, nanometers, or other units. If you use an optional divisor, make sure that you do not include white space before or after the forward slash character.

For Example

POSUNIT=PRIMARY/1000

If the primary units that you use are millimeters, then the units of the values in the calibration table are microns.

If you do not specify this keyword, the controller uses encoder counts for the position units of the SampleDistRow, SampleDistCol, offsetrow, and offsetcol arguments.

[CORUNIT=corunit]

Optional. Specifies the correction units of the correction values in your calibration table, which show as CorrectionValue in 2D Axis Calibration File Format Example. Valid unit-based keywords are PRIMARY, SECONDARY, and COUNTS.

You can use the forward slash character (/) to include an optional divisor that lets you specify correction units as microns, nanometers, or other units. If you use an optional divisor, make sure that you do not include white space before or after the forward slash character.

For Example

CORUNIT=PRIMARY/1000

If the primary units that you use are millimeters, then the units of the values in the calibration table are microns.

If you do not specify this keyword, the controller uses encoder counts for the correction units.

[OFFSETROW=offsetrow]

Optional. Changes the starting location of the row axis of the 2D calibration table. Use for stages that have the marker located in the middle of travel. Calibration is done from one end to the other in one pass. The offset is the location of the home position in relation to the position of the first entry in the calibration table. If the OFFSETROW value is within the minimum and maximum row position values, linear interpolation is used when downloading the table to bias the table so that the correction value is 0 for position 0.

If you do not specify this keyword, the first entry in the calibration table corresponds to a position of 0 for the axis you specified in the RowAxis argument.

The units of this keyword are specified by the POSUNIT keyword.

[OFFSETCOL=offsetcol]

Optional. Shifts the zero location of the column axis of the 2D calibration table and is used for stages with the marker located in the middle of travel. Calibration is done from one end to the other. The offset represents the location of the home position in relation to the position of the first entry in the calibration table. Use POSUNIT to specify the units of this keyword. If the OFFSETCOL value is within the minimum and maximum column position values, linear interpolation is used when downloading the table to bias the table so that the correction value is 0 for position 0.

If you do not specify this keyword, the first entry in the calibration table corresponds to a position of 0 for the axis you specified in the ColumnAxis argument.

[ABSOLUTEFEEDBACKOFFSETROW=absolutefeedbackoffsetrow]

Optional. Specifies the value of the PrimaryAbsoluteFeedbackOffset Parameter that was active on the axis that you specified for the RowAxis argument of the calibration table when you collected the data that you used to generate the calibration file. Because you specify this value in the calibration file, the controller can dynamically shift the calibration table if you change the value of the PrimaryAbsoluteFeedbackOffset parameter at a different time. Changes that you make to the PrimaryAbsoluteFeedbackOffset parameter do not have an effect on calibration until you reset the controller.

[ABSOLUTEFEEDBACKOFFSETCOL=absolutefeedbackoffsetcol]

Optional. Specifies the value of the PrimaryAbsoluteFeedbackOffset Parameter that was active on the axis that you specified for the ColumnAxis argument.

Because you specify this value in the calibration file, the controller can dynamically shift the calibration table if you change the value of the PrimaryAbsoluteFeedbackOffset parameter at a different time. Changes that you make to the PrimaryAbsoluteFeedbackOffset parameter do not have an effect on calibration until you reset the controller.

[NEGCOR]

Optional. Changes the sign of all of the correction values.

[ROLLOVERROW=rolloverrow]

Optional. Specifies the distance, in counts, at which calibration rollover occurs for the row axis. If you do not specify this keyword, calibration rollover will not occur for the row axis.

[ROLLOVERCOL=rollovercol]

Optional. Specifies the distance, in counts, at which calibration rollover occurs for the column axis. If you do not specify this keyword, calibration rollover will not occur for the column axis.

[SERIALNUMBER="serialnumber"]

Optional. Specifies the serial number of the Aerotech system on which the calibration file was created. This keyword is for reference only. Do not change the serial number in your calibration file.

Galvo 2D Axis Calibration

IMPORTANT: Galvo, GI4, and GL4 functionality are available only if you are using the PC-based controller.

Use galvo 2D axis calibration to correct positions of axes of a galvo scanner that is connected to a galvo drive. Axes must be homed before they are calibrated by the controller. The format of a galvo 2D axis calibration table is almost the same as the format of a 2D axis calibration table, with the differences and restrictions that follow:

  • A galvo 2D axis calibration table starts with a :GALVO2D token. A 2D axis calibration table starts with a :START2D token.
  • The ColumnAxis and OutputAxis1 arguments must be the first axis of the galvo drive.
  • The RowAxis and OutputAxis2 arguments must be the second axis of the galvo drive.
  • The SampDistRow and SampDistCol arguments must be positive.
  • You cannot use the arguments that follow:
    • OFFSETROW
    • OFFSETCOL
    • ABSOLUTEFEEDBACKOFFSETROW
    • ABSOLUTEFEEDBACKOFFSETCOL
    • ROLLOVERROW
    • ROLLOVERCOL
    • SERIALNUMBER
  • The table must have an odd number of rows and columns. The center of the table corresponds to the home position of the galvo scanner.
  • The table can have a maximum number of 138,000 points.

When you use a galvo 2D axis calibration table with the GI4, the restrictions that follow also apply:

  • The table must have an exact number of 65 rows and 65 columns.
  • The SampDistRow and SampDistCol arguments must be equal to 1/64 of the range of the scanner protocol.
  • For Example

    A 16-bit scanner protocol has a range of  216 = 65536 Counts. Thus, the SampDistRow and SampDistCol arguments must equal 1024 counts. Refer to the equation that follows.

Galvo 2D Axis Calibration File Format

IMPORTANT: Typically, axis indices are specified as zero-based integers. But calibration files specify axis indices as one-based integers.

Galvo 2D axis calibration files are text files with *.cal extensions. Each galvo 2D axis calibration file contains one or more galvo 2D axis calibration tables. You can specify up to one calibration table for each galvo scanner in the calibration file.

A single-line comment must start with a semicolon (;). All characters between the start of a comment and the next new line (or the end-of-file if the comment starts on the last line in the file) are ignored during calibration file processing. You can include single-line comments at the end of a line that contains calibration data.

Table: Galvo 2D Axis Calibration File Format Settings

Setting Description

RowAxis

The index (1-32) of the row input axis. The axes are indexed vertically through the table.

ColumnAxis

The index (1-32) of the row input axis. The axes are indexed horizontally through the table.

OutputAxis1

The index (1-32) of the first output axis.

OutputAxis2

The index (1-32) of the second output axis.

SampDistRow

Distance between rows. This distance is added to every row after the first row, which is RowAxis Position = 0.

SampDistCol

Distance between columns. This distance is added to every column after the first column, which is ColumnnAxis Position = 0.

NumCols

Number of point pairs or triplets per row in the calibration table. One column is made up of two or three OutputAxis values.

CorrectionValue

Enter correction values in pairs or triplets. Refer to OUTAXIS3 for more information. The values are used to directly compensate the specified axis positions. Use the CORUNIT keyword to specify the units of the correction values.

[OUTAXIS3=outaxis3]

Optional. The index (1-32) of the third output axis. If you specify this keyword, there are three correction values per point. If you do not specify this keyword, there are only two correction values per point.

[POSUNIT=posunit]

Optional. Specifies the position units of the SampDistRow, SampDistCol, OFFSETROW, and OFFSETCOL keywords. Valid unit-based keywords are PRIMARY, SECONDARY, and COUNTS.

You can use the forward slash character (/) to include an optional divisor that lets you specify position units as microns, nanometers, or other units. If you use an optional divisor, make sure that you do not include white space before or after the forward slash character.

For Example

POSUNIT=PRIMARY/1000

If the primary units that you use are millimeters, then the units of the values in the calibration table are microns.

If you do not specify this keyword, the controller uses encoder counts for the position units of the SampleDistRow, SampleDistCol, offsetrow, and offsetcol arguments.

[CORUNIT=corunit]

Optional. Specifies the correction units of the correction values in your calibration table, which show as CorrectionValue in Galvo 2D Axis Calibration File Format Example. Valid unit-based keywords are PRIMARY, SECONDARY, and COUNTS.

You can use the forward slash character (/) to include an optional divisor that lets you specify correction units as microns, nanometers, or other units. If you use an optional divisor, make sure that you do not include white space before or after the forward slash character.

For Example

CORUNIT=PRIMARY/1000

If the primary units that you use are millimeters, then the units of the values in the calibration table are microns.

If you do not specify this keyword, the controller uses encoder counts for the correction units.

[NEGCOR]

Optional. Changes the sign of all of the correction values.