MC_CamResumePos

PLCopen motion icon

 Function Block - Returns the slave axis position for resuming an MC_CamIn move.

Inputs

Input

Data Type

Range

Unit

Default

Description

Enable

BOOL

FALSE, TRUE

N/A

No default

Enables execution.

Master

AXIS_REF

AXIS_NUM - 1 to 256

N/A

No default

Master axis.

This must be the same as the Master Axis specified for the most recently executed MC_CamIn function block.

Slave

AXIS_REF

AXIS_NUM - 1 to 256

N/A

No default

Slave axis.

This must be the same as the Slave Axis specified for the most recently executed MC_CamIn function block.

CamTableID

INT

0 to 255

N/A

No default

Profile ID number.

  • This value is generated by MC_CamTblSelect.
  • This must be the same as the CamTableID specified for the most recently executed MC_CamIn function block.

Outputs

Output

Data Type

Range

Unit

Description

Done

BOOL

FALSE, TRUE

N/A

TRUE = the function block has successfully calculated the slave position.

The slave position is available at the SlavePos output.

Error

BOOL

FALSE, TRUE

N/A

TRUE = an invalid input was specified or an error occurred in the calculations.

The value at the SlavePos output is undefined.

ErrorID

INT

No range

N/A

Indicates the error if Error output is TRUE.

See PLCopen Function Block ErrorIDs.

SlavePos

LREAL

No range

User units

If the Done output is TRUE, this output returns the:

  • position for the slave axis given the profile.
  • current master axis position.
  • previously programmed master and slave offsets and scaling.

Remarks


  • This function block starts a motion-related action and stores data for calculations and error checking.
    If using a dual-core controller, see Program a Multi-Core Controller.
  • Returns the slave axis position for the most recently executed MC_CamIn profile, based on the current position of the master axis.
    • This slave axis position can be used to command the slave axis to return to the proper location prior to resuming a MC_CamIn function.
    • When calculating the slave axis position, MC_CamResumePos utilizes the master offset, slave offset, master scaling, and slave scaling of the most recently executed MC_CamIn function block for the slave axis.
  • The typical application of MC_CamResumePos is to aid in returning a slave axis back to its profile position after an event (e.g., E-stop) caused the slave axis to go off path.
  • See Resume Camming After an E-Stop for instructions.

Figure 1: MC_CamResumePos

FBD Language Example

FFLD Language Example

IL Language Example

Not available.

ST Language Example

Inst_MC_CamResumePos( TRUE, Axis1, Axis2, Profile1CamTableID);

See Also