Continuous Resettable Axes

Resettable axes can also rotate indefinitely to either direction. However, unlike cyclic axes, they use a limited non-cyclic range of angles. For instance, such an axis may use the range of -3000 to +3000 degrees.

The angle limit is a soft limit - the axis can rotate on and on in the same direction. However, when that software limit is reached, the axis must be reset to a smaller angle, within a much smaller range.

Resetting the axis angle has no effect on the axis position or real angle - it is a software reset only. For instance, the angle 2999 may be reset to 119 (subtracting a number of full 360 cycles) before the machine can continue its rotation to angle 3001 (which becomes 121 after the reset).

In order to define an axis as resettable, the following variable must be set to TRUE_: M5_A_RESETABLE for the alpha axis, M5_B_RESETABLE for the beta axis.

These variables are ignored if the axis is defined as cyclic (see above).

The axis reset range must also be defined. The default range is -360 to +360 degrees, but other ranges are acceptable (For example, 0 to 360). The reset range is defined with the following variables:

  • M5_A_RESET_FROM and M5_A_RESET_TO for the alpha axis

  • M5_B_RESET_FROM and M5_B_RESET_TO for the beta axis

Whenever GPP2 reaches one of the axis soft limits, it invokes a RESET AXIS block with one of the qualifiers alpha: or beta:, indicating the axis that needs to be reset. The angle to be rest is found in A_LASTPOS or B_LASTPOS respectively.

The EX2 program is expected to do the following:

  • Reset the axis on the machine by outputting the appropriate machine command.

  • Modify A_LASTPOS or B_LASTPOS to the new reset value, based on the specific machine behavior. The new value must match the machine rest value!

GPP2 checks the value of A_LASTPOS (or B_LASTPOS) after the RESET AXIS block is executed. The new value must meet the following criteria: (a) it must be within the axis reset range; (b) it must be equivalent to the previous value (the same direction, since no real rotation takes place). If the criteria are not met, a runtime error is generated.

RESET AXIS by Request

Usually, an axis reset block (RESET AXIS) is invoked by GPP2 when a resettable axis reaches the lower or upper soft limit. However, it is also possible to request an axis reset from the EX2 program. This may be useful if the PP developer prefers to reset the axis at the beginning of each procedure or as part of a connection process.

In order to request an axis reset, the EX2 program has to set one of two request flags to TRUE_. The A_RESET_AXIS system flag is used for the A (primary) axis, and the B_RESET_AXIS system flag is used for the B (secondary) axis. The requests are only relevant to resettable axes.

When GPP2 identifies that an axis reset block has been raised, it invokes the RESET AXIS block with the appropriate quantifier (depending on the axis requested). The EX2 program is expected to do the reset by setting the A_LASTPOS or B_LASTPOS variables to the new reset value.

GPP2 only checks the request flags at two points:

  • After execution of the START PROC block. This block is invoked at the beginning of each procedure, just before the first connection motion. This is the simple way to request an axis reset.

  • After execution of the BEGINNING OF CONNECT block. The process is more complex here. If a request flag is raised, GPP2 aborts the current connection, invokes the RESET AXIS block and then restarts a whole new connection process (starting with a re-invocation of the BEGINNING OF CONNECT block). The EX2 program logic should be aware of this process and only raise the request flag in certain conditions (For example, the angle is above or below a certain limit).

Some functionality may be dependent on the product package. Contact your Reseller if you require a license.