Homing¶
This chapter describes the Homing interface, which is used to home an axis. The Homing interface can be retrieved using the GetHoming method on the AxisControl interface.
Overview¶
The Homing interface supports multiple predefined homing methods that are executed using the Start method on the Homing interface. At the start of each method, the IsHomed signal is cleared. This signal is asserted at the end of successful homing.
Axis with different type of switches shows an axis with possible homing positions, to explain the definitions and terminology for homing. The start position of an axis is indicated by the black dot. The home position is denoted by the circled letter and the path that is traveled is indicated by the arrow. Three different homing positions \(X\), \(Y\) and \(Z\) are shown in Axis with different type of switches, based on different events (i.e. switch transition or index pulse).
Two homing velocities can be configured, i.e. the InitialVelocity and the HomeVelocity. The home velocity is used during the last movement to the home position and the initial velocity is used in all other movements during homing.
Homing definitions states the definitions used throughout this section.
Symbol/Name |
Definition |
---|---|
Initial position of an axis at the start of the execution of the homing method. |
|
Indicates the path that is traveled during the homing procedure, using InitialVelocity. |
|
Indicates the path that is traveled during the homing procedure, using HomeVelocity. |
|
Indicates distance from a reference frame to another reference frame. |
|
Index pulse event. |
|
Desired home position Z. |
|
Reference frame R. |
|
machine zero |
A point that shall have zero value after homing. |
encoder zero |
The point at which encoder reading is zero. |
limit switch |
A positive (negative) limit switch is active when the position is higher (lower) than the switch position and inactive elsewhere. |
area switch |
An area switch is active for a defined position range and inactive elsewhere. |
end stop |
Hard stop to indicate end of an axis. |
Note
In the figures in this chapter, the positive direction is towards the right.
The relationship between different concepts used throughout the section is demonstrated in Homing offset definitions. Reference E and M represent the encoder zero and the machine zero respectively, whereas H denotes the home position.
Machine zero is offset from encoder zero by HomeOffset. Home position is offset from machine zero by UserOffset. UserOffset allows users to change the position that shall have zero value after homing.
Preconditions¶
The queue associated with the axis must be in state Idle and must not be locked. An axis must be in state Operation enabled during the entire execution of the homing method unless stated otherwise. Additionally, it is required to connect the StabilizingComplete input of the command queue to check if the axis is at a standstill before starting homing. Therefore, the StabilizingComplete input of the command queue must be connected to the StabilizingComplete event of the settling state machine, or to the InPosition event of the trajectory interpolator if no settling state machine is available. The home procedure fails if these conditions are not met.
For each homing method holds that if the required homing inputs are not properly configured, the homing method cannot be executed. Sequence diagram shows an example usage of the homing interface.
Signals¶
The generic signals for homing are given in Generic homing signals.
Name |
Data type |
R/W |
Description |
---|---|---|---|
IsHomed |
Bool |
R |
Homing status signal. |
HomeOffset |
Double |
R |
Home position offset value of the last successful home procedure. Only valid when homed. |
HomePosition |
Double |
R |
Home position value of the last successful home procedure. Only valid when homed. |
UserOffset |
Double |
RW |
User defined offset. |
Inputs¶
Homing inputs gives a complete overview of available homing inputs. The homing procedure assumes that the signals connected to the homing inputs are active-high, if needed the polarity should be inverted by the user.
Name |
Data type |
Description |
---|---|---|
IndexPulse |
Bool |
Input connecting to signal containing value of index pulse. |
AreaSwitch |
Bool |
Input connecting to signal containing value of area switch. |
LimitSwitch |
Bool |
Input connecting to signal containing value of limit switch. |
EndStop |
Bool |
Input connecting to signal containing value of end stop. |
PositionSensor |
Double |
Input connecting to signal containing value of position sensor. |
Event responder¶
Homing is an event responder, i.e. Homing implements EventResponder. The following event responses are available:
ResetResponse
Reset response¶
A reset of the homing state machine causes a transition to the Idle state, unless the state was Homing. If the state was Homing it is aborted and the state machine goes to Error. In the Idle state, the signal IsHomed is reset.
Methods¶
Homing methods states all supported homing methods and their configuration. The methods are explained in the linked pages including figures to illustrate how the home position is found. These figures illustrate only one home direction, but each method (with a moving axis) can be executed in the directions as stated in Homing directions. After the home position is found (i.e. the HomePosition signal is set), (1) the HomeOffset is updated, (2) the IsHomed signal is set and (3) the axis is stopped via a quick stop. This implies that after completion, the axis will be located at the braking distance of the home position, not necessarily at the home position. After quickstopping, the homing procedure will leave the axis in the state that the axis had prior to homing.
If during homing the direction is reversed, the condition operators are also adjusted if necessary. For example, see the paths in Method LimitSwitch (for positive home direction) where the limit switch is active at the beginning.
Method |
Description |
---|---|
None |
No homing method. |
Set machine zero based on an encoder reading. |
|
Set machine zero to a known position (e.g. from absolute encoder). |
|
Machine zero is equal to the first index pulse position. |
|
Machine zero is equal to the first index pulse position after rising edge of the limit switch. |
|
Machine zero is equal to the falling edge of the limit switch. |
|
Machine zero is equal to the first index pulse position after falling edge of the limit switch. |
|
Machine zero is equal to the first index pulse position after falling edge of the area switch while moving in the homing direction. |
|
Machine zero is equal to the rising edge of the area switch while moving opposite to the homing direction. |
|
Machine zero is equal to the first index pulse position after rising edge of the area switch while moving opposite to the homing direction. |
|
Machine zero is equal to the first index pulse position after rising edge of the area switch while moving in the homing direction. |
|
Machine zero is equal to the rising edge of the area switch while moving in the homing direction. |
|
Machine zero is equal to the first index pulse position after falling edge of the area switch while moving opposite to homing direction. |
|
Machine zero is equal to the rising edge of the endstop. |
|
Machine zero is equal to the first index pulse after endstop while moving opposite to the homing direction. |
Direction |
Description |
---|---|
None |
No movement. |
Positive |
Movement starts in positive direction, if axis is not at limit switch or end stop. |
Negative |
Movement starts in negative direction, if axis is not at limit switch or end stop. |
State machine¶
Homing state machine represents the state machine of the homing implementation and Homing states lists the possible states.
State |
Description |
---|---|
Idle |
No homing busy. |
Homing |
Homing procedure busy. The active homing procedure can be aborted by calling the Reset method on the Homing interface. |
Homed |
Homing procedure completed without error. |
Error |
Error occurred during homing. Use the RunException property on the Homing interface to obtain details regarding the error. |
On start of execution of a homing method, the IsHomed signal is reset. The IsHomed signal is set when a homing method is completed successfully. After execution of a homing method, it is possible to home again.
Sequence diagram¶
Example homing sequence shows an example of how to get and use the homing interface. The example assumes homing is pre-configured for example using XML XML configuration.
IEC mapping¶
If familiar with the homing methods defined in IEC 61800-7-201, one can use IEC to PMP mapping of homing methods to see which configuration of a PMP homing method should be chosen to execute the homing method as defined by the IEC.
IEC method |
PMP method |
Home direction |
Details |
---|---|---|---|
1 |
LimitSwitchA |
Negative |
|
2 |
LimitSwitchC |
Positive |
|
3 |
LimitSwitchC |
Positive |
|
4 |
LimitSwitchA |
Positive |
|
5 |
LimitSwitchA |
Negative |
|
6 |
LimitSwitchC |
Negative |
|
7 |
AreaSwitchF |
Positive |
|
8 |
AreaSwitchD |
Positive |
|
9 |
AreaSwitchC |
Positive |
|
10 |
AreaSwitchA |
Positive |
|
11 |
AreaSwitchA |
Negative |
|
12 |
AreaSwitchC |
Negative |
|
13 |
AreaSwitchD |
Negative |
|
14 |
AreaSwitchF |
Negative |
|
17 |
LimitSwitchB |
Negative |
|
18 |
LimitSwitchB |
Positive |
|
19 |
LimitSwitchB |
Positive |
|
20 |
LimitSwitchB |
Positive |
|
21 |
LimitSwitchB |
Negative |
|
22 |
LimitSwitchB |
Negative |
|
23 |
AreaSwitchE |
Positive |
|
24 |
AreaSwitchE |
Positive |
|
25 |
AreaSwitchB |
Positive |
|
26 |
AreaSwitchB |
Positive |
|
27 |
AreaSwitchB |
Negative |
|
28 |
AreaSwitchB |
Negative |
|
29 |
AreaSwitchE |
Negative |
|
30 |
AreaSwitchE |
Negative |
|
33 |
IndexPulse |
Negative |
|
34 |
IndexPulse |
Positive |
|
35 |
AbsolutePosition |
None |
See also
- Homing
XML configuration example of the homing interface.