Formatting Variables and Array Elements

The Variable Format (VF) command is used to format variables and array elements. The VF command is specified by:

VF m.n

where m is the number of digits to the left of the decimal point (0 thru 10) and n is the number of digits to the right of the decimal point (0 thru 4).

A negative sign for m specifies hexadecimal format. The default format for VF is VF 10.4 Hex values are returned preceded by a $ and in 2’s complement.

:V1=10

Assign V1

:V1=

Return V1

0000000010.0000

Default format

:VF2.2

Change format

:V1=

Return V1

10.00

New format

:VF-2.2

Specify hex format

:V1=

Return V1

$0A.00

Hex value

:VF1

Change format

:V1=

Return V1

9

Overflow

Local Formatting of Variables

PF and VF commands are global format commands that effect the format of all relevent returned values and variables. Variables may also be formatted locally. To format locally, use the command, {Fn.m} or {$n.m} following the variable name and the ‘=’ symbol. F specifies decimal and $ specifies hexadecimal. n is the number of digits to the left of the decimal, and m is the number of digits to the right of the decimal. For example:

Examples:

:V1=10

Assign V1

:V1=

Return V1

0000000010.0000

Default Format

:V1={F4.2}

Specify local format

0010.00

New format

:V1={$4.2}

Specify hex format

$000A.00

Hex value

:V1=”ALPHA”

Assign string “ALPHA” to V1

:V1={S4}

Specify string format first 4 characters

ALPH

The local format is also used with the MG* command.

Converting to User Units

Variables and arithmetic operations make it easy to input data in desired user units such as inches or RPM.

The DMC-1700/1800 position parameters such as PR, PA and VP have units of quadrature counts. Speed parameters such as SP, JG and VS have units of counts/sec. Acceleration parameters such as AC, DC, VA and VD

have units of counts/sec2. The controller interprets time in milliseconds.

DMC-1700/1800

Chapter 7 Application Programming • 165

Page 173
Image 173
Galil DMC-1700 Formatting Variables and Array Elements, Converting to User Units, Local Formatting of Variables, VF m.n

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.