JP #TEST, (V1<V2) & (V3<V4)

In this example, this statement will cause the program to jump to the label #TEST if V1 is less than V2 and V3 is less than V4. To illustrate this further, consider this same example with an additional condition:

JP #TEST, ((V1<V2) & (V3<V4)) (V5<V6)

This statement will cause the program to jump to the label #TEST under two conditions; 1. If V1 is less than V2 and V3 is less than V4. OR 2. If V5 is less than V6.

Using the JP Command:

If the condition for the JP command is satisfied, the controller branches to the specified label or line number and continues executing commands from this point. If the condition is not satisfied, the controller continues to execute

the next commands in sequence.

Conditional

Meaning

JP #Loop,COUNT<10

Jump to #Loop if the variable, COUNT, is less than 10

JS #MOVE2,@IN[1]=1

Jump to subroutine #MOVE2 if input 1 is logic level high. After the subroutine

 

MOVE2 is executed, the program sequencer returns to the main program location

 

where the subroutine was called.

JP #BLUE,@ABS[V2]>2

Jump to #BLUE if the absolute value of variable, V2, is greater than 2

JP #C,V1*V7<=V8*V2

Jump to #C if the value of V1 times V7 is less than or equal to the value of V8*V2

JP#A

Jump to #A

Example Using JP command:

Move the X motor to absolute position 1000 counts and back to zero ten times. Wait 100 msec between moves.

#BEGIN

Begin Program

COUNT=10

Initialize loop counter

#LOOP

Begin loop

PA 1000

Position absolute 1000

BGX

Begin move

AMX

Wait for motion complete

WT 100

Wait 100 msec

PA 0

Position absolute 0

BGX

Begin move

AMX

Wait for motion complete

WT 100

Wait 100 msec

COUNT=COUNT-1

Decrement loop counter

JP #LOOP,COUNT>0

Test for 10 times thru loop

EN

End Program

Using If, Else, and Endif Commands

The DMC-1700/1800 provides a structured approach to conditional statements using IF, ELSE and ENDIF commands.

Using the IF and ENDIF Commands

An IF conditional statement is formed by the combination of an IF and ENDIF command. The IF command has as it’s arguments one or more conditional statements. If the conditional statement(s) evaluates true, the command interpreter will continue executing commands which follow the IF command. If the conditional statement evaluates false, the controller will ignore commands until the associated ENDIF command is executed OR an ELSE command occurs in the program (see discussion of ELSE command below).

DMC-1700/1800

Chapter 7 Application Programming • 147

Page 155
Image 155
Galil DMC-1700 Using If, Else, and Endif Commands, JP #TEST, V1V2, Using the JP Command, Example Using JP command

DMC-1800, DMC-1700 specifications

The Galil DMC-1700 and DMC-1800 are advanced motion controllers widely recognized for their high performance and versatility in the automation and robotics industries. These controllers are designed to meet the demands of complex motion control applications, providing users with enhanced features and innovative technologies that optimize motion precision and efficiency.

One of the main features of the Galil DMC-1700 is its ability to handle up to 8 axes of motion control. This capability makes it suitable for a range of applications, from simple point-to-point movements to intricate trajectories in multi-axis systems. In contrast, the DMC-1800 extends this functionality, supporting up to 64 axes, making it ideal for large-scale automation environments.

Both models leverage Galil's powerful programming interface, which simplifies the development of motion control applications. The DMC-1700 and DMC-1800 controllers utilize a high-level programming language that supports advanced motion commands, including linear interpolation, circular interpolation, and complex motion profiles. This feature allows users to implement sophisticated motion sequences seamlessly.

In terms of connectivity, the Galil DMC series offers multiple communication options, including Ethernet, RS-232, and CAN bus, ensuring compatibility with various hardware and enabling easy integration into existing systems. The controllers also come equipped with digital and analog I/O ports, providing flexibility for sensor feedback and actuator control.

The advanced technology incorporated into both the DMC-1700 and DMC-1800 includes on-board PID control, which ensures precise motion control through closed-loop feedback. This results in improved stability and accuracy, particularly in high-speed applications. Additionally, the controllers offer extensive diagnostics and monitoring capabilities, allowing for real-time performance analysis and troubleshooting.

Another notable characteristic of these motion controllers is their compact design, which offers space-saving advantages while maintaining high processing power. Their robust construction and ability to operate in challenging environments make them suitable for a wide range of industrial applications, from CNC machining to assembly lines.

In conclusion, the Galil DMC-1700 and DMC-1800 motion controllers stand out due to their high-performance capabilities, advanced programming features, and flexibility in connectivity. With their ability to handle complex motion control tasks efficiently, these controllers are invaluable tools for engineers and manufacturers looking to enhance their automation processes. By integrating Galil's innovative motion control technology, industries can achieve greater precision, speed, and reliability in their operational workflows.