Mathematical And Functional Expressions; Mathematical Operators - Galil Motion Control DMC-14 5 Series Manual

Table of Contents

Advertisement

#B
N=-1
KP N
TY
EN
#CMDERR
IF _TC=6
N=1
XQ _ED2,_ED1,1
ENDIF
IF _TC=1
XQ _ED3,_ED1,1
ENDIF
EN
Example – Ethernet Communication Error
This simple program executes in the IOC-7007 and indicates (via the serial port) when a
communication handle fails. By monitoring the serial port, the user can re-establish communication if
needed.
Instruction
#LOOP
JP#LOOP
EN
#TCPERR
MG {P1}_IA4
RE
Note: The #TCPERR routine only detects the loss of TCP/IP Ethernet handles, not UDP.

Mathematical and Functional Expressions

Mathematical Operators

For manipulation of data, the DMC-14XX provides the use of the following mathematical operators:
Operator
+
-
*
/
110
Chapter 7 Application Programming
i
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com
Begin thread 1
Create new variable
Set KP to value of N, an invalid value
Issue invalid command
End of thread 1
Begin command error subroutine
If error is out of range (KP -1)
Set N to a valid number
Retry KP N command
If error is invalid command (TY)
Skip invalid command
End of command error routine
Interpretation
Simple program loop
Ethernet communication error auto routine
Send message to serial port indicating which handle did not receive
proper acknowledgement
Return to main program
Function
Addition
Subtraction
Multiplication
Division
DMC-14x5/6

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dmc-14 6 seriesDmc-1415Dmc-1416Dmc-1425

Table of Contents