Parker Hannifin User Information Warning — ACR series products are used to control electrical and mechanical components of motion control systems. You should test your motion system for safety under all potential conditions. Failure to do so can result in damage to equipment and/or serious injury to personnel.
Parker Hannifin Table of Contents User Information ......................................................ii Table of Contents ....................................................iii Change Summary ................................................... vii Revision B Changes......................................................................................... vii Getting Started .........................................................8 Application Description ..............................................
Parker Hannifin Program Flow ................................................................................................ Selection ................................................................................................. Repetition ................................................................................................ Other Conditional Statements..................................................................... Parameters and Bits.....................................................
Parker Hannifin Servo Loop Fundamentals ....................................120 Setpoint Compensation .................................................................................120 Viewing the Setpoint Calculations ..............................................................121 Following Error .............................................................................................121 Binary Host Interface ...........................................123 Binary Data Transfer ....................
Parker Hannifin Additional Features ..............................................151 CANopen .....................................................................................................151 Limited Amounts of Nodes and I/O.............................................................151 Alternate Mapping of Digital I/O ................................................................151 Semi-Automatic Network Configuration ......................................................
Parker Hannifin Change Summary The change summary below lists the latest additions, changes, and corrections to the ACR Programmer’s Guide and the corresponding section of ACR-View Online Help. Revision B Changes Document 88-028698-01B (ACR Programmer’s Guide) supersedes document 88-028698-01A. Changes associated with this document are notated in this section. Topic Description Program Labels Refined the rules.
Parker Hannifin Getting Started Use the tutorials in this section to guide you through the configuration and tuning of your ACR series controller, and to help you create a project and become familiar with the ACR-View software. Application Description The tutorial leads you through setting up a sample application—a three-axis system (an X-Y-Z gantry that moves a camera carriage) controlled by a four-axis, standard ACR9000.
Parker Hannifin Getting Started - Tutorial Use this basic tutorial to familiarize yourself with the ACR-View software and how to set up a project. Starting a New Project When you create a new project, wizards guide you as you set up the project. First, add a controller and provide its basic configuration data. 1. On the Start menu click Programs, click Parker Automation, then click ACR-View, and then select ACR-View. 2. Click Create New Project, and then type Sample in the box. Click OK. 3.
Parker Hannifin 11. In the Scaling dialog, do the following: a. Under Specify Units, click Inches. b. In the Transmission list, select Leadscrew. c. In the Transmission Details box (below the Transmission list), type 0.2—this represents the number of inches per revolution of the leadscrew. d. Click Next. 12. In the Fault dialog, do the following: a. Select the Enable Positive Software Limit Detection check box, and then type 24 b.
Parker Hannifin 19. In the Fault dialog, do the following: a. Select the Enable Positive Software Limit Detection check box, and then type 24 b. Select the Enable Negative Software Limit Detection check box, and then type 0 c. Select the Enable Maximum Position Error Detection check box. d. In the Maximum Positive Position Error box, type 0.2 e. In the Maximum Negative Position Error box, type –0.2 f. Click Next. 20. In the Dedicated I/O dialog, do the following: a.
Parker Hannifin 25. In the Fault dialog, do the following: a. Select the Enable Positive Software Limit Detection check box, and then type 6 b. Select the Enable Negative Software Limit Detection check box, and then type 0 c. Select the Enable Maximum Position Error Detection check box. d. In the Maximum Positive Position Error box, type 0.2 e. In the Maximum Negative Position Error box, type –0.2 f. Click Next. 26. In the Dedicated I/O dialog, do the following: a.
Parker Hannifin 2. 3. 4. In the Masters dialog, assign axis Z to master 1: a. In the Axes list to the left, select Axis 2. b. In the Masters list to the right, select Master 1. c. Click Move Axes to Master. d. Click Next In the Master 0 dialog, do the following: a. In the Acceleration Ramp box, type 10 b. In the Velocity box, type 5 c. In the Deceleration Ramp box, type 10 d. In the Stop Ramp box, type 10 e. Click Next. In the Master 1 dialog, do the following: a.
Parker Hannifin Creating a program This application requires two programs. Program 0: Determines the motion the gantry (axes X and Y), allowing a camera to take scans from various positions. Program 1: Activates when the gantry (axes X and Y) crosses a boundary marked by a light curtain. When the gantry passes through the light curtain, input 10 turns on, which initiates retraction of the camera (axis Z) to a safety position. When input 10 turns off, the camera returns to its original position. 1.
Parker Hannifin 4.
Parker Hannifin Servo Tuning - Tutorial The tuning process lets you hone the servo response and settling for your particular system. Settling and responsiveness are the main components that determine performance. Generally, the goal of servo tuning is good settling, with a secondary goal of good responsiveness. Ultimately, only you can determine which aspect is of prime importance, and when the tuning is “good enough” for your system. For safety, tune the servo system unloaded.
Parker Hannifin Tuning Example The tuning example assumes the following: • Parker BE 241 motor. • 9 to 1 load-to-rotor inertia ratio. Illustration Legend Color Position Green Commanded Yellow Actual 1. As a starting point, the PGAIN is set to 0.0003; no DGAIN is set at this time. Figure 1 shows that the motor is under responsive.
Parker Hannifin 2. The PGAIN is increased to 0.0005 to increase the response. As Figure 2 illustrates, the motor response increased significantly, the motor is under-damped. Before we continue adjusting the motor response, it is important to compensate for the under-damping by adding DGAIN.
Parker Hannifin 3. Setting the DGAIN to 0.00001 slightly over-damps the response, as shown in Figure 3. Now we can turn again to adjusting the motor response by increasing the PGAIN. If we were to increase the proportional gain without adjusting the derivative gain, the oscillations would increase and possibly create motor instability.
Parker Hannifin 4. 20 With PGAIN increased to 0.001, motor responsiveness has increased (Figure 4) and the over-damping has decreased slightly. As there is no significant change to the settling, there is no need to adjust the DGAIN. However, there is still room for improvement on motor response.
Parker Hannifin 5. The PGAIN is increased to 0.005, resulting again in increased responsiveness (Figure 5). But with increased oscillations, due to under-damping, we need to adjust the DGAIN again.
Parker Hannifin 6. 22 Increasing the DGAIN to 0.00003 damps the oscillation. As Figure 6 illustrates, both motor response and damping look good. We are ready to add a load to the motor.
Parker Hannifin 7. With a loaded motor, we can see that the response has slowed and the damping is weaker. Like before, we can increase the PGAIN for a better response.
Parker Hannifin 8. 24 The PGAIN is increased to 0.02, and we can see better response from the motor. But there is still some oscillation from the motor, so we increase the damping.
Parker Hannifin 9. With DGAIN increased to 0.00015 the chattering is significantly reduced—both motor response and damping look good. With a load attached, the motor is now fast and stable; no more tuning is necessary.
Parker Hannifin System Configuration The following section helps you understand how to configure your ACR controller for use. • Communication Levels • Hardware Configuration • Dedicated I/O • End-of-Travel Limits • Attachments • Memory Allocations Communication Levels Communication channels are either at the "system" level or at a "program" level. The command prompt indicates which level a communication channel is currently at. Certain commands are limited to a specific level.
Parker Hannifin Program/PLC Level The "program" or “PLC” level lets you edit and run individual programs or PLCs. The command prompt at the program level is as follows: Pnn> The command prompt at the PLC level is as follows: PLCn> Where "nn" or “n” represents the currently active program number. To select the program or PLC level from any other level, issue the PROG or PLC command followed by the program number.
Parker Hannifin Hardware Configuration Before using an ACR controller, you must define for the firmware what specific hardware is installed. The default configuration is as follows: CONFIG ENC8 DAC4 DAC4 ADC8 The command uses four arguments— encoders, module 0, module 1, and module 2. Encoder: The encoder argument is the number of encoder channels installed. NONE, ENC2, ENC4, ENC6, ENC8, ENC10 Module 0: The module 0 argument is the type of module installed in the first SIMM socket.
Parker Hannifin Dedicated I/O The ACR series controller contains I/O dedicated to Drive Enable, Drive Reset, and Drive Fault signals. Refer to the appropriate hardware manual for configuration. The ACR series controllers also contain hardware and software endof-travel limits, and homing. In the ACR90x0, the default is the lowest onboard inputs being assigned to the lowest axis. For example, axis 0 uses inputs 0, 1, and 2; axis 1 uses inputs 3, 4, and 5.
Parker Hannifin NOTE: There are no restrictions regarding how to assign hardware limits and homing inputs. However, you should exercise caution because it is possible to create imaginary limit and home inputs. This is because the controller assumes all three inputs are in the same multiple of 32 bits. The assignment of inputs does not roll over to the next block of 32 bits. For example, if the positive hardware limit is assigned to input 31, the negative hardware limit and homing inputs are not assigned.
Parker Hannifin Hardware Limit Enable By default, positive and negative hardware limits are disabled. You can enable the limits by setting the appropriate control bits (bit 20= positive hardware limit enable, bit 21= negative hardware limit enable). You can also control the hardware limits using the HLIM command.
Parker Hannifin Soft Limit Enable By default, positive and negative software limits are disabled. You can enable the limits by setting the appropriate control bits (bit 22= positive software limit enable, bit 23= negative software limit enable). You can also control the software limits using the SLIM command.
Parker Hannifin Attachments Attachments are a means of defining the hardware you have, and how it connects together. Software Attachments Before using an ACR controller, define the feedback and signal output for each axis. By default, each axis is attached to its matching encoder and DAC output. Using the ATTACH AXIS command, change the default attachments to fit your application. By default, each encoder and DAC is set to the same index as the axis to which it is attached.
Parker Hannifin Signal: The signal argument determines the signal output by the ACR controller. • Analog voltage output DAC0 through DAC7 • Step and directions outputs. STEPPER0 through STEPPER7 • Sinusoidal/Trapezoidal commutation output. CMT0 through CMT7 Velocity: The velocity argument determines the velocity attachment. This lets you set a velocity feedback source for dualloop feedback—this provides a software tachometer based on encoder or analog signal input.
Parker Hannifin Master/Slave Attachments Without master/slave attachments, motion cannot occur. So what are masters and slaves? NOTE: There are no default master/slave attachments. Masters Master are trajectory (or motion profile) generators for coordinated motion. A master computes trajectories only for the slave or slaves attached to that master. You can assign only one master to a program.
Parker Hannifin Setting up coordinated motion does not differ. After attaching a master to the program, you attach all the slaves. For example, an ACR9000 controls coordinated motion for five axes: you attach master zero to program zero, and axes zero through four to program zero. For more information, see the ATTACH MASTER command in the ACR Command Language Reference. Slaves Each master uses its own set of dedicated slaves; slaves act as simple placeholders for axes.
Parker Hannifin The diagram below helps illustrate the concepts and relationships between masters and slave, programs and axes. Attaching Slaves As previously stated, for a program to make motion, it must have a master and slaves attached to it. Once you have attached a master, you can then attach the slaves. Each master contains its own set of slaves, and each set of slaves is independent of the slaves in other masters. When attaching to slaves, start with the first available slave.
Parker Hannifin • To reuse an axis and attach it to a different master/slave, you must first separate it from the current master/slave using the DETACH command. For more information, see the ATTACH SLAVE command in the ACR Command Language Reference. Slaves and Axis Names The ATTACH SLAVE command lets you provide an axis name (up to four alpha characters)—such as X, ARM, or UP. You can use the axis name in the program code (for that program only).
Parker Hannifin Memory Allocations Memory allocation on the ACR series controllers is completely customizable —you can assign controller memory to features and functions that need it most for your particular application. Using the Configuration Wizard, you can quickly allocate memory for the following: programs, PLCs, global variables, local variables, arrays, and communication stream buffers. It is important to dimension the memory correctly for your application.
Parker Hannifin NOTE: The memory organization differs for each controller—for more information, see the section titled Memory Organization in the ACR Command Language Reference. System and Program Memory Levels Memory is allocated at two levels, the system level and program level: System At the SYS prompt, you can allocate memory for the following: • Programs: The factory default divides memory equally among programs 0-7 (factory default is 512K total).
Parker Hannifin • Arrays: The factory default provides no memory allocated to arrays. After allocating memory, these items are available only within the specified program. How Much Memory? There are no simple guidelines to determine how much memory your programs might require; the needs of each application are different. It also depends how you intend to develop programs for the controller.
Parker Hannifin Displaying Current Memory Allocations From the SYS prompt, you can view memory allocations for programs, PLCs, communication stream buffers, global variables, and aliases. The controller displays the default memory allocation for only programs. For all other items, you must allocate memory to them (PLCs, global variables, and aliases), or change the default memory allocation (communication stream buffers).
Parker Hannifin Programming Basics The following section explains some fundamental concepts of the AcroBASIC programming language. Aliases Alternative names, called aliases, can be assigned to parameters, bits, constants, and variables to make program code more readable. Aliases are recognized globally (across user programs). NOTE: Do not confuse aliases with axis names. You can assign an axis name to an axis through the ATTACH SLAVE command.
Parker Hannifin • Use the RETURN command to indicate the end of the subroutine. • Do not put a REM command on the same line as a label. Example _START GOSUB Label1 GOTO START _Label1 PRINT “Inside Label1 subroutine” RETURN Remarks You can add comments to a program. You can put a REM statement by itself on a line, or you can place it on the same line after a program statement.
Parker Hannifin You can only issue some parent commands in conjunction with a daughter statement. For example, the FLASH command has the ERASE, LOAD, IMAGE, RES, and SAVE daughter statements. Therefore, you can issue the FLASH ERASE, FLASH LOAD, FLASH IMAGE, FLASH RES, and FLASH SAVE commands, but not FLASH by itself. Description of Format Each parent or daughter command shows the necessary elements to correctly use that command.
Parker Hannifin Arguments and Syntax The syntax of an AcroBASIC command shows you all the components necessary to use it. Commands can contain required and optional arguments. They also contain a number of symbols: • Braces { }—arguments that are optional. Do not type the braces in your code. • Parentheses ( )—arguments that are optional, and must appear within the parentheses in your code. Also used to indicate variables and expressions.
Parker Hannifin Example 2 FBVEL {AXIS {value}} {AXIS {value}} ... Optional arguments can nest. This provides the flexibility to set data for or receive reports on multiple axes. For example, the following sets the velocity feedback gain for axes X and Y to 0.0001 and 0.0002 respectively. FBVEL X 0.0001 Y 0.0002 Because the FBVEL command can report on multiple axes, you specify at least one axis on which the controller is to report back. P00>FBVEL X 0.0001 P00>FBVEL X Y 0.0001 0.
Parker Hannifin Programs and Commands There is a subset of AcroBASIC commands that act right away. While you can use them in programs, you can also send them from a terminal emulator and effect changes immediately—commands such as ACC, DEC, and VEL. You can also make on-the-fly changes to a program from a terminal emulator. At the appropriate program prompt (SYS, PROG, or PLC), you can enter the line of code.
Parker Hannifin Starting, Pausing, and Halting Programs Once downloaded to a controller, you can control programs from the SYS prompt, as well as any PROG or PLC prompt. You must include the program or PLC number when issuing the command—for example RUN PROG0, or PAUSE PROG0, or HALT PROG0. The following commands provide immediate program control from a terminal editor: Running a Program While the program starts, the controller returns to the SYS, PROG, or PLC prompt.
Parker Hannifin Pausing a Program Pausing a program places a feed hold on the current move and suspends the program at the current command line. ► To suspend a currently running program, send the PAUSE command. Resuming a Paused Program Once paused, you can resume the program—motion and code execution continue from the places at which they paused. ► To continue program operation, send the RESUME command. Affecting Multiple Programs You can control all programs simultaneously using the ALL argument.
Parker Hannifin Program Flow Code is executed sequentially, following the order in which it is written. But based on some input, you can shift code execution elsewhere in a program using conditional statements. Using conditional statements, you can create code that tests for specific condition and repeats code statements. The conditional statement provides a logical test—a truth statement—allowing decisions based on whether the conditions are met.
Parker Hannifin When using an IF/THEN statement, observe the following: • You can nest GOTO and GOSUB statements in an IF/THEN statement. Example The following demonstrates several simple IF/THEN statements. IF (BIT 24) THEN P0 = P0+1 IF (P0 > 4000) THEN GOSUB 100 : P0 = P0-1 IF/ELSE The IF/ELSE statement provides a powerful tool for program branching and program flow control.
Parker Hannifin Here is how it works. When the IF condition is true, the subsequent statements are executed. When the IF condition is false, each ELSEIF statement is tested in order. When an ELSEIF condition tests true, the subsequent statements are executed. When the ELSEIF condition test false, the statements following ELSE condition execute. After executing the statements following an IF, ELSEIF, or ELSE, the program moves past the ENDIF to continue program execution.
Parker Hannifin Repetition The repetition structure—known as a loop—controls the repeated execution of a statement or block of statements. While the conditions remain true, the program loops (or iterates) through the specific code. Typically, the repetition structure includes a variable that changes with each iteration. And a test of the value determines when the conditions of the expression are satisfied. The program then moves to the next statement past the repletion structure.
Parker Hannifin WHILE/WEND The WHILE/WEND loop executes as long as its condition remains true. You can use the WHLE/WEND anywhere in a program. The WHILE sets the condition, and is followed by statements you want executed when the condition is true. When the condition is false, the statement immediately following WEND executes. The condition is evaluated only at the beginning of the loop. When using a WHILE/WEND statement, observe the following: • Do not nest GOTO statements in an WHILE/WEND statement.
Parker Hannifin Example The following demonstrates inhibiting a program until a certain condition is met. INH 2 : REM wait until bit 2 = 1 INH -516 : REM wait until bit 516 = 0 IHPOS The IHPOS command lets you inhibit program execution based on the setpoint of a given parameter or a timeout is reached. NOTE: While intended to inhibit program execution based on an axis position, you can use any system parameter or user defined parameter.
Parker Hannifin Following is a list of the most commonly used parameter and bit tables: • Master Parameters • Master Flags • Axis Parameters • Axis Flags • Object Parameters • Program Parameters • Program Flags Using Parameters and Bits You can specify parameters and bits in your programs or at a terminal emulator. Use the following format: Px or BITx, where x represents the parameter or bit number. Example The following demonstrates how to format parameters and bits.
Parker Hannifin Printing the Current Value You can send the PRINT command followed by a parameter or bit whose value you want to see. Bits return the following values: • -1 when set. • 0 when clear. You can use a question mark in place of the PRINT command. The question mark is a shortcut in a terminal emulator. NOTE: When printing a system parameter, the value returned is either an integer or a 32-bit floating point.
Parker Hannifin Programming Example The following program creates a square. You can use ACR-View to set up the controller. Then enter the program into program 0 and download it to the controller.
Parker Hannifin Parametric Evaluation Most commands take arguments. Often, those command-line arguments are literals—values that are interpreted as they are written. For example, axis numbers, bit index numbers, acceleration or deceleration speeds, or positional values. In addition to literals, you can use expressions (also called formulas). The ACR controller can solve complex integer or floating point math. To use expressions, you must enclose them in parentheses.
Parker Hannifin Parentheses Using parentheses, you can group operations in an expression to change the order in which they are performed. Operational Order For example, the expression 4+6/2 provides the answer 7, and not 5, because division performs before addition. When a mathematical expression contains operators that have the same rank, operations are performed left to right. For example, in the expression 2+6/3*5-9 division and multiplication perform before addition and subtraction.
Parker Hannifin Example 2 When the following IF statement proves true, the message “OK” prints. IF(P0=1234) THEN PRINT “ok” Example 3 The following concatenates strings $V1 and $V2, and sets string $V0 equal to the result. $V0 = $V1 + $V2 Example 4 The following program generates a random number from 0 to 999. As the program loops, it counts each loop. When the number equals 123, the program exits the loop and prints the count.
Parker Hannifin Basic Setup Before You Begin The tables in this section list commands according to the following command groups: Axis Limits Non-Volatile Character I/O Operating System Drive Control Program Control Feedback Control Program Flow Global Objects Servo Control Interpolation Setpoint Control Logic Function Transformation Memory Control Velocity Profile Warning — ACR Series products are used to control electrical and mechanical components of motion control systems.
Parker Hannifin Axis Limits Command Description ALM Set stroke limit ‘A’ BLM Set stroke limit ‘B’ EXC Set excess error band HLBIT Set hardware limit/homing input HLDEC Hardware limit deceleration HLIM Hardware limit enable IPB Set in-position band ITB Set in-torque band JLM Set jog limits MAXVEL Set velocity limits PM Position maintenance SLDEC Software limit deceleration SLIM Software limit enable SLM Software positive/negative travel range TLM Set torque limits Character I
Parker Hannifin Feedback Control Command Description HSINT High speed interrupt INTCAP Encoder capture MSEEK Marker seek operation MULT Set encoder multipliers NORM Normalize current position OOP High speed output PPU Set axis pulse/unit ratio REN Match position with encoder RES Reset or preload encoder ROTARY Set rotary axis length Global Objects Command Description ADC Analog input control ADCX Expansion board analog input AXIS Direct axis access CIP Ethernet/IP status DAC
Parker Hannifin Interpolation Command Description CIRCCW Counter clockwise circular move CIRCW Clockwise circular move INT Interruptible move INVK Inverse kinematics MOV Define a linear move NURB NURBs interpolation mode SINE Sinusoidal move SPLINE Spline interpolation mode TANG Tangential move mode TARC 3-D circular interpolation TRJ Start new trajectory Logic Function Command Description CLR Clear a bit flag DWL Delay for a given period IHPOS Inhibit on position INH Inhib
Parker Hannifin Non-Volatile Command Description BRESET Disable battery backup ELOAD Load system parameters ERASE Clear the EEPROM ESAVE Save system parameters FIRMWARE Firmware upgrade/backup FLASH Create user image in flash PBOOT Auto-run program PROM Dump burner image Operating System Command Description ATTACH Define attachments CONFIG Hardware configuration CPU Display processor loading DEF Display the defined variable #DEFINE Define variable DETACH Clear attachments DI
Parker Hannifin Program Control Command Description AUT Turn off block mode BLK Turn on block mode HALT Halt an executing program LIST List a stored program LISTEN Listen to program output LRUN Run and listen to a program NEW Clear out a stored program PAUSE Activate pause mode REM Program comment RESUME Release pause mode RUN Run a stored program STEP Step in block mode TROFF Turn off trace mode TRON Turn on trace mode Program Flow 68 Command Description BREAK Exit a pro
Parker Hannifin Servo Control Command Description DGAIN Set derivative gain DIN Dead zone integrator negative value DIP Dead zone integrator positive value DWIDTH Set derivative sample period DZL Dead zone inner band DZU Dead zone outer band FBVEL Set feedback velocity FFACC Set feedforward acceleration FFVC Feedforward velocity cutoff region FFVEL Set feedforward velocity FLT Digital filter move IDELAY Set integral time-out delay IGAIN Set integral gain ILIMIT Set integral ant
Parker Hannifin Transformation Command Description FLZ Relative program path shift OFFSET Absolute program path shift ROTATE Rotate a programmed path SCALE Scale a programmed path Velocity Profile 70 Command Description ACC Set acceleration ramp DEC Set deceleration ramp F Set velocity in units/minute FOV Set feedrate override FVEL Set final velocity IVEL Set initial velocity JRK Set jerk parameter (S-curve) LOOK Lookahead mode MBUF Multiple move buffer mode ROV Set rapid f
Parker Hannifin Startup Programs You can set a program to automatically run on powering up or rebooting the controller. The PBOOT command provides that ability. • The PBOOT command must appear as the first statement in a program. • From a terminal, sending the PBOOT command starts all PBOOT programs. • Every PROG and PLC can use PBOOT. Example The following program runs on power-up, flashing output 32.
Parker Hannifin Return to Factory Default Various commands can return specific sections of the ACR controller to factory default. To reset the entire ACR controller, you must issue certain commands in a specific order. 1. Open ACR-View 2. Connect to the controller. 3. Open a Terminal Editor. 4.
Parker Hannifin The wizard makes some choices for you behind the scenes. The ACR9000 has the largest feature set, and typically requires configuration for those features. The ACR1505 and ACR8020 may require different configuration. The Configuration Wizard, once completed, lets you review the code it has generated. In that configuration code, you might find code for features that do not apply to your specific controller.
Parker Hannifin If you do not make any changes to the Memory defaults, the wizard allocates additional memory to programs zero and one. In addition, the wizard allocates memory to program 15, which stores wizard data.
Parker Hannifin The next section is specific to the ACR9000 and currently does not apply to other ACR controllers. The Extended I/O section sets and clears bits related to homing, hardware and software limits, and drive faults—all performed behind the scenes and does not come from user supplied data.
Parker Hannifin AXIS1 IDELAY 0 AXIS1 DGAIN 1e-005 AXIS1 DWIDTH 0 AXIS1 FFVEL 0 AXIS1 FFACC 0 AXIS1 TLM 10 AXIS1 FBVEL 0 REM Axis Limits AXIS1 HLBIT 3 AXIS1 HLDEC 100 SET BIT16176 SET BIT16177 SET BIT16180 SET BIT16181 AXIS1 SLM (24,0) AXIS1 SLDEC 100 CLR BIT16182 CLR BIT16183 DAC1 GAIN 3276.8 AXIS1 ON ATTACH AXIS2 ENC2 DAC2 ENC2 AXIS2 PPU 39999.999404 AXIS2 EXC (0.2,-0.
Parker Hannifin All the unused axes are turned off—this is done directly with the AXIS OFF command rather than using bits designated for this purpose. Turning off the axes reduces CPU load and increases system performance. REM Turn off any unused Axes AXIS3 OFF AXIS4 OFF AXIS5 OFF AXIS6 OFF AXIS7 OFF REM Code Generated by ComACRsrvr Module, File Version: 1.1.2.9 @ Wednesday, March 15, 2006 17:00:43 REM Code Generated from map:program8k v1.1 CodeMap File:C:\WINDOWS\system32\kjconfig.cmp v3.
Parker Hannifin REM the desired master acceleration ACC 20 REM the desired master deceleration ramp DEC 20 REM the desired master stop ramp (deceleration at end of move) STP 20 REM the desired master velocity VEL 10 REM the desired acceleration versus time profile. JRK 0 Resources Reserved for Generated Code The Configuration Wizard reserves controller resources based on the controller, its firmware version, and the features you enable.
Parker Hannifin NOTE: By default, the wizard matches motion profiles to programs of the same number. Because the wizard reserves the Prog7.8k file for the above-mentioned features, the MASTER07 motion profile definition is placed in the Prog08.8k file. If no other programs are defined beyond the Prog08.8k file, the controller continues scanning programs 00-08 without delay. There is no delay executing the Prog08.8k file and MASTER07.
Parker Hannifin 80 • Bits 1976-1983 Drive Disabled Flag Axis 8-15*: Triggered when a drive is faulted (or optionally when motion is killed) and is used by the PLC program to set the Drive Disable output. • Bits 1984-1991 Drive Enable Flag Axis 0-7: Triggered when a drive is faulted or disabled, the flag signals the Drive Enable function to clear the faulted condition and enable the drive.
Parker Hannifin Making Motion Now that the controller is configured, it is ready to make motion. The ACR controller can perform linear, circular, or more complex motion with a single axis or multiple axes. Four Basic Categories of Motion There are four basic categories of motion used in motion control: coordinated, jog, gear, and cam. • Coordinated Moves Profiler (Multi-Axis Profile): Use the MOV command for linear-interpolated incremental and absolute moves.
Parker Hannifin Move Types To command motion, use a command appropriate to the desired type of motion, such as JOG (single-axis profile), CIRCW (TwoDimensional Clockwise Circle), CIRCCW (Two-Dimensional Counter Clockwise Circle), SINE (Sinusoidal Move), or TARC (3-D Arc) The MOV (Define a Linear Move) command activates linear-interpolated motion.
Parker Hannifin Incremental Motion Incremental motion is commanded relative to the current position. To move an incremental distance (a distance “relative” to the current position), use a slash mark ( / ) following the axis. NOTE: The slash mark is only applicable in linear-interpolated motion. Example 1 In this example, the X axis moves an incremental distance of 20 units from its current position. Then the Y axis moves a decremental distance of 30 units from its current position.
Parker Hannifin Example—Incremental Motion The X axis is commanded to the following relative positions: X0 X/-400 X/500 X/200 X/100 Example—Absolute and Relative The X axis is commanded to the following absolute and incremental positions.
Parker Hannifin Combining Types of Motion The user can command multiple types of motion (linear, circular, or sinusoidal) in a single statement. The controller coordinates the motion of all axes in the statement regardless of the type of motion. Example The following illustrates a coordinated move where the X axis performs linear-interpolation and the Y axis performs sinusoidal interpolation.
Parker Hannifin What are Motion Profiles? To make motion, the user must define the motion profile. The acceleration, deceleration, stop ramps, velocity, and distance (ACC, DEC, STP, VEL, and MOV commands, respectively) set the motion profile values. • Acceleration: The ACC (Set Acceleration Ramp) command sets the master acceleration. The master acceleration is used to ramp from lower to higher speeds. The value is in units per second 2 .
Parker Hannifin Motion profile values for each master can be set in two ways: ► Through the Configuration Wizard. ► In a program using the appropriate motion profile statements (ACC, DEC, STP, or VEL). In either case, the program continues to use those motion profile values until new values are commanded. NOTE: Motion profile values in a specific program can be changed from within a different program using the MASTER (Direct Master Access) command.
Parker Hannifin Primary Setpoint All profilers feed their commanded positions to a summation point, and the result is the Primary Setpoint for each axis. See Figure 1. Figure 1 Primary Setpoint Summation In effect, the Jog, Gear, and Cam profilers act as offsets to the Coordinated Motion Profiler. The example below demonstrates the offset concept. Example Suppose an application cuts four diamond shapes from sheets of stock. The program commands motion of axes X, Y, and Z.
Parker Hannifin For the second shape, instead of providing a new set of X and Y coordinates, a jog statement is used to shift the Y axis 3 units. You can then provide the same coordinates used to cut the first shape. The new starting position becomes coordinates (0, 3). JOG ABS Y3 X-2 Y1 X0 Y2 X2 Y1 X0 Y0 To cut the third and fourth diamond shapes, jog statements again shift the starting positions for axes X and Y. After each jog statement, the coordinates of the first shape are reused.
Parker Hannifin The Coordinated Moves Profiler always starts and ends at coordinates (0, 0). With the first shape, there are no JOG, GEAR, or CAM commands, so the setpoint for the X and Y axes is (0,0): For the second shape, the jog statement tells the Jog Profiler to start the Y axis at 3 units.
Parker Hannifin Velocity Profile Commands A basic motion profile for coordinated motion, controlled by an attached master, consists of acceleration, deceleration, stop ramps and a velocity. You can further control coordinated motion using additional velocity profile commands. Axis motion with gear, cam, or jog offsets are controlled solely by their associated commands—for example, CAM OFFSET, CAM SCALE, GEAR ACC, GEAR RATIO, JOG DEC, or JOG JRK.
Parker Hannifin • ROTARY (Set Rotary Axis Length)—sets a rotary axis length used in a shortest-distance calculation. The resulting move is never longer than half the rotary axis length. • TMOV (Time Based Move)—sets the time (in seconds) in which the move is completed. The controller calculates a new master motion profile to complete the move in the specified time. The new motion profile values for acceleration, deceleration, stop ramps, and velocity are no greater than the user-specified values.
Parker Hannifin • PPU (Set Axis Pulse per Unit Ratio)—sets the pulses per programming unit for an axis, allowing convenient units for motion profile such as inches, millimeters, or degrees. The PPU for each axis is independent of that of other axes. Caution —Damage to equipment and/or serious injury to personnel may result if PPU is changed to a value inappropriate to the application.
Parker Hannifin REN Details The REN command copies the actual position from the encoder into the Secondary Setpoint of the servo loop. The values for the Primary Setpoint register and for the Coordinated Moves Profiler’s offset are then calculated backwards from the Secondary Setpoint. This action removes the following error. In the example in Figure 2, the actual position is 11. That number is copied into the register for the Secondary Setpoint, and the Primary Setpoint is then calculated (11).
Parker Hannifin RES Details The RES command is used to zero out the primary setpoint (RES), or to preload positions into the Coordinated Moves Profiler and Actual Position registers (example: RES X10). See Figure 3 for a diagram of the profiler and summation registers for the command RES X10. The values of the Coordinated Moves Profiler, Primary and Secondary Setpoints, and Actual Position registers have been changed to 10. The remaining profilers have been changed to zero.
Parker Hannifin Coordinated Moves Profiler The Coordinated Moves Profiler (formerly called the current position profiler) controls motion for multiple axes using a single set of motion profile values. The MOV command (Define a Linear Move) commands absolute and incremental motion. NOTE: The MOV command is not necessary for coordinated motion. The controller recognizes the axis name and a value as commanded motion, such as X500.
Parker Hannifin Example 1 Two axes are attached to the same master and instructed to move to absolute positions: axis X to 25 millimeters and axis Y to 15 millimeters. All axes start, accelerate, decelerate, and stop together.
Parker Hannifin Example 2 Two axes are attached to the same master, and the program moves one axis to an absolute position: axis X to 25 millimeters. As only axis X is commanded to move, axis Y is not included in the motion trajectory calculation.
Parker Hannifin Jog Profiler Each axis has a dedicated Jog Profiler which can, using a set of motion profile values, control absolute, incremental, or continuous motion for that axis. It can do this independently or in conjunction with the other profilers (Cam, Gear, and Coordinated Moves). NOTE: Multiple axes may be commanded in a single jog statement, such as JOG ABS X500 Y100. The motion is not coordinated. For any application, the controller is first configured for coordinated motion.
Parker Hannifin Example 1 Two axes are set to different acceleration, deceleration, and velocities, and are moved the same distance. JOG JOG JOG JOG ACC DEC VEL INC X1000 Y500 X1000 Y500 X25 Y50 X10 Y10 Figure 4 looks at the commanded motion of the X axis. In the upper graph (velocity motion profile), JOG ACC and JOG DEC determine the acceleration and deceleration values, which always graph as ascending and descending slopes, respectively.
Parker Hannifin Figure 5 looks at the movement for the Y axis, characterized by more gradual slopes for acceleration and deceleration values of 500 in the velocity motion profile (as compared to the X-axis’ values of 1000). Figure 5 Y-Axis Velocity and Position Profiles Again, the straight line between points P1 and P2 on the position motion profile is where the Y-axis movement is a constant velocity.
Parker Hannifin Figure 6 shows the velocity motion profiles for both the X and Y axes superimposed. The Y axis is dashed. Due to a higher JOG VEL value, the Y axis finishes its commanded motion in less time than the X axis. Figure 6 X and Y Velocity Motion Profiles Figure 7 graphs the change in position for the X and Y axes. The Y axis is dashed. The overall slope of the position curve for the Y axis is steeper, reflecting its higher JOG VEL value (JOG VEL X25 Y50).
Parker Hannifin At one second (t 0 + 1.0 sec.), the axis is commanded to decrease speed to the new velocity. See Figure 8 for the velocity profile. Motion ends at t 1. Figure 8 Change in JOG VEL Value “On the Fly” Example 3 To illustrate sequential jog moves, two axes are attached to the same program. The program moves each axis an incremental distance of 10 units using two separate moves.
Parker Hannifin JOG VEL Details Figure 10 shows the bit profiles for the Jog Flags (Bits 792 through 796) as a JOG VEL command is executed.
Parker Hannifin JOG Commands See the ACR Command Language Reference for detailed information, including necessary arguments, on JOG (Single Axis Velocity Profile) and its associated commands: • JOG ABS (Jog to Absolute Position)—uses the current jog settings to jog an axis to an absolute jog offset. • JOG ACC (Set Jog Acceleration)—sets the programmed jog acceleration for an axis. • JOG DEC (Set Jog Deceleration)—sets the programmed jog deceleration for an axis.
Parker Hannifin JOG REN Details The JOG REN command (Transfer Current Position into Jog Offset) clears the Coordinated Moves Profiler of a given axis and adds the difference to the Jog Profiler offset (example: JOG REN X). It can also be used to preload a position into the Coordinated Moves Profiler (adjusting the Jog Profiler to make up the difference) (example: JOG REN X2). In either case, the Gear and Cam profilers and the Primary and Secondary setpoints do not change.
Parker Hannifin The drawing in Figure 12 illustrates JOG REN as it preloads the Coordinated Moves Profiler.
Parker Hannifin JOG RES Details The JOG RES command (Transfer Jog Offset Into Current Position) clears the Jog Profiler offset of a given axis, and adds the difference to the Coordinated Moves Profiler (example: JOG RES X). It can also preload the Jog Profiler offset, and, again, adjusts the Coordinated Moves Profiler to make up the difference (example: JOG RES X2). In either case, the Gear and Cam profilers and the Primary and Secondary setpoints do not change.
Parker Hannifin The drawing in Figure 14 illustrates JOG RES as it preloads the Jog Profiler. Figure 14 JOG RES Preloads the Jog Profiler (JOG RES X2) Gear Profiler The Gear Profiler controls motion for axes needing to match their motion output to some form of input (see SRC command—Set External Timebase—for available sources). The input source is usually external, such as an electronic gearbox, trackball, follower axis, or changes of ratio related to position.
Parker Hannifin Cam Profiler The Cam Profiler controls motion for axes needing precise motion. It uses an array of target points in relation to an externally sourced timebase (see SRC command—Set External Timebase—for available sources). By breaking the motion into discrete target points, the cam arrives at the exact point needed. The Cam Profiler provides linear interpolation between points, regardless of how many points are necessary for the move. All changes in motion are real time.
Parker Hannifin NOTE: Relevance of positive and negative direction— NOTE: If an end-of-travel limit is encountered during the homing operation, motion is reversed and the home switch is sought in the opposite direction. If a second limit is encountered, the homing operation is terminated, stopping motion at the second limit. NOTE: For homing operations, always use the clock as the source of the Jog Profiler.
Parker Hannifin JOG VEL X10 Y10 : REM Set axes jog parameters used during homing JOG ACC X100 Y100 JOG DEC X100 Y100 HLBIT X0 Y3 : REM X uses 1Home (input2), Y uses 2Home (input5) HLIM X3 Y3 : REM enable EOT limit checking for box axes JOG SET SET CLR CLR CLR HOMVF 16144 16176 16152 16153 16154 X0.1 Y0.
Parker Hannifin Figures A and B show the homing operation when the Home Backup Enable, Home Negative Edge Select, and Home Negative Final Direction bits are clear (Quinary Axis Flags, Bit16128-Bit16639). Figure A Homing Profile Attributes: • JOG HOME X1 • Home Backup Enable (bit index 24) is clear. • Home Negative Edge Select (bit index 25) is clear. • Home Negative Final Direction (bit index 26) is clear.
Parker Hannifin Positive Homing (Homing Backup Enabled) Figures C through F show the homing operation when the Home Backup Enable bit is set (parameters 4600-4615). The seven steps below describe a sample homing operation, as illustrated in Figure C. Figures D through F show the homing operation for different values of the Home Negative Edge Select and Home Negative Final Direction bits—the Home Backup Enable bit is set. 1.
Parker Hannifin Figure D Homing Profile Attributes: • JOG HOME X1 • Home Backup Enable (bit index 24) is set. • Home Negative Edge Select (bit index 25) is set. • Home Negative Final Direction (bit index 26) is clear. Figure E Homing Profile Attributes: • Figure F JOG HOME X1 • Home Backup Enable (bit index 24) is set. • Home Negative Edge Select (bit index 25) is clear. • Home Negative Final Direction (bit index 26) is set.
Parker Hannifin Negative Homing (Homing Backup Enabled) Figures G through J show the homing operation for different values of the Home Negative Edge Select and Home Negative Final Direction bits—the Home Backup Enable bit is set. Figure G Homing Profile Attributes: • Figure H • Home Backup Enable (bit index 24) is set. • Home Negative Edge Select (bit index 25) is set. • Home Negative Final Direction (bit index 26) is set.
Parker Hannifin Figure I Homing Profile Attributes: • JOG HOME X-1 • Home Backup Enable (bit index 24) is set. • Home Negative Edge Select (bit index 25) is set. • Home Negative Final Direction (bit index 26) is clear. Figure J Homing Profile Attributes: • JOG HOME X-1 • Home Backup Enable (bit index 24) is set. • Home Negative Edge Select (bit index 25) is clear. • Home Negative Final Direction (bit index 26) is clear.
Parker Hannifin Limit Detection The Configuration Wizard assists with setting up the Hardware and Software Limits Detection. When limits are enabled, motion stops when the load encounters a limit. If the load hits a hardware limit, motion stops at the rate set by the HLDEC; if the load hits a software limit, motion stops at the rate set by the SLDEC. Dedicated I/O for Homing For each axis, the user can assign which inputs are used for positive and negative hardware limits, and the input used for homing.
Parker Hannifin NOTE: There are no restrictions regarding how to assign hardware limits and homing inputs. However, you should exercise caution because it is possible to create imaginary limit and home inputs. This is because the controller assumes all three inputs are in the same multiple of 32 bits. The assignment of inputs does not roll over to the next block of 32 bits. For example, if the positive hardware limit is assigned to input 31, the negative hardware limit and homing inputs are not assigned.
Parker Hannifin Servo Loop Fundamentals Each of the profilers contains a register with a value of the current offset. These values are added together and the summation is called the Primary Setpoint (PSP). PSP = Coordinated Moves + Jog + Gear + Cam See Figure 15 for a diagram of the Primary Setpoint summation.
Parker Hannifin The information up to and including the SSP is the commanded position. See Figure 16. Figure 16 Secondary Setpoint Summation Viewing the Setpoint Calculations Servo loop calculations for the actual position of an axis can be observed in ACR-View. The Servo Loop Status window shows the motion offsets, primary and secondary setpoints, servo gains and other values, and how they result in the final position output. ► In the Project Workspace, click Status Panel, then click Servo Loop Status.
Parker Hannifin Figure 17 Following Error 122 Programmer’s Guide
Parker Hannifin Binary Host Interface You can enhance communications with the ACR series controller through the binary host interface. Binary Data Transfer The binary data transfers in this chapter consist of a control character ( Header ID ) followed by a stream of data encoded according to the current state of the MODE command. Note that regardless of the mode, the Header ID is never converted during binary data transfer.
Parker Hannifin Receiving When receiving control prefix encoded data, a '#' character is thrown away and causes the next character to be read from the data stream. If the character is in the range of 0x3F to 0x5F, the character is 'XORed' with 0x40 to decode the true value. Otherwise, the character is used exactly as read from the stream. High Bit Stripping High bit stripping follows Kermit communications protocol conventions for 7-bit data paths.
Parker Hannifin Binary Data Packets Packets allow binary access to system parameters at any time. This method must be used if commands are sitting in the input queue since PRINT statements would also be buffered. The packet is the quickest way to access information such as current position and following error for display in an application program. Packet Request Packets are requested by sending a four-byte binary request record.
Parker Hannifin Parameter Access The following is a list of groups and what the isolation mask will isolate: Group Description Isolation Usage 0x10 Flag Parameters Eight consecutive parameters 0x18 Encoder Parameters ENC0-ENC15 0x19 DAC parameters DAC0-DAC7 0x1A PLC parameters PLC0–PLC7 0x1B Miscellaneous Eight consecutive parameters 0x1C Program Parameters PROG0 - PROG15 0x20 Master Parameters MASTER0 - MASTER7 0x28 Master Parameters MASTER8 - MASTER15 0x30 Axis Parameters AXI
Parker Hannifin Long integers (LONG) are returned as a four-byte field. Floating point numbers (FP32) are returned in 32-bit IEEE floating-point format. Both types of field are returned with the low order byte first.
Parker Hannifin Usage Example This example requests current position from axis 0 parameter P12288: Fields: Header Parameter Value Output: 00 88 00 30 Input: 00 88 00 30 10 11 12 00 Current Position Parameter Value: AXIS0: 0x00121110 Binary Get Long This packet gets a single parameter from the card. The parameter index is a 2-byte value sent low-order byte first. The parameter value in the receive packet is a 4-byte long integer received low-order byte first.
Parker Hannifin Receive Packet None. Binary Get IEEE This packet gets a single parameter from the card. The parameter index is a 2-byte value sent low-order byte first. The parameter value in the receive packet is a 4-byte image of an IEEE floating point number received low-order byte first.
Parker Hannifin Binary Peek Command A binary peek command consists of a four-byte header followed by an address and the data to be fetched from that address. The header contains a data conversion code that controls pointer incrementing and theFP32 -> IEEE floating point conversion. Note: Refer to Binary Global Parameter Access Note at end of Binary Host Interface section for details. The command returns the header and peek address followed by the requested data.
Parker Hannifin Usage Example NOTE: Addresses shown are for example only. Addresses will vary from card to card, depending on system memory allocation.
Parker Hannifin Receive Packet None. Conversion Codes Code Source Destination 0x00 LONG LONG 0x01 IEEE32 FP64 0x02 IEEE32 FP32 Usage Example NOTE: Addresses shown are for example only. Addresses will vary from card to card, depending on system memory allocation.
Parker Hannifin Binary Address Packet Transmit Packet Data Field Description Byte 0 Header ID ( 0x00 ) Byte 1 Packet ID ( 0x92 ) Byte 2 Program Number Byte 3 Parameter Code Receive Packet Data Field Description Byte 0 Header ID ( 0x00 ) Byte 1 Packet ID ( 0x92 ) Byte 2 Program Number Byte 3 Parameter Code Long 0 Parameter Address Parameter Codes Code Mnemonic Description 0x00 DV Double Variables 0x01 DA Double Arrays 0x02 SV Single Variables 0x03 SA Single Arrays 0x04
Parker Hannifin Binary Parameter Address Command A binary parameter address command consists of a four-byte header containing a parameter index. The command returns the header followed by the address of the parameter. If the returned address is zero, the parameter index was invalid.
Parker Hannifin Binary Mask Command A binary mask command consists of a four-byte header followed by an address and two bit masks to be combined with the data at that address. There is no information returned from this command. The address must point to a long integer storage area. The NAND mask is used to clear bits and the OR mask is used to set bits.
Parker Hannifin Binary Parameter Mask Command A binary parameter mask command consists of a four-byte header followed by two bit masks to be combined with a system parameter. There is no information returned from this command. The parameter index in the header must be a long integer. The NAND mask is used to clear bits and the OR mask is used to set bits.
Parker Hannifin Binary Move Command A binary move consists of a variable length header followed by a number of four-byte data fields. The bit-mapped information in the header determines the number of data fields and their content. All data fields are sent low order byte first.
Parker Hannifin There are two versions defined for Header Code 0 based on Secondary Master Flag Bit Index 5, Enable Rapid Move Modes. The default-disabled mode for this flag (Secondary Master Flag Bit Index 5 cleared) uses the following Header Code 0 definition. This Header Code 0 definition is compatible with ACR2000/ACR8000 Firmware Versions 1.17.04 and below, and is compatible with all AcroCut/AcroMill software versions.
Parker Hannifin Header Code 1 Data Field Data Type Description Bit 0 Master Bit 0 Master for this move packet Bit 1 Master Bit 1 Bit 2 Master Bit 2 Bit 3 Interrupt Select Interrupt host when move starts Bit 4 Arc Direction CCW if set, else CW Bit 5 Arc Mode Packet contains center points or Spline Knot present Bit 6 Arc Plane Bit 0 Primary and secondary axis or NURB Mode Bit 7 Arc Plane Bit 1 For binary arc move commands or SPLINE Mode Header Code 2 Data Field Data Type Descriptio
Parker Hannifin Header Code 4 Data Field Data Type Description Bit 0 Reserved Reserved Bit 3 Master Bit 3 Master for this move packet Bit 4 Reserved Reserved Data Field Data Type Description Bit 0 Reserved Reserved Data Field Data Type Description Bit 0 Slave 8 Present Slave target positions to be contained Bit 1 Slave 9 Present Bit 2 Slave 10 Present Bit 3 Slave 11 Present Bit 4 Slave 12 Present Bit 5 Slave 13 Present Bit 6 Slave 14 Present Bit 7 Slave 15 Present Bit
Parker Hannifin Header Code 7 Data Field Data Type Description Bit 0 Reserved Reserved Bit 1 Bit 2 Bit 3 Bit 4 Bit 5 Bit 6 Bit 7 The following Move Modes definition applies to Header Code 0 used with the Master Enable Rapid Move Modes flag set.
Parker Hannifin Example 2 The following illustrates Move Mode 1—Feed Cornering: Example 3 The following illustrates Move Mode 2—Feed Stopping: 142 Programmer’s Guide
Parker Hannifin Example 4 The following illustrates Move Mode 3—Rapid: Linear Moves The bits in header code 2 indicate which target positions are contained in the binary move packet. If the "incremental target" bit in header code 3 is set, the targets are relative to the current target positions of the slaves; otherwise, the targets are absolute. The "floating point data" bit in header code 3 indicates that the target data is in IEEE floating point format, otherwise they are long integers.
Parker Hannifin The "arc direction" bit in header code 1 indicates the direction of the arc relative to the primary and secondary axes. A counterclockwise arc is defined as an arc from the positive primary axis toward the positive secondary axis. The radius of the arc will be equal to the distance between the arc target position and the given center point. If the arc target position is equal to the target position of the previous move, a 360-degree path will be generated.
Parker Hannifin Binary CLR Data Type Description Byte 0 Header ID ( 0x1D ) Byte 1 Index Byte 0 Byte 2 Index Byte 1 Byte 3 0x00, this byte is for ACR8020 DPCB only. Usage Example Binary Output Description 1C 08 02 Set bit 520 ( 0x0208 ) 1D 20 00 Clear bit 32 ( 0x0010 ) Binary FOV Command The immediate setting of feedrate override for any or all axes can be accomplished with an 8-byte binary command sequence. This sequence is a 4-byte command header followed by a 4-byte FOV value.
Parker Hannifin Data Type Description Bit 1 Master 1 Affected Bit 2 Master 2 Affected Bit 3 Master 3 Affected Bit 4 Master 4 Affected Bit 5 Master 5 Affected Bit 6 Master 6 Affected Bit 7 Master 7 Affected NOTE: Masters affected by the FOV contained in this command.
Parker Hannifin Usage Example This example uses the following IEEE conversions: 0.500 = 3F000000 0.123 = 3DFBE76D Binary Output Description 07 08 00 00 00 00 00 3F Set Master 3 FOV to 0.5 07 05 00 00 6D E7 FB 3D Set Master 0 and Master 2 FOV to 0.123 Binary ROV Command (Version 1.17.05 & Up) The immediate setting of rapid feedrate override for any or all axes can be accomplished with an 8-byte binary command sequence. This sequence is a 4-byte command header followed by a 4-byte ROV value.
Parker Hannifin Header Bit Mask Data Type Description Bit 0 Master 0 Affected Bit 1 Master 1 Affected Bit 2 Master 2 Affected Bit 3 Master 3 Affected Bit 4 Master 4 Affected Bit 5 Master 5 Affected Bit 6 Master 6 Affected Bit 7 Master 7 Affected NOTE: Masters affected by the ROV contained in this command.
Parker Hannifin Usage Example This example uses the following IEEE conversions: 0.500 = 3F000000 0.123 = 3DFBE76D Binary Output Description 07 08 00 00 00 00 00 3F Set Master 3 ROV to 0.5 07 05 00 00 6D E7 FB 3D Set Master 0 and Master 2 ROV to 0.123 Application: Binary Global Parameter Access Also see Binary Peek and Binary Poke commands. Description Global user variables (see Variable Memory Allocation) can be read and set using the Binary Peek and Poke Command interface.
Parker Hannifin Even though global variables are stored on-board as floating point 64 (FP64) numbers, they are returned as IEEE32 numbers (Conversion Code 0x01). Setting Global Variables Peek at the System Pointer Address (see System Pointer Address on previous page) to receive the Global_Variable_Address. • If the returned address is zero, there are no dimensioned global variables (see the DIM command).
Parker Hannifin Additional Features CANopen The CANopen feature on ACR series controllers provides standardized network communication and flexible configuration for motion control.
Parker Hannifin other words, each I/O bit is controlled by only one flag. In addition, this table represents the maximum amounts of I/O that can appear at XIO flag parameters 4104-4111. For example, if P32771= 1 and Node 0 only has 32 physical inputs and outputs, only flag parameters 4104 and 4105 have meaning. Semi-Automatic Network Configuration The network configuration is as automatic as possible, but the user must adjust some settings.
Parker Hannifin For available bit rates and constraints of bus length, see the CiA Draft standard 301, version 4.02, table 2. The default bit rate is 125Kbit/second. Bit rate and master node numbers are saved with the ESAVE command. Transmission Cycle Period ACR9000 uses a periodic cyclic transmission protocol between the master and the nodes for digital and analog outputs, and for analog inputs. Digital inputs transmit to the ACR9000 only when their input state has changed.
Parker Hannifin node of the example above, and the timing in the table below, the time using a PIO-347 would be 12 milliseconds, and using a PIO-337 would be two milliseconds.
Parker Hannifin • Check for success and any other status of interest. For example, application operation may depend on I/O present, or expected I/O may be verified. • Proceed with application that depends on external I/O AcroBASIC Language Access to CANopen I/O All “objects” (for example steppers, encoders, axes, and masters) in an ACR controller may be accessed via bits and parameters as well as commands.
Parker Hannifin Field Description Read/ Write Start Network R/W Description When set, this flag will attempt to communicate with the CANopen network. This flag is automatically cleared by the controller when the attempt to start the network has completed. See the section on “Starting and Configuring the Network” for more details. Reset Network R/W When set this flag will reset all of the Extended I/O nodes.
Parker Hannifin The description and parameter numbers are shown in the following table. The control parameters are those that should be set before attempting to start the network. The status parameters are those that the controller will set because of attempting to start the network.
Parker Hannifin Read/ Write Field Description Number of Digital R Output Bytes Description The total number of bytes (1 byte = 8 bits) taken for digital outputs on the network. Number of Analog R inputs The total number of analog inputs on the network. Number of Analog R Outputs The total number of analog outputs on the network. Bus State R Indicates the current bus state. See the next page for more detail on what this value means.
Parker Hannifin The Bus State Description table below gives the possible bus states and the corresponding CAN LED indicator state. The only normal states are “READY TO START” and “NETWORK STARTED”. Any red in the CAN LED indicates a problem. Bus State Description (parameter P32779) Bus State CAN LED State PRE-INITIALIZED. The network has not been 0 off 1 Blinking Green NETWORK STARTED. Successful network start. 2 Solid Green INVALID MASTER NODE ID.
Parker Hannifin The Node ID must be set by the user to match the node ID settings on the actual nodes. All other node information is filled in by the controller after the network is started. The node information is saved with the ESAVE command, and user applications may use it to verify expected network configuration, or make run time application decisions. This information could serve as a source for a front-end software GUI that displays bus and node status, although no configuration would be possible.
Parker Hannifin Flags for Extended Digital I/O Each possible node will have two blocks of flag parameters, each 16 parameters in length, to accommodate the possible 512 bits each of extended digital inputs and outputs. Flag parameter numbers are shown the table below.
Parker Hannifin For example a 0-10V DAC would take values of 0-32767, and a ±10V device would take values of –32768 to 32767. However, a ±5V device would also take values of –32768 to 32767. To translate from this raw binary number to the range and units being controlled or measured, ACR9000 employs entered offsets and gains.
Parker Hannifin DAC Parameter/DAC number 0 1 … 31 DAC Output Value P33280 P33296 … P33776 Reserved P33281 P33297 … P33777 DAC Gain P33282 P33298 … P33778 DAC Offset P33283 P33299 … P33779 Reserved P33284 P33300 … P33780 Reserved P33285 P33301 … P33781 Reserved P33286 P33302 … P33782 Reserved P33287 P33303 … P33783 ADC Parameter/ADC number 0 1 … 31 ADC Input Value P33288 P33304 … P33784 Reserved P33289 P33305 … P33785 ADC Gain P33290 P33306 … P
Parker Hannifin and two analog outputs (0 to 10 VDC). They are both configured at a bit rate of 1 Mb. The example shows the required setup, and how to use the data in a very basic program.
Parker Hannifin Communication The Axis connectors provide an RS-485 communication interface to the drive through the COM2 port. Parker drives supporting Drive Talk automatically detect RS-232/485 on power up; therefore, the drives must be connected to ACR series controller before being powered up. Otherwise, the drives set the communication interface as RS-232.
Parker Hannifin Enabling Auto-Addressing ► To enable auto-addressing, set the “Auto Address Request” bit (bit index 0, Drive Talk Drive-Control Flags). Drive Control Flags The “Drive Talk Drive Control Flags” let you get and send configuration data, set up the Aries error log, and retrieve status data. NOTE: All Drive Talk control bits are self-clearing. To perform an action one time, set the control bit. When the bit is cleared, the action is complete or the action has timed out.
Parker Hannifin Drive Status Flags You can get status data of an Aries drive. On power up the controller does not contain drive status data. In the “Drive Talk DriveControl Flags” (bit index 8-25) you can select what status data the controller gets. Then set the “Get Drive Data Request” bit (bit index 4) to retrieve the status data. The controller stores the drive status data in the “Drive Talk Parameters”.
Parker Hannifin Example The following example demonstrates the set up for two axes with Aries drives: OPEN DTALK “COM2:9600,N,8,1” AS #1 REM OPEN PORT P28672=1 : REM SET DEVICE NUMBER FOR DRIVE 1 P28928=1 : REM SET DEVICE NUMBER FOR DRIVE 2 P28673=0 : REM SET DRIVE TALK AXIS1 TO ARIES DRIVES P28929=0 : REM SET DRIVE TALK AXIS2 TO ARIES DRIVES CLR 11122 : REM RESET TIMEOUT CLR 11123 : REM RESET TIMEOUT CLR 11124 : REM RESET TIMEOUT SET 10505 : REM GET TPE AXIS0 USING GET DRIVE DATA SET 10500 : REM UPDATE D
Parker Hannifin DTALK command from a terminal. For more information, see DTALK in the ACR Command Language Reference. Once in “pass through” mode, you can communicate with an Aries drive using its native command language. NOTE: You can only use the DTALK command to set the controller into the “pass through” mode. Subsequent communication with the Aries drive is performed through a terminal, using the Aries command language. Do not use the DTALK command in a ACR controller program or PLC.
Parker Hannifin Exiting “Pass Through” Mode Exiting the “pass through” mode and closing the Drive Talk session are two distinct acts. Though you exit the “pass through” mode, the Drive Talk session remains open. See the section titled Closing Drive Talk (above). ► To exit the “pass through” mode from the terminal, send the escape character (ASCII 27). Inverse Kinematics Kinematics is a branch of mechanics that provides a mathematical means of describing motion.
Parker Hannifin • Use the PASSWORD command to protect the program from uploading or listing. • Include the INVK commands in a program, or in the setup before a program. Example The following program results in a circle instead of a straight line because of the transformation described in program 7 (PROG7).
Parker Hannifin Troubleshooting When a system does not function as expected, the first thing to do is identify and isolate the problem. When this is accomplished, steps may be taken toward resolution. Problem Isolation The first step is to isolate each system component and ensure that each component functions properly when it is run independently. This may require dismantling the system and putting it back together piece by piece to detect the problem.
Parker Hannifin Troubleshooting Table This section includes a table of common problems and their solutions. For locations of the ACR90x0 controllers’ status LEDs, and for non-problem indications, see Chapter 2, Specifications, in the ACR9000 Hardware Installation Guide. Table 1 in this chapter only lists problem LED indications. PROBLEM CAUSE / VERIFICATION SOLUTION There is no power to the controller. Check for disconnected power cable.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION Axis status LED is not Axis is disabled with no fault (normal state for Enable drive. on steppers or servo motors). Axis Status LED Axis status LED is red Axis fault. Motion on this axis is disabled during a Check for faulted drive. Enable drive. (Refer to Operation fault state. section of this table.) NOTE: The LED illuminates red whenever the drive Check for axis cable disconnected.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION No Ethernet link is detected. Check for the correct type of cable. EPL Status LED EPL link/activity: yellow LED is off Verify the cable pinout matches the ACR90x0. (See the section “Ethernet and ETHERNET Powerlink Connectors” in Chapter 2, Specifications, of the ACR9000 Hardware Installation Guide.) Ethernet speed: green Ethernet port is getting intermittent 10Mbps and Verify the Ethernet card in the PC is functioning correctly.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION Ethernet Communication Communication Error: Using straight through (patch) Ethernet cable. Change to a crossover Ethernet cable. Using crossover Ethernet cable through router/hub. Change to a straight through Ethernet cable. Wrong computer IP address and/or subnet mask. Change IP address of computer in Ethernet card settings. Same IP address as ACR9000. Change IP address of computer in Ethernet card settings.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION Excess position error (EXC). (Motor has exceeded Increase the EXC setting. maximum position error.) Verify by checking Status Panels Æ Bit Status Æ Axis Flags Æ Primary Axis Flags. (Each axis is indicated by Bit “Not Excess Error.”) Drive will enable, but Incorrect configuration for motor attached. will not hold torque Correct the configuration for servo or stepper through the Configuration Wizard. Servo motor running open loop.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION Drive will enable, but Stepper output motion does not occur. ACR Correct configuration for stepper through Configuration Wizard. motor will not move controller not configured for stepper output in Tuning gains must remain at default values: PGAIN Configuration Wizard. 0.002441406; IGAIN, ILIMIT, IDELAY, DGAIN, DWIDTH, FFVEL, FFACC, and TLM=0. Axis encountered limits.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION Torque Limit is set to zero. Assign the appropriate Torque Limit value. Verify Torque Limit setting by Status Panels Æ Example: TLM X1 indicates torque is limited to 10% of drive Numeric Status Æ Axis Parameters Æ Limit motor capacity for axis X. Parameters Æ Plus/Minus Torque Limit Improper operation Feedback device counts are missing Check the feedback cable and connections. Check the amplifier to send back correct signals.
Parker Hannifin PROBLEM CAUSE / VERIFICATION SOLUTION Motion stops Axis has encountered soft limits. Jog off the limit. Clear the appropriate Positive/Negative Soft unexpectedly Verify: Status Panels Æ Bit Status Æ Axis Flags Æ Limit Encountered Bit. Clear the associated Master Kill All Quinary Axis Flags. (Each axis is indicated by Bit Moves Request Bits. “Positive/Negative Soft Limit Encountered.
Parker Hannifin Error Handling This section on error handling addresses error checking and recovery, which is to be programmed into each application. Error handling is then done automatically as the application runs, and is helpful in diagnosing problems. Sample Program (ACR90x0) The following is an example error handling routine for the ACR90x0 with firmware revision 1.18.15 and above. It was written to handle possible axis, CANopen, and Motion Enable Input error conditions.
Parker Hannifin ' This software program is provided free of charge and without ' warranty of any kind, either expressed or implied. In no event ' will PARKER HANNIFIN CORPORATION be liable for any damages, ' including but not restricted to lost profits, lost savings, or ' component failure arising out of the use or inability to use this ' software program. The sole purpose of this program is to ' demonstrate the functional application of the customer’s desired ' application.
Parker Hannifin #DEFINE MEIErrorCode P50 #DEFINE CANopenErrorCode P51 #DEFINE XErrorCode P52 #DEFINE YErrorCode P53 REM additional variables used to determine when the error occurred #DEFINE Time LV0 #DEFINE ms LV1 #DEFINE seconds LV2 #DEFINE ExcSeconds LV3 #DEFINE minutes LV4 #DEFINE ExcMinutes LV5 #DEFINE hours LV6 #DEFINE ExcHours LV7 #DEFINE days LV8 PROGRAM PBOOT : REM program will execute when controller power is turned on REM dimension some string variables for error message REM storage/display and i
Parker Hannifin REM flag (bit 5645) INH -5647 : REM wait until request has finished REM Clear axis KAMR flags CLR XKillAllMotion CLR YKillAllMotion $V0 = "Motion Enable Input is good" ENDIF REM - Check CANopen (PIO) status (only needed if using CANopen I/O) IF (P32779 > 0) IF (P32779 = 2) $V1 = "CANopen status is good" CANopenErrorCode = 0 ELSE IF (P32779 = 1) $V1 = "CANopen is ready to start (SET 11265)" CANopenErrorCode = 0 ELSE IF (P32779 > 2 AND CANopenErrorCode = 0) REM prevents recursive error display
Parker Hannifin IF (YPosSoftEOT AND YErrorCode <> 1) INH -824 Set ErrorOccurred YErrorCode = 1 $V3 = "Positive Software End-of-travel hit, Axis 1" CLR YPosSoftEOT : REM EOT flag is automatically cleared, REM but we clear it to prevent recursive REM printing of error INH -YPosSoftEOT CLR KillMasterMoves ENDIF IF (YNegSoftEOT AND YErrorCode <> 2) INH -824 Set ErrorOccurred YErrorCode = 2 $V3 = "Negative Software End-of-travel hit, Axis 1" CLR YNegSoftEOT : REM EOT flag is automatically cleared, REM but we cle
Parker Hannifin REM --------- Excess position error ---------IF (XExcessErrorFault) XErrorCode = 5 $V2 = "Axis 0 disabled due to excess position error" CLR XExcessErrorFault ENDIF REM -- Use only for servo axes !!! Encoder Signal Lost or Fault IF (NOT XDriveEnabled AND (XErrorCode = 0) AND (XEncoderFault OR XEncoderLost)) XErrorCode = 6 $V2 = "Axis 0 disabled due to encoder fault" ENC 0 RES : REM try to reset encoder ENDIF REM if none of the errors above, then possible Drive Fault REM Input caused error.
Parker Hannifin REM --------- Hardware EOT's --------IF (YPosHardEOT) YErrorCode = 3 $V3 = "Positive Hardware End-of-travel hit, Axis 1" CLR YPosHardEOT : REM EOT flag is not automatically REM cleared, program must clear it ENDIF IF (YNegHardEOT) YErrorCode = 4 $V3 = "Negative Hardware End-of-travel hit, Axis 1" CLR YNegHardEOT : REM EOT flag is not automatically REM cleared, program must clear it ENDIF REM --------- Excess position error -----------IF (YExcessErrorFault) YErrorCode = 5 $V3 = "Axis 1 disabl
Parker Hannifin REM --------- Print error out comm1 to terminal --------IF (ErrorOccurred) REM Print time since controller power on or reset GOSUB CheckTime IF (MEIErrorCode > 0) PRINT #1, "MEI Error ";MEIErrorCode;" -> ";$V0 REM Motion Enable Input status ENDIF IF (CANopenErrorCode > 0) PRINT #1, "CANopen Error ";CANopenErrorCode;" -> ";$V1 REM CANopen status ENDIF IF (XErrorCode > 0) PRINT #1, "Axis 0 Error ";XErrorCode;" -> ";$V2 : REM Axis 0 REM status ENDIF IF (YErrorCode > 0) PRINT #1, "Axis 1 Error "
Parker Hannifin ExcMinutes = minutes MOD 60 REM extract the hour portion REM remove excess minutes and convert to full hours hours = (minutes - ExcMinutes) /60 REM remove any hours less than a full day ExcHours = hours mod 24 REM only full days are left. Only works up to <25 days.
Parker Hannifin Appendix The appendix contains supplemental materials not directly related to any specific ACR series controller discussion. IP Addresses, Subnets, & Subnet Masks The factory assigns an IP address of 192.168.10.40 and a subnet mask of 255.255.255.0 to each controller. Before adding the controller to your network, assign it an IP address and subnet mask appropriate for your network. Caution —Talk with your Network Administrators before assigning an IP address or subnet mask to a controller.
Parker Hannifin The address consists of a network ID and a host ID. The network ID acts as a general address, like a zip code; The host ID is the address for a specific device within the network, like a home address. Most IP addresses fall into one of the following address classes: • Class A range. The first 8 bits are for the network ID; The remaining 24 bits are for the host ID. • Class B range. The first 16 bits are for the network ID; The remaining 16 bits are for the host ID. • Class C range.
Parker Hannifin Suppose you have 6 computers in a class C network. All share the same network address 192.168.10. in the first three octets. The final octet for each computer is different, and represents the host ID. Some addresses are reserved for private networks or intranets, where networks are masked or protected from the Internet: 10.0.0.0 to 10.255.255.255 172.16.0.0 to 172.31.255.255 192.168.0.0 to 192.168.255.
Parker Hannifin To provide another level of addressing, some of the host ID is borrowed to create a subnet ID. The subnet ID allows you to logically group devices together (often related to a specific network segment). Once data arrives at the network, the subnet ID allows routers or host devices to locate the appropriate network segment, and then the host. Suppose you have a class C network, comprised of 6 computers. All share the same network ID 192.168. but are divided into two subnets.
Parker Hannifin What subnet mask to use depends on your network configuration, and address class. Where the host ID appears in the IP address, use a zero in the subnet mask. And where the network ID and subnet ID appear, use 255 in the subnet mask. Suppose on network 172.20.0.0 (class B) you have to set up a new computer. You assign it 172.20.44.180 as the IP address. As a class B network, the first two octets are reserved for the network ID.
Parker Hannifin Output Module Software Configuration Examples The following commands are used to configure the ACR1200, ACR1500, ACR2000, ACR8000, ACR8010 output modules for operation: ► CONFIG tells the control what type of output module is installed. ► ATTACH AXIS attaches the axis to signal output and feedback. ► ESAVE saves the axis attachments.
Parker Hannifin Example 3 The following example configures an eight axis ACR8010 board for two closed-loop servos with two commutator and two open-loop steppers (one DAC output module and one stepper output module): CONFIG ENC4 DAC4 STEPPER4 NONE ATTACH AXIS0 ENC0 CMT0 ENC0 ATTACH AXIS1 ENC2 CMT1 ENC2 ATTACH AXIS4 STEPPER4 STEPPER4 ATTACH AXIS5 STEPPER5 STEPPER5 ATTACH AXIS6 STEPPER6 STEPPER6 ATTACH AXIS7 STEPPER7 STEPPER7 AXIS2 OFF AXIS3 OFF CMT0 ENC0 ENC1 CMT0 DAC0 DAC1 CMT1 ENC2 ENC3 CMT1 DAC2 DAC3 Ex
Parker Hannifin Example 6 The following example configures a four axis ACR1500 with two on-board DAC outputs for two closed loop servos. Also included on the board is an analog input module (ADC input module). NOTE: On the ACR1200 card, the attach axis statements for AXIS3 through AXIS7 must be left in the default configuration to ensure proper operation.
Parker Hannifin Index AcroBASIC commands ............................. 48 syntax ................................... 44 aliases bits .................................. 43, 58 constants ............................... 43 DEFINE .................................. 43 parameters........................ 43, 58 variables ................................ 43 attachments axis attaching ....................... 33, 34 names ................................ 38 masters ................................. 35 attaching ...
Parker Hannifin overview ...............................110 subroutine.............................112 I/O hardware limits ....................... 29 homing limit ........................... 29 LED troubleshooting....... 173, 174, 175 limits hardware ............................... 30 enable ................................ 31 input assignment ................. 29 homing .................................110 software................................. 31 enable ................................ 32 positions....