Hyundai HI4 operation manual Function Arithmetic Function, DEGRAD270, Orderror, Timer

Models: HI4

1 427
Download 427 pages 29.73 Kb
Page 405
Image 405

11.Robot Language Explanation

------------------------------------------------------------------------------------------------

11.4Function

11.4.1 Arithmetic Function

The functions that have the numeric value returned, are called the arithmetic functions.

Function Name

Description

Example

 

 

 

ABS(a)

Returns the absolute value of a

V19!+ABS(V20!)

 

 

 

MAX(a, b)

Returns the bigger value between a and b.

MAX(V20!, 0)

 

 

 

MIN(a, b)

Returns the smaller value between a and b.

MIN(V20!, 10)

 

 

 

DEGRAD(a)

Returns radian value of a in degree.

DEGRAD(270)

 

 

 

RADDEG(a)

Returns degree value of a in radian.

RADDEG(3.1415*V20!)

 

 

 

SQR(a)

Returns a square root of a.

SQR(V20!)

 

 

 

SIN(a)

Returns a sine value of a in radian.

SIN(V20!)

 

 

 

COS(a)

Returns a cosine value of a in radian.

COS(V20!)

 

 

 

TAN(a)

Returns a tangent value of a in radian.

TAN(V20!)

 

 

 

ATN(a)

Returns a arctangent value of a in radian.

ATN(V20!)

 

 

 

ATN2(a, b)

Returns a arctangent value of a triangle which have

ATN(V25!, V26!)

 

x length of a and y length of b, in radian.

 

 

 

 

DIST(a, b)

Returns the distance to a point which x coordinate

DIST(V5!, V6!)

 

is a and y coordinate is b.

 

ORD(a)

Returns the character code for the first character

ORD("ERROR")

 

of the string.

 

VAL(a)

Returns the value of a number described in string.

VAL("29.38E-2")

 

 

 

STRPOS(a, b)

Returns the first location matching to b string

STRPOS(V7$, "=")

within a string.

 

 

 

LEN(a)

Returns the length of a string.

LEN(V8$)

 

 

 

TIMER

Gets the elapsed time from the power on in seconds.

TIMER

 

 

 

----------------------------------------------------------------------------------------

11 - 40

Page 405
Image 405
Hyundai HI4 operation manual Function Arithmetic Function, DEGRAD270, Orderror, Timer