Table of Contents

IStep

Namespace
ZCore
INTERFACE IStep

Interface for single steps in Sequence among others. The main implementation of this interface is the Step class, which should be looked into for further documentation.

Methods

Begin

METHOD PUBLIC Begin () : INT

This method returns the index of the first step in this Sequence. It is the same value as given when this object is being constructed via FB_init

Returns

INT

CurrentIndex

METHOD CurrentIndex () : INT

Returns the current step in which the object is actually in

Returns

INT

End

METHOD PUBLIC End () : INT

This method returns the index of the last step in this Sequence. It is the same value as given when this object is being constructed via FB_init

Returns

INT

Previous

METHOD PUBLIC Previous () : INT

This method returns the previous step index. At initialization of this function block previous is equal to 0.

Returns

INT

RepeatStep

METHOD RepeatStep ()

Calling this method sets the next step to be taken to the same that we are already in. Use this method if it is required to get into the OnEntry section of a step. Internally, this method calls

_step.SetNext(_step.Index());

Restart

METHOD PUBLIC Restart ()

This method changes the step index to Begin and OnExit of the actual step will trigger and OnEntry of the Begin step will also trigger.

This method can be used during execution of the sequence to jump right at the beginning and be sure to trigger OnExit and OnEntry correctly.

SetNext

METHOD PUBLIC SetNext (
 [input] index : INT)

Set the next provided step. Also, it changes the state of this step object to the changed status such that IsNotRepeatable will return FALSE the next time that it is called. Hence, if used properly (see Step the next step will be called in the same cycle. If index is out of bounds (Begin and End) the internal state switches to error.

Inputs

index INT

index to which the step instance should switch next