Galil DMC-3425 user manual If, Else, and Endif, Examples, Using the if and Endif Commands

Models: DMC-3425

1 210
Download 210 pages 53.34 Kb
Page 129
Image 129

Examples

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.

Instruction

Interpretation

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

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

Instruction

Interpretation

#BEGIN

Begin Program

COUNT=10

Initialize loop counter

#LOOP

Begin loop

PA 1000

Position absolute 1000

BGA

Begin move

AMA

Wait for motion complete

WT 100

Wait 100 msec

PA 0

Position absolute 0

BGA

Begin move

AMA

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

If, Else, and Endif

The DMC-3425 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 its 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-3425

Chapter 7 Application Programming121

Page 129
Image 129
Galil DMC-3425 user manual If, Else, and Endif, Examples, Using the if and Endif Commands

DMC-3425 specifications

The Galil DMC-3425 is a sophisticated motion controller known for its versatility and high performance in various industrial applications. Designed primarily for multi-axis control, it is well-suited for robotics, CNC machinery, and automated manufacturing systems.

One of the standout features of the DMC-3425 is its ability to control up to 32 axes simultaneously, providing unparalleled flexibility for complex motion tasks. This capability is enhanced by its advanced motion algorithms that ensure smooth and precise movements, essential for high-quality manufacturing and assembly processes. The controller supports a variety of motor types, including servo, stepper, and brushless motors, making it compatible with a wide range of existing equipment.

In terms of connectivity, the DMC-3425 offers an extensive selection of communication options. It supports Ethernet, RS-232, and RS-485 interfaces, allowing for seamless integration with various industrial networks, including EtherCAT and CANopen. This connectivity is vital for real-time data exchange and remote monitoring, enhancing overall system efficiency.

The controller is powered by Galil's innovative software architecture, which includes the DMC programming language. This user-friendly language enables engineers to create complex motion profiles easily, with support for trajectory generation, coordinate transformations, and PID control. The DMC-3425 also features built-in commands for motion profiling, including linear and circular interpolation, allowing for sophisticated path planning.

Moreover, the DMC-3425 comes equipped with an integrated programming environment that facilitates rapid application development. Users can simulate motion profiles before implementation, reducing downtime and minimizing errors. This environment is designed for quick learning, making it accessible even for those new to motion control.

Additionally, the Galil DMC-3425 features a robust safety architecture. It includes over-temperature detection, emergency stop inputs, and configurable limits for position and speed, ensuring safe operation in various environments.

Overall, the Galil DMC-3425 is a powerful and flexible motion controller that combines advanced technologies with user-friendly design. Its ability to handle multiple axes, extensive connectivity options, and comprehensive programming environment make it a top choice for manufacturers seeking to enhance automation and improve productivity in their operations.