MC_TouchProbe

This FB serves to detect the position of an axis at the time of a trigger event (" touch probe ") with high precision.

  • For the trigger event, the following touch probe sources are supported:
    • Touch probe of the drive (digital input or zero pulse)
    • External touch probe source (e.g. fast I/O)
    • Simple digital input
  • Different edge events can be configured. The output of the FB distinguishes between positive and negative edge.
  • The detected positions are output in the unit of the connected axis.
    Additionally to the position, the timestamp of the touch probe event is output
  • The FB differs between the following modes:
    • Single measurement
    • Permanent measurement
  • The measurement is configured via defining the MC_TRIGGER_REF structure.
  • An active measurement can be aborted via the FB MC_AbortTrigger .

 

 

 

MC_TouchProbe

 

 

 

AXIS_REF

-

 

Axis

TriggerInput

 

-

MC_TRIGGER_REF

MC_TRIGGER_REF

-

 

TriggerInput

Done

 

-

BOOL

BOOL

-

 

Execute

Busy

 

-

BOOL

BOOL

-

 

WindowOnly

CommandAborted

 

-

BOOL

LREAL

-

 

FirstPosition

Error

 

-

BOOL

LREAL

-

 

LastPosition

ErrorID

 

-

L_IE1P_Error

       

ActivationLevel

 

-

BOOL

       

ValueStored_PosEdge

 

-

BOOL

       

RecPosition_PosEdge

 

-

LREAL

       

ValueStored_NegEdge

 

-

BOOL

       

RecPosition_NegEdge

 

-

LREAL

       

NewValueStored_PosEdge

 

-

BOOL

       

NewValueStored_NegEdge

 

-

BOOL

       

RecData

 

-

L_MC1P_TpReceiveData

 

 

 

 

 

 

 

 

Inputs/outputs

Name

Data type

Information/possible settings

TriggerInput

MC_TRIGGER_REF

Transfer of the touch probe configuration

Touch probe configuration

Inputs

Name

Data type

Information/possible settings

Axis

AXIS_REF

Transfer of the axis data structure

Motion axes (AXIS_REF)

Execute

BOOL

FALSE รค TRUE

Start touch probe detection.

  • All outputs of the FB are reset to the initial values.

WindowOnly

BOOL

Activate Window evaluation

FALSE

Acceptance window for touch probe detection is not effective.

TRUE

The acceptance window defined via FirstPosition and LastPosition is effective. If the detected touch probe position is outside the acceptance window, this event is ignored.

FirstPosition

LREAL

Starting position for acceptance window in [unit]

  • Lower limit with regard to a positive direction of rotation.

LastPosition

LREAL

End position for acceptance window in [unit]

  • Upper limit with regard to a positive direction of rotation.
Outputs

Name

Data type

Value/meaning

Done

BOOL

TRUE

Touch probe event has been detected and the respective axis position has been recorded successfully.

Busy

BOOL

TRUE

Processing is running.

CommandAborted

BOOL

TRUE

The command has been aborted by another FB (e.g. MC_AbortTrigger ).

Error

BOOL

TRUE

An error has occurred. For details see ErrorID .

ErrorID

If Error = TRUE: Error number for the error that has occurred.

ActivationLevel

BOOL

Level of the TP input at the time of TP function activation in the drive

  • The application can detect the nature of the first active edge by evaluating the ActivationLevel when a "positive or negative edge" is assigned.

ValueStored_PosEdge

BOOL

TRUE

Measured value saved (after triggering on positive edge).
.

RecPosition_PosEdge

LREAL

Stored measured value (after triggering on positive edge) in [unit].

ValueStored_NegEdge

BOOL

TRUE

Measured value stored (after triggering to negative edge).

RecPosition_NegEdge

LREAL

Stored measured value (after triggering to negative edge) in [unit]

NewValueStored_PosEdge

BOOL

TRUE

New positive measured value stored

  • If a new measured value is detected, this signal is set for the duration of one call cycle at the FB.

NewValueStored_NegEdge

BOOL

TRUE

New negative measured value stored

  • If a new measured value is detected, this signal is set for the duration of one call cycle at the FB.

RecData

L_MC1P_TpReceiveData

Information on a touch probe event.