MC_Stop

PLCopen motion icon

 Function BlockClosed A function block groups an algorithm and a set of private data. It has inputs and outputs. - Aborts the active move, removes the next move from the queue, performs a controlled stop, and switches the axis to Stopping state.

Inputs

Input

Data Type

Range

Unit

Default

Description

Execute

BOOL

0, 1

N/A

No default

On the rising edgeClosed A rising edge is the transition of a digital signal from low to high. It is also called positive edge, request to stop the axis.

It can be held high to prevent any other moves from being queued.

Axis

AXIS_REF

1, 256

N/A

No default

Name of a declared instance of the AXIS_REF library function.

Deceleration

LREAL

No range

User unit/sec2

No default

Trapezoidal: Deceleration rate.

S-curve: Unused.

See S-curve and Trapezoidal Acceleration / Deceleration for more information.

JerkClosed In physics, jerk is the rate of change of acceleration; more precisely, the derivative of acceleration with respect to time

LREAL

No range

User unit/sec3

No default

Trapezoidal: 0 (zero).

S-curve: Constant jerkClosed In physics, jerk is the rate of change of acceleration; more precisely, the derivative of acceleration with respect to time.

See S-curve and Trapezoidal Acceleration / Deceleration for more information.

Outputs

Output

Data Type

Range

Unit

Description

Done

BOOL

 

 

Indicates both:

  • The axis has reached zero velocity.
  • The Execute input is low.

Busy

BOOL

 

 

High from the time both:

  • The Execute input goes high until the axis reaches zero velocity.
  • The Execute input is low.

Active

BOOL

 

 

High from the time both:

  • The MC_Stop move becomes the active move until the axis reaches zero velocity.
  • The Execute input is low.

Error

BOOL

 

 

Indicates an invalid input was specified.

ErrorID

INT

 

 

Indicates the error if the Error output is set to TRUE.

See PLCopen Function Block ErrorIDs for more information.

Remarks

  • See Function Blocks - General Rules for more information about how inputs and outputs work.
  • An MC_Stop cannot be aborted.
    • This means that, while in Stopping state, no function block can command any motion on the axis.
    • The axis remains in Stopping state until it reaches zero velocity and the Execute input is low.
  • The application program can hold the axis in Stopping state even after it reaches zero velocity by leaving the Execute input high.

MC_Stop

Figure 6-210: MC_Stop

Time Diagram

This example shows the behavior of the combination of a MC_Stop FB with a MC_MoveVelocity FB.

  • A rotating axis is ramped down with FB2 MC_Stop
  • The axis rejects motion commands as long as MC_Stop parameter “Execute” = TRUE

FB1 MC_MoveVelocity reports an error indicating the busy MC_Stop command.

Figure 6-211: Time Diagrams: First and Second FBs

MC_Stop: Timing Diagram

Figure 6-212: Time Diagram

FBD Language Example

Not available.

FFLD Language Example

MC_Stop: LD example

IL Language Example

Not available.

ST Language Example

            (* MC_Stop S
            T example *)

Inst_MC_Stop( StopRequest , Axis1, 100.0, 100.0 ); //Inst_MC_Stop is an instance of MC_Stop function block


StopComplete := Inst_MC_Stop.Done;     //store the Done output into a user defined variable

StopActive := Inst_MC_Stop.Active;     //store the Active output into a user defined variable

StopError := Inst_MC_Stop.Error;       //store the Error output into a user defined variable