background image

Trajexia motion control system

TJ1-MC04
TJ1-MC16

programming manual

Cat. No. 
I52E-EN-03

Austri

Tel: 

+43 (0) 

1 80 

19 00 

www.omr

on.at 

Bel

gium 

Tel: 

+32 (0) 

2 466 

24 80 

www.omr

on.be 

Czec

h R

epub

lic 

Tel: 

+420 234 

602 602 

www.omr

on.cz

 

Denm

ark 

Tel: 

+45 43 

44 00 

11 

www.omr

on.dk

 

Finland 

Tel: 

+358 (0) 

207 464 

200

www.omr

on.fi 

Franc

Tel: 

+33 (0) 

1 56 

63 70 

00

www.omr

on.fr 

German

Tel: 

+49 (0) 

2173 680 

00 

www.omr

on.de 

Hung

ary 

Tel: 

+36 (0) 

1 399 

30 50 

www.omr

on.hu 

Italy

 

Tel: 

+39 02 

32 68 

777 

www.omr

on.it 

Middl

e Ea

st & 

Africa

Tel: 

+31 (0) 

23 568 

11 00

www.omr

on-industri

al.c

om

Netherland

Tel: 

+31 (0) 

23 568 

11 00 

www.omr

on.nl 

Norw

ay 

Tel: 

+47 (0) 

22 65 

75 00 

www.omr

on.no 

Pol

and 

Tel: 

+48 (0) 

22 645 

78 60 

www.omr

on.pl 

Por

tug

al 

Tel: 

+351 21 

942 94 

00 

www.omr

on.pt 

Rus

sia 

Tel: 

+7 495 

745 26 

64 

www.omr

on.ru 

Spain 

Tel: 

+34 913 

777 900 

www.omr

on.es

 

Sweden 

Tel: 

+46 (0) 

8 632 

35 00 

www.omr

on.se 

Switz

erland 

Tel: 

+41 (0) 

41 748 

13 13 

www.omr

on.ch 

Turk

ey 

Tel: 

+90 (0) 

216 474 

00 40 

www.omr

on.com.

tr

United 

Kingdom 

Tel: 

+44 (0) 

870 752 

08 61 

www.omr

on.co

.uk 

OMRON

 EUROPE

 B.V.

   W

egal

aan 67-69, NL-2132 JD

, Hoofddorp

, The Netherl

ands.   

Tel: +31 (0) 23 568 13 00   F

ax: +31 (0) 23 568 13 88   www.omr

on-industri

al.c

om 

Au

th

ori

se

d D

ist

rib

uto

r:

Note:

Although w

e do striv

e for per

fection, Omr

on Eur

ope BV and/or its

 sub

sidi

ary and affi

liat

ed comp

anies do not

 warr

ant or m

ake an

y repr

esent

ations r

egar

ding the c

orrect

ness

 or comp

let

eness

 

of inf

ormation de

scribed in thi

s c

atalogue. Pr

oduct inf

ormation in thi

s c

atalogue i

s pr

ovided ‚a

s is‘ w

ithout w

arranty

 of an

y k

ind, either expr

ess

 or implied, inc

luding, b

ut not

 limited t

o, the 

implied w

arrantie

s of

 merch

antab

ility

, fitne

ss f

or a par

ticul

ar purpo

se, or non-infringement

. In a jurisdiction wher

e the exc

lusion of

 implied w

arrantie

s is

 not v

alid, the exc

lusion sh

all be 

deemed to be r

eplac

ed by s

uch 

valid e

xclu

sion, whic

h most

 clo

sely m

atche

s the int

ent and p

urpose of

 the original

 exc

lusion. Omr

on Eur

ope BV and/or its

 sub

sidi

ary and affi

liat

ed comp

anies 

reser

ve the right

 to m

ake an

y c

han

ges

 to the pr

oducts, their spec

ification

s, dat

a at its

 sole di

scr

etion at an

y time w

ithout prior notic

e. The m

ateri

al c

ontained in thi

s c

atalogue m

ay be out

 of 

dat

e and Omron E

urope B

V and/or its

 sub

sidi

ary and affi

liat

ed comp

anies m

ake no c

ommitment to upd

ate s

uch m

ateri

al.

Cat

. No

. I5

2E-

EN

-03

Tra

jex

ia 

mot

ion

 co

ntr

ol 

sys

tem

 

pr

og

ra

mm

in

g m

an

ua

l

Cat

. No

I52E

-EN-03

Summary of Contents for TJ1-MC04

Page 1: ...ular purpose or non infringement In a jurisdiction where the exclusion of implied warranties is not valid the exclusion shall be deemed to be replaced by such valid exclusion which most closely matches the intent and purpose of the original exclusion Omron Europe BV and or its subsidiary and affiliated companies reserve the right to make any changes to the products their specifications data at its...

Page 2: ...not avoided will result in death or serious injury WARNING Indicates a potentially hazardous situation which if not avoided could result in death or serious injury Caution Indicates a potentially hazardous situation which if not avoided may result in minor or moderate injury or property damage OMRON 2007 All rights reserved No part of this publication may be reproduced stored in a retrieval sys te...

Page 3: ...71080001 Describes the installation and operation of the MECHA TROLINK II application mod ule Sigma III with MECHATRO LINK interface manual SIEP S800000 11 Describes the installation and operation of Sigma III servo drives with MECHATRO LINK interface V7 Inverter TOEP C71060605 02 OY Describes the installation and operation of V7 inverters F7Z Inverter TOE S616 55 1 OY Describes the installation a...

Page 4: ...to Trajexia Tools software Refer to the Programming Manual Open the terminal window and type the following commands Type PRINT VERSION in the terminal window The version parameter returns the current firmware version number of the motion controller Type PRINT FPGA_VERSION SLOT 1 in the terminal window The parameter returns the current FPGA version number of the TJ1 MC__ Functionality TJ1 MC__ Firm...

Page 5: ...ables 25 2 3 4 Mathematical specifications 27 2 4 Motion execution 28 2 4 1 Motion generator 28 2 4 2 Sequencing 29 2 4 3 Move loading 29 2 5 Command line interface 30 2 6 BASIC programs 30 2 6 1 Managing programs 30 2 6 2 Program compilation 31 2 6 3 Program execution 31 3 BASIC commands 33 3 1 Categories 33 3 1 1 Axis commands 33 3 1 2 Axis parameters 34 3 1 3 Communication commands and paramete...

Page 6: ... 43 3 2 11 Is less than 43 3 2 12 Is less than or equal to 43 3 2 13 Hexadecimal input 44 3 2 14 Comment field 44 3 2 15 Statement separator 44 3 2 16 44 3 2 17 ABS 45 3 2 18 ACC 45 3 2 19 ACCEL 45 3 2 20 ACOS 45 3 2 21 ADD_DAC 46 3 2 22 ADDAX 46 3 2 23 ADDAX_AXIS 47 3 2 24 AIN 47 3 2 25 AND 47 3 2 26 AOUT 48 3 2 27 ASIN 48 3 2 28 ATAN 48 3 2 29 ATAN2 48 3 2 30 ATYPE 49 3 2 31 AUTORUN 49 3 2 32 AX...

Page 7: ...ROR 58 3 2 52 COMMSTYPE 58 3 2 53 COMPILE 58 3 2 54 CONNECT 59 3 2 55 CONSTANT 59 3 2 56 CONTROL 59 3 2 57 COPY 60 3 2 58 COS 60 3 2 59 CREEP 60 3 2 60 D_GAIN 60 3 2 61 D_ZONE_MAX 61 3 2 62 D_ZONE_MIN 61 3 2 63 DAC 61 3 2 64 DAC_OUT 61 3 2 65 DAC_SCALE 61 3 2 66 DATE 62 3 2 67 DATE 62 3 2 68 DATUM 62 3 2 69 DATUM_IN 63 3 2 70 DAY 64 3 2 71 DAY 64 3 2 72 DECEL 64 3 2 73 DEFPOS 64 3 2 74 DEL 65 3 2 ...

Page 8: ...ENCODER 74 3 2 94 ENCODER_BITS 74 3 2 95 ENCODER_CONTROL 74 3 2 96 ENCODER_ID 75 3 2 97 ENCODER_RATIO 75 3 2 98 ENCODER_READ 75 3 2 99 ENCODER_STATUS 76 3 2 100 ENCODER_TURNS 76 3 2 101 ENCODER_WRITE 76 3 2 102 ENDIF 76 3 2 103 ENDMOVE 77 3 2 104 EPROM 77 3 2 105 ERROR_AXIS 77 3 2 106 ERROR_LINE 77 3 2 107 ERRORMASK 78 3 2 108 ETHERNET 78 3 2 109 EX 79 3 2 110 EXP 79 3 2 111 FALSE 79 3 2 112 FAST_...

Page 9: ...133 GET 88 3 2 134 GLOBAL 89 3 2 135 GOSUB RETURN 89 3 2 136 GOTO 89 3 2 137 HALT 90 3 2 138 HEX 90 3 2 139 HLM_COMMAND 90 3 2 140 HLM_READ 91 3 2 141 HLM_STATUS 92 3 2 142 HLM_TIMEOUT 93 3 2 143 HLM_WRITE 94 3 2 144 HLS_NODE 95 3 2 145 HW_PSWITCH 95 3 2 146 I_GAIN 96 3 2 147 IDLE 96 3 2 148 IEEE_IN 96 3 2 149 IEEE_OUT 96 3 2 150 IF THEN ELSE ENDIF 97 3 2 151 IN 97 3 2 152 INDEVICE 98 3 2 153 INIT...

Page 10: ...2 MECHATROLINK 107 3 2 173 MERGE 108 3 2 174 MHELICAL 109 3 2 175 MOD 109 3 2 176 MOTION_ERROR 109 3 2 177 MOVE 110 3 2 178 MOVEABS 111 3 2 179 MOVECIRC 112 3 2 180 MOVELINK 114 3 2 181 MOVEMODIFY 115 3 2 182 MPOS 116 3 2 183 MSPEED 116 3 2 184 MTYPE 116 3 2 185 NAIO 117 3 2 186 NEG_OFFSET 117 3 2 187 NEW 117 3 2 188 NEXT 117 3 2 189 NIO 117 3 2 190 NOT 118 3 2 191 NTYPE 118 3 2 192 OFF 118 3 2 19...

Page 11: ...OFIBUS 125 3 2 214 PSWITCH 126 3 2 215 RAPIDSTOP 127 3 2 216 READ_BIT 127 3 2 217 REG_POS 128 3 2 218 REG_POSB 128 3 2 219 REGIST 128 3 2 220 REMAIN 130 3 2 221 REMOTE_ERROR 130 3 2 222 RENAME 130 3 2 223 REP_DIST 131 3 2 224 REP_OPTION 131 3 2 225 REPEAT UNTIL 131 3 2 226 RESET 132 3 2 227 RETURN 132 3 2 228 REV_IN 132 3 2 229 REV_JOG 133 3 2 230 REVERSE 133 3 2 231 RS_LIMIT 133 3 2 232 RUN 133 3...

Page 12: ... 141 3 2 253 STOP 141 3 2 254 SYSTEM_ERROR 142 3 2 255 T_REF 142 3 2 256 TABLE 143 3 2 257 TABLEVALUES 143 3 2 258 TAN 144 3 2 259 THEN 144 3 2 260 TICKS 144 3 2 261 TIME 144 3 2 262 TIME 145 3 2 263 TO 145 3 2 264 TRANS_DPOS 145 3 2 265 TRIGGER 145 3 2 266 TROFF 145 3 2 267 TRON 146 3 2 268 TRUE 146 3 2 269 TSIZE 146 3 2 270 UNITS 147 3 2 271 UNLOCK 147 3 2 272 UNTIL 147 3 2 273 VERIFY 147 3 2 27...

Page 13: ...ocol 158 4 3 1 Host Link master 158 4 3 2 Host Link slave 163 4 3 3 User defined protocol 165 4 4 PROFIBUS 167 4 4 1 Introduction 167 4 4 2 Communication set up 167 4 4 3 Communication Status 172 4 5 DeviceNet 173 4 5 1 Introduction 173 4 5 2 Communication set up 173 4 5 3 Communication Status 178 4 6 MECHATROLINK II 179 5 Trajexia Tools interface 180 5 1 Introduction 180 5 2 Specifications and co...

Page 14: ... outputs 251 6 1 5 Origin search 253 6 1 6 Registration 259 6 1 7 Tracing and monitoring 269 6 2 Practical examples 279 6 2 1 Shell program 279 6 2 2 Initialization program 283 6 2 3 Single axis program 286 6 2 4 Position with product detection 287 6 2 5 Position on a grid 289 6 2 6 Bag feeder program 291 6 2 7 CAM table inside a program 293 6 2 8 Flying shear program 295 6 2 9 Correction program ...

Page 15: ...I O data communication problems 303 7 4 TJ1 DRT 304 7 4 1 System errors 304 7 4 2 I O data communication problems 304 7 5 TJ1 ML__ 304 7 5 1 System errors 304 7 5 2 Bus errors 304 7 6 TJ1 FL02 305 7 6 1 System errors 305 I52E EN 03 book Seite 15 Freitag 29 Juni 2007 11 55 11 ...

Page 16: ...is being supplied Doing so may result in electric shock WARNING Never short circuit the positive and negative terminals of the bat teries charge the batteries disassemble them deform them by applying pressure or throw them into a fire The batteries may explode combust or leak liquid WARNING Fail safe measures must be taken by the customer to ensure safety in the event of incorrect missing or abnor...

Page 17: ...n Caution Pay careful attention to the polarity when wiring the DC power supply A wrong connection may cause malfunction of the system Caution Tighten the screws on the terminal block of the Power Supply Unit to the torque specified in this manual Loose screws may result in burning or malfunction Caution Do not operate the Unit in any of the following locations Doing so may result in malfunction e...

Page 18: ...result in an unexpected operation Caution Always use the power supply voltage specified in this manual An incorrect voltage may result in malfunction or burning Caution Take appropriate measures to ensure that the specified power with the rated voltage and frequency is supplied Be particularly careful in places where the power supply is unstable An incorrect power supply may result in malfunction ...

Page 19: ...e may result in malfunction Caution Leave the dust protective label attached to the Unit when wiring Removing the dust protective label may result in malfunction Caution Remove the dust protective label after the completion of wiring to ensure proper heat dissipation Leaving the dust protective label attached may result in malfunc tion Caution Use crimp terminals for wiring Do not connect bare str...

Page 20: ... environments that are subject to noise use a system with shielded twisted pair STP cable and hubs suitable for an FA environment Do not install twisted pair cables with high voltage lines Do not install twisted pair cables near devices that generate noise Do not install twisted pair cables in locations that are subject to high humidity Do not install twisted pair cables in locations subject to ex...

Page 21: ...l the unit properly Improper installation of the unit may result in malfunction Caution Be sure to mount the Termination Unit supplied with the TJ1 MC__ to the right most Unit Unless the Termination Unit is properly mounted the TJ1 will not function properly I52E EN 03 book Seite 21 Freitag 29 Juni 2007 11 55 11 ...

Page 22: ...interpolation all using simple motion commands Trajexia offers control of up to 16 axes over a MECHATROLINK II motion bus or traditional analogue or pulse control with independent position speed or torque control for every axis And its powerful motion instruction set makes programming intuitive and easy You can select from a wide choice of best in class rotary linear and direct drive servos as wel...

Page 23: ...le between 0 5 ms 1 ms or 2 ms TJ1 FL02 Flexible Axis Unit The TJ1 FL02 allows full control of two actuators via an analogue output or pulse train The module supports the main absolute encoder protocols allowing the connection of an external encoder to the system Drives and Inverters A wide choice of rotary linear and direct drive servos as well as inverters are available to fit your needs in comp...

Page 24: ...es the acceleration rate of a movement for a certain axis 2 3 1 Axis system and task statements The commands functions and parameters apply either to one of the axes the tasks running or the general system Axis statements The motion control commands and the axis parameters apply to one or more axes Axis parameters determine and monitor how an axis reacts on commands given and how it reacts to the ...

Page 25: ...000 slots with indexes 0 to 63999 The TABLE is accessible for reading and writing too but the way it is accessed differs for those two operations Before being read a particular TABLE memory slot needs to be defined and written first using the command TABLE x value1 value2 where x is the index of the start TABLE memory slot to define and value1 value2 are the values written into the TABLE memory at...

Page 26: ...aneously in different tasks and have their own version of variable a and label start If you need to hold data in common between two or more programs VR variables should be used Or alternatively if the large amount of data is to be held the TABLE memory can be used To make a program more readable when using a global VR variable two approaches can be taken The first is using a named local variable a...

Page 27: ...8 608 to 16 777 215 Example TABLE 0 10 65536 PRINT HEX TABLE 0 HEX TABLE 1 FFFFF6 10000 Positioning For positioning the TJ1 MC__ will round up if the fractional encoder edge distance calculated exceeds 0 9 Otherwise the fractional value will be rounded down The internal measured position and demanded position of the axes represented by the MPOS and DPOS axis parameters have 32 bit counters Floatin...

Page 28: ...ffers in the Trajexia Hardware Reference manual for detailed explanation The BASIC programs are separate from the motion generator program which controls moves for the axes The motion generator has separate functions for each axis so each axis is capable of being programmed with its own axis parameters for example speed acceleration and moving independently and simultaneously or they can be linked...

Page 29: ...m the NTYPE buffers to the MTYPE buffers and the NTYPE buffers are marked as idle This process is called move loading If there is a valid move in the MTYPE buffers then it is processed When the move has been completed the MTYPE buffers are marked as idle Move Loading Sequencing Axis Task 1 MOVECIRC AXIS 0 FORWARD AXIS 1 MOVE AXIS 0 Task 2 Motion Generator Task 3 Next Move NTYPE Move buffers Task b...

Page 30: ...ools allows copying the TJ1 MC__ version to disk or vice versa Programs on the computer are stored in ASCII text files They may therefore be printed edited and copied using a simple text editor The source programs are held in the TJ1 MC__ in a tokenised form and as a result the sizes of the programs will be less on the TJ1 MC__ compared to the same programs on the computer Storing programs Program...

Page 31: ...the I O of the TJ1 MC__ revolves around the servo cycle period of the system The servo cycle period is determined by the SERVO_PERIOD system parameter The TJ1 MC__ will either have a servo cycle period of 0 5 1 0 or 2 0 ms I O refresh The I O status of the TJ1 MC__ is refreshed at the beginning of every servo cycle The captured status of the digital inputs is transferred to the IN system input var...

Page 32: ...can be left connected as an operator interface or may be removed and the programs run stand alone Programs are set in Trajexia Tools to run automatically at start up using the Set Power Up Mode selection under the Program menu This operation sets which program to run automatically and at which priority This can also be accomplished by the RUNTYPE BASIC command The current status can be seen using ...

Page 33: ...an axis according to values of a movement profile stored in the TABLE variable array The motion is linked to the measured motion of another axis to form a continuously variable software gear box CANCEL Cancels the move on an axis CONNECT Connects the demand position of an axis to the measured move ments of the axis specified for driving_axis to produce an electronic gearbox DATUM Performs one of 7...

Page 34: ...the axis status Name Description CLOSE_WIN Defines the end of the window in which a registration mark is expected CLUTCH_RATE Defines the change in connection ratio when using the CONNECT command CREEP Contains the creep speed D_GAIN Contains the derivative control gain DAC_SCALE Sets scale and polarity applied to DAC values DATUM_IN Contains the input number to be used as the origin input DECEL C...

Page 35: ...of consecutive moves MPOS Is the position of the axis as measured by the encoder Name Description MSPEED Represents the change in the measured position in the last servo period MTYPE Contains the type of move currently being executed NTYPE Contains the type of the move in the Next Move buffer OFFPOS Contains an offset that will be applied to the demand position without affecting the move in any ot...

Page 36: ...o the Host Link Slave from either VR or TABLE var iable array HLS_NODE Defines the Slave unit number for the Host Link Slave protocol SETCOM Sets the serial communications Name Description Name Description FALSE Equal to the numerical value 0 OFF Equal to the numerical value 0 ON Equal to the numerical value 1 PI Equal to the numerical value 3 1416 TRUE Equal to the numerical value 1 Name Descript...

Page 37: ...Returns the arc sine of an expression ATAN Returns the arc tangent of an expression ATAN2 Returns the arc tangent of the non zero complex number made by two expressions COS Returns the cosine of an expression EXP Returns the exponential value of an expression FRAC Returns the fractional part of an expression IEEE_IN Returns floating point number in IEEE format represented by 4 bytes IEEE_OUT Retur...

Page 38: ...h increasing decreasing variable GOSUB RETURN Jumps to a subroutine at the line just after label The program execution returns to the next instruction after a RETURN on page 132 is given GOTO Jumps to the line containing the label Name Description IF THEN ELSE ENDIF Controls the flow of the program base on the results of the con dition ON GOSUB or ON GOTO Enables a conditional jump to one of sever...

Page 39: ...turns the value of the specified bit in the specified VR varia ble RESET Resets all local variables on a task Name Description SCOPE Programs the system to automatically store up to 4 parameters every sample period to the TABLE variable array SET_BIT Sets the specified bit in the specified VR variable to one TABLE Writes and reads data to and from the TABLE variable array TABLEVALUES Returns list ...

Page 40: ...OFFSET Applies a positive offset to the DAC signal from the servo loop SCOPE_POS Contains the current TABLE position at which the SCOPE com mand is currently storing its first parameter SERVO_PERIOD Sets the servo cycle period of the TJ1 MC__ SYSTEM_ERROR Contains the system errors since the last initialization TIME Returns the current time held by the real time clock TSIZE Returns the size of the...

Page 41: ...on1 Any valid BASIC expression expression2 Any valid BASIC expression Example result 10 2 Assigns the value 8 to the variable result See also N A Type Mathematical function Syntax expression1 expression2 Description The operator multiplies two expressions Arguments expression1 Any valid BASIC expression expression2 Any valid BASIC expression Example result 3 7 Assigns the value 21 to the variable ...

Page 42: ...Example IF a 10 THEN GOTO label1 If variable a contains a value equal to 10 program execution continues at label label1 Otherwise program execution continues with the next statement See also N A Type Mathematical function Syntax variable expression Description The operator assigns the value of the expression to the variable Arguments variable A variable name expression Any valid BASIC expression E...

Page 43: ...ntains a value greater than or equal to 10 program execution continues at label label1 Otherwise program execution continues with the next statement See also N A Type Mathematical function Syntax expression1 expression2 Description The operator returns TRUE if expression1 is less than expression2 other wise it returns FALSE Arguments expression1 Any valid BASIC expression expression2 Any valid BAS...

Page 44: ...ou can use at the beginning of a line or after a valid statement Arguments N A Example This line is not printed PRINT Start See also N A Type Program command Syntax Description The statement separator separates multiple BASIC statements on one line You can use it on the command line and in programs Arguments N A Example PRINT THIS LINE GET low PRINT DOES THREE THINGS See also N A Type Special char...

Page 45: ...ts with the UNITS axis parameter Example ACC 100 Sets ACCEL and DECEL to 100 units s2 See also ACCEL DECEL UNITS Type Axis parameter Syntax ACCEL expression Description The ACCEL axis parameter contains the axis acceleration rate The rate is set in units s2 The parameter can have any positive value including zero Arguments N A Example BASE 0 ACCEL 100 Set acceleration rate PRINT Acceleration rate ...

Page 46: ...d axes Arguments axis The axis from which to sum the speed reference output to the base axis Set the argument to 1 to cancel the link and return to normal operation Example BASE 0 OUTLIMIT AXIS 1 15000 ADD_DAC 1 AXIS 0 ADDAX 0 AXIS 1 WDOG ON SERVO AXIS 0 ON SERVO AXIS 1 ON Execute moves on axis 0 This example shows controlling the Servo Driver axis 0 with dual feedback control using both axis 0 an...

Page 47: ...s the number of the axis to which the base axis is currently linked to by ADDAX Arguments N A Example BASE 0 ADDAX 2 PRINT ADDAX_AXIS 2 0000 See also ADDAX AXIS Type System parameter Syntax AIN analogue_chan Description 10V analogue input channels are provided by connecting JEPMC AN2900 modules on the MECHATROLINK II bus Note The analogue input value is checked to ensure it is above zero even thou...

Page 48: ...ogue_chan Description This command sets the output value of the 10V analogue output channels that are provided by connecting JEPMC AN2910 modules on the MECHA TROLINK II bus The range of the value set is 32000 32000 for voltage range 10V 10V Arguments analogue_chan Analogue output channel number 0 31 Example No example See also N A Type Mathematical function Syntax ASIN expression Description The ...

Page 49: ...ervo Drivers connected to the system via MECHATROLINK II bus the default ATYPE value is 41 Mechatro Speed For axes controlled by the Servo Drivers connected to the system via the TJ1 FL02 the default ATYPE value is 44 Flexible axis Servo Arguments N A Example ATYPE AXIS 1 45 This command will set axis 1 as Flexible axis encoder output axis See also AXIS AXIS type ATYPE value Applicable TJ1 unit Vi...

Page 50: ...G 1 ENCODER Z OUT 1 ENCODER B B0 REG 0 AUX IN OUT 0 ENCODER A B1 REG 1 ENCODER Z OUT 1 ENCODER B Type Axis parameter Syntax AXIS_ENABLE ON OFF Description The AXIS_ENABLE axis parameter is used to enable or disable particular axis independently of others This parameter can be set on or off for each axis individually The default value on start up is on or all axes The axis will be enables if both A...

Page 51: ...e B Spline math ematical function by a configurable expansion factor to another area in the TABLE This is ideally used where the source CAM profile is too course and needs to be extrapolated into a greater number of points Arguments type Reserved for future expansion Always set this to 1 data_in Location in the TABLE where the source profile is stored number_in Number of points in the source profi...

Page 52: ...ments The command can take up to 16 arguments axis_i The number of the axis set as the base axis and any subsequent axes in the group order for multi axis moves Example BASE 1 UNITS 2000 Set unit conversion factor for axis 1 SPEED 100 Set speed for axis 1 ACCEL 5000 Set acceleration rate for axis 1 BASE 2 UNITS 2000 Set unit conversion factor for axis 2 SPEED 125 Set speed for axis 2 ACCEL 10000 S...

Page 53: ... break points from program simpletest See also N A Type Axis command Syntax CAM start_point end_point table_multiplier distance Description The CAM command is used to generate movement of an axis following a position profile which is stored in the TABLE variable array The TABLE val ues are absolute positions relative to the starting point and are specified in encoder edges The TABLE array is speci...

Page 54: ...y high If a distance of 100 mm is specified CAM will take 10 seconds to execute The SPEED parameter in the base axis allows modification of the speed of movement when using the CAM move Note When the CAM command is executing the ENDMOVE parameter is set to the end of the previous move Example Assume that a motion is required to follow the position equation t x x 25 10000 1 cos x Here x is in degre...

Page 55: ...le if the link_option is set to 4 then the CAMBOX operates like a physical CAM CAMBOX works on the default basis axis set with BASE unless AXIS is used to specify a temporary base axis Note While CAMBOX is being executed the ENDMOVE parameter will be set to the end of the previous move The REMAIN axis parameter will hold the remainder of the distance on the link axis Arguments start_point The addr...

Page 56: ...ed CANCEL 1 cancels only the presently buffered move Any moves stored in the task buffers indicated by the PMOVE variable can be loaded into the buffer as soon as the buffered move is cancelled Arguments N A Example FORWARD WA 10000 CANCEL Example MOVE 1000 MOVEABS 3000 CANCEL Cancel the move to 3000 and move to 4000 instead MOVEABS 4000 Note that the command MOVEMODIFY is a better solution for mo...

Page 57: ...to their default values CLEAR_PARAM cannot be performed if the controller is locked Arguments N A Example No example See also N A Type Axis parameter Syntax CLOSE_WIN CW Description The CLOSE_WIN axis parameter defines the end of the window inside or out side which a registration mark is expected The value is in user units Arguments N A Example No example See also AXIS OPEN_WIN REGIST UNITS Type A...

Page 58: ... Rx Overrun Serial port 2 14 Port 2 Parity Error Serial port 2 15 Port 2 Rx Frame Error Serial port 2 Type Slot parameter Syntax COMMSTYPE SLOT unit_number Description This parameter returns the type of unit in a controller unit The table below lists the return values Arguments unit_number Unit numbers are 0 to 6 with 0 being the unit immediately to the right of the TJ1 MC__ Example No example See...

Page 59: ... wired to axis 0 An input channel monitors the encoder pulses from the conveyor and forms axis 1 This code can be used BASE 1 SERVO OFF This axis is used to monitor the conveyor BASE 0 SERVO ON CONNECT 0 25 1 See also AXIS CANCEL CLUTCH_RATE CONNECT RAPIDSTOP Type System command Syntax CONSTANT name value Description Declares the name as a constant for use both within the program containing the CO...

Page 60: ...d BASIC expression Example PRINT COS 0 1 0000 See also N A Type Axis parameter Syntax CREEP Description The CREEP axis parameter contains the creep speed for the axis The creep speed is used for the slow part of an origin search sequence CREEP can have any positive value including 0 The creep speed is entered in units with the unit conversion factor UNITS For example if the unit conversion factor ...

Page 61: ...ut to zero when the demand movement is complete and the magnitude of the Following Error is less than the D_ZONE_MIN value The servo loop will be reactivated when either the Following Error rises above the D_ZONE_MAX value or a fresh movement is started Arguments N A Example D_ZONE_MIN 3 D_ZONE_MAX 10 With these 2 parameters set as above the DAC output will be clamped at zero when the movement is ...

Page 62: ... Description The DATUM command makes one of 6 origin searches to position an axis to an absolute position and also reset the Following Errors DATUM uses both the creep and demand speed for the origin search The creep speed in the sequences is set with the CREEP axis parameter and the demand speed is set with the SPEED axis parameter The datum switch input number used for sequences 3 to 6 is set by...

Page 63: ...tum switch is reached The axis then reverses at creep speed until the datum switch is reset The axis continues at creep speed until the Z marker of the encoder is encoun tered The demand position is then reset to 0 and the measured position cor rected so as to maintain the Following Error 6 The axis moves at demand speed reverse until the datum switch is reached The axis then moves forward at cree...

Page 64: ...ntax DEFPOS pos_1 pos_2 pos_3 pos_4 DP pos_1 pos_2 pos_3 pos_4 Description The DEFPOS command defines the current demand position DPOS as a new absolute position The measured position MPOS will be changed accordingly in order to keep the Following Error DEFPOS is typically used after an origin search sequence see DATUM command as this sets the cur rent position to 0 DEFPOS can be used at any time ...

Page 65: ...to be deleted Example DEL oldprog See also COPY NEW RENAME SELECT TABLE Type Axis parameter read only Syntax DEMAND_EDGES Description The DEMAND_EDGES axis parameter contains the current value of the DPOS axis parameter in encoder edge units Arguments N A Example No example See also AXIS DPOS Type System command Syntax DEVICENET unit_number 2 1 VR_start_outputs no_outputs VR_start_inputs no_inputs...

Page 66: ...r 2 executed without error 1 0 No DeviceNet I O connection 1 DeviceNet I O connection running 2 0 VR variables in the output data range have been updated 1 VR variables in the output data range have not been updated yet 3 0 DeviceNet I O connection size matches the DEVICENET unit_number 2 command 1 DeviceNet I O connection size does not match the DEVICENET unit_number 2 command 4 7 0 Always zero 8...

Page 67: ...xis cannot belong to more than one group All groupings can be cleared using DISABLE_GROUP 1 Arguments axis_i A BASIC expression that evaluates to an axis number Example DISABLE_GROUP 1 DISABLE_GROUP 0 1 2 3 DISABLE_GROUP 4 5 6 7 WDOG ON STOP enable_b FOR ax 4 TO 7 AXIS_ENABLE AXIS ax ON NEXT ax A system of 8 axes requires that axes 4 7 keep running if axes 0 3 have an error and vice versa The axes...

Page 68: ...ype Axis command Syntax DRIVE_ALARM VR Description The DRIVE_ALARM function reads the current alarm of the Servo Driver that is connected to the Trajexia system via MECHATROLINK II Upon successful execution the command returns 1 and stores the value in the VR memory location specified by the VR parameter If the command cannot be executed the value 0 is returned The command is executed on the drive...

Page 69: ...us this parameter selects the data to be moni tored by DRIVE_MONITOR according to the table below If a Servo Driver for the axis is connected using the TJ1 FL02 this parameter sets outputs of the TJ1 FL02 Set bit 8 of this parameter to switch on OUT 0 for an axis Set bit 9 of this parameter to switch on OUT 1 for an axis Keep in mind that the same outputs are used by the HW_PSWITCH command Argumen...

Page 70: ...E_INPUTS bit 0 See also N A Bit number Description Sigma II Description Junma 0 P_OT P_OT 1 N_OT N_OT 2 DEC Signal selected with Pn511 0 DEC 3 Encoder Phase A N C 4 Encoder Phase B N C 5 Encoder Phase C N C 6 EXT1 Signal selected with Pn511 1 EXT1 7 EXT2 Signal selected with Pn511 2 N C 8 EXT3 Signal selected with Pn511 3 N C 9 BRK Brake output BK 10 Reserved E_STP 11 Reserved N C 12 IO12 CN1 inpu...

Page 71: ...The number of the parameter to be read Note that the parameter num bers are hexadecimal The format of the data can be found in the Servo Driver manual size For most parameters the size is normally 2 bytes Some special parame ters may be 4 bytes long Sizes for each parameter can be found in the Servo Driver manual VR The VR address where the read parameter is stored upon successful execution Exampl...

Page 72: ...iary inputs as well as registration selection The explanation of each bit is given in the second table below Note Only bits relevant to Flexible axis are listed Arguments N A Example PRINT DRIVE_STATUS AXIS 4 This command will print the current value of DRIVE_STATUS for axis 4 Example BASE 3 ATYPE 44 IF DRIVE_STATUS AND 32 32 THEN PRINT REG 0 input is ON for axis 3 ENDIF See also AXIS MARK MARKB R...

Page 73: ...mat of the data can be found in the Refer to the Servo Driver manual for the format of the data size For most parameters the size is normally 2 bytes Some special parame ters may be 4 bytes long Sizes for each parameter can be found in the Servo Driver manual value The value to be written into driver parameter mode The write mode Possible values 0 or omitted write and store in RAM 1 write and stor...

Page 74: ...ration or 0 for Gray code Note If using Flexible axis absolute encoder axis it is essential to set this parameter for the axis before setting the ATYPE Arguments N A Example ENCODER_BITS 25 256 12 ATYPE 47 In this example a 25 bit EnDat encoder is used that has 12 bits for multi turn value and 13 bits per one revolution Example ENCODER_BITS 12 64 1 ATYPE 48 In this example a 12 bit 4096 positions ...

Page 75: ...rately achieve all positions Note ENCODER_RATIO does not replace UNITS Only use ENCODER_RATIO where absolutely necessary For all other axis scaling use UNITS Arguments denominator A number between 0 and 16777215 that is used to define the denomina tor in the above equation numerator A number between 0 and 16777215 that is used to define the numerator in the above equation Example ENCODER_RATIO 819...

Page 76: ...The multi turn data is not automatically applied to the axis MPOS parameter after initialization The application programmer must apply this from the pro gram using OFFPOS or DEFPOS commands as required If applied to axis of ATYPE value other than 46 or 47 the parameter returns 0 Arguments N A Example PRINT ENCODER_TURNS AXIS 1 This command will print absolute encoder multi turn counts for axis 1 S...

Page 77: ...el Also pop up screens will prompt to write the program data into flash memory Arguments N A Example No example See also POWER_UP RUNTYPE Type System parameter read only Syntax ERROR_AXIS Description The ERROR_AXIS axis parameter contains the number of the axis which has caused the motion error A motion error occurs when the AXISSTATUS state for one of the axes matches the ERRORMASK setting In thi...

Page 78: ... define in which cases a motion error is gener ated For safe operation it is strongly recommended to generate a motion error when the Following Error has exceeded its limit in all cases This is done by setting bit 8 of ERRORMASK Type System command Syntax ETHERNET function unit_number parameter values Description The command ETHERNET is used to read and set certain functions of Ether net communica...

Page 79: ...3 See also N A Type Constant read only Syntax FALSE Description The FALSE constant returns the numerical value 0 Arguments N A Example test res IN 0 OR IN 2 IF res FALSE THEN PRINT Inputs are off ENDIF See also N A Type Axis parameter Syntax FAST_JOG Description The FAST_JOG axis parameter contains the input number to be used as the fast jog input The number can be from 0 to 7 As default the param...

Page 80: ...IMIT FE_RANGE MPOS UNITS Type Axis parameter read only Syntax FE_LATCH Description Contains the initial FE value which caused the axis to put the controller into MOTION_ERROR This value is only set when the FE exceeds the FE_LIMIT and the SERVO parameter has been set to 0 FE_LATCH is reset to 0 when the SERVO parameter of the axis is set back to 1 Arguments N A Example No example See also N A Type...

Page 81: ...also AXIS AXISSTATUS ERRORMASK FE UNITS Type Axis parameter Syntax FHOLD_IN FH_IN Description The FHOLD_IN axis parameter contains the input number to be used as the feedhold input The valid input range is 0 to 31 Values 0 to 15 represent phys ically present inputs of TJ1 MC__ I O connector and are common for all axes Values 16 to 27 represent software inputs which can be freely used in pro grams ...

Page 82: ...pe network node unit remote_area remote_offset length local_area local_offset timeout ip1 ip2 ip3 ip4 Description FINS Factory Interface Network Service is a Proprietary OMRON communi cation protocol A subset of this protocol has been implemented in Trajexia The FINS protocol has been implemented with the intention of enabling seamless communication with other OMRON devices PLCs HMIs etc and softw...

Page 83: ...ger VR value 0x01 Integer TABLE value 0x02 float TABLE value local_offset The offset of the first value in the local source memory area The range depends upon the VR or TABLE array size and value for the length argu ment timeout The number of milliseconds to wait for a response from the destination FINS server before timing out IP1 IP2 IP3 IP4 Optional parameters that define the remote destination...

Page 84: ...31 value If specified this is the state to set the given flag to i e on or off This can also be written as 1 or 0 Example FLAG 27 ON Set flag bit 27 on See also N A Type System command Syntax FLAGS value Description Read and set the FLAGS as a block The FLAGS command is provided to aid compatibility with earlier controllers and is not recommended for new pro grams The 32 flag bits can be read with...

Page 85: ...dly executed until variable is greater than end at which time program execu tion will continue after NEXT Note FOR NEXT statements can be nested up to 8 levels deep in a BASIC program Arguments variable A BASIC expression start A BASIC expression end A BASIC expression increment A BASIC expression commands One or more BASIC commands Example FOR opnum 8 TO 13 OP opnum ON NEXT opnum This loop turns ...

Page 86: ... N A Type Mathematical function Syntax FRAC expression Description The FRAC function returns the fractional part of the expression Arguments expression Any valid BASIC expression Example PRINT FRAC 1 234 0 2340 See also N A Type System parameter Syntax FRAME value Description Used to specify which frame to operate within when employing frame transfor mations Frame transformations are used to allow...

Page 87: ...ition is greater than FS_LIMIT Arguments N A Example No example See also AXIS AXISSTATUS UNITS Type Axis parameter Syntax FWD_IN Description The FWD_IN axis parameter contains the input number to be used as a forward limit input The valid input range is 0 to 31 Values 0 to 15 represent physically present inputs of TJ1 MC__ I O connector and are common for all axes Values 16 to 27 represent softwar...

Page 88: ...to 7 are logical channels that are superimposed on the programming port 0 when using Trajexia Tools Note Channel 0 is reserved for the connection to Trajexia Tools and or the command line interface Please be aware that this channel may give problems for this function Arguments n The specified input device When this argument is omitted the port as specified by INDEVICE will be used See the table be...

Page 89: ...8 GLOBALs can be declared Arguments name Any user defined name containing lower case alpha numeri cal or underscore characters vr_number The number of the VR to be associated with name Example GLOBAL srew_pitch 12 GLOBAL ratio1 534 ratio1 3 56 screw_pitch 23 0 PRINT screw_pitch ratio1 See also N A Type Program control command Syntax GOSUB label RETURN Description The GOSUB structure enables a subr...

Page 90: ...o one or to all Host Link Slaves on the selected port Program execution will be paused until the response string has been received or the timeout time has elapsed The timeout time is specified by using the HLM_TIMEOUT parameter The status of the transfer can be monitored with the HLM_STATUS parameter Notes When using the HLM_READ be sure to set up the Host Link Master pro tocol by using the SETCOM...

Page 91: ...g string MCW151 TEST STRING and checking the echoed string Check the HLM_STATUS parameter for the result HLM_ABORT or value 2 This performs the Host Link ABORT XZ command to abort the Host link command that is currently being processed The ABORT command does not receive a response HLM_INIT or value 3 This performs the Host Link INITIALIZE command to initialize the transmission control procedure of...

Page 92: ...st link command PLC_DM or value 0 DM area RD PLC_IR or value 1 CIO IR area RR PLC_LR or value 2 LR area RL PLC_HR or value 3 HR area RH PLC_AR or value 4 AR area RJ PLC_EM or value 6 EM area RE mc_area value Data area MC_TABLE or value 8 TABLE variable array MC_VR or value 9 Global VR variable array Type Communication parameter Syntax HLM_STATUS PORT n Description The HLM_STATUS parameter contains...

Page 93: ...tes that the Slave did not recognize the com mand and has returned a IC response Type Communication parameter Syntax HLM_TIMEOUT Description The HLM_TIMEOUT parameter specifies the fixed timeout time for the Host Link Master protocol for both serial ports A timeout error will occur when the time needed to both send the command and receive the response from the Slave is longer than the time speci f...

Page 94: ...rom one program task only to avoid any multi task timing problems Arguments port The specified serial port 1 RS 232C serial port 1 2 RS 422A serial port 2 node The Slave node number to send the Host link command to Range 0 31 pc_area The PC memory selection for the Host link command See the first table below pc_offset The address of the specified PC memory area to write to Range 0 9999 length The ...

Page 95: ... HW_PSWITCH command are stored in FIFO queue This command is applicable only to Flexible axis axes with ATYPE values 43 44 and 45 The command can be used with either or 5 parameters Only 1 parameter is needed to disable the switch or clear FIFO queue All five parameters are needed to enable switch After loading FIFO and going through the sequence of positions in FIFO if the same sequence has to be...

Page 96: ... Example No example See also D_GAIN I_GAIN OV_GAIN P_GAIN VFF_GAIN Type Mathematical function Syntax IEEE_IN byte0 byte1 byte2 byte3 Description The IEEE_IN function returns the floating point number represented by 4 bytes which typically have been received over a communications link Arguments byte0 byte3 Any combination of 8 bit values that represents a valid IEEE floating point number Example VR...

Page 97: ...n commands One or more BASIC commands Example IF MPOS 0 22 VR 0 THEN GOTO exceeds_length Example IF IN 0 ON THEN count count 1 PRINT COUNTS count fail 0 ELSE fail fail 1 ENDIF Example IF IN stop ON THEN OP 8 ON VR cycle_flag 0 ELSEIF IN start_cycle ON THEN VR cycle_flag 1 ELSEIF IN step1 ON THEN VR cycle_flag 99 ENDIF Example IF key_char 31 THEN GOSUB char_1 ELSEIF key_char 32 THEN GOSUB char_2 EL...

Page 98: ... the default input device This device will be selected for the input commands when the n option is omitted The INDEVICE parameter is task specific The supported values are listed in the table below Arguments N A Example No example See also GETGET INPUT LINPUT KEY Value Description 0 Programming port 0 default 1 RS 232C serial port 1 2 RS 422A 485 serial port 2 5 Trajexia Tools port 0 user channel ...

Page 99: ...is argument is omitted the port as specified by INDEVICE will be used variable The variable to write to Example Consider the following program to receive data from the terminal INPUT 5 num PRINT 5 BATCH COUNT num 0 A possible response on the terminal could be 123 CR BATCH COUNT 123 See also INDEVICE GET LINPUT KEY Type Mathematical function Syntax INT expression Description The INT function return...

Page 100: ...station 7 operation_signals INVERTER_COMMAND module station 1 alarm_number Description INVERTER_COMMAND controls inputs and clears alarm of the frequency inverter connected to the system via the MECHATROLINK II bus There are two INVERTER_COMMAND functions 1 Clears an alarm 7 Controls operation signals To use an inverter via MECHATROLINK II you should put the command and the reference via communica...

Page 101: ... 0 param_number param_size VR INVERTER_READ module station 1 alarm_number VR INVERTER_READ module station 2 VR INVERTER_READ module station 3 VR INVERTER_READ module station 4 from length VR Description INVERTER_READ reads the parameter speed reference torque reference or alarm from the frequency inverter connected to the system via the MECHATROLINK II bus There are five INVERTER_READ functions 0 ...

Page 102: ...ultifunction Input 5 5 Hex 20 Inverter multifunction Input 6 6 Hex 40 Inverter multifunction Input 7 8 Hex 100 External fault 9 Hex 200 Fault reset 14 Hex 4000 Fault history data clear 15 Hex 8000 External BB command Type System command Syntax INVERTER_WRITE module station 0 param_number param_size VR mode INVERTER_WRITE module station 2 value INVERTER_WRITE module station 3 value Description INVE...

Page 103: ... has been declared and that input is low A forward jog input and a reverse jog input are available for each axis respectively set by FWD_JOG and REV_JOG The speed of the jog can be controlled with the FAST_JOG input Arguments N A Example No example See also AXIS AXIS FAST_JOG FWD_JOG REV_JOG UNITS Type I O parameter Syntax KEY n Description The KEY parameter returns TRUE or FALSE depending on if a...

Page 104: ...meter read only Syntax LINKAX Description Returns the axis number that the axis is linked to during any linked moves Linked moves are where the demand position is a function of another axis Arguments N A Example No example See also CONNECT CAMBOX MOVELINK Type I O command Syntax LINPUT n vr_variable Description The LINPUT command assigns the ASCII code of the characters to an array of variables st...

Page 105: ...with the terminal window LIST is used as an immediate com mand line command only and must not be used in programs The LIST command prints the current selected program or the program spec ified by program_name The program name can also be specified without quotes If the program name is omitted the current selected program will be listed Note This command is implemented for an offline VT100 terminal...

Page 106: ...om being viewed modified or deleted by personnel unaware of the security code The UNLOCK command allows the locked state to be unlocked The code number can be any integer and is held in encoded form LOCK is always an immediate command and can be issued only when the system is UNLOCKED Arguments code Any valid integer with maximum 7 digits Example LOCK 561234 The programs cannot be modified or seen...

Page 107: ...by the STARTUP program to check that the number of detected MECHATROLINK II modules corresponds with the expected MECHATROLINK unit 4 station VR Returns the address of MECHATROLINK II device at that station number The station numbers are a sequence 0 x for all the attached devices 1 is returned if no device is allocated to that station It is used by the STARTUP program to check that the number of ...

Page 108: ... Syntax MERGE Description The MERGE parameter is a software switch that can be used to enable or disable the merging of consecutive moves With MERGE is on and the next move already in the next move buffer NTYPE the axis will not ramp down to 0 speed but will load up the following move enabling a seamless merge The default setting of MERGE is off It is up to the programmer to ensure that merging is...

Page 109: ...wise direction The parameter is set to 0 or 1 See MOVECIRC distance3 The distance to move on the third axis in the BASE array axis in user units Example No example See also MOVECIRC Type Mathematical function Syntax expression1 MOD expression2 Description The MOD function returns the expression2 modulus of expression1 This function will take the integer part of any non integer input Arguments expr...

Page 110: ...ring a 2 axis movement the individual speeds are calculated using the equations below Given command MOVE x1 x2 and the profiled speed vp as calculated from the SPEED ACCEL and DECEL parameters from the base axis and the total multi axes distance L SQR x1 2 x2 2 The individual speed vi for axis i at any time of the movement is calculated as vi xi vp L Arguments The command can take up to 16 argumen...

Page 111: ... 2 axis movement the individual speeds are calculated using the equations below Given command MOVE ax1 ax2 the current position ay1 ay2 and the profiled speed vp as calculated from the SPEED ACCEL and DECEL parameters from the base axis and the total multi axes distance L SQR x1 2 x2 2 where x1 axi ayi The individual speed for axis at any time of the movement is calculated as vi xi x vp L Argument...

Page 112: ...s moving in the circular arc must have the same number of encoder pulses per linear axis distance If they do not it is possible to adjust the encoder scales in many cases by adjusting with ENCODER_RATIO axis parameters for the axis Arguments end_1 The end position for the base axis end_2 The end position for the next axis centre_1 The position around which the base axis is to move centre_2 The pos...

Page 113: ...nsure that the two points correspond to correct points on a circle Example The command sequence to plot the letter 0 might be as follows MOVE 0 6 Move A B MOVECIRC 3 3 3 0 1 Move B C MOVE 2 0 Move C D MOVECIRC 3 3 0 3 1 Move D E MOVE 0 6 Move E F MOVECIRC 3 3 3 0 1 Move F G MOVE 2 0 Move G H MOVECIRC 3 3 0 3 1 Move H A See also AXIS ENCODER_RATIO UNITS SPECIFIED END POINT ACTUAL END POINT Directio...

Page 114: ...the two axes travel the same distance so the distance to move must equal the link_distance MOVELINK works on the default basis axis group set with BASE unless AXIS is used to specify a temporary base axis The axis set for link_axis drives the base axis Note If the sum of link_acceleration and link_deceleration is greater than link_distance they are both reduced in proportion in order to equal the ...

Page 115: ...0 8 0 0 8 1 This move is all decel In a constant speed phase with matching speeds the two axes travel the same distance so the distance to move must equal the link distance The constant speed phase can be specified as follows MOVELINK 0 2 0 2 0 0 1 This is all constant speed The MOVELINK command lets the three sections to be added by summing the distance link_distance link_acceleration and link_de...

Page 116: ...s set with the SERVO_PERIOD parameter MSPEED represents a snapshot of the speed and significant fluctuations which can occur particularly at low speeds It can be worthwhile to average several readings if a stable value is required at low speeds Arguments N A Example No example See also AXIS SERVO_PERIOD VP_SPEED UNITS Type Axis parameter read only Syntax MTYPE Description The MTYPE parameter conta...

Page 117: ...gram command Syntax NEW program_name Description The NEW command deletes all program lines of the program in the controller NEW without a program name can be used to delete the currently selected program using SELECT The program name can also be specified without quotes NEW ALL will delete all programs The command can also be used to delete the Table NEW TABLE The name TABLE must be in quotes Note...

Page 118: ...escription The OFF constant returns the numerical value 0 Arguments N A Example OP lever OFF The above line sets the output named lever to OFF See also N A Type Axis parameter Syntax OFFPOS Description The OFFPOS parameter contains an offset that will be applied to the demand position DPOS without affecting the move in any other way The measured position will be changed accordingly in order to kee...

Page 119: ...nts expression Any valid BASIC expression label Any valid label in the program Example REPEAT GET 5 char UNTIL 1 char and char 3 ON char GOSUB mover stopper change See also GOSUB RETURN GOTO Type Program control command Syntax ON expression GOTO label label Description The expression is evaluated and then the integer part is used to select a label from the list If the expression has the value 1 th...

Page 120: ... line sets the bit pattern 10010 on the first 5 physical outputs outputs 13 to 17 would be cleared The bit pattern is shifted 8 bits by multiplying by 256 to set the first available outputs as outputs 0 to 7 do not exist Example VR 0 OP VR 0 VR 0 AND 65280 OP VR 0 This routine sets outputs 8 to 15 ON and all others off The above programming can also be written as follows OP OP AND 65280 Example va...

Page 121: ...ommand when the n option is omitted The OUTDEVICE parameter is task specific The supported values are listed in the table below Arguments N A Example No example See also PRINT Value Description 0 Programming port 0 default 1 RS 232C serial port 1 2 RS 422A 485 serial port 2 5 Trajexia Tools port 0 user channel 5 6 Trajexia Tools port 0 user channel 6 7 Trajexia Tools port 0 user channel 7 Type Axi...

Page 122: ...se Values that are too high will cause oscillation Values that are too low will cause large Follow ing Errors Note In order to avoid any instability the servo gains should be changed only when the SERVO is off Arguments N A Example No example See also D_GAIN I_GAIN OV_GAIN VFF_GAIN Type Constant read only Syntax PI Description The PI constant returns the numerical value 3 1416 Arguments N A Exampl...

Page 123: ...be selected to output the information to Multiple items to be printed can be put on the same line separated by a comma or a semi colon A comma separator in the print command places a tab between the printed items The semi colon separator prints the next item without any spaces between printed items The width of the field in which a number is printed can be set with the use of w x after the number ...

Page 124: ...ype Task command Syntax PROC task_number Description The PROC modifier allows a process parameter from a particular process to be read or written If omitted the current task will be assumed Arguments task_number The number of the task to access Example WAIT UNTIL PMOVE PROC 3 0 See also N A Type Task parameter Syntax PROC_STATUS Description The PROC_STATUS parameter returns the status of the proce...

Page 125: ...BUS DP master unit and defines areas in the VR memory where I O exchange takes place PROFIBUS function 4 returns the data exchange sta tus of the TJ1 PRT Refer to the table for the description of the bits in the data exchange status word Arguments unit_number Specifies the unit number of the TJ1 PRT in the Trajexia system VR_start_outputs The starting address in VR memory of the controller where t...

Page 126: ...ed PSWITCHs are calculated on each servo cycle and the output result applied to the hardware The response time is therefore 1 servo cycle period approxi mately Note An output may remain on if it was on when the PSWITCH was turned off The OP command can be used to turn off an output as follows PSWITCH 2 OFF OP 14 OFF Turn OFF pswitch controlling OP 14 Note The physical switches that are used with P...

Page 127: ...The output is to be on for a period of 120 units This can all be put together in the following lines of BASIC code switch UNITS AXIS 0 10 Set unit conversion factor REPDIST 360 REP_OPTION ON PSWITCH 0 ON 0 11 ON 80 200 This program uses the repeat distance set to 360 degrees and the repeat option on so that the axis position will be maintained between 0 and 360 degrees See also HW_PSWITCH OP UNITS...

Page 128: ...ccurred the MARK axis parameter is set to on and the position is stored in the REG_POS axis parameter For the secondary registration event the MARKB axis parameter is set to on and the position is stored in the REG_POSB axis parameter This command is applicable only to flexible axis axes with ATYPE values 43 44 and 45 MECHATROLINK II registration can be performed using encoder Z marker or external...

Page 129: ...egistration event occurs The mode parameter also specifies the use of the windowing function and filtering The mode parameter differs between MECHATROLINK II and Flexible Axis The functions for each bit in the mode parameter is explained in the tables below Example REGIST 4 1 AXIS 1 This command selects the primary registration event that occurs on the rising edge of REG 0 input signal for the axi...

Page 130: ...ts Arguments N A Example To change the speed to a slower value 5mm from the end of a move start SPEED 10 MOVE 45 WAIT UNTIL REMAIN 5 SPEED 1 WAIT IDLE See also AXIS UNITS Type Axis parameter Syntax REMOTE_ERROR Description Returns the number of errors on the digital communication link of a driver Arguments N A Example PRINT REMOTE_ERROR 1 0000 See also N A Type Program command Syntax RENAME old_pr...

Page 131: ... 5000000 Arguments N A Example No example See also AXIS DPOS MPOS REP_OPTION UNITS Type Axis parameter Syntax REP_OPTION Description The REP_OPTION parameter controls the application of the REP_DIST axis parameter and the repeat option of the CAMBOX and MOVELINK Axis commands The default value is 0 See the table below Arguments N A Example No example See also AXIS CAMBOX MOVELINK REP_DIST Bit Desc...

Page 132: ...meter contains the input number to be used as a reverse limit input The number can be set from 0 to 7 and 19 The valid input range is 0 to 31 Values 0 to 15 represent physically present inputs of TJ1 MC__ I O connector and are common for all axes Values 16 to 27 represent software inputs which can be freely used in programs and commands such as IN and OP These are also common for all axes Values 2...

Page 133: ... parameter contains the absolute position of the reverse soft ware limit in user units A software limit for reverse movement can be set from the program to control the working range of the machine When the limit is reached the TJ1 MC__ will decelerate to 0 and then cancel the move Bit 10 of the AXISSTATUS axis parameter will be turned on while the axis position is smaller than below RS_LIMIT Argum...

Page 134: ...whether the program specified by program_name is run automatically at start up or not and which task it is to run on The task number is optional if omitted the program will run at the highest available task The current RUNTYPE status of each programs is displayed when a DIR command is executed If one program has compilation errors no programs will be started at power up To set the RUNTYPE using Tr...

Page 135: ...xis parameter Arguments N A Example WDOG ON SERVO OFF square S_REF AXIS 0 2000 WA 250 S_REF AXIS 0 2000 WA 250 GOTO square These lines can be used to force a square wave of positive and negative movement with a period of approximately 500ms on axis 0 See also AXIS S_REF_OUT OUTLIMIT SERVO Type Axis parameter read only Syntax DAC_OUT S_REF_OUT Description The S_REF_OUT parameter contains the speed ...

Page 136: ...he MSPEED parameter is written as the change in encoder edges per servo period 3 Applications like the CAM command CAMBOX command and the SCOPE command all use the same TABLE as the data area Arguments control Set on or off to control SCOPE execution If turned on the SCOPE is ready to run as soon as the TRIGGER command is executed period The number of servo periods between data samples table_start...

Page 137: ... on their entry in the list in the control panel Arguments N A Example SELECT PROGRAM PROGRAM selected RUN See also COMPILE DEL EDIT LIST NEW RUN STEPLINE STOP TROFF Type Axis parameter Syntax SERVO Description The SERVO parameter determines whether the base axis runs under servo control SERVO ON or open loop SERVO OFF In closed loop the motion control algorithm will output a speed reference signa...

Page 138: ...ation command Syntax SETCOM baud_rate data_bits stop_bits parity port_number mode Description The SETCOM command sets the serial communications for the serial ports The command will enable the Host Link protocols or define the general pur pose communication The serial ports have 9 600 baud 7 data bits 2 stop bits even parity and XON XOFF enabled for general purpose communication by default These d...

Page 139: ...nd may have any value The result value will be in the range from 1 to 1 Arguments expression Any valid BASIC expression Example PRINT SIN PI 2 1 0000 See also N A Mode Description Type Slot modifier Syntax SLOT Description Modifier specifies the unit number for a parameter such as COMMSTYPE Trajexia unit numbers are 0 to 6 Arguments N A Example No example See also N A Type Axis parameter Syntax SP...

Page 140: ...Axis command Syntax STEP_RATIO output_count dpos_count Description This command sets up a ratio for the output of the axis stepper Every servo period the number of steps is passed through the STEP_RATIO function before it goes to the step pulse output Pulse Count Out numerator denominator MPOS STEP_RATIO affects both MOVECIRC and CAMBOX Notes The STEP_RATIO function operates before the divide by 1...

Page 141: ... be stepped A new task will be started when there is no copy of the program run ning If the task is specified as well then only the copy of the program running on the specified task will be stepped If there is no copy of the program run ning on the specified task then one will be started on it Arguments program_name The name of the program to be stepped task_number The number of the task with the ...

Page 142: ...ost error Any unit in the system 17 Terminator not fitted 18 Device lost error Any device in the system Type Axis parameter Syntax T_REF DAC Description The T_REF parameter contains the torque reference value which will be applied to the servo motor The range of this parameter is defined by the number of available bits For MECHATROLINK axes T_REF takes 32 bits so the available range is 2147483648 ...

Page 143: ...jexia Tools all use the same TABLE as the data area Do not use the same data area range for different purposes The TABLE and VR data can be accessed from all different running tasks To avoid problems of two program tasks writing unexpectedly to one global variable write the programs in such a way that only one pro gram writes to the global variable at a time The TABLE and VR data in RAM will be lo...

Page 144: ...k clock pulses TICKS is a 32 bit counter that is decremented on each servo cycle TICKS can be written and read It can be used to measure cycles times add time delays etc Each task has its own TICKS parameter Use the PROC modifier to access the parameter for a certain task Without PROC the current task will be assumed Arguments N A Example delay TICKS 3000 OP 9 ON test IF TICKS 0 THEN OP 9 OFF ELSE...

Page 145: ...he axes Frame transformations have to be specially written in the C language and downloaded into the controller It is essential to contact OMRON if you want to install frame transformations Arguments N A Example No example See also FRAME Type System command Syntax TRIGGER Description The TRIGGER command starts a previously set up SCOPE command Note Trajexia Tools uses TRIGGER automatically for its...

Page 146: ...s Arguments N A Example TRON MOVE 0 10 MOVE 10 0 TRON MOVE 0 10 MOVE 10 0 See also SELECT TROFF Type Constant read only Syntax TRUE Description The TRUE constant returns the numerical value 1 Arguments N A Example test t IN 0 AND IN 2 IF t TRUE THEN PRINT Inputs are ON ENDIF See also N A Type System parameter read only Syntax TSIZE Description The TSIZE parameter returns the size of the TABLE arra...

Page 147: ...e rev is equal to 5mm Therefore there are 4 000 5 800 edges mm UNITS is thus set as following UNITS 1000 4 5 See also AXIS ENCODER_RATIO Type Axis parameter Syntax VERIFY Description The verify axis parameter is used to select different modes of operation on a stepper encoder axis VERIFY OFF Encoder count circuit is connected to the STEP and DIRECTION hard ware signals so that these are counted as...

Page 148: ...ample Wait until at command speed MOVE 100 WAIT UNTIL SPEED VP_SPEED See also AXIS MSPEED UNITS Type System command Syntax VR address Description The VR command reads or writes the value of a global VR variable These VR variables hold real numbers and can be easily used as an element or as an array of elements The TJ1 MC__ has in total 1024 VR variables The VR variables can be used for several pur...

Page 149: ...necessary to provide a means of resetting completely following manual intervention Example loop Assign VR 65 to VR 0 multiplied by axis 1 measured position VR 65 VR 0 MPOS AXIS 1 PRINT VR 65 GOTO loop See also CLEAR_BIT READ_BIT SET_BIT TABLE Type System command Syntax VRSTRING vr_start Description Combines the contents of an array of VR variables so that they can be printed as a text string All p...

Page 150: ...en you check MTYPE 0 it is 0 because the movement HAS NOT STARTED YET not because it has finished See also AXIS WAIT LOADED Note WAIT IDLE is a command specifically designed to wait until the previous movement has been finished so it is handles the delay from when the previous command is executed in the program until the command is correctly loaded in the motion buffer Type System command Syntax W...

Page 151: ...be disabled when a MOTION_ERROR occurs A motion error occurs when the AXISSTATUS state for one of the axes matches the ERRORMASK setting In this case the software switch WDOG will be turned off the MOTION_ERROR parameter will have value 1 and the ERROR_AXIS parameter will contain the number of the first axis to have the error Note The WDOG parameter can be executed automatically by Trajexia Tools ...

Page 152: ... valid BASIC expressions The logical XOR function between two bits is defined as in the table below Arguments expression1 Any valid BASIC expression expression2 Any valid BASIC expression Example VR 0 10 XOR 18 The XOR is a bit operator and so the binary action taking place is as follows 01010 XOR 10010 11000 The result is therefore 24 See also N A Bit 1 Bit 2 Result 0 0 0 0 1 1 1 0 1 1 1 0 I52E E...

Page 153: ...e command line and the IP address of the TJ1 MC__ shows on the command line Unit Interface Protocol Comment TJ1 MC__ Ethernet Trajexia Tools protocol To program monitor and debug the project with Trajexia Tools FINS server To communicate with any FINS master for example PLC HMI or personal computer FINS client To communicate to any FINS server for example PLC or another Trajexia unit Serial Host L...

Page 154: ...0 4 2 1 Communicate with Trajexia directly from your computer 1 Do not change the Ethernet settings in Trajexia fig 1 2 Set the Trajexia Tools settings as shown fig 2 3 Set your computer settings as shown I52E EN 03 book Seite 154 Freitag 29 Juni 2007 11 55 11 ...

Page 155: ...he server assigns an IP address to the computers automatically 1 Set the IP address the Subnet Mask and the gateway from the Terminal window command line in Trajexia with Ethernet 1 1 0 10 83 50 70 Ethernet 1 1 2 255 255 240 0 Ethernet 1 1 8 10 83 48 1 fig 4 2 Check that the IP settings of the local Trajexia system and the remote computer are as shown After power on the TJ1 MC__ display shows alte...

Page 156: ... the port with the command Ethernet 1 1 12 new_port_n Unlike the standard Ethernet commands this command takes effect immediately after execution The port changes to default at power on Therefore this command needs to be included in any program that is executed at power on The FINS commands allow communications between nodes in different networks A FINS master device can read and write the Trajexi...

Page 157: ... designation error Number of elements invalid 1104 Address out of range 01 01 00 00 command_code response_code word_1 word_2 01 01 00 00 command_code response_code dword_1 Note The returned words and dwords are in big endian format Parameter Values hex 01 02 00 command_c ode var_ type start_ address fixed total_words word 1 01 02 C2 00 command_c ode var_t ype start_ address fixed total_ words dwor...

Page 158: ...slave User defined protocol 4 3 1 Host Link master If the TJ1 MC__ is the Host Link master you can send BASIC commands to a Host Link slave for example a PC When you send a BASIC command to a Host Link slave the execution of the next BASIC command waits until the Host Link slave sends a response You can use these BASIC commands i Condition Response code hex Description All elements valid 0000 OK V...

Page 159: ...rt and enables the Host Link protocols BASIC command Description Type Header code Name Function I O memory reading RR CIO AREA READ Reads the specified number of words beginning with the designated CIO IR word RL LR AREA READ Reads the specified number of words beginning with the designated LR word RH HR AREA READ Reads the specified number of words beginning with the designated HR word RD DM AREA...

Page 160: ...ica tions processing XZ ABORT command only Aborts the operation that is per formed by a Host Link command and returns to the initial status INITIALIZE com mand only Initializes the transfer control proce dures for all Host Link units IC Undefined com mand response only This is the response when the com mand header code is invalid Type Header code Name Function Note The Host Link protocol supports ...

Page 161: ... 01 Not executable in RUN mode The command that was sent can not be executed when the PC is in RUN mode Check the relation between the com mand and the PC mode 13 FCS error The FCS is wrong Influence from noise transfer the command again Header code Name BASIC command required RUN MON PRG 14 Format error The command format is wrong A command that cannot be divided has been divided The frame length...

Page 162: ...rt uses RS422 communication i i Bit Name Description 0 7 End code The end code is the end code defined by the Host Link slave when a prob lem occurred in the data string of the sent command or an end code defined by the Host Link master when a prob lem occurred in the data string of the received response 8 Timeout error A timeout error occurs if no response is received within the time out period T...

Page 163: ...C0052 Result The PC runs in MON mode Note that this is necessary for writing data to the PC using HLM_WRITE Example Reading PC model code using HLM_COMMAND timeout BASIC code HLM_TIMEOUT 500 Destination address VR 100 HLM_COMMAND HLM_MREAD 2 13 MC_VR 100 Host Link communication From Host Link master to Host Link slave 13MM42 From Host Link slave to Host Link master no response Result Because the m...

Page 164: ... cedures for all Host Link units IC Undefined com mand response only This is the response when the command header code is invalid Type Header code Name Function End code Description Probable cause Solution 0 Normal completion No problem exists N A 13 FCS error The FCS is wrong Check the FCS calcu lation method If there was influence from noise transfer the command again 14 Format error The command...

Page 165: ...he command format did not match the number of bytes in the second or later frame Correct the command data and transfer the command again A5 Aborted due to entry number data error in transmission data There was an entry number data error in the second or later frame or a data length error Correct the command data and transfer the command again A8 Aborted due to frame length error in trans mission d...

Page 166: ...n PRINT SCENE ENDIF Check response GOSUB read_buffer GOTO loop read buffer count 0 resp_status 0 k 1 TICKS 5000 REPEAT IF KEY 1 THEN count count 1 GET 1 k PRINT k count TABLE count k PRINT count ENDIF UNTIL TICKS 0 OR k 13 PRINT Received count 0 characters FOR i 1 TO count IF TABLE i 13 THEN PRINT CHR TABLE i ELSE PRINT cr ENDIF NEXT i IF TICKS 0 THEN PRINT Timeout in the communication with the F5...

Page 167: ...e TJ1 PRT You must assign an address to the TJ1 PRT before you set the power of the Trajexia system on To initialise the TJ1 PRT use the BASIC PROFIBUS command PROFIBUS unit_number 2 1 output_start output_count input_start input_count where unit_number is the number of the TJ1 PRT unit output_start is the start address of the output data range of VR variables output_count is the number of VR varia...

Page 168: ...he TJ1 PRT unit is as follows 1 Set the unit number with the two rotary switches of the TJ1 PRT unit fig 5 2 Switch on the power to the system The RUN LED lights The ERH LED flashes 3 Create a BASIC Program containing the command PROFIBUS 2 2 1 10 7 150 3 In this example the system initializes a TJ1 PRT unit with unit number 2 The system sends seven output words from the master to the VR s 10 to 1...

Page 169: ...0 fig 6 1 Start the CX PROFIBUS software tool 2 Right click the MyNetwork tree 3 Select Add Device fig 7 4 Select the PROFIBUS master board 5 Click OK fig 8 6 Open the Device Catalogue from the View menu I52E EN 03 book Seite 169 Freitag 29 Juni 2007 11 55 11 ...

Page 170: ...click Add Device fig 10 10 Double click the TJ1 PRT slave module in the MyNetwork tree 11 Set the node number in the Station Address field 12 Add Insert input and output modules to the configuration list below 13 Make sure that the quantity of input words and output words in the selected modules are equal to the quantity selected with the PROFIBUS command 14 Click OK To configure the CJ1W PRM21 wi...

Page 171: ... Double click the master module in the MyNetwork tree 2 Set the Station Address and Unit Number fig 12 3 Select the Slave area tab 4 Set the Start Address field of Output Area 1 and Input Area 1 5 Save the project I52E EN 03 book Seite 171 Freitag 29 Juni 2007 11 55 11 ...

Page 172: ... information to the TJ1 MC__ You can retrieve the status information in BASIC with the command PROFIBUS unit_number 4 0 The result provides the following information i Bit Value Description 0 0 Failed configuration of I O data exchange 1 I O data exchange configured successfully 1 0 I O data not available 1 I O data available 2 0 Data exchange active in OPERATE mode 1 Data exchange active in CLEAR...

Page 173: ...nge from 0 to 63 If you select a node number with the node number selectors that exceeds this range you will select the node number that is set by software The nodes that enable software setting are 64 to 99 To initialise the TJ1 DRT use the BASIC DEVICENET command DEVICENET unit_number 2 1 output_start output_count input_start input_count where unit_number is the number of the TJ1 DRT unit output...

Page 174: ...anges from 32768 to 32767 A VR variable can hold a 24 bit number and it can also hold fragments The exchange with the DeviceNet master does not support values outside the range 32768 to 32767 or fragments Note The maximum number of VR variables to exchange data is 32 Note If you use an OMRON DeviceNet master it is advised to select either input_count or output_count with a value of 4 8 16 or 32 fo...

Page 175: ...hange VR variables with the Trajexia system do these steps fig 14 1 Start the CX Integrater in the CX ONE software tool 2 Select Network from the Insert menu 3 Select DeviceNet from the Select Network screen The Network view shows fig 15 4 Select CJ1W DRM21 from the OMRON Communication adapter list I52E EN 03 book Seite 175 Freitag 29 Juni 2007 11 55 11 ...

Page 176: ...UAL 176 Revision 3 0 5 Drag and drop the CJ1W DRM21 to the Network window fig 16 6 Install the EDS file from the CX Integrator 7 Select No from the dialog window The icon is not needed I52E EN 03 book Seite 176 Freitag 29 Juni 2007 11 55 11 ...

Page 177: ...p 12 Click Connection tab 13 Click User Setup 14 Click Use Poll Connection 15 Select Con Path 16 Select the number of variables that has been selected for the DeviceNet communication 17 Click OK to confirm all dialog boxes 18 Select Work Online from the Network menu 19 Select Parameter from the Component menu 20 Right click on the Master icon 21 Select Parameter Download I52E EN 03 book Seite 177 ...

Page 178: ...e TJ1 DRT DeviceNet parameters using a DeviceNet configurator The default level is 11V Bit Value Description 0 0 DeviceNet unit_number 2 not executed yet 1 DeviceNet unit_number 2 executed without error 1 0 No DeviceNet I O connection 1 DeviceNet I O connection running 2 0 VR variables in the output data range have been updated 1 VR variables in the output data range have not been updated yet 3 0 ...

Page 179: ...reference command to the MECHATROLINK slaves The slaves send feedback and status information to the TJ1 ML__ The MECHATROLINK II uses a synchronization clock and broadcast messaging to make sure that all the slaves execute the commands at the same time In addition other information is transferred at a lower rate for example the reading and writing of parameters There are specific BASIC commands to...

Page 180: ... Motion Perfect 2 CX Server CX Drive to program and setup the Servo Drivers and Inverter The Trajexia Tools can be used to program via serial communication other OMRON motion controllers C200HW MC402E R88A MCW151 E and R88A MCW151 DRT E 5 2 Specifications and connections 5 2 1 PC Specifications The PC specification for the use of Trajexia Tools are i Use the most recent version of Trajexia Tools U...

Page 181: ...Trajexia Tools Setup program starts automatically 3 If the Trajexia Tools Setup program does not start automatically start it manually execute setup exe in the root directory of the CD fig 1 4 Select the language you want to use from the drop down list Click OK fig 2 5 The Trajexia Tools Setup window shows Click Next I52E EN 03 book Seite 181 Freitag 29 Juni 2007 11 55 11 ...

Page 182: ...e fig 4 7 Type your name in the Name field 8 Type your company name in the Company field 9 Type your user licence number in the Licence fields Your user licence number is on the label attached to the jewel case of the Trajexia Tools CD 10 Click Next fig 5 11 Click Yes I52E EN 03 book Seite 182 Freitag 29 Juni 2007 11 55 11 ...

Page 183: ...Trajexia Tools interface PROGRAMMING MANUAL 183 Revision 3 0 fig 6 12 Click Next fig 7 13 Click Next I52E EN 03 book Seite 183 Freitag 29 Juni 2007 11 55 11 ...

Page 184: ...ace PROGRAMMING MANUAL 184 Revision 3 0 fig 8 14 Click Next fig 9 15 Click Next 16 The Trajexia Tools Setup program copies files to your PC This can take a few minutes I52E EN 03 book Seite 184 Freitag 29 Juni 2007 11 55 11 ...

Page 185: ...Trajexia Tools interface PROGRAMMING MANUAL 185 Revision 3 0 fig 10 17 Click Finish The CX Drive Readme File window shows Close this window I52E EN 03 book Seite 185 Freitag 29 Juni 2007 11 55 11 ...

Page 186: ...cable to the Ethernet port of the TJ1 MC__ The IP address of the TJ1 MC__ shows 4 times in the LED display 5 When you start Trajexia tools software it tries to communicate with the controller When you start Trajexia Tools for the first time the communication settings are not the suitable ones so you have to cancel see fig 12 and set your communication settings A Note If you work off line the simul...

Page 187: ...gram on your PC Select from the Windows Start menu Programs OMRON Trajexia Tools Trajexia Tools 7 The Trajexia Tools startup screen shows Wait until the Cancel button is visible Then click Cancel fig 13 8 Select the menu Options Communications I52E EN 03 book Seite 187 Freitag 29 Juni 2007 11 55 11 ...

Page 188: ...NUAL 188 Revision 3 0 fig 14 9 Make sure ENet0 in the list is selected 10 Click Configure fig 15 11 Type 192 168 0 250 in the Server name IP address field 12 Click OK fig 16 13 Click OK I52E EN 03 book Seite 188 Freitag 29 Juni 2007 11 55 11 ...

Page 189: ...anel on your PC 15 Double click on the Network Connections icon 16 Right click on the Local Area Connection icon Click on the Properties menu fig 18 17 Click on the General tab 18 Select Internet Protocol TCP IP in the list 19 Click Properties I52E EN 03 book Seite 189 Freitag 29 Juni 2007 11 55 11 ...

Page 190: ...on the General tab 21 Select Use the following IP address 22 Type 192 168 0 251 address in the IP address field 23 Type 255 255 255 0 in the Subnet mask field 24 Click OK 25 Click OK 26 Close the Network Connections screen I52E EN 03 book Seite 190 Freitag 29 Juni 2007 11 55 11 ...

Page 191: ...ncy between the project on the PC and the Trajexia system Programs that are edited are automatically duplicated on the PC A Trajexia Tools project consists of a project prj that contains the Trajexia configuration the Servo Driver parameters and a set of bas programs Those files are stored in a folder with the same name or the prj file Note A program that is made on one computer cannot be cor rect...

Page 192: ...ore you save to the PC make sure that the program on the PC has a back up copy first Load Downloads the project that is in the PC to the Trajexia system The project on the Trajexia system is overwritten Before you load to the Trajexia system make sure that the program on the Trajexia system has a back up copy first Change Lets you open a project that is on your PC that is different to the default ...

Page 193: ...he project that is on the Trajexia Tools with the project that is on the PC This option offers the possibility to Save Load or Examine the differences individually for each individual program inside the project This option allows a modification of a program off line using the simulator and a download of the same program to the TJ1 MC__ This option also allows more than one person work on the same ...

Page 194: ...ace 5 Status bar 5 4 1 Control panel The control panel allows a quick and easy way of accessing to the most commonly used controls to handle and commission a project 5 4 2 Menu bar The menu bar has these items Project Controller Program Tools External Options Window Help The menus are described in detail in section Menu descriptions p 196 1 2 3 4 5 I52E EN 03 book Seite 194 Freitag 29 Juni 2007 11...

Page 195: ...is and motion parameters This helps to program development and system commissioning Refer to oscilloscope in the Tools menu p 205 Keypad Not implemented in Trajexia Jog Axis This window allows the user to manually move the axes on the Trajexia Refer to Jog Axis in the Tools menu p 205 Digital IO Refer to Digital IO Status in the Tools menu p 205 Analog input Refer to Analog input in the Tools menu...

Page 196: ...exia system The project on the Trajexia system is overwritten Before you load to the Trajexia system make sure that the program on the Trajexia system has a back up copy first Save project as Uploads the project that is in the Trajexia system to the PC and saves as to a directory on the hard drive of the PC Check project A check is made between the Project on the Trajexia system and the PC The che...

Page 197: ...Load table A list of table values can be loaded from an external file with the extension lst or bas It imports the values and stores it in TABLE values Save table file Saves a lst or bas file from TABLE values to the project directory Load program file Loads a file that contains code that can be executed in a task Save program file Saves the program file as in txt format Recent projects You can op...

Page 198: ...xia Tools is disconnected from the system Disconnect Disconnects from the Trajexia system Available when the Trajexia Tools is connected to the system Connect to simulator Not fully implemented for Trajexia Reset the controller Do a software reset on the Trajexia system The Trajexia Tools application disconnects from the Trajexia system Recover project from EPROM Resets the Trajexia system and res...

Page 199: ...oller The PC is connected to a Trajexia Motion Controller TJ1 MC__ with 1 64 Dev 94 software The servo period is 1000μs Axis Shows the axes that are available Comms The communication capability of the Trajexia Motion Controller I O The type and range of the digital analog and virtual inputs and outputs CANIO Not implemented for Trajexia I52E EN 03 book Seite 199 Freitag 29 Juni 2007 11 55 11 ...

Page 200: ...ardware address that uniquely identifies each node of the network This address is read only Normal Communications Port Number The TCP port used to communicate with Trajexia Tools Token Communications Port Number The TCP port used to communicate with PC Motion ActiveX control Enable features Not implemented for Trajexia Enable editing Sets the Trajexia to work with the RAM version of the programs I...

Page 201: ...f the project and that you wish to continue A standard file selector opens Select the file you need A windows dialog box opens to make sure you wish to continue Press OK to start The flash EPROM process will take approximately 7 minutes OMRON recommends that you load a new version of the system software only when you are advised to do so by your distributor or by OMRON Caution Do not load software...

Page 202: ... 28 Use to check the contents and file structure of the TJ1 MC__ directory Lock Unlock Lock the Trajexia system to prevent unauthorised access When the Trajexia system is locked it is not possible to list edit or save any of the Trajexia programs The Trajexia system is not available through the Trajexia Tools software although the terminal and unlock dialog boxes are available Type a 7 digit numbe...

Page 203: ... replace and printing are all supported and conform to the standard Windows short cut keys In addition it provides BASIC syntax highlighting program formatting and program debugging facilities Debug Checks the syntax of a program and gives possible solutions The program is opened in a special trace mode that executes line by line You can set breakpoints in the program to run the program until the ...

Page 204: ...he current program in the specified process in the step mode line by line Stop The Stop command stops the program in the TJ1 MC__ controller This is not the same as Motion Stop The program stops at the end of the CPU cycle The servo motors maintain position Stop all The Stop all command stops all programs in the TJ1 MC__ controller This is not the same as Motion Stop The programs stop at the end o...

Page 205: ...Power Up dialog window Select the program you want to run automatically A small drop down menu appears to the right of the window If you want Trajexia to allocate the process to run in choose default as the process number You can also specifically select the process 5 5 4 Tools menu fig 31 The Trajexia Tools tools can be accessed by the Tools Menu or the Toolbar button I52E EN 03 book Seite 205 Fr...

Page 206: ...and monitors the status of external inputs The separator that divides the two banks of data can be moved by the mouse When the user changes a unit parameter all parameters that use this parameter value are re read and adjusted by this factor Examples of the types of parameters that are affected by this parameter are SPEED ACCEL MPOS The parameter axistatus shows the status of the axis The colour o...

Page 207: ...en is first displayed or when the parameter value is set If a parameter value is changed the value displayed may be incorrect The refresh button forces Trajexia Tools to read the complete selection again e Following Error x Forward Soft Limit y Reverse Soft Limit c Cancelling Move o Encoder Error char Description Note If you change a parameter value you must refresh the display before making anoth...

Page 208: ...TARTUP program creates a STARTUP program for the detected configuration In the tab corresponding to the TJ1 ML__ you can see the information corresponding to the detected MECHATROLINK II slaves including Inverter and I O modules fig 34 Clicking the Config button only available for servo and inverter the next window appears Status tab Drive ID Motor ID Firmware Version Shows information of the Serv...

Page 209: ...the drive at the same time from either the programs or via FINS independently of the mode fig 35 Launch CX Drive From Trajexia Tools it is only possible to read and write parameters of a Servo Driver If more Servo Driver functionality is needed for example Read alarm code Jog Set rigidity Autotuning it is necessary to launch CX Drive Clicking this button starts CX Drive connected to the current ax...

Page 210: ... four channels each capable of recording 1 sample per SERVO_PERIOD with manual cycling or program linked triggering The controller records the data at the selected frequency and uploads the information to the oscilloscope to be displayed If a larger time base is used the data is retrieved in sections and the graphic is plotted in section across the display The moment the controller starts to recor...

Page 211: ... has completed the recording before the oscilloscope displays the trace When the oscilloscope runs with continuous triggering the oscilloscope is unable to select a suitable vertical scale The oscilloscope must be stopped and restarted In manual mode the user selects the most appropriate scale Y Shift The vertical offset value is used to move a trace vertically on the display This control is usefu...

Page 212: ...uns until the oscilloscope is triggered and one set of data recorded by the controller is retrieved and displayed In continuous trigger mode the oscilloscope continues to run and retrieve data from the controller each time the oscilloscope is triggered and new data recorded The oscilloscope continues to run until the trigger button is clicked for a second time Trigger halt data capture When the tr...

Page 213: ... controller Set capture options When this option button is clicked the advanced oscilloscope configuration settings dialog box is displayed Advanced Oscilloscope options General information Displaying Controller Table Points If the oscilloscope is configured for both table and motion parameters then the number of points plotted across the display is determined by the time base and samples per divi...

Page 214: ... mode the table data is not re read only the motion parameters are con tinuously read back from the controller Enabling Disabling of oscilloscope controls Whilst the oscilloscope is running all the oscilloscope con trols except the trigger button are disabled Hence if it is necessary to change the time base or vertical scale the oscilloscope must be halted and re started Display accuracy The contr...

Page 215: ...value to exceed the maximum permitted value on the controller then the original value is used by the oscilloscope Table Data Graph It is possible to plot controller table values directly the table limit text boxes enable the user to enter up to four sets of first last table indices Parameter checks If analogue inputs are being recorded then the fastest oscilloscope resolution sample rate is the nu...

Page 216: ...outputs OP 8 to OP 15 are the digital outputs built in in TJ1 MC__ Additional Digital outputs in the system are mapped automatically starting from OP 32 Input Output Banks I O These represent virtual I Os that you can use inside the program as user flags Setting one of those virtual outputs makes the corresponding virtual input to be set too If an indicator is grey then its corresponding input or ...

Page 217: ...function is DISABLED and when the input is off 0 V then the jog function is ENABLED The jog functions implemented here disable the fast jog function which means that the speed at which the jog will be performed is set by the JOGSPEED axis parameter What is more this window limits the jog speed to the range 0 demand speed where the demand speed is given by the SPEED axis parameter Before allowing a...

Page 218: ...alue to the range from zero to the demand speed for this axis where the demand speed is given by the SPEED axis parameter This value can be changed by writing directly to this control or using the jog speed control The scroll bar changes the jog speed up or down in increments of 1 unit per second Jog inputs These are the inputs which will be associated with the forward reverse jog functions They m...

Page 219: ... and press return The change will become active immediately and can be made whilst programs are running Options Range Both tools have the option to set the start and end of the range to view In the TABLE view tool the max value displays the highest readable value this is the system parameter TSIZE If the range of values is larger than the dialog box can display then the list will have a scroll bar...

Page 220: ...a Trajexia have been automated by the options available in the Trajexia Tools menu options However if direct communication is required the terminal window may be used fig 44 Select channel When Trajexia Tools is connected to the controller the terminal tool will show a dialog to select the communications channel Channel 0 is used for the Trajexia command line and channels 5 6 and 7 are used for co...

Page 221: ...cation settings The settings can only be changed offline The different options are Serial for other OMRON motion controllers C200HW MC402 E and R88 MCW151 E USB is not used Simulation Used to work offline a virtual motion control system is simulated Ethernet is the option used for Trajexia PCI is not used Editor Edits the different options of the text editor I52E EN 03 book Seite 221 Freitag 29 Ju...

Page 222: ...Tools interface PROGRAMMING MANUAL 222 Revision 3 0 General Options fig 47 Allows to set various options of the system CAN Drive Not implemented in Options I52E EN 03 book Seite 222 Freitag 29 Juni 2007 11 55 11 ...

Page 223: ... to be displayed in the terminal window Very useful for commissioning Program Compare Allows to compare programs CX Drive Configuration Allow to select the directory of the CX Drive Database FINS Configuration Selects the port and the timeout for the FINS communication Language At the moment only English has been implemented I52E EN 03 book Seite 223 Freitag 29 Juni 2007 11 55 11 ...

Page 224: ...o quickly handle and configure your desktop according to the user needs Clear Controller Messages Clear the Controller Messages window 5 5 7 Help Menu fig 50 Motion Perfect Help of the Trajexia Tools Trio BASIC Language Help of the BASIC commands and parameters About Motion Perfect 2 Shows the version of Trajexia Tools I52E EN 03 book Seite 224 Freitag 29 Juni 2007 11 55 11 ...

Page 225: ...ion is the configuration existing in the moment you create the program The STARTUP program does these actions Checks the number of nodes in the system Checks that the node numbers agrees Checks if all devices are connected and have power Any non agreement the program stops Sets the correct ATYPE as selected in the intelligent axis window Sets the mode Run or Commisioning How to use the Startup pro...

Page 226: ...of the section created automatically put your own application code Typically variable initialisation and axes parameters 4 At the end of the STARTUP program run your application programs It is recommended to run the SHELL program explained later in this section 5 Set the STARTUP program to run at power on I52E EN 03 book Seite 226 Freitag 29 Juni 2007 11 55 11 ...

Page 227: ...d devices Unit 0 IF NOT MECHATROLINK 0 3 0 THEN PRINT Error getting device count for unit 0 STOP ELSE IF VR 0 3 THEN PRINT Incorrect device count for unit 0 STOP ENDIF ENDIF IF NOT MECHATROLINK 0 4 0 0 THEN PRINT Error getting address for unit 0 station 0 STOP Note OMRON recommends that the statement RUN your_program is used at the end of the Startup pro gram to start your application program The ...

Page 228: ...ing address for unit 0 station 2 STOP ELSE IF VR 0 67 THEN PRINT Incorrect address for unit 0 station 2 STOP ENDIF ENDIF Set axis types Unit 0 ATYPE AXIS 0 40 ATYPE AXIS 1 40 ATYPE AXIS 2 40 Set drives into run mode Unit 0 MECHATROLINK 0 20 65 MECHATROLINK 0 20 66 MECHATROLINK 0 20 67 Stop MECHATROLINK Section THIS SECTION MUST BE MANUALLY SET BY THE USER ACCORDING TO THE APPLICATION TYPICAL ACTIO...

Page 229: ...ere are three main concepts Inertia ratio Rigidity Resonant frequency These concepts are described in the Hardware Reference Manual in the chapter System Philosophy This section shows example parameter values for Speed Loop Gain Proportional position gain Velocity Feed Forward gain The example values for the program and motion parameters in the Trajexia system are given below Note that they are ap...

Page 230: ...E 81920 WAIT IDLE WA 100 DEFPOS 0 GOTO loop Example 1 Pn202 1 Gear ratio numerator Pn203 1 Gear ratio denominator Motion Parameter values Description UNITS 1 Working in encoder counts SPEED 200000 Speed setting ACCEL 1000000 Acceleration setting DECEL 1000000 Deceleration setting MOVEMENT 81920 10 Turns Drive Parameter value Description Profile generator Following Error Demanded Position Measured ...

Page 231: ... example are i Motion Parameter values P_Gain 131072 VFF_GAIN 0 Fn001 4 Note The colours and scale of the oscilloscope for speed mode are as follows Red MSPEED Measured Axis speed Units is 50 units ms division Blue FE Following Error Units is depending on the graph Green MPOS Measured Axis position 50000 units divi sion I52E EN 03 book Seite 231 Freitag 29 Juni 2007 11 55 11 ...

Page 232: ...d overshoot are better The parameter values for the example are i Example 3 fig 6 The parameter P_GAIN is increased further The Following Error decreases proportionally The parameter values for the example are i Motion Parameter values P_Gain 131072 VFF_GAIN 0 Fn001 6 Motion Parameter values P_Gain 200000 VFF_GAIN 0 Fn001 6 I52E EN 03 book Seite 232 Freitag 29 Juni 2007 11 55 11 ...

Page 233: ... Example 5 fig 8 The value of the parameter P_GAIN is set to the value in example 1 The value of VFF_GAIN is increased The Following Error is reduced without a reduction to the stability The Following Error is not proportional to the speed The parameter values for the example are i Motion Parameter values P_Gain 262144 VFF_GAIN 0 Fn001 6 Motion Parameter values P_Gain 131072 VFF_GAIN 1400000 Fn001...

Page 234: ...oot when the acceleration changes this can be reduced but not eliminated by increasing the speed loop gain if the mechanical system can cope with a high gain The parameter values for the example are i Example 7 fig 10 The value of the rigidity is increased from 6 to 8 The overshoot undershoot is smaller but the motor has more vibration The parameter values for the example are i Motion Parameter va...

Page 235: ...ion loop in the Servo Driver the Demand_Position in cycle n with the Measured_Position in cycle n The Trajexia for the internal handling continues to use its own position loop so the Following Error that read in the Axis parameter in Trajexia is not the real one in the Servo drive To read the correct Following Error use DRIVE_MONITOR Adjust the rigidity of the servo the speed loop gain and the pos...

Page 236: ... mode SERVO 1 DRIVE_CONTROL 2 To monitor the Following Error in DRIVE_MONITOR WDOG 1 DEFPOS 0 loop MOVE 81920 WAIT IDLE WA 100 DEFPOS 0 GOTO loop Example 1 fig 13 The Following Error is proportional to the speed There is a soft profile due to the low rigidity setting low gain The parameter values for the example are Note The colours and scale of the oscilloscope for position mode are as follows Re...

Page 237: ...example are i Example 3 fig 15 With high gain the motor starts to vibrate but the profile is more stable that in MECHATROLINK II Speed mode The parameter values for the example are i Motion Parameter values Fn001 4 Pn109 0 Motion Parameter values Fn001 6 Pn109 0 Motion Parameter values Fn001 8 Pn109 0 I52E EN 03 book Seite 237 Freitag 29 Juni 2007 11 55 11 ...

Page 238: ...5 fig 17 With the feedforward set to 100 the Following Error is very small and proportional to the acceleration The optimum value of 100 correction is the maximum value that can be set The parameter value of Pn109 is easier to set than the parameter value of VFF_GAIN The parameter values for the example are i Motion Parameter values Fn001 6 Pn109 95 Motion Parameter values Fn001 6 Pn109 100 I52E E...

Page 239: ...define the most convenient units to work with For example for a moving part that makes a linear motion you can prefer mm or fraction of mm For a moving part that makes a rotation motion you can prefer a degree of angle or its fraction For more information on the UNITS axis parameter see section 3 2 270 However the user must be aware that not only the UNITS axis parameter matters in the conversion ...

Page 240: ...he ratio between user units that the user wants to use in the program and the position sent to the Servo Driver via the MECHATROLINK II bus Taking the electronic gear setting into account the equation expressing the relation between user units the UNITS parameter parameters Pn202 and Pn203 encoder pulses and mechanical measurement units is where y is the number of encoder counts and x is the amoun...

Page 241: ...s 2 UNITS must not have an infinite number of decimal digits This can create rounding errors that result in small position errors that add up to large accumulative position errors 3 For reasons of stability it is necessary to avoid situations where Pn202 Pn203 is less than 0 01 or greater than 100 We can now rewrite the last equation to 1 10 Gear 13 bit incremental encoder Full turn 360 M 1 motor_...

Page 242: ... current motor position even if there is no power supplied The absolute encoder gives the position within one turn that is a fraction from 0 to and excluding 1 and it has a multiturn counter You can set the multiturn behaviour of the absolute encoder with the parameter Pn205 of the Sigma II Servo Driver This parameter adjusts the maximum number of turns that the counter counts before it has an ove...

Page 243: ...d be set large enough to have an overflow of the counter out of the effective position This is called limited axis or finite axis A typical example of a limited axis is a ball screw as shown in fig 24 When the mechanical system always moves in the same direction it reaches the overflow of the multiturn counter In this case the value of Pn205 must guarantee that the overflow always occurs in the sa...

Page 244: ...is equation gives This results in We calculate the parameters as we did in example 1 This gives To guarantee the correct overflow both in Trajexia and in the Servo Driver we must set two additional axis parameters REP_DIST 60 and REP_OPTION 1 With these settings the command MOVE 35 rotates the table 35 degrees in positive direction The range of possible MPOS and DPOS values is from 0 degrees to 60...

Page 245: ...s not possible to reset the position within one turn the fraction from 0 to and excluding 1 To adjust zero offset use the parameter Pn808 For more details see the NS115 MECHATROLINK II Interface Unit manual At power up the absolute encoder position is read from the motor and written to MPOS using the following con version For MPOS This is correct if If this value is greater than 5 000 000 MPOS can...

Page 246: ...tween user units and encoder counts is Therefore One solution is Note that we have not used the pulley radius in the calculation This is to avoid the use of π which cannot be expressed as a fractional number In toothed pulleys the number of teeth and mm per tooth is commonly used The calculation of the multiturn limit setting is 17 bit absolute encoder 1 6 31 Gear r 320 2 PI 1 turn 320mm move Tota...

Page 247: ...hanical measurement units must be tenths of an angle degree Therefore the total repeat distance for the full turn of the moving part is 3600 tenths of an angle degree With the same procedure as in example 1 we have Therefore m motor_revolution n machine_cycle m motor_revolution n machine_cycle 4160 pulley_revolution 320 machine_cycle n 13 pulley_revolution n 13 6 31 motor_revolution 1 pulley_revol...

Page 248: ...nt solution is n 100 and m 1224 Or when we simplify the factors n 25 and m 306 Therefore Pn205 m 1 305 With these settings executing MOVE 180 moves the moving part 180 tenths of an angle degree or 18 angle degrees in forward direction UNITS 2 131072 Pn202 1224 Pn203 360000 17 UNITS 131072 Pn202 17 Pn203 500 Pn205 16 REP_DIST 3600 REP_OPTION 1 m motor_revolution n machine_cycle n 12 24 motor_revolu...

Page 249: ...1 we have Therefore if we use the mechanical system to set the electronic gear ratio we have One possible solution is Because 217 50 is a number with an infinite number of decimal digits we can choose the following M 17 bit absolute encoder 1 10 Gear Pulley 12 teeth 50mm between teeth Main Wheel 144 stations 50 mm between stations Pn202 Pn203 UNITS 2 17 encoder_counts 1 motor_revolution 1 pulley_r...

Page 250: ...ution The total travel distance of the ball screw is 540 mm The mechanical measurement units must be mm With the same procedure as in example 1 we have Therefore One solution is UNITS 2 32768 15 Pn202 1 Pn203 15 Pn205 4 REP_DIST 50 REP_OPTION 1 17 bit absolute encoder M 1 3 Gear 10mm 540mm Pn202 Pn203 UNITS 2 17 encoder_counts 1 motor_revolution 1 ballscrew_revolution 3 motor_revolution 10mm 1 bal...

Page 251: ...us Writing and reading them if they do not physically exist when the I O units are not connected has no effect Use the command OP to write and read these outputs All outputs are unique to the controller They are not accessed per axis The digital input range has three parts Digital inputs 0 15 These inputs physically exist on the TJ1 MC__ You can physically access them on the 28 pin screwless conne...

Page 252: ... axis 0 the CN1 41 input of the first driver assigned to that axis is used but for axis 3 the same input CN1 41 of the other driver the one assigned to axis 3 is used Therefore we say that those inputs are accessed per axis they are not unique for the whole controller In general these two inputs have a different status at the same time Also note that neither of these two inputs can be accessed usi...

Page 253: ... search sequences They are different in these areas The means used to detect limit positions of the moving part sensors switches etc Origin home position or reference Possible positions of the moving part related to limit positions and origin position Trajexia includes some pre defined basic homing sequences DATUM 0 This is not really an origin search This command sets DPOS MPOS and cancels the ax...

Page 254: ...05 properly and in accordance with the mechanical system and desired measurement units used in programming Those parameters have influence to the origin search especially if an absolute encoder is used For more information on setting these parameters see section 6 1 2 ON min limit switch origin limit switch moving part max limit switch encoder OFF ON OFF OFF ON OFF For safety reasons limit switche...

Page 255: ...t switches These scenarios depend on the position of the moving part when the power comes on The program example that does this origin search sequence is given below Absolute origin switch IN0 Left limit switch IN1 Right limit switch IN2 BASE 0 DATUM_IN 0 FW_IN 2 RV_IN 1 SERVO ON WDOG ON DATUM 4 WA 1 WAIT UNTIL MTYPE 0 OR IN 1 OFF IF IN 1 ON FORWARD WAIT UNTIL IN 0 ON WAIT UNTIL IN 0 OFF CANCEL DA...

Page 256: ... possible scenarios for origin search against limit switches depending on the position of the moving part on power on are shown in the figure The program example that does this origin search sequence is given below Origin and left limit switch IN0 Right limit switch IN1 BASE 0 DATUM_IN 0 SERVO ON WDOG ON DATUM 4 WA 1 WAIT IDLE ON OFF ON OFF min limit switch moving part max limit switch FORWARD REV...

Page 257: ...ate torque limit is required in order not to damage the mechanics during the origin search process The example for this homing procedure is shown in the figure The program example that does this origin search sequence is given below BASE 0 DRIVE_CONTROL 11 Monitor torque with DRIVE_MONITOR SERVO ON WDOG ON SPEED CREEP REVERSE WA 1 WAIT UNTIL DRIVE_MONITOR 100 Wait for particular amount of applied ...

Page 258: ...epending on the position of the moving part on power on are shown in the figure The program example that does this origin search sequence is given below Origin and left limit switch IN0 Right limit switch IN1 REV_IN 1 BASE 0 DATUM_IN 0 SERVO ON WDOG ON DATUM 6 WA 1 WAIT IDLE Static origin search forcing a position from a user reference This origin search procedure performs a static origin search b...

Page 259: ...or interrupted Only the position of an axis is stored This information can be used like other parameters or values in a program The registration information is available to a program immediately after the registration The advantage of registration is that it is done very quickly Therefore the axis position that is stored is very accurate To achieve this speed and accuracy registration is implement...

Page 260: ...er Registration in the Sigma II Servo Driver occurs when an axis assigned to the Sigma II Servo Driver is connected to the Trajexia system via the MECHATROLINK II bus There are three registration inputs on the Sigma II Servo Driver but only one hardware latch so only one input can be used at a time The physical inputs are in pins CN1 44 CN1 45 and CN1 46 on the 50 pins CN1 connector but Trajexia u...

Page 261: ...ma II Servo Driver with one difference There is only one physical input and one logical latch too so no settings of Servo DriverServo Driver parameters are necessary The physical input is associated to logical latch EXT1 and only the rising signal edge can be used for registration Registration in the TJ1 FL02 The TJ1 FL02 has two physical registration inputs and two latch circuits per encoder inpu...

Page 262: ...r to section 3 2 219 MARK is a flag that signals whether the position has been captured or not For the second registration input of the TJ1 FL02 the parameter MARKB is also available For more information refer to sections 3 2 170 and 3 2 171 REG_POS holds the captured axis position Only if the MARK flag signals that the position was captured successfully you can regard the REG_POS value as valid F...

Page 263: ...p WAIT UNTIL MARK 1 PRINT Position captured in REG_POS REGIST 0 WAIT UNTIL MARK 0 GOTO loop Position t Registration Input REG_POS xxx The trigger is active MARK 0 REGIST 0 REGIST 0 MARK 1 MARK 1 MARK 0 MARK 1 REG_POS Pos1 REG_POS Pos1 The trigger is active If the trigger is not active the registration is ignored The position information is available I52E EN 03 book Seite 263 Freitag 29 Juni 2007 1...

Page 264: ...PEN_WIN axis parameter or greater than the CLOSE_WIN parameter Exclusive windowing allows the registration to occur only outside the specified window of axis positions With this windowing function the registration events are ignored if the axis measured position is greater than the OPEN_WIN axis parameter or less than the CLOSE_WIN parameter When the windowing function is used the internal process...

Page 265: ...here is an uncertainty in the edges of the window when marks may be detected near the edges This is more notable for axes connected to the system via the MECHATROLINK II bus due to bus delays To compensate for these delays a user must set the window margins large enough Position t Registration Input REG_POS xxx The trigger is active MARK 0 REGIST 0 REGIST 0 MARK 1 MARK 0 MARK 0 MARK 1 REG_POS Pos1...

Page 266: ...ube by a mechanical mandrel and at the same time the tube is sealed vertically The feeder movement is intermittent and the feed length corresponds with the bag length Once the bag is fed the horizontal sealer closes the bag so it can be filled with the product After that the process starts again feeding the new bag Mandrel for bag forming Vertical sealer External encoder for slip compensation E Fe...

Page 267: ...ithout correction an error of 0 1 mm per bag is accumulated With a small number of bags the difference is not visible but after 500 bags the error is 50 mm which is a 25 of the bag length fig 39 When working with registration marks the motion controller executes an incremental movement to a certain position If during the positioning the registration mark is detected the target position is changed ...

Page 268: ...arts to be synchronized with the right position on the wood If the movement is started by the program upon detecting a signal from the photocell there is always at least one SERVO_PERIOD of time of uncertainty Instead the movement is started using the MOVELINK command with link_option 1 which means that the link to the master axis starts when the registration event occurs on link master axis The c...

Page 269: ...ting of the motion system For more information on the software oscilloscope and its features and capabilities refer to section 5 5 4 You can trigger the oscilloscope to start tracing given axis and system parameters in two ways manually or by a program Triggering manually is done using the oscilloscope tool The parameters are stored in the Table memory of the controller The range of the Table memo...

Page 270: ...ble memory The memory range used is defined by the parameters of the SCOPE command When the parameters are in the Table memory the oscilloscope can be configured to show a range of Table memory locations instead of axis and system parameters The exact moment when the tracing is started can be exactly determined because it is controlled by the TRIGGER command This means the start of tracing is sync...

Page 271: ... due to different conditions of the motion system The part of the program that creates the CAM table is Initial CAM values VR end_pos 15 current_end_pos VR end_pos FOR i 0 TO 999 TABLE i VR end_pos 1 COS 2 PI i 999 2 NEXT i loop IF VR end_pos current_end_pos THEN Recalculate the CAM Table FOR i 0 TO 999 TABLE i VR end_pos 1 COS 2 PI i 999 2 NEXT i current_end_pos VR end_pos ENDIF GOTO loop The VR ...

Page 272: ... in TABLE 2000 to TABLE 2999 Torque reference for AXIS 1 is stored in TABLE 3000 to TABLE 3999 MSPEED AXIS 1 is stored in TABLE 4000 to TABLE 4999 The capture covers 1000 samples 2ms sample 2seconds SCOPE ON 2 1000 4999 MPOS AXIS 0 DPOS DRIVE_MONITOR MSPEED FORWARD AXIS 0 Move the master axis forward TRIGGER Start tracing and storing of parameters WHILE NOT MOTION_ERROR Cambox that will start in A...

Page 273: ...Triggered ENDIF WAIT IDLE WEND HALT fig 44 To view the capture result in the oscilloscope of Trajexia Tools you must make the settings in the Oscilloscope Configuration window as given in the figure You must also disable further capturing to avoid mixing the results of two different captures in the same Table memory entries I52E EN 03 book Seite 273 Freitag 29 Juni 2007 11 55 11 ...

Page 274: ...ive of the cosine is the sine At high speeds there are some ripples The green graph is the torque of the motor for the slave axis set with DRIVE_COMMAND 11 as a percentage of the nominal torque The torque is proportional to the acceleration Because the acceleration is a derivative of the speed and the speed is sinusoidal curve the acceleration and also the torque is a cosine curve There is one pea...

Page 275: ...end this leads to a discontinuation of the profile which causes an indefinite speed of the axis and ends up with this error the WDOG goes off and all axes stop The scenario above is hard to analyze when you do not know what happens The only thing that the user sees is that the slave axis has an error once every few hours or even less often But the oscilloscope can clearly show where the problem is...

Page 276: ...r happens on any axis The data is already captured in the Table memory and we can start using the oscilloscope to see the status of the desired parameters at the moment the error occurred Following the scenario described above with the oscilloscope settings as in fig 44 the result is given in fig 46 The measured position of the master axis given in red does not seem to be the cause because there i...

Page 277: ...at the slave axis must follow Because the speed is a derivative of the position at the point of discontinuity of the position curve the speed gets a high value This value equals infinity in theory in practice the value is just very big This causes the error The red graph shows where the root of the problem is The amplitude of the cosine curve and therefore the end_pos parameter has been changed du...

Page 278: ...scontinuity in the CAM red graph coincides in time with the interrup tion of the movement To analyze this check the position values individually with a spreadsheet program To ana lyze the point values in detail you can export the TABLE points to a spreadsheet program for a more complex analysis I52E EN 03 book Seite 278 Freitag 29 Juni 2007 11 55 11 ...

Page 279: ...OF SHELL PROGRAM THIS VERSION IS DESIGNED FOR MECHATROLINK SERVOS ADAPT THIS PROGRAM ACCORDING TO YOUR APPLICATION IN THIS EXAMPLE ANY ERROR MAKES STOP ALL PROGRAMS AND MOVEMENTS STOP WE USE A GLOBAL VARIABLE VR 0 FOR PROGRAM MANAGEMENT VR 0 bit0 To start the application rising edge VR 0 bit1 To RESET all alarms rising edge VR 0 bit2 To STOP the application rising edge This example is for an appli...

Page 280: ...ng 3 OK action 3 GOSUB stop_all GOSUB start_application loop If Error or Stop command IF MOTION_ERROR 0 OR READ_BIT 1 0 THEN GOSUB alarm_sequence Clear the Servo Driver Warning if any IF DRIVE_STATUS AXIS 0 AND 2 0 THEN DRIVE_CLEAR AXIS 0 IF DRIVE_STATUS AXIS 1 AND 2 0 THEN DRIVE_CLEAR AXIS 1 IF DRIVE_STATUS AXIS 1 AND 2 0 THEN DRIVE_CLEAR AXIS 1 GOTO loop alarm_sequence IF MOTION_ERROR 0 THEN pro...

Page 281: ...XIS 1 ENDIF ELSE project_status 1 ENDIF GOSUB stop_all GOSUB reset_all GOSUB start_application RETURN stop_all STOP THE PROGRAMS STOP APPLICATION STOP THE AXES FOR i 0 TO max_axis BASE i CANCEL 1 Cancel NTYPE WA 1 CANCEL 1 Cancel possible program buffer CANCEL Cancel MTYPE NEXT i Release Run command in the servos WDOG 0 Open the position loop FOR i 0 TO max_axis BASE i WAIT IDLE SERVO 0 NEXT i RET...

Page 282: ...WA 3000 DATUM 0 RUN startup 1 STOP ENDIF In case of Servo Driver error IF AXISSTATUS AND 8 0 THEN DRIVE_CLEAR NEXT i WA 100 In case of axis error DATUM 0 WEND project_status 1 Stopped but no error alarm_status 5 action 3 RETURN start_application Wait for rising edge in bit 0 of VR 0 WHILE READ_BIT 0 0 0 IF MOTION_ERROR 0 THEN RETURN WEND WHILE READ_BIT 0 0 1 IF MOTION_ERROR 0 THEN RETURN WEND RUN ...

Page 283: ...PPLICATION BASE x restart 0 inertia_ratio set_load_inertia_ratio EXAMPLE 1 SGMAH 01AAA61D OY motor data enc_resolution 2 13 13 bit encoder max_speed 5000 5000 rpm max speed EXAMPLE 2 SGMAH 01A1A61D OY motor data enc_resolution 2 16 16 bit encoder max_speed 5000 5000 rpm max speed WRITE PARAMETERS IN THE SERVO DRIVE_WRITE 103 2 inertia_ratio Write inertia ratio DRIVE_READ 110 2 10 IF VR 10 0012 THE...

Page 284: ...4321 1 Pn81E 4321 To make the Digital inputs in the Servo Driver available for reading through DRIVE_INPUTS word restart 1 ENDIF IF restart 1 THEN DRIVE_RESET Initial gains For MECHATROLINK_SPEED By experience this setting is a good starting point P_GAIN INT 214748 3648 max_speed enc_resolution This is the optimum value Set if needed VFF_GAIN INT 60000 1073741824 enc_resolution max_speed Initial g...

Page 285: ...ll have running the motor at max_speed without VFF_GAIN in MECHATROLINK SPEED FE_LIMIT 1073741824 P_GAIN UNITS SPEED is set to 1 3 of max_speed SPEED max_speed73 enc_resolution 60 UNITS ACCEL in 200ms from 0 to max_speed ACCEL SPEED 0 2 DECEL in 200ms from max_speed to 0 DECEL SPEED 0 2 I52E EN 03 book Seite 285 Freitag 29 Juni 2007 11 55 11 ...

Page 286: ...pical for this point to point movement with linear acceleration Note the following During linear acceleration the graph of the position is parabolic because the speed is a derivative of the position During constant speed the graph of the position is straight During linear deceleration the graph of the position is counter parabolic During stop the graph of the position is constant When an overflow ...

Page 287: ...ding to the formula Torquetotal Jtotal α Torquefriction where Torquefriction is usually small α is the angular acceleration and J the inertia of the system 6 2 4 Position with product detection fig 51 A ballscrew moves forward at a creep speed until it reaches a product a microswitch IN 2 turns on The ballscrew is stopped immediately the position at which the product is sensed is indicated and the...

Page 288: ...os MPOS CANCEL WAIT IDLE PRINT Product Position prod_pos SPEED 100 MOVEABS 0 WAIT IDLE GOTO start speed Forward Moveabs IN 1 IN 2 t CANCEL WAIT IDLE PRINT Product position SPEED 100 MOVEABS 0 WAIT IDLE Start WAIT UNTIL IN 1 ON WAIT UNTIL IN 1 ON SPEED 10 FORWARD WAIT UNTIL IN 2 ON I52E EN 03 book Seite 288 Freitag 29 Juni 2007 11 55 11 ...

Page 289: ... is divided into a 5 x 5 grid and each of the positions on the grid contains a box which must be filled using the same square pattern of 100mm by 100mm A dispensing nozzle controlled by digital output 8 must be turned on when filling the box and off at all other times I52E EN 03 book Seite 289 Freitag 29 Juni 2007 11 55 11 ...

Page 290: ...zzle ON GOSUB square_rel OP nozzle OFF NEXT y NEXT x GOTO start square_rel MOVE 0 100 MOVE 100 0 MOVE 0 100 MOVE 100 0 WAIT IDLE WA 1000 RETURN t t y x speed y speed Square_rel x X 0 Y 0 X 1 Y 0 X 0 Y 1 X 0 Y 2 X 0 Y 3 X 0 Y 4 X 4 Y 4 200 100 Square_rel MOVEABS 0 200 MOVEABS 0 400 OP nozzle I52E EN 03 book Seite 290 Freitag 29 Juni 2007 11 55 11 ...

Page 291: ...The figure shows a typical bag feeder that is part of the machine Bag feeder machines have two modes Without mark Forward feeds the film a set distance for films of a flat colour With mark Forward feeds the film to a printed mark on the film The program in this section shows the typical code for a bag feeder machine I52E EN 03 book Seite 291 Freitag 29 Juni 2007 11 55 11 ...

Page 292: ...ition counter MPOS DPOS goes from 0 to 999999 and 0 again UNITS 27 SPEED 100 ACCEL 1000 DECEL 1000 REP_DIST 1000000 REP_OPTION 1 SERVO ON WDOG ON Main program loop Define current position as zero DEFPOS 0 Wait for rising edge in Digital Input start_signal WAIT UNTIL IN start_signal 0 WAIT UNTIL IN start_signal 1 Time Time Position Speed IN start_signal REG_POS MOVEABS REGIST 1 MOVEABS REGIST 1 MAR...

Page 293: ...ark has been detected the position is corrected MOVEMODIFY bag_distance expected_pos REG_POS failed 0 ELSE If the mark has not been detected PRINT Mark not detected failed failed 1 IF failed max_fail THEN After several consecutive misdetection stop the application PRINT Mark definitelly lost program_alarm 3 STOP ENDIF ENDIF ENDIF Wait until the feed movement has finished WAIT IDLE GOTO loop 6 2 7 ...

Page 294: ...1 SERVO 1 Enable position loop in axis 1 BASE 0 SERVO 1 Enable position loop in axis 0 The position counter counts from 0 to 11999 and then back to 0 again REP_OPTION 1 REP_DIST 12000 SPEED 200 FORWARD BASE 1 loop CAMBOX in_tbl end_tbl 1 lnk_dst master opt start WAIT IDLE GOTO loop filltable The shape of the CAM is stored in TABLE 0 to TABLE 360 npoints 360 in_tbl 0 end_tbl in_tbl npoints Distance...

Page 295: ... COS PI i npoints 1 2 NEXT i RETURN 6 2 8 Flying shear program fig 58 An example of the Flying shear program In this application there are three axes Axis 0 shear_axis the advancement of the shear Axis 1 flying_axis is the flying shear Axis 2 line_axis transports the material Axis 1 Axis 0 Axis 2 I52E EN 03 book Seite 295 Freitag 29 Juni 2007 11 55 11 ...

Page 296: ...ut MOVEABS end_pos AXIS shear_axis WAIT UNTIL MTYPE AXIS shear_axis 2 WAIT IDLE AXIS shear_axis First time we have a certain wait time because the material has been just been cut wait_distance cut_lenght l_acc 2 MOVELINK 0 wait_distance 0 0 line_axis AXIS flying_axis WAIT UNTIL MTYPE AXIS flying_axis 22 1 2 3 4 5 Flying shear axis slave Material feeder Master ZERO POSITION Initial situation materi...

Page 297: ... when it is in synchronization with the line Slow speed to cut SPEED AXIS shear_axis cut_speed MOVEABS end_pos AXIS shear_axis MOVEABS 0 AXIS shear_axis WAIT UNTIL NTYPE AXIS shear_axis 2 Fast speed to return WAIT LOADED AXIS shear_axis SPEED AXIS shear_axis return_speed cut_counter cut_counter 1inch Return back synchronized with the master in such a way that there is no wait time line_back cut_le...

Page 298: ...he same The cut in the material is made This gives a new material edge 4 The deceleration part the material continues and the shear stops 5 Move back at high speed the distances are calculated such that when the slave reaches it original position the edge of the product is in the correct position to start a new cut A A new movement starts step 2 6 2 9 Correction program This application is for a r...

Page 299: ... fig 61 conveyor 0 labeller 1 virtual 15 SERVO AXIS conveyor 1 SERVO AXIS labeller 1 WDOG 1 BASE labeller CONNECT 1 conveyor ADDAX virtual FORWARD AXIS conveyor REGIST 1 WAIT UNTIL MARK 0 loop WAIT UNTIL MARK correction REG_POS expected_pos MOVE correction AXIS virtual WAIT IDLE AXIS virtual OFFPOS label_length correction REGIST 1 WAIT UNTIL MARK 0 GOTO loop t speed 0 0 0 OFFPOS correction labelle...

Page 300: ...r value Error or alarm on Servo Driver assigned to the axis Caution Disconnect all cables before you check if they have burned out Even if you have checked the conduction of the wiring there is a risk of conduction due to the return circuit Caution If the encoder signal is lost the servo motor can run away or an error can be generated Make sure that you disconnect the motor from the mechanical sys...

Page 301: ...rs To remove the error do these steps 1 Refer to the Servo Driver manual to determine the cause of the error and solve the error 2 Reset the controller or click the Axis status error button 7 2 3 Unit errors Unit errors show on the LED display of the TJ1 MC__ as Unn where nn is the number of the unit that caused the error There are four possible causes Defective unit Unit not connected to the Traj...

Page 302: ...ystem There are too many non axis MECHATROLINK II stations in the system To solve this problem change the system so that it adheres to the rules for adding units to a system See the Hardware Reference manual 7 2 5 Replace the battery To replace the backup battery do these steps 1 Make sure the Power Supply Unit is set to on for at least five minutes If not the capacitor that backs up the memory of...

Page 303: ...s are not too long You have not properly terminated the PROFIBUS network Terminate the PROFIBUS net work at the appropriate places The PROFIBUS master unit is defective Replace the master unit The TJ1 PRT is defective Replace the TJ1 PRT COMM LED is off and BF LED is flashing The PROFIBUS configuration is incorrect there is no communica tion with the master Check that you use the cor rect GSD file...

Page 304: ...ss Network cable error Check network cables Indication Problem Solution All LEDs are off The power is off Turn the power on The TJ1 ML__ is defective Replace the TJ1 ML__ Indication Problem Solution BF LED is on Cable failure on the MECHATRO LINK II bus Check MECHATROLINK II cables between stations connected to the unit for interruptions and irregular ities short circuit between com munication lin...

Page 305: ...cation Problem Solution All LEDs are off The power is off Turn the power on The TJ1 FL02 is defective Replace the TJ1 FL02 RUN LED is on A EN or B EN LED is off The axis for which EN LED is off is not enabled Enable the axis perform WDOG ON and or AXIS_ENABLE on the axis RUN LED is on A EN or B EN LED flashes There is an axis error for the axis for which EN LED flashes The TJ1 MC__ indicates the n...

Page 306: ...25 BASIC commands 33 BASIC programming 24 BASIC programs 30 Battery 302 C CAM table example 293 Caution safety 16 Command Axis 33 Communication 36 I O 36 Program 37 Program control 38 System 38 Task 40 Command line interface 30 Constants 36 Correction example 298 D DEVICENET Communication set up 173 Communication status 178 Errors 304 I52E EN 03 book Seite 306 Freitag 29 Juni 2007 11 55 11 ...

Page 307: ...s 229 Homing 253 Initialization program 283 Origin search 253 Position mode 235 Position on a grid 289 Position with product detection 287 Registration 259 Servo driver characteristics 251 Setting units 239 Shell program 279 Single axis program 286 Speed mode 230 Startup program 225 Tracing and monitoring 269 F FINS slave protocol 156 Flexible axis Errors 305 Flying shear example 295 I52E EN 03 bo...

Page 308: ... Basic commands 158 Master protocol 158 Slave protocol 163 I Icons 195 Initialization example 283 Installation of software 181 Intelligent drives 208 Interface DEVICENET 173 Ethernet 153 MECHATROLINK 179 PROFIBUS 167 Serial 158 Interface overview 153 IO status 216 J Jog 217 M MECHATROLINK Errors 304 I52E EN 03 book Seite 308 Freitag 29 Juni 2007 11 55 11 ...

Page 309: ...24 Menu descriptions 196 Modifier Slot 38 Motion execution 28 Multitasking 23 N Network connection 187 O Operand 37 Mathematical 37 Origin search example 253 Oscilloscope 210 P Parameter Axis 34 Communication 36 I O 36 Slot 38 System 39 Task 40 PC Connection 186 Direct connection 154 I52E EN 03 book Seite 309 Freitag 29 Juni 2007 11 55 11 ...

Page 310: ...S interface 167 Program file compare 192 Programming tool 180 Project compare 192 Protocol DEVICENET 173 FINS client 158 FINS slave 156 Host Link master 158 Host Link slave 163 MECHATROLINK 179 PROFIBUS 167 Trajexia Tools 156 User defined 165 Protocols overview 153 R Registration example 259 S Safety operating environment 17 Safety unit assembly 21 Serial interface 158 Servo driver characteristics...

Page 311: ...0 Startup example 225 STARTUP program Modify 208 System overview 22 T Table viewer 219 Tracing and monitoring example 269 Trajexia compare 192 Trajexia Tools protocol 156 U Units example 239 User defined protocol 165 V VR editor 219 I52E EN 03 book Seite 311 Freitag 29 Juni 2007 11 55 11 ...

Page 312: ...ix to the catalogue number on the front cover of the manual i Revision code Date Revised content 01 August 2006 Original 02 October 2006 DeviceNet update 03 May 2007 Updated with TJ1 MC04 and TJ1 ML04 Improved BASIC commands programming examples and tips I52E EN 03 book Seite 312 Freitag 29 Juni 2007 11 55 11 ...

Reviews: