Home
CTRIO Version 2.0 User Manual, Second Edition
Contents
1. N base terminals to properly identify the base terminal points Terminator I O Input Output Channels M e e e e e e e e e e e e e o o o p eem LJ Ol 1A 1B 1C 1D vo vo v1 Y1 2A 28 2c 20 v2 v2 v3 v3 N OK ERR CH1CH2 EN 0 OQ OQ Q OJOJO OO O 0 oO 0 D D N Channel Commons j M 1A 1B 1C 1D YO Y 2A 2B2C2D Y2Y3 Q O O IOIOoIOoIQoIOo IOoIOIOoO0 o oIoJo O0000000000000000 1M 1M 1M am co co C1 C1 2M 2M 2M 2M C2 C2 ca c3 c 96999996969999c9 CJO O OLO O OO O OPO D D D D H E GOSOSOSSOSSOSSOSSOSS User Bus Terminals no internal connection to CTRIO rg S S S 8 8 S SS S S S 8 S S S S 4 e eje e eje e e e e e e e e o o E F USER BUS 1 USER BUS 2 LO J LOJ DjB HjBIJB DjB B10 OO H HO H D Notes 2 26 1 Inputs 1A 1B 1C 1D and 2A 2B 2C 2D require user provided 9 30VDC power sources Terminals 1M and 2M are the commons for Channel 1 and Channel 2 inputs Maximum current consumption is 12mA per input point 2 Polarity of the input power sources can be reversed Consideration must be given however to the polarity of the field device Many field devices are designed for only one polarity and can be damaged if power wiring is reversed 3 Outputs have one polarity only and are powered by user provided 5 36VDC power sources The maximum allowable current per o
2. Counter I O User Manual 5 5 Chapter 5 Configuring the CTRIO Outputs Creating and Using the Output Preset Tables Preset tables can be used only when the corresponding input is configured for a timer or quad counter that is not scaled or if a counter is set to Position scaling To create tables of presets click the Preset Tables button on the main Preset Tables Preset Tables Workbench dialog This will open the au Output Preset Tables dialog To create a new table click F Add or Edit This will open the Edit Preset Table dialog Build a Preset Table by adding preset entries one at a time Click Add Preset or Edit Preset to open the Edit Preset DEM Entry dialog rc The preset tables work similiar to an event drum not a 2 programmable limit switch For example in the Edit Preset Table dialog below the output is SET at count 100 Once the output is p SET if the count drops below 100 the output will not go OFF it will remain SET Once a step is complete the focus is on the next step and that step only Edit Preset Table x Add Preset On the Edit Preset Entry dialog select one of the six Output Functions Set the preset File Number 1 RESET at 200 f see s Pulse ON for 2000 ms at 300 value in engineering units if the signal has Name RESET COUNT at 400 fat been scaled Set the preset value in raw fene count if the signal
3. eee eee eee ee ee 2 10 CPU and CTRIO Compatibility Chart 0 0 0 eee eee 2 10 Setting H2 CTRIO Jumpers 0 ccc cece eee eee eee eens 2 11 Wiring the H2 CTRIO Module 0 ccc ee eee eee ees 2 12 H2 CTRIO Quadrature Encoder Wiring Example 0 0 00 e eae 2 13 H2 CTRIO TTL Quadrature Encoder Field Wiring eese 2 14 H2 CTRIO TTL Input Wiring llle RII 2 15 H2 CTRIO Output Wiring Schematic sleeeee 2 16 H2 CTRIO Stepper Servo Drive Wiring Example eee 2 17 Installing the H4 CTRIO 2 cc eee I Ih 2 18 CPU and CTRIO Compatibility Chart 0 0 eee eee 2 18 Wiring the H4 CTRIO Module 0 c cee cee eee eee eens 2 19 H4 CTRIO Quadrature Encoder Wiring Example eese 2 20 H4 CTRIO TTL Quadrature Encoder Field Wiring eese 2 21 H4 CTRIO TTL Input Wiring lese 2 22 H4 CTRIO Output Wiring Schematic 0 0 cee e 2 23 H4 CTRIO Stepper Servo Drive Wiring Example eee 2 24 Installing the TIH CTRIO leeeeeeeeeeeee eR eee eee 2 25 CPU and CTRIO Compatibility Chart scseeeeeee eee 2 25 Wiring the T1H CTRIO Module 0 ccc eee eee eee nnn 2 26 T1H CTRIO Output Field Wiring 0 0 0c ccc cee eee 2 27 T1H CTRIO Input Field Wiring 00 0 eee eee RII 2 27 ii Counter I O User Manual Table of Contents ee T1H CTRIO Quadrature Enco
4. oojoo USER BUS 1 CO 24VDC USER BUS 2 Y1 OVDC Counter I O User Manual 2 27 Chapter 2 Installation and Field Wiring SY T1H CTRIO Quadrature Encoder Wiring Example Input Output Channels NPN Open Collector Output Encoder Channel Commons 9 0O O O O O O O O O O O O C1 2M 2M 2M 2M C2 C2 C3 C3 U O O O 0 H D D U 1M C0 CO C1 DIU 040 User Bus Terminals no internal connection to CTRIO O O O O OlIO O O O OIO O O USER BUS 1 USER BUS 2 oojoo Wio D D H1D U USER BUS 1 1M 424VDC SOUND 6 USER BUS 2 OVDC 2 28 Counter I O User Manual Chapter 2 Installation and Field Wiring T1H CTRIO TTL Quadrature Encoder Field Wiring Input Output Channels e e ejeje je e e e e o e e e e o 1A 1B 1C 1D Yo YO Y1 Y1 2A 2B 2c 2D Y2 Y2 Y3 Y3 cirmrammumpmp mum C Ld A IK B AAA HFE 100 Channel Commons 0 1W 9 0O O O O O O O O O O O O O O O 10 E 1M 1M 1M 1M CO CO C1 C1 2M 2M 2M 2M C2 C2 C3 C3 g D BIB Dj B BD B1 oj H I 1G User Bus Terminals no internal connection to CTRIO o 0o 0o O O O O Oj O O O O O O O O USER BUS 1 USER BUS 2 OOOO
5. T i l La Y1 ike Y3 eee g D lt c 1 T i a V H4 CTRIO Notes 1 Inputs 1A 1B 1C 1D and 2A 2B 2C 2D require user provided 9 30VDC power sources Terminals 1M and 2M are the commons for Channel 1 and Channel 2 inputs Maximum current consumption is 12mA per input point 2 Polarity of the input power sources shown above can be reversed Consideration must be given however to the polarity of the field device Many field devices are designed for only one polarity and can be damaged if power wiring is reversed 3 Outputs have one polarity only as shown above and are powered by user provided 5 36VDC power sources The maximum allowable current per output circuit is 1A Counter I O User Manual 2 19 Chapter 2 Installation and Field Wiring SY H4 CTRIO Quadrature Encoder Wiring Example N gt gt m wo Ge G Z e L Ge Go Gp vo OM m Oo 9 30VDC 2A0 6 2 20 Counter I O User Manual Chapter 2 Installation and Field Wiring H4 CTRIO TTL Quadrature Encoder Field Wiring amp 1A DE B 1C HFE gt 100 0 1W Gp 1D 1096 2D E B c GM 7 Gp Nc C co ce HFE gt fe v
6. Inhibit 1 Inhibit 1 is available only if you have selected a Counter or Quad Counter as the primary function For example if you have chosen either counter function on terminal 1A you will have an option of using terminal 1D for an inhibit signal The Inhibit 1 signal prevents the CTRIO from counting pulses The Inhibit feature is available with the A Counter or Quad Counter on each channel Inhibit 1 represents a hard wired input to terminal D An appropriate field device must be connected to the designated terminal to perform the inhibit function rj u Sz gt a gt n 1 nj n 1 x ic rj s Soset z pococeesoSscos OSES g Q 3 Inhibit lt A lt 5 Q S E s E Ri 2 y 10 Counter I O User Manual Chapter 4 Configuring the CTRIO Inputs Introduction to the Scaling Wizard Scaling raw signals to engineering units is a accomplished using the Scaling Wizard Start eem the Scaling Wizard by clicking the ruler button Cel on the Configure IO dialog This button Sici A appears only after you select one of the Counter BB comin m or Timer functions The Scaling Wizard options are different for the Counter functions as compared with the ru NN Timer functions Position and Rate scaling are available when you select a Counter function Interval scaling is available when you sele
7. sleeeee e 6 46 Run at Velocity on CTRIO until Input Function Value Position 6 47 System FUNCTIONS 66 cise se ve des ee a SS Y X e ec oe oe a rd 6 48 Reading All CTRIO s Internal Registers Flowchart 0 00000 eee eee 6 49 Writing to All CTRIO s Internal Registers Flowchart 0 00000 6 50 Writing to One CTRIO Internal Register Flowchart elles 6 51 Chapter 7 Using Monitor I O Using the Monitor I O Dialog 0 cece ce ee eee eee eens 7 2 I O Status amp Input Functions 2 2 E ce eee nee 7 3 Output FUNCIONS ssec bk REPRE UR RR bebe Leoe Se EES E SE S ed there dae 7 4 System F nctlons sek ex ew wh ohh haee ER S RESEEREEEES 7 6 Monitor I O Error Codes ccc ee ee ete een 7 7 Chapter 8 DirectLogic Programming Examples Programming Examples Overview 0 ccc cece eee eee hn 8 2 Load and Run a Pulse Profile leen 8 3 Dynamic Positioning sseeeeeeeee IR 3n 8 4 Dynamic Velocity 12 22 22 ke nia RR RR RR Le E Ra EE ERES 8 5 Velocity Mode iiiiasssccc sk hu hr hh RR EERE ET ERR DEER Ch OR KORR RR 8 6 Runto Limit Mod 7 e Ree exe es d RE E 8 7 Run to Position Mode cor ee RR Rr ey Red ER Rees 8 8 System Functions Examples Overview 0 cece eee eee eee ees 8 9 Simulating Retentive Counter 0 ccc cece eee nnn 8 10 Reading CTRIO Internal Registers 0 cee eee eee ee eens 8 11 Counter I O User Manual v
8. lllllee eh 6 5 Output Control Bit Definitions Raw Mode 0 0 eee eee eee 6 5 Output Control Bit Definitions for Preset Table Control 0 6 5 Output Control Bit Definitions Pulse Output 0 0 eee eee 6 5 Input Function Control Bit Definitions leen 6 5 System Functions Control Bit Definitions eee 6 6 System Functions Status Bit Definitions llle 6 6 1 0 Map Dialog Re ROERERROR E RR Reni e erm x ex mr reed rd ue a das 6 7 I O Map with DirectLogic PLC 2 ranges mode 0 0 0 eee eee eee 6 7 I O Map with DirectLogic PLC 4 ranges mode 00 e eee eee eee 6 8 I O Map with EBC WinPLC se 0 0 ce eee ee eee 6 9 I O Map with DirectLogic PLC with CTRIO in ERM EBC Network 6 9 I O Map with an H2 PBC or T1H PBC Profibus DP Controller 6 10 I O Map with a TTK DEVNETS DeviceNet Controller 004 6 11 I O Map with a T1K MODBUS Modbus RTU Controller 0 6 13 Exporting to DirectSOFT sisse r9 9 pes ee es ee EE E 6 14 Printing a Memory Map Report 0 cee n 6 14 Addressing Conventions 0 cece eee eee eee eee eens 6 15 with V memory Examples for DirectLOGIC PLCs 0 0 0 0 ee eee 6 15 Example for Bit accessed Data in PLC CPUs 0 0 0 e eee eee eee 6 15 Addressing High and Low Byte of Word Parameters 00 e ee eee 6 15 Addressing H
9. 1 Step Count O FFFFFFFF ul rj i i Enable Output nable utp Enable Output Enable Output Goto Pasitior Goto Positia Goto Positi Direction Jirectior Direction Process Command Process Commen Process Command Output Enabled Of Gutput Enabled Output Enabled GM Output Enabled Off Position Loaded Of ade Position Loade Position Loaded im Output Active Off E Table Complete for c Output Stalled Or a Gutput Stalled Gutp Command Error OR Comma Command Error Of c Command Complete Of Command C Command Complete i CTRIO read of PLC outputs is Suspended Click to enable Last Error Code o No error Pulse Output Command Codes 0x20 0x21 and 0x22 Velocity mode 0x20 is shown in the example above Depending upon which command is selected different parameter fields status bits and control bits will apply No matter which one is selected be sure to fill in the parameter fields with valid entries refer to chapter6 and then Process the Command Counter I O User Manual 7 5 Chapter 7 Using Monitor I O ses System Functions The Systems Functions dialog allows you read from or write to the current input count and the current output pulse count under the following conditions The current input count can be read from or written to if the input is configured for a Counter or Quad Counter Timer values are not accessable The current output pulse count can be read from or
10. Pour des renseignements additionnels touchant la garantie et la s curit veuillez consulter la section Modalit s et conditions de notre documentation Si vous avez des questions au sujet de l installation ou du fonctionnement de cet quipement ou encore si vous avez besoin de renseignements suppl mentaires n h sitez pas nous t l phoner au 770 844 4200 Cette publication s appuie sur l information qui tait disponible au moment de l impression la soci t Automationdirect com nous nous efforcons constamment d am liorer nos produits et services C est pourquoi nous nous r servons le droit d apporter des modifications aux produits ou aux publications en tout temps sans pr avis ni quelque obligation que ce soit La pr sente publication peut aussi porter sur des caract ristiques susceptibles de ne pas tre offertes dans certaines versions r vis es du produit Marques de commerce La pr sente publication peut contenir des r f rences des produits fabriqu s ou offerts par d autres entreprises Les d signations des produits et des entreprises peuvent tre des marques de commerce et appartiennent exclusivement leurs propri taires respectifs Automationdirect comMC nie tout int r t dans les autres marques et d signations Copyright 2003 Automationdirect com Incorporated Tous droits r serv s Nulle partie de ce manuel ne doit tre copi e reproduite ou transmise de quelque fa on que ce soit sans le cons
11. llle 6 28 Status Bits 6 29 Control Bits Registers s se isses emm trek ace Re RR Rx edd esed ER 6 29 Memory Mapping Example for D2 240 CPU 6 6 eee eA 6 30 Pulse Output Profiles 0 0 ccc ccc I 6 31 Trapezoid S Curve Symmetrical S Curve Home Search Profiles 6 32 Trapezoid S Curve Symmetrical S Curve and Home Search Flowchart 6 33 Running a Trapezoid S Curve Symmetrical S Curve or Home Search Profile 6 34 Dynamic Positioning i i ehh RE RRERREEERR ERI E Y EE ERES 6 35 Dynamic Positioning Flowchart 02 0 cece eee eee ee eee 6 36 Dynamic Positioning using the CTRIO YO and Yl 2 2 eee eee ee eee 6 37 Dynamic Velocity using the CTRIO YO and Y1 1 1 eee eee 6 38 Dynamic Velocity see ee ere eee eee OA A RRS Ee EEE aos EEG 6 38 Dynamic Velocity Mode Flowchart 2 0 0 0 0 0 eee eee ee eee eee 6 39 Velocity Mode v ces e eee cede edad eed eR eee EE weg seg eee eee ee eed 6 40 Velocity Mode control on CTRIO YO amp Y1 1 eee 6 40 Velocity Mode Flowchart 0 0 cece eee IIIA 6 41 Run to Limit Mode 2 526 ccc ecco eee Ge eNOS See SE Re eee ee ee E 6 42 Run to Limit Mode Flowchart llslleeee eens 6 43 vi Counter I O User Manual Table of Contents M M Run at Velocity on CTRIO YO amp Y1 until Discrete Input Limit 6 44 Run to Position Mode amp cxiseussxat Laced oe RA RARE EA RR RR ee 6 45 Run to Position Mode Flowchart
12. 789 a 2 s trailing edge of an upward pulse to the trailing edge of the next upward pulse or M 7 ejes F from the leading edge of an upward pulse ear to the trailing edge of the same pulse or finally from the leading edge of a 5 m mj downward pulse to the trailing edge of the pue pem same downward pulse The last option could be restated as timing Sto from the trailing edge of an upward pulse to the rising edge of the next upward pulse 2 The Free Run option is assigned by clicking in the appropriate box If your application calls for velocity measurements to be taken at the commencement of some event do not use Free Run If your application calls for velocity measurement on a continuous moving average basis you should use Free Run 3 The Enable Timeout option is assigned by clicking in the appropriate box and specifying a Timeout period Once the timer is enabled the Timeout Bit is set if the time that it takes the CTRIO to see the configured input edge exceeds the specified Timeout Period Also if the time before the CTRIO sees the next configured edge exceeds the specified Timeout Period the Timeout bit is set More information about the Timeout function can be found in chapter 6 4 The last remaining decision to be made is about scaling Clicking the button with the tape measure symbol starts the Scaling Wizard We discuss the scaling wizard later in this chapter The Scaling
13. SOI ac CTR2 EAD The module is configured goo LD CTRIO using CT RIO Workbench to SOD scone accommodate the user s eto 6 OUT 5 36VDC application The function of oo P m 4 perpoin each input counting timing a QD oh TALAT aq reset etc and output pulse De uh spices op BP 2 Q output discrete output etc is TUE dco e Iac UCI qu defined in the configuration of ar D q an jp LP b D Q the module 2D go oy IMB o q e son Yo Refer to Chapters 4 and 5 to e a Em co NEP S D eec R Pc dl determine what input and EE e Q Hor v2 oP Q D output configurations are so zi c3 VOR D o possible ala e l y3 amp P D D Sp Yi D idi M Field device wiring must be compatible with the module configuration See the notes below for further details about power source Me A considerations circuit polarities and field devices Also refer to the specifications on pages 1 5 and 1 6 for more information Notes 1 Inputs 1A 1B 1C 1D and 2A 2B 2C 2D require user provided 9 30VDC power sources Terminals 1M and 2M are the commons for Channel 1 and Channel 2 inputs Maximum current consumption is 12mA per input point 2 Polarity of the input power sources shown above can be reversed Consideration must be given however to the polarity of the field device Many field devices are designed for only one polarity and can be damaged if power wiring is reversed 3 Outputs have one
14. 1 9 17 25 24 1 24 9 25 1 25 9 Output Control Bit Definitions for Preset Table Control Output Control Offsets are listed in the order of the Output 0 Output 3 Output n Control Bits transfers from CPU to CTRIO Bit Offsets WinPLC EBC PBC DEVNETS MODBUS V memory Offsets DirectLOGIC PLCs Enable Output 32 40 48 56 26 0 26 8 27 0 27 8 Process Command 39 47 55 63 Output Control Bit Definitions Pulse Output Pulse output control Offsets are listed in the order of Outputs 0 1 2 3 Output Control Bit transfers from CPU to CTRIO Bit Offsets WinPLC EBC PBC DEVNETS MODBUS V memory Offsets from Output Start octal 26 7 26 15 27 7 27 15 Read as Enable Output 32 48 26 0 27 0 Level Go to Position 33 49 26 1 27 1 Rising Edge Suspend Output 34 50 26 2 27 2 Level Direction 36 52 26 4 27 4 Level Process Command 39 55 Output Control Bit Definitions Raw Mode Output Control Offsets are listed in the order of the Output 0 Output 3 Output n Control Bits transfers from CPU to CTRIO Bit Offsets WinPLC EBC PBC DEVNETS MODBUS 26 7 27 7 Rising Edge V memory Offsets DirectLOGIC PLCs Enable Output 32 40 48 56 26 0 26 8 27 0 27 8 Counter I O User Manual 6 5 Chapter 6 Program Control nnn EY System Functions Status Bit Definitions Fr
15. Scaled Value 75 yds Cancel lt Back rein BS 12 l Counter I O User Manual Chapter 4 Configuring the CTRIO Inputs Rate Scaling Counter To select Rate Scaling click the radio button beside the word Rate Now click Next to move to the Output Settings dialog Scaling Wizard Output Settings x On the Output Settings dialog you will notice the field for engineering units Enter an appropriate value for Rate Scaling for Dutput Format example RPM fps flow etc Seven data types are available including BCD to make values more easily used by DirectLOGIC PLCs Engineering Units APM up to 4 characters Floating Point Integer rounded Integer 10 1 implied decimal place Integer x100 2 implied decimal places BCD rounded BCD x10 1 implied decimal place BCD x100 2 implied decimal places Cancel lt Back VIIIIAYD Click Next to open the Rate Settings dialog EXSUMEMICSTORUSCSINUrS Lx It is here that you enter the counts per unit Unit Definition of time and the time base A scale offset is Counts unit 000 Rate Scaling Calculator l rovi j he resul Enter a count value and sample also provided to adjust the result by a Mana E a constant amount configuration g Unit Time Base This window contains a calculator to double UEM Counts in sample 5000 check your Rate Settings Enter a value into eas the Raw Value field to see the equivalent min
16. The Systems Functions examples on the following pages use the DirectLOGIC Write to Intelligent Module WT and or Read from Intelligent Module RD instructions to write to or read from the CTRIO s internal registers Reading From CTRIO Internal Memory Reading the CTRIO s internal memory consists of several steps Step one is using the WT instruction to send a Systems Function s command to the CTRIO telling it to put its internal register values into the CTRIO s shared RAM Step two is processing the request for the internal register values using the Process Command bit Step three is using the RD instruction to read the values from the CTRIO s shared RAM memory into PLC V memory Steps 1 and 2 WT instruction and Process Command PLC V memory gt CTRIO s Shared RAM CTRIO s Shared RAM gt Process Command to internal processor CTRIO s Shared RAM lt Internal data values Step3 RD instruction PLC V memory lt CTRIO s Shared RAM Writing to CTRIO Internal Memory Writing to the CTRIO s internal registers is basically a two step process Step one is using the WT instruction to send a System Function s command and the desired data values to the CTRIO s Shared RAM Step two is using the Process Command bit to tell the CTRIO to process the command and data values that are in the CTRIO s Shared RAM This moves the data values from the Shared RAM into the CTRIO s internal registers Steps 1 and 2
17. V2030 CemCodg Free Blocks 233 Preset Tables TotalPreset Tables T Config Status Ea Pulse Profiles Total Pulse Profiles 1 Quit Counter I O User Manual Chapter 3 Introduction to CTRIO Workbench Pe Module Modes of Operation On the CTRIO Workbench main window a single button toggles between Run Mode and Program Mode The Module Mode indicator will tell you which mode your module is in You can make configuration changes in either Run Mode or Program Chin Mode but to save your configuration to the module you must click Write Module which is only active in Program Mode ETSI Read File igned In the lower left corner of the main Workbench dialog is the Config Information Config Status indicator If the current configuration is different Ra from the CTRIO and different from any saved files the indicator T2tal Blocks 256 will display the word Changed If the current configuration has Free Blocks 249 been written to the module or a file the message will read Same as Module Same as File or Same as Both Config Status Changed Program Mode Configuring the CTRIO Module e After the configuration is created or changed in CTRIO Workbench it must be written to the CTRIO module This is accomplished by returning to 0O BBE the main CTRIO Workbench window and clicking on Write Module Config Operations If the configuratio
18. 1 1 Initialize Settings LD Load Run to K22 Position Mode Sor 0x22 Hex 2040 Command Code Register CO ITI 2 Ul This rung loads Target Velocity Compare format Duty Cycle Input Function and Position Compare Value into the Parameter registers Set Direction C2 D V3000 Target Velocity Decimal P ww e Parameter 1 LD Run Frequency K1000 Specifies Parameter 3 is Greater than or Equal to Ch1Fn1 Value and 50 duty cycle Hex Parameter 2 Function Duty Cycle Specified position to compare against Input Function Value Decimal LDD V3001 OUTD V2030 B2056 7 SET Process Command Parameter 3 Input Function DWord value for Position Comparison C1 SET Initialize Settings Complete B2056 4 3 L OUT Direction B2056 7 Gti Command Command Complete Complete Error C1 B2022 7 B2022 6 4 AF Initialize Settings co 2056 0 Error before Enabling the Output RST Process Command This rung waits for the Command s Complete bit with no Command SET Enable Output 5 f Reset Count C3 s 1 B2056 0 Enable Output bit C1 RST Initialize Settings Complete This rung stops the pulse output by disabling the RST Enable Output B2054 1 OUT Input Counter Reset END 8 8 Counter I O User Manual Chapter 8 DirectLogic Programming Examples nn System Functions Examples Overview
19. Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Hela PLC Status Inputs Base Addr V2000 Control neay Action Command Code V2040 V2040 Set to 10 Load Stored Profile Para meter 1 V2041 V2041 File of stored profile determined by user Process Command V2056 7 C227 Turn ON until Command Complete status bit is returned see step 4 Command Complete Status V2022 7 When ON Profile is now loaded clear Process Command bit step 3 Command Error V2022 6 ON if Command or Parameters are invalid Set Direction V2056 4 Set ON or OFF for Direction of Rotation 0 Enable utput V2056 0 Turn ON to start pulses Output Enable Status V2022 0 When ON module is confirming Enable Output 0 Activ utput e Status V2022 4 When ON module is pulsing OFF with Enable Status ON profile has completed isable utput V2056 0 Turn OFF when pulse status is OFF and Enable Status is ON spend utput V2056 2 Turn ON to pause output pulses without resetting pulse count Sus utput pended V2022 2 6 34 Counter I O User Manual ON when out pulse train has been suspended Chapter 6 Program Control Chapter 6 Program Control E Dynamic Positioning For Dynamic Positioning only the motion limits of Min Freque
20. Process Command 39 55 Output Control D Words Pulse Output Pulse output control Offsets are listed in the order of Outputs 0 1 2 3 Word Control CPU to CTRIO Word Offsets WinPLC EBC PBC DEVNETS MODBUS 26 7 27 7 Rising Edge V memory Offsets from Output Start octal Command Code 0 6 10 16 Word Parameter 1 T 11 17 Word Parameter 2 DWord Control CPU to CTRIO 2 8 Word Offsets WinPLC EBC PBC DEVNETS MODBUS 12 20 V memory Offsets from Output Start octal DWord Parameter 3 0 2 0 4 Counter I O User Manual 6 27 Chapter 6 Program Control a M Command Code and Parameter Definitions Command HouBeD er fetes 1 Word Parameter 2 DWord Parameter 3 M or z une ymmetrical S Curve Load Table from ROM Home Search File Number Load Table from ROM Dynamic Positioning Target Position decimal Load Table from ROM Es mns J Target Velocity decimal Run Frequency Duty Cycle 0 to 99 Velocity Mode 20Hz 25KHz decimal Number of Pulses BCD Hex Edge amp mni Run Frequency Run to Limit Mode 20Hz 25KHz Duty ECD 99 Compare Function amp Run Frequency Desired Input Function Value Run to Position Mode 20Hz 25KHz Duty eve 99 decimal A value of 0 will generate a duty cycle of 50 Fields above separated by an amp indicate a cod
21. V200 201 Cunerl Court VADE 2005 Prevor Tee 2020 1 An Reset Vakan V2DOS 2007 Tien IV2020 0 Cahad Stat V2II2U 8 Capture Complete VAZN 10 Time Out Oupa Date Cinni CTRIO Oupa Daia Korbel CTRIO hapaa Oaia Conti CTRIO Output Data Corti C TRIO VRBAS Nac Vea r VAEA Crist Capkan Co oe me ese Counter I O User Manual 6 7 Chapter 6 Program Control EY I O Map with DirectLogic PLC 4 ranges mode When using the CTRIO module with a DirectLogic PLC in 4 ranges mode enter the starting V memory location for the word inputs and outputs and the starting V memory location for the it inputs and outputs Control relays V40600 range would usually be used for bit control In the I O Map dialog below note that Input Output and Systems Functions addresses shown are in word and Control Relay formats Thus word and Control Relay addressing will need to be used in the ladder logic program to address the CTRIO control and status words bits Remember that the CTRIO will consume the address ranges listed in all four range fields LS mn We Maw Krein wie RC Capi Crate Rend hom PLC c A cun am tappe Stateg V siden he werd newt 2000 Stating V addens ko wend tena 2230 Amg Nama Amga am frg adie torte renee EED Stating V addes iata oupa FETT Range agi 0 406905 15 Range agro 040615 5 iat Functions Output Functions System Functions OR fv Quad Court On frd Lage T PEN Odd rou Daa CTO C
22. d T 10K Gnd B gus 0 1W 10 E 5VDC 9 30VDC HO 2 6 Counter I O User Manual TTL Device General Purpose Transistor Chapter 2 Installation and Field Wiring a HO CTRIO TTL Input Wiring oK ERR A 9 vo so CTR TMR IN 9 30V 5 12mA DC Pulse Out 5 36V 1A C 10K p 0 1W 10 E TTL Device HFE gt 100 zu ze x T o 9 2 o 1096 TTL Device HFE gt 100 i an I 9 30VDC 10 TTL Device HFE gt 100 HFE gt 100 Counter I O User Manual 2 7 Chapter 2 Installation and Field Wiring EY HO CTRIO Output Wiring Schematic See page 2 3 for locating and setting the jumpers Q vc CTRIO Sourcing Outputs Output Jumper Settings 451036VDC Yn where n 0 or 1 C O C O O OID C O O Load Sinking Outputs Jumper Settings Load 2 10 9 O 5 to 36VDC OOO OO Q Yn where n 0 or 1 CTRIO Output Q vc 2 8 Counter I O User Manual Chapter 2 Installation and Field Wiring M l HO CTRIO Stepper Servo Drive Wiring Example IN A
23. taent unaren FT Masa Cregeen By Fares CTRIO module Samal een eae LJ Oo oa na Conta riomsa o teed Pecks ne ron LA Hane Rates LL et PeP tog Pane Pole ow Successful On line Connection Once you are connected to your CTRIO module you will enter the main window of CTRIO Workbench Here you select the CTRIO module you wish to configure by clicking on its slot number in the Installed Modules box You will be able to enter Workbench s Configuration dialog and after successfully configuring the module you will be able to toggle the CTRIO module between Program Mode and Run Mode and enter the Monitor I O dialog H CTRIO Workbench E L r Current PLC p Current Module r Module Status Config Operations Type Name gt jite Module DL250 Bils ETRID 1 Module Mode NEN Comm Link Scaniime 426 us Read Module 250 1 KSeq Max Scan Time 562us Write File Comm Status Booter version 102 OS Version 20i gessi Select PLE r Module Configuration Utility Functions Installed Modules Config IO Goto PROGRAM Chl Fn QuadCounterw Captue Out 0 1 Pulse Output Monitor 1 0 Step Direction Chi Fn2 Ch2 Fn1 Out2 Discrete onChl Fnl p Special Preset Mode aaro Rescan Ch2 Fn2 Dut3 Raw i p 3 Hardware Info r Config Information Total Blocks 255 1 0 Map Inputs V2000 Outputs
24. Counter I O User Manual 3 5 CONFIGURING THE INPUTS APTER UsiNc CTRIO WORKBENCH In This Chapter Configure I O Dialog Overview s 13 dd a eye ot eee p EG os 4 2 Input Function Selections audacior cadets Mideak WOReS e 4 3 Soc AMI TT 4 4 Quadrature Counter soii wei ds RARE AUS CE aol E Ke CX a 4 5 PUISECALCH PTT c P 4 6 Edge TIME ursus dodo vines pen aA ee RR CE Mie CR aie ras 4 7 Dual Edge TIME esce ose the ace ee oe EORR eet aS 4 8 Reset 1 and Reset 2 Hard Resets for Counters Only 4 9 Soft Resets cana dor Ra ts 40a bee eben ee EHE RUE ORE UE eee es 4 9 Capt re l ceutused Hades sob rurani t edu asi ed Hees ee 4 10 ra M PT r ee 4 10 Introduction to the Scaling Wizard 0 000 eee 4 11 Chapter 4 Configuring the CTRIO Inputs Configure IO Dialog Overview The Configure IO dialog is the location where input and Module Configuration output functions are assigned to the module The choice of Config IO input and output functions determines which options are available The input and output function boxes H2 H4 T1H CTRIO Configure I O Dialog protopt you wath selene for LI x supported functions The Workbench cana eel Outputs software disallows any unsupported Um F gen configurations m enn 7 Pulse CW CCW From the main CTRIO Workbench window click on the Go to PROGRAM Mode button if in RUN Mode Th
25. Example rising input 1D at Duty 45 set this parameter to 212D Hex Set Direction V2056 4 C224 Set ON or OFF for Direction of Rotation Process Command V2056 7 C227 Turn ON Command Complete status bit is returned see step 4 Command Status V2022 7 When ON command has been accepted clear Process Command bit step 3 Command Error V2022 6 ON if Command or Parameters are invalid Enable Output V2056 0 Turn ON to start pulses Output Active Status V2022 4 ON while pulsing OFF when limit has stopped pulsing Suspend Output V2056 2 Turn ON to pause output pulses without resetting pulse count Output Suspended V2022 2 6 44 Counter I O User Manual ON when out pulse train has been suspended Chapter 6 Program Control Run to Position Mode Run to Position Mode controls the pulse outputs directly from the CPU controller program No CTRIO Workbench Pulse Profile is required for this mode The Run to Position Mode command Command 0022Hex BCD allows Pulse Outputs that terminate when the specified Input Function Value position count is reached Set Word Parameter 1 to the desired Frequency Set Word Parameter 2 Low Byte to the Duty Cycle and the High Byte to the Compare Functions as defined below Leaving the Duty Cycle set to 0 achieves the default 5096 otherwise it can be set in 196 increments by writing th
26. HFE gt 100 0 1W E 10 TTL Device B 10K HFE 100 0 1W E 10 Counter I O User Manual 2 15 Chapter 2 Installation and Field Wiring EY H2 CTRIO Output Wiring Schematic The CTRIO outputs are individually isolated DC switches that can be used to break the high or the low side of a DC load Cn where n 0 1 2 3 CTRIO Output 451036VDC Yn Load 5 to36VDC C3 Cn where n 0 1 2 3 CTRIO Output Yn 2 16 Counter I O User Manual Chapter 2 Installation and Field Wiring Ea H2 CTRIO Stepper Servo Drive Wiring Example gt e 2A B is 2B D aic 2c O w 2D O mw gy O Step Amplifier 2 NC 5 36VDC C2 D Step Amplifier OPTO Power xz p 5 36VDC Y2 E OPTO Power Pulse or CW E Q Yo e Pulse or CW Direction or CCW C3 Z Z Cr Direction or CCW V s This example assumes that the Step Amplifier interface to be optocoupler LEDs common anodes at the OPTO Power terminal with internal current limiting resistors This is a standard method but you must consult you step amplifier documentation to ensure that this method is applicable Counter I O User Manual 2 17 Chapter 2 Installation and Field Wiring Installing the H4 CTRIO The H4 CTRIO
27. Number into Parameter 1 Decimal SET Process Command Verify that you ve entered the correct table number Is Command Complete ON RESET Process Command RESET Process Command 6 26 Counter I O User Manual At this point your table is active SET Enable Output Chapter 6 Program Control _ Pulse Output Status Control Bits and Command Codes Output Status Bit Definitions Pulse Output Pulse output control Offsets are listed in the order of Outputs 0 1 2 3 Status Bit CTRIO to CPU Bit Offsets WinPLC EBC PBC DEVNETS MODBUS V memory Offsets from Input Start octal Output Enabled 32 48 22 0 23 0 Position Loaded 33 49 22 1 23 1 Output Suspended 34 50 22 2 23 2 Output Active 36 52 22 4 23 4 Output Stalled 37 53 22 5 23 5 Command Error 38 54 22 6 23 6 Command Complete 39 55 Output Control Bit Definitions Pulse Output Pulse output control Offsets are listed in the order of Outputs 0 1 2 3 Control Bit CPU to CTRIO Bit Offsets WinPLC EBC PBC DEVNETS MODBUS V memory Offsets from Output Start octal 22 7 23 7 Read as Enable Output 32 48 26 0 27 0 Level Go to Position 33 49 26 1 27 1 Rising Edge Suspend Output 34 50 26 2 27 2 Level Direction 36 52 26 4 27 4 Level
28. O OOO JO H D 1 DL D D U 1 HJ HFE 100 Power 5VDC L r 10K p 0 1W 10 9 30VDC Counter I O User Manual 2 29 Chapter 2 Installation and Field Wiring T1H CTRIO TTL Input Wiring Input Output Channels 9J O O O O O O O O O O O O O O O NPN 1A 1B 1C 1D YO YO Y1 Y1 2A 2B 2C 2D Y2 Y2 Y3 Y3 General Purpose Transistor DjBIDIDO LIO luiulu Ol 10K B I eG 100 Channel Commons 10 9O O O O O O O O O O 1M 1M 1M 1M CO CO C1 C1 2M 2M 2M 2M C2 C2 C3 C3 D D TTL Device E I User Bus Terminals no internal connection to CTRIO O O O O O O O O O O O O O O O O USER BUS 1 USER BUS 2 foun n o o o o u o u oTa u u u u uT o 1096 TTL Device E gt ee 9 30VDC a E TTL Device 10K B HFE gt 100 0 1W 10 E E TTL Device 10K g HFE gt 100 0 1W 10 m 2 3 0 Counter I O User Manual Chapter 2 Installation and Field Wiring E M l T1H CTRIO Output Wiring Schematic The CTRIO outputs are individually
29. WT instruction command and data and Process Command Bit PLC V memory gt CTRIO Shared RAM CTRIO Shared RAM gt Process Command to internal processor CTRIO Shared RAM gt internal data registers Counter I O User Manual 8 9 Chapter 8 DirectLOGIC Logic Programming Examples EE M jj Simulating Retentive Counter The following Systems Functions example uses the Write to Intelligent WT instruction to write the current count stored in the PLC s retentive memory to the CTRIOS current count register on a power cycle or a RUN STOP RUN PLC mode change DirectSOFT 32 First Scan SPO System Functions Command 0x04 Hex Write One Register System Command Code Register Specifies which CTRIO register will be written to when WT Instruction is executed Hex 0 Hex Ch1 Fn1 4 Hex Output 0 1 Hex Ch1 Fn2 5 Hex Output 1 2 Hex Ch2 Fn1 6 Hex Output 2 First Scan 3 Hex Ch2 Fn2 7 Hex Output 3 SPO LD 2 K K1 CTRIO base slot number LD 8 bytes of data will be written to Ke the CTRIO V2100 V2103 LD Offset 80 Hex is the beginning of KBg the Command Frame in the CTRIO did V2100 System Command Code Register Always ON SP1 TMRF TO 3 The 50ms Timer allows enough time for the KS CTRIO module to come up in RUN mode after the PLC is changed from RUN STOP RUN The Process Command timer is not needed for power cycle operations TO B2060 7 since the PLC wi
30. Wizard is intelligent in that it offers scaling options that are appropriate for your input selections Counter I O User Manual 1 7 Chapter 4 Configuring the CTRIO Inputs see Dual Edge Timer The Dual Edge Timer is designed to measure from a pulse edge on one incoming signal to a pulse edge on another incoming signal The user selects whether to measure between rising edges falling edges etc The choices are summarized in the tables below The CTRIO discrete output s can be assigned to the Dual Edge Timer function using the Preset Tables dialog Refer to Creating and Using the Output Tables section in Chapter 5 for details Dual Edge Timer at Function 1 Rising edge of C to rising edge of D Rising edge of C to falling edge of D Falling edge of C to rising edge of D Falling edge of C to falling edge of D Dual Edge Timer at Function 2 Rising edge of D to rising edge of C Rising edge of D to falling edge of C Falling edge of D to rising edge of C Falling edge of D to falling edge of C To insure proper operation the field device wiring and the configuration must be compatible For wiring information see Chapter 2 Notice that the module s four input terminals are represented by the A B C and D boxes on the left side of this dialog If you are wiring your inputs to terminals 1C and 1D you will need to select the Channel 1 tab near the top of this window and click Dual Edge Timer in box C or D At this poi
31. then continue to Lm 2 at Frequency 2 Run to Limi 1 at Frequency 1 then reverse to Limit 2 at Frequency 2 Profle Type Fun to Limit at Frequency 1 then contine to Court at Frequency 2 aa un tes Lent 1 at Frequency 1 then reverse Io Court af Frequency 2 Frequency 1000 He Uma onc v Event Hohe Fie State Penta 3 fe se Pre Total Erinn Profile inio Blocks Usad 1 E Run lo Lind 1 al Feequerny 1 nen reverse to Count at Frequency 2 cme Fiequency 1000 H2 Limi C Evert Mighlevel Frequency2 100 He Lmi2 Ono v Evert Hoher F mS Frequency 1 The frequency at which the Home Search will begin Limit 1 Home Search Frequency 1 will run to CTRIO input Limit 1 and stop unless Frequency 2 is enabled Frequency 2 if enabled Once Limit 1 is reached the pulse output will continue at Frequency 2 until CTRIO Limit 2 is reached or pulse Count is reached at Frequency 2 Limit 2 if enabled Home Search Frequency 2 will run to CTRIO input Limit 2 and stop Count if enabled The number of output pulse counts generated at Frequency 2 before terminating 5 14 l Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs m Home Search Routines 1 Run to Limit 1 at Frequency 1 l Frequency 1 Limit 1 Home 2 Run to Limit 1 at Frequency 1 then continue to Limit 2 at Frequency 2 Frequency 2 Frequency 1 Limit 2 Home Limit 1 3 Run to Limit 1 at Frequency
32. u 2 Counter I O User Manual Chapter 4 Configuring the CTRIO Inputs m Input Function Selections Supported Functions The input channels offer the same configuration options The module supports five primary input functions Counter e Quadrature Counter Pulse Catch Edge Timer Dual Edge Timer Each of the primary functions uses one or two input terminals for making connections to field devices plus a common Combinations of the listed functions are possible CTRIO Workbench disallows any unsupported configurations Three secondary input functions are also supported Reset Capture Inhibit Each secondary input modifies the primary input functions in some way and uses one input terminal Limit Out 0 and Limit Out 2 input functions are only available for use when the outputs are set to pulse output mode Discrete Outputs Pre Assigned to Input Functions CTRIO discrete outputs can be assigned to the Counter Timer and Pulse Catch input functions within the Configure I O dialog The outputs respond to presets assigned by the user in the Preset Tables dialog The presets are assigned based on the scaled value of an input or the raw value if it has no scaled value The CTRIOS four outputs can all be assigned to one function or they can be grouped within functions and within channels in any manner selected by the user See Chapter 5 for more information on using Preset Tables Counter I O User Manual 4 3 Ch
33. 1 then reverse to Limit 2 at Frequency 2 Frequency 1 Ie 2 o l Frequency 2 gt t t Limit 1 Limit 2 Home 4 Run to Limit 1 at Frequency 1 then continue to Count at Frequency 2 Frequency2 Frequency 1 Count Home Limit 1 5 Run to Limit 1 at Frequency 1 then reverse to Count at Frequency 2 Frequency 1 Iq o Frequency 2 Counter I O User Manual 5 15 Chapter 5 Configuring the CTRIO Outputs Additional Pulse Profiles Three additional pulse profiles are available to use that are not Q defined or created using the Pulse Profiles Table dialog however the output s must be configured for Pulse Step Direction or Pulse CW CCW using the Configure I O dialog The profile parameters are stored in the CPU controller memory registers The profiles are briefly described below and will be discussed in detail in Chapter 6 With all three profiles the output is a step response output to the specified target frequency thus no acceleration deceleration parameters are configured Velocity Mode User specifies the target frequency pulse train duty cycle and the step count Once initiated the output will begin pulsing at the target frequency and continue until the step count is reached With a step count of OxFFFFFFFE the pulse output will continue indefinetly until the control program disables the output Run to Limit Mode User specifies target frequ
34. 4 v rrr vh a ee eL e e e Te MUR RARO UR TR C RAT HR 45 Pulse Cateh m 46 Edge Timer suciis osse cee gee nee ii baw Pa eee a ee ee a i eee eee ee 47 Dual Edge Timer cites de detects isped oie oe sa ep Re he kd d e E NAN SERRA UI did 4 8 Soft Resets soc IER Pa VIG waste Nh Saad Brana dei docile ene IRL MAR oe SAVE d 4 9 Reset 1 and Reset 2 Hard Resets for Counters Only 0 000 eee 4 9 Counter I O User Manual Table of Contents Capture T ocorre ces ee tads a a ahaa Hg OA a a 08 19 0628 DR DV 8 DR DR TR GR a OR T UU 4 10 Inhibit os ike R9 Rx x Rabe bebe ee ee DEG Se RR EIE E ee 4 10 Introduction to the Scaling Wizard 2 0 0 cece cee ee eee eee 411 Scaling Wizard Examples for Counter Functions 0 0 0 eee eee eee 4 11 Position Scaling Counter 1 0 cee ce ene tenes 4 12 Rate Scaling Counter cecep ssi ipia a a eee tenet eee I 9h 4 13 Using the Scaling Wizard with Timer Functions 0000s eee eee 4 14 Interval Scaling Timer rrr cesare cece eee eee III 4 14 Chapter 5 Configuring the Outputs Using CTRIO Workbench Configure IO Dialog Overview 0 cece cee eee eee hn 5 2 Output Function Selections 0 0 0 ccc cee ee eee eee hn 5 3 Supported Functions essere e ue ears dee ee RES CS EEN ESSERE EES 5 3 CTRIO Memory Usage Pulse Profiles and Preset Tables 004 5 3 Raw OUtpUt iiec RR wal assan BRO WED 8 4 81 a ale alae Re 0 5 4 Discrete Outputs
35. 6 7 gt Entry types are defined below Follows format of Input DWord Parameter 1 5 Flash ROM is rated for 100 000 writes Counter Quad Counter Reset must be ON to perform the Edit Entry Number for Edit Table Entry Commands The Entry Number refers to the position of the preset in the table sequence The first preset is Entry Number 0 the second preset is 1 and so forth Entry Type for Edit Table Entry Commands The Entry Type is defined according to the table below Entry Type Write Output ON Set Write Output OFF Reset Pulse Output ON Pulse Output OFF Toggle Output Reset Function 6 24 Counter I O User Manual Edits preset that resets count Chapter 6 Program Control Discrete Outputs Driven from a Scaled level Edit Level Response Command Code 30 If a Counter or Timer function is scaled to produce a rate alarm level settings can be used to trigger discrete outputs at values predetermined by the user The alarm levels can be set within CTRIO Workbench or from the user s control program Additionally a deadband percentage in tenths of a percent can be set to prevent the output from changing too frequently near the Rate Level threshold ON when greater condition example Consider a Discrete Output set to turn ON when a level gets to 100 with a 10 deadband The output will turn ON when the level gets to 100 If the level drops the output
36. Accel Time 1000 ms Decel Time 1000 ms C setFeg 40 He PosFeg 1000 Hz EndFreg 40 He Calculate Profile aie ots Min Freq Change 3 Min Entry Time 10 ms tma Total Pulses The total amount of output pulses that will be generated during the Trapezoidal profile Accel Time The amount of time required for the Start Frequency to ramp up the Position Frequency Decel Time The amount of time required for the Position Frequency to ramp down to the End Frequency Start Freq The frequency at which the Trapezoidal profile will begin Pos Freq The target frequency to which the Start Frequency rises End Freq The frequency to which the Position Frequency falls Min Freq Change The amount of calculated frequency change that must take place before stepping to the next frequency Min Entry Time The amount of time spent in each step 5 10 Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs Fe Symmetrical S Curve Profile The Symmetrical S Curve profile can also be used for applications that are sensitive to sudden changes in position or velocity resulting with vibrations or jerky reactions The Symmetrical S Curve provides more controlled acceleration and deceleration periods than a Trapezoidal profile by increasing the transistion times The S Curve and Symmetrical S Curve profiles differ in that the Symmetrical S Curve has symmetrical acceleration and deceleration pro
37. B C LLL D Step Amplifier ze 41 M 5 36VDC OPTO Power 3 xls YC Pulse or wA Yo Direction or COW 1 Y1 OUT Sinking Outputs Jumper Settings OOO O OOO Oj See page 2 3 for locating and setting the jumpers Counter I O User Manual 2 9 Chapter 2 Installation and Field Wiring se Installing the H2 CTRIO Module The H2 CTRIO module is compatible with several DL205 CPU slot interface devices Consideration must be given to the firmware versions of the CPU slot interfaces to assure their compatibility with the H2 CTRIO see chart below The H2 CTRIO module plugs into any I O slot of any DirectLogic 205 base except slot 0 when using a DirectLogic PLC or H2 PBC controller Slot 0 is available for the H2 CTRIO module when using the WinPLC or H2 EBC interface devices Slot 0 is the I O slot adjacent to the CPU The H2 CTRIO cannot be used in DL205 local expansion bases or in Serial Remote I O bases For installation instructions refer to the DL205 User Manual D2 USER M if using a DirectLogic PLC e DL205 Installation and I O Manual D2 INST M if using a WinPLC EBC Profibus slave interface module The first time you power up the CTRIO module you should see the OK LED blinking The blinking LED indicates that the module is in program mode CPU and CTRIO Compatibility Chart CPU slot Device Firmware Hardware DirectSOFT32 Slot Restrictions D2 240 v 3 22 or later v 3 0C Build 71 or later any 1
38. Bit of Word PLC Control Outputs Base Addr V2030 Control Relay D2 240 PLCStatus Inputs Base Addr V2000 Control Relay D2 240 Description Pulse Catch Starting V2020 0 C160 On when Pulse Catch is in progress Enable Pulse Catch V2054 0 Turn ON to Enable Pulse Catch Function Pulse Catch Output Pulse State e V2020 1 ON for the Pulse Output Width duration specified in Configure 1 0 The CTRIO will not recognize any input pulses while the Output Pulse is active Take this into consideration when configuraing the Pulse Output Width time 6 22 Counter I O User Manual Chapter 6 Program Control nnn RRR Runtime Changes to CTRIO Configured Preset Tables Presets and preset tables can be set up entirely within CTRIO Workbench so that no program control is necessary to assign discrete Preset Tables to CTRIO Input Fuctions You can make runtime edits to presets preset tables from your control program To make a runtime change a series of commands must be executed which will pass new values to a preset table or call a different preconfigured table Command Codes are passed to the CTRIO module to effect the required edit Each Command Code has its own syntax and all Command Codes must be presented in a particular sequence The command code and associated parameters must be loaded into the appropriate memory locations A Process Command instruction must be
39. CTRIO DEVNETS MODBUS from Output Start octal Command Code 0 6 10 16 Word Parameter 1 1 7 11 17 Word Parameter 2 2 8 12 20 DWord Control DWord Offsets WinPLC EBC V memory Offsets CPU to CTRIO PBC DEVNETS MODBUS from Output Start octal DWord Parameter 3 0 2 0 4 Counter I O User Manual 6 23 Chapter 6 Program Control Runtime Changes Contd Command DirectLOGIC n 10 Parameter 1 Word DirectLOGIC n 11 Parameter 2 Word DirectLOGIC n 12 decimal se Parameter 3 DWord DirectLOGIC n 0 n 1 decimal Load Table from RAM File Number decimal Clear RAM Table Initialize RAM Table Entry Type decimal Pulse Time Preset Count Time4 Add Table Entry Entry Type decimal Pulse Time Preset Count Time4 Edit Table Entry File amp 2 14 Entry Num 82 Entry Types Hex BCD Pulse Time Preset Count Time4 Write RAM to ROMS 999 Edit and Reload File amp 2 15 Entry Num amp Entry Type3 Hex BCD Pulse Time Preset Count Time Initialize Table on Reset Entry Type decimal Pulse Time Preset Count Time4 Run to Position Target Position Edit Level Response If appropriate for Entry Type in ms Level Behavior decimal Deadband Level Rate Setting Field entries separated by an amp are to be loaded in the high byte and low byte of that word See example on page
40. Count input functions Raw mode Direct access to discrete outputs from user application program Target Position Range 2 1 billion 32 bits or 31 bits sign bit 1 6 Counter I O User Manual Chapter 1 Introduction Fs HO CTRIO LED Indicators HO CTRIO LED Descriptions Module OK User Program Error Ch1 F1 Resource State Ch1 F2 Resource State OK Output Status HO CTRIO LED Diagnostic Definitions ERR Description ON OFF All is well RUN Mode ON ON Hardware Failure Blinking Blinking Boot Mode Used for Field OS Upgrades Blinking OFF Program Mode OFF Blinking Module Self diagnostic Failure OFF ON Module Error Due to Watchdog Timeout OFF OFF No Power to Module HO CTRIO LED Diagnostic Definitions Blinks when Channel 1 Function 1 is counting or timing Blinks when Channel 1 Function 2 is counting or timing Follow actual output state ON output is passing current Counter I O User Manual 7 Chapter 1 Introduction i H2 CTRIO LED Indicators H2 CTRIO LED Descriptions Module OK User Program Error Channel 1 Status Channel 2 Status OK Output Status H2 CTRIO LED Diagnostic Definitions ER Description ON OFF All is well RUN Mode ON ON Hardware Failure Blinking Blinking Boot Mode Used for Field O
41. GSD file for use with Workbench version 2 This can be downloaded from www automationdirect com H2 WinPLC H2 H4 EBC TIK DEVNETS T1K MODBUS and T1H PBC Users These controllers are not impacted by the expanded I O map in version 2 Using CTRIO Workbench Version 1 If you prefer to continue using CTRIO version 1 and Workbench version 1 you will need to use the update Firmware function within Workbench to load version 1 0 1 firmware into the CTRIO module Version 2 features will not be accessable when using version 1 firmware 1 2 Counter I O User Manual Chapter 1 Introduction CTRIO Module Overview The H0 CTRIO H2 CTRIO H4 CTRIO and TIH CTRIO Counter I O CTRIO modules are designed to accept high speed pulse type input signals for counting or timing applications and designed to provide high speed pulse type output signals for servo stepper motor control HO CTRIO H2 CTRIO H4 CTRIO T1H CTRIO monitoring alarm or other discrete control functions All CTRIO modules offer great flexibility for applications which call for precise counting or timing based on input events or for high speed control output applications The CTRIO can be used for applications that call for a combination of both high speed input and high speed output control functions For ease of documentation purposes CTRIO will be used to designate all four CTRIO modules HO CTRIO H2 CTRIO H4 CTRIO and T1H CTRIO when the functionality
42. Output clamp voltage 60VDC Maximum load current 1 0A Maximum load voltage 36VDC Maximum leakage current 100yA Inrush current 5A for 20ms OFF to ON response less than 3usec ON to OFF response less than 3usec ON state V drop lt 03V External power supply for loop power only not required for internal module function Overcurrent protection 15A max Thermal shutdown Tjunction 150 C Overtemperature reset Tjunction 130 C Duty cycle range 1 to 99 in 1 increments default 50 Configurable Presets a each output can be assigned one preset or a single b each output can be assigned one table of presets one table can contain i max 128 presets max predefined tables 255 User supplied power source required for stepper drive configurations CTRIO Output Resources Pulse output Discrete outputs _ Pulse outputs 2 channels 2 outputs per each channel H2 H4 T1H CTRIO Discrete outputs 4 pts Pulse output Discrete outputs Pulse outputs 1 channel 2 outputs per single channel HO CTRIO Discrete outputs 2 pts Pulse outputs pulse direction or cw ccw Profiles Trapezoid S Curve Symmetrical S Curve Dynamic Position Dynamic Velocity Home Search Velocity Mode Run to Limit Mode Run to Position Mode Resource Options Discrete outputs configurable for set reset pulse on pulse off toggle reset count functions assigned to respond to Timer
43. Process Command C1 SET Initialize Settings Complete Direction Control C2 B2056 4 3 oo OUT Direction Initialize Settings Command Command Complete Complete Error C1 B2022 7 B2022 6 B2056 7 4 I RST Process Command This rung waits for the Command B2056 0 Complete bit with no Command Error before Enabling the Output SET Enable Output Initialize Settings co C1 an p Initialize Settings RST Complete his rung stops the pulse output B2056 0 by disabling the Enable Output bit RST Enable Qutput B2056 7 S RST Process Command 6 END Counter I O User Manual 8 3 Chapter 8 DirectLOGIC Logic Programming Examples EM Dynamic Positioning The following example program runs a Dynamic Positioning pulse profile Turn on CO to load the profile number and process the command Turning on C2 will start the pulse output to position specified in Parameter 3 The sign of the value in the target pulse count register controls the pulse output direction When a new position is specified the CTRIO moves to the new position relative to its previous position as long as the Enable Output bit remains set Clearing the Enable Ouput bit will disable output pulsing and reset the current position to 0 DirectSOFT 32 First Scan 1 ne ED K10 Load Table Command bu 0x10 Hex OUT V2040 Command Code Register Initialize Settings co iwi Table File Number i E E Decimal This rung loads loads
44. Reset 2 Hard Resets for Counters Only Reset 1 is available only if you have selected a Counter or Quad Counter as the primary function For example if you have chosen either counter function single ended or quadrature on terminal 1A you will have an option of using terminal 1C for a hard reset signal Other options are available on terminal 1D Those options are Capture and Inhibit see next page Reset 2 is available if you have selected to use terminal 1B fora connected to terminal 1B Two distinct types of hard resets are available One is an edge reset The other is a level reset The Edge Reset sets the current count to zero on the specified edge rising or falling of the reset pulse see upper exampel The Level Reset resets the count to zero as long as the reset pulse is held high or low depending on configuration When the reset pulse disappears the count resumes see lower example If the Reset options are not available in the Configure IO dialog then you have selected input functions that do not use the reset modifier Reset 1 and Reset 2 represent hard wired inputs to terminal C or D An appropriate field device must be connected to the designated terminal to perform the reset function Soft Resets P Unassigned I Reset Reset Value counter input Reset 2 will reset the counter gt ng 6 q Q KA o n 1 n 1 2 A 29 9 M p ag
45. The velocity can be changed on the fly by entering a different value into V3000 The sign of the value in the target velocity register controls the pulse output direction Clearing the Output Enable bit will always suspend pulsing First Scan SPO ED Load Table 0x10 Hex OUT V2040 Command Code Register Initialize Settings re LD Table File Number 2 cs K1 i r Decimal This rung loads loads the QUT any Parameter 1 Profile Dynamic velocity profile File Number into Parameter 1 a Initialize Settings Complet nitialize Settings Complete Initialize gt ene Settings Complete C1 B2056 7 3 ES SET Process Command c3 Change Velocity Complete I Command Complete Command Error B2022 7 B2022 6 B2056 7 4 1 RsT Process Command This rung waits for the Command T Complete bit with no Command SET Enable Output Error before Enabling the Output Change Velocity Enable Start Output C2 B2056 0 Dp 5 V3000 Target Velocity iis rung Iade the aor e Velocity holding register into UID eo Parameter3 Target Velocity register Target Velocity Parameter 3 C3 L PD Change Velocity Complete Initialize Settings CO B2056 0 6 HF RST Enable Output This rung stops the pulse output by B2056 7 disabling the Enable Output bit It RST Process Command also resets the position count to 0 7 END Counter I O User Manu
46. Timer The Edge Timer measures the time from the rising edge of one pulse to the rising edge of the next pulse or the o e rising edge of one pulse to the falling edge of the same 0 pulse or the falling edge of one pulse to the falling edge q C of the next pulse Encoders proximity sensors etc can ip be connected to input C and or input D on either 2 e channel or both channels The CTRIO discrete output s aD D can be assigned to the Timer function using the Preset o S Tables dialog Refer to Creating and Using the Output q Tables section in Chapter 5 for details D e e To insure proper operation the field device wiring and the e QD configuration must be compatible For wiring information see e e Chapter 2 Notice that the module four input terminals are represented by the A B C and D boxes on the left side of this dialog If you are wiring your input to terminal 1C you will need to select the Channel 1 tab near the top of this window and click Counter in box C At this point you have four decisions to make regarding your input at 1C s TITI m 9 1 First designate the pulse edges you want SE me ex lt to measure between There are four choices me om aee 5 You can measure the time from the leading L3 E can f r Ree E ix edge of the upward pulse to the leading a T edge of the next upward pulse or from the npm
47. V2041 V2041 File containing cw accel decel and ccw acccel decel Process Command V2056 7 C227 Turn ON until Command Complete status bit is returned Command Complete Status V2022 7 When ON Profile is now loaded clear Process Command bit Command Error V2022 6 ON if Command or Parameters are invalid Enable Output V2056 0 C220 Turn ON to ramp to target velocity Turn OFF to disable pulses Parameter 3 V2031 V2030 V2031 V2030 Target velocity User defined DWord Output Active Status V2022 4 When ON module is pulsing Suspend Output V2056 2 Turn ON to pause output pulses without resetting pulse count Output Suspended V2022 2 The sign of the value in the Target Velocity register 4 Parameter 3 determines the direction of the pulse train output In the DzrectLOGIC programming example to the right BCD 5000 is converted to decimal 5000 when CO is turned ON You could load LD a V memory location instead of using a constant as shown in the example 6 3 8 Counter I O User Manual For a D2 250 use ADDB K1 ON when out pulse train has been suspended LD K5000 BIN INV ADDD 3000 Chapter 6 Program Control Dynamic Velocity Mode Flowchart The flowchart below provides the logical sequence necessary to execute a Dynamic V
48. and or description applies to all four modules III y The CTRIO module has its own menm Cot cdd Mode tne Cor Opens microprocessor and operates ae 0t emo i M asynchronously with respect to the Parise P MeSonTee us CPU The response time of on board gs eo em outputs is based on the module scan LL 21 SERRE aaa time not the CPU s scan time a CHfn QusdCourterw Cachae OO Pike Outcast Monier UO CTRIO Workbench wna re All module configuration is done via oti seil Boag a ell ae a software utility eliminating the en Ml erum mem need for ladder programming to Tasted ze Ue vous EXE Dur VD Losco configure the module The software echo reve tite sn rent ating utility is called CTRIO Workbench Haste tio 773 CTRIO Functions The CTRIO module supports five primary input functions Counter Quad Counter Pulse Catch Edge Timer and Dual Edge Timer Three secondary input functions are also supported These functions Reset Capture and Inhibit each modify the primary input functions in some way Information is available about each of the primary and secondary functions in chapter 4 The CTRIO module supports three primary output functions Pulse train output for servo stepper motor control configurable for CW CCW or step and direction discrete output functions assigned to Counter Timer input functions and raw output control directly from the CPU interface program Information is av
49. are not fault tolerant and are not designed manufactured or intended for use or resale as on line control equipment in hazardous environments requiring fail safe performance such as in the operation of nuclear facilities aircraft navigation or communication systems air traffic control direct life support machines or weapons systems in which the failure of the product could lead directly to death personal injury or severe physical or environmental damage High Risk Activities Automationdirect com specifically disclaims any expressed or implied warranty of fitness for High Risk Activities For additional warranty and safety information see the Terms and Conditions section of our catalog If you have any questions concerning the installation or operation of this equipment or if you need additional information please call us at 770 844 4200 This publication is based on information that was available at the time it was printed At Automationdirect com we constantly strive to improve our products and services so we reserve the right to make changes to the products and or publications at any time without notice and without any obligation This publication may also discuss features that may not be available in certain revisions of the product This publication may contain references to products produced and or offered by other companies The product and company names may be trademarked and are the sole property of their respective owner
50. commons between Ch 1 amp Ch 2 Example for High Side sourcing outputs on Y0 Y3 use the CO to C1 CO to C2 and CO to C3 jumpers Wire 5 36VDC to any of the C terminals Example for Low Side Wire OVC END on C0 C3 use the YO to Y1 YO to Y2 and YO to Y3 jumpers Wire OVDC GND to any one of the Y terminals YO to Y1 Y2 Y3 C0 to C1 C2 C3 Share commons between high or low side of outputs when isolation is not require Counter I O User Manual l 2 1 1 Chapter 2 Installation and Field Wiring Wiring the H2 CTRIO Module The H2 CTRIO module has two independent input channels each consisting of 4 optically isolated input points pts LA 1D on common 1M and pts 2A 2D on common 2M The inputs can be wired to either sink or source current The module has 4 optically isolated output points pts YO Y3 with isolated commons C0 C3 respectively The outputs must be wired so positive current flows into Cn terminal and then out of the Yn terminal see the diagram below and the schematic on page 2 16 Remember that the internal CTR 24VDC jumpers can be used to iN GUA PUTS connect the input commons or ess oK outputs output commons 60 2 P CMM ERE together Qo o c
51. current count register to simulate retentive counts memory It also gives you the ability to read the current pulse count You can also change the reset to value without reconfiguring the CTRIO a added Dynamic Velocity profile similar to straight velocity but adds accel decel between velocity changes and determines direction from the input velocity value 7 added offline configuration options for all CPU Controllers 8 can configure the CTRIO outputs as Raw simple discrete outputs 9 added Timeout feature for Timer Functions and Suspend Output feature for pulse outputs Expanded I O Map Implications DL205 DirectLogic Users Does not apply to DL05 405 and Terminator I O Users If you have a H2 CTRIO configuration created in version 1 with the outputs mapped immediately following the inputs you will need to adjust the V memory assignments in your PLC program if you intend to use CTRIO Workbench version 2 For example if your existing CTRIO map uses V2000 V2023 for inputs and V2024 V2053 for outputs you will need to adjust the output V memory starting address by 32 bits to make room for the additional input memory usage V2000 V2025 for the inputs and V2026 V2057 for the outputs Also if you are presently using any of the four V memory locations immediately following the output memory map V2053 V2057 those V memory locations will also be adjusted due to the expanded I O memory usage H2 PBC Users The H2 PBC requires an updated
52. des codes de la National Electrical Manufacturer s Association NEMA Des organismes de r glementation ou des services gouvernementaux locaux peuvent galement vous aider d terminer les codes ainsi que les normes respecter pour assurer une installation et un fonctionnement s rs L omission de respecter la totalit des codes et des normes applicables peut entrainer des dommages l quipement ou causer de graves blessures au personnel Nous ne garantissons pas que les produits d crits dans cette publication conviennent votre application particuli re et nous n assumons aucune responsabilit l gard de la conception de l installation ou du fonctionnement de votre produit Nos produits ne sont pas insensibles aux d faillances et ne sont ni conqus ni fabriqu s pour l utilisation ou la revente en tant qu quipement de commande en ligne dans des environnements dangereux n cessitant une s curit absolue par exemple l exploitation d installations nucl aires les syst mes de navigation a rienne ou de communication le contr le de la circulation a rienne les quipements de survie ou les syst mes d armes pour lesquels la d faillance du produit peut provoquer la mort des blessures corporelles ou de graves dommages mat riels ou environnementaux activit s risque lev La soci t Automationdirect comMC nie toute garantie expresse ou implicite d aptitude l emploi en ce qui a trait aux activit s risque lev
53. dialog shown to the right Notice that the window has a tab for XM each input Channel Channel 1 and Channel 2 offer the same Function 2 configuration options Remember that EE 7 Dual Edge Timer the HO CTRIO only has one input channel EE The input options are listed by Tess function Four boxes labeled A B C and D correspond to the input HO CTRIO Configure I O Dialog terminals on the face of the module LA 1D or 2A 2D A D for the Channel Dupuis H0 CTRIO a The Output functions are listed as 0 1 ued Cour Biesen X 2 and 3 These numbers correspond to the markings beside the modules output ns 1g terminals Y0 Y3 YO Y1 for the Br H0 CTRIO For example you might click on E pe T sae m Discrete Output in the 0 box then Busi Timer OK to return to the main Workbench window Once you arrive back at the 5 5 s use Catcl LE main window you must click Write Eee Tine Module to save your selection to the module The module will need to be in Program Mode to perform the Write o cms Module operation If you do not perform the Write Module operation or a Write File operation your configuration will be lost upon quitting Workbench This applies to all changes to the module configuration 5 2 Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs ae Output Function Selections Supported Functions
54. direction f fionnarem 2 Each input pulse is counted but you are free to 727 onm ae a designate whether you want the count to register ven Facti on the rising edge of the pulse the falling edge or jem elem ei ocu BE both The button with the graphical Ej comm ral Dns on representation of a pulse toggles between these l choices nu p u a Vee Discrete ces Chit Feit 3 The Reset value is assigned by clicking and typing a value in the data input field This value is f mem ca m X 7 for hardwired resets When the hardwired reset is Rz B activated the count value returns to the reset value o eee peee Cavern Doce ene 4 The last remaining decision to be made is about wm scaling Clicking the button with the ruler symbol l starts the Scaling Wizard We discuss the scaling C __ cen wizard later in this chapter The Scaling Wizard is intelligent in that it offers scaling options that are appropriate for your input selections 4 4 Counter I O User Manual Chapter 4 Configuring the CTRIO Inputs FO Quad Counter 1A The CTRIO module supports quadrature counting ao e using quadrature encoders as inputs Connect your 0 B encoder to input A and input B on either channel A D Q second quadrature endcoder can be connected to the Q w other channel The C and D inputs are available to 2 cont
55. e D D Edge Reset 7 e o a Q e gt S gt rj S a n 1 ny 1 S Im S SSES g Q S Q gt Zz a M OSes DS e Level Reset a 8 S E E Q Soft resets are available by turning on the appropriate control bit in your control program Counters only or by using the Reset Count function within a Discrete Output Preset Table configuration Counters Timers Counter control bit resets are always level resets meaning they hold the count at zero until the reset bit is turned off Counter I O User Manual 4 9 Chapter 4 Configuring the CTRIO Inputs o Capture 1 Capture 1 is available only if you have selected a Counter or Quad Counter as the primary function For example if you have chosen either counter function on _ 2 terminal 1A you will have an option of using terminal E Q 1D for a capture signal D q ndoon o nae Capture 1 snapshots the current count into the 2nd Q e DWord register Parameter 2 The Capture feature is XQ im available with a single ended Counter on input A or a ND I Quad Counter on inputs A and B eg S co G e Capture 1 represents a hard wired input to terminal D An Q D dd appropriate field device must be connected to the designated a B terminal to perform the capture function g a ie e
56. for the inputs and outputs based on the CTRIOS position with respect to the T1K MODBUS controller and other CTRIO modules in the system The example below on the left assumes the T1H CTRIO is the first intelligent module following the TIK MODBUS controller When using the T1H CTIO module with a TIK MODBUS controller configured for 585 985 addressing mode enter the Starting Modbus register address for the inputs and outputs based on the CTRIOS position with respect to the T1K MODBUS controller and other CTRIO modules in the system The example below on the right assumes the T1H CTRIO is the first intelligent module in following the T1K MODBUS controller DirectLOGIC PLC Addressing Mode Oups Mae p ooo cms Ret iros Me est Functions Output Functicns System Functions iA nt Quad Courter DU Ar Lap Tn Donde teams DR VaR Y Revver VSE rabie Capi ox 7 c nem rem j Oupa Data Cortes CIPO Oupa Data Cortes CTED ru Modbus 585 985 Addressing Mode CI pe xj Map Dectay Mode oua Map Opa Map TI MODBUS PLC Adds State Media ys beak aa D e Ryg Rege Rer Ld i Vut Functions Ove Functions System Functions AA n Quad Courter red Dia CT RIO 9 Corb 5x9 d 2017 DU Ar Lape Ten s frou Data TRIO Cortot inoa Data CTAP 9 Cortsota ugs Data Koriste CTRI jan Tee Oupa Data erties OTRO Oupa Data ACTER Oups foa Kerisi o T
57. from CTRIO Workbench 1 3 5 7 Parameter 1 Contents DWORD 2 6 12 16 Parameter 2 Contents DWORD Non scaled Counter Raw Input Value Not Used Scaled Counter Scaled Value pos or rate Raw Value Non scaled Counter with Capture Raw Value Captured Value Scaled Counter with Capture Scaled Value pos or rate Captured Value Non scaled Timer Previous Time us In Progress Time us Scaled Timer Scaled Interval rate In Progress Time us Pulse Catch Counter I O User Manual Not Used Not Used Chapter 6 Program Control ann RRR Example Input Control Status Bits and Parameter Register Addresses The following tables provide example addresses based on V2000 selected for the base input address and V2030 selected for the base output address The Input Functions discussed on the following pages use these example addresses Status Registers Example using V2000 as base input address for Input Channel 1 Status bits and DWords received from CTRIO to CPU PLC Example 1 PLC Example 2 Name Bit of Word see note 2 Control Relay see note 1 Value D2 250 1 260 D4 450 D2 240 nae apt urg V2020 0 C160 ON when Capture is complete Timer Capture Starting V2020 0 C160 On when Timer Capture begins Timer Capture Complete Timing OR V2020 1 C161 ON when Timer Capture complete Counting E On when specified Timer Time Out period T
58. from and write to the CTRIO s internal registers The CTRIO s internal current count register can be read from or written to to if the input is configured for a Counter or Quadrature Counter Timer values are not accessable The CTRIO s internal current output pulse count can be read from or written to only if the pulse output is running Dynamic Velocity or Dynamic Positioning profiles See Chapter 8 for DirectLOGIC programming examples that use the RD and WT instructions to execute system function commands PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Relay D2 240 PLC Status Inputs Base Addr V2000 Control Relay D2 240 Action User Specifed to use with RD WT Instruction Command Code User Specifed to use with RD WT Instruction 1 Hex Read All Registers 2 Hex Write All Registers 4 Hex Write One Register 5 Hex Write Reset Value System Command Error V2024 6 ON if Command or Parameters are invalid System Command Complete V2024 7 When ON command has been accepted clear er Command it Process Command Note 1 V2060 7 Turn ON Command Complete status bit is returned The D2 240 CPU does not support bit of word addressing The status and control bits must be mapped to control relay words An example of mapping code is shown below S
59. has not been scaled We Seats De discuss scaling elsewhere in this chapter Hove Up Pulse ON and Pulse OFF require a Pulse TERM Time setting Sort Ascending Sort Descending The Pulse Time is set in ms 1 000 ms 1 sec Fora description of the Output Functions see page 5 6 Output Function reset To set a particular table as the default table use the Set Default Output Settings dialog described on page 5 6 f D i use UN C Pulse Off Pulse Time C Toggle jo ms C Reset Count Cancel 5 6 Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs Using the Discrete Outputs in Level Mode If a Counter or Timer function is scaled to produce a rate alarm level settings can be used to trigger discrete outputs at values predetermined by the user Click the Level button on the Configure I O dialog This will open the Default Output Settings Level Mode dialog The alarm level is set within the Default Output Settings Level Mode dialog Default Output Settings Level Mod xl Also a deadband percentage in tenths of a Default Level Command percent can be set to prevent the output from changing too frequently chattering near the Rate C None Level threshold ON when value is greater than level ON when greater condition example ON when value is less than level Consider a Discrete Output set to turn ON when a level gets to 500 rpm with a 10 deadband The output will turn ON whe
60. leaving this window Cancel Counter I O User Manual a 1 1 Chapter 4 Configuring the CTRIO Inputs SY Position Scaling Counter To select Position Scaling click the radio button beside the word Position Now click Next to move to the Output Settings dialog On the Output Settings dialog you will notice the field for engineering units Enter an appropriate value for Position Scaling for example yards feet meters cubic inches etc Engineering Units vds up to 4 characters Output Format Floating Point Integer rounded Seven data types are available including BCD integer i aid decimal placa to make values more easily used by Integer x100 2 implied decimal places C BCD rounded DirectLOGIC PLCs C BCD x10 1 implied decimal place Click Next to open the Position Settings BCD 100 2 implied decimal places dialog It is here that you enter the span of raw counts that equates to a span of engineering units This window contains a calculator to double check EIS MAE ES Tet RTT TT ES x the meaning of your Position Settings Enter a value into the Raw Value field to see the equivalent Minimum Raw Value O counts value in engineering units Maximum Raw Value fi 000 counts Minimum Scaled Value o yds Maximum Scaled Value 300 yds Position Scaling Calculator Cancel lt Back L ee Enter a raw count value to confirm scaling configuration Raw Value 25d counts
61. output is active Load the Duty Cycle value into Parameter 2 Hex Load the Pulse Count into Parameter 3 Decimal New Frequency or Duty Cycle The Output Active bit will be ON until the CTRIO sends out all of the pulses you configured Is You can also suspend the Output Active pulse output at any time with SET RESET the Suspend Output bit ON Process Process Command Command RESET Output Enable Change Direction Command Complete ON RESET Output Enable Counter I O User Manual 6 41 Chapter 6 Program Control Run to Limit Mode Run to Limit Mode controls the pulse outputs directly from the CPU controller program No CTRIO Workbench Pulse Profile is required for this mode The Run to Limit Command 0021Hex BCD can be used to seek limit positions or for Home Search routines You may want to consider using the Home Search Pulse Profile s created using Workbench unless you need the CPU controller to control the entire profile and parameters etc The CTRIO input must be assigned for Limit by the CTRIO Workbench utility Set Word Parameter 1 to the desired Frequency Set Word Parameter 2 Low Byte to the Duty Cycle and the High Byte to the Edge to Seek as defined below Leaving the Duty Cycle set to 0 achieves the default 50 otherwise it can be set in 1 increments by writing this value from 1 to 99 Hex BCD The flowch
62. page 6 16 and will be mapped to V2000 V2003 in this example If input D is configured for count Capture the Enable Count Capture bit must be ON in order for input D to be able to snapshot the current count The Count Capture Complete bit is used to indicate the acquisition has occurred The program will need to turn OFF the Enable Capture and confirm the Capture Complete bit resets before attempting the next count capture The Reset bit will reset raw and scaled values to the specified reset value The last captured value if applicable will remain PLC Control Outputs Base Addr V2030 Bit of Word Name PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 D2 240 Control Relay PLC Status Inputs Base Addr V2000 Control Relay D2 240 Chapter 6 Program Control Fs Description Parameter 1 V2001 V2000 V2001 V2000 refer to table on page 6 16 Parameter 2 V2003 V2002 V2003 V2002 refer to table on page 6 16 Counter Capture Complete V2020 0 C160 On when Count Capture is complete Available only when input D is configured for Capture input Enable Count Capture V2054 0 Turn ON to Capture Count Available only when input D is configured for Capture input Reset V2054 1 Turn ON to Reset Counter Value to Reset Value At Reset Value V2020 1 On when Counter is at Reset Value Counter I O Us
63. written to only if the pulse output is running Dynamic Velocity or Dynamic Positioning profiles DirectLogic Users The reading from and writing to the CTRIO internal registers is accomplished using the DirectLOGIC Read from Intelligent module RD and Write to Intelligent module WT instructions respectively See chapter 8 for Systems Functions ladder logic examples EBC WinPLC PBC DEVNETS MODBUS Users The Systems Functions dialog is available for use when connected to these interface devices however there is currently no way for the user control program to read from or write to the CTRIO s internal registers Monitor 1 0 x 1 0 Status amp Input Functions Output Functions System Functions SysCmd Offset 0480 0x81 Offset Register Value 0x02 Write all registers 0404 Write one register Ov82 085 Chi Fni 95 0x05 Write reset value Ov86 0K89 Chl Fn2 d OWBA amp BD Ch2 Fni D OdE 091 Ch2 Fn2 D Process SysCmd 032 0495 Output 0 died Syma Ener Off 0x86 0x98 Output 1 g SysCmd Complete Of Ov9A 0x9D Output 2 o OE OA1 Duput3 o L CTRIO read of PLC outputs is gt gt Suspended lt lt Click to enable Last Eror Code 0 No error 7 6 Counter I O User Manual Chapter 7 Using Monitor I O nnn RRR Monitor I O Error Codes The appropriate error code listed below will be displayed on the Monitor I O Status Bar when an error occurs Error Code Description 0 N
64. 0 9 8 7 6 5 4 3 2 1 0 V2524 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 V2524 9 1 f V2524 1 1 Addressing High and Low Byte of Word Parameters In the following example the V memory location V2510 contains a value equal to 3 decimal in the high byte and 10 decimal in the low byte 3 decimal 03 Hex 0000 0011 binary in the high byte and 10 decimal 0A Hex 0000 1010 binary in the low byte This example could represent the Command Code Edit Table Entry The value 03 Hex would represent the File number in the high byte and the 0A Hex would represent the remainder of the Command Code in the low byte High Byte Low Byte Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 V2510 0 0 0 0 0 0 1 1 0 0 0 0 1 0 1 0 High Nibble Low Nibble High Nibble Low Nibble Addressing High and Low Word of DWord Parameters Double Word parameters are addressed in a similar fashion to the high and low bytes of a Word Parameter For example a DWord that begins in V2300 consumes both V2300 and V2301 The Low Word is V2300 and the High Word is V2301 Counter I O User Manual 6 15 Chapter 6 Program Control SY Input Function Status Control Bits and Parameters Input Function Status Bit Definitions Input function offsets are listed in the order of Ch1 Fn1 Chl Fn2 Ch2 Fn1 Ch2 Fn2 Ch x Fn x Status Bits transfers from CTRIO to CPU Bit Of
65. 0 slot except 0 D2 250 v 1 56 or later v 3 0C Build 71 or later any 1 0 slot except 0 D2 250 1 v 3 5 or later v 3 0C Build 71 or later any 1 0 slot except 0 D2 260 v 1 2 or later v 4 0 or later any 1 0 slot except 0 H2 WinPLC 7 XK or later any 1 0 slot i prior to Rev 9A any 1 0 slot except 0 H2 EBC v 2 1 357 or later Rev 9A or later any 1 0 slot T i prior to Rev 4A any 1 0 slot except 0 eres Rev 4A or later any 1 0 slot Updated firmware versions can be downloaded from our web site at www automationdirect com Note for applications requiring multiple CTRIO modules DirecfLOGIC CPUs and dynamic access in ladder logic to CTRIO data we recommend using the D2 250 1 or D2 260 CPU These CPUs support Bit of Word addressing 32 bit math instructions and have adequate memory for multiple CTRIO applications 2 i 10 Counter I O User Manual Chapter 2 Installation and Field Wiring Eu Setting H2 CTRIO Jumpers Jumpers are provided to connect input commons or outputs output commons Use of these jumpers is not necessary to set up the CTRIO module The jumpers are provided solely for convenience in wiring 1M to 2M 1M e e 2M YO e e Yi YO e e Y2 7 Yole e Y3 3 CO le e C1 z C0 e e C2 co ee C3 Jumper Settings Share input
66. 01 V2000 V2001 V2000 Previous Time Parameter 2 V2003 V2002 V2003 V2002 In Progress Time Timer Capture V2020 0 C160 On when Time Capture is in progress Starting Enable Timer Capture V2054 0 Turn ON to Enable Timer Capture Function Not available when Free Run Timer option is selected Timer Capture V2020 1 On when Timing is complete Complete Timer Timeout Bit V2020 2 6 20 Counter I O User Manual Chapter 6 Program Control SG Edge and Dual Edge Timer Timeout Function The Timer Timeout Function is available for use with standard and Free Run Timers It is primarily used in Free Run timing of recurring events rate velocity calculations etc The specified Timeout Period is in effect once the timer is enabled until receiving the first configured input edge Then it is in effect until receiving the next edge of the timing input to complete the timing cycle Standard Timers Once the timer is enabled the Timeout Bit is set if the time that it takes the CTRIO to see the configured input edge exceeds the specified Timeout Period The program will need to turn off the Enable Timer Capture bit and confirm the Timer Capture Complete bit and Timeout bit resets before attempting the next time capture cycle Once timing has been initiated if the time before the CTRIO sees the next configured edge exceeds the specified Timeout Period the Timeout bit is set The Timer register values are reset to
67. 5 A c Cuneet Court At Reset Value Reset Prenosi Tene Timer Captured Start Capture Complete Timed Out pt Enable Capture Output Enabled Position Loaded Output Suspended Output Active Output Stated Cond Emoe Cond Complete Command Code Parameter t Parameter 2 Parameter 3 Enable Output Goto Poution Suspend Output Direction D NOTE The exported nicknames are not unique to a specific slot number or module If you have multiple modules installed and wish to export from more than one module you will need to specify a unique prefix suffix If specified this two character identifier will be added to the rel Out PosLoded beginning or end of each nickname to ensure uniqueness Out OuSusp None C AddPrefiz 7 Add Suffix Unique Slot ID 1 or 2 characters Ou Parama Ouf Enion OK Cancel OaD Suspe Out Decton Counter I O User Manual 6 14 Chapter 6 Program Control SS Addressing Conventions with V memory Examples for DirectLOGIC PLCs Example for Bit accessed Data in PLC CPUs In this example the V memory location V2524 contains a value equal to 514 in decimal 514 decimal 0202 Hex 0000 0010 0000 0010 binary The bit V2524 1 refers to the 2nd to the least significant bit set to 1 in this example Likewise V2524 9 refers to bit number 9 the 10th from the least significant bit also set to 1 in this example Bit 15 14 13 12 11 1
68. A AH Quad Courter Oi Ard Lap Tee of os freut Duta CT RIO S Cortese VERO 2001 Cument Court VOLIE 9 BOT A Rata Caveat DAL Cut CIIM it Beo CUN DITN CT ORDIN EEpOMRUENIN C ipa Due pde NN y fesi TOALE SI Crate Cage Ca ce nem onm I O Map with EBC WinPLC When using the CTRIO module in an EBC WinPLC system non PLC system the addressing will be shown as Native EBC WinPLC addresses or if using Think amp Do the addressing can be shown as Native Think amp Do addresses Just click on the desired mode in the Map Display Mode field The 8 pt module offset described in the note above does not apply to EBC WinPLC or EBC Think amp Do systems Counter I O User Manual 6 9 Chapter 6 Program Control I O Map with an H2 PBC or T1H PBC Profibus DP Controller When using the CTRIO module with an H2 PBC or T1H PBC native Profibus addressing will be displayed in the I O Map as shown below For the T1H PBC the first two output bytes of memory are automatically reserved for the Hot Swap base rescan feature The H2 PBC does not support the Hot Swap feature H2 PBC IO Map T1H PBC IO Map Note that output bytes 0 1 are reserved for the Hot Swap base rescan feature Creating an offline file for H2 T1H CTRIO module For the T1 H PBC enter a 2 byte Output Offset to accommodate memory used by the Hot Swap base rescan feature This does not apply to an H2 PBC system The example show
69. Blocks Used 1 Total Pulses 10000 Accel Time 1000 ms Decel s Start Freg 40 Hz Pos Freg 1000 Hz Calculate Profile ime 1000 ms Hz Deceleration Time Total Pulses The total amount of output pulses that will be generated during the Trapezoidal profile Accel Time The amount of time required for the Start Frequency to ramp up the Position Frequency Decel Time The amount of time required for the Position Frequency to ramp down to the End Frequency Start Freq The frequency at which the Trapezoidal profile will begin Pos Freq The target frequency to which the Start Frequency rises End Freq The frequency to which the Position Frequency falls Counter I O User Manual 5 9 Chapter 5 Configuring the CTRIO Outputs a M S Curve Profile The S Curve profile can be used for applications that are sensitive to sudden changes in position or velocity resulting with vibrations or jerky reactions The S Curve profile provides more controlled acceleration and deceleration periods than the Trapezoidal profile by increasing the transistion times Edit Pulse Profile xl Profile Info Name Peak Freq 1000 Hz Total Time 10 99 sec Symmetrical Curve Dynamic Positioning Dynamic Velocity Home Search Accel Time 1000 ms Decel Time 1000 ms File Stats 34 File Number 1 Total Entries 11 Blocks Used 15 Total Pulses 10000
70. CTRIO High Speed Counter Module Manual Number HX CTRIO M M NARNING Thank you for purchasing automation equipment from Automationdirect com We want your new automation equipment to operate safely Anyone who installs or uses this equipment should read this publication and any other relevant publications before installing or operating the equipment To minimize the risk of potential safety problems you should follow all applicable local and national codes that regulate the installation and operation of your equipment These codes vary from area to area and usually change with time It is your responsibility to determine which codes should be followed and to verify that the equipment installation and operation is in compliance with the latest revision of these codes At a minimum you should follow all applicable sections of the National Fire Code National Electrical Code and the codes of the National Electrical Manufacturer s Association NEMA There may be local regulatory or government offices that can also help determine which codes and standards are necessary for safe installation and operation Equipment damage or serious injury to personnel can result from the failure to follow all applicable codes and standards We do not guarantee the products described in this publication are suitable for your particular application nor do we assume any responsibility for your product design installation or operation Our products
71. DC C2 OPTO Power OPTO Power y2 E gt Pulse or CW Pulse or wA C3 Direction or CCW D e Y3 YQ Qe Direction or CCW This example assumes that the Step Amplifier interface to be optocoupler LEDs common anodes at the OPTO Power terminal with internal current limiting resistors This is a standard method but you must consult you step amplifier documentation to ensure that this method is applicable 2 24 Counter I O User Manual Chapter 2 Installation and Field Wiring Se Installing the TLH CTRIO The TIH CTRIO module is compatible with several Terminator I O Network interface devices Consideration must be given to the firmware versions of the Network interfaces to assure their compatibility with the T1H CTRIO see chart below The TIH CTRIO module plugs into any valid I O slot in a Terminator I O system The T1H CTRIO cannot be used in Serial Remote I O bases T1K RSSS For installation instructions refer to the Terminator I O Installation and I O Manual T1K INST M The first time you power up the CTRIO module you should see the OK LED blinking The blinking LED indicates that the module is in program mode CPU and CTRIO Compatibility Chart CPU slot Device Firmware Hardware T1H EBC v 1 0 444 or later v 2l or later T1H PBC v 1 1 10 or later v 2D or later T1K DEVNETS v 1 80 or later T1K MODBUS v 1 80 or later Update
72. EE EE 1 4 CTRIO Specifications e e e Eas ti OOO CI E ma e ACE OR ae oe ee eee a 1 5 HO CTRIO LED Indicators eee s 1 7 H2 CTRIO LED Indicators ccc ec ec ee ec s 1 8 H4 CTRIO LED Indicators eee s 1 9 TIH CTRIO LED Indicators eee an 1 10 Chapter 2 Installation and Field Wiring Installing the HO CTRIO Module leeeeeeee nn 2 2 CPU and CTRIO Compatibility Chart 0 0 0 ee eee 2 2 Sinking Outputs oe xk en eere ndeee SESSA GA Oba pee RR he hee eire 2 3 Sourcing Outputs isses eR RR E EE aa ey x3 pe STE EE EES 2 3 Jurniper Selectloris si sipan 8308303 9 38 b RR sede te ostia Sod t ie Re a I Rte eae AE UR 2 3 Setting HO CTRIO Jumpers leseeeeeeee RR n 2 3 Table of Contents ii Wiring the HO CTRIO Module sseeeeeeee e hn n 2 4 HO CTRIO Quadrature Encoder Wiring Example 0 0000 e eee eee 2 5 HO CTRIO TTL Quadrature Encoder Field Wiring ee eee 2 6 HO CTRIO TTL Input Wiring lsleeeee cece eee eee es 2 Sinking Outputs Jumper Settings 0 0 0 cee eee eee ee ene 2 8 Sourcing Outputs Jumper Settings 1 0 0 ee eee 2 8 HO CTRIO Output Wiring Schematic 0 ccc eee ee eee 2 8 Sinking Outputs Jumper Settings 0 0 eee eee ene 2 9 HO CTRIO Stepper Servo Drive Wiring Example 0 eee eee eee 2 9 Installing the H2 CTRIO Module
73. Max Minimum Pulse Width 5 usec Input Voltage Range 9 30VDC Maximum Voltage 30VDC Input Voltage Protection Zener Clamped at 33VDC Rated Input Current 8mA typical 12mA maximum Minimum ON Voltage 9 0VDC Maximum OFF Voltage 2 0VDC Minimum ON Current 5 0mA 9VDC required to guarantee ON state Maximum OFF Current 2 0mA OFF to ON Response Less than 3 usec ON to OFF Response Less than 3 usec CTRIO Input Resources Counter Timer H2 H4 T1H CTRIO 4 2 per each 4 input channel group supports 2 quadrature counters max Counter Timer HO CTRIO 2 2 per single 4 input channel supports 1 quadrature counter max Resource Options 1X 2X or 4X Quadrature Up or Down Counter Edge Timer Dual Edge Timer Input Pulse Catch Reset Inhibit Capture Timer Range Resolution 42 billion 32 bits 1 usec Counter Range 2 1 billion 32 bits or 31 bits sign bit Counter I O User Manual 1 5 Chapter 1 Introduction a CTRIO Specifications CTRIO Output Specifications F 4 pts independently isolated current sourcing or sinking Outputs H2 H4 T1H CTRI0 FET Outputs open drain and source with floating gate drive E 2 pts isolated either both current sourcing or both current sourcing Outputs HO CTRIO FET Outputs open drain and source with floating gate drive Voltage range 5VDC 36VDC Maximum voltage 36VDC
74. Non scaled Counter Raw Input Value Not Used Scaled Counter Scaled Value pos or rate Raw Value Non scaled Counter with Capture Raw Value Captured Value Scaled Counter with Capture Scaled Value pos or rate Captured Value Non scaled Timer Previous Time us In Progress Time us Scaled Timer Scaled Interval rate In Progress Time us Pulse Catch Not Used 6 2 Counter I O User Manual Not Used Chapter 6 Program Control Input Function Status Bit Definitions Input function offsets are listed in the order of Ch1 Fn1 Chl Fn2 Ch2 Fn1 Ch2 Fn2 Ch x Fn x Status Bits transfers from CTRIO to CPU Bit Offsets WinPLC EBC PBC DEVNETS MODBUS For DirectSOFT32 users the 1 0 Map dialog displays the exact memory locations in use by the CTRIO module Within the I O Map dialog you can print out a report of memory loctions in use V memory Offsets DirectLOGIC PLCs Count Capture Complete Bit 0 8 16 24 20 0 20 8 21 0 21 8 Timer Capture Start 0 8 16 24 20 0 20 8 21 0 21 8 Timer Capture Complete Timing OR At Reset Value Counting 1 9 17 25 20 1 20 9 21 1 21 9 Timer Timed Out Bit 2 10 18 29 20 2 20 10 21 2 21 10 Pulse Catch Output Pulse State 0 8 16 24 20 0 20 8 21 0 21 8 Pulse Catch Start 1 9 17 25 20 1 20 9 21 1 21 9 Output Status Bit Definitions for Preset Table C
75. Offline Refer to chapter6 for 35 0 so en of g P A Search 5d Jasc Software CTRIO WB 2 EBC WinPLC i i ideli Fae EA offline addressing guidelines for some of the 2 Help ES k a interface devices To launch the CTRIO Ir Tom z Workbench 2 Offline version go to Start Programs AutomationDirect Tools CTRIO a ret WB2 Offline e fusus In the Workbench Offline window shown to the m right click on the Select PLC button Select desired MCI PLC or interface device The only limitations in the Offline version are that you cannot access Monitor I O and that you cannot ae connect to the CTRIO from the Offline utility Bm Save the configuration file to disk and connect to 99 Jou o a EET the CTRIO using the appropriate Workbench drm c support version then write the file to the CTRIO 777 seme bees m 3 2 Counter I O User Manual Chapter 3 Introduction to CTRIO Workbench Online CTRIO Configuration To configure the CTRIO module Online a CTRIO must be installed in the PLC base or Terminator I O system and the system power must be on Your PC communicates with the CTRIO module through the PLC or interface device port DirectSOFT32 Users You will need to connect your PC to any port ona DirectLOGIC CPU DCM or ECOM module If you are linked to your CPU through DirectSOFT32 CTRIO Workbench will start via the existing link If you are disconnected from your PLC and sta
76. P 1 LD Note 2 VC200 OUT V2060 LD V2024 OUT VC100 For example DirectSoft32 uses B2020 1 in the ladder code to indicate that you are addressing the second bit of V memory register 2020 The B prefix indicates bit of word addressing 6 48 Counter I O User Manual Chapter 6 Program Control a Reading All CTRIO s Internal Registers Flowcharts The flowcharts below provide the logical sequence necessary to Read the CTRIO s internal registers Reading the CTRIO s internal registers is a two step process 1 Ask the CTRIO to transfer the internal register values to its shared RAM 2 Transfer the values from the CTRIO s shared RAM to the controller s memory DirectLogic Read from CTRIO 1 This command tells the CTRIO to copy all 8 of it s internal register values 4 bytes per value into it s shared RAM making them accessible to the CPU 2 The 32 bytes of data make up the 8 CTRIO register values They are arranged as follows Bytes 0 3 Cht Fn1 Bytes 4 7 Cht Fn2 Bytes 8 11 Ch2 Fn1 Bytes 12 15 Ch2 Fn2 Bytes 16 19 Output 0 Bytes 20 23 Output 1 Bytes 24 27 Output 2 Bytes 28 31 Output 3 Use the PLC s WT instruction to write the 2 byte command code 01 Read All Registers to the CTRIO at offset 80 hex Make sure the parameters you re using are correct SET Process Command Command C
77. PO CART 8 e rati Captum T x7 99 me jj T1H CTRIO Module in System DirecfLOGIC Addressing Mode 585 985 Addressing Mode 4st Input V400 V437 32 Words 33001 33033 Output V2000 V2037 32 Words 43001 43033 on d Input V440 V477 32 Words 33034 33065 Output V2040 V2077 32 Words 43034 43065 gni Input V500 V537 32 Words 33066 33097 Output V2100 V2137 32 Words 43066 43097 qth Input V540 V557 32 Words 33098 33129 Output V2140 V2177 32 Words 43098 43129 sth Input V600 V637 32 Words 33130 33161 Output V2200 V2237 32 Words 43130 43161 gth Input V640 V677 32 Words 33162 33193 Output V2240 V2277 32 Words 43162 43193 ath Input V700 V737 32 Words 33194 33225 Output V2300 V2377 32 Words 43194 43225 gth Input V740 V777 32 Words 33226 33257 Output V2340 V2377 32 Words 43226 43257 Counter I O User Manual l 6 13 Chapter 6 Program Control Printing a Memory Map Report You can print an I O Memory Map Report from the I O Map dialog or save as a txt file Click on the Report button located near the bottom of the I O Map dialog to display the Memory Map Report dialog The addresses listed in the Memory Map Report are a combination of the Input Functions Output Functions and Systems Functions addresses shown in the I O Map Report Memory Map Report xj Ch1 Fn1 Quad Counter V2000 2001 Current Count 2020 1 At Reset V
78. RIO You can use the H4 CTRIO module in DirectLogic 405 PLC systems D4 450 only PC based control strategies using the H4 EBC interface module Hx ERM networks using the H4 EBC interface module Support Systems for the TIH CTRIO You can use the TIH CTRIO module in e PC based control strategies using the TI H EBC interface module Profibus systems using the T1H PBC slave interface module e Hx ERM networks using the T1H EBC interface module Modbus systems using the TIK MODBUS slave interface module e DeviceNet systems using the TIK DEVNETS slave interface module 1 4 l Counter I O User Manual Chapter 1 Introduction SS CTRIO Specifications Module Type General Intelligent Modules Per Base Limited only by power consumption 1 0 Points Used None I O map directly in PLC V memory or PC control access Field Wiring Connector Standard removable terminal block Internal Power Consumption 400mA Max at 5V from Base Power Supply H2 H4 T1H CTRIO 250mA at 5V from Base Power Supply HO CTRIO All 1 0 in ON State at Max Voltage Current Operating Environment 32 F to 140 F 0 C to 60 C Humidity non condensing 5 to 95 Manufacturer Host Automation Products LLC Isolation Inputs H2 H4 T1H CTRIO 2500V 1 0 to Logic 1000V among Input Channels and All Outputs CTRIO Input Specifications 8 pts sink source 100K Hz Max Inputs HO CTRIO 4 pts sink source 100K Hz
79. S Upgrades Blinking OFF Program Mode OFF Blinking Module Self diagnostic Failure OFF ON Module Error Due to Watchdog Timeout OFF OFF No Power to Module H2 CTRIO LED Diagnostic Definitions 1A 2A Blinking 7 times per second Input is Configured as Counter and is Changing Following State of Input Input is not Configured as Counter 0 3 Follow actual output state ON output is passing current 1 8 Counter I O User Manual Chapter 1 Introduction fs H4 4 CTRIO LED Indicators H4 CTRIO LED Descriptions OK Module OK ER User Program Error 1A 1D COUNTER 1 0 K ER TB Ch1A Ch1D Input Status 2A 2D Ch2A Ch2D Input Status Chl F1 F2 Ch1 Resource State 20 YS Ch2 F1 F2 H4 CTRIO Ch2 Resource State YO Y3 OK Output Status H4 CTRIO LED Diagnostic Definitions Description ER ON OFF All is well RUN Mode Blinking Blinking Boot Mode Used for Field OS Upgrades Blinking OFF Program Mode OFF Blinking Module Self diagnostic Failure OFF ON Module Error Due to Watchdog Timeout OFF OFF No Power to Module 1A ID User Terminal Block is not Properly Installed H4 CTRIO LED Diagnostic Definition Follow actual input state Ch1 2A 2D Follow actual input state Ch2 Ch1 F1 blinks when Channel 1 Function 1 is co
80. The module supports four output functions Raw Pulse Step Direction Pulse CW CCW e Discrete Ch 1 2 Fn 1 2 Each function uses one or two output terminals for making connections to field devices plus a common Combinations of the listed functions are possible CTRIO Workbench disallows any unsupported configurations CTRIO Memory Usage Pulse Profiles and Preset Tables CTRIO Workbench can create a maximum of 255 predefined Pulse Profiles The total number of Pulse Profiles available is 255 minus the number of predefined Preset Tables Pulse Profiles and Preset Tables are saved as File 1 through File 255 The module has 256 Total Blocks of memory allocated for Pulse Profiles and Preset Tables usage The number of memory blocks used varies between Pulse Profiles and Preset Tables Pulse Profile Tables x Pulse Profiles File 2 Trapezoid 1 File 3 Dynamic Position File 4 5 Curve File 5 Symmetric S Curve File 6 Drill Home Search m Delete Add Exit Contig Information Total Blocks 256 120 Map Free Blocks 248 Preset Tables Config Status Pulse Profiles Counter I O User Manual 5 3 Chapter 5 Configuring the CTRIO Outputs Raw Output The CTRIO module supports Raw output mode This mode allows the CPU controller program to have direct access to the ne module s output points Each out
81. acc Er Rex Ros ewe 8 4 Dynamic Velocity Profile c ou0 8 63 wink eee et oe boe nans 8 5 Velocity WIGdE 4 4524 bees Kee as RUE enikan OR Cg ck Vo wd RE 8 6 R n to Position Mode occa e etr eae p o hora a Sos 9 barns 8 7 Dynamic Positioning Profile is niece e ex dem RR Rea 8 8 System Functions Examples Overview cue coed one ER Rees 8 9 Simulating Retentive Counter uu a cac yc ORCI n e CR 8 10 Reading CTRIO Internal Registers xu dee doe ctt roo eh cas 8 11 Chapter 8 DirectLOGIC Logic Programming Examples Programming Examples Overview The programming examples on the following pages are provided as is without a guarantee of any kind This Chapter is provided by our technical support group to assist others We do not guarantee the examples are suitable for a particular application nor do we assume any responsibility for them in your application Chapter 6 Program Control contains flowcharts that provide detailed steps needed to execute a pulse profile or System Functions command The DirectLOGIC programming examples provided on the following pages are simple examples that are intended to assist you in the basics of loading and running various output pulse profiles The examples are complete enough to load a profile process the command and load the Parameter registers necessary to execute the profile Two System Functions examples are also provided Load and Run a Pulse Profile example You will need to have a Trapezoi
82. ailable about each of the output functions in chapter 5 Counter I O User Manual 1 3 Chapter 1 Introduction a Typical Counter Applications High speed cut to length operations using encoder input Pick and place or indexing functions controlling a stepper drive Dynamic registration for web material control Accurate frequency counting for speed control with onboard scaling positioning e g flying punch PLS programmable limit switch functions for packaging gluing or labeling stepper motor drive control valve control rate monitoring for speed and or flow Support Systems for the CTRIO Modules The CTRIO modules are compatible with several CPU slot interfaces Consideration must be given to the firmware versions of the CPU slot interfaces to assure their compatibility with the CTRIO See Chapter 2 for CPU CTRIO compatibility listings Multiple CTRIO modules can reside in the same base provided that the backplane power budget is adequate Support Systems for the HO CTRIO You can use the HO CTRIO module in DirectLogic 05 06 PLC systems Support Systems for the H2 CTRIO You can use the H2 CTRIO module in DirectLogic 205 PLC systems D2 240 D2 250 1 or D2 260 e DL205 WinPLC systems H2 WPLCx xx PC based control strategies using the H2 EBC interface module Hx ERM networks using the H2 EBC interface module Profibus systems using the H2 PBC slave interface module Support Systems for the H4 CT
83. al 6 1 1 Chapter 6 Program Control i Creating an offline file for TIH CTRIO with TIK DEVNETS The CTRIO module I O memory is accessed by the DeviceNet master using Intelligent I O Input Object and Intelligent I O Output Object commands The Input and Output Objects consist of a unique Class Instance and Attribute Each CTRIO module consumes 64 bytes of input registers and 64 bytes of output registers Instance refers to the CTRIOS position with respect to the TIK DEVNETS controller and other CTRIO modules in the system The first CTRIO module from the controller would be Instance 1 The second CTRIO module from the controller would be Instance 2 and so on Intelligent I O Input Object Class 109 Instance Attribute Instance Attribute Address Service 00 01 02 03 62 63 Common Service Service Code Common Service OEh Get_Attribute_Single Intelligent I O Input Object Class 110 Instance Attribute Attribute Address Service 00 01 02 03 62 63 Common Service Service Code Common Service 10h Set_Attribute_Single 6 12 Counter I O User Manual Chapter 6 Program Control _ T O Map with a TIK MODBUS Modbus RTU Controller When using the T1IH CTRIO module with a TIK MODBUS controller configured for DirectLOGIC addressing mode enter the Starting V memory address
84. al 8 5 Chapter 8 DirectLOGIC Logic Programming Examples Velocity Mode The following example program loads and executes a Velocity Mode pulse profile For Parameter 3 a specific number of pulse output counts can be specified or if set to FHE Hex the pulse output will remain ON at the specified Target Velocity until the output is disabled DirectSOFT 32 First Scan SPO Load Velocity 1 m Mode 0x20 Hex Command Code Register Initialize Settings co LD Target Velocity 2 M v3000 Decimal This rung loads Target f Veloci but Cycle and OUT yami Parameter 1 pulse zur is the Run Frequency arameter registers UD E 0 specifies 50 duty cycle Hex OUT Parameter 2 Moone Duty Cycle LDD Kffffffff Hex specifies unlimited pulse a count use decimal value otherwise OUTD Parameter 3 V2030 Target Pulse Count B2056 7 SET Process Command C1 Initialize Settings SET Complete Set Direction C2 B2056 4 3 H pLM OUT Direction Initialize Settings Command Command Complete Complete Error C1 B2022 7 B2022 6 B2056 7 Thi its for th ME RST Process Command Command Complete e B2056 0 bit with no Command SET Enable Output Re Ou Enabling Initialize Settings 5 yr RST ee eer gt This rung stops the pulse Complete output by disabling the B2056 0 Enable Output bit RST Enable Output 6 END 8 6 l Counter I O User Manual Chap
85. alue V2054 1 Reset Edge Timer 2004 2005 Previous Time V 2006 2007 Timer V2020 8 Captured Start dialog It is very convenient to have a printed list of the CPU controller I O memory used V2020 8 Capture Complete V2054 8 Enable Capture by the CTRIO module when attempting to write the control program Pulse Step 2022 0 Output Enabled 2022 1 Position Loaded Exporting to DirectSOFT You can export a csv file containing addressing and nicknames used in the I O Map dialog Click on the Export button located near the bottom of the I O Map dialog to display the Export to DirectSOFT dialog shown below on the left The csv file shown below on right contains a combination of the Input Functions Output Functions and Systems Functions addressing and nicknames shown in the I O Map dialog This file can imported into your DirectSOFT ladder logic program DirectSOFT32 File Import Element Documentation If you have more than one CTRIO module in a system and intend to create a csv file for more than one module use the Add Prefix or Add Suffix option to distinguish one modules nicknames from the others For example add add prefix or suffix S1 to identify the CTRIO module s nicknames in slot 1 Export to DirectSOFT xj p Export Filename 1 CTRIO CSV r Pretix Sutfix 3S le dt Mem pot Kumar ok Qu Window Hb Aoc Os Gen LRA OP rend aes B 0 70 EZ sx 4S Re
86. amel mpa Data CTO Corot inora Data TRO Conte SX fron Tee pp ac s Roe Sze BICIO Caen St SIEN Cactus Complete Vane 10137 fied Gu Dunt Data Core CTRD Orap Data oris CIFRO Output Data Corse s CTFOO Oan VAGETO Y EQ Rer VERTU GCZON Enable Captum ox e nem tem 6 8 Counter I O User Manual Chapter 6 Program Control I O Map with DirectLogic PLC with CTRIO in ERM EBC Network When using the CTRIO module with a DirectLogic PLC with the CTRIO module in an ERM EBC network first configure the ERM network using the ERM Workbench utility Then from ERM Workbench enter the CTRIOS starting input and output V Map addresses into the CTRIO Workbench s I O Map starting V memory location for the bt inputs and outputs tt Note If there is an 8 pt discrete 1 0 module preceeding the CTRIO module in the EBC base enter the the appropriate starting V memory bit I O address in CTRIO Workbench with a V40xxx 8 address as shown in 1 0 Map example below to the right This corrects the word offset created by the 8 pt discrete I O module Inthe example below to the left note that V40416 Hi 8 15 is the starting ERM Workbench CTRIO input V Map location due to the 8 pt discrete input module preceeding the CTRIO module Ll Le tea ent shaor E A Dem Y 3 4 7 tarom 2 E Ree A16 A04 7 Rage 915 OME 15 V Functions Out Functions Spem Functions D
87. ample uses the Write to Intelligent WT instruction to write the current count stored in the PLC s retentive memory to the CTRIO s current count register on a power cycle or a RUN STOP RUN PLC mode change No permissive bits are required to be turned on in this example Reading CTRIO Internal Registers example This Systems Functions example uses the Write to Intelligent Module WT and Read from Itelligent Module RD instructions to read all of the CTRIOS internal registers every 900ms You must turn CO on to initialize the settings to perform the Read routine 8 2 Counter I O User Manual Chapter 8 DirectLogic Programming Examples Load and Run a Pulse Profile The following example program loads and executes a Pulse Profile that was created using CTRIO Workbench Pulse Profiles dialog This example can be used for Trapezoid S Curve Symmetrical S Curve and Home Search profiles Home Search requires that CTRIO inputs C and or D are configured for Limit Out 0 and or Limit Out 2 The Pulse Profile number is stored in V3000 for this example Turning on CO will load and run the pulse profile DirectSOFT 32 First Scan SPO Load Table Command 0x10 Hex Command Code Register Initialize Settings co LD Table File Number 2 T V3000 Decimal This rung loads the Pulse Profile Table number from V3000 into Parameter 1 OUT Parameter 1 register V2041 Profile File g Number B2056 7 SET
88. apter 4 Configuring the CTRIO Inputs a MMMMImMmmmmsmsoso Counter Function The CTRIO module supports up or down counting using single ended encoders or other single ended pulse sources as inputs Encoders proximity sensors etc can be connected to input A and or input B a n on either channel or both channels The C and D inputs o g are available to modify the A and B inputs The C and D O q inputs can be used for Reset Inhibit or Capture These Do functions are explained later in this chapter The CTRIO 2 e discrete output s can be assigned to the Counter function ac D using the Preset Tables dialog Refer to Creating and Using D e the Output Tables section in Chapter 5 for details D p To insure proper operation the field device wiring and the e e configuration must be compatible For wiring information see Q a Chapter 2 e xd e The modules four input terminals are represented by the A B C and D boxes on the left side of this dialog If you are wiring your counter input to terminal 1A you will want to select the Channel 1 tab near the top of this window and click Counter in box A At this point you have four decisions to make regarding your input at 1A 1 Select count up or count down A button in the Function 1 box toggles between Up and Down counting Click the button labeled Up or Down to see the change to the opposite count
89. arameters you re using are correct ThinknDo Write to CTRIO The Destination Register values are as follows 0 Cht Fn1 1 Ch1 Fn2 Use ThinknDo s Call Block 2 Ch2 Fn1 to write the 2 byte 3 Ch2 Fn2 command code 04 Write One Register the 2 byte 4 Ouput 0 destination register value 5 Ouput 1 and the 4 byte value to the 6 Ouput 2 CTRIO s shared RAM at 7 Ouput 3 Address 80 Make sure the parameters you re using are correct SET Process Command Is Command Complete ON Counter I O User Manual 6 5 1 UsiNc Monitor 1 O In This Chapter Using the Monitor I O Dialog isch OR RR es 7 2 Monitor I O Error Codes iuda sace dora eh ee Oe e a e t ds 7 7 Chapter 7 Using Monitor I O Using the Monitor I O Dialog using Monitor I O before attempting to control the module from your controller program Monitor 1 0 is extremely useful for debugging and the commissioning of a new system Monitor 1 0 allows you to confirm proper configuration of the module as well as field wiring and external device operation It is highly recommended to simulate your CTRIO Counter Timer or Pulse Output Profile etc application The Monitor I O dialog is accessible from the main Workbench dialog when the module is in Run Mode Monitor 1 0 On the main Workbench dialog click the button labeled Monitor I O After clicking on the Monitor I O button the dia
90. arget location After the GoTo Position is acknowledged the program can load the next position into the DWord Parameter 3 When Pulses Active Status goes to 0 then setting the GoTo Position control bit will again start the output toward the new position The CTRIO moves to the new position relative to its previous position as long as the Enable Output control bit remains set Clearing the Enable Output bit will disable output pulsing and reset the current position to 0 See Chapter 8 for a DirectLOGIC programming example that executes a Dynamic Positioning pulse profile using the bit D word addressing in the table on page 6 37 The sign of the value in the Target Position register Parameter 3 determines the Discos direction of the pulse train output In the co T DirectLOGIC programming example to E Mie the right BCD 5000 is converted to BN decimal 5000 when CO is turned ON You could load LD a V memory location instead of using a constant as shown in the For a D2 250 u ADDD se H K1 example ABUB Kk Counter I O User Manual 6 3 5 Chapter 6 Program Control Dynamic Positioning Flowchart The flowchart below provides the logical sequence necessary to execute a Dynamic Positioning pulse profile Load 10 into Command Code Verify that the The direction will be Hex CTRIO is determined automatically Bio NI Load Position configured by the CTRIO Value into correct
91. art on the following page provides the logical sequence necessary to execute a Run to Limit pulse profile See Chapter 8 for a DirectLOGIC programming example that executes a Run to Limit Mode pulse profile using the bit D word addressing in the table on page 6 44 Parameter 2 Word Parameter 2 defines three elements of the Run to Limit routine Bits 13 and 12 determine which edge s to terminate Output Pulses and Bits 9 and 8 determine which CTRIO Input terminal to use for the limit The low byte specifies the duty cycle m e EU Rising Edge Ch1 C 00 00 0000 Falling Edge Chi C 01 00 1000 Both Edge Ch1 C 10 00 2000 Rising Edge Ch1 D 00 01 0100 Falling Edge Ch1 D 01 01 1100 Both Edge Ch1 D 10 01 2100 Rising Edge Ch2 C 00 10 0200 Falling Edge Ch2 C 01 10 1200 Both Edge Ch2 C 10 10 2200 Rising Edge Ch2 D 00 11 0300 Falling Edge Ch2 D 01 11 1300 Both Edge Ch2 D 10 11 2300 Edge s Bits 15 12 CTRIO Input Bits 11 8 Rising 0000 OHex Chic 0000 OHex Falling 0001 1Hex Ch1D 0001 1Hex Both 0010 2Hex Ch2C 0010 2Hex Ch2D 0011 3Hex 6 42 Counter I O User Manual Chapter 6 Program Control Run to Limit Mode Flowchart The flowchart below provides the logical sequence necessary to execute a Run to Limit Mode pulse profile Load 21 into Command Code Hex Load Frequency into Parameter 1 Decimal into Parameter 2 Hex SET Make sure Pr
92. but you must consult you step amplifier documentation to ensure that this method is applicable 2 3 2 Counter I O User Manual Chapter 2 Installation and Field Wiring Solid State Input Device Wiring to HO H2 H4 T1H CTRIO NPN Field Device This drawing illustrates wiring that is typical for Channel 1 terminals 1A 1B 1C and 1D The same circuitry is also present at the corresponding Channel 2 terminals Sensing Circuit The same circuitry is present at the corresponding Channel 2 terminal PNP Field Device This drawing illustrates wiring that is typical for Channel 1 terminals 1A 1B 1C and 1D The same circuitry is also present at the corresponding Channel 2 terminals 24VDC UN Sensing ae ue The same circuitry is present at the corresponding Channel 2 terminal Counter I O User Manual 2 33 INTRODUCTION TO CTRIO WORKBENCH In This Chapter What is CTRIO Workbench cea qao e d vote eee Rn en 3 2 Getting Started with CTRIO Workbench sese 3 2 Module Modes of Operation deese y Soc ERE ER EO ICE Sae t d 3 5 Chapter 3 Introduction to CTRIO Workbench What is CTRIO Workbench CTRIO Workbench is the software utility you will use to configure the CTRIO module s inputs and outputs Workbench also lets you setup the CTRIO s built in scaling f
93. coder Wiring Example leeeeee eee 2 20 H4 CTRIO TTL Quadrature Encoder Wiring Example 0 000 002 eee eee 2 21 H4 CTRIO TTL Input Wiring Example 20 0 eee eee ee eens 2 22 H4 CTRIO Output Wiring Schematic 0 0 ce eee ee 2 23 H4 CTRIO Stepper Drive Wiring Example 0 0 0 0 eee eee eee 2 24 Installing the TTH CTRIO Module 2 cece eee 2 25 Wiring the TIH CTRIO Module 1 2 2 eee deiere riiai Eien 2 26 T1H CTRIO Quadrature Encoder Wiring Example cece eee eee ee eee 2 28 T1H CTRIO TTL Quadrature Encoder Wiring Example 0 00 00 c ee eee eee 2 29 T1H CTRIO TTL Input Wiring Example 0 0 00 eee ee eee 2 30 T1H CTRIO Output Wiring Schematic 2 31 T1H CTRIO Stepper Drive Wiring Example sleee I 2 32 Solid State Input Device Wiring to HO H2 H4 T1H CTRIO 0 2 ee eee ee ee eee 2 33 Chapter 2 Installation and Field Wiring e Installing the HO CTRIO Module The H0 CTRIO module is compatible with DirectLogic DL05 and DL06 PLCs Consideration must be given to the firmware versions of the PLCs to assure their compatibility with the HO CTRIO see chart below The HO CTRIO module plugs into any option card slot of any DL05 and DL06 PLC For installation instructions refer to the DL05 or DL06 User Manual D0 USER M or D0 06USER M The first time you power up the CTRIO module you should see the OK LED blinking The blinking LED indicates
94. cree on Con m Notice that the module s four input oa terminals are represented by the A B C El creat a ij and D boxes on the left side of this Rede Tia eie sa Rt dialog If you are wiring your input to terminal 1C you will need to select the D e l Channel 1 tab near the top of this dd a window and click Pulse Catch in box C Three selections must be made in Coca conjunction with the Pulse Catch option 1 First a decision must be made whether to look for the rising edge of the pulse or the falling edge of the pulse This is a critical decision Careful attention should be paid to the type of output the field device generates If the signal voltage is normally low but a short duration pulse sends the signal to the ON state you will want to trigger off the rising edge and vice versa 2 The second decision you will need to make is the e minimum pulse width you want to capture Transients below this width will not be recorded Set this value by _ 2 typing the desired value in the Minimum Width In p g field D e 3 The final decision to be made is the length of pulse PD ow the CTRIO module should send in response to the ND D input pulse Make this setting by typing in the desired 6 value in the Pulse Out Width field D D e a Y3 e pst n 20 8 status bit 1 6 Counter I O User Manual Chapter 4 Configuring the CTRIO Inputs Ea Edge
95. ct a Timing function We will step through the dialogs used for each scaling type Substitute appropriate values to set up scaling for your application Scaling Wizard Examples for Counter Functions On the counter Scaling Wizard you can select None gt y gt Scaling type Function Used with Notes Position or Rate No scaling is accomplished if the None lore dM Ho scura moved 1 iti Converts raw counts to engineering Counter Typically used for units of distance button B selected Position units using linear interpolation User Quad counter position size etc scaling is appropriate for e a ea measuring distance position C Rate Converts count rate to engineering Counter Typically used for units of speed flow x units by sampling count normalizing to Quad counter velocity etc Rate is preferred over or size Rate scal i ng 1S desired timebase and scaling to Interval for count frequencies over engineering units 5kHz although it may be used for lower appropriate for velocity RPM Rees we cers nu flow or similar rate based c Conve count ine eenginesing Edge Timer Like Rate neva i ical used for units by measuring pi idth ual Edge Timer units of speed flow velocity etc measurements You may want cowering to E dide Interval Timer Inyal is pei over Hes Gl the t ired tir 2 ing t t i 4 to read the Notes and other earn iris DRM though A may be used as high 10kHe with acceptable accuracy information before
96. d S Curve Symmetrical S Curve or Home Search profile configured using the Configure I O dialog You will need to have the appropriate Pulse Profile Table File Number decimal stored in V3000 for this example You must turn CO on to load and run the pulse profile C2 controls the pulse output direction Dynamic Positioning Profile example You will need to have a Dynamic Positioning profile configured as Table File Number 1 using the Configure I O dialog You will need to have the appropriate Target Pulse Count Position signed decimal stored in V3000 for this example You must turn CO on to initialize the settings Then turn C2 on to Go to Position Dynamic Velocity Profile example You will need to have a Dynamic Velocity profile configured as Table File Number 1 using the Configure I O dialog You will need to have the appropriate Target Velocity signed decimal stored in V3000 for this example You must turn CO on to initialize the settings and enable the output Velocity Mode Run to Limit Mode and Run to Position Mode examples No CTRIO Pulse Profile Tables are necessary to execute these profiles but the Outputs need to be configured for Step Direction or CW CCW using the Configure I O dialog All parameters are stored in V memory as shown in the examples You must turn CO on to initialize the settings and to run the pulse profile C2 controls the pulse output direction Simulating Retentive Counter example This Systems Functions ex
97. d code 02 Write All Registers and the 32 bytes of data to the CTRIO s shared RAM at Address 80 SET Make sure the parameters you re using are correct Process Command Is Command Complete ON 6 50 Counter I O User Manual ThinknDo Write to CTRIO Use ThinknDo s Call Block to write the 2 byte command code 02 Write All Registers and the 8 DWORD values to the CTRIO s shared RAM at Address 80 Make sure the SET parameters you re using are correct Process Command Is Command Complete ON Chapter 6 Program Control EEE Writing to One CTRIO Internal Register Flowcharts The flowcharts below provide the logical sequence necessary to Write to one of the CTRIO s internal registers Writing to a CTRIO internal register is a two step process 1 Transfer the data value from the controller s memory to the CTRIO s shared RAM 2 Ask the CTRIO to transfer this value from its shared RAM to it s internal registers DirectLogic Write to CTRIO The Destination Register values are as follows 0 Ch1 Fn1 1 Ch1 Fn2 Use the PLC s WT instruction 2 Ch2 Fn1 to write the 2 byte command 3 Gn2 Fn code 04 Write One Register 4 Ouput 0 the 2 byte destination register 5 Ouput 1 value and the 4 byte value to 6 Ouput 2 the CTRIO s shared RAM at 7 Ouput 3 offset 80 hex SET Process Command ls Command Error ON Make sure the p
98. d firmware versions can be downloaded from our web site at www automationdirect com Counter I O User Manual 2 25 Chapter 2 Installation and Field Wiring se Wiring the TLH CTRIO Module Apply the labels that come with the 1 0 module to the 1 0 The TIH CTRIO module has two independent input channels each consisting of 4 optically isolated input points pts LA 1D on common 1M and pts 2A 2D on common 2M The inputs can be wired to either sink or source current The module has 4 optically isolated output points pts YO Y3 on isolated commons C0 C3 respectively The outputs must be wired so that positive current flows into Cn terminal and then out of the Yn terminal see the diagram on the following page and the schematic on page 2 31 The module is configured using CTRIO Workbench to accommodate the user s application The function of each input counting timing reset etc and output pulse output discrete output etc is defined in the configuration of the module Refer to Chapters 4 and 5 to determine what input and output configurations are possible Field device wiring must be compatible with the module configuration See the notes below for further details about power source considerations circuit polarities and field devices Also refer to the specifications on pages 1 5 and 1 6 for more information P f
99. d identical starting stoping frequencies The maximum target frequency is specified The target position of output pulses is located in a memory register in the CPU controller Once the position is reached the output is disabled and a new target position can be specified in the memory register Prete Inte tne Mren Freg 40 He MammumFreg NOO He Proin Type a Trpesod decal Rate m uve retical S Curve rr Velocity Hoe Seach Fie Stats File Nurber 1 Todfrer Bedsted 1 Accel Rate The rate at which the Minimum Frequency will to ramp up the Maximum Frequency This sets the deceleration rate as well Minimum Freq The frequency at which the profile will begin Maximum Freq The target frequency to which the Minimum Frequency rises 5 12 Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs Ea Dynamic Velocity Profile The Dynamic Velocity profile is a trapezoidal profile with the direction acceleration and deceleration rates specified The target velocity is located in a memory register in the CPU controller Once the CPU controller initiates the profile output pulses will be generated at the target velocity until the CPU controller disables the output pulses Cocker AccelRate 11000 pay Crchweee Decet Rate 11 pss Counter clockwme Accel Rate 11000 pay Courterclochwive Dace Rate 1000 pu Clockwise Accel Rate The clockwise rate at which the output will ramp up from Opss to the ta
100. de V2040 V2040 Set to 22 Hex Pulse at velocity until Function Input Limit Parameter 1 V2041 V2041 Set initial run frequency 20Hz 25000Hz decimal Parameter 2 V2042 V2042 Bits 15 12 Comparison Bits 11 8 Input Function to use Low Byte Duty cycle 1 99 can leave 0 for 5096 Hex Parameter 3 V2031 V2030 V2081 V2030 Specified position for Input Function DWord to compare against decimal Set Direction V2056 4 C224 Set ON or OFF for Direction of Rotation Process Command V2056 7 C227 Turn ON Command Complete status bit is returned see step 4 Command Status V2022 7 When ON command has been accepted clear Process Command bit step 3 Command Error V2022 6 ON if Command or Parameters are invalid Enable Output V2056 0 Turn ON to start pulses Output Active Status V2022 4 ON while pulsing OFF when position is reached Suspend Output V2056 2 Turn ON to pause output pulses without resetting pulse count Output Suspended V2022 2 ON when out pulse train has been suspended Counter I O User Manual l 6 47 Chapter 6 Program Control System Functions se System Functions Commands are primarily used to read from and write to the CTRIO s internal registers The flowcharts on the following pages provide DirectLogic and ThinknDo users the logical sequence necessary to read
101. default 50 otherwise it can be set in 196 increments by writing this value from 1 to 99 decimal After this command is processed the Run Frequency and Duty Cycle fields can be adjusted by direct access In order to change directions from Pulse Output in Velocity mode the Enable Output bit must first be cleared which stops the Pulse Outputs Then after the new direction bit is written the Enable Output bit can be set to resume pulsing The flowchart on the following page provides the logical sequence necessary to execute a Velocity Mode pulse profile See Chapter 8 for a DirectLOGIC programming example that executes a Velocity Mode pulse profile using the bit D word addressing in the table below Velocity Mode control on CTRIO YO amp Y1 Name PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Relay D2 240 PLC Status Inputs Base Addr V2000 Control Relay D2 240 Action Command Code V2040 V2040 Set to 20 Hex Pulse at Velocity Parameter 1 V2041 V2041 Set initial run frequency 20Hz 25000Hz decimal Parameter 2 V2042 V2042 Duty cycle Dd can leave 0 for 50 decimal Parameter 3 V2031 V2030 V2031 V2030 Number of pulses DWord set to FFFF FFFF for no limit Hex Set Direction V2056 4 C224 Set ON or OFF for Direction of Rotation Pr
102. der Wiring Example eese 2 28 T1H CTRIO TTL Quadrature Encoder Field Wiring eese 2 29 TIH CTRIO TTL Input Wiring eeeee RR 2 30 T1H CTRIO Output Wiring Schematic 2 31 T1H CTRIO Stepper Servo Drive Wiring Example eese 2 32 PNP Field Device 4sscccsescoo rr e rh Ry RE ksi k oret hee 2 33 NPN Field Device 2 exque xxm eder eese Re ahah ERRANS 2 33 Solid State Input Device Wiring to HO H2 H4 T1H CTRIO sees 2 33 Chapter 3 Introduction to CTRIO Workbench What is CTRIO Workbench seeeeeee hn 3 2 Installing CTRIO Workbench ose sess 0 0 0 eee eee RII 3 2 Getting Started with CTRIO Workbench 0 0 cece e eee eee eens 3 2 Offline CTRIO Configuration vi 6 ei e vases eas oa he e oe RE ee ORG 3 2 Online CTRIO Configuration llle I 3 3 Successful On line Connection sasssa eeit rrr ce n 3 4 Module Modes of Operation 0 ccc ce hn 3 5 Program Mode Configuring the CTRIO Module sees 3 5 Run Mode Start Processing I O Pulses with the CTRIO Module 3 5 Chapter 4 Configuring the Inputs Using CTRIO Workbench Configure IO Dialog Overview eee hn 4 2 Input Function Selections 2sssssee rg re hh ehh eh sch e hen 4 3 Supported Functions ccc cece eee eee ee Eh rh t es eg aa EEE OE EE E 4 3 Discrete Outputs Pre Assigned to Input Functions lleleeeeee 4 3 ei eid nai 4 4 Quad Counter
103. e output Raw E ion i Pulse Step Di Once the output selection is made a new button 0 Preset Set ira appears on the Configure IO dialog The button is Discrete on Ch Fn labeled as shown to the right The leading numeral represents the number of the output terminal Clicking on the Preset button causes the Default Output Settings dialog to pop up Default settings are loaded on power up Raw Discrete on Ch1 Fnl On the Output Settings dialog select Use Single Preset We will discuss Preset Tables later in this ae NN chapter Now click OK to arrive at the Edit Preset Entry dialog C None ORIS Six output functions are available as shown in the figure vom een below Set the preset value in engineering units if the signal has been scaled Set the preset value in raw count if the signal has not been scaled We discuss scaling in EdtPreset chapter 4 Pulse ON and Pulse OFF require a Pulse Time ae setting The Pulse Time is set in msec 1 000 sec 1 msec Unscaled teen Edit Preset Entry X Output Function Set Preset C Reset T feet Output Function Definitions C Pulse On Set Writes output ON maintained a Pulse Off I Time Reset Writes output above OFF Toggle M TE Pulse On Writes output ON for specified time C Reset Count Pulse Off Writes output OFF for specified time Toggle Changes state of output Cancel Reset Count Resets the count to Preset Value
104. e Go lo Q c B 10k Ts HFE gt 100 01W 10 OM 5VDC C ay 9 30VDC Il Counter I O User Manual 2 2 1 Chapter 2 Installation and Field Wiring H4 CTRIO TTL Input Wiring e m General pups Transistor T qp Pe E TTL Device 2B B 10K e 1C HFE 100 2C 0 1W 10 amp 1D i i 2D D 1M E ym 2M NC NC E D amp co amp d e TTL Device Y2 HFE gt C1 C3 amp D pu Yi Y3 D Al amp TTL Device B 10K HFE gt 100 0 1W E 10 cC TTL Device B 10K HFE gt 100 0 1W 10 om 2 22 Counter I O User Manual or the low side of a DC load Chapter 2 Installation and Field Wiring nS H4 CTRIO Output Wiring Schematic The CTRIO outputs are individually isolated DC switches that can be used to break the high Ce Cn where n 0 1 2 3 CTRIO Output 5 to 36VDC O Yn Load Load 5 to 36VDC Cn where n 0 1 2 3 CTRIO Output Yn Counter I O User Manual 2 23 Chapter 2 Installation and Field Wiring H4 CTRIO Stepper Servo Drive Wiring Example N gt gt ho UJ N O 6006990060 2M NE D NC Step Amplifier Step Amplifier CO 5 36VDC 5 36V
105. e Input Data CTRIO gt Controller addresses and Output Data Controller gt CTRIO addresses based on the Map Display Mode and the starting I O addresses specified The memory map addresses displayed correspond to the offset addresses shown in the tables on the previous pages Click on the System Functions tab to display the System Functions addressing The command bits are used when reading from and writing to the CTRIO s internal registers The other bits can be used to monitor the status of each individual I O point on the module I O Map with DirectLogic PLC 2 ranges mode When using the CTRIO module with a DirectLogic PLC enter the starting V memory location for the inputs and outputs in the appropriate fields at the top of the IO Map dialog In the I O Map dialog shown below note that the Input Output and Systems Functions addresses shown are in word and bit of word formats Thus word and bit of word addressing will need to be used in the ladder logic program to address the CTRIO s control and status words bits A xi Map Delay Mode Irene Mao Enable Wwe in PLC iV Dupa Mae Enable fesd kom PLC V TLC MaopedAdsenerM range Starting V addens for inputs vao Surg V ddes ha oupa 2030 fang Poons Angs Faa Range fang tre Functone Gaga Functions Syston Functions OANA nt Quid Courter ChUfra Edge Tie inpdOsa CIHIDoConkole inpurData CThiOoConbole VeutDalalCTiOoConole Irout Data CTRIDo Controler
106. e with different definitions for each byte high byte and low byte For example to enter the Pulse Output to Limit command set the high byte of the Word Parameter 2 to the edge you wish to terminate the output pulses see definition following and set the low byte to the desired duty cycle In order to process a command first the program must load the Command Code and required DWord Word and bit parameters Then the program should drive the Process Command bit to a 1 and look for the CTRIO to acknowledge the command with the Command Complete bit Finally the program should remove the Process Command bit and set the Enable Output bit when appropriate If the Command Error bit is received the CTRIO was unable to process the command due to an illegal value in either the Command Code or parameter files DWord and Word values for pulse outputs are unsigned integers 6 28 Counter I O User Manual Chapter 6 Program Control nn RRR T Status Bits Example using V2000 as base input address For Output Channel 1 Status bits received from CTRIO to CPU PLC Example 1 PLC Example 2 Name Bit of Word see note 2 Control Relay see note 1 Value D2 250 1 260 D4 450 D2 240 Output Enabled V2022 0 C120 Position Loaded V2022 1 C121 N when Enable Output is ON sed for Dynamic Positioning Output Active V2022 4 C124 Output Stalled V2022 5 C125 N when Output is Pulsing 0 U Output Suspended V2022 2 C122 ON when Output pu
107. ed to either sink or source current 2A F JA F The module has 4 optically isolated output points pts Y0 Y3 on ao oe e isolated commons C0 C3 respectively The outputs must be wired 2D vs 1D vi so that positive current flows into Cn terminal and then out of the H4 CTRIO Yn terminal see the diagram below and the schematic on page 2 23 eur 9 30VDC The module is configured using CTRIO Workbench to 5 12mA C D accommodate the user s application The function of each input E e counting timing reset etc and output pulse output discrete pereon aa FENI output etc is defined in the configuration of the module M amp D Refer to Chapters 4 and 18 5 to determine what M u GLA input and output e i J amp configurations are 2 IE G NC OR i P THF Co MN lt L Beo possible m p D oS Field device wiring must be Hs 26 gp e t HET D compatible with the module m eo 2E D configuration L 3 L 69 aM a e See the notes below for further details about ele D co power source C2 a cols Eee cre ES considerations circuit c wee ols ity YO Ll Pp polarities and field Y2 G E BR Y2 A Te Ct ci etn QE Grp devices Also refer to the specifications on M pages 1 5 and 1 6 for zd more information
108. elocity pulse profile Load 10 into Command Code Verify that the Hex CTRIO is configured correctly Load Pulse Profile Number into Parameter 1 Decimal Is Table Number Correct SET Process Command Verify that you ve entered the correct table number Is Command Complete ON RESET Process Command RESET Process Command The CTRIO is continually reading the Velocity register in the CPU When a new value appears in this register the CTRIO will use the SET profile settings to move to Output Enable the new velocity The direction is determined automatically from the sign of the velocity value Positive values will produce CW pulses Load Velocity value into Negative values will produce egative values will pi Parameter 3 CCW pulses You can change the velocity value as often as you need You can also suspend the pulse output at any time with the Suspend Output bit New Velocity Value RESET Output Enable Counter I O User Manual 6 39 Chapter 6 Program Control Velocity Mode Velocity Mode controls the pulse outputs directly from the CPU controller program No CTRIO Workbench Pulse Profile is required for this mode Velocity Mode command Command 0020 Hex BCD allows a specified number of pulse output counts or the number of Pulses can be set to FFFFFFFF in Hex for unlimited pulse counts Leaving the Duty Cycle set to 0 achieves the
109. en click on the Config I O button to arrive at a dialog shown to the right Notice that the window has a tab for each input Channel r Function 2 9 f Edge Timer ulse Step Dir Un Ra n Pulse CW CCW ul You don t have to be in PROGRAM mode to enter the Configure 1 0 dialog however you must be in PROGRAM mode to save the Edge Timer Dual Edge Timer configuration to the CTRIO module _ Cos The input options are listed by function Four boxes labeled A B C HO CTRIO Configure I O Dialog and D correspond to the input terminals on the face of the module 1A 1D or Sica LE Disk 2A 2D A D for the HO CTRIO T meem The Output functions are listed as 0 1 2 and 3 These numbers correspond to the markings beside the modules output terminals YO Y3 YO Y1 for the H0 CTRIO For example you might click on Counter in the A box then OK to return to the main Workbench window Once you arrive back at the main window you must click Write Module Dual edge Tiner to save your selection to the module The module will need to be in Program Mode to perform the Write Module ee operation If you do not perform the Write Module operation or a Write File operation your configuration will be lost upon quitting Workbench This applies to all changes to the module configuration r Function 2 SI sl
110. ency and pulse train duty cycle A CTRIO module input C or D must be configured as a Limit input When the Limit is reached the pulse output is disabled Run to Position Mode User specifies target frequency pulse train duty cycle and target position The current position is obtained from the specified Input Function i e Quadrature counter When the current position reaches the specified target position the pulse output is disabled The comparing of the current and target position can be based on greater than or equal to or less than values 5 16 Counter I O User Manual PROGRAM CONTROL In This Chapter Input Memory Map for Data Transfers from CTRIO to CPU 6 2 Output Memory Map for Data Transfers from CPU to CTRIO 6 4 VO Map Dialog cv eesti dtr e E Rare doute dut eee angen es 6 7 Addressing Conventions 4 66044 REOR o ace Soak e KRESS 6 15 Input Function Status Control Bits and Parameters 6 16 INDUEFUNCUIONS PPP PCI 6 19 Runtime Changes to CTRIO Configured Preset Tables 6 23 Pulse Output Status Control Bits and Command Codes 6 27 Pulse Output Profiles 1 ucibus depo aede oe ee ba ee Dex 6 31 Syst m US o TP Rm 6 48 Chapter 6 Program Control OE Input Memory Map for Data Transfers from CTRIO to CPU The following table shows which memory locations are used for memory transfers from the CTRIO module to the CPU The starting memory location is defined by the u
111. entement pr alable crit de la soci t Automationdirect com M Incorporated Automationdirect com conserve les droits exclusifs l gard de tous les renseignements contenus dans le pr sent document MANUAL REVISIONS Please include the Manual Number and the Manual Issue both shown below when communicating with Technical Support regarding this publication Manual Number HX CTRIO M Issue Second Edition Rev B Issue Date 10 03 Publication History Issue Description of Changes First Edition Original Rev A Corrections Rev B Corrections Second Edition Added T1H CTRIO and H4 CTRIO Updated for CTRIO Workbench version 2 Rev A Added HO CTRIO and flowcharts Rev B Corrections TABLE OF CONTENTS Chapter 1 Introduction to the CTRIO Modules CTRIO Version 2 and Workbench Version 2 New Features eee 1 2 Expanded I O Map Implications ice RII 1 2 Using CTRIO Workbench Version 1 llleeeleeeee rh 1 2 CTRIO Module Overview 0 ccc cece cece RR s 1 3 CTRIO Workbench siss zixes uer eG 46 6 66465 6h bdo doe RS od Ge WEE RE 1 3 CTRIO EUDCEOLS sek es pure RR VENE E aeta alta s a doe SUR US See oA 1 3 Typical Counter Applications sss rsss RII 1 4 Support Systems for the CTRIO Modules 0 cece eee eee eA 1 4 US enne uM 1 4 aen uem P TET 1 4 HASCIRIO 69 oL 6445 8 oeancededatade steaks bonnet eee SEE LE 1 4 TAEEGTRIO S enel cuoc estes
112. er Manual l 6 19 Chapter 6 Program Control EY Edge Timer and Dual Edge Timer Parameters 1 and 2 are explained on page 6 16 and will be mapped to V2000 V2003 in this example Standard Timers When the Enable Timer Capture bit is ON and the configured input edge occurs the CTRIO will begin timing The Timer Capture Starting bit will be ON while the timing is in progress and will turn OFF when the next configured input edge occurs and the Timer Capture Complete bit turns ON The program will need to turn off the Enable Timer Capture bit and confirm the Timer Capture Starting and Timer Capture Complete bits reset before attempting the next time capture cycle Turning OFF the Enable Timer Capture bit resets the timers register values to zero Free Run Timers If the Free Run Timer option was configured the Enable Timer Capture bit is not available When the configured input edge occurs the CTRIO will begin timing The Timer Capture Starting bit will be ON while the timing is in progress and will turn OFF when the next configured input edge occurs When this edge occurs the Timer in progress time register resets to zero The previous time register will always retain the most recent captured time value PLC Control PLCStatus DU RES foie pase Outputs Base Inputs Base GS Addr V2030 Addr V2000 Cont oI Ra Cont does ESSI RU iR m iR m ontrol Relay Control Relay Bit of Word Bit of Word D2 240 D2 240 Parameter 1 V20
113. ering units Enter an Engineering Units up to 4 characters appropriate value for Interval Scaling for DutputFomat C Floating Point example RPM fps flow etc Seven data types are paseo aes e available including BCD to make values more B ponis a ee eee Integer x100 2 implied decimal places easily used by DirectLOGIC PLCs C BED rounded C BCD x10 1 implied decimal place C BCD x100 2 implied decimal places Cancel lt Back Scaling Wizard Interval Settings x Click Next to open the Interval Settings Unit Definition Data Smoothing dialog It is here that you enter the oui oo 0mnomnnm counts per unit of time and the time iod as m base A scale offset is also provided to Scale Offset 0 adjust the result by a constant amount Interval Scaling Deiner s os Unit Time B Enter a pulse interval i This window contains a calculator to E ee p eee pape ut scaling double check the meaning of your Rate configuration Setti E luei he R seconds N ettings Enter a value into the Raw _ Pei Puse Tim H u Value field to see the equivalent value in C hours Scaled Value engineering units Data Smoothing allows rolling averages Cancel lt Back Finish to be taken to calculate a value ES E mm Min 1 sample max 25 samples in the rolling average B 14 l Counter I O User Manual CONFIGURING THE OUTPUTS APTER UsiNc CTRIO WORKBENCH In This Chapter Configure IO Dal
114. essary to execute a Run to Position Mode pulse profile Load 22 into Command Code Hex Load Frequency into Parameter 1 Decimal Load Function Duty Cycle into Parameter 2 Hex Load Position value into Parameter 3 Decimal SET Process Command ON Is Command Complete RESET Process Command Make sure the Input is configured as a Counter RESET Process Command 6 46 Counter I O User Manual At this point the CTRIO will begin outputting pulses You can change the Frequency and or the Duty Cycle as often as you need you can even change them while the output is active The Output Active bit will be ON until the CTRIO sends out all of the pulses you configured You can also suspend the pulse output at any time with the Suspend Output bit Select Direction SET Output Enable Load new parameter values New Frequency or Duty Cycle Is Output Active ON RESET Output Enable Change Direction RESET Output Enable nnn RRR Chapter 6 Program Control Run at Velocity on CTRIO until Input Function Value Position Name PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Relay D2 240 PLC Status Inputs Base Addr V2000 Control Relay D2 240 Action Command Co
115. f clockwise acceleration and deceleration and counter clockwise acceleration and deceleration come from the CTRIO Workbench Profile The target velocity is stored in a register in the CPU controller The program needs to prepare the Load Table command by selecting Command Code 0010 Hex BCD set Word Parameter 1 to the File number of the profile example File 3 Dynamic Velocity 1 and set Word Parameter 3 to the desired target velocity Then the program can set the Process Command bit and watch for the Command Complete bit Then the program should clear the Process Command bit Set the Enable Output bit to start the output pulses The velocity can be changed on the fly by entering a different value into the target velocity register The velocity will ramp up down to the new target velocity at the specified accel decel rates Clearing the Enable Output bit will always suspend pulsing Chapter 6 Program Control se See Chapter 8 for a DirectLOGIC programming example that executes a Dynamic Velocity pulse profile using the bit D word addressing in the table below Dynamic Velocity using the CTRIO YO and Y1 Name PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Haley PLC Status Inputs Base Addr V2000 Control Hela Action Command Code V2040 V2040 Set to 10 Load Stored Profile Parameter 1
116. file Not Used Target Position Dynamic Velocity File of stored profile Not Used Target Velocity Home Search File of stored profile 6 4 l Counter I O User Manual Not Used Not Used Chapter 6 Program Control For DirectSOFT32 users the I O Map dialog displays the exact memory locations in use by the CTRIO module Within the I O Map dialog you can print out a report of memory loctions in use Output n Parameter Definitions Parameters are in decimal format unless specified Profiles Completely Controlled by User Program Parameter 1 Contents WORD Parameter 2 Contents WORD Parameter 3 Contents DWORD Velocity Mode Initial Frequency Duty Cycle Number of Pulses Hex Run to Limit Mode Initial Frequency Input Edge Duty Cycle Hex Not Used Run to Position mode Initial Frequency Input Function Control Bit Definitions Input function offsets are listed in the order of Ch1 Fn1 Ch1 Fn2 Ch2 Fn1 Ch2 Fn2 Ch n Fn n Control Bits transfers from CPU to CTRIO Bit Offsets WinPLC EBC PBC DEVNETS MODBUS Input Function Comparison and Duty Cycle Hex Input Function Comparison Value V memory Offsets DirectLOGIC PLCs Enable Count Capture 0 8 16 24 24 0 24 8 25 0 25 8 Enable Timer Capture 0 8 16 24 24 0 24 8 25 0 25 8 Enable Pulse Catch 0 8 16 24 24 0 24 8 25 0 25 8 Reset
117. files The Decel Time and End Frequency are determined by the Accel Time and Start Frequency The Symmetrical S Curve uses less memory than the S Curve profile Edit Pulse Profile o XJ Profile Info Name Peak Freq ft re 1000Hz Profile Type Total Time 10 88 sec Symmetrical S Curve Accel Time Dynamic Positioning 1000 ms Dynamic Velocity Home Search Decel Time 1000 ms File Stats File Number 1 Total Entries 56 Blocks Used 8 Total Pulses 10000 Accel Time 1000 ms Decel tine os StetFreg 40 Hz PosFreg 1000 He eq OH tate Pte Min Freq Change I Min Entry Time fo ms Cancel Total Pulses The total amount of output pulses that will be generated during the Trapezoidal profile Accel Time The amount of time required for the Start Frequency to ramp up the Position Frequency This also represents the deceleration time Start Freq The frequency at which the Trapezoidal profile will begin This also represents the end frequency Pos Freq The target frequency to which the Start Frequency rises Min Freq Change The amount of calculated frequency change that must take place before stepping to the next frequency Min Entry Time The amount of time spent in each step Counter I O User Manual 5 1 1 Chapter 5 Configuring the CTRIO Outputs Cp LLL u Dynamic Positioning Profile The Dynamic Positioning profile is a trapezoidal profile with identical acceleration deceleration rates an
118. fsets WinPLC EBC PBC DEVNETS MODBUS V memory Offsets DirectLOGIC PLCs Count Capture Complete Bit 0 8 16 24 20 0 20 8 21 0 21 8 Timer Capture Start 0 8 16 24 20 0 20 8 21 0 21 8 Timer Capture Complete Timing OR At Reset Value Counting 1 9 17 25 20 1 20 9 21 1 21 9 Timer Timed Out Bit 2 10 18 29 20 2 20 10 21 2 21 10 Pulse Catch Output Pulse State 0 8 16 24 20 0 20 8 21 0 21 8 Pulse Catch Start 1 9 17 25 Input Function Control Bit Definitions Input function offsets are listed in the order of Ch1 Fn1 Chl Fn2 Ch2 Fn1 Ch2 Fn2 Ch n Fn n Control Bits transfers from CPU to CTRIO Bit Offsets WinPLC EBC PBC DEVNETS MODBUS 20 1 20 9 21 1 21 9 V memory Offsets DirectLOGIC PLCs Enable Count Capture 0 8 16 24 24 0 24 8 25 0 25 8 Enable Timer Capture 0 8 16 24 24 0 24 8 25 0 25 8 Enable Pulse Catch 0 8 16 24 24 0 24 8 25 0 25 8 Reset 1 9 17 25 Input Function Status DWord Parameters Input function offsets are listed in the order of Ch1 Fn1 Chl Fn2 Ch2 Fn1 Ch2 Fn2 and 6 16 are in decimal format DWord Status CTRIO to CPU DWord Offsets WinPLC EBC PBC DEVNETS MODBUS 24 1 24 9 25 1 25 9 V memory Offsets from Output Start octal DWord Parameter 1 0 2 4 6 0 4 10 14 DWord Parameter 2 Configured Function
119. gure I O dialog See Chapter 8 for a DirectLOGIC programming example that loads and runs a pulse profile using the bit D word addressing in the table on the page 6 34 Fora Home Search Profile if you are at the home position and the Home Search profile is initiated there will not be any pulse outputs 6 3 2 Counter I O User Manual Chapter 6 Program Control Trapezoid S Curve Symmetrical S Curve and Home Search Flowchart The flowchart below provides the logical sequence necessary to execute a Trapezoid S Curve Symmetrical S Curve or Home Search pulse profile Load 10 into Command Code Verify that the HEX CTRIO is configured correctly ect ction Load Pulse Profile Number into At this point the profile will v Parameter 1 begin to run Decimal leane SET RESET umae Output Enable Output Enable Correct SET Process Command The Output Active bit will be ON ON while the profile is Verify that running you ve entered the correct table number Wait here until Output Active goes OFF indicating the profile has completed Complete ON Run Profile Again RESET Process Command RESET Output Enable RESET Process Command Counter I O User Manual 6 33 Chapter 6 Program Control EY Running a Trapezoid S Curve Symmetrical S Curve Profile or Home Search Profile on CTRIO YO amp Y1 ame PLC Control Outputs Base Addr V2030
120. igh and Low Word of DWord Parameters llle 6 15 Input Function Status DWord Parameters lisse 6 16 Input Function Status Bit Definitions llle 6 16 Input Function Control Bit Definitions cse 6 16 Counter I O User Manual Vv Table of Contents fii Input Function Status Control Bits and Parameters esses 6 16 Control Registers esses aka Rom eg Roe ane Rui ADEM ded Jede ln Je deje 6 17 Status Redlsters Lees E RS ERR ER E PR I dod ee deus 6 17 Example Input Control Status Bits and Parameter Register Addresses 6 17 Memory Mapping Example for D2 240 CPU 0 eee ee eee 6 18 Input FulictlOns undo duke em Rer hace P Rei ER de I aans aiso RR RO RR D ee 6 19 Counter amp Quadrature Counter l i ee 6 19 Edge Timer and Dual Edge Timer llle 6 20 Edge and Dual Edge Timer Timeout Function 0 6 21 Pulse Catch Input Function l l I 6 22 Runtime Changes to CTRIO Configured Preset Tables 0046 6 23 Entry Number for Edit Table Entry Commands 0 00 c eee ee eee 6 24 Entry Type for Edit Table Entry Commands llselleleeeeee 6 24 Discrete Outputs Driven from a Scaled level 6 2 cee eee 6 25 Load Preset Table Flowchart 0 20 00 cece eee ee eens 6 26 Pulse Output Status Control Bits and Command Codes 6 6 27 Command Code and Parameter Definitions
121. ii INTRODUCTION TO THE CTRIO MODULE In This Chapter CTRIO Version 2 and Workbench 2 New Features 1 2 CTRIO Module Overview 2s sss 1 3 Support Systems Tor the CTRIO Module 12s xk Rma 1 4 CTRIO Specificati nS osre ecis grid RE DECR OR CRCRCI we dese OS 1 5 HO CTRIO LED Indicators odorem aree eoe ees 1 7 H2 CTRIO LED Indicators 442 33 2 0 90 REGRESO ER AERA OE S 1 8 HASC TRIO LED Indicators ic 3 ont T ucc SP ROCA ER SIR RO Cn 1 9 T1H CTRIO LED Indicators 5 5 2 acq REGE EE OR SS CE ERR OS 1 10 Chapter 1 Introduction RY CTRIO Version 2 and Workbench Version 2 New Features Below is a list of the new features that were added to HO H2 HA T1H CTRIO and Workbench version 2 Module firmware version 2 requires CTRIO Workbench version 2 for proper configuration Firmware versions and CTRIO Workbench can be downloaded from www automationdirect com CTRIO version 2 Workbench version 2 new features 1 added HO CTRIO H4 CTRIO and T1H CTRIO support added 5 user configurable Home Search Profiles 2 3 added I O mapping details for all PLC Controller interface modules 4 status of CTRIO onboard outputs are now part of the I O map 5 added System Functions to Monitor I O and through I O map that allow you to read and write to the CTRIOs internal registers Doing this expanded the I O map by 32 input bits and 32 output bits This gives you the ability to write a stored value into the
122. imer Timed Out Bit V2020 2 C162 is exceeded Pulse Catch Output ON for the specified pulse time if input pulse Pulse State V2020 0 C160 qualifies as a valid pulse Pulse Catch Starting V2020 1 C161 ON when pulse edge occurs Parameter 1 V2001 V2000 V2001 V2000 Decimal Parameter 2 V2003 V2002 V2003 V2002 Decimal Control Registers Example using V2030 as base output address for Input Channel 1 Control bits sent from CPU to CTRIO PLC Example 1 Bit of Word PLC Example 2 Control Relay see kame see note 2 D2 250 1 260 D4 450 note 1 D2 240 CPU zd Enable Counter Capture V2054 0 C260 Bit Enable Timer Capture V2054 0 C260 Bit Enable Pulse Catch V2054 0 C260 Bit Reset V2054 1 C261 Bit Counter I O User Manual 6 17 Chapter 6 Program Control EY Memory Mapping Example for D2 240 CPU Note 1 The D2 240 CPU does not support bit of word addressing The status and control bits must be mapped to control relay words An example of mapping code is shown below SP 1 LD VC260 OUT V2054 V2020 OUT VC160 Note 2 For example DirectSoft32 uses B2020 1 in the ladder code to indicate that you are addressing the second bit of V memory register 2020 The B prefix indicates bit of word addressing 6 18 Counter I O User Manual Input Functions Counter amp Quadrature Counter Parameters 1 and 2 are explained on
123. ions Error Complete CO B2024 6 B2024 7 LD AF CTRIO base slot number 32 bytes of data will be Read from the CTRIO Offset 82 Hex is the beginning of the Input and Output Registers within the Command Frame System Command Code Register Initialize System Functions TO co 5 c T END The Timer controls how often the internal registers are Read RD from the CTRIO Counter I O User Manual l 8 1 1
124. is value from 1 to 99 Hex BCD Word Parameter 3 specifies the value that Input Function will compare against The flowchart on the following page provides the logical sequence necessary to execute a Run to Position pulse profile See Chapter 8 for a DirectLOGIC programming example that executes a Run to Position pulse profile using the bit D word addressing in the table on page 6 47 Parameter 2 Word Parameter 2 defines three elements of the Run to Position routine Bit 12 determines if the specified position is greater than or equal or less than the current Input Function position value Bits 9 and 8 determine which Input Function to use for the comparison The low byte specifies the duty cycle Specified Position Parameter 2 Parameter 2 Parameter 2 Hex Parameter 3 is Bit 12 Bits 9 amp 8 Duty cycle at 50 less than Ch1 Fn1 00 0000 greater than Ch1 Fn1 00 1000 less than Ch1 Fn2 01 0100 1100 0200 1200 0300 1300 greater than Ch1 Fn2 less than Ch2 Fn1 greater than Ch2 Fn1 less than Ch2 Fn2 greater than Ch2 Fn2 Oj O O Comparison Bits 15 12 Input Function Bits 11 8 Greater Than or Equal 0001 1Hex Ch 1 Fn 1 0000 OHex Less Than 0000 OHex Ch 1 Fn2 0001 1Hex Ch 2 Fn 1 0010 2Hex Ch 2 Fn2 0011 3Hex Counter I O User Manual 6 45 Chapter 6 Program Control Run to Position Mode Flowchart The flowchart below provides the logical sequence nec
125. isolated DC switches that can be used to break the high or the low side of a DC load Cn where n 0 1 2 3 CTRIO Output 5 to 36VDC C Yn Load Load 5 to 36VDC G Cn where n 0 1 2 3 CTRIO Output C3 Yn Counter I O User Manual 2 3 1 Chapter 2 Installation and Field Wiring ee T1H CTRIO Stepper Servo Drive Wiring Example Input Output Channels OD C O O O GGG O O P O O e 1A B 1C 1D Yo YO Y1 Y1 2A 2B 2c 2D Y2 Y2 Y3 Y3 Step Amplifier o ujdjBjH gi D fO D HB B UD UL D Step Amplifier i ji 5 36VDC L 5 36VDC IF C OPTO Power T OPTO Power ral Channel Commons C3 Pulse or CW Be quus e e e eje e e e o e e e e o o o 1M 1M 1M 1M co co C1 c1 2M 2M 2M 2M C2 C2 C3 C3 Direction or CCW Direction or COWES F User Bus Terminals no internal connection to CTRIO 2 29 29 2 29 2 29 29 9 2 l l USER BUS 1 USER BUS 2 Uj B HI B B D JH D 1H OOO D H U DU This example assumes that the Step Amplifier interface to be optocoupler LEDs common anodes at the OPTO Power terminal with internal current limiting resistors This is a standard method
126. ld be passed from the CPU to the CTRIO are also included Function enable bits etc The current status of each configured input and output is shown just below the Input Status and Output Status columns KK x VO Statue amp Input Functions Ouiyad Forschons Syslem Furetioen Qhereil harei Inout Situs ODO Oups irut Status 5 Output Status D Oua Out A 8 c D 042 ous fern ako ge a NEN o o ee ee MEMEEM Input Functor Inga Funchors Quad Courter Edge Tenet Unconhgaed Uncorfigueed Current Count So Lat Tare E E Timer 39 Captued Start m Ar Reset Value On Capnse Conclete m Enable Capture ReveeCont Lat Enor Code No enor In the example above the Current Count for Ch1 Fnl Quad counter is 994 The Reset Count button can be used to reset the count to the configured Reset Value For Ch1 Fn2 the Edge Timer is captured at 38us The Enable Capture bit must be on prior to when the configured edge input occurs Note that Output Status Out 0 and Out 3 are ON Out 0 is configured for pulse output and Out 3 is configured for a Raw discrete output These outputs can be controlled from the Output Functions window Counter I O User Manual 7 3 Chapter 7 Using Monitor I O esse Output Functions The Output Functions dialog includes all Output Function Word and DWord Parameters file number duty cycle target position etc and status bits passed from the CTRIO module to the CPU Output Enabled Command Co
127. le and System Functions flowcharts are provided to give an overview of the steps needed to execute a pulse output profile or a SystemFunctions command DirectLOGIC PLC addressing tables are also provided with CTRIO I O data mapped in the word and CR bit areas of CPU memory shown on page 6 29 Counter I O User Manual 6 3 1 Chapter 6 Program Control SY Trapezoid S Curve Symmetrical S Curve Home Search Profiles For predefined Trapezoid S Curve Symmetrical S Curve and Home Search profiles the program needs to prepare the Load Table command by selecting Command Code 0010 Hex BCD and setting Word Parameter 1 to the File number of the profile example File 1 Trapezoid 1 Then the program can set the Process Command bit and watch for the Command Complete bit Then the program should clear the Process Command bit and set the Direction bit if necessary and finally the Enable Output bit to start the output pulses Clearing the Enable Output bit will always suspend pulsing and reset any profile in progress to it s beginning Once complete the profile remains loaded and can be restarted by clearing the Enable Output changing the direction bit if desired and again setting the Enable Output The flowchart on the next page provides the logical sequence necessary to execute a Trapezoidal S Curve Symmetrical S Curve or Home Search pulse profile For the Home Search routine a CTRIO input must be assigned to Limit by the CTRIO Workbench Confi
128. ll enter RUN mode after the 4 JI SET CTRIO module If the timer is not used and the PLC is changed from RUN STOP RUN a zero System Command System Command value will be written to the CTRIO module Error Complete B2024 6 B2024 7 B2060 7 5 RST Process Command TAO K10 EDD 6 gt V2002 Current Raw Count Register OUTD WT instruction will write Raw Count to CTRIO V2102 on power cycle or RUN STOP RUN change Reset Count co B2054 1 OUT Input Counter Reset g M END 8 10 l Counter I O User Manual Chapter 8 DirectLOGIC Logic Programming Etdraples 8 DirectLogic Programming Examples Reading CTRIO Internal Registers The following Systems Functions example uses the Write to Intelligent Module WT and Read from Itelligent Module RD instructions to read all of the CTRIOS internal registers every 900ms and place the data starting at V2200 DirectSOFT 32 Initialize System Functions co ID K1 System Functions Command 0x01 Hex Read all Registers V2100 Initialize System Functions a System Command Code Register CTRIO base slot number CO LD 2 l K1 LD L K2 LD K80 2 bytes of data will be written to the CTRIO Offset 80 Hex is the beginning of the Command Frame in the CTRIO V2100 B2060 7 System Command Code Register L d4 OUT Process Command Initialize System System System Command Command Funct
129. log Overview ezsa duae eve eot eee boe p i oe 5 2 Output Function Selections iu usw sme e e ea OR RR aS 5 3 nc 2er c P LITTITUDTTTT 5 4 Discrete OOUEDEUS us cee eens Eon nd eee ee CO E en 5 5 gsccrenqoU A C 5 8 Trapezoidal Profile secesi aie ensina CARCER UR SIC ERR 5 9 S CUVE Profile oues geek ted ar e co oa eds A oM er ded 5 10 Symmetrical 5 Curve Profile 44 4 5 2 0060 ss Cake e Rh Ryo da 5 11 Dynamic Positioning Prom sc ina ate e hcl R RR be d 5 12 Dynamic Velocity Profile 3 aac are ly eater EORR WRdCR X 5 13 Home Search Profile c oui dt rr cR eces iteki neresti ero 5 14 Additional Pulse Profiles 4 os6 s00 ces de Rx 5 16 Chapter 5 Configuring the CTRIO Outputs Configure IO Dialog Overview The Configure IO dialog is the location where input and gt Module Configuration output functions are assigned to the module The choice of Config IO input and output functions determines which options are available The input and output function boxes H2 H4 T1H CTRIO Configure I O Dialog prompt you with selections for configure 10 mx supported functions The Workbench Chanel Chamel2 Outputs software disallows any unsupported Bie ioni configurations Pae Ste 0 Pulse Cw CCW From the main CTRIO Workbench window click on the Go to m m rerum T PROGRAM Mode button Then m m E click on the Config I O button to arrive at a
130. log below will appear if you have mapped the I O in the CTRIO to the controller Here you have the ability to suspend CTRIO reads from the CPU controller Doing so will allow Monitor I O to control the CTRIO without any control program intervention With the output reads suspended the Monitor I O dialog allows you to simulate program control for example enabling a timer resetting a counter running a pulse profile or turning on an output configured for Raw mode etc When exiting Monitor I O you will be prompted to re enable the controller output reads Attention x CTRIO is currently reading output data from the controller This will interfere with the I O Monitor s ability to control CTRIO Would you like me to suspend output reads Yes No The Monitor I O dialog is divided into three functional areas I O Status amp Input Functions Output Functions and System Functions Just below the Windows title bar you will see tabs to switch between the three Functions The functions are described on the pages that follow 1 0 Status amp Input Functions Output Functions System Functions 7 2 Counter I O User Manual Chapter 7 Using Monitor I O I O Status amp Input Functions I O Status amp Input Functions dialog includes all Input Function DWord Parameters raw count time scaled count time etc and status bits passed from the CTRIO module to the CPU Capture Starting Complete bits etc The control bits that wou
131. lse is suspended 0 C TRIO Output Fault should never be ON Command Error V2022 6 C126 N if Command or Parameters are invalid 0 Command Complete V2022 7 C127 ON if Module Receives Process Command Control Bits Registers Example using V2030 as base output address for Output Channel 1 Control DWords Words and bits sent from CPU to CTRIO Name PLC Example 1 Bit of Word PLC Example 2 Control Relay see note 1 see note 2 D2 250 1 260 D4 450 D2 240 CPU Command Code V2040 V2040 Parameter 1 V2041 V2041 Parameter 2 V2042 V2042 Parameter 3 V2031 V2030 V2031 V2030 Enable Output V2056 0 C220 Go to Position V2056 1 C221 Suspend Output V2056 2 C222 Direction V2056 4 C224 Process Command V2056 7 C227 Counter I O User Manual l 6 29 Chapter 6 Program Control i MMM Y Memory Mapping Example for D2 240 CPU Note 1 The D2 240 CPU does not support bit of word addressing The status and control bits must be mapped to control relay words An example of mapping code is shown below SP 1 LD VC220 OUT V2056 LD V2022 OUT VC120 Note 2 For example DirectSOFT32 uses B2022 2 in the ladder code to indicate that you are addressing the third bit of V memory register 2022 The B prefix indicates bit of word addressing 6 3 0 Counter I O User Manual Chapter 6 P
132. ly Parameter 3 Signed Decimal Load Pulse Profile number into Parameter 1 Decimal Is Table Number Correct SET Go To Position SET Process Command Once the current position is loaded The CTRIO will begin to send output pulses Verify that you ve entered the Correct table number You can suspend the pulse output at any time by using the Suspend Output bit Is Position Loaded ON Using Suspend Output will NOT reset the zero point Is Command Complete ON RESET Process Command RESET Go To Position Is Command Error ON If you have more position values you can load them as soon as the Position Loaded bit comes ON You don t RESET have to wait for the currently Process loaded position to be More Command reached Positions Turning on Output Enable sets the zero point for the CTRIO that is the current position value is set to 0 SET Enable Output RESET Enable Output 6 36 Counter I O User Manual _ Chapter 6 Program Control Dynamic Positioning using the CTRIO YO and Y1 Name PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Relay D2 240 PLC Status Inputs ase Addr V2000 Control Relay D2 240 Action Command Code V2040 V2040 Set to 10 Load St
133. module is compatible with two DL405 CPU slot interface devices Consideration must be given to the firmware versions of the CPU slot interfaces to assure their compatibility with the H4 CTRIO see chart below The H4 CTRIO module plugs into any I O slot of any DirectLogic 405 base H EBCs support the use of the H4 CTRIO in DL405 local expansion bases The H CTRIO cannot be used in Serial Remote I O bases For installation instructions refer to the DL405 User Manual D4 USER M if using a DirectLogic PLC DL405 Installation and I O Manual D4 INST M if using an H4 EBC interface The first time you power up the CTRIO module you should see the OK LED blinking The blinking LED indicates that the module is in program mode CPU and CTRIO Compatibility Chart CPU slot Device Firmware Hardware DireciSOFT32 April 2000 or nd H8 CIS v 2 00 SH RISC v 1 500 v 4 0 Build 16 or later May 2000 or later H8 CISC v 2 00 SH RISC v 2 500 2 1 328 or later v 4F or later Updated firmware versions can be downloaded from our web site at www automationdirect com 2 i 18 Counter I O User Manual Chapter 2 Installation and Field Wiring ee Wiring the H4 CTRIO Module The H4 CTRIO module has two independent input channels each consisting of 4 optically isolated input points pts LA 1D on COUNTER I O common 1M and pts 2A 2D on common 2M The inputs can be OK ER TB wir
134. mplete etc The control bits that would be passed from the CPU to the CTRIO are also included Enable Output Go to Position Direction etc VO Slalus rend Funcions Output Functions System Functions Pulse Step Puls Direction Decrete on Ohl Fnl Panset Mode Command Command Command DAD Load Table mau Lond Tate QQN Velocity Mode ID Run to Lent Mode 2 22 Run ta Preiten Mode 2 Fenua BR zJ y 4 1 Lu 1 Enable Dipa Enable Output Process Command Process Command Output Enabled on Dutput Enabled ow Posion os Output Active on Table Complete m Ouret Stalled Of E Command Enor of Command Enor of Command Complete on Command on CTRIO read of PLC outputs is gt gt Sunpended lt Click to enable Lact Enor Code Noema b MO Sus M legad Functions Output Function Systems Functions Pieve Pde IRivectiony Digetete on Chi Fnit Rew Preset Made Command Conmand Command 10 Load Tabie 2 A p i File Number B m a 15 J 3j I i r 1 Enable Oupa ae n mene Quiet Enabled ow Pornon Loaded Co Ount Active Oe Output Stalked on Command Enor Command Emor oir Command Complete or Commard Comelete oH CTRIO read of PLC outputs ia gt gt Suapanded lt Click to enable Lest EnorCode 0 No enor In the example above Outputs 0 and 1 are configured for Pulse step and direction Output 2 is configured to Preset mode assigned to Ch1 Fn1 quad counte
135. n below assumes the T1H CTRIO module is the first module in the system The CTRIO modules consume 44 bytes of input memory and 52 bytes of output memory The maximum amount of I O memory per H2 T1H PBC station is 244 input bytes and 242 output bytes You may need to refer to the Profibus User Manuals H2 PBC M T1H PBC M for information on bytes used by discrete and or analog I O modules to be able to determine the appropriate Starting input and output byte offset addresses for the CTRIO module For the T1H PBC enter a 2 byte Output Offset to accomodate memory used by the Hot Swap base rescan feature 6 10 Counter I O User Manual Chapter 6 Program Control I O Map with a TIK DEVNETS DeviceNet Controller When using the TIH CTRIO module with The TIK DEVNETS controller I O Map will display native DeviceNet addessing as shown below Mao Dechy Mode veu Mao Dua Mae TW OCVNET PLC Aderson Stang bye ote loc rp g Sirge tioa A Rer M gt j furor p a SSS rev Functions Output Functions System Functions OX And Quad Courter NAR Lage Tm Daa CTR Corbie npa Daa CTR Cortot Fou Date CTRD Coole Vou Dea C TRI o Corista 0 3 gt Curert Court oti Porn Te 221 M Pansat Via 1235 Te 330 Capres Sur 311 Caton C Dua Data former CTRD Oupa Dara Corio CTRID Oupa Data Cortes CTRD Ospas Dara Corm s CTPID A0 Y eve 0 9 Crate Cann Ca J mej cnm oc Counter I O User Manu
136. n the level gets to 100 If the level drops the output will stay on until the mE level drops below 450 rpm where it will turn OFF B5 Md C OFF when value is greater than level OFF when value is less than level Deadband 10 Lx OFF when less condition example Consider a Discrete Output set to turn OFF when less at 500 When the level gets to 500 the output Cancel turns OFF If the level rises again the output will stay OFF until the level gets to 550 where it will turn ON Counter I O User Manual 5 7 Chapter 5 Configuring the CTRIO Outputs EM Pulse Outputs The CTRIO module offers up to two axes of motion control YO and Y1 as an axis and or Y2 and Y3 as an axis The H0 CTRIO has one axis of motion control YO and Y1 The outputs can be configured for CW CCW or step and direction operation The outputs respond to profiles defined by the user and called by the user control program The following pulse profiles are supported Trapezoid S Curve Symetrical S Curve Dynamic Positioning Dynamic Velocity Home Search There are three additional pulse profiles that are available to use that are not created using the Pulse Pulse Proris Ouput Profiles Tables These profiles Velocity Mode p Pulse Profiles Run to Limit Mode and Run to Position Mode are File 1 2axisJo discussed at the end of this chapter Pulse Profiles Creating Pulse Output Pr
137. n was created using Workbench Offline ram Doi M version you must connect your PC to the CTRIO module through the CPU controller and write the configuration to Ascona a the module Entering program mode takes the CTRIO module offline Input pulses are not read or processed in Program mode and all outputs are disabled DirectLOGIC CPUs will hold last value in V memory while the CTRIO is in Program Mode Run Mode Start Processing I O Pulses with the CTRIO Module Selecting Run Mode causes the CTRIO module to begin processing pulses based on the I O configuration you created In Run mode the CTRIO Workbench utility also allows you to monitor and verify the proper operation of inputs and outputs You can see the count change reset etc using the Monitor I O dialog Monitor I O is very useful for debugging and commissioning of a new system See chapter 7 for information on Monitor I O If you are using a DzrectLOGIC CPU the CTRIO mode follows the CPU mode If the CPU is placed in Run Mode the CTRIO module will also enter Run Mode If the CPU is placed in STOP or PROGRAM Mode the CTRIO will enter Program Mode The CTRIO also responds to mode changes made in Workbench and can be placed in Run Mode while the CPU is in Stop or Program Mode The CTRIO module responds to the most recent change whether performed in Workbench or from the CPU The CTRIO module will not enter Run Mode if it does not have a valid configuration
138. ncy Max Frequency and Acceleration rate come from the CTRIO Workbench Profile After loading a Dynamic Position Profile setting the Enable Output causes the CTRIO module to assume a position of 0 pulses The program should write the next target position in DWord Parameter 3 and set the Go to Position bit This will cause the CTRIO to set both the Pulses Active and the New Position Loaded bit and begin to output pulses The number of pulses and direction are determined by the CTRIO based on the difference between the current location and the specified target location The flowchart on the following page provides the logical sequence necessary to execute a Dynamic Positioning pulse profile The program can monitor the state of the Pulses Active bit and the New Position Loaded bit to determine when the new position has been attained The New Position Loaded status bit will always follow the state of the Load Seek New Position control bit This status bit should be used to signal the program that the CTRIO has received the new state of the control bit Position Loaded Status Bit Pulses Active Status Bit V40622 1 or C441 V40622 0 or c440 0 0 Idle 1 Go To Position Acknowledged Pulsing 1 Still Pulsing Go To Position Control Bit is OFF 0 Go To Position Acknowledged Position Attained CTRIO Dynamic Position Pulse Output State You do not have to wait on the CTRIO to complete a move that is in progress before loading the next t
139. nt you have four decisions to make regarding your input at 1C or 1D 1 First designate the pulse edges you want to measure between 2 The Free Run option is assigned by clicking in the appropriate box If your application calls for velocity measurements to be taken at the commencement of some event do not use Free Run If your application calls for velocity measurement on a continuous basis you should use Free Run Configure 10 ax 3 The Enable Timeout option is assigned by Vat rr t eed clicking in the appropriate box and specifying a mere vatem 2 i Timeout period Once the timer is enabled the qe ace pasha Timeout Bit is set if the time that it takes the m r CTRIO to see the configured input edge exceeds oe F E eov the specified Timeout Period Also if the time before the CTRIO sees the next configured edge Rada ii er exceeds the specified Timeout Period the Timeout nine bern bit is set More information about the Timeout function can be found in chapter 6 4 The last remaining decision to be made is about scaling Clicking the button with the tape measure symbol starts the Scaling Wizard We discuss the scaling wizard later in this chapter The Scaling Wizard is intelligent in that it offers scaling options that are appropriate for your input selections 4 8 Counter I O User Manual Chapter 4 Configuring the CTRIO Inputs Reset 1 and
140. o error 100 Specified command code is unknown or unsupported 101 File number not found in file system 102 File type is incorrect for specified output function 103 Profile type is unknown 104 Specified input is not configured as a limit on this output 105 Specified limit input edge is out of range 106 Specified input function is unconfigured or invalid 107 Specified input function number is out of range 108 Specified preset function is invalid 109 Preset table is full 110 Specified table entry number is out of range 111 Specified register number is out of range 112 Specified register is in unconfigured input or output onor ro 09 VO Stobart i ingua Functions Output Functions System Functions Charest Orei input Staus p Statue Irgat Statue Duipal Status A 8 c D O40 Out a 8 c o Dua 043 st cect OH 008 008 08 cet Ot NEANNMENN Ingra Functions rou Functions Quad Counter Edge Timer Uncentgued Unconigured Cert Court a Laat Tine Tue 3 Caghaed Stat m Al Reret Value Off Capture Compite m a RewtCont CTRIO read of PLC outputs i 5 Sutpended c Olek to enable Status bar Counter I O User Manual 7 7 DinECTLOGIC APTER PROGRAMMING EXAMPLES In This Chapter Programming Examples Overview 200s eee eee eee 8 2 Load and Run a Pulse Profile 2 cad ee cbens andar ERR earned 8 3 Dynamic Positioning Profile 4 35
141. ocess Command the Input is ON configured as a Limit Is Command Complete RESET Process Command RESET Process Command At this point the CTRIO will begin outputting pulses You can change the Frequency and or the Duty Cycle as often as you need you can even change them while the output is active The Output Active bit will be ON until the CTRIO sends out all of the pulses you configured You can also suspend the pulse output at any time with the Suspend Output bit Select Direction SET Output Enable Load new parameter values New Frequency or Duty Cycle Is Output Active ON RESET Output Enable Yes Change Direction RESET Output Enable Counter I O User Manual 6 43 Chapter 6 Program Control ee Run at Velocity on CTRIO YO amp Y1 until Discrete Input Limit Name PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000 Bit of Word PLC Control Outputs Base Addr V2030 Control Relay D2 240 PLC Status Inputs Base Addr V2000 Control Relay D2 240 Action Command Code V2040 V2040 Set to 21 Hex Run to Limit Mode Parameter 1 V2041 V2041 Set initial run frequency 20Hz 25000Hz decimal Parameter 2 V2042 V2042 Select discrete input edge in high byte low byte duty cycle 1 99
142. ocess Command V2056 7 C227 Turn ON Command Complete status bit is returned see step 4 Command Status V2022 7 When ON command has been accepted clear Process Command bit step 3 Command Error V2022 6 ON if Command or Parameters are invalid Enable Output V2056 0 Turn ON to start pulses Disable Output V2056 0 Turn OFF to start pulses Suspend Output V2056 2 Turn ON to pause output pulses without resetting pulse count 6 40 Output Suspended V2022 2 ON when out pulse train has been suspended While Velocity Mode Control is running Run Frequency step 2 and Duty Cycle step 3 may be actively changed simply by writing a new Parameter value Since no accel decel parameters are specified in this profile the output change is a step response Counter I O User Manual Chapter 6 Program Control Velocity Mode Flowchart The flowchart below provides the logical sequence necessary to execute a Velocity Mode pulse profile Load 20 into Command Code Hex Select Direction At this point the CTRIO will begin outputting pulses Load the Frequency into Parameter 1 Decimal SET Output Enable Verify the CTRIO is configured correctly You can change the Frequency and or the Duty Load new Cycle as often as you need parameter values you can even change them while the
143. ofile Tables To create Pulse profiles click the Pulse Profiles button on the main Workbench dialog This will open the Pulse Profiles Tables dialog To create a new profile click Add or Edit This will open the Edit Pulse Profile dialog iX DIT On the Edit Pulse Profile dialog select one of the six Pulse Profile Types This dialog is used to name and define the pulse profile parameters The various parameter fields contain typical default values Workbench will disallow any invalid parametrer entries Biscke Use d Tots Pes 10000 Acci Tee 00 m Decal Tine 00 ma Stat Foner 40 He Pea Free CJ c YXO me Redfin 0 hz 5 8 Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs Trapezoidal Profile The Trapezoidal profile changes the velocity in a linear fashion from the specified Start Frequency until the specified target Position Frequency is reached During decelerating the velocity changes in a linear fashion from the specified Position Frequency until the specified End Frequency and Total Pulses is reached Acceleration Time Edit Pulse Profile Profile Into Nene Peak Freq 1000 Hz Position Frequency Profile Type Total Time 10 97 sec S Curve Symmetrical S Curve Accel Time Dynamic Positioning 1002 ms Dynamic Velocity Home Search Decel Time 1006 ms r File Stats Start Frequency End Frequency Total Entries
144. om Table on page 6 2 DirectLOGIC Offset n 24 Status Bits V memory Offsets transfers from CTRIO to CPU DirectLOGIC PLCs System Command Error 24 6 System Command Complete 24 7 Ch1A 25 0 Chi B 25 1 Ch1C 25 2 Ch1D 25 3 Ch2A 254 Ch2 B 25 5 Ch2 C 25 6 Ch2 D 25 7 Out 0 Active 25 8 Out 0 Mode 25 9 Out 1 Active 25 10 Out 1 Mode 25 11 Out 2 Active 25 12 Out 2 Mode 25 13 Out 3 Active 25 14 Out 3 Mode 25 15 System Functions Control Bit Definitions From Table on page 6 4 DirectLOGIC Offset n 30 Control Bits V memory Offsets transfers from CPU to CTRIO DirectLOGIC PLCs Process System Command 30 7 6 6 Counter I O User Manual Chapter 6 Program Control 1 O Map Dialog The I O Map dialog is accessible from the main Workbench dialog On the main Workbench dialog click the button labeled I O Map The I O Map dialog divides the controller I O memory used by the CTRIO module into three groups 1 0 Map Input Functions Output Functions and System Functions Just below the Map Display Mode field you will see tabs to switch between Input Functions Output Functions and System Functions Click on the Input Functions tab or Output Functions tab to display the CTRIO module s assigned input or output functions quad counter pulse catch pulse out discrete out etc For each input and or output function assigned the I O Map dialog displays th
145. omplete ON 2 Use the PLC s RD instruction to read the 32 bytes from the CTRIO s shared RAM at offset 82 hex and place them in the PLC s v memory ThinknDo Read from CTRIO 1 This command tells the CTRIO to copy all 8 of it s internal register values into it s shared RAM making them accessible ERES The 8 CTRIO register values are arranged as follows DWORDO Cht Fn1 DWORD 1 Cht Fn2 DWORD 2 Ch2 Fn1 DWORD 3 Ch2 Fn2 DWORD 4 Output 0 DWORD 5 Output 1 DWORD 6 Output 2 DWORD 7 Output 3 Use ThinknDo s Call Block to write the 2 byte command code 01 Read AII Registers to the CTRIO at address 80 Make sure the parameters you re using are correct SET Process Command Command Complete ON Use ThinknDo s Call Block to read the 8 DWORD values from the CTRIO s shared RAM at address 82 Counter I O User Manual 6 49 Chapter 6 Program Control Cs Writing to All CTRIO s Internal Registers Flowcharts The flowcharts below provide the logical sequence necessary to Write to all of the CTRIO s internal registers Writing to the CTRIO s internal registers is a two step process 1 Transfer the data values from the controllers memory to the CTRIO s shared RAM 2 Ask the CTRIO to transfer these values from its shared RAM to it s internal registers DirectLogic Write to CTRIO Use the PLC s WT instruction to transfer the 2 byte comman
146. on M The inputs can be wired to either sink or source current The module has 2 optically isolated output points pts YO Y1 on common YC The outputs can be wired to either sink or source current but the F3 F3 sink source jumper selection sets both outputs to the same option Sourcing outputs must oko O ERR be wired so positive current E IN ao flows into the YC terminal and e A se 9 then out of the Yn terminal m Le Saree oma Sinking outputs must be wired ui ii p so positive current flows into m TE l LB rl la Yn terminal and then out of m M s the YC terminal see the vh 5 ye ve Ex e diagram to the right and the vo w e schematic on page 2 8 I vi i We Source operation is the factory OUT eee lvo default setting for the outputs ms F mn n The module is configured HCIO using CTRIO Workbench to Lf accommodate the user s application The function of I each input counting timing reset etc and output pulse output discrete output etc is defined in the configuration of the module Refer to Chapters 4 and 5 to determine what input and output configurations are possible Field device wiring must be compatible with the module configuration See the notes below for further details about p
147. ontrol Output Status Offsets are listed in the order of the Output 0 Output 3 Output x Status Bits transfers from CTRIO to CPU Bit Offsets WinPLC EBC PBC DEVNETS MODBUS V memory Offsets DirectLOGIC PLCs Command Error 38 46 54 62 22 6 22 14 23 6 23 14 Command Complete 39 47 55 63 Output Status Bit Definitions Pulse Output Output Status Offsets are listed in the order of the Output 0 1 2 3 Status Bit CTRIO to CPU Bit Offsets WinPLC EBC PBC DEVNETS MODBUS 22 7 22 15 23 7 23 15 V memory Offsets from Input Start octal Output Enabled 32 48 22 0 23 0 Position Loaded 33 49 22 1 23 1 Output Suspended 34 50 22 2 23 2 Output Active 36 52 22 4 23 4 Output Stalled 37 53 22 5 23 5 Command Error 38 54 22 6 23 6 Command Complete 39 55 22 7 23 7 Counter I O User Manual 6 3 Chapter 6 Program Control EY Output Memory Map for Data Transfers from CPU to CTRIO The following table shows which memory locations are used for memory transfers from the CPU module to the CTRIO The starting memory location is defined by the user in the I O Map within CTRIO Workbench If you are using a DirectLOGIC CPU you will use the memory address offsets in the second column If you are using a WinPLC EBC PBC DEVNETS or MODBUS interface you will use the non PLC offsets in column one Data T
148. ored Profile Parameter 1 V2041 V2041 File of desired Dynamic Positioning Profile Process Command V2056 7 C227 Turn ON until Command Complete status bit is returned see step 4 Command Complete Status V2022 7 When ON Profile is now loaded clear Process Command bit step 3 Command Error V2022 6 ON if Command or Parameters are invalid Enable Output V2056 0 Turn ON to assume 0 position Turn OFF to disable pulses and zero position Output Enable Status V2022 0 When ON pulses are now enabled and last position is retained Parameter 3 V2031 V2030 V2031 V2030 Target position User defined DWord Go To Position V2056 1 C221 Starts pulses with direction to obtain the new position relative to previous position Position Loaded Status V2022 1 When ON Go To position is acknowledged Output Active Status V2022 4 When ON module is pulsing OFF with Position Loaded status ON new position move has completed Go To Position V2056 1 Turn OFF to be ready to load a new position Suspend Output V2056 2 Turn ON to pause output pulses without resetting pulse count Output V2022 2 Suspend To seek the next position repeat steps 7 10 ON when out pulse train has been suspended Counter I O User Manual 6 3 7 Dynamic Velocity For Dynamic Velocity the motion limits o
149. ower source considerations circuit polarities and field devices Also refer to the specifications on pages 1 5 and 1 6 for more information Notes 1 Inputs A B C and D require user provided 9 30VDC power sources Terminal M is the commons for the inputs Maximum current consumption is 12mA per input point 2 Polarity of the input power sources shown above can be reversed Consideration must be given however to the polarity of the field device Many field devices are designed for only one polarity and can be damaged if power wiring is reversed 3 The maximum allowable current per output circuit is 1A 2 4 Counter I O User Manual Chapter 2 Installation and Field Wiring H0 CTRIO Quadrature Encoder Wiring Example K ERR KS vo BO y TE am parva A E A B mm IB gn c Z pm D r T TT M vc Gnd vo D cu v1 Power ou 9 30VDC HO CTRIO Counter I O User Manual 2 5 Chapter 2 Installation and Field Wiring EY HO CTRIO TTL Quadrature Encoder Field Wiring ERR OK Yo AQ e BO Y1 CTR TMR IN 9 30V 5 12mA DC Pulse Out 5 36V 1A IN LE D A D B A 10K ET c AAA In 0 1W c 10 5 jm z m ve Dg Yo c m iv 10K OUT B HFE gt 100 H0 CTRIO 0 1W 10 gt oS E Power amp
150. passed to the CTRIO module A Command Complete signal must be received and the Command Error bit must stay at zero Finally the Enable Output instruction must be passed to the CTRIO module Some changes require a combination of Command Codes so those changes must follow the steps above for each Command Code processed Output Control and Status Offsets are listed in order of Output 0 Output 3 Control Bit Bit Offsets WinPLC EBC PBC V memory Offsets transfers from CPU to CTRIO DEVNETS MODBUS DirectLOGIC PLCs Enable Output 32 40 48 56 26 0 26 8 27 0 27 8 Process Command 39 47 55 63 26 7 26 15 27 7 27 15 Status Bit Bit Offsets WinPLC EBC PBC V memory Offsets transfers from CTRIO to CPU DEVNETS MODBUS DirectLOGIC PLCs Command Error 38 46 54 62 22 6 22 14 23 6 23 14 Command Complete 39 47 55 63 22 7 22 15 23 7 23 15 In order to process a command first the program must load the Command and Required Word and DWord Parameters Then the program should drive the Process Command bit to a 1 and look for the CTRIO to acknowledge the command with the Command Complete bit Finally the program should remove the Process Command bit and set the Enable Output bit when appropriate If the Command Error bit is received the CTRIO was unable to process the command due to an illegal value in either the Command Code or Parameter fields Word Control Word Offsets WinPLC EBC PBC V memory Offsets CPU to
151. ping in a value When the count is reset using any of the reset methods the count value returns to the Reset Value The reset options are described in more detail later in this chapter 3 The last remaining decision to be made is about scaling Clicking the button with the ruler symbol starts the Scaling Wizard The Scaling Wizard is intelligent in that it offers only those scaling options that are appropriate for your input selections We discuss the scaling wizard in greater detail later in this chapter Counter I O User Manual 1 5 Chapter 4 Configuring the CTRIO Inputs M Pulse Catch The CTRIO Pulse Catch function allows a very short duration pulse to be qualified and lengthened to a time period long enough to guarantee that it is seen by che CPU CPU scans necessarily vary with the length and complexity of the user s program A scan frequency of several milliseconds or more is common A pulse that lasts less than one millisecond is typically hard to catch during the CPU scan The CTRIO modules Pulse Catch function sees the fast incoming signal and holds its status in a status bit until the CPU can see it A discrete output s can also be tied to follow the Pulse Catch input reus fundo 7 Pe Cuch igi one To insure proper operation the field device JE nae E Alie OWONI wiring vis 7 salt must be Mom S oe compatible For wiring information see Pute Out z D iata 2 j m zoan De
152. polarity only as shown above and are powered by user provided 5 36VDC power sources The maximum allowable current per output circuit is 1A 2 12 Counter I O User Manual Chapter 2 Installation and Field Wiring H2 CTRIO Quadrature Encoder Wiring Example 1A 2A e A A e Cu B 2B B D 1C xc D 1D Power Power o 2D e FL 1 2 qs o Gnd ij a D NC qp e CO o p YO S2 e Q e e Counter I O User Manual 2 13 Chapter 2 Installation and Field Wiring H2 CTRIO TTL Quadrature Encoder Field Wiring gt N gt c o N 5 B 10K A HFE gt 100 0 1W 10 ru B 10K HFE gt 100 0 1W 10 E N o Is m w SSESS d Qeqmeoesoc z a SS OLS o lt S C B 10K Ond T HFE 100 0 1W 10 E S2 9 E 5VDC 9 30VDC 2 14 Counter I O User Manual Chapter 2 Installation and Field Wiring H2 CTRIO TTL Input Wiring NPN TA General Purpose Transistor 2A e c Q an TTL Device n 2 o D ic HFE 100 D 01w 2C E 10 2 e NEA 27 1M 2M Q D e cz D oO iS TTL Device Qo Yo Tes B OK e gt 100 S2 0 1W g E 10 Y3 LAC e e 2 M TTL Device B 10K
153. previous page notice the drop down menu Here you have access to all of the Preset Table Commands The Load Table Command 0x10 will allow you to load any configured Preset Tables In the screen capture on the left you ll see we have selected Preset Table number 1 for this example Remember that Output 2 is assigned to Input Function Ch1 Fn1 which is configured as a Quad Counter Input To load a configured Preset Table for Output 2 to use based on Ch1 Fn1 s count follow the steps below 1 select Command Code 10 0x10 2 enter the desired Preset Table Number in the File Number field 3 click the Process Command button and confirm the Command Complete bit is ON If the Command Error is ON an explanation of the error will appear on the dialog status line Then turn the Process Command button OFF 4 click on the Enable Output to allow the output to operate based on the Preset Table and current status of Ch1 Fn1 quad counter input As the encoder s count on Ch1 Fn1 changes the output 2 turns ON and OFF based on the entries in Preset Table number 1 Turning the Enable Output OFF while the Preset Table is being executed will disable the output 1 0 Status amp Input Functions Output Functions System Functions Pulse Step Pulse Direction Discrete on Ch1 Fn1 Raw eset Mode Command Command Command Command 0x20 Velocity Mode E 0x10 Load Table bl Ei 0 fj Frequency 1000 4 n File Number 1 ul i bee fo m
154. put can be configured for Raw e g output mode and each will have a unique control bit qp g To insure proper operation the field device wiring and the configuration D e must be compatible For wiring information see Chapter 2 PD q v Refer to Output Control Bit Definitions Raw Mode on page a D 6 5 for Raw output control bit addressing 2 e Ci a e A x The module s output terminals are MEE oe represented by the 0 1 2 and 3 boxes f ee l 0 and 1 for the HO CTRIO on the T A right side of this dialog mj 7 r mecm 5n a 7 Ee Taa Ra eric I rcs d Be Tee 5 4 Counter I O User Manual Chapter 5 Configuring the CTRIO Outputs aaa Discrete Outputs The CTRIO module has four discrete outputs numbered Y0 Y3 YO Y1 E X for the HO CTRIO The outputs respond to presets assigned by the Dutputs user in the Configure IO dialog Unassigned The presets are assigned based on the scaled value of an input or the raw value if it has no scaled value The four outputs can all be assigned to one function or they can be grouped within functions and within channels in any manner selected by the user aw Pulse Step Dir Pulse Cw CCW To assign output presets begin by selecting the ouput on the Configure Batet nct IO dialog The outputs are identified based on terminal number In the example to the right output terminal 0 is designated for a discret
155. r and Output 3 is configured as Raw mode In the screen capture on the left notice the pull down menu The menus are context sensitive They will change to display values that are appropriate to the CTRIO s configuration Here you have acccess to all pulse profile commands Command 0x10 will allow you to load any configured Pulse Profiles Trapezoidal S Curve Dynamic Positioning etc In the screen capture on the right you ll see we have selected Pulse Profile number 2 for this example To run a configured Pulse Profile follow these steps 1 select Command Code 10 0x10 2 enter the desired Pulse Profile Number in the File Number field 3 click the Process Command button and confirm the Command Complete bit is ON If the Command Error is ON an explanation of the error will appear on the dialog status line Then turn the Process Command button OFF 4 select the Direction leaving the Direction button OFF selects forward clicking the button ON selects the reverse direction 5 dick on Enable Output to run the Pulse Profile The Output Enabled and Output Active indicators will turn ON When the profile is complete the Output Active indicator will turn OFF Turning OFF the Enable Output during the profile run will terminate the pulse output To run the profile again turn OFF the Enable Output and then re enable it 7 4 Counter I O User Manual Chapter 7 Using Monitor I O In the screen capture on the right on the
156. rget velocity that is specified in the CPU controller memory register Clockwise Decel Rate The clockwise rate at which the output will ramp down from the target velocity that is specified in the CPU controller memory register to Opss Counter Clockwise Accel Rate The counter clockwise rate at which the output will ramp up from Opss to the target velocity that is specified in the CPU controller memory register Counter Clockwise Decel Rate The counter clockwise rate at which the output will ramp down from the target velocity that is specified in the CPU controller memory register to Opss Counter I O User Manual 5 13 Chapter 5 Configuring the CTRIO Outputs se Home Search Profile The Home Search profile is used to find the home position which is usually a reference point to which the object being moved can return upon command at any time during or after the execution of a positioning profile There are several Home Search routines to choose from all with the option to designate whether you want Limit 1 and or Limit 2 a CTRIO discrete input to register on the rising edge falling edge high level or low level signal Limit 1 and Limit 2 can be the opposite edges of the same physical CTRIO input ER The Home Search profile requires that CTRIO inputs C and or D are configured for Limit Out 0 or Limit 2 This is done using the Configure 1 0 dialog erase prate P Profile into Name Fun to Lint 1 at Frequency 1
157. rogram Control SG Pulse Output Profiles Loading a pre defined Pulse Profile is the easiest method for pulse output motion control Command Code 0010 Hex BCD For the Trapezoid S Curve Symmetrical S Curve and Home Search profiles all of the required characteristics of acceleration run frequency and total pulse count etc are entered in the CTRIO Workbench Pulse Profile entry window For Dynamic Positioning and Dynamic Velocity profiles the target position and target velocity are stored in a memory location in the controller All other profile characteristics are entered in the CTRIO Workbench Pulse Profile entry window For Velocity Mode Command Code 0020 Hex BCD Run to Limit Mode Command Code 21 Hex BCD and Run to Position Mode Command Code 22 Hex BCD all profile parameters are stored in the controller s memory registers No CTRIO Workbench Pulse Profile is required In order to process a command first the program must load the Command Code and required DWord Word and bit parameters Then the program should drive the Process Command bit to a 1 and look for the CTRIO to acknowledge the command with the Command Complete bit Finally the program should remove the Process Command bit and set the Enable Output bit when appropriate If the Command Error bit is received the CTRIO was unable to process the command due to an illegal value in either the Command Code or parameter files On the pages that follow Pulse Profi
158. rol the quadrature input counting The C and D ND D inputs can be used for Reset Inhibit or Capture o 8 These functions are explained later in this chapter pe The CTRIO discrete output s can be assigned to the O Quad Counter function using the Preset Tables dialog A Refer to Creating and Using the Output Tables e section in Chapter 5 for details e To insure proper operation the field device wiring a a rE and the configuration must be compatible For eas Fireten wiring information see Chapter 2 Ej fa v E te Discrete on Chi Frit Notice that the modules four input terminals are represented by the A B C mp g a and D boxes on the left side of this dialog as Pv If you are wiring your quadrature counter inputs to terminal 1A and 1B you will e mee Sete COUT 2 need to select the Channel 1 tab near the LU top of this window and click Quad Counter in box A Notice that input B is To keare Ij now slaved to input A pietach nii Dua Edge Timer At this point you have three decisions to make regarding your quadrature input Ca eee 1 A multiplier can be applied to the quadrature input to increase its resolution Select 1x 2x or 4x 1X pulses processed on leading edge of input A 2X pulses are processed on both edges of input A 4X pulses processed on both edges of input A and both edges of input B 2 The Reset Value is assigned by clicking in the data input field and ty
159. rt CTRIO Workbench you will be prompted to establish a link to your CTRIO module You will ind CTRIO Workbench under PLC menu Tools CTRIO Workbench and in the DirectSOFT32 Launch Window Utilities menu Select Link Link Enabled Search View Tools Ja Debug windo Connect Link Setup Offline Setup Memory Map WinPLC EBC and PLC gt ERM gt EBC Users You will need to connect your PC to the RJ45 Ethernet port on the WinPLC or EBC interface device directly or via hub switch etc Connect to the ST style fiber optic port on the Hx EBC F units Access the WinPLC and EBC support version at Start gt Programs gt AutomationDirect Tools CTRIO Workbench or in the DzrectSOFT32 Launch Window Utilities menu as shown above Select the appropriate Workbench version You will be prompted to establish an Ethernet link to i your CTRIO module WinPLCs will need to be given an IP address before connecting with Workbench EBCs will need to have an address selected by DIP Switch or via NetEdit before connecting with Workbench Fi DirectSOFT32 Programming 4 l utilities DBWin32 Logger Version Aq D5400 ini HA CTRIO WB 2 EBC WinPLC CTRIO WB 2 PBC CTRIO WB 2 Offline Bf ERM Workbench NetEdit Uninstall gt CTRIO Workbench DirectLogic PLC fifi CTRIO Workbench EBC WinPLC E DBWin32 Logger ff ERM Workbench Net dit CTRIO WB 2 Direc
160. s Automationdirect com disclaims any proprietary interest in the marks and names of others Copyright 2003 Automationdirect com Incorporated All Rights Reserved No part of this manual shall be copied reproduced or transmitted in any way without the prior written consent of Automationdirect com Incorporated Automationdirect com M retains the exclusive rights to all information included in this document AVERTISSEMENT A Nous vous remercions d avoir achet l quipement d automatisation de Automationdirect comMC Nous tenons ce que votre nouvel quipement d automatisation fonctionne en toute s curit Toute personne qui installe ou utilise cet quipement doit lire la pr sente publication et toutes les autres publications pertinentes avant de l installer ou de l utiliser Afin de r duire au minimum le risque d ventuels probl mes de s curit vous devez respecter tous les codes locaux et nationaux applicables r gissant l installation et le fonctionnement de votre quipement Ces codes different d une r gion l autre et habituellement voluent au fil du temps Il vous incombe de d terminer les codes respecter et de vous assurer que l quipement l installation et le fonctionnement sont conformes aux exigences de la version la plus r cente de ces codes Vous devez tout le moins respecter toutes les sections applicables du Code national de pr vention des incendies du Code national de l lectricit et
161. ser in the I O Map within CTRIO Workbench If you are using the DirectLOGIC CPU you will use the memory address offsets in the second column If you are using an H2 WinPLC EBC PBC MODBUS or DEVNETS in the CPU slot you will use the non PLC offsets in column one Data Type and Offset WinPLC EBC PBC DEVNETS MODBUS Address for Inputs DirectLOGIC Definition dwX0 n 0 Ch 1 Fn 1 Parameter 1 dwX1 n 2 Ch 1 Fn 1 Parameter 2 dwX2 n 4 Ch 1 Fn 2 Parameter 1 dwX3 n 6 Ch 1 Fn 2 Parameter 2 dwX4 n 10 Ch 2 Fn 1 Parameter 1 dwX5 n 12 Ch 2 Fn 1 Parameter 2 dwX6 n 14 Ch 2 Fn 2 Parameter 1 dwX7 n 16 Ch 2 Fn 2 Parameter 2 bX0 7 bX8 15 n 20 Ch 1 Fn 1 Status Low Byte Ch 1 Fn 2 Status High Byte NI A A m AR me mA mA 4 bX16 23 bX24 31 n 21 Ch 2 Fn 1 Status Low Byte Ch 2 Fn 2 Status High Byte bX32 39 bX40 47 n 22 Output 0 Status Low Byte Output 1 Status High Byte bX48 55 bX56 63 n 23 Output 2 Status tn B Output 3 Status High Byte bX64 71 bX72 79 bx80 87 bx88 95 n 24 System Functions Read Write CTRIO Internal Registers see p 6 6 for bit definitions 44 Total Input n Parameter Definitions Parameter values are in Decimal format Parameter 1 Contents DWORD Configured Function from CTRIO Workbench Bytes Parameter 2 Contents DWORD
162. tLogic PLC Wi CTRIO WB 2 EBC WinPLC fifi cTRIO we 2 Offline CTRIO WB 2 PBC Location C LLLI HER akizi Cm C Caen Moin odds ee Carts Ope ens ta tate IM Som Tam I Mae Seam Ton LJ Com ae passu LL ZEN Swane Satis Mant J dh PP Cm cnr t Facts pansies Cioe ime ue Out v Marta Regen mem uM One Oder ux S fh tan ind a A Corte remsen Tai Backes Wue was Dant One Coo tola Pent o Toa Pus Tte Cort ta Aerin taa Pss Plin oe Counter I O User Manual Chapter 3 Introduction to CTRIO Workbench a 3 4 PBC DEVNETS and MODBUS Users Gura 5 You will need to connect your PC to the RJ12 serial port on BE ERM Workbench the PBC DEVNETS or MODBUS interface device CTRIO Workbench DirectLogic PLC Access the various support versions at Bi CTRIO Workbench EBC WinPLC 2 Net dit Start Programs AutomationDirect Tools CTRIO Workbench or in the DzrectSOFT32 Launch Window Utilities menu as shown on the previous page Select the appropriate DBWin32 Logger i CTRIO WB 2 DirectLogic PLC Ri CTRIO WB 2 EBC WinPLC Workbench version OIM ee s You will be prompted to establish a serial link to your CTRIO FAKEN ES module s a aida Come LC Cont Meche Mode siuna Corta Com ns Select the PC serial WEN ET pm eene Sean T port Workbench will m ERES Cm Boota vnm use to connect to the 5 m oam
163. ter 8 DirectLogic Programming Examples Run to Limit Mode The following example program loads and executes a Run to Limit Mode pulse profile Turn on CO to run the profile CTRIO input C or D must be assigned to Limit for this profile DirectSOFT 32 First Scan SPO Load Run to Limit Mode 0x21 Hex Command Code Register Initialize Settings co Target Velocity 2 J Decimal This rung loads the Target Velocity the Limit Input and Edge andDuty Parameter 1 Cycle into the Parameter registers Run Frequency 0 specifies Rising Edge Chi C 50 Duty Cycle Hex Parameter 2 register Edge Input Duty Cycle B2056 7 SET Process Command C1 Initialize Settings SET Complete Set Direction C2 B2056 4 3 c OUT Direction Initialize Settings Command Command Complete Complete Error This rung waits C1 B2022 7 B2022 6 B2056 7 for the 4 RST Process Command GOmmmand eee bit with no ai ee Command Error SET Enable Output pefore Enabling the Output Initialize Settings CO C1 5 RST Initialize Settings This rung stops the pulse oe output by disabling the B2056 0 Enable Output bit RST Enable Output 6 END Counter I O User Manual 8 7 Chapter 8 DirectLOGIC Logic Programming Examples Run to Position Mode The following example program loads and executes a Run to Position Mode pulse profile Turn on CO to run the pulse profile DirectSOFT 32 First Scan SPO
164. that the module is in program mode CPU and CTRIO Compatibility Chart PLC CPU Firmware DirectSOFT32 v 4 60 or later v 4 0 Build 16 or later v 1 40 or later v 4 0 Build 16 or later Updated firmware versions can be downloaded from our web site at www automationdirect com 2 2 Counter I O User Manual Chapter 2 Installation and Field Wiring a sil Setting HO CTRIO Jumpers The module s internal jumpers must be set to the High Side Common position for high side switching sourcing outputs or to the Low Side Common position for low side switching sinking outputs The sink source jumper selection sets both outputs to the same option Source operation is the factory default setting di Lr Al E ES E E i HI D a i Q O Q O oboo e ec eo Jumper Selections Sourcing Outputs Sinking Outputs eioojoo OOO Oj COO OO OOO O9 High Common position Low Common position for switching the high for switching the low side side of a DC load of a DC load Counter I O User Manual 2 3 Chapter 2 Installation and Field Wiring a M M Wiring the HO CTRIO Module The HO CTRIO module has one input channel consisting of 4 optically isolated input points pts A D on comm
165. the OUT on Parameter 1 Profile Dynamic Positioning profile File Number c1 L PD Initialize Settings Complete Initialize Settings Complete C1 B2056 7 3 SET Process Command C3 Go to Position Change Complete Command Command Complete Error B20227 B20226 B2056 7 4 L RST Process Command ase als rng hare un OO omplete bit with no Comman SET Enable Output Error before Enabling the Output Go to Position Start B2056 1 RST Go to Position Go to Position Enable Start Bit Output 5 Y ail DOr so Target Pulse Count Position This rung loads the Target Pulse Count OUTD nn Parameter 3 Target Position into Parameter Pulse Count 3 register C3 Go to Position L PD Go to Position Change Complete Change Complete P a SET Go to Position Tli rung starts the pulse output to the a Position Count specified in Parameter 3 Initialize Settings co B2056 0 o O MF RST Enable Output This run stops the pulse output B2056 7 by disabling the Enable Output bit RST Process Command W also resets the position count to 8 END 8 4 Counter I O User Manual Chapter 8 DirectLogic Programming Examples nN Dynamic Velocity The following example program executes a Dynamic Velocity pulse profile Turn CO on to load the profile number process the command and enable the output The Target Velocity needs to be specified inV3000
166. unction that will scale signals to desired engineering units switch between the CTRIO s Program mode and Run mode monitor I O status and functions and have diagnostic control of module functions The CTRIO Workbench utility ships with the CTRIO User Manual You can also download the latest version free at the Host Engineering Web site www hosteng com Installing CTRIO Workbench The CTRIO Workbench utility installs directly from its executable file Double click on the Setup exe icon The install shield will step you through the installation process The utility installs into C HAPTools directory Several support versions of CTRIO Workbench are loaded on your PC during the installation One is for DzrectLOGIC PLC users DirectSoft32 Rel 3 0C Build 71 or later is required The other support versions are for WinPLC EBC PBC DEVNETS and MODBUS users An Offline support version is also available to create module configuration files offline Getting Started with CTRIO Workbench Several paths are available to start CTRIO Workbench All users will find CTRIO Workbench at Start gt Programs gt AutomationDirect Tools CTRIO Workbench DirectSOFT32 users will find CTRIO Workbench under PLC menu Tools CTRIO Workbench and in the DzrectSOFT32 Launch Window Utilities menu Offline CTRIO Configuration CEA 2com nic ueites A complete CTRIO configuration file cwb 8 E Sq i pane i CTRIO WB 2 DirectLogic PLC can be created
167. unting or timing Ch1 F2 blinks when Channel 1 Function 2 is counting or timing Ch2 F1 blinks when Channel 2 Function 1 is counting or timing Ch2 F2 blinks when Channel 2 Function 2 is counting or timing YO Y3 E Follow actual output state ON output is passing current Due to the multiplexed design of the DL405 LED matrix OFF state LEDs may appear to blink ON slightly This is to be expected and does not necessarily indicate a transient condition of the function corresponding to the LED Counter I O User Manual 1 9 Chapter 1 Introduction a T1H CTRIO LED Indicators T1H CTRIO LED Descriptions a Module OK TiH CTRIO cr CHI CH2 oK ERA CH User Program Error Channel 1 Status Channel 2 Status Channel 1 A D Input Status 1A1B 1010 17 yo Y1 2A 2B 2C 20 A311 r IY ILLU Channel 2 A D Input Status 0952004 T x WEEN Zd Output Status T1H CTRIO LED Diagnostic Definitions OK ER Description ON OFF All is well RUN Mode ON ON Hardware Failure Blinking Blinking Boot Mode Used for Field OS Upgrades Blinking OFF Program Mode OFF Blinking Module Self diagnostic Failure OFF ON Module Error Due to Watchdog Timeout OFF OFF No Power to Module T1H CTRIO LED Diagnostic Definitions Blinks when Channel 1 Function 1 is counting or timing Blinks
168. utes Sample Time 1000 jms a c value in engineering units hows Scaled Value 300 As an example let s say you have a 1 000 Calc Options l Data Smoothing pulse revolution encoder and you want to Calc Intervet 0 ms py eae use it to measure RPM of the encoder mn j _ shaft You would enter 1 000 for the Counts unit and minutes as the Time Base im A check using the calculator over a sample ESA Ea time of 1 000 ms 1 second reveals that 5 000 counts equals 300RPM 5000 counts 1000 counts per rev 5 revolutions 5 revolutions 1 sec x 60 sec 1 minute 300 RPM Data Smoothing allows rolling averages to be taken to calculate a value Min 1 sample max 25 samples in the rolling average Counter I O User Manual u 13 Chapter 4 Configuring the CTRIO Inputs Using the Scaling Wizard with Timer Functions Scaling raw signals to engineering units is accomplished using the Scaling Wizard Start the Scaling Wizard by clicking the ruler button on the Configure IO dialog Function 2 This button appears only after you select one of the Counter or Timer functions Edge Timer J Edge in Free Run Interval Scaling Timer To select Interval Scaling click the radio button beside the word Interval Now click Next to move to the Output Settings dialog Scaling Wizard Output Settings x On the Output Settings dialog you will notice the field for engine
169. utput circuit is 1A 4 User Bus 1 and User Bus 2 are each an independent 8 wiring terminal bus They can be used for additional power rail connections Counter I O User Manual T1H CTRIO Input Field Wiring NPN Device Output Input Output Channels Chapter 2 Installation and Field Wiring PNP Device NPN Device Output Output PNP Device Output User Bus Terminals no internal connection to CTRIO Q O O O O USER BUS 2 ojojo T1H CTRIO Output Field Wiring CTRIO Source To Load L From YO USER BUS 1 1M 24VDC USER BUS 2 2M OVDC Input Output Channels Channel Commons Q 2 2 2 2 2D Y2 Y2 Y3 Y3 iiomo e e e je o 2M C2 C2 C3 C3 em ad in rom Loa U U U U U esc L User Bus Terminals no internal connection to CTRIO o O O O O USER BUS 2
170. uus rh Ey he rem ey edenema aai Ge e TP e bre e 5 5 Creating and Using the Output Preset Tables 0 0 0 00 e ee eee 5 6 Using the Discrete Outputs in Level Mode 0 0 0 cece cc eee 5 7 Pulse Outputs sccccc cece cede das sac aie RR ORARE CORRER nee eee nea eee 5 8 Creating Pulse Output Profile Tables 0 0 scele 5 8 Trapezoidal Profile eis sape rte hh E ee 5 9 S Curve Profile seus rure ga RR RERO RE RERO AURA A 5 10 Symmetrical S Curve Profile ccc ccc eee n 5 11 Dynamic Positioning Profile sees nn 5 12 Dynamic Velocity Profile 00084 rere enr TEC aiaa 5 13 Home Search Profile 1 ssec ehh deca ese Rh ee 5 14 Home Search Routines uou reb e eee s arre pos ang oe eR 5 15 Additional Pulse Profiles 0 cc cece eee eee Rh hh hn 5 16 iv I Counter I O User Manual Table of Contents E i Chapter 6 Program Control Input n Parameter Definitions 0 0 I 6 2 Input Memory Map for Data Transfers from CTRIO to CPU 6 2 Output Status Bit Definitions Pulse Output 00 eee eee 6 3 Output Status Bit Definitions for Preset Table Control 04 6 3 Input Function Status Bit Definitions llle 6 3 Output n Parameter Definitions llle 6 4 Output Memory Map for Data Transfers from CPU to CTRIO 6 4 Output n Parameter Definitions
171. when Channel 2 Function 1 is counting or timing Follow actual output state ON output is passing current 1 1 0 Counter I O User Manual INSTALLATION AND FIELD WIRING In This Chapter Installing the HO CTRIO Module 1 1 2 eee RI 2 2 Settirig the HO CTRIO JUMPERS sg ruere eet rr pA date RR RE RI EI tains 2 3 Wiring the HO CTRIO Module i e eR hn ERR ERR E awe Rhone 2 4 HO CTRIO Quadrature Encoder Wiring Example 000 0 eee eee eee eee 2 5 HO CTRIO TTL Quadrature Encoder Wiring Example 00 0 eee eee eee eee eee 2 6 HO CTRIO TTL Input Wiring Example 0 0 0 2 7 HO CTRIO Output Wiring Schematic css ssor saniser an a a R ene eee 2 8 HO CTRIO Stepper Drive Wiring Example 00 2 9 Installing the H2 CTRIO Module 1 1 2 cee 2 10 Setting the H2 CTRIO Jumpers eerte RR A eed CR ER E RUE e eges 2 11 Wiring the H2 CTRIO Module sereni istma suremiseen RE RR ERR ERE ER 2 12 H2 CTRIO Quadrature Encoder Wiring Example leleeeeeeee 2 13 H2 CTRIO TTL Quadrature Encoder Wiring Example 000 cece eee ee eee 2 14 H2 CTRIO TTL Input Wiring Example 0 00 cee eee 2 15 H2 CTRIO Output Wiring Schematic 0 cece eee eee 2 16 H2 CTRIO Stepper Drive Wiring Example a a E E E A 2 17 Installing the H4 CTRIO Module 2 0 cee eee 2 18 Wiring the H4 CTRIO Module reet rt le aie wrk m EU Ae ERR ETE TER 2 19 H4 CTRIO Quadrature En
172. will stay on until the level drops below 90 where it will turn OFF OFF when less condition example Consider a Discrete Output set to turn OFF when less at 100 When the level gets to 100 the output turns OFF If the level rises again the output will stay OFF until the level gets to 110 where it will turn ON Edit the behavior of a Discrete Output triggered by a Rate Level by using the Edit Level Response Command Command Code 30Hex The Level Behavior setting for Parameter 1 is given in the table below Level Behavior for Discrete Output Parameter 1 Contents ON when greater than Level Rate setting 0000 Hex ON when less than Level Rate setting 0080 Hex OFF when greater than Level Rate setting 0001 Hex OFF when less than Level Rate setting 0081 Hex The Deadband is written to Parameter 2 as a x10 integer one implied decimal position To achieve a 10 096 deadband the control program needs to write 100 decimal 64 Hex to Parameter 2 The Level Rate setting is written to Parameter 3 in the same format as Input Parameter 1 of the CTRIO Function to which this Discrete Output has been assigned Counter I O User Manual 6 25 Chapter 6 Program Control Load Preset Table Flowchart The flowchart below provides the logical sequence necessary to load and execute a discrete output preset table Load 10 into Command Code Verify that the Hex CTRIO is configured correctly Load Table
173. ype and Offset WinPLC Address for Inputs Configured Profile from CTRIO Workbench Parameter 1 Contents WORD Parameter 2 Contents WORD EBC PBC DEVNETS MODBUS DirectLOGIC BI Format dwY0 n 0 Output 0 Parameter 3 DWord 4 dwY1 n 2 Output 1 Parameter 3 DWord 4 dwY2 n 4 Output 2 Parameter 3 DWord 4 dwY3 n 6 Output 3 Parameter 3 DWord 4 wYO n 10 Output 0 Command Word 2 wY1 n 11 Output 0 Parameter 1 Word 2 wY2 n 12 Output 0 Parameter 2 Word 2 wY3 n 13 Output 1 Command Word 2 wY4 n 14 Output 1 Parameter 1 Word 2 wY5 n 15 Output 1 Parameter 2 Word 2 wY6 n 16 Output 2 Command Word 2 wY7 n 17 Output 2 Parameter 1 Word 2 wY8 n 20 Output 2 Parameter 2 Word 2 wY9 n 21 Output 3 Command Word 2 wY10 n 22 Output 3 Parameter 1 Word 2 wY11 n 23 Output 3 Parameter 2 Word 2 v8 15 m24 Ch 1 2 Control High Byte Woa 2 DY24 51 m25 Ghz Control High Bwe Word Ri LENN NEC DY56 83 m27 Output 3 Control ign Bye Word en System Functions bx80 87 n 30 Read Write CTRIO Internal Registers DWord bx33 95 see p 6 6 for bit definitions A A 52 Total Output n Parameter Definitions Parameters are in decimal format Bytes Parameter 3 Contents DWORD Trapezoidal File of stored profile Not Used Not Used S Curve Symmetrical S Curve File of stored profile Not Used Not Used Dynamic Positioning File of stored pro
174. zero The program will need to turn off the Enable Timer Capture bit and confirm the Timer Capture Starting bit Timer Capture Complete bit and the Timeout bit reset before attempting the next time capture cycle Free Run Timers The Timeout Bit is set if the time that it takes the CTRIO to see the configured input edge exceeds the specified Timeout Period The Timeout bit resets when the next timing cycle begins The Previous Time register value is reset to zero Once timing has been initiated if the time before the CTRIO sees the next configured edge exceeds the specified Timeout Period the Timeout bit is set The Timer register values are reset to zero The Timeout bit resets when the next timing cycle begins Counter I O User Manual 6 2 1 Chapter 6 Program Control SY Pulse Catch Input Function When the Enable Pulse Catch bit is ON and the configured input edge occurs the CTRIO will begin timing and the Pulse Catch Starting bit will turn ON If the input signal remains active for the specified qualification period the Pulse Catch Output Pulse State bit will turn ON for the configured duration If a discrete output is assigned to follow the pulse state it will also turn ON for the configured duration Unlike the Count or Time capture the Pulse Catch function is automatically reset as long as the Enable Pulse Catch bit remains ON PLC Control Outputs Base Addr V2030 Bit of Word PLC Status Inputs Base Addr V2000
Download Pdf Manuals
Related Search
Related Contents
OPERATING INSTRUCTIONS: - Great Lakes Metal Detecting DISCOVR-e USER MANUAL Vanderbilt University Human EM6260 manually d bedienungsanleitung timer 3-zeilig edt 9000 Citizen Systems 3541 Printer User Manual Chief SLB185 KIFT – Autonomous Vehicle - Department of Electrical Engineering ショックリレー FUMOIR FUMOIR Copyright © All rights reserved.
Failed to retrieve file