Function Block MLFB_HomeFindLimitFastInputModuloPipe Network motion icon

Description

This function block performs a single-axis home to a limit switch connected to a High Speed Input. The motor starts to move according to the direction setting. The home position has been found as soon as the fast inputClosedThe inputs are taken into account at each cycle depending on the system periodicity (for example each millisecond). Under certain circumstances this can be insufficient when more accuracy is needed, or if a quick response is required from the system. To fill the gap, a drive may have some Fast Input connections (generally one or two). When an event happens that triggers a Fast Input (e.g. when a sensor sends a rising edge), the detection of a signal occurs faster (which can be 1000 times more accurate than the system periodicity). Then the timestamp associated with this input can be provided to the IPC to take corrective action selected is triggered on the edge selected.

An absolute move is made to the triggered position, and then the position value is set. This function is to be used when the axis is set-up in Modulo mode.

 

The following figure shows the function block I/O:

UDFB HomeFindLimitFastInputModulo

Figure 8-237: MLFB HomeFindLimitFastInputModulo

 

Arguments

Input

ibExecute

Description

Request the homing step procedure at rising edgeClosedA rising edge is the transition of a digital signal from low to high. It is also called positive edge

 

Data type

BOOL

 

Range

[0 , 1]

 

Unit

N/A

 

Default

iAxisID

Description

Name of a declared instance of the AXIS_REF library function

 

Data type

AXIS_REF

 

Range

[1 , 256]

 

Unit

N/A

 

Default

iPosition

Description

Offset Position Applied After Home Switch is found

 

Data type

LREAL

 

Range

 

Unit

User unit

 

Default

ibDirection

Description

Define the axis homing direction

Value

Description

0

clockwise rotation

1

counterclockwise rotation

 

Data type

BOOL

 

Range

[0 , 1]

 

Unit

N/A

 

Default

iVelocity

Description

Commanded velocity for the homing move

 

Data type

LREAL

 

Range

 

Unit

User unit/sec

 

Default

iAcceleration

Description

Commanded acceleration for the homing move

 

Data type

LREAL

 

Range

 

Unit

User unit/sec2

 

Default

iDeceleration

Description

Commanded deceleration for the homing move

 

Data type

LREAL

 

Range

 

Unit

User unit/sec2

 

Default

ibLimitSwitchMode

Description

Limit switch state to complete homing

Value

Description

0

Rising edge of switch

1

Falling edge of switch

 

Data type

BOOL

 

Range

[0 , 1]

 

Unit

N/A

 

Default

iTimeout

Description

Maximum time for homing move to complete. If exceeded the homing procedure will error out. 0= no time limit

 

Data type

TIME

 

Range

 

Unit

sec

 

Default

ibFastInputNumber

Description

Limit switch state to complete homing.

Value

Description

0

Fast InputClosedThe inputs are taken into account at each cycle depending on the system periodicity (for example each millisecond). Under certain circumstances this can be insufficient when more accuracy is needed, or if a quick response is required from the system. To fill the gap, a drive may have some Fast Input connections (generally one or two). When an event happens that triggers a Fast Input (e.g. when a sensor sends a rising edge), the detection of a signal occurs faster (which can be 1000 times more accurate than the system periodicity). Then the timestamp associated with this input can be provided to the IPC to take corrective action Number 1

1

Fast Input Number 2

 

Data type

BOOL

 

Range

[0 , 1]

 

Unit

N/A

 

Default

iCycleTime

Description

Ethercat Cycle Time

250, 500 or 1000

 

Data type

LREAL

 

Range

 

Unit

microseconds

 

Default

Output

obDone

Description

Indicates the move completed successfully.

The Command Position has reached the endpoint

 

Data type

BOOL

 

Unit

N/A

obActive

Description

Indicates this move is the active move

 

Data type

BOOL

 

Unit

N/A

obError

Description

Indicates an invalid input was specified or the move was terminated due to an error

 

Data type

BOOL

 

Unit

N/A

oErrorID

Description

Indicates the error if Error output is set to TRUE

Value

Description

1

Axis in Error State

2

Axis is Not Enabled

3

Timeout Exceeded

4

SDO Read/Write Error

5

Input Parameter out of Range

 

Data type

DINT

 

Unit

N/A

Usage

This homing procedure performs a homing function searching for sensorClosedA sensor is a type of transducer that converts one type of energy into another for various purposes including measurement or information transfer using only High Speed Input Switches. (A High Speed Limit Switch has 1 “Off” (or “On”) area).

  • Home is commanded by user in the desired homing direction at the selected Velocity.
  • The Timeout can cause an error if exceeded

Related Functions

MLFB_HomeFindHomeFastInput

MLFB_HomeFindHomeFastInputModulo

MLFB_HomeFindLimitFastInput

Example

Structured Text

 

Direction:= 0;

Position:=1000;

Velocity:=1000;

Acceleration:=10000;

Deceleration:=10000;

SwitchMode:=0;

Timeout:=T#100;

FastInputNumber:=0;

CycleTime:=1000;

 

inst_fbHomeFindLimitFastInputModulo(True, Axis1, Position, Direction, Velocity, Acceleration, Deceleration, LimitSwitchMode, Timeout, FastInputNumber, CycleTime);

 

HomeComplete :=inst_fbHomeFindLimitFastInputModulo.Done;

HomeActive :=inst_fbHomeFindLimitFastInputModulo.Active;

HomeError :=inst_fbHomeFindLimitFastInputModulo.Error;

HomeErrorID :=inst_fbHomeFindLimitFastInputModulo.ErrorID;

 

 

Ladder Diagram

UDFB HomeFindLimitFastInputModulo: LD example

 

Function Block Diagram

UDFB HomeFindLimitFastInputModulo: FBD example

 

Go back to the top of the page [Top]