beautypg.com

Length function, Limit function, Log function – Delta RMC151 User Manual

Page 372: Length( array ), Log( a ), Limit( min , inval, Max )

background image

RMC70/150 and RMCTools User Manual

FLOOR(5.8) returns 5
FLOOR(-17.8) returns -18

5.14.2.22. LENGTH Function

LENGTH(array)
Returns the number of elements in the Array.

Parameters

array (Array Name)
The input array.

Return Value

Returns a DINT.

Examples

MyVar := Length(MyArray);

5.14.2.23. LIMIT Function

LIMIT(Min, InVal, Max)
Limits InVal to the lower limit Min and the upper limit Max. If InVal falls between Min and

Max, returns InVal. If InVal is greater than Max, returns Max. If InVal is less than Min,

returns Min.

Parameters

Min (REAL or DINT)
The lower limit.
InVal (REAL or DINT)
The input value to be limited.
Max (REAL or DINT)
The upper limit.

All three input parameters must have the same data type.

Return Value

Returns the same data type as the input parameters.

Examples

LIMIT(1, _Axis[0].ActPos, 10) returns the Axis 0 Actual Position if it the position is

between 1 and 10. Returns 1 if the position is less than 1. Returns 10 if the position is

greater than 10.

5.14.2.24. LOG Function

352

Delta Computer Systems, Inc.

This manual is related to the following products: