Home
SYSMAC CS/CJ/CP Series SYSMAC One NSJ Series
Contents
1. x10 x 10 R J x 10 x 10 x 10 x 10 x 108 x 107 x 10 x 10 x Fi JS Unit No Header Beginning word No of words FCS Terminator BCD code 0000 to 0959 0001 to 0960 Response Format x10 x10 9 R J x 16 x 16 x 16 x 167 x 16 x 16 x a oo Unit No Header End code Read data 1 word FOS Terminator BCD code Read data for number of words read Limitations The text portion of the response s first frame can contain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Execution Conditions Commands Responses PLC Mode PLC Mode UM Area Single Multiple Single Multiple RUN MON PROG Write protected Read protected ox No OK OK OK OK OK OK OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if the specified words exceed the data area boundaries or are not specified in BCD or if the number of words
2. x10 x 10 M E A Unit No BCD Header FCS Terminator l code Response Format x 10 x 10 M I x16 x16 x N Unit No BCD Header End code FCS Terminator code Limitations The UM write protected end code for this command is different from that of the other commands Execution Conditions Commands Responses PiCmoas Umaea Single Multiple Single Multiple RUN MON PROG Write protected Read protected ox m x No no No OK o OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect End code Hex 00 Normal completion Not executable in RUN mode Not executable in MONITOR mode UM write protected 13 FCS error 144 C mode Command Details Section 4 3 End code Hex 4 3 35 REGISTER I O MEMORY QQMR Pre registers to the table all of the I O memory area bits words and timers counters that are to be read The registered contents are retained until they are overwritten or until the power is cut off so they can be read by QQIR Refer to 4 3 36 READ I O MEMORY QQIR Command Format nr eto Q QIM R x 10 x 10 x 10 x 10 l is Unit No BCD Header code Area classification Word address Bit word Data break Bit word 00 to 15 Bit designation BCD Word Word data desi
3. x10 x10 R x 10 x 10 x 10 x 10 OP1 OP2 OP3 OP4 x 10 x 10 x 10 x 10 ke J N Unit No BCD Header Program address Timer counter type Timer counter FCS Terminator code BCD yP number BCD Instruction name Timer counter type Timer counter Char Char Char Char number BCD acter 1 acter 2 acter 3 acter 4 HIGH SPEED COUNTER T 0000 to 2047 WAIT TIMER WATT 7 m w COUNTER WAIT e o e wo HIGH SPEED TIER T o Mmo oo FToTALZINGTIMER M o o Mo REVERSIBLE COUNTER C N m R mer F h m o Note SP represents a space 20 Hex 122 C mode Command Details Section 4 3 Response Format x 16 x 169 OP1 OP2 OP3 OP4 x 10 x 102 x10 x 109 Unit No BCD Header End code Constant area SV word address FCS Terminator code classification Classification SV or word eos ter 1 ter 2 ter 3 ter 4 Cost C C BP ooo a8 aio J 86 osas ARR E 0000 0869 mooo o e e i Wa wf 08 0000 fo 05 ime 08 00000 2087 amr fe Jf Yes oar mo o o m e C SP 0000 to 9999 current x E SP 0000 to 9999 EM indirect current SP 0000 to 9999 bank EMbarks0t0C E m lowe SP 0000109999 ai indirect banks 0 to Hopo e 0000 to 9999 pea paer p p fem fen foes Index register marec R 6P 000010 0015 Note SP represents a space 20 Hex Parameters Program Address Command Designates the program address i
4. Unit No BCD ena End code FCS Terminator Execution Conditions Commands Responses PLC Mode waa Single wutipie Single _ wuttpie RUN won PROG Writerprotected Readkprotected Cmo End Codes An end code of 14 format error will be returned if the length of the command is incorrect or if the bit is designated as other than 00 by the TIM CNT desig nation An end code of 15 entry number data error will be returned if the area classi fication word address or bit parameter setting is out of range including hexa decimal data 00 nomaonion 137 C mode Command Details Section 4 3 4 3 27 FORCED RESET KR Force resets the operating status of operands Only one bit at a time can be force set Command Format x10 x 10 K R OP1 OP2 OP3 OP4 x 102 x102 x10 x 10 x 10 x 10 x d Unit No BCD a Area classification Word address Bit FCS Terminator codqe Classifica Area classification Word tion Charac Charac Charac Charac address ter 1 ter 2 ter 3 ter 4 co fe l O 6P 0000to6143 00to15 C E SP SP 0000 to 0511 00 to15 o SP 0000 to 0511 00 to 15 SP SP a a os ee Note SP represents a space 20 Hex Response Format x 10 x100 K R x 16 x 16 Unit No BCD Header End code FCS Terminator l code
5. x 10 x100 W OP1 OP2 OP3 OP4 x 10 x 102x 10 x 109 x 10 x 102x 10 x 10 x d Unit No BCD Header Timer counter type Timer counter SV 0000 to 9999 BCD FCS Terminator code number Instruction name Timer counter type Timer counter Char Char Char Char number BCD acter 1 acter 2 acter 3 acter 4 HIGH SPEED TIMER T M H W 0000 to 2047 WAIT merw o o m wo HIGH SPEED TIMER T O M HWH TOTALIZING TIMER T T B M yE a o ee e a E SP COUNTER Note SP represents a space 20 Hex Response Format x10 x109 W x16 x 169 x d e es es 2 a Unit No BCD eS End code FCS Terminator Parameters Timer Counter Type Command Designate the timer counter instruction type for changing the constant SV Timer Counter Number Command Designate in four digits BCD the timer counter instruction number for chang ing the constant SV Index register designation is not possible New Constant SV Command Designate the new constant SV in four digits hexadecimal Limitations Timers T2048 to T4095 and counters C2048 to C4095 cannot be read The command cannot be executed unless the SV is a constant If there are multiple relevant instructions in cyclic task 0 a search will be con ducted from program address 0 and the first instruction found will be read The SV can be changed only in cyclic task 0 If the SV is a DM o
6. FINS network Network address N Serial Communications Unit Board E g Unit number 0 port 1 PLC No routing tables required to treat serial communications path as a network Address to distinguish standard PLC 1 Network address To N 2 Node address To m nications Unit CPU Unit 3 Unit address Serial communications path iy ee port ae CompoWay F Modbus address g ex _ Target OMRON Component or Modbus Slave 81 Serial Gateway Overview Section 3 6 With Routing Tables Specify the addresses as shown in the following example Address Specification Address Contents Example 1 Serial communications A path network address Remote node address 2 Local PLC internal communications 00 hex 80 hex 128 decimal Remote unit address 3 Serial port unit address e from Unit No 0 port Remote network address FINS network Serial Communications Unit Board VA il E g Unit number 0 port 1 2 Node address Local PLC internal communications To 00 hex PLC Routing tables for treating serial communications path as a network Unit b Network nit number address 80 hex 128 decimal A Calculated from Unit No 0 port 1 D A O F ES oo O5 Q 28 ie 3 Unit address Be herpes 3 z Serial communications path To serial port unit poWay F Modbus 1 Network address address To serial communications path network address A e
7. Command code Parameter Response Format The response format is as follows when the parameter is 00 hex 06 20 Command End code code 195 FINS Commands Section 5 3 The response format is as follows when the parameter is 01 hex read 06 20 ae End code Average cycle time Max cycle time Min cycle time code Parameters Parameter code command Specify the operations for this command as follows 00 hex Initializes the cycle time 01 hex Reads the average maximum and minimum cycle time Average cycle time response The CPU Unit continuously calculates the cycle time and remembers the pre vious eight cycle times The average cycle times is the average of these eight cycle times expressed as four bytes of binary data in 0 1 ms incre ments The average cycle time is obtained as follows Average cycle time Sum of 8 previous cycle times 8 In the following example the average cycle time is 65 0 ms 00 00 02 8A Maximum cycle time The maximum cycle time is the maximum value of the cycle time measured after the cycle time initialize request is received It is expressed in four binary bytes in increments of 0 1 ms Minimum cycle time The minimum cycle time is found in the same way as the maximum cycle time described above End code response Refer to 5 1 3 End Codes for information on end codes Comments The maximum
8. Execution Conditions Commands Responses PiCmoas Umawa single Multiple Single Multiple RUN MON PROG Write protected Read protected_ OK No OK No No OK OK OK OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect or if the bit is designated as other than 00 by the TIM CNT desig nation An end code of 15 entry number data error will be returned if the area classi fication word address or bit parameter setting is out of range including hexa decimal data 00 oman 138 C mode Command Details Section 4 3 4 3 28 MULTIPLE FORCED SET RESET FK Force sets resets or cancels the operating status of operands Multiple bits can be simultaneously force set reset or canceled Command Format x 10 x 109 F K OP1 OP2 OP3 OP4 x 10 x 102 x 10 x 10 Unit No BCD Bias Area classification Word address code te m Forced set reset cancel ae X lt l TTT FCS Terminator Bt 15 14 13 12 11 10 01 00 0000 Ignore 3 2 11 0 001 0 Designates o 0011 Designates 1 O 100 Designates force reset O 10 1 Designates force set 1000 Designates force set reset cancel Classification Area classification Word oO eo ea 0000 to 6143 eR RSP SP 0000 to 0198 wR pw a e e oone mo h R e e ft 08 EA Comer Je N P
9. Error processing PRINT iBRL i ERL iERRi ERR CHOSE a END FINS Commands with Host Link Protocol Section 3 5 Programming Example for Host Computer Side BASIC Reception LR KKKKKKKKKKKKKKKKKKKKKKKKKK KKK KKK KKK KKK i CS1W SCU21 Serial Communications Unit i Command to Host Computer RECV 098 i Sample Reception Program LR KK KKKKKKKKKKKKKKKKKKKKK KKK KKK KKK KKK KKK Initial Settings CLOSE 1 ON ERROR GOTO EROPE DIM CHDATAS 300 i Data array declaration CHDATAS 0 LO000TsCHDATAS I t112Ti Te CHDATAS 2 122223 CHDATAS 3 133331 CHDATAS 4 7144441 CHDATAS 5 i15555i OPEN iCOM E73i AS 1 i Opens port ol Main Process RESPDATAS 77 INPUT 1 COMMANDS i Receives data from PLC line TS LEFTS COMMANDS LEN COMMANDS 3 Checks FCS GOSUB FCS IF FCSS lt gt MIDS COMMANDS LEN COMMANDS 2 2 THEN ENDCODES 110041 GOTO RESPONSE CMNDCODES MIDS COMMANDS 27 4 Checks command code IF CMNDCODES lt gt i10101i THEN ENDCODES 704017 GOTO RESPONSE FOR I 0 TO VAL i1 amp Hi MIDS COMMANDS 39 4 1 i Sets No of read elements RESPDATAS RESPDATAS CHDATAS I NEXT I PRINT Send datai RESPDATAS ENDCODES 700007 Sets end code to 0000 Hs RESPONSE RSV MID COMMAND 9 2 DA MID COMMAND 19 6 SAS MIDS COMMANDS 13 6 Swaps DNA DA1 DA2 SIDS MIDS COMMA
10. The following codes can be used only when the CPU Unit is in PROGRAM mode Error code hex FFFF All errors cleared 809F Cycle time too long 80C0 to I O bus error This error occurs when there is an error in an I O bus 80C7 check or a Unit has been removed or added when power is turned on to the PLC 80E0 I O setting error This error occurs if the I O table differs from actual O points in the System 80E1 I O points overflow 80E9 Duplication error This error occurs if the same unit number is assigned to more than one Unit or the same word is allocated more than once 80EA Basic I O word duplication resulting from rack first word settings 80F0 Memory error This error occurs if an error is found in the user pro gram PLC Setup Registered I O Tables routing tables or CPU Bus Unit Setup memory 82F0 Fatal Inner Board error C101 to FALS 007 executed C2FF End code response Refer to 5 7 3 End Codes for information on end codes Comments If the specified error is not occurring a normal end code will be returned lf the present error is one that can only be cleared when the CPU Unit is in PROGRAM mode it will not be possible to clear it in MONITOR or RUN mode The cause of the error must be removed before executing ERROR CLEAR command code 2101 or the same error will immediately occur again after the command is executed 5 3 28 ERROR LOG READ 21 02 Reads the PLC s error log Access right
11. o 22 01 ee Command Disk No Beginning No of Directory Absolute directory code file position files length path 22 01 26 bytes 22 bytes 22 bytes Command End code Disk data No of File data gt gt File data code files a AA Read file data Parameters Disk number command The classification of the file memory with the file name to be read is specified as follows 8000 hex Memory card 8001 hex EM file memory Beginning file position command The first file to be read The first file number is 0000 hex Number of files command The number of file names to be read between 0001 and 0014 hex A maxi mum number of 20 file names can be read at one time If there are more file names than that add one to the number of response files when specifying the next beginning file position To read disk data only specify 0000 hex for both the beginning file position and the number of file names A response will be returned for up to the number of files read Directory length Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of t
12. End code Hox 00 Normal completion Frame length error Not executable due to CPU Unit CPU error 4 3 24 STATUS CHANGE SC Changes the CPU Unit operating mode Command Format x10 x10 S C x 16 x 16 x od Unit No BCD sas Mode data FCS Terminator code Mode data consists of two digits one byte hexadecimal With the leftmost two bits specify the CPU Unit operating mode Set all of the remaining bits to 0 x 16 x 16 Bit 7 6 5 4 3 2 1 0 010 1001010 Bit Operation mode 11 0 0 0 PROGRAM mode 1 0 MONITOR mode This area is different 1 1 RUN mode from that of STATUS READ Response Format x10 x100 S C x16 x 169 x Unit No BCD cee End code FCS Terminator Limitations RUN mode and MONITOR mode designations differ from those in STATUS READ 134 C mode Command Details Section 4 3 Execution Conditions Commands Responses PiCmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected_ p OK No OK No OK x x KK End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the mode data is out of range o Normalcompletion SOS 4 3 25 ERROR READ MF Reads CPU
13. CS2H CPUL JL EIP built in ports CJ2M CPU1L built in ports CJ2M CPU3L Serial Option Board CS1G H CPULI_JH built in ports CS1G H CPULILI EV1 built in ports CS1D CPULILIH built in ports CJ1G H CPULIL_IH built in ports CJ1G CPULIL built in ports CJ1M CPULJL built in ports CS1W SCB21 V1 41 V1 unit version Pre Ver 1 2 Serial Communications Board ports CS1W SCU21 V1 unit version Pre Ver 1 2 Serial Communica tions Unit ports CJ1W SCU21 41 unit version Pre Ver 1 2 Serial Communica tions Unit ports CVM1 CPUL IL built in 30 words ports CV CPULIL built in ports CV500 LK201 Host Link Unit Data words per frame 1 tframe Other frames 31 words Precautions when Reusing Programs from Earlier Models CS CJ Series CVM1 and CV Series C series Host Link Units Other Boards and Units Section 2 4 Words per Frame for C mode RG Command Data words per frame 1 tframe Other frames C200H LK101 LK201 89 words 89 aaa LK202 Host Link Units C500 LK103 LK203 Host Link Units 3G2A5 LK101 LK201 Host Link Units 3G2A6 LK101 LK201 LK202 Host Link Units SRM1 built in ports CPM1 built in ports CPM1A built in ports CQM1 CPUL built in ports CQM1H CPUL IL built in ports CQM1H SCBL IL built in ports C200HX HG HE CPULJLI built in ports C200HW COML IL Communications Board ports CS2H CPUL IL EIP built in ports CJ2M CPU1L built in
14. Number of Bytes of Command Data Set the number of bytes of command data including the command code that are stored from the first command word Number of Bytes of Response Data Set the number of bytes of response data including command code and end code that are stored from the first response word Serial Port Number Set the serial port number to which the host computer is connected Destination Network Address Set the network address of the destination node i e the computer Set 00 to send communications within the local network Destination Node Address Set the node address of the destination node i e the computer Set 00 when transmitting within the local PLC Destination Unit Address Set the unit address of the Unit to which the host computer is connected Response Setting Normally this bit is set to O to require a response When a response is not required set this bit to 1 Communications Port Number Set the port number in the CPU Unit which will transmit CMND 490 54 FINS Commands with Host Link Protocol Section 3 5 Number of Retries Set the maximum number of times CMND 490 is to be resent if no re sponse is returned Response Monitor Time If the Response Setting is set to require a response set the response mon itor time Note If response data longer than that set in the Number of Bytes of Response Data is returned all extra response data will not be stored If response data shor
15. x 10 x 102 x 10 x 10 OP1 OP2 OP3 OP4 Constant area classification New SV word address FCS Terminator Instruction name Timer counter type Timer counter Char Char Char Char number acter 1 acter 2 acter 3 acter 4 HIGH SPEED TIMER 0000 to 2047 WAIT TIMERWAIT ss WAIT an e HIGH SPEED TIMER T TOTALIZING TIMER T 128 C mode Command Details Response Format Parameters Limitations Note Note Section 4 3 SP represents a space 20 Hex Classification SV or word Charac Charac Charac Charac address ECD nsan e o n e oo co 008 owes AR a a e SP 000070 0950 HR __ _ SP _ 1P 000010 0511 WR w__ R__ SP SP 000010 0511 Timer Tf M___ 8 0000 10 2047 Counter n m SP 000010 2047 DM gt m se 08 DM nde o m heP 000079090 EMourentbak E m 6P heP 0000109999 EM indirect current P 0000 to 9999 bank EM indirect 010 Dataregiter b R 6m em 0000005 indexregister R lem 00000 0015 SP represents a space 20 Hex x10 x100 W x 16 x 16 x wo A A a A y Unit No BCD M End code FCS Terminator code Program Address Command Designate the program address in four digits decimal BCD for beginning the search for the specified timer counter instruction Timer Counter Type Command Designate the timer counter instruction type for changing the constant SV
16. 2 3 4 5 6 7 s8 o9 a eic od e F ood Hexadecimal 81 85 89 sD 91 95 99 oD A1 a5 A9 AD B1 B5 B9 BD ES e Sending Modbus RTU Commands with the CMND Instruction e Set FINS command code 2804 hex CONVERT TO MODBUS RTU COMMAND in S e Set the following parameters starting at S 1 with the leftmost byte first see note Slave address 1 byte Function code 1 byte and the communications data n bytes 234 FINS Commands Section 5 3 Note For Modbus RTU set the Modbus RTU Slave address 1 byte in the leftmost byte of S 1 and the function code 1 byte in the rightmost byte of S 1 5 3 48 CONVERT TO MODBUS ASCII COMMAND 28 05 Execution Conditions Command Format Response Format Parameters When this command is sent to a serial port on a Serial Communications Unit or Board Ver 1 2 or later the Serial Communications Unit Board removes the FINS header and sends the enclosed Modbus ASCII command With this command OMRON components connected to a PLC through Mod bus ASCIl communications can be accessed from a PLC or PT by sending a FINS message containing a Modbus ASCIl command Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode 28 05 Command Slave Function Communications code address code data ASCII ASCII ASCII 28 05 Command End code Slave Fu
17. Area forced sta CIO 6143 17FF00 O9FBOO tus a 255515 Work F1 W000 to 000000 to Area W511 01FFOO Holding H0O00 to H511 000000 to Bit Area 01FF00 E E Timer Completion T0000 to 000000 to T0000 to 000000 to Area Flag T4095 OFFFOO T2047 T0000 07FF00 to T1023 000000 to 03FF00 Counter CNT C0000 to 800000 to Area C4095 8FFF00 C0000 to 080000 to C2047 OFFFOO C0000 to 080000to C1023 OBFFOO 165 Designating Command Parameters Data type CS CJ mode Memory Memory area Memory Memory Memory area address address address 41 T0000 to T2047 T0000 to T1023 Timer Completion Area Flag with forced sta Counter CNT Area Timer TIM Area Counter CNT Area EM Area C0000 to C2047 C0000 to C1023 T0000 to 000000 to T4095 OFFFOO C0000 to 800000 to C4095 8FFFOO T0000 to 000000 to T4095 OFFFOO C0000 to 800000 to C4095 8FFFOO 81 T0000 to T2047 T0000 to T1023 C0000 to C2047 C0000 to 3 023 D0000000 to 000000 to D3276715 7FFFOF D00000 to 000000 to D32767 7FFFOO 20 to 2F EO 0000000 to 3276715 to EF_0000000 to 3276715 EO to E8 E10_ 0000000 000000 to to 3276715 7FFFOF to E18 0000000 O to 3276715 AO to AF E0_00000 to 000000 to t 32767 7FFF00 to See EF_00000 to 60 to E10_00000 to 32767 to E18_00000 to 32767 E0000000 to 000000 to E3276715 7FFFOF Word E00000 to 000000 to E32767 7FFFOO rth 7 TKOOOO to 000000 to TKO031
18. Execution Conditions Access right at UM read DIP switch UM Network write other device protection write protection protection Ne o o o o o RUN mode MONITOR mode PROGRAM mode Command Format Laue 22 03 12 bytes Command Diskno Parameter File name File position Data length File data code code Directory Absolute directory length path Response Format Command End code code 215 FINS Commands Parameters Comments Section 5 3 Disk number command The classification of the file memory with the file name to be read is specified as follows 8000 hex Memory card 8001 hex EM file memory Parameter code command As follows 0000 hex Writes a new file If a file with the same name already exists the new file will not be created 0001 hex Writes a new file If a file with the same name already exists it will be overwrit ten 0002 hex Adds data to an existing file 0003 hex Overwrites an existing file File name command Specifies the name of the file to be written For details on the configuration refer to page 168 File position command Specifies the number of bytes from the start of the file from which to start writ ing Files start at 00000000 To create a new file or add data to an existing file soecify 00000000 as the file position Data length command Specifies the nu
19. Responses PiCmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Cox mn ox x x OK ox ox OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if 108 C mode Command Details Section 4 3 the specified words exceed the data area boundaries or are not specified in BCD or if the number of words to read is 0 End code Hex Normal completion 13 FCS error 14 Format error 15 Entry number data error 18 Frame length error i 4 3 5 TIMER COUNTER PV READ RC Reads the contents of the specified number of timer counter PVs present val ues T0000 to T2047 or C0000 to C2047 starting from the specified timer counter Command Format x10 x10 R x 10 10 x10 x10 x 109 x10 x 10 x10 kJ D Unit No BCD Header Beginning word No of words FCS Terminator code Timer 0000 to 2047 0001 to 2048 Counter 2048 to 4095 Response Format x10 x100 R C x 16 x160 x 10 x 10 x 10 x 10 kJ A E Unit No BCD a End code Read data 1 word FCS Terminator Code Read data for number of words read Limitations The text portion of the response s first frame can c
20. SNA 33 source network address 33 Index source node number 34 source unit address 34 startup mode xix status reading 4 150 153 STATUS CHANGE SC 134 STATUS READ MS 133 subdirectories 226 T TEST TS 142 testing 3 101 time data accessing 4 150 153 TIMER COUNTER PV READ RC 109 TIMER COUNTER PV WRITE WC 117 TIMER COUNTER STATUS READ RG 110 TIMER COUNTER SV CHANGE 1 W 127 TIMER COUNTER SV CHANGE 2 W 128 TIMER COUNTER SV CHANGE 3 W 130 TIMER COUNTER SV READ 1 R 121 TIMER COUNTER SV READ 2 R 122 TIMER COUNTER SV READ 3 R 124 timers reading Completion Flag status 177 U V UM read protection 171 undefined command IC 148 volume labels 168 239 Index 240 February 1999 September 1999 Revision History A manual revision code appears as a suffix to the catalog number on the front cover of the manual Cat No W342 E1 15 Revision code The following table outlines the changes made to the manual during each revision Page numbers refer to the previous version Revision code Revised content Original production Page 18 Catalog number corrected for the CQM1 PC Pages 31 117 The S 2 beginning read address for the first command word corrected for CMND 490 Page 26 Page 28 Page 37 Internal communications setting added for DA1 and SA1 Values for node address changed in table Last two sentences removed from SA2 descr
21. SP represents a space 20 Hex Classification Constant area classification SV or word Charac Charac Charac Charac address ter 1 ter 2 ter 3 ter 4 BCD SP 0000 t0 0959 0000 to 9999 0000 to 9999 C R fier 0000 0015 current a EM indirect current bank EM banks 0 to C EM indirect 0 to C naa ragistor Note SP represents a space 20 Hex _ wo woo p e gt C E 131 C mode Command Details Section 4 3 Response Format x10 x10 9 W x 16 x 16 x Unit No BCD End code FCS Terminator Parameters Program Address Command Designate the program address in six digits decimal BCD for beginning the search for the specified timer counter instruction Timer Counter Type Command Designate the timer counter instruction type in ASCII for changing the con stant SV or the word address in which it is stored Timer Counter Number Command Designate in four digits BCD the timer counter instruction number for reading the constant SV Index register designation is not possible Constant Area Classification Command Designate the ASCII characters to express the constant or area classification New SV Word Address Command Designate the newly set constant SV or the word address in which it is stored Limitations Timers T2048 to T4095 and counters C2048 to C4095 cannot be changed If
22. SRC MRES SRES CompoWay F unit ad See note network node aes address address DA2 DNA DA1 etc Serial Serial port port unit allocated address address Node No x 10_ x 102 End code Command Response Text MRC MRES ASCII code 2 bytes Frame before Conversion FINSheader header FINS command command Modbus RTU ern eae Remote Etc ae SRC command section only network unit address address address DNA Communications data n bytes FUNCTION code 1 byte Slave address 1 byte or local network node address Modbus RTU frame Error check CRC 1 byte FUNCTION code 1 byte End silent interval of 3 5 characters See note Communications data n bytes Slave address 1 byte Start silent interval of 3 5 characters See note The silent interval in the Modbus RTU frame is automatically generated by the Serial Communications Board Unit 87 Communications Frames Section 3 7 Response Frame 3 7 3 Modbus ASCll Command Frame Frame before Conversion Frame before Conversion Modbus RTU frame FUNCTION code 1 byte Slave address Start silent eal of 3 5 characters Dyte See note Frame after Conversion FNSheader header Remote Remote Etc node address DA1 e network address DNA Serial port unit address Serial port 00 hex al
23. a 7 nt PLC Setup Area 8010 0000 to 01FF 512 words VO Table Registration Area I O Table Registration Area 8012 0000 to O4FF 1 280 words 0000 to 1F3F g 8000 Routing Table Area E CPU Bus Unit Setup Area 8002 0000 to 143F 5184 words Comments 8000 words 8013 0000 to 01FF 512 words Data command Set to 0000 The number of words to be cleared is specified by the number of words in the command format This parameter has two bytes one word of data End code response Refer to 5 1 3 End Codes for information on end codes The PARAMETER AREA CLEAR command can be executed regardless of the CPU Unit s mode It is the user s responsibility to program steps to prohibit this command from being executed when the CPU Unit is in the RUN mode if such protection is necessary Execute CPU UNIT STATUS READ command code 0601 to read the CPU Unit s mode Refer to 5 3 17 CPU UNIT STATUS READ 06 07 Data can only be cleared from the I O registration table when the CPU Unit is in PROGRAM mode When data is cleared from the I O registration table for CJ series CPU Units the CPU Unit enters the status where I O is automati cally allocated at power ON and the status of mounted Units is reflected in the I O registration table It is not simply cleared to 0000 hex Each parameter area must be cleared in its entirety 5 3 10 PROGRAM AREA READ 03 06 Execution Conditions Command Format 184 Reads the co
24. 0128 99 021 MOV 000A D00000 4 021 MOV 0100 D00001 021 3 MOV 0000 D00002 021 i MOV 0405 D00003 021 1 MOV 0000 D00004 070 XFER 000A 0100 D00010 3 090 SENDD00010 D00020 D00000 4 0128 A202 00 04 013 m te DIFU 012801 0128 A219 0002 00 04 00 5 KF Main execution 6 condition E A202 0128 a AEA 7 021 MOV 000A D00100 021 MOV 0201 D00101 021 MOV 0400 D00102 021 MOV 0405 D00103 021 MOV 0030 D00104 ao 098 RECVD01000 D02000 D00100 9 0128 A202 02 04 013 RF EA 0128 A219 0002 02 04 01 H 11 0128 0128 A219 02 03 04 070 H H XFER 0o00A D02000 D05030 12 END 1 2 3 1 When the SEND 090 RECV 098 Enabled Flag is ON and the execution condition CIO 000000 is ON execution of the instructions for network transmissions are started CIO 0128 00 will remain ON from when SEND 090 is started until execution has been completed 62 FINS Commands with Host Link Protocol Section 3 5 2 11 12 Set the control data D00000 oo oa l Number of send words 10 Serial port 1 peripheral port Destination network address 00 B network Destination node address 00 B node Destination unit address 00 CPU Unit Response required Communications port No 4 Number of retries 5 Response monitor time 2 s 0000 Default Transmit Data Stored Stores 10 words of data starting f
25. AES ENA COES ae net Po a a a a a e E E 103 4 3 C mode Command Details 0 ee ce ee ee eee eee eeee 105 SECTION 5 FINS Commands cccccccccccccccccsseccssces 149 Sak ommimane WSS a5 uc ctictecn amp 8 alee ce with e werdcee wick Cae eee Bas oe eae Oe 150 5 2 Designating Command Parameters so 100 6 ows du Se th hoe Sh Pee hE eS koe dar ONS 6 OSS 163 39 PINS Commands axccch5 ote he ca OY bees betes Bide a oh Oo ehh eee 170 MACY 2 5 5 4008564665 5 5545056 oe SSS aes eee ee A Revision History sesecsececcececcecoesecsesees 24 vii About this Manual This manual describes the C series Host Link and FINS communications commands used with CS CJ series and CP series Programmable Controllers PLCs and NSJ Controllers and includes the sections described below Please read this manual and all related manuals listed in the following table and be sure you under stand information provided before attempting to design or implement communications for CS CJ series or CP series Programmable Controllers PLCs or NSJ Controllers a e SYSMAC CS CJ CP NSJ Series CS1G H CPULILI EV1 CS1G H CPULILIH CS1D CPULILIH CS1D CPULILIS CJU1H CPULILIH R CJ1G CPULILI CJ1M CPULILI CJ1G CPULILIP CJ1G H CPULILIH CU2H CPU6L_I EIP CU2H CPU6L CJ2M CPULIL CS1W SCULILI V1 CS1W SCBLIL V1 CJ1W SCULILI V1 CP1H XLILILILI L CP1H XALILILIL U CP1H YUUILILI LU CP1L M LLILILI L CP1E ELILIDLI L CP
26. CP series CPU Unit or an NSJ Controller the data will be stored accord ing to the response format beginning at the first response word 1 byte 1 byte CMND 490 execution Word 15 87 0 Command Command format data 15 Control data Cf C t1 ot Designates where to send etc Response C 5 Response format data Command frame a bytes Se SE CS CJ series Communications Unit CPU Unit Controller Link Unit ie eee eee etc FINS header f CS CJ series CPU Unit Automatically a mn O Text i gt lt 4 E bytes ee ee ie 1 998 bytes max eee nema e e e e ee rrr a Text Automatically ae code code Response frame Note FINS commands and responses are handled as binary data and data is sent and received in binary format Host Link communications however are basi cally in ASCII 3 2 2 Using with respect to a host computer connected by Host Link With Host Link communications a FINS command frame with a Host Link header and a terminator is sent from a host computer to a CS CJ CP series CPU Unit or NSJ Controller The basic frame formats are shown below Note Host Link communications handle ASCII data so data is sent and received in ASCII For that reason FINS command and response frames must also be sent and received in ASCII when they are handled using Host Link communi cations 31 FINS Command and Response Frames Section 3 3 Command Frame Host Link header FINS command frame
27. CP1L L10DLI L CP1L L14DL1 L CP1L L20DL1 L CP1L M30DL1 L CP1L M40DL1 1 CP1L M60DL_ L1 CP1L CPU Unit Operation Manual SYSMAC CP Series CP1E CPU Unit Hardware User s Manual CP1E ELILIDLI U CP1E NUUDU U J SYSMAC CP Series CP1E CPU Unit Software User s Manual CP1E EOULIDLI L CP1E NUUIDUI U Cat No W472 W465 W452 W450 W451 E W479 W480 Describes the following for CJ2 CPU Units e Overview and features e Basic system configuration e Part nomenclature and functions e Mounting and setting procedure e Remedies for errors Also refer to the Software User s Manual W473 Describes the built in EtherNet IP port and Ether Net IP Units Describes basic settings tag data links FINS communication and other functions Provides basic specifications on NSJ Controllers including an overview designing installation and maintenance Provides basic specifications on CP series CP1H PLCs including an overview designing installa tion and maintenance Provides information on programming CP series PLCs Provides basic specifications on CP series CP1L PLCs including an overview designing installa tion and maintenance Describes the following information for CP1E PLCs e Overview and features e Basic system configuration e Part names and functions e Installation and settings e Troubleshooting Describes the follo
28. Command End code Unit address of Unit with access right code Node number of device with access right Network address of device with access right If any other device holds the access right the device will be identified Parameters Program No command Always FFFF hex End code response Refer to 5 7 3 End Codes for information on end codes Comments If any other device has the access right the access right cannot be acquired with this command use ACCESS RIGHT FORCED ACQUIRE command code 0C01 Refer to 5 3 25 ACCESS RIGHT FORCED ACQUIRE 0C 02 When ACCESS RIGHT ACQUIRE command code 0C01 is executed while any other device has the access right subsequent commands cannot be exe cuted from the other device This command should generally not be used dur ing normal processing The following table shows which FINS commands can be executed even when another device holds the access right Command Command name Command execution code while another device has access right 0103 Yes 0202 PARAMETER AREAWRITE mo 0203 PARAMETER AREA CLER mo 0307 PROGRAMAREA WRITE mo 0308 procRamaREA SCLER mo oo aon s o wo o mw mw mw ee 0620 CYCLE TIME READ 0701 CLOCK READ 0702 CLOCK WRITE MESSAGE READ CLEAR ACCESS RIGHT ACQUIRE ACCESS RIGHT FORCED ACQUIRE 202 FINS Commands Section 5 3 Command Command name Command execution code while another device has access right 2101 ER
29. Do not attempt to disassemble repair or modify any Units Any attempt to do so may result in malfunction fire or electric shock Provide safety measures in external circuits i e not in the Programmable Controller including the following items to ensure safety in the system if an abnormality occurs due to malfunction of the Programmable Controller or another external factor affecting the operation of the Programmable Control ler Programmable Controller indicates the CPU Unit and all other Units and is abbreviated PLC in this manual Not doing so may result in serious acci dents e Emergency stop circuits interlock circuits limit circuits and similar safety measures must be provided in external control circuits The PLC will turn OFF all outputs when its self diagnosis function detects any error or when a severe failure alarm FALS instruction is executed Unexpected operation however may still occur for errors in the I O con trol section errors in I O memory and other errors that cannot be detected by the self diagnosis function As a countermeasure for all such errors external safety measures must be provided to ensure safety in the system The PLC outputs may remain ON or OFF due to deposition or burning of the output relays or destruction of the output transistors As a counter measure for such problems external safety measures must be provided to ensure safety in the system Provide measures in the compu
30. Encapsulates a Modbus ASCIl com MAND mand in a FINS command and sends it to a serial port The Modbus ASCIl command is extracted and sent through the serial port at the receiving end Any Any CONVERT TO HOST LINK FINS COM Sends any FINS command to a PLC MAND See note 2 connected to the serial port of a Serial Communications Board or Unit Ver 1 2 or later only 151 Command Lists 152 Note 1 Section 5 1 These commands will not be accepted and an end code of 2102 hex can not write due to protection will be returned if the Write Protection from FINS Commands Sent to CPU Units via Networks option is selected in the PLC Setup for a CS CJU series CPU Unit with unit version 2 0 or later CP series CPU Unit or NSJ Controller The Serial Gateway function can be used with Host Link FINS commands only under the following conditions For more details refer to 3 5 FINS Commands with Host Link Protocol and the CS CJU Series Serial Communications Boards and Serial Communica tions Units Operation Manual W336 E1 05 Connecting to the Destination PLC Connect the destination PLC to the serial port of a Serial Communications Unit or Board Ver 1 2 or later as a Host Link Slave and use the serial gateway mode or protocol macro mode communications Specifying the Destination PLC s FINS Address Destination Network Address DNA e When a routing table is created to treat the serial communications path as a
31. Fatal Inner Board error eee ee eeasee esa eteeoe 1 Duplication error ee ee ee ee eee 1 I O bus error D2 2 eees eee kta sees seme ee ee 1 Memory error Non fatal error data response Non fatal error data for the CPU Unit is configured as follows First byte Second byte f_____ TF OS Bt 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 A A A A ry A A a A A A A A A Other non fatal errors Reserved for system 1 Special I O Unit setting error oa eee 1 CS1 CPU Bus Unit setting error e 1 Battery error Ho 1 SYSMAC BUS error 6 BSS Beams eee 1 Special I O Unit error oe eee ee hee ees se 1 CPU Bus Unit error TEREE ee ee 1 Inner Board error pee eee S 1 I O verification error a a a ee ee ee 1 PLC Setup error fae ooo oe e ek ee eB See Be ee Reserved for system Bee eee eee ee See ee ee eee we eee 1 Basic I O Unit error eee eeee see eee eee eee eae eee eee eee 1 Interrupt task error Se Bebe eee eee eee ee Cane ee eee sees 1 Duplex error eau eB eee Baw en eat eee eae ee eee eee wee eee 1 FAL error Note For details refer to the CPU Unit s operation manual Message yes no response If MSG 046 has been executed the bit corresponding to the message num ber will be ON 1 as shown below To read the messages generated by 194 FINS Commands Section 5 3 MSG 195 execute MESSAGE READ command code 0920 Refer to 5 3 21 MESSAGE READ 09 20 First byte
32. MON PROG Write protected Read protected Cox n ox OK ox OK OK o OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 19 not executable will be returned if there is no registered data 00 _ Normalcompleton SOS Frame length error Not executable Not executable due to CPU Unit CPU error 4 3 37 ABORT XZ Aborts the Host Link command that is currently being processed allowing the next command to be received Command Format x10 x100 X Z IN Unit No BCD Header FCS Terminator code Limitations Multiple responses to a command can be cancelled with this command An FCS code and terminator are required End Codes The ABORT command does not receive a response 147 C mode Command Details End Codes Section 4 3 There are no end codes with this command There is no response If the ABORT command XZ is received when data is being sent from a serial port to a host the send operation will be stopped even in the middle of a frame 4 3 38 INITIALIZE xx Command Format Limitations End Codes Initializes the transmission control procedure of the Units at all the unit num bers x pi Multiple responses to a command can be cancelled with this command The INITIALIZE command does not receive a response There are no end codes with this command The
33. Restarting these Units is required to read and enable the new routing tables Confirm that the sys tem will not be adversely affected before transferring the routing tables XXil SECTION 1 Introduction This section introduces the C mode commands and FINS commands and explains the relationship between them 1 1 Overview of Communications Commands 00e eee eee 2 12 Comode C Ominiands esere 5 0 8 Howe BERS LO OSE Sesh CsA eee atlods 2 tS FINS Commands 226 6 ice055 eho es i eae cerned wr ab ah cate ees Overview of Communications Commands Section 1 1 1 1 Overview of Communications Commands Communications Commands Addressed to CS CJ CP NSJ series Units Communications commands C mode Commands FINS Commands Note A CS CJ CP series CPU Unit or NSJ Controller can receive the following communications commands C mode commands via Host Link M Via CMND 490 SEND 090 RECV 098 FINS commands Via Host Link C mode commands are specialized Host Link communications commands They are issued by a host computer and sent to a CPU Unit The devices that can be connected for serial communications are the CPU Unit a Serial Com munications Unit and a Serial Communications Board FINS commands are message service communications commands They do not depend on a particular transmission path They can be used for communi cations on various networks Controller Link Ethernet etc and for serial comm
34. a ae a ae DM Word 82 EM Area a bank Oto Bit 20 to 2F bank F EM bela 10 to to E8 bela 18 EM pa Oto Word ale to AF or a to 97 bank F 2 to 5F see note alll 10 to 60 to 68 18 EM current bank indexRegister Ja v Sala Register 0A pv 88 Note Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F 5 3 4 MEMORY AREA FILL 01 03 Writes the same data to the specified number of consecutive memory area words Access right at UM read DIP switch UM Network write other device protection write protection protection OK No Execution Conditions RUN mode MONITOR mode PROGRAM mode Command Format 01 03 Command Beginning address No of items Data code binary I O memory area code 175 FINS Commands Section 5 3 Response Format Parameters Comments 01 03 Command End code code I O memory area code beginning address number of items command Specify the type of data written the beginning address of the data to be writ ten and the number of items of data to be written 2 digits hexadecimal The memory areas that can be written are given in the following table O Memory Area Codes Refer to 5 2 2 I O Memory Address Designations for the specific addresses that can be used Data command Specify the data to be written to the memory area starting from the beginning address
35. always remove the metal jumper from the voltage selector terminals The product will be destroyed if 200 to 240 VAC is supplied while the metal jumper is attached Always use the power supply voltages specified in the operation manuals An incorrect voltage may result in malfunction or burning Take appropriate measures to ensure that the specified power with the rated voltage and frequency is supplied Be particularly careful in places where the power supply is unstable An incorrect power supply may result in malfunction Install external breakers and take other safety measures against short cir cuiting in external wiring Insufficient safety measures against short cir cuiting may result in burning Do not apply voltages to the Input Units in excess of the rated input volt age Excess voltages may result in burning Do not apply voltages or connect loads to the Output Units in excess of the maximum switching capacity Excess voltage or loads may result in burning Separate the line ground terminal LG from the functional ground termi nal GR on the Power Supply Unit before performing withstand voltage tests or insulation resistance tests Not doing so may result in burning Application Precautions 5 Install the Units properly as specified in the operation manuals Improper installation of the Units may result in malfunction With CS series PLCs be sure that all the Unit and Backplane mounting screws are tightened to the
36. f O gt O Host Link Unit S 92 pa re c m gt a O Unit or Unit None or V1 Ee Unit oy CPU Unit EE JEEE r Precautions when Reusing Programs from Earlier Models Section 2 4 Header CS CJ C Series cede Series 5200HE C200HS C120 c500 C1000H C500F C1000HF CaM1 HG HX C2000H NA W TIMER al ale a Yes COUNTER SV CHANGE 2 W TIMER Yes Yes Yes COUNTER SV ie ae 3 CVM1 and CV Series D i O 5 fo m o a a Q 5 E E O C500 3G2A5 Host Link Unit c D x l N e wo lt N oO mM N rr O Sit Board D xX E l n oO I O Q LO gt O Host Link Unit 3 ih eb 99 i o c D gt A O Unit or Unit Oy ee jiii Unit None E CPU Unit DN n Q i lt CPU Unit x n Oo re Yes Yes Yes Yes D Rade CHANGE Yes Yes FORCED Ke CE Yes Yes RESET MULTIPLE Yes No Yes No No FORCED SET RESET NA FR MULTIPLE No No No FORCED SET RESET STA TUS READ NA KC FORCED SET Yes Yes Yes Yes RESET CAN CEL PLC MODEL Yes Yes READ TEST Yes Yes Yes bet a os hehe PROGRAM Yes e Yes Yes READ WP PROGRAM Yes Yes Yes Yes WRITE ae TABLE feelers ae bal ll REGISTER hl ial bal al hall bal ee QQIR READ 1 O MEMORY o Gu com Yes Yes Yes Yes me ee INITIALIZE Yes Yes Yes command S Undefined Yes Yes Yes
37. m lo on ns wee as F R 00 04 13 14 15 16 18 21 23 Sa w foo 01413 n s eenas F w foo an n 1 e 19 OT Oo ooo w loo 01 04 13 14 15 16 18 19 21 23 e Ms Joo 13 14 18 21 SC 00 13 14 15 18 19 21 e MF oo 01 02 13 14 15 18 19 21 e KS boo 18 45 e a F KR oo o0 13 14 15 18 21 e K loo n n5 e a F k foo n ns we a o gt MM 00 13 14 18 21 e i314 iB RP o0 13 14 18 19 21 23 wP oo o1 02 13 14 15 18 19 21 23 A3 A4 A5 AB m lo o o o n3 w 1819 2 QQMR 00 13 14 15 18 21 A3 A4 A5 AB oaar o ns e ee Eoo o Ee OOCOSC SCSCCOCSCSCSSS N spo hm OOOOCOCSS S CSOCCCSCSCSCSCSCSCSSS N respons lo SSS dc 4 3 C mode Command Details 4 3 1 About this Section With C mode command and response formats a single character is indicated by a single box Each character is sent and received as a single byte in ASCII Execution Conditions The Execution Conditions table at the beginning of the description of each command provides the following information 105 C mode Command Details Section 4 3 Commands Single Single command frames are used when there are 131 characters or less Commands Multiple Tells whether the command can be spit into multiple frames when there are more than 131 characters Responses Single Single response frames are used when there are 131 characters or less Responses Multiple Tells whether the response can be spit into mu
38. mat the part in excess will not be read and a normal response will be returned The following rules apply to records stored in the access log e If there is already a record for the same node the old record will be over written with a new one e If there is not already a record for the same node a new record will be created at the end of the log e If the log is full i e 20 records have already been stored the oldest record will be discarded and a new record will be created 5 3 31 FINS WRITE ACCESS LOG CLEAR 21 41 Clears the access log data Execution Conditions Access right at UM read DIP switch UM Network write other device protection write protection protection O N xK KN RUN mode MONITOR mode PROGRAM mode Command Format 21 4 Mo Command format Response Format 21 41 Command End code format End code response Refer to 5 1 3 End Codes for information on end codes Comments This command clears the access log data for FINS write commands 5 3 32 FILE NAME READ 22 01 Reads file data such as the names of files saved in file memory Access right at UM read DIP switch UM write Network write other device protection protection protection Execution Conditions RUN mode MONITOR mode PROGRAM mode 211 FINS Commands Command Format Response Format Section 5 3
39. that is connected to port 2 unit address 81 hex 4 hex x unit number 6 99 hex 153 decimal corresponding to network address 5 in the routing tables of the Serial Communications Unit unit number 6 that is connected to the PLC on the Ethernet Routing is performed between the networks so use the setting for routing tables Network Ethernet FINS message an ee aa Unit E g Operation mode change ei a operation stopped 0402 hex CPU Unit Ethernet unit Network address node address 4 AEN ae Hk Port 2 unit address 81 hex 4 hex x unit Unit No for Host Link 0 Unit No for Host Link 1 Sil Unit No for Host Link 2 re ea TTT ah 153 decimal which corresponds to network CS Cu series or address 5 CVM1 CV series PLC Host Link slave Serial port unit Serial port network address 153 address 5 be 94 Communications Frames Section 3 7 Settings e FINS Network Settings item Value example Setting location Send destination network Network address for Set 05 hex in bits 00 to 07 net address serial communica work address of control data network address allocated tions path allocated C 2 in the CMND 490 instruc to target serial port in routing in local network tion tables table settings is 5 Note Set 0 hex in bits 08 to 11 serial port number of control data C 2 in the CMND 490 instruction Send destination nod
40. x J Unit No BCD Header End code FCS Terminator code Execution Conditions Commands Responses Picmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected x x x N No x x o _ End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundary the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of A5 will be returned instead of 15 for non hexadecimal write data in multiple command frames o nomaron SSCS Note The command is provided for compatibility with previous models We recom mend using CIO AREA WRITE WR whenever possible 115 C mode Command Details Section 4 3 4 3 12 HR AREA WRITE WH Writes data to the HR Area H000 to H511 starting from the specified word Writing is done in word units Command Format Oo x10 x10 W H x 10 x 10 x 10 x 10 x 16 x 167 x 16 x 16 x L ae ee Unit No Header Beginning word Write data 1 word FCS Terminator BCD code 0000 to 0511 Write data for number of words to write Response Format x10 x100 W H x 16 x 16 kg Unit
41. 0000 t0 2047 Note SP represents a space 20 Hex Response Format x 10 x100 F K x 16 x 16 1 Unit No BCD a End code FCS Terminator code Limitations Only 15 timers counters can be set reset LR 0000 to LR 0199 correspond to data link bits CIO 1000 to CIO 1199 Execution Conditions Commands Responses PLC Mode waa Single wutipie Single _ Muhiple RUN won PROG Wiiteprotectd Readkprotected Cm End Codes An end code of 14 format error will be returned if the length of the command is incorrect The forced set reset cancel data is 16 bytes long An end code of 15 entry number data error will be returned if the area classi fication word address or bit parameter setting is incorrect An end code of 15 139 C mode Command Details Section 4 3 will also be returned if the a data specification of O or 1 is used when a timer or counter is designated 00 oman 4 3 29 FORCED SET RESET CANCEL KC Cancels all forced set and forced reset bits including those set by FORCED SET FORCED RESET and MULTIPLE FORCED SET RESET Command Format x10 x10 K c Xo o d Unit No BCD Header FCS Terminator code Response Format x10 x10 K C x 16 x 16 x od a Unit No BCD Header End code FCS Terminator code Execution Conditions Commands R
42. 0001 to 6144 Response Format x10 x10 FR Rx 16 x16 x 16 x 16 x 16 x 16 x a ik oe Unit No BCD Header End code Read data 1 word FCS Terminator code Read data for number of words read C mode Command Details Section 4 3 Limitations The text portion of the response s first frame can contain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Execution Conditions Commands Responses PiLGmoas umaa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Cox m OK OK OK OK OK OK OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if the specified words exceed the data area boundaries or are not specified in BCD or if the number of words to read is 0 00 _ Normalcompleton SOS Entry number data error Frame length error Not executable due to CPU Unit CPU error 4 3 3 LR AREA READ RL Treats ClO 1000 to CIO 1199 as a data link area and reads t
43. 2 4 Precautions when Reusing Programs from Earlier Models 15 2 4 1 C series Host Link Units with 1 N Host Link Format Selected 15 2 4 2 C series Host Link Units with 1 1 Host Link Format Selected 20 2 4 3 C mode Command Support 0 0 22 C mode Commands Section 2 1 2 1 C mode Commands LJ Note Note C mode Host Link commands form a command response system for serial communications Host Link Mode to perform various control operations between a CPU Unit and a host computer directly connected to it These operations include reading from and writing to I O memory changing operat ing modes executing forced set and forced reset operations and so on LJ a C mode command 1 There are two Host Link formats the 1 N Host Link with N 1 and the 1 1 Host Link e The 1 1 Host Link is the earlier Host Link format supported by C series PLCs such as the C200H C1000H and C2000H e The built in peripheral and RS 232C ports of CS CJU series CPU Units built in serial ports of N tyoe CP1E CPU Units serial port C on NSJ Controllers and serial ports 1 and 2 on the Option Board for CP series CPU Units support only the 1 N Host Link format When a Serial Com munications Board or Unit version 1 2 or later is being used a 1 1 Host Link program created for a C series PLC C200H C1000H C2000H can be reused by selecting the Host Link 1 1 format In this manual the term Host Lin
44. 228 230 C CIO Area reading 177 CIO AREA READ RR 106 CIO AREA WRITE WR 114 clock reading 196 setting 197 CMND 490 31 53 58 59 170 setting example 42 C mode commands 2 command formats 9 details 99 148 execution conditions 105 force conditions 102 from host computer 14 list of 2 100 overview 7 25 partitioned 10 partitioned responses 11 response formats 9 command formats for C mode commands 9 commands C mode 2 from host computer 14 overview 7 25 communications 2 addressed to CS CJ series PLCs 2 FINS 2 4 5 27 65 152 parameters 163 partitioned 10 Index commands for CV series PLCs ACCESS RIGHT RELEASE 205 Communications Port Enabled Flags 58 Communications Port Error Flags 58 counters reading Completion Flag status 177 CPU Unit status 3 101 cycle time reading 195 D DAI 33 DA2 33 debugging 5 151 154 destination node number 33 destination unit address 33 DIP switch UM protection 171 directories creating deleting 226 DM Area reading 171 177 writing 174 175 DM AREA READ RD 111 DM AREA WRITE WD 118 E EM AREA READ RB 113 EM AREA WRITE WEB 120 end codes 103 104 155 164 environment precautions xviii error log 5 150 153 ERROR READ MB 135 error response format for C mode commands 10 errors clearing 206 209 reading 200 207 execution conditions for C mode commands 105 for FINS comma
45. 3 5 3 5 MULTIPLE MEMORY AREA READ 01 04 Execution Conditions Command Format Response Format Parameters Comments Reads in one batch the contents of the specified number of non consecutive I O memory area words starting from the specified word Access right at UM read DIP switch UM Network write other device protection write protection protection RUN mode MONITOR mode PROGRAM mode OK OK see 01 o a wo o i Command Beginning address Beginning address code I O memory area code I O memory area code 01 o Command End code Data Data code I O memory area code I O memory area code I O memory area code command Specify the type of data to read The memory areas that can be read are given in the following table O Mem ory Area Codes Refer to 5 2 2 VO Memory Address Designations for the specific addresses that can be used Beginning address command Specify the first word bit flag to read I O memory area code data response Indicates the data type and contents of the designated I O memory area s The data in the designated memory area s will be returned in the sequence specified by the command The number of bytes that can be read for each item depends on the I O mem ory area that is read For details regarding data configuration refer to Element Data Configurations on page 163 End code response
46. 3 K 5 CREATE DELETE O K Disabled OK OK Disabled DIRECTORY D MEMORY CASSETTE Disabled Disabled OK isabled OK OK note Disabled TRANSFER CP1H 4 CPU Units CP1L CPU Units only s OK O OK Debugging 23 FORCED SET RESET Disabled 02 FORCED SET RESET Disabled OK OK OK OK OK Disabled CANCEL Serial Gate 28 03 CONVERT TO COMPO OK OK OK OK OK OK OK ay WAY F COMMAND 28 04 CONVERTTOMOD OK OK OK OK OK OK OK BUS RTU COMMAND 28 05 ICONVERT TO MOD OK OK OK OK OK OK OK BUS ASCII COMMAND Any Any CONVERT TO HOST _ Depends on the command code used LINK FINS COMMAND Note W 1 File to memory area transfers are not possible 2 File to program area transfers are not possible 3 Program area io file transfers are possible 4 Memory Cassette contents cannot be transferred to the program area if program area data is included 5 With CS CJ series CPU Units with unit version 2 0 or later CP series CPU Unit NSJ Controller an option is available in the PLC Setup Write Protec tion from FINS Commands Sent to CPU Units via Networks to not re ceived FINS write commands from specified network nodes even if a FINS write command is sent to the CPU Unit The FINS write commands are the ones listed as Disabled in the Write protected from network column above The enables creating a system in which write control operations are possi 154 Command Lists Section 5 1 ble only from specific nodes For deta
47. 6 With Routing Tables Specify the addresses as shown in the following example Address Specification Address Contents Example 1 Serial communications path unit address A 2 Unit No for Host Link incremented by 1 3 Actual remote unit address fia Remote unit address pins commend CPU Unit 00 hex Serial Communications Unit Board E g Unit number O port 1 Remote network address s 1 Remote node address Serial communications path Host Link FINS PLC Routing tables for treating serial communications path as a network d 5 etwor Unit number addrass Q 80 hex 128 decimal A O Calculated from Unit No 0 port 1 Serial communications path Host Link FINS 1 Network address To serial communications path network address A Target PLC 2 Node address Unit numbers for Host Link 0 to 31 1 3 Unit address E g 00 hex for CPU Unit Za CPU Unit 3 6 9 Using anon PLC Component as the Target Network to Serial Conversion Routing tables to enable the serial communications path to be treated as a network are optional Without Routing Tables Specify the addresses as shown in the following example Address Specification Exam N S 1 Network Remote network address Address to distinguish address 2 Node Remote node address TAER G heii Serial port unit address 80 hex 128 decimal Remote unit address Calculated from unit number 0 port 1 m
48. ACCESS RIGHT ACQUIRE See Acquires the access right as long as no other note device holds it 02 ACCESS RIGHT FORCED Acquires the access right even if another ACQUIRE device already holds it 03 ACCESS RIGHT RELEASE Releases the access right that has been acquire 01 ERROR CLEAR See note ERROR LOG READ Reads the error log 01 02 04 05 07 OA oC 15 20 01 02 0C 0C 0C 21 21 21 FINS write access log ERROR LOG CLEAR See note Clears all error log records FINS WRITE ACCESS LOG READ The CPU Unit automatically keeps a log of any access for FINS write commands This command reads this log 1 FINS WRITE ACCESS LOG Clears the FINS write access log CLEAR See note FINS Commands Section 1 3 21 FILE NAME READ Reads file device data SINGLE FILE READ Reads a specified length of file data from a specified position within a single file 03 SINGLE FILE WRITE See note Writes a specified length of file data from a File memory MESSAGE READ CLEAR Reads and clears messages and reads FAL FALS messages specified position within a single file FILE MEMORY FORMAT See Formats initializes the file device note FILE DELETE See note Deletes specified files stored in the file device FILE COPY See note Copies files from one file device to another file device in the same system FILE NAME CHANGE See note Changes a file name MEMORY AREA FILE TRANSFER Transfers or compares data bet
49. Aborts the operation being performed by a Host Link nications command and then returns to the initial status processing xx INITIALIZE command only Initializes the transfer control procedures for all Host Link Units IC Undefined command response This is the response when the command header only code cannot be decoded 101 C mode Command List Section 4 1 C mode Command Force Conditions Header Multiple Single Multiple code frame frame frame command response response protect protect vali Not vali vali Not vali RD OMAREAREAD Valid Notvalid vaia Vaid Valid Vaia vaia Valid Valo Vall vall vall vall vall vall vall vall ie id aad Vall R SV READ 3 Valid Not valid Valid Not valid Valid Valid Valid Valid Not valid W SV CHANGE 1 Valid Not valid Valid Not valid Not Valid Valid Not Not valid valid valid W SV CHANGE 2 Valid Not valid Valid Not valid Not Valid Valid Not Not valid valid valid W SV CHANGE 3 Valid Not valid Valid Not valid Not Valid Valid Not Not valid valid valid valid valid Valid FK MULTIPLE Valid Not valid Valid Not valid Not Valid Valid Valid FORCED valid SET RESET KC FORCED SET Valid Not valid Valid Not valid Not Valid Valid Valid Valid RESET CANCEL valid READ Nat vali valid 102 End Codes Section 4 2 Header Multiple Single Multiple code frame frame frame command response response protect protect WP PR
50. Data response The data in the specified program area will be returned in sequence starting from the beginning word End code response Refer to 5 1 3 End Codes for information on end codes Comments A maximum of 992 bytes can be read with each command Partition the data into units of 992 bytes or less and use aS many commands as necessary to read from 00000000 hex to the final address When the Prohibit from saving into a memory card and transferring program from PLC setting is enabled this command cannot be executed 5 3 11 PROGRAM AREA WRITE 03 07 Writes data to the specified number of consecutive program area words start ing from the specified word Execution Conditions Access right at UM read DIP switch UM Network write other device protection write protection protection Oo N KN _ N RUN mode MONITOR mode PROGRAM mode e NOK 185 FINS Commands Command Format Section 5 3 03 07 FE FF Command Progra code No Response Format Parameters Comments Beginning word No of Data bytes 03 07 FF FF XUN SSsSSs TN XH ES Command End code Program Beginning word No of code No bytes Program No command and response Always FFFF hex Beginning word command and response For the beginning address the beginning of the program area is specified as a relative address of 000000
51. FINS Commands Section 3 4 3 4 3 Other FINS Command Settings Aside from the addresses the following data must be set Content Values Designation method Designation method CMND 490 Designation in operand frame when anes is created Number of retries Number of times to retry sending 0 to F Hex 0 to 15 times the command Port No Logical communications port CS 0 to 7 Hex CJ CP series CPU Units have 8 communications ports so 8 com munications commands can be executed simultaneously To exe cute 9 or more commands simul taneously it is necessary to set up exclusive control Serial port No Specifies the number of the serial 0 Unit Board port of the Unit with Host Link 1 Serial port 1 for Serial capabilities Communications Board Unit or Peripheral port for CPU Unit 2 Serial port 2 for Serial Communications Board Unit or RS 232C port for CPU Unit Response moni Monitors the time it takes to return 0001 to FFFF Hex 0 1 to Yes No tor time a response If a response is not 6 553 5 seconds returned within the designated time a response timeout is gener ated Response Designates whether or not a 0 or 1 bit Yes Yes required not response is required required ICF bit 0 works that can be accessed Note Unit address are fixed for Units and Boards as well as for serial ports For the SEND 090 RECV 098 and CMND 490 instructions the CPU Unit will add the proper unit address based on th
52. Inner Board SNA Source network address Specify within the following ranges hex 00 Local network 01 to 7F Remote network 1 to 127 decimal 33 Settings for Sending FINS Commands Section 3 4 SA1 Source node address Specify within the following ranges hex 00 Internal communications in PLC 01 to 20 Node address in Controller Link Network 1 to 32 decimal 01 to FE Ethernet 1 to 254 decimal for Ethernet Units with model numbers ending in ETN21 SA2 Source unit address Specify within the following ranges hex 00 CPU Unit 10 to 1F CPU Bus Unit SID Service ID Used to identify the process generating the transmission Set the SID to any number between 00 and FF Note 1 The unit address for a CPU Bus Unit is 10 hexadecimal plus the unit num ber set on the front panel of the CPU Bus Unit 2 With a CS CJ series CPU Unit with unit version 2 0 CP series CPU Unit or NSJ Controller the GCT Gateway Count Number of Bridges Passed Through in FINS command response frames is decremented from to 07 hex variable The GCT was previously decremented from 02 hex For CS CJ series CPU Unit with unit version 3 0 or later the GCT Gateway Count Number of Bridges Passed Through in FINS command response frames is decremented from to 02 hex by default If the user specified CX Net for this CPU Unit version the GCT will be decremented from 07 hex With a CS CJ series CPU Unit with unit version 3 0 or later NSJ Contro
53. Network type Select PLC2 Serial Gateway function port Select port 1 2 in the PORT field according to the calculated address PLC name PLC2 Select the Use SYSWAY with the port option in the Host Link SYSWAY settings PLC name PLC1 T PLC Host Link unit number Enter the Host Link unit number in the Host Link Unit Number field for the target PLC in the Host Link SYSWAY settings 1 2 3 1 Register the PLC to be connected serially using Host Link FINS in the project gateway e g PLC2 2 Inthe Change PLC Dialog Box of the target PLC e g PLC1 select the relay PLC gateway PLC in the Network Type pull down menu e g PLC2 See note and click the Settings Button to the right of the Net work Type pull down menu Note The PLC name enclosed in square brackets e g PLC2 indicates the gateway PLC Change PLC x Device Name PLCI Device Type cst G CJ1G Settings i Network Type Toolbus z Settings l FinsGateway 4SYSMAC LINK SYSMAC WAY Select the PLC to be used as the a relay PLC e g PLC2 in the a Network Type pull down menu 3 The Network Settings Dialog Box will be displayed Click the Guide for Se rial Gateway Button 4 The Serial Gateway Guide Dialog Box will be displayed Select the unit and the port number under the Calculate Address Area the serial port number address is automatically calculated in the Calculated Address
54. No BCD ca End code Complete program FCS Terminator code Limitations The command cannot be executed if the UM Area is read protected Data is read from the beginning of the UM Area to the maximum limit of the program area 142 C mode Command Details Section 4 3 The response s first frame will contain 30 words of program data The second and later frames will contain 31 words except for the last frame which will contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Execution Conditions Commands Responses PLC Mode umaa Single Multiple Single Multiple RUN MON PROG Write protected Read protected x No x x x x x o _ No End Codes An end code of 14 format error will be returned if the length of the command is incorrect o oman 4 3 33 PROGRAM WRITE WP Writes to the CPU Unit user s program area the machine language program transmitted from the host computer The contents are written as a block from the beginning Command Format x10 x109 W P x 16 x 169 ae a i Unit No BCD Sia Complete program FCS Terminator Response Format x 10 x109 W P x 16 x 169 nm Unit No BCD n End code FCS Terminator code Limitations The comman
55. No Header End code FCS Terminator BCD code Execution Conditions 7 Commands Responses PiCmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected_ x x x N No x x KK End Codes An end code of 14 format error will be returned if the length of the command is incorrect or the first word of write data is not in the first frame An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundary the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of A5 will be returned instead of 15 for non hexadecimal write data in multiple command frames o nomani O 116 C mode Command Details Section 4 3 4 3 13 TIMER COUNTER PV WRITE WC Writes the PVs present values T0000 to T2047 or C0000 to C2047 of timers counters starting from the specified word Command Format CO x 10 x 10 W C x 10 x 107 x 10 x 10 x 16 x 16 x 16 x 16 x d see IN Unit No BCD Header Beginning word Write data 1 word FCS Terminator nitNo BCD code Timer 0000 to 207 na a y Counter 2048 to 4095 Write data for number of PV to write Response Format x10 x 10 WC x 161 x 16 x d i Unit No BCD Header End code FCS Terminator code Limitations
56. Not created Serial port unit address Any compo OMRON CompoWay Created Network address 00 hex indicates Must be the unit nent except Component F assigned to the communications in address of the serial PLC serial port accord local PLC port ing to the routing tables Modbus Modbus Not created Network address for Node address for RTU Slave RTU specifying the specifying the including actual remote PLC actual remote PLC OMRON Inverter Modbus Modbus ASCII Slave ASCII Note To access from a CX Programmer Select Change PLC Serial Gateway Guide and enter the actual Host Link unit number The CX Programmer will automatically increment the value by one 3 6 8 Using a PLC as the Target Network to Serial Conversion Routing tables are required to enable the serial communications path to be treated as a network 79 Serial Gateway Overview Section 3 6 Required Routing Tables Specify the addresses as shown in the following example Address Specification Address Contents Example 1 ial icati h Remote network address ease a ae ad A 2 Unit No for Host Link Remote node address heremented by 1 s 1 7 3 Actual remote unit address for Remote unit address ae command CPU Unit 00 hex FINS network Serial Communications Unit Board E g Unit number O port 1 PLC Routing tables for treating serial communications path as a network Unit number address FINS Commu nica
57. RUN enabling the PLC to execute its program The CPU Unit will start operation when RUN is executed You must confirm the safety of the system before executing RUN When the prohibit overwriting of protected program setting is enabled this command cannot be executed Access right at UM read DIP switch UM write Network write other device protection protection protection m ox o ox o RUN mode MONITOR mode PROGRAM mode OK OK 04 01 FF FF Command Program code No Mode 04 01 i CSONT o ES Command End code code Program number command Always FFFF hex Mode command Set the CPU Units operating mode as follows 02 hex Change to MONITOR mode 04 hex Change to RUN mode End code response Refer to 5 1 3 End Codes for information on end codes If only the command code or only the command code and program number are sent the mode will be changed to MONITOR mode If the CPU Units operating mode has already been changed to the intended mode when this command is sent a normal completion will be returned Changes the CPU Unit s operating mode to PROGRAM stopping program execution The CPU Unit will stop operation when STOP is executed You must confirm the safety of the system before executing STOP FINS Commands Section 5 3 Access right at UM read DIP switch UM write Network write other device protection protection protection No No Execution Condit
58. Refer to 5 1 3 End Codes for information on end codes The maximum number of elements that can be read with each command depends on the network as shown in the following table Network Maximum number of elements Contraller Link Ethernet SYSMAC LINK DeviceNet 89 If nothing is specified after the command code a normal response will be returned but nothing will be read lf there is an error in the I O memory area code or beginning address the I O memory area will not be read 177 FINS Commands Section 5 3 I O Memory Area Codes 178 Data type CS CJ mode CV mode Bytes per memory area memory area element code code CE CIO Area Bit e C A s ho COaea TCO Btwihforcedst 70 o h Holding Bit Area HR 72 me Word Bw fo h moe nied wR Completion Flag ae ee Completion Flag a e PV eo a a wmo re DM Area o2 e a EM Area EM bank 0 to Bit with forced sta 20 to 2C bank F tus EM 10 to to E8 18 EM bank 0 to Word na to AF or Z to 97 bank F to 5F see note EM 10 to 60 to 68 18 EM curari a me Word gt Task Flag et w oo po ooe n o oo e a a e S DataRegister on v e wo ppo o7 ew E T Too Note Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F FINS Commands Section 5 3 5 3 6 MEMORY AREA TRANSFER 01 05 Execution Conditions Command Format Response Format Parameters Comments Copies an
59. See note a Host Link terminator Note A FINS command frame also consists of the destination node address the source node address and other FINS command format data The CS CJ CP series CPU Unit or NSJ Controller that receives the command will return the following response frame to the host computer Response Frame Host Link header FINS response frame See note Host Link terminator Note A FINS response frame also consists of the contents set e g requested a the time of transmission and the FINS command response format data lt is also possible to send a FINS command frame with a Host Link header and terminator from a CS CJ CP series not possible from a CP1E CPU unit CPU Unit or NSJ Controller to a host computer connected by Host Link Sys tem unsolicited communications initiated by a slave 3 3 FINS Command and Response Frames If the data from the command code onwards is set in the words specified with S when a FINS command is sent by means of CMND 490 a FINS header will be generated automatically and attached and the FINS command frame will be sent When the FINS response frame is received the FINS header will be automatically removed and the response data from the command code onwards will be stored as specified in the words specified with operand D When a FINS command is sent by Host Link communications the header is attached before the FINS frame and the FCS and terminator are attached after it 3 3 1 FINS Com
60. TRANSFER 0105 000050 179 5 3 7 PARAMETER AREA READ 02 01 000040 180 5 3 8 PARAMETER AREA WRITE 02 02 000 181 5 3 9 PARAMETER AREA CLEAR 02 03 000000 183 5 3 10 PROGRAM AREA READ 03 06 0 00 cee ees 184 5 3 11 PROGRAM AREA WRITE 03 07 0 0 0 0 0c eee ees 185 5 3 12 PROGRAM AREA CLEAR 03 08 0 0000 186 Deon JRUINGO4 Ole ccc soa detec Sette Seed wea ie GEER e Ah aoe Mes 188 Sla STOP M O2 ecb tethers a a Aaa 188 5 3 15 CPU UNIT DATA READ 0501 2 0 0 2 2008 189 5 3 16 CONNECTION DATA READ 05 02 02000005 192 5 3 17 CPU UNIT STATUS READ 0601 0000 193 5 35 18 CYCLE TIME READ 0620er pokes asd bevia dee c hi wA 195 529519 CLOCK READ OOL o ccsemencle atictnn dota data gies aa wands 196 525 20 CLOCK WRITE OF 02 026 tte Pe bei eh tee bee d 197 529 21 MESSAGE READ 09 2022 24 oe ea ecen cae ae wient eee ewes 198 5 322 MESSAGE CLEAR 0920 eireas Sante dig eadherkte Satheckon eaters dws 199 5 3 23 FAL FALS READ 09 20 6 2 3 ov cautions eb eed Wee athens 200 5 3 24 ACCESS RIGHT ACQUIRE 0C 01 040 201 5 3 25 ACCESS RIGHT FORCED ACQUIRE 0C 02 203 5 3 26 ACCESS RIGHT RELEASE 0C 03 20000 205 5327 BRRORIC LEAR 21 Oly vee sot ba ou a he ded caren bee eden 206 5 3 28 ERROR LOG READ 21 02 06 230 didn ae ale thee eed eed 207
61. Unit are mounted to the Backplane of the CPU Unit commands can be sent to the host computer from a CPU Unit on a network on another level up to three network levels Note In principle send commands to the host computer only when one host com puter is connected to one CPU Unit If more than one CPU Unit is connected to the host computer the commands may collide with each other and prevent normal communications Create a program that will exclusively control com mands that are being sent to a host computer to which multiple CPU Units are connected Considerations when Sending Commands from a CPU Unit Consider the following items when using instructions SEND 090 RECV 098 and CMND 490 to send commands from the CPU Unit 49 FINS Commands with Host Link Protocol Section 3 5 1 2 3 1 SEND 090 RECV 098 and CMND 490 executed by the CPU Unit are converted to the same format for FINS commands that are sent to CPU Units on networks 2 A program must be created to process the commands received by the host computer 3 When instructions SEND 090 RECV 098 and CMND 490 are exe cuted in a CPU Unit some of the control data settings will be different Re fer to the relevant instruction specifications 3 5 5 Sending Commands from the CPU Unit Send 090 50 When controls are being implemented by sending commands from the local CPU Unit or another CPU Unit on a network to a host computer three instruc tions
62. Unit error information Command Format x 10 x 10 M F x 10 x 10 x E Unit No BCD Biola Error clear FCS Terminator code For the error clear parameter specify 01 to clear errors and 00 to not clear errors BCD Response Format x10 x 10 M F x 16 x 169 x 16 x 16 x 16 x 16 x 16 x 16 x 16 x 16 x Header End code Error information Error information FCS Terminator Unit No BOD code 1st word 2nd word 135 C mode Command Details Section 4 3 1st word x 168 x 16 x 16 x 16 Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 oloo lo 010 000 1 Battery error A40204 gt 7 T Special I O Unit error OR of A40206 and A40207 bore ee 1 FAL generated A40215 Sesh eee es 1 Memory error A401 15 ee 1 I O bus error A401 14 Cede eee eee dew ee cag ee eb Hx 1 No end instruction error FALS A40109 Program error Seod op o e seaenee hehe ges d aoe o 4 1 System error FALS A401 06 2nd word x 163 x 162 x 16 x 16 Bit 15 14 13 12 1110 9 8 7 6 5 4 3 2 1 0 FAL FALS No 00 to 99 BCD ae ee eee ae a ee 1 I O verify error A40209 SUS hie sees ee ee ee gs 1 Cycle time overrun A40108 88 6 ee Eee eee
63. Units for NSJ3 TOCCB M3D Simplex Systems NSJ5 SQUIL1 B M3D Bsns D CP NSJ8 TVULI B M3D J CS1D Process control CPU Units esmou P J a CS1 CPU Units CJ1M CPU Units fer CJ1 CPU Units Err CJ series Basic I O Units CS1H CPULIL V CS1G CPULIH V CJ1 H CPU Units CJ1H CPULILIH R CJ1H CPULILIH CJ1G CPULILIH CJ1G CPULILIP Loop CPU Units NSJ series Expansion Units CS series Basic I O Units CS series Special I O Units CJ series Special I O Units CS series CPU Bus Units CJ series CPU Bus Units CS series Power Supply Units Note A special Power Supply Unit must be used for CS1D CPU Units S S A 1 Can only be used with the CP1H CPU unit 2 Indicated as E type in some parts of this manual 3 Indicated as N type in some parts of this manual CJ series Power Supply Units TABLE OF CONTENTS PRECAUTIONS osccconscuenssansceriecasnecacewawes XY 1 Mended AUCICNCS vax toc sek dene eens A EAA EDENE TSAA EEA xvi 2 General PrecauliOns eseria 8h a a ae Sy ee OS A ee oe ok xvi 3 Sie Preca oS ewan det hae a a a eos as awe T ER xvi 4 Operating Environment Precautions lt 4 cs a3 0cc0 5 sran npa E E aA OE
64. W TIMER COUNTER SV Changes the SV of the specified timer counter instruction changing CHANGE 1 to anew constant SV W Finds the specified timer counter instruction beginning with the designated program address in the user program and changes the constant SV in four digits BCD or the word in which the SV is stored to a new constant SV or storage word Finds the specified timer counter instruction beginning with the designated program address in the user program and changes the constant SV in four digits BCD or the TIMER COUNTER SV CHANGE 2 word in which the SV is stored to a new constant SV or W TIMER COUNTER SV CHANGE 3 storage word R CPU Unit status MS STATUS READ Reads the CPU Unit s operating conditions operating mode forced set reset status and fatal errors STATUS CHANGE Changes the CPU Unit s operating mode MF ERROR READ Reads the CPU Unit s error information i e all fatal or non fatal errors currently in effect Forced FORCED SET Forcibly sets one designated bit set reset FORCED RESET Forcibly resets one designated bit FK MULTIPLE FORCED Forcibly sets resets cancels multiple designated bits SET RESET FORCED SET RESET CAN Cancels all forced set reset status CEL PLC model code MM PLC MODEL READ Reads the model code of the CPU Unit reading Testing TS TEST Returns just as it is a single block that was sent from the host computer Program area PROGRAM READ Reads in one batch
65. Yes oe response only TXD No Yes No No No No No No beets response eo eee MES eo eee FINS MES idl all ee fee f Yes Yes SAGE slave initiated Note When using CVM1 or CV series built in ports or Host Link Units the response data format for the MS command STATUS READ is different from the format for other Units For details refer to 4 3 23 STATUS READ MS se n lt O O es lt Z to se n se n ie ie S amp S g ie se n Oy n O O O DY n Oy n se n oy n se n se n Oy Oy n n se Oy n n EE O E O DY n se n 24 Precautions when Reusing Programs from Earlier Models Section 2 4 Manuals for Host Link Operations PLC Product Model suffixes omitted Manual type Catalog No CS CJ Series Communications CPU Unit CJ2H CPUL IL_ EIP Reference W342 E1 commands C CJ2M CPULIL Manual mode and FINS CS1G H CPULILIH CS1G H CPULILJ EV1 CS1D CPULILIH CJ1M CPUL IL CJ1G H CPULILIH CJ1G CPULIL Serial Communi CS1W SCB21 V1 41 V1 cations Unit CS1W SCU21 V1 Board CJ1W SCU21 41 Serial Communications Unit Board CS1W SCB21 V1 41 V1 Operation W336 E1 CS1W SCU21 V1 Manual CJ1W SCU21 41 C200HX HG HE CPU Unit C200HX HG HE CPUL IL Operation W303 E1 Manual C200HX HG HE CPUL IL Z Operation W322 E1 Manual C200HS CPU Unit C200HS CPUL IL Operation W235 E1 Manual C Series Host Link Units C200H LK101 201 202 System W143 E1
66. aa Beginning read address Number of response data bytes Memory area code s 2 oa o0 c 2 o0 o0 Oooo ee Beginning read address Destination network address Serial port No S 3 00 oA C 3 iis Number of elements read D First response wor Control code a Destination unit address Destination node address Number of retries Communications port number Response required not required Ps Response monitor time D SE D 1 00 o0 Ooo End code Read data D 11 H Read data 42 FINS Commands with Host Link Protocol Section 3 5 3 5 FINS Commands with Host Link Protocol FINS commands can be sent and received using the Host Link protocol between interconnected host computers and PLCs 3 5 1 Connection Configurations One of the following two methods can be used to send and receive FINS com mands using the Host Link protocol Sending from a Computer to a CPU Unit Note The host computer can be connected to the peripheral port or RS 232C port on the CPU Unit or to a serial ports on a Serial Communications Unit Board The Host Link protocol must be used regardless of the point of connection CPU Unit Directly Connected to Host Computer CPU Unit CPU Units on a Network CPU Unit Host Link FINS command Network Controller Link Ethernet etc Sending from a CPU Unit to a Computer Slave Initiation Note 1 Slave initiation is not possible from a CP1E CPU 2 The host computer can be conn
67. and minimum cycle times are initialized when operation is started 5 3 19 CLOCK READ 07 01 Execution Conditions Command Format 196 Reads clock information Access right at UM read DIP switch UM Network write other device protection write protection protection RUN mode MONITOR mode PROGRAM mode 07 01 Command code FINS Commands Response Format Parameters Section 5 3 07 01 Command End code code Year Month Day Hour Minute Second Day of week Year month day hour minute second day of week response The year month day of month hour minute and second are expressed in BCD Year The rightmost two digits of the year 1998 1999 and 2000 are expressed as 98 99 and 00 respectively 2096 and 2097 will be expressed as 96 and 97 Hour 00 to 23 BCD Day of week As follows Value hex 00 o1 02 03 04 05 06 End code response Refer to 5 7 3 End Codes for information on end codes 5 3 20 CLOCK WRITE 07 02 Execution Conditions Command Format Response Format Parameters Writes clock information Access right at UM read DIP switch UM Network write other device protection write protection protection mo ox ox m RUN mode MONITOR mode PROGRAM mode SST TTT Tt code Year Month Day Hour Minute Second Day of week 07 02 wep Co
68. at the end to the host computer 11 Command Response Formats Section 2 2 12 The following diagram shows the response format when there are more than 131 characters Command frame _ D o Ak 5 2 c o O c DIO T Host computer Terminator 131 characters max Note PLC Delimiter Delimiter SNIN O O O O Cc LL Delimiter Delimiter Terminator _ Dlo ake i fu c o 5 Clo DIO T Response frame 1 Response frame 2 Response frame 3 128 characters max 128 characters max Frames in partitioned commands or responses must have not more than 128 characters including the delimiter terminator Delimiters from the host computer are detected by the presence of a CR code The delimiter will be detected even if there is data in front of it Command Response Formats FCS Calculations Section 2 2 The PLC calculates the FCS Frame Check Sequence value for each com mand frame it receives and it checks for errors by comparing that value with the FCS value sent with the command frame The host computer must calcu late the FCS value when sending a command frame Also when checking for errors in response frames the host computer must calculate the FCS value for each response frame it receives and compare that value to the FCS value sent in the response frame Ce oleae Unit number ASCII Code 40 1 31 30 R 52 1 31 Calculation result
69. been requested 16 bytes of spaces 20 hex will be returned Message data will be returned as is even if a control code such as CR 0D hex is included in the message data End code response Refer to 5 1 3 End Codes for information on end codes The MESSAGE READ MESSAGE CLEAR refer to 5 3 22 MESSAGE CLEAR 09 20 and FAL FALS READ refer to 5 3 23 FAL FALS READ 09 20 commands share the same command code 0920 They are distin guished by bits 14 and 15 of the two byte parameter following the command code To read FAL FALS messages bit 14 must be OFF 0 and bit 15 must be ON 1 5 3 24 ACCESS RIGHT ACQUIRE 0C 01 Execution Conditions Command Format Acquires the access right as long as no other device holds it Execute the ACCESS RIGHT ACQUIRE command when you need to execute commands continuously without being interrupted by other devices As soon as the exe cution of the commands has been completed execute ACCESS RIGHT RELEASE command code 0C03 to release the access right Refer to 5 3 26 ACCESS RIGHT RELEASE OC 03 If another devices holds the access right the device will be identified in the response Access right at UM read DIP switch UM Network write other device protection write protection protection po No OK KN RUN mode MONITOR mode PROGRAM mode 0C 0 FF FF Command Progra code No 201 FINS Commands Section 5 3 Response Format OC 01 eye ee ge Se
70. decimal is set for the serial port The CX Net in the CX Programmer is used to set the relationship between the serial port s unit address and the allocated network address in the local net work tables of the routing tables These settings are then transferred to the CPU Unit to which the Serial Communications Unit Board is mounted CX Net in CX Programmer g Local network table in routing tables Unit number Network Ld address n Set the unit address U as a decimal for the unit number Serial Communications Unit Board Serial communications path Unit address U 80 hex 81 hex unit number x 4 hex Network address n Unit Addresses for Serial CS CJ Series CPU Unit Communications Ports CPU Unit Peripheral port RS 232C port Serial communications port on Unit address CPU Unit Peripheral port FD hex 253 decimal RS 232C port FC hex 252 decimal 84 Serial Gateway Overview Section 3 6 CP series CPU Unit CP series CPU Unit Serial port 1 Serial port 2 Serial communications port on Unit address Option Board of CPU Unit Serial port 1 FD hex 253 decimal Serial port 2 FC hex 252 decimal NSJ Controller NSJ Controller Serial port C on Controller Section Serial communication port on Unit address NSJ Controller Serial port C FC hex 252 decimal Serial Communications Unit Board e Serial Port 1 Unit Addresses Tunitmumber 0 712 3 4 5 6 7 8 A C DIE F pus
71. described below I O memory designation involves the designation of the memory area code and the address within the memory area code e Memory area codes are designated in one byte two digits hexadecimal as shown in the table in 5 2 2 V O Memory Address Designations e Addresses within memory area codes consist of a total of three bytes six digits hexadecimal Of these two bytes four digits hexadecimal desig nate the word and one byte two digits hexadecimal designates the bit I O memory address Memory area code Address within I O memory area designation designation werd oo 4 bytes 8 digits hexa gt 1 byte 2 digits hex 2 bytes 4 digits hex 1 byte 2 digits hex decimal Memory area code Set by classification From 0000 hex 00 to OF hex word bit in order CIO WR etc Upper limit depends Note Always 00 hex Note Also possible on memory area for word address and with forced status code Timer Counter Com pletion Flags Example Example Example Example Bit 13 of CIO 0010 CIO 30 hex 0010 000A in hexa __ Bit 13 OD in hexadec 30000A0D hex decimal imal Example I O memory reading Bit 13 of ClO 0010 i e CIO 001013 is read L Read address I O memory area designation Area CIO Data type Bit Command code Example Reading W005 o ot D Ld Lo L Read address I O memory designation Area WR Data type Word Command code Element Data Bit Designations Configurat
72. directory code code Memory area code Nems length path Memory area specification File specification Response Format 22 OA Command End code No of items code Parameters Parameter code command Specify the transfer compare method as follows 0000 hex Data transfer from the I O memory area to the file memory 0001 hex Data transfer from the file memory to the I O memory area 0002 hex Data compared I O memory area code Beginning address command The memory area to be used for data transfer or comparison and the first address in the memory area to be transferred or compared The memory areas that can be written are given in the following table Refer to 5 2 2 VO Memory Address Designations for the specific addresses that can Data type Mode memory area Bytes per element code m Word Work Area WR Auxiliary Bit Area AR be used PV DM DMArea DM Wod pMaea Area E T 0 to bank F Word AAEE to AF or 50 to5F see note EM bank 10 to bank 18 60 to 68 a oe M E A Note Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F Number of items command and response In the command format specify the number of items in word units to be transferred or compared In the response format this parameter indicates the number of items transferred or successfully compared Refer to Element Data Configurations on page 163 for the
73. end codes The MESSAGE READ MESSAGE CLEAR refer to 5 3 22 MESSAGE CLEAR 09 20 and FAL FALS READ refer to 5 3 23 FAL FALS READ 09 20 commands share the same command code 0920 They are distin guished by bits 14 and 15 of the two byte parameter following the command code To read MSG 195 messages bits 14 and 15 must be OFF 0 5 3 22 MESSAGE CLEAR 09 20 Execution Conditions Command Format Response Format Clears messages generated with MSG 195 Access right at UM read DIP switch UM write Network write other device a ee ee No when et messages RUN mode MONITOR mode PROGRAM mode 09 20 Command Message No code 09 20 Command End code code 199 FINS Commands Section 5 3 Parameters Message number command Turn ON the bits of the messages to be cleared Multiple messages can be cleared at one time First byte Second byte Bit 15 14 13 8 7 6 5 4 3 2 1 0 01110 0 i T i i i i i L i i Set to 0 Message No 0 E E E ee a Message No 1 TETEE Message No 2 TEE EE Message No 3 Ca et ee ee ee s Message No 4 et Se eh Ge amp ode ex Message No 5 Cee eeee See eee hast Message No 6 eee hedeee ag tees pai Message No 7 01 Message clear End code response Refer to 5 7 3 End Codes for information on end codes Comments The MESSAGE READ MESSAGE CLEAR refer to 5 3 22 MESSAGE C
74. g 80 hex Target OMRON Component or Modbus Slave Serial to Serial Conversion Routing tables to enable the serial communications path to be treated as a network are optional Without Routing Tables Specify the addresses as shown in the following example Address Specification Address ontents eae Example irect serial con Remote network address D i See 00 hex See note direct serial Local PLC in h Remote node address connection ternal commu 00 hex Serial port unit 80 hex 128 decimal TET R t it add Calculated from unit Serial communications emote unit address address number 0 port 1 path Host Link FINS Serial Communications Unit Board Note Serial port unit Address for standard E g Unit number O port 1 address e g 80 hex direct serial connection We can be set 1 Network address PLC Direct serial connection To 00 hex WS No routing tables required to treat serial 2 Node address Local T communications path as a network PLC internal O communications To 00 hex i communications path l Way F M 3 Unit address fompewalir Modbus To serial port unit Target OMRON Component or Modbus Slave address e g 80 hex With Routing Tables Specify the addresses as shown in the following example Address Specification Contents Example Address __ Remote network address 1 Serial communications A path network address Remote node addre
75. gt serial conversion e When a routing table is not created to treat the serial communications path as a network this is the actual node address used to specify the destination PLC the Host Link unit number 1 for serial gt serial gt serial conversion e Destination Unite Address DA2 This is the serial ports unit address e Unit addresses for serial port 1 7 C Bo ard Hexadecimal 0 oa es ec o0 ea oe ac AO aa re Ac eo ea oo ec ea e Unit addresses for serial port 2 7 C Bo ard Hexadecimal ei e5 eo ao or os oa ed m As A AD er es eo aD es e Sending Modbus ASCII Commands with the CMND Instruction e Set FINS command code 2805 hex CONVERT TO MODBUS ASCII COMMAND in S e Set the following parameters in ASCII starting at S 1 with the leftmost byte first Slave address 2 byte ASCII Function code 2 byte ASCII and the communications data ASCII 2 x n bytes Note For Modbus RTU set the Modbus RTU Slave address 1 byte in the leftmost byte of S 1 and the function code 1 byte in the rightmost byte of S 1 236 A B ABORT XZ 147 access right acquiring 5 150 153 201 203 at another device 171 releasing 5 150 153 205 accessing I O memory 4 accessing program area 3 4 101 accessing time data 4 150 153 AR AREA READ RJ 112 AR AREA WRITE WJ 119 ASCII data 31 backup precautions xvii Battery Error Flag xvii bits controlling
76. hex instruction ICMND S D Q 95 Communications Frames Section 3 7 Command Details Operand Offset Value meaning SSCS S D01000 0402 hex Change operating mode stop operation FINS command code 0402 hex FFFF hex Change operating mode stop operation Always FFFF hex D D02000 a aa First response storage word C D00000 000C hex Command data bytes 0004 hex 4 bytes decimal 000A hex Response data bytes 0004 hex 4 bytes decimal 0005 hex Send destination network address 05 hex Serial port number 0 hex not used 3 0200 hex Send destination node address 02 hex set the unit number for Host Link 1 Send destination unit address 00 hex 0000 hex Response required Communications port number 0 Resends 0 hex 0000 hex Response monitoring time 2 s Response Operand Offset Value meaning SSCS D D02000 0402 hex Change operating mode stop operation FINS command code 0402 hex FFFF hex FINS end code FFFF hex normal end Note 1 The method used to set the remote destination network address node ad dress and unit address for sending data to or receiving data from the PLC connected serially via Host Link to another PLC on the network to which the Serial Communications Board Unit is mounted using the SEND 090 RECV 098 instructions is the same as for the CMND 490 instruction 2 When creating Host Link FINS command frames using the CMND 490
77. is in RUN mode if such protection is nec essary Execute CPU UNIT STATUS READ command code 0601 to read the CPU Unit s mode Refer to 5 3 17 CPU UNIT STATUS READ 06 01 Even if data is written to the Timer Counter PV Area the Completion Flags will not be turned OFF 0 179 FINS Commands Section 5 3 I O Memory Area Codes Data type CS CJ mode CV mode Bytes per memory area memory area element code S code z CIO Area Word Eo Holding Bit Area a Auxiliary Bit Area B o Pv B 2 DM DMArea si DM o Wa o C Area CE T 0 to ee to AF or ee to 97 bank F to 5F see note EM on 10 to 60 to 68 on 18 EM current Word bank Note Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F 5 3 7 PARAMETER AREA READ 02 01 Reads the contents of the specified number of consecutive CPU Unit parame ter area words starting from the specified word Access right at UM read DIP switch UM Network write other device protection write protection protection Execution Conditions RUN mode MONITOR mode PROGRAM mode OK OK Command Format 02 01 80 S N Command Parameter Beginning No of words code area code word Response Format o 02 01 pan Command Endcode Parameter Beginning No of words Data code area code word Parameters Parameter area code command and response Specify the para
78. mode 217 FINS Commands Command Format 22 05 Command Disk No code Response Format Parameters Comments Section 5 3 12 bytes 12 bytes No of File name gt gt File name Directory Absolute directory files length path 22 5 Command End code No of code files Disk number Command The classification of the file memory with the file to be deleted is specified as follows 8000 hex Memory card 8001 hex EM file memory Number of files command Specify the number of files to be deleted File name command Specify the name of the file to be deleted For details on the configuration refer to page 168 Directory length Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself Number of files response Indicates the number of files actually deleted End code response Refer to 5 1 3 End Codes for information on end codes The specified files will
79. of C 3 With this method set the serial port number physical port to 0 hex not used in bits 08 to 11 of C 2 e Set the unit address of the Serial Communications Board Unit itself Board E1 hex Unit 10 hex unit number in the send destination unit address bits 00 to 07 of C 3 and set the serial port numbers Port number 1 1 hex Port number 2 2 hex in the serial port number phys ical port bits 08 to 11 of C 2 e Host Link FINS Always set the unit address of the actual destination unit Sending Modbus RTU Commands e Set the FINS command code 2804 hex indicating the Modbus RTU con version in S e Set the slave address 1 byte FUNCTION code 1 byte communica tions data n bytes in order of leftmost byte to rightmost bytes see note from S 1 onwards Note For Modbus RTU set the Modbus RTU slave address 1 byte in the leftmost byte of S 1 and the FUNCTION code 1 byte in the rightmost byte of S Example of Sending Modbus RTU Command Using CMND 490 Instruction This example is for writing a frequency reference value from an OMRON 3G3MV Inverter connected through RS 485 to the Serial Communications Unit via two networks Ethernet to Controller Link Example The CMND 490 instruction is executed in the PLC for Ethernet The Modbus RTU command for writing frequency reference value data is sent via Ethernet to the 3G3MV Inverter Modbus RTU slave address 02 that is connected to port 1 Unit address 80 hex 4
80. of MEMORY AREA FILE TRANS FER command code 220A will be recorded as the date of the file that has been transferred Files cannot be overwritten when transferring data from a memory area to file memory End code response Refer to 5 1 3 End Codes for information on end codes 5 3 40 PARAMETER AREA FILE TRANSFER 22 0B Execution Conditions Command Format Compares or transfers data between the parameter area and the file memory Access right at UM read DIP switch UM write Network write other device protection a No OK OK See note RUN mode MONITOR mode PROGRAM mode OK See note OK See note Note Data cannot be transferred from file memory to the parameter area 22 OB 12 bytes S Command Parameter Parameter Beginning No of Disk No File name Directory Absolute directory code code areacode address items length path Parameter area specification File specification 222 FINS Commands Response Format Parameters Section 5 3 Command Endcode_ No of items code Parameter code command Specify the transfer compare method as follows 0000 hex Data transfer from the parameter area to the file memory 0001 hex Data transfer from the file memory to the parameter area 0002 hex Data compared Parameter area code Command Specify the parameter area to be used for data transfer or comparison The rightmost
81. point Probable cause 10 Command 01 Command Command data The command is longer than Check the command format and format error too long the maximum permissible correct the command data length 02 Command Command data The command is shorter than Check the command format and the minimum permissible correct the command data length 03 Elements Command data The designated number of Check the number of elements and too short data don t elements differs from the set data for each element match number of write data items 04 Command Command data An incorrect format was Check the command format and format error used correct the command data 05 Header Routing table Either the relay table in the Set the routing tables correctly error local node or the local net work table in the relay node is incorrect 11 Parameter 01 Area classi Memory area The specified word does not Check the memory areas and error fication missing code in exist in the memory area or parameter codes in the command command data there is no EM Area and correct the command data 02 Access size Access size The access size specifica Check the memory areas and specification in tion is incorrect or an odd access size and correct the access command data word address is specified size 03 Address Starting address The start address in com Check the area being processed range error in command data mand process i
82. port 1 or 2 on Option Board of CP series CPU Unit See note Serial communications port on Serial Communica tions Board Unit with unit version 1 2 or later Modbus RTU Serial communications port on Serial Communica tions Board Unit with unit version 1 2 or later or serial port 1 or 2 on Option Board of CP series CPU Unit See note Modbus ASCll Serial communications port on Serial Communica Host Link FINS tions Board Unit with unit version 1 2 or later Note Not possible when a CP1E CPU unit is used Using the CPU Unit FINS message on network or CPU bus RS 232C or peripheral port FINS header 2803 FINS header AS ie ae CompoWay F command on CPU Unit ep D v Q D D 5 lt D mD D og D roy a gt 5 3 D e D ap Q O 3 3 O A mD D 3 S D O Q 66 Serial Gateway Overview Section 3 6 Using a Serial Communications Board Unit RS 232C or RS 422A 485 CompoWay F command Modbus RTU command Modbus ASCIl command FINS message via network or CPU bus FINS header 2803 CompoWay F command FINS header 2804 Modbus RTU command FINS header 2805 Modbus ASCII command Serial Communications Board Unit User z ifi User specified FINS header User specified data Host Link header e n Terminator The Serial Gateway is enabled under the following conditions e In Serial Gateway mode i e In protocol macro mode with the Serial Gatew
83. provides an overview of FINS commands Section 4 provides detailed descriptions of the C mode commands Section 5 provides detailed descriptions of the FINS commands N WARNING Failure to read and understand the information provided in this manual may result in per sonal injury or death damage to the product or product failure Please read each section in its entirety and be sure you understand the information provided in the section and related sections before attempting any of the procedures or operations given X Read and Understand this Manual Please read and understand this manual before using the product Please consult your OMRON representative if you have any questions or commenis Warranty and Limitations of Liability WARRANTY OMRON s exclusive warranty is that the products are free from defects in materials and workmanship for a period of one year or other period if specified from date of sale by OMRON OMRON MAKES NO WARRANTY OR REPRESENTATION EXPRESS OR IMPLIED REGARDING NON INFRINGEMENT MERCHANTABILITY OR FITNESS FOR PARTICULAR PURPOSE OF THE PRODUCTS ANY BUYER OR USER ACKNOWLEDGES THAT THE BUYER OR USER ALONE HAS DETERMINED THAT THE PRODUCTS WILL SUITABLY MEET THE REQUIREMENTS OF THEIR INTENDED USE OMRON DISCLAIMS ALL OTHER WARRANTIES EXPRESS OR IMPLIED LIMITATIONS OF LIABILITY OMRON SHALL NOT BE RESPONSIBLE FOR SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES LOSS OF PROFITS OR COMMERCIAL LOSS IN
84. s Number of Read Words Set the total number of words of data to be read from the host computer Serial Port Number Set the serial port number to which the host computer is connected Destination Network Address Set the network address of the destination node i e the computer Set 00 to send communications within the local network Destination Node Address Set the node address of the destination node i e the computer Set 00 when transmitting within the local PLC Destination Unit Address Set the unit address of the Unit to which the host computer is connected Communications Port Number Set the port number in the CPU Unit which will transmit RECV 098 FINS Commands with Host Link Protocol Number of Retries Section 3 5 Set the maximum number of times RECV 098 is to be resent if no re sponse is returned Response Monitor Time Set the time to wait for a response Control Word Settings The setting range for each item is shown on the following table Number of read words 0001 to 010D 1 to 269 words 00 CPU Unit Inner Board CPU Bus Unit Serial port number Destination network address Destination node address Destination unit address 01 Port 1 02 Port 2 Local network 00 01 to 7F Network address 1 to 127 00 00 10 to 1F Internal communications in PLC Node address of Ethernet Unit with model number ending in ETN21 1 to 254 Node address of Ether
85. serial port 1 Unitnumber o 1 2 3 4 5 6 7 ea o ale c od amp F Boara exadecimal 80 84 ee ec 90 ea se ac Ao aa as ac eo lea ee aC ea e Unit addresses for serial port 2 Unitnumber o 1 2 3 4 5 6 7 e o alB ic od e F Boar Hexadecimal 81 85 89 sD 91 95 99 oD A1 a5 AS AD B1 B5 B9 BD ES e Sending CompoWay F Commands with the CMND Instruction e Set FINS command code 2803 hex CONVERT TO COMPOWAY F in S e Set the following parameters starting at S 1 in ASCII with the leftmost byte first CompoWay F node number 2 byte ASCII subaddress 2 byte ASCII SID 2 byte ASCII CompoWay F command MRC 2 byte ASCII CompoWay F command SRC 2 byte ASCII and text ASCII 2 x n bytes 232 FINS Commands Section 5 3 Note For CompoWay F set SID 0 1 byte ASCII 30 hex in the leftmost byte of S 3 and the most significant digit of the CompoWay F com mand code s MRC 1 byte ASCII in the rightmost byte of S 3 Set the least significant digit of the CompoWay F command code s MRC 1 byte ASCII in the leftmost byte of S 4 and the most significant digit of the CompoWay F command code s SRC 1 byte ASCII in the rightmost byte of S 4 Be sure to set the remaining data with this 1 byte offset as well 5 3 47 CONVERT TO MODBUS RTU COMMAND 28 04 Execution Conditions Command Format Response Format Parameters When this command is sent to serial port 1 or 2 on an
86. serial port s unit address permanent must be allocated and the routing table s local network table must be created The following dia grams show serial port s unit address e Example 1 Serial Communications Board Serial Communications Board Serial port 1 Serial port 2 38 Settings for Sending FINS Commands Section 3 4 Summary of Addresses Serial port on Board Serial port s unit address Serial port 1 E4 hex 228 decimal Serial port 2 E5 hex 229 decimal e Example 2 Serial Communications Unit Serial Communications Unit Serial port 1 Serial port 2 Serial port on Unit Serial port s unit address Example Unit number 1 Serial port 1 80 hex 04 hex x unit num 80 hex 04 hex x 1 84 ber hex 132 decimal Serial port 2 81 hex 04 hex x unit num 81 hex 04 hex x 1 85 ber hex 132 decimal Unit addresses for serial port 1 Unitnumber 0 1 T 2 7 3 4 5 T 6 7 7 7 8 79 7TaT BT cToDTeET F Hexadecimal 80 84 88 sc 90 94 98 9c AO A4 As AC Bo B4 Ba BC Decimal 128 132 136 140 144 148 152 156 160 164 168 172 176 180 184 188 Unit addresses for serial port 2 Unit number 0 1 2 3 4 5 6 7 8 9 B C D E F Hexadecimal 81 85 89 8D 91 95 99 9D A1 A5 AD B1 B5 B9 BD Decimal 129 133 137 141 145 149 153 157 161 165 173 177 181 185 189 The three addresses used in FINS commands can be summarized as f
87. service to end or force executed the end of the service and then exe cute the command 06 Service The service is not being If necessary start the service stopped executed 07 No execution right The local node is not in the data link Execute the command from a LNK indicator on The right to execute the Unit Board service has not been obtained node that is participating in the data link A response was not returned Restart the Board If the problem because a buffer error persists replace the Board occurred 08 Settings not Settings required The settings required before Make the required settings complete before execution executing the service have not been made 09 Necessary Command data The required elements have Check the command format and set items not set not been set in the command the required elements in the data command data OA Number Action numbers The specified action transi Check the action transition numbers already defined and transition tion number has already to ones that are not being used and numbers of pro been registered in a then execute the command gram in program previous program area OB Error will Cause of error The cause of the error has Remove the cause of the error and not clear being cleared not been removed then execute ERROR CLEAR 01 No access right The access right is held by Wait until the access right is another dev
88. the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path command Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 1 3 End Codes for information on end codes Comments The CPU Unit s clock data will be recorded as the date of any directory that is created 226 FINS Commands Section 5 3 5 3 43 MEMORY CASSETTE TRANSFER CP series CPU Units Only 22 20 Transfers or verifies data between a Memory Cassette mounted in a CP series CPU Unit see note and the memory areas in the CP series CPU Unit Transfers can go either direction Note This command is supported only by CP series CPU Units Except CP1E CPU Units Applicable data Storage location in CPU Unit RAM user program area Parameter area PLC Setup CPU Bus Unit set RAM parameter area tings and routing tables Symbol table Built in flash memory Comment Memory Area Comments I O comments row comments and Built in flash memory Comment Memory Area annotations Program indices section names section Built in flash memory Comment Memory Area co
89. the end code of a sent command that is completed normally is 0040 Handling Network Relay Errors If bit 15 is ON an error has occurred during a network relay operation The end code has an additional two byte one word network relay error code which can be used to determine the location of the relay error The following diagram shows the response data when a network relay error occurs when CMND 490 is used Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 D First Re sponse Word Command code Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 21 0 D 1 1 Maincode Sub code 1 Fatal CPU Unit error 1 Non fatal CPU Unit error 1 Network relay error Bit D 2 Error network address Error network address 00 to 7F 0 to 127 Error Node Address Ethernet 01 to 7E SYSMAC NET 01 to 7E Controller Link 01 to 20 SYSMAC LINK 01 to 3E _s to 128 to 126 to 32 to 62 1 Use this information to determine the node where the error occurred and take appropriate measures Note When Using SEND 090 and RECV 098 Check the path the command took using the routing tables Check the end code and take appropriate measures for the relay node where the error occurred 162 Designating Command Parameters Section 5 2 5 2 Designating Command Parameters 5 2 1 Designating I O Memory Variable Area Addresses When reading from and writing to the I O memory variable area designate O memory area addresses as
90. the timing shown below Data Received from Host Computer Response Required Host computer 2 Serial Communications Response Board Unit Communications Port 1 Enabled Flag CEE E E ee ew ew ew ew ew ew ew ew ee ew ee 0 Command acknowledged t t Command completed No Response Required Host computer 2 Serial Communications 1 Board Unit Communications Port 1 Enabled Fla Command acknowledged t 4 Command completed 59 FINS Commands with Host Link Protocol Section 3 5 Command transmission to the host computer can commence even when the port is receiving a command from the host computer 1 The transmission of a response to the command from the host computer is postponed until the transmission of the command to the host computer is completed 2 When a response is not required from the host computer the Communica tions Port Enabled Flag will turn ON when the command to the host computer has passed from the CPU Unit to the port Host Computer Receiving Data 60 Response Required Host computer Command _ 2 Response Serial Communications Board Unit i 1 Communications Port Enabled Flag t 4 Command acknowledged Command completed No Response Required Host computer 1 2 Serial Communications Board Unit 1 Communications Port Enabled Flag Command acknowledged t 4 ommand completed At 1 in the diagram the response to a command sent from the host com pu
91. turn ON in the following cases Error Flags e When an error is generated during execution of SEND 090 RECV 098 or CMND 490 e When an error response or retry error has been generated for the port These Flags will turn OFF when the corresponding Communications Port Enabled Flag is turned OFF at the start of operation or at the start of execut ing the SEND 090 RECV 098 or CMND 490 wa e oo co R219 06 Communications Port Error Flag Port No 6 00 Communications Port Error Flag Pot No0 58 FINS Commands with Host Link Protocol Section 3 5 Communications Port The Communication Port Completion Code words will contain the FINS end Completion Codes code after SEND 090 RECV 098 or CMND 490 has been executed If the Communications Port Enabled Flag turns OFF when operation is started or SEND 090 RECV 098 or CMND 490 are executed the contents of these words will be cleared Flag Transitions Communications Port Enabled Flag Command 2 Command 1 E i Command 3 i being i being being i i i t Network communications instructions executed executed i executed SEND 090 RECV 098 CMND 490 Communications Port Error Flag Communications end code 0000 Normal end 0000 End of previous Normal end 0202 processing No unit corresponding to unit address 3 5 9 Timing of Commands to Host Computers Commands sent to a host computer are transmitted with
92. versions Pages 4 5 110 and 111 Note and references to it added and 21 40 and 21 41 added Pages 24 and 28 Note added Page 45 Information on destination unit address changed Page 55 Addresses corrected in program Page 110 Pages 111 to 113 Column added and 21 40 and 21 41 added Pages 146 and 167 Version changed to internal system version Page 163 FFFF added to table Page 166 Sections added on 21 40 and 21 41 August 2004 CompoBus D was changed to DeviceNet throughout the manual Pages 8 38 and 111 Notes added Page 15 Section 2 4 replaced Page 24 Note changed Page 28 Description of ICV and RSV changed Pages 28 29 41 49 and 50 Information on GCT changed Pages 28 29 31 40 45 46 and 48 Information added on new Ethernet Units and other settings changed Page 33 Information on unit addresses added Page 34 Graphic changed Page 35 Values for gateway count changed Pages 39 41 44 45 47 49 and 50 Values of GCT RSV changed Page 41 Description of RSV changed Page 58 Section added Page 70 Status definitions added to graphic Pages 111 and 113 Commands added to table Page 185 Commands 28 03 28 04 and 28 05 added 10 January 2006 Page v Information on general precautions notation added Page xxiii Information on liability and warranty added 11 October 2006 Corrections and additions were made throughout the manual to include the following Unit CP series PLCs C
93. wait time FINS command code Text FCS Terminator 1 080 characters 540 bytes max Sending Commands to a CPU Unit on a Network Note The following format can also be used to send FINS commands to a CPU Unit connected to the host computer Nes Saree Nene HS 7 WY WY 1 NY Head UnitNo fleader pepon ICF RSV GCT DNA DAI wait time DA2 SID FINS command code Text 1 080 characters T D a aa Host Link Settings The symbol must be attached to the beginning of the command Unit Number The unit number set is that of the destination CPU Unit connected to the host 45 FINS Commands with Host Link Protocol Section 3 5 46 computer When the host computer is connected to a CPU Unit the unit num ber is designated in the PLC Setup When the host computer is connected to a Serial Communications Board or a Serial Communications Unit the unit number is the designated in the Setup for the Board or Unit Header Code The header code distinguishes between different types of commands Set FA ASCII 46 41 when using FINS commands Response Wait Time The response wait time sets the time from when the CPU Unit receives a command block until it starts to return a response It can be set from 0 to F in hexadecimal in units of 10 ms Example If F 15 is set the response will begin to be returned 150 ms 15 x 10 ms after the command block was received ICF Information Control Field Specifies whether or not
94. will be returned Bit 15 OFF 0 Without last word data to be written Bit 15 ON 1 With last word data to be written Bits 0 to 14 No of words to be written Bits 0 to 7 second byte Bits 8 to 15 first byte Data Command The data to be written The leftmost bits bits 15 to 8 of each word must be specified first followed by the rightmost bits bits 7 to 0 The required number of bytes in total for each write can be calculated as follows No of words x 2 each word consists of two bytes End code response Refer to 5 1 3 End Codes for information on end codes 182 FINS Commands Comments Section 5 3 Parameters will be written regardless of the operating mode of the CPU Unit There are some settings in the PLC Setup that cannot and will not be written if the CPU Unit is in RUN mode but the end code will be 0000 nevertheless It is the user s responsibility to program steps to prohibit this command from being executed when the CPU Unit is in the RUN mode if such protection is neces sary Execute CPU UNIT STATUS READ command code 0601 to read the CPU Unit s mode Refer to 5 3 17 CPU UNIT STATUS READ 06 01 Data can only be written to the I O registration table when the CPU Unit is in PROGRAM mode All words in the specified parameter area must be written at the same time to ensure complete data A maximum of 498 words can be written with each command Nothing will be writte
95. x 107 x 10 x 10 x 16 x 16 x 16 x 16 kJ a ee eee ee Header Beginning word Write data 1 word FCS Terminator EN ORO Goo 0000 to 9999 Meade for number of words to write Response Format x 10 x 108 W D rasa a d A Unit No BCD Header End code FCS Terminator code Limitations The DM Area is comprised of D00000 to D32767 but the range that can be read by this command is D00000 to D09999 Execution Conditions Commands Responses Ptemos waa Single _ Multiple Single _ Muhiple RUN won PROG Wiiteprotectd Readkprotected End Codes An end code of 14 format error will be returned if the length of the command is incorrect or the first word of write data is not in the first frame An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundary the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of A5 will be returned instead of 15 for non hexadecimal write data in multiple command frames o nomani 118 C mode Command Details Section 4 3 4 3 15 AR AREA WRITE WJ Writes data to the Auxiliary Area A448 to A959 starting from the specified word Writing is done in word units Command Format see x10 x 10 W Jf x 10 x 107 x10 x 10 x 168 x 162 x 16 x 16
96. 00 hex The beginning address must be a multiple of four Number of bytes command and response Specify the number of bytes of data to write The number of bytes must be a multiple of 4 and 996 or less The leftmost bit bit 15 is used to indicate when program area writing is completed Bit 15 must be ON 1 the last word of data Bit 15 OFF 0 Not last word of data Bit 15 ON 1 Last word of data Bits 0 to 14 Number of bytes written Bits 0 to 7 second byte Bits 8 to 15 first byte Data command Specify the data to be written by designating the beginning address and the number of bytes End code response Refer to 5 7 3 End Codes for information on end codes The PROGRAM AREA WRITE command can be executed only when the CPU Unit is in PROGRAM mode A maximum of 996 bytes can be written with each command Partition the data into units of 996 bytes or less and use as many commands as necessary to write from 00000000 hex to the final address When the Prohibit from overwriting to a protected program setting is enabled this command cannot be executed 5 3 12 PROGRAM AREA CLEAR 03 08 Execution Conditions 186 Completely initializes the contents of the program area from the beginning of the program area to the final program address Access right at UM read DIP switch UM Network write other device protection write protection protection No OK o mo RUN mode MONITOR mode PROGRAM mode P
97. 001F00 TK an TKOOOO to 000000 to TKO031 001F00 000000 to 7FFFOF 90 to 97 E0 00000 to 32767 to 50 to 5F E7_00000 to 32767 000000 to 7FFF00 166 D00000 to 000000 to D32767 7FFFOO 000000 to 7FFFOO E000000 to 000000 to 2 E32767 7FFFOO TF 7 Section 5 2 Length Memory Per ele address Ment 000000 to 07FF00 000000 to 03FF00 080000 to OFFFOO 080000 to OBFF00 000000 to 07FF00 000000 to 03FF00 080000 to OFFFOO 080000 to aaa 2 Designating Command Parameters a B address Memory Memory Memory area address Section 5 2 CS CJ mode Memory Memory area Length Memory Per ele address address Ment Index PV DC IROO to IR15 010000 to 4 Register 010F00 Data PV BC DROO to 020000 to 9C DRO to DR2 000300 to 2 Register DR15 020F00 000500 Clock Pulses Condition Flags Note 07 Less Than Flag lt Negative Flag N Overflow Flag OF Underflow Flag UF Greater Than or Equals Flag gt Not Equal Flag lt gt Less Than or Equals Flag lt Always OFF Flag ON Always ON Flag OFF Access Error 200100 Flag 1 min clock pulse 1 s clock pulse 0 2 s clock pulse 0 1 s clock pulse 0 02 s clock pulse Error Flag ER Carry Flag CY Greater Than Flag gt Equals Flag 000000 000100 000200 000300 000400 100000 100100 100200 100300 100400 100500
98. 1 built in ports CPM1A built in ports CQM1 CPUL IL built in ports C200HS CPUL built in ports C200HX HG HE CPUL IL built in ports C200HW COML JL Communications Board ports CS CJ Series CS2H CPULIL EIP built in ports CJ2M CPU1L built in ports CJ2M CPU3L Serial Option Board CS1G H CPULILJH built in ports CS1G H CPULJLIJ EV1 built in ports CS1D CPULILIH built in ports CJ1G H CPULJLJH built in ports CJ1G CPULIL built in ports CJ1M CPUL JL built in ports CS1W SCB21 V1 41 V1 unit version Pre Ver 1 2 Serial Communications Board ports CS1W SCU21 V1 unit version Pre Ver 1 2 Serial Communications Unit ports CJ1W SCU21 41 unit version Pre Ver 1 2 Serial Communications Unit ports B mode CVM1 CPULIL built in ports Fixed length CVM1 CV CV CPULIL built in ports CV500 LK201 Host Link Unit C mode C200H LK101 LK201 LK202 Host Link 29 words 30 words 89 i 89 n Variable C200H Units Pe wore oral D mode C500 LK103 LK203 Host Link Units C500 C120 3G2A5 LK101 LK201 Host Link Units Note When the MS command reads the CPU Unit s status data and an FAL or FALS instruction has not been executed spaces ASCII code 20 hex are included as the FAL FALS message in the response frame for some models fixed length response in the table above In the other models no data is included as the FAL FALS message in the response frame variable length response frame if an FAL or FALS instruction has not been ex
99. 100600 100700 100800 100900 100A00 100E00 100F00 ail a el 1 The only current EM bank that can be read with FINS commands is the current EM bank that is set at the end of the cycle 2 Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F 167 Designating Command Parameters Section 5 2 Number of Elements for 1O MEMORY AREA READ 0101 and I O MEMORY AREA WRITE 0102 Volume Labels and File Names 168 Examples Designation Memory area Address within memory code area code CIO 0010 B0000A00 hex 000A hex 00 hex CIO 001013 30000A0D hex 30 hex 000A hex OD hex bit 13 of CIO 0010 W010 B10000A00 hex 000A hex W01013 31000A0D hex 31 hex 000A hex OD hex bit 13 of W010 H010 B2000A00 hex 000A hex H01013 32000A0D hex 32 hex 000A hex OD hex bit 13 of H010 CIO 001013 bit 13 of 70000A0D hex 70 hex 000A hex OD hex CIO 0010 with forced status CIO 0010 with forced FOOOOA00 hex FO hex 000A hex 00 hex status T0010 Completion 09000A00 hex 000A hex Flag D00010 value 82000A00 hex 000A hex E 3 00010 value A8000A00 hex 000A hex Current EM bank 98000A00 hex 98 hex 000A hex 00 hex 00010 value The maximum number of elements that can be specified for reading or writing with O MEMORY AREA READ 0101 and I O MEMORY AREA WRITE 0102 depends on the network that must be passed through Max number of read Max number of write elemen
100. 119 1 to 12 1 to 31 0 to 23 0 to 59 0 to 29 All data values are in binary Year Add 1980 to the value returned The year is the number of years since 1980 Second Multiply the value returned by two The value returned is expressed in units of two seconds End code response Refer to 5 7 3 End Codes for information on end codes 5 3 33 SINGLE FILE READ 22 02 Reads the contents of a file stored in the file memory Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode Command Format 22 02 12 bytes Command Disk No File name File position Data length Directory Absolute directory code length path Response Format Command End code File capacity File position Data length Data code Parameters Disk number command The classification of the file memory with the file name to be read is specified as follows 8000 hex Memory card 8001 hex EM file memory File name command Specify the name of the file to be read For details on the configuration refer to page 168 File position command Specify the number of bytes the relative byte address from the start of the file from which to start reading Files start at 00000000 hex Data length command Specify the number of bytes of data to read File capac
101. 1E NULIDUI LI NSJU UULULI B G5D NSJU OUULI B M3D Communications Commands Reference Manual SYSMAC CS CJ NSJ Series CS1G H CPULILI EV1 CS1G H CPULILIH CS1D CPULILIH CS1D CPULILIS CU2H CPU6L_I EIP CJ2H CPU6L CU2M CPULILJ CJ1H CPULILIH R CJ1G CPULILI CU1M CPULILI CU1G CPULILIP CJ1G H CPULILIH NSJU LUUULI B G5D NSJU OULLI B M3D Programmable Controllers Instructions Reference Manual SYSMAC CS CJ NSJ Series CS1G H CPULILJ EV1 CS1G H CPULILIH CS1D CPULILIH CS1D CPULILIS CJ1G CPULIL CJ1M CPULILJ CJ1G CPULILIP CU1G H CPULILIH NSJLI LILILIL B G5D NSJLI LILILIL B M3D Programmable Controllers Programming Manual SYSMAC CS Series CS1D CPULILIH CPU Units CS1D CPULILIS CPU Units CS1D DPLO1 Duplex Unit CS1D PA207R Power Supply Unit Duplex System Operation Manual SYSMAC CS Series CS1G H CPULILIJ EV1 CS1G H CPULILIH Programmable Controllers Operation Manual SYSMAC CJ Series CJ1G CPULILI CJ1M CPULILI CU1G CPULILIP CJ1G H CPULILIH Programmable Controllers Operation Manual SYSMAC CJ Series CU2H CPU6LI EIP CU2ZH CPU6L CJ2M CPULJL CPU Unit Software User s Manual W342 W474 W394 W405 W339 W393 W473 Describes the communications commands used with CS series CJ series and CP series PLCs and NSJ Controllers This manual Describes the ladder diagram programming instructions supported by CS CJU series PLCs
102. 200 END 210 PRINT ZTEXCEPTION DATA 220 GOTO 140 Explanation l2 3a 1 The host computer s transmission reception program is started up and the Host Link command is input 2 The Host Link command that was input is sent to the PLC and the data that is received is displayed on the screen Note The example program up to this point does not include an error processing routine in case reception is not normal e g if there is no FCS Include error processing routines when creating an actual program 400 FCSCHCK 410 L LEN RESPONSES Transmission reception data ADC O 04 PCSCKS 11 430 AS RIGHTS RESPONSES 1 440 PRINT RESPONSES AS L 450 IF A i THEN LENGS LEN RESPONSES 3 ELSE LENGS LEN RESPONSES 2 460 FCSPS MIDS RESPONSES LENGS 1 2 FCS data that is received 470 FOR I L TO LENGS Number of characters in FCS calculation 480 Q ASC MIDS RESPONSES1 1 XOR Q 490 NEXT 1 500 FCSDS HEXS Q 510 IF LEN FCSDS 1 THEN FCSDS i101 FCSD FCS calculation result 520 IF FCSD lt gt FCSP THEN FCSCK iERRi 530 PRINT iFCSDS 1 FCSD TFCSP i FCSPS iFCSCK 1 FCSCK Normal FCS reception space abnormal FCS reception ERR 540 RETURN 14 Precautions when Reusing Programs from Earlier Models Section 2 4 2 4 Precautions when Reusing Programs from Earlier Models Observe the following precautions when reusing host computer programs cre ated for communications with C series Host Link Units 2 4 1 C series Host Link Un
103. 5 3 29 ERROR LOG CLEAR 2103 00 ccc eee eee 209 5 3 30 FINS WRITE ACCESS LOG READ 21 40 209 5 3 31 FINS WRITE ACCESS LOG CLEAR 2141 211 529252 FILENAME READ 22 0 sasn ini icant go it paeeee esas 2 211 543 33 SINGLE FILE READ 22 Oia st ae onsarcdrar casts a Ryerbaeseesarc becee te 58 214 5 3 34 SINGLE FILE WRITE 22 03 0 cece nes 215 5 3 35 FILE MEMORY FORMAT 22 04 0 0 0 0 cee eee 216 520550 FILE DELETE 220 acs wt hae tea bedeue tied dscseeacees 217 3o FPILECOPY 2007 x ons ehh anna he Aa pe keh te OX 218 5 3 38 FILE NAME CHANGE 22 08 d4 444 2etsbce de scateidndetin 219 5 3 39 MEMORY AREA FILE TRANSFER 22 0A 220 5 3 40 PARAMETER AREA FILE TRANSFER 22 OB 222 5 3 41 PROGRAM AREA FILE TRANSFER 22 0C 224 5 3 42 CREATE DELETE DIRECTORY 22 15 0 226 5 3 43 oy CASSETTE TRANSFER CP series CPU Units Only 3 5 3 44 FORCED SET RESET 23 01 2 0 eens 228 5 3 45 FORCED SET RESET CANCEL 23 02 06 230 5 3 46 CONVERT TO COMPOWAY F COMMAND 28 03 230 5 3 47 CONVERT TO MODBUS RTU COMMAND 28 04 233 5 3 48 CONVERT TO MODBUS ASCH COMMAND 28 05 235 149 Command Lists Section 5 1 5 1 Command Lists 5 1 1 FINS Commands The following table lists the FINS commands Type Command w I O memory area EO AREA READ Reads the contents of consecutive I O access memory a
104. A WRITE WL 115 M N machine configuration reading 4 150 153 memory areas accessing I O 4 comparing transferring 220 reading 171 177 transferring data 179 writing 174 175 messages 194 clearing 199 displaying 5 150 153 reading 198 200 model code 3 101 model numbers reading model numbers of Units 192 reading PLC model number 189 MULTIPLE FORCED SET RESET FK 139 non fatal error data 194 O online edit precautions xvii operating environment precautions Xvill operating mode at startup Xix changing 4 150 153 P Parameter Areas accessing 4 150 153 clearing 183 comparing transferring 222 reading 180 writing 181 partitioned commands 10 partitioned responses 11 PLC changing to RUN mode 188 reading controller data 189 PLC model code reading 3 101 PLC MODEL READ MM 141 precautions application xix general xv operating environment xviii safety xvi program clearing 186 comparing transferring 224 reading 184 writing to program area words 185 program area accessing 3 4 101 150 153 PROGRAM READ RP 142 PROGRAM WRITE WP 143 R READ I O MEMORY QQIR 146 RECV 098 58 59 REGISTER I O MEMORY QQMR 145 remote I O systems 191 response codes 103 105 155 response formats for C mode commands 9 responses partitioned 11 S SA1 34 SA2 34 safety precautions xvi SEND 090 58 59 service ID 34 SID 34
105. ANY WAY CONNECTED WITH THE PRODUCTS WHETHER SUCH CLAIM IS BASED ON CONTRACT WARRANTY NEGLIGENCE OR STRICT LIABILITY In no event shall the responsibility of OMRON for any act exceed the individual price of the product on which liability is asserted INNO EVENT SHALL OMRON BE RESPONSIBLE FOR WARRANTY REPAIR OR OTHER CLAIMS REGARDING THE PRODUCTS UNLESS OMRON S ANALYSIS CONFIRMS THAT THE PRODUCTS WERE PROPERLY HANDLED STORED INSTALLED AND MAINTAINED AND NOT SUBJECT TO CONTAMINATION ABUSE MISUSE OR INAPPROPRIATE MODIFICATION OR REPAIR Xii Application Considerations SUITABILITY FOR USE OMRON shall not be responsible for conformity with any standards codes or regulations that apply to the combination of products in the customer s application or use of the products At the customer s request OMRON will provide applicable third party certification documents identifying ratings and limitations of use that apply to the products This information by itself is not sufficient for a complete determination of the suitability of the products in combination with the end product machine system or other application or use The following are some examples of applications for which particular attention must be given This is not intended to be an exhaustive list of all possible uses of the products nor is it intended to imply that the uses listed may be suitable for the products e Outdoor use uses involving potential chemical contam
106. ASCII code or local 4 bytes network node address Sub Command Text ETX address o MRC SRC ASCII code 03 hex 00 ASCII code 4 bytes 3030 hex etc Communications Frames Section 3 7 Note Response Frame 3 7 2 Modbus RTU Command Frame Note CompoWay F commands use ASCII as the transmission code Therefore be sure to use ASCII for the CompoWay F command after the FINS command code 2803 hex from node number to text using CMND 490 or other instruc tion Example If the CompoWay F command MRC SRC is 01 02 where the quotation marks indicate ASCII characters 0 1 0 2 must be treated as ASCII characters Therefore set 01 as 3031 hex not 01 hex and 02 as 3032 hex not 02 hex Further to write the CompoWay F command to the command storage area using CMND 490 in frame order without creating empty bytes the SID com ponent of the CompoWay F command requires 1 byte of ASCII as 30 hex so the subsequent components s 3 and afterwards must be set in one byte each Frame before Conversion CompoWay F Sub End code panied Response Text 2h x 10 5 address asc MR MRES ASCII h 02 hex 402 00 Gas SRC RES ae 0316x ASCII ASEN ASCII ASCII code 8 bytes code code 4 bytes S030 8 bytes 8 bytes hex etc _ Frame after Conversion oe 4 a gt FINS header FINS command FINS end code Remote Remote Remote MRC
107. ATUS READ Reads the CPU Unit s operating conditions Seed ing mode forced set reset status and fatal errors SC STATUS CHANGE Changes the CPU Unit s operating mode so ERROR READ Reads the CPU Unit s error information i e all fatal or non fatal errors currently in effect Forced set reset l FORCED SET Forcibly sets one designated bit FORCED RESET ts RESET FORCED RESET __ Forcibly resets one designated bit si resets one designated Forcibly resets one designated bit wli MULTIPLE FORCED SET RESET Forcibly sets resets cancels multiple designated bits KC FORCED SET RESET CANCEL Cancels all forced set reset status PLC model code CC PLC MODEL READ Reads the model code of the CPU Unit reading Testing TEST Returns just as it is a single block that was sent from the host computer Program area PROGRAM READ Reads in one batch the contents of the CPU Unit s accessing user program at the machine language object level WP PROGRAM WRITE Writes into the CPU Unit s user program area the machine language object sent from the host com puter I O table creation MI O TABLE CREATE Creates an I O table with the contents of the actual I O configuration I O memory area QQMR REGISTER I O MEMORY Registers the I O memory words or bits that are to registration and be read reading READ I O MEMORY Reads the registered I O memory words bits all at once Host Link commu XZ ABORT command only
108. Bas eatae xviii 5 Application Precaution aig 25 56 oas Gai Oe ATE ae ee ee E a Bae XiX SECTION 1 Introduccion 215 6556 ais eee ee Ge eee ee ee ee ees 1 1 1 Overview of Communications Commands 0 0 ccc cee eee eee 2 b gt Cmo Commie rises eaea aa a a oes ets eee ee 2 ly FINS CONDS en e e ates vee a Gd nk E E ee 4 SECTION 2 Overview of C mode Commands eccceeees 7 8 9 Zl Camode Commands 3334 50 deeded ead Shae Se tae tke eens eso 2 2 Command Response Formats 65 of caw op oeee Fide eh tae oP ee ke ee ate tees 2 3 JXpPpliCation Example 2 644 cceu scat ee swede ld eeteandba he tweeted ne oe bbe ade 14 2 4 Precautions when Reusing Programs from Earlier Models 0000005 15 SECTION 3 Overview of FINS Commands ccccccscees 27 Sel RUNS Commands 534 dudy sods oe bey eee te wwe Oe oe Oh ee eTA 28 So WWsine FINS Commands ccu2catencadncteecentles hie at legs eee at domed ate 30 3 3 FINS Command and Response Frames 00 e eens 32 3 4 Settings for Sending FINS Commands 0 0 ce eee eens 34 3 5 FINS Commands with Host Link Protocol 0 0 0 0 0 eee eens 43 ao SeralGadteway QverviewW lt s2 suc ns acerca twit Esa ei L868 ee EERE Re 66 Sor COmmuUunicalOns Frames saseda bea baaa Shon aae seme t Rec oa Rea eS 86 SECTION 4 C mode Commands cccccccccccccccccssecese 99 And CAm e CominanG VAS 44 eto cb ealn 6 heheh Gad oh es Gow a tetesied 100
109. C500 LK201 203 Manual 3G2A5 LK101 103 3G2A6 LK101 201 202 CQM1 CPU Unit CQM1 CPULIL Programming W228 E1 Manual CPM1 CPU Unit CPM1 LIUIWILI Operation W262 E1 Manual CPM1A CPU Unit CPM1A ULIUUL Operation W317 E1 Manual SRM1 CPU Unit SRM1 CL IL Operation W318 E1 Manual CVM1 and CPU Unit CVM1 CV CPULIL Operation W205 E1 CV Series Host Link Unit CV500 LK201 Manual 25 Precautions when Reusing Programs from Earlier Models Section 2 4 26 This section provides an overview of FINS commands 3 1 3 2 3 3 3 4 3 5 3 6 3 7 FINS COMMaiNdS vitare re aE E E E ERER Usine FINS Commands 2 242200 iaden ea raderer E ene tenes 3 2 1 Issuing and using any command CMND 490 instruction 3 2 2 Using with respect to a host computer connected by Host Link FINS Command and Response Frames 00 cece eee ees 3 3 1 FINS Command Frame Configuration 0004 3 3 2 FINS Response Frame Configuration 000000 3 3 3 Individual Items in Command Response Frames Settings for Sending FINS Commands 0 00 0 ce eee eee 3 4 1 FINS Command and Response Formats 3 4 2 Addresses in FINS Commands 0 000 e eee eee 3 4 3 Other FINS Command Settings 0 0 0 0 0 0 eee ees 3 4 4 CMND 490 Setting Example 0 0 0 0 0000 FINS Commands with Host Link Protocol 000000 3 5 1 Connection Con
110. Cassette Data t e designation command Bit 15 All or individual area designation OFF All ON Individual areas OFF All areas for bits 00 and 02 through 07 See note ON Only areas specified by bits 00 and 02 through 07 Multiple bits can be turned ON Bits 14 to 08 Reserved Bit 07 Data memory initial values Bit 06 Data memory Bit 05 Program indices Bit 04 Comments Bit 03 Symbol table Bit 02 parameter area Bit 01 Reserved Bit 00 User program Function block sources If bit 15 is OFF and any of bit 02 or bits 02 to 07 is ON an Other Parameter Error will occur and an end code of 110C hex will be returned End code response Refer to 5 1 3 End Codes for information on end codes Stored data type response When reading the data type in the Memory Cassette parameter 8000 hex the following bits corresponding to the stored data will be turned ON More than one bit may be turned ON Bit 07 Data memory initial values Bit 06 Data memory Bit 05 Program indices Bit 04 Comments Bit 03 Symbol table Bit 02 Parameter area Bit 01 Function block sources Bit 00 User program 5 3 44 FORCED SET RESET 23 01 Force sets ON or force resets OFF bits flags or releases force set status Bits flags that are forced ON or OFF will remain ON or OFF and cannot be written to until the forced status is released Execution Conditions Access right at UM read DIP switch UM Network write en coue
111. Cat No W342 E1 15 SYSMAC CS CJ CP Series CS1G H CPUL _ H CJ2H CPU6L EIP CP1H Xi JL LILI CS1G H CPUL _ EV1 CJ2H CPU6L CP1H XAU LLL J L CS1D CPUL_ _IH CJ2M CPUL CP1H Yi JULI CS1D CPULILIS CJ1H CPUL _ H R CP1L M LU ILI I U1 CS1W SCBL L V1 CJ1G H CPULI_IH CP1E E IDU_I L CS1W SCUL _ V1 CJ1G CPUL _IP CP1E Ni_ILIDUJ L CJ1G CPUL CJ1M CPUL L CJ1W SCULIL V1 SYSMAC One NSJ Series NSJL LILILIC B G5D NSJO OOO0O B M3D Communications Commands REFERENCE MANUAL SYSMAC CS CJ CP Series CS1G H CPULILIH CS1G H CPUL _ EV1 CS1D CPULI_JH CS1D CPULILIS CS1W SCBLILI V1 CS1W SCUL L V1 CJ2H CPU6_ EIP CJ2H CPU6 CJ2M CPUL CJ1H CPUL _JH R CJ1G H CPUL L_ H CJ1G CPUL L P CJ1G CPUL IL CJ1M CPUL CJ1W SCUL IL V1 CP1H X LLL CP1H XALLL CP1H YULUL L CP1L M LULL L CP1E E ID CP1E N DUI SYSMAC One NSJ Series NSJO OOO0O B G5D NSJO OOO0O B M3D Communications Commands Reference Manual Revised February 2010 Notice OMRON products are manufactured for use according to proper procedures by a qualified operator and only for the purposes described in this manual The following conventions are used to indicate and classify precautions in this manual Always heed the information provided with them Failure to heed pre cautions can result in injury to people or damage to property DANGER Indicates an imminently hazardous situation which if not avoided will res
112. Commands are divided with regard to timers and counters If an attempt is made to designate across timers and counters an end code of 15 entry num ber data error will be returned Execution Conditions Commands Responses Picmoas Umwea single Multiple Single Multiple RUN MON PROG Write protected Read protected_ x x N No x x KK End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundary the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of A5 will be returned instead of 15 for non hexadecimal write data in multiple command frames o noman SSS o sew SS 4 oma 15 Emyn SSS 8 meenen O O OSOS O a Notexecutable due to CPU Unt CPU ror as Aboned due to FCS error in transmitdata aa Aborted due to format error in transmit data PAB Aborted due to entry number data error in transmit data OO A8 Aborted due to frame length error in transmit data 13 14 15 18 21 A3 A4 A5 A8 117 C mode Command Details Section 4 3 4 3 14 DM AREA WRITE WD Writes data to the DM Area starting from the specified word D00000 to D09999 Writing is done in word units Command Format x10 x10 W D x 108
113. Controller Link DeviceNet RS 485 Modbus ASCIl Modbus ASCll Slave device Note 1 The FINS header contains the following information e Remote destination network address DNA Same as for CompoWay F e Remote destination node address DA1 Same as for CompoWay F e Remote unit address DA2 Same as for CompoWay F 2 The contents of the Modbus ASCII command enclosed in the FINS mes sage that is sent is as follows Slave address ASCII FUNCTION code ASCII Communications data ASCII 73 Serial Gateway Overview Section 3 6 The header 8A hex and LRC CR LF are not required when sending FINS They are added automatically for serial communications 3 6 6 Converting from FINS to Host Link FINS A PLC slave that is connected serially to the PLC master via Host Link can be accessed from the PLC master or personal computer see note using FINS messages Accessing a device on another network via Host Link serial com munications is also possible by using FINS messages By converting the FINS to Host Link FINS the PLC can function as a Host Link master Note Applications such as CX Programmer or CX Protocol that use CX Server aS a communications driver e Sent FINS message FINS header User specified FINS command see note 1 e Message after conversion FINS command enclosed in Host Link header and terminator see note 2 FINS message Hos
114. EA WRITE Writes the specified data in word units beginning with the designated EM word Timer counter SV R TIMER COUNTER SV READ 1 Reads in four digits BCD the constant SV that is reading written as an operand of the designated timer counter instruction R TIMER COUNTER SV READ 2 Finds the specified timer counter instruction begin ning with the designated program address and reads the constant SV in four digits or the word in which the SV is stored TIMER COUNTER SV READ 3 Finds the specified timer counter instruction begin ning with the designated program address and reads the constant SV in four digits BCD or the word in which the SV is stored 100 C modeCommandList Section 4 1 Type Header code Timer counter SV W TIMER COUNTER SV CHANGE 1 ee the SV timer counter number S of the changing specified timer counter instruction to a new constant SV Finds the specified timer counter instruction begin ning with the designated program address in the user program and changes the constant SV in four digits BCD or the word in which the SV is stored to a new constant SV or storage word TIMER COUNTER SV CHANGE 2 W TIMER COUNTER SV CHANGE 3 Finds the specified timer counter instruction begin ning with the designated program address in the user program and changes the constant SV in four digits BCD or the word in which the SV is stored to a new constant SV or storage word CPU Unit status ST
115. EM AREA READ Reads the specified number of words beginning with the designated EM word C mode Commands Section 1 2 Type Header code I O memory WR CIO AREA WRITE Writes the specified data in word units beginning with the writing designated CIO word WL LR AREA WRITE Writes the specified data in word units beginning with the designated LR word WH HR AREA WRITE Writes the specified data in word units beginning with the designated HR word WC TIMER COUNTER PV WRITE Writes the specified timer counter PV data in word units beginning with the designated word WD DM AREA WRITE Writes the specified data in word units beginning with the designated DM word WJ AR AREA WRITE Writes the specified data in word units beginning with the designated AR word WE EM AREA WRITE Writes the specified data in word units beginning with the designated EM word Timer counter SV R TIMER COUNTER SV READ Reads in four digits BCD the constant SV that is written as reading 1 an operand of the designated timer counter instruction TIMER COUNTER SV READ Finds the specified timer counter instruction beginning 2 with the designated program address and reads the con stant SV in four digits or the word in which the SV is stored TIMER COUNTER SV READ _ Finds the specified timer counter instruction beginning 3 with the designated program address and reads the con stant SV in four digits BCD or the word in which the SV is stored Timer counter SV
116. ER STATUS READ RG Reads the ON OFF status of the Completion Flags of the specified number of timers counters starting from the designated word T0000 to T2047 or C0000 to C2047 Command Format x10 x 10 R G x 10 x 10 x10 x 10 x 103 x 10 x 10 x 10 xo d ax Unit No BCD Header Beginning word No of words FCS Terminator code Timer 0000 to 2047 0001 to 2048 Counter 2048 to 4095 Response Format x10 x100 RG x 16 x 16 x J oo Unit No Header Endcode FCS Terminator BCD code Read data 1 word Read data for number of words read 1 ON 0 OFF Limitations The number of words per frame for response data is different to that for C series Units For details refer to 2 4 Precautions when Reusing Programs from Earlier Models The text portion of the response s first frame can contain up to 121 words If more than 121 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 124 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Designate 0000 to 2047 for timers and 2048 to 4095 for counters add 2048 to the actual counter number Timers
117. Eee eee gue wx 1 Number duplication A40113 Cee agaeeeueg hese uap ee eeeeg eae 1 I O setting error A401 10 ce 1 SYSMAC BUS error A40205 Limitations Only FAL and FALS numbers 0 to 99 can be read For numbers 100 to 511 FAL FALS number 00 will be set Execution Conditions 7 Commands Responses PiGmoas Umawa _Singie_ Multiple Single Multiple RUN MON PROG Write protected Read protected_ Pp OK No OK No x x x KK End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the error clear parameter is not set to 00 or 01 o oman 136 C mode Command Details Section 4 3 End code Hew Not executable Not executable due to CPU Unit CPU error 4 3 26 FORCED SET KS Force sets the operating status of operands Only one bit at a time can be force set Command Format x10 x 10 K S OP1 OP2 OP3 OP4 x 10 x 107 x 10 x 10 x 101 x 10 E J N Unit No BCD Ae Area classification Word address Bit FCS Terminator code Classifica Area classification Word aiia a ter 1 ter 2 ter 3 ter 4 elo fC fI OCS 0000to6143 o0 to15 tR E RCP wR WR SP C E E E AA 00 00 Note SP represents a space 20 Hex Response Format x 10 x 10 K S x 16 x 169
118. FINS com Addressed to CS CJ CP mands from a PLC CS CJ CVM1 CV or C200HX HG HE Z CPU Unit or series CPU Units and NSJ computer on another network or from a host computer connected directly to Controllers the local network Host computer PLC on another network CS CuJ series PLC vise CPU Unit Computer 29 Using FINS Commands Section 3 2 1 2 3 1 A FINS command sent from a PLC or computer on another network is transmitted to the CPU Unit from the Backplane of the CPU Rack via a Communications Unit Controller Link Unit Ethernet Unit etc FINS commands sent from a host computer to a CPU Unit are sent with a Host Link header code and a terminator as in the Host Link communica tions mode C Host computer Serial communications Host Link mode FINS command b Communications CS1 series i PU Unit Communications Unit CPU Unit PLC on network E Computer on network Communications Board Network Controller Link Ethernet etc The FINS commands available for CS CJ CP series CPU Units and NSJ Con trollers fall into the following broad categories Refer to the relative operation manuals for FINS commands addressed to other Units and Boards e O memory area reading and writing e Parameter area reading and writing e Program area reading and writing e Operating mode changes e Machine configuration reading e CPU Unit status reading e Time data access e Message reading and cl
119. Field Select the Use SYSWAY with the port option and enter the actual Host Link unit number for the target communications partner PLC in the Host Link Unit Number field see note Finally click the Apply Button 75 Serial Gateway Overview Section 3 6 The Serial Serial Gateway Guide Communications port address is automatically i J calculated Select the Unit the Unit Calculate Address Calculated Address 26200 A Select the port gt CPU ur Ba Hostlink EY SWAY Setting Select this option ME Use SYSWAY with the port If using Hostlink S sway calculated address will be Hostlink Unit reflected into Network number Mumber Enter the unit number for the actual Host Link values are Lancel HELP l incremented by 1 automatically Note When using the CX Programmer enter the actual Host Link unit number Do not add 1 to the value The CX Programmer will automatically add 1 internally Access from CX Programmer Connected to Network Network to Serial Routing tables to treat serial communications path as network Personal computers e g CX Pro Required CX Programmer etc grammer connected through the network to the PLC master can access a PLC slave that is con nected serially to the PLC master via Host Link FINS message Network Ethernet Controller soma LInk DeviceNet RS 422A 485 Host Link comman Used as
120. H built in ports CS1G H CPULJLIJ EV1 built in ports CS1D CPULILIH built in ports CJ1G H CPULJL_JH built in ports CJ1G CPULIL built in ports CJ1M CPUL JL built in ports Earlier versions unit version Pre Ver 1 2 Earlier versions of the Serial Communi CS1W SCB21 V1 41 V1 Serial Communi Cations Boards Units support only the cations Board ports 1 N Host Link format CS1W SCU21 V1 Serial Communications Unit ports CJ1W SCU21 41 Serial Communications Unit ports CVM1 CV Series Only the 1 N Host Link format is sup f F ported by the built in ports on CPU CVM1 CPULU built in ports Units of CVM1 CV Series PLCs as well CV CPULIL built in ports as the ports on Host Link Units and CV500 LK201 Host Link Unit Serial Communications Units Boards C Series Either the 1 N Host Link or 1 1 Host C500 LK103 LK203 Host Link Units Link format can be selected with these 3G2A5 LK101 LK201 Host Link Units Sertes Host Link Units 3G2A6 LK101 LK201 LK202 Host Link Units C Series C200H LK101 LK201 LK202 Host Link Units 1 1 format With this Host Link C Series Either the 1 N Host Link or 1 1 Host format the connec C500 LK103 LK203 Host Link Units Link format can be selected with these eee ae I 3G2A5 LK101 LK201 Host Link Units Serres Host Link Units 1 1 only 3G2A6 LK101 LK201 LK202 Host Link Units C Series C200H LK101 LK201 LK202 Host Link Units Note The following diagrams show the differences in the command and response frame
121. Hex Response Format Unit No BCD Header End code Constant area SV word address FCS Terminator code classification Classification Constant area classification Constant or ter 1 ter 2 ter 3 ter 4 Constant fe fo N _ C SP _ _ 0000t0 9990 coo e M o s mooo oo y R em e oowoo mo h R e e ooon w o w hR e e ooon D E E E E SA i Dmte fo fm fx heP 00000 9999 EMourenoa JE m fem fem 0000 sees EM indirect current x SD 0000 to 9999 bank EMbarks0t0C E m lowe SP 0000109999 n indirect banks 0 to E oyr 0000 to 9999 pea paese 0 a e ea Index register ndvect R 6P 0000100015 125 C mode Command Details Section 4 3 Note SP represents a space 20 Hex Parameters Limitations Execution Conditions Commands Responses Ptemos maa Single _ wutipie Single _ Multiple RUN won PROG Wiiteprotectd Readkprotected No Program Address Command Designates the program address in six digits decimal BCD for beginning the search for the specified timer counter Timer Counter Type Command Designate the timer counter instruction type for reading the constant SV or the word address in which it is stored Timer Counter Number Command Designate the timer counter instruction number for reading the constant SV or the word address in which it is stored Index register designation is not possi ble Con
122. Hexadecimal eo 64 as ec oo Toa se oc Ao aa as ac 80 ee es BC ea e Serial Port 2 Unit Addresses Unitnumber 0 1 2 3 4 5 6 7 8 9 A B C D E F Board Hexadecimal e1 65 60 Jen or Tos Joo 90 ar as ao aD er es Teo feo eS These settings enable the serial communications path to be treated as a sin gle FINS network Further the network address allocated to the serial port can be specified in the destination network address part of the FINS mes sage This enables messages to passed on to serial ports in a system com prised of multiple networks connected to a single PLC including the serial communications path FINS message CO e Serial Communications Unit Board CPU Unit es Sea Routing Local enabled network t i i 7 Serial communications path pecify on which pat Q send the message 85 Communications Frames Section 3 7 Reasons for Routing Tables CompoWay F Modbus RTU Modbus ASCll Protocol Conversion Routing tables are not required to enable serial communications paths to be treated as networks The serial port can be specified in the node without using routing tables by specifying the node to which the Board Unit is con nected and specifying the unit address as that of the serial port Host Link FINS Protocol Conversion and Use of Network Routing tables are required to enable the serial communications path to be treated as a network This is because wit
123. Host Link Master Personal computers e g CX Pro Required a a grammer connected through the network to the PLC master can access a PLC on another network Control Link bevieshlet via a PLC slave that is connected serially to the PLC master via Host Link pecified Terminator RS 422A 485 Host Link CS CJ series neue i eei or CVM1 CV ink Master series PLC Host Link Slave Network Ethernet Controller Link DeviceNet 76 Serial Gateway Overview Section 3 6 Sending FINS Messages or Sending Receiving Data Using CMND 490 RECV 098 SEND 090 in the CPU Unit s Ladder Program The Board Unit converts the FINS messages to Host Link FINS in this opera tion Access from CPU Unit on the Same PLC CPU bus to Serial Routing tables to treat serial communications path as network Serial Communications Unit Board Slave PLCs connected serially to Optional UNDG the Serial Communications Board SeND o0 Unit using Host Link can be a accessed from the CPU Unit in the same PLC RS 422A 485 Host Link Used as Host Link Master T Slave PLCs connected serially to Required i the Serial Communications Board Unit using Host Link can be accessed from a CPU Unit in a PLC connected to the network Network Ethernet Controller LInk DeviceNet a Terminator RS 422A 485 m Link ss as Host Link Master CS CJ series or CVM1 CV se
124. Host Link FINS command frames using the CMND 490 instruction always set the unit number for Host Link incremented by one 1 to 32 for the remote destination send destination node address word C 3 bits 08 to 15 of the CMND 490 instruction Do not set the unit number of the actual Host Link slave 0 to 31 Using the Host Link unit number without incrementing by one will access the PLC with the en tered Host Link unit number less one For example specify the remote PLC with Host Link unit number 2 by en tering 3 for the remote destination node address If 2 is entered the PLC with Host Link unit number 1 will be accessed To access a PLC on a Host Link FINS network using the Serial Gateway from CX Programmer however enter the actual Host Link unit number without incrementing by one Select Change PLC click the Display Se rial Gateway Guide Button and set unit number in the Host Link SYSWAY Settings field of the Serial Gateway Guide Dialog Box 3 The contents of the FINS command enclosed by the Host Link header and terminator is as follows Host Link unit number Host Link header FA FINS header FINS command Text FCS CR 3 6 7 Treating Serial Communications Paths as Networks When the Serial Gateway is executed routing tables are either required or optional as follows e Routing tables are required to treat a serial communications path as a network when converting FINS messages to Host Link FINS for serial conve
125. ILE COPY See note Copies files from one file memory to another file memory in the same sysiem 22 08 _ FILE NAME CHANGE See note Changes a file name 22 OA MEMORY AREA FILE TRANSFER Transfers or compares data between the See note I O memory area and the file memory 22 PARAMETER AREA FILE TRANSFER Transfers or compares data between the See note parameter area and the file memory 22 OC PROGRAM AREA FILE TRANSFER Transfers or compares data between the See note UM User Memory area and the file memory 22 DIRECTORY CREATE DELETE See Creates or deletes a directory note 22 20 MEMORY CASSETTE TRANSFER Transfers and verifies data between a CP1H CPU Units CP1L CPU Units Memory Cassette and the CPU Unit only Debugging 23 01 FORCED SET RESET See note Force sets or force resets bits or releases force set status 23 02 FORCED SET RESET CANCEL See Cancels all bits that have been force set note or force reset Serial Gateway 28 03 CONVERT TO COMPOWAY F COM Encapsulates a CompoWay F command functions MAND in a FINS command and sends it to a serial port The CompoWay F com mand is extracted and sent through the serial port at the receiving end 28 04 CONVERT TO MODBUS RTU COM Encapsulates a Modbus RTU command MAND in a FINS command and sends it to a serial port The Modbus RTU com mand is extracted and sent through the serial port at the receiving end 28 05 CONVERT TO MODBUS ASCII COM
126. K No OK OK OK OK OK End Codes 6 99 An end code of 14 format error will be returned if the data break between two items is omitted The command will be considered correct if there is a data break just before the FCS or at the beginning of a multiple frame com mand An end code of 15 entry number data error will be returned if the area classi fication word address or bit word setting is out of range including hexadeci mal data 00 omamo OOOO 4 3 36 READ I O MEMORY QQIR Command Format 146 Reads the word and bit data from multiple I O memory areas that was regis tered with QQMR x10 x10 Q Q R x J JN Unit No BCD Header code FCS Terminator C mode Command Details Section 4 3 Response Format x10 x10 7 Q Q I R x16 x 169 SEE x 108 x 10 x 101 x 10 N Unit No Header code End code timer counter word designation Data break BCD ON 1 OFF 0 word data BCD au 2 gt OFF n 1x16 x16 X16 x10 ad 2 1 Word data FCS Terminator Bit data CIO LR AR HR WR ON OFF DM EM and other word Hex data Limitations The data is read in the same order in which it was registered with QQMR Execution Conditions Commands Responses PiCmoas Umawa Single Multiple Single Multiple RUN
127. LEAR 09 20 and FAL FALS READ refer to 5 3 23 FAL FALS READ 09 20 commands share the same command code 0920 They are distin guished by bits 14 and 15 of the two byte parameter following the command code To clear messages bit 14 must be ON 0 and bit 15 must be OFF 0 5 3 23 FAL FALS READ 09 20 Reads FAL 006 FALS 007 error messages Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode Command Format Command FAL FALS No code Response Format 09 20 16 bytes Command End code FAL FALS Error message code No Parameters FAL FALS No command and response In the command format specify in hexadecimal in bits 0 to 13 the FAL or 200 FINS Commands Comments Section 5 3 FALS number to be read as shown below In the response format the FAL or FALS number is returned First byte Second byte aa IUO NAAS E NN Bt 15 14 13 8 7 0 5 55 O uy s FAL or FALS No 10 FAL FALS READ returned as 00 in the response Error message response The error message specified in the FAL 006 or FALS 007 instruction A single error message consists of 16 ASCII characters lf a message consists of less than 16 bytes spaces 20 hex will be returned for the remainder If no message has been registered for a message number that has
128. M write Network write other device protection protection protection OK OK RUN mode MONITOR mode PROGRAM mode 06 01 Command code rae S 06 01 16 bytes a S Command End code Fatal error Non fatal Message Error Error code data error data Yes no code message Parameters Status Mode Status response The operating status of the CPU Unit is as shown below Bits 3 to 6 are unde fined Always mask these bits before accessing them Undefined Status 0 Stop user program is not being executed 1 Run user program is being executed awe a Gere Built in flash memory access CS1 H CJ1 H CJ1M CP1H NSJ and CS1D only 0 Not writing 1 Writing ot Battery status CS1 H CJ1 H CU1M CP1H NSJ and CS1D only 0 No battery 1 Battery present oe CPU status 0 Normal 1 CPU on standby waiting for a signal from a device such as a SYSMAC BUS Remote I O Slave Unit 193 FINS Commands Section 5 3 Mode response The CPU Unit operating mode is as follows 00 PROGRAM 02 MONITOR 04 RUN Fatal error data response Fatal error data for the CPU Unit is configured as follows First byte Second byte Bit 15 14 13 12 11 10 9 8 7 6 0 0 0 0100 1 FALS error oS ee oe 1 Cycle time over Bo ee 1 Program error Pea eeasee wees 1 I O setting error Ogee Bees ee ea aee 1 I O point overflow re 1
129. MONITOR mode PROGRAM mode OK See note 2 OK See note 2 Note 1 Data can be transferred from the program area to the file memory 2 Data cannot be transferred from file memory to the program area in these modes Command Format seees 22 0C FF OFF 00 00 00 00 FF FF FF FF 12 bytes oe ee Command Parameter Program Beginning word No of bytes Disk No File name code code No Program area specification File specification Directory Absolute directory length path Response Format 2 0G Command End code Data length code Parameters Parameter code command Specify the transfer compare method as follows 0000 hex Data transfer from the program area to the file memory 224 FINS Commands Comments Section 5 3 0001 hex Data transfer from the file memory to the program area 0002 hex Data compared Program number and beginning word command Always FFFF hex Beginning word command Always 00000000 hex Number of bytes command Specify the number of data bytes to be transferred or compared Always FFFFFFFF hex Disk number command The classification of the file memory where the file to be transferred or com pared is registered is specified as follows 8000 hex Memory card 8001 hex EM file memory File name command Specify the name of the file to be trans
130. NDS 25 2 with SNA SA1 and SA2 TS 7 000F00C02 RSV 10244DA SA 81D CMNDCODE ENDCODE RESPDATAS GOSUB FCS RESPONSES TS FCSS i 7i Creates a response frame Returns received RSV SID without change ie Hs Hs Hs s PRINT 1 RESPONSE i Transmits data to PLC line GOTO 160 1 FCS Calculation Subroutine FCS Adds FCS L LEN T Asg FOR J 1 TO L TIS MEDS Tor ay 2 A tASC TJS XOR A NEXT J FCSS HEXS A EF LEN lt FCSS 1 THEN FCSS i107 FCSS RETURN Error processing PRINT iBRL i ERL iERRi ERR CLOSE T END 65 Serial Gateway Overview Section 3 6 3 6 Serial Gateway Overview 3 6 1 Overview FINS messages commands that are received are automatically converted into the corresponding protocol and then sent via serial communications The responses are also automatically converted FINS messages can be con verted into the following protocols e CompoWay F e Modbus RTU e Modbus ASCIl e Host Link FINS FINS commands enclosed in Host Link header and ter minator Note Serial Communications Boards Units can receive FINS commands via a FINS network including Host Link FINS or via the CPU bus Applicable Units and Serial Communications Ports Command after Applicable Units and serial communications conversion ports CompoWay F CS CJ series CPU Unit with unit version 3 0 or later serial port C on the Controller Section of an NSJ Controller or serial
131. OGRAM Valid Valid Valid Not valid Not Not Valid Not Valid WRITE valid valid valid MI I O TABLE Valid Not valid Valid Not valid Not Not Valid Not Valid GENERATE valid valid valid ORY REGISTER I O Valid Not valid Valid Valid Valid Valid Valid Valid Valid MEMORY XZ ABORT Valid Valid Valid Valid Valid Valid Valid Valid Valid command only xx INITIALIZE Valid Valid Valid Valid Valid Valid Valid Valid Valid command only IC Undefined com Valid Valid Valid Valid Valid Valid Valid Valid mand response only 4 2 End Codes End Code Summary These are the response end codes that are returned in the response frame When two or more errors occur the end code for the first error will be returned Contents Probable cause Corrective measures code Normal completion No problem exists 01 Not executable in RUN mode The command that was sent cannot Check the relation between the com be executed when the PLC is in RUN mand and the PLC mode mode 02 Not executable in MONITOR mode The command that was sent cannot be executed when the PLC is in MONITOR mode 03 UM write protected The PLC s UM is write protected Turn OFF pin 1 of the CPU Unit s DIP switch SW1 04 ddress over The program address setting in an Check the program read or write command is above the highest program address Not executable in PROGRAM mode The command that was sent cannot This code is not currently used b
132. Operand e Set the FINS command code 2803 2804 2805 hex in S e Set the data without spaces see note following the FINS command code in S 1 onwards Note Frames are set in the same order as in I O memory from leftmost to rightmost byte without blank bytes 00 hex C Operand C 2 bits 00 to 07 Send destination network address e With routing tables that treat serial communications path as a network Network address corresponding to serial port in the routing tables e Without routing tables that treat serial communications path as a network e CompoWay F Modbus Depends on the system configuration e Host Link FINS Always set the unit address of the serial port C 3 bits 08 to 15 Remote destination node address e CompoWay F Modbus e With routing tables that treat serial communications path as a network 00 hex indicates local PLC communications e Without routing tables that treat serial communications path as a net work Node address for specifying the actual remote PLC e Host Link FINS e Host Link unit number incremented by one 1 to 32 C 3 bits 00 to 07 Send destination unit address e CompoWay F Modbus Always set the unit address of the serial port 90 Communications Frames Section 3 7 Note Use either of the following methods to specify the serial port using the CMND 490 instruction e Set 80 81 hex 4 x unit number directly as the serial port unit address in the send destination unit address bits 00 to 07
133. Option Board of a CP series CPU Unit or a serial port on a Serial Communications Unit Board ver sion 1 2 or later the CPU Unit or Serial Communications Unit Board removes the FINS header and sends the enclosed Modbus RTU command With this command OMRON components connected to a PLC through Mod bus RTU communications can be accessed from a PLC or PT by sending a FINS message containing a Modbus RTU command Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode Command Slave Function Communications code address code data Command End code Slave Function Communications code address code data Command Slave Address Specify the Modbus RTU device address Set the address in hexadecimal between 01 and F7 hex 1 to 247 decimal Function Code Specify the function code of the Modbus RTU command Set the address in hexadecimal between 01 and FF hex 1 to 255 decimal Communications Data Specify the required parameters associated with the function code The amount of communications data varies In some cases there is no communi cations data Response The response is the same as the command except that it contains an end code 233 FINS Commands Section 5 3 Precautions e FINS Header Destination Address Contents The following settings are required e Destination Network Address DNA e When a routing table i
134. READ RG DM AREA READ RD AR AREA READ RJ EM AREA READ RE LR AREA WRITE WL HR AREA WRITE WH TIMER COUNTER PV WRITE WC DM AREA WRITE WD AR AREA WRITE WJ EM AREA WRITE WE TIMER COUNTER SV READ 1 R TIMER COUNTER SV READ 2 R 000000 TIMER COUNTER SV READ 3 R 2 TIMER COUNTER SV CHANGE 1 W TIMER COUNTER SV CHANGE 2 W 04 TIMER COUNTER SV CHANGE 3 W STATUS READ MS STATUS CHANGE SC ERROR READ MF FORCED SET KS FORCED RESET KR MULTIPLE FORCED SET RESET FK FORCED SET RESET CANCEL KC PLE MODEL READ MM or ois Cobh oota a a A a ee TESI TS gene ane nase PROGRAM READ RP PROGRAM WRITE WP oouo aaao aaan I O TABLE GENERATE MI ooon aaan REGISTER I O MEMORY QQMR aooaa READ I O MEMORY QQIR noaaraa anaa ABORT XZ 4e4d64e 6 INITIALIZE XX Undefined Command IC SECTION 4 C mode Commands 100 103 105 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 124 127 128 130 133 134 135 137 138 139 140 141 142 142 143 144 145 146 147 148 148 99 C modeCommandList Section 4 1 4 1 C mode Command List The following table lists the C mode commands Host L
135. RORCLER O O o o O 2103 ERRORLOGCLER mno 2141 FINS WRITE ACCESSLOG CLEAR No 220 2200 sneEFEwRmE O m 2204 FLEMEMORYFORM mn 2205 Febe o o y 2207 lFecoy O O o O 2200 FLENamEchaneE J oo y MEMORY AREA FILE TRANSFER I O memory to file transfers only 2208 PARAMETER AREA FILE TRANSFER No 2200 PROGRAM AREA FILE TRANSFER no 2015 CREMTEDELETE DIRECTORY mno 2220 MEMORY CASSETTE TRANSFER no Note ACCESS RIGHT ACQUIRE is used to prevent Programming Devices or other Units from taking the access right when more than one command is to be exe cuted in succession When finished always execute ACCESS RIGHT RELEASE 0C03 5 3 25 ACCESS RIGHT FORCED ACQUIRE 0C 02 Acquires the access right even if another device already holds it Access right at UM read DIP switch UM Network write other device protection write protection protection OK OK Execution Conditions RUN mode MONITOR mode PROGRAM mode Command Format 0C 02 FF EF es a Command Program code No Response Format OC 02 Command End code code 203 FINS Commands Parameters Comments 204 Section 5 3 Program number command Always FFFF hex End code response Refer to 5 1 3 End Codes for information on end codes Even if any other device has the access right the access right can be acquired with this command and a normal e
136. RY AREA READ 01 01 Reads the contents of the specified number of consecutive memory area words starting from the specified word Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode Command Format Command Beginning address No of items code AE binary I O Memory area code Response Format 01 01 Eee a Command End code Data for number of items code 171 FINS Commands Parameters 172 Note Section 5 3 I O memory area code beginning address number of items command Specify the type of data read the beginning address of the data to be read and the number of items of data to be read 2 digits hexadecimal The memory areas that can be read are given in the following table O Mem ory Area Codes Refer to 5 2 2 VO Memory Address Designations for the specific addresses that can be used Data response Indicates the data from the specified I O memory area is returned in sequence starting from the beginning address The required number of bytes in total is calculated as follows Number of bytes required by each item x number of items For details regarding data configuration refer to Element Data Configurations on page 163 End code response Refer to 5 7 3 End Codes for information on end codes 1 Ifthe specified number of elements is 0000 hex nothing will be re
137. Read data 1 word FCS Terminator BCD code Read data for number of words read Limitations The DM Area is comprised of D00000 to D32767 but the range that can be read by this command is D00000 to D09999 The text portion of the response s first frame can contain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Execution Conditions 7 Commands Responses PiCmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Cox n ox OK x OK ox o OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if 111 C mode Command Details Section 4 3 the specified words exceed the data area boundaries or are not specified in BCD or if the number of words to read is 0 o Normalcompleton SOS Entry number data error Frame length error Not executable due to CPU Unit CPU error 4 3 8 AR AREA READ RJ Command Format Reads the contents of the specified number of Auxiliary Area words A000 to A959 starting from the specified word
138. Second byte J 2 fC 2 2 2 OE Bit 15 8 7 6 5 4 3 2 1 0 Always 0 Message No 0 0 no 1 7 wey ee Message No 1 0 no 1 ee Message No 2 0 no 1 Re BG ee Es Message No 3 0 no 1 lt lt lt Oo DO O nn DN Cees see aes ee Message No 4 0 no 1 no 1 ee Message No 6 0 no 1 Sew eeneaaceaaseaeege Message No 7 0 no 1 Error code response Among errors that occur when the command is executed the error code indi cates the most serious If there are no errors it will be 0000 hex Error message response Indicates messages from execution of FAL 006 or FALS 007 If there is no error message or if FAL 006 or FALS 007 are not being executed 16 spaces ASCII 20 will be returned End code response Refer to 5 7 3 End Codes for information on end codes lt lt lt Oo ODO O nn Nn lt iq AANA AAA RH AH lt iq n Comments To read the error log read the appropriate Auxiliary Area words or execute ERROR LOG READ command command code 2102 Refer to 5 3 28 ERROR LOG READ 21 02 5 3 18 CYCLE TIME READ 06 20 Initializes the PLC s cycle time history or reads the average maximum and minimum cycle time Execution Conditions Access right at UM read DIP switch UM Network write other device protection write protection protection RUN mode MONITOR mode PROGRAM mode Pr ox o o o o Y O Command Format 06 20
139. See note L Text Header code FCS calculation range 0100 0011 0011 0101 0011 0100 4 Hex 0000 EOR EOR EOR 0001 0000 0010 0001 0010 i 2 Hex L Terminator FCS The value is converted to hexadecimal and handled as ASCII Note The FCS is an 8 bit value converted into two ASCII characters The 8 bit value is the result of an exclusive OR sequentially performed between each character in a transmission from the first character in the frame to the last character of the text in that frame Non ASCII data however may sometimes be sent in the text data If the data length is 7 bits the leftmost bit of each character is masked before the FCS is calculated 13 Application Example Section 2 3 2 3 Application Example Sending a Host Link Command from a Host Computer 10 20 30 40 3 60 70 80 In this example program a Host Link command is sent from a host computer and a response is received CS1 SAMPLE PROGRAM FOR EXCEPTION CLOSE LoS OPEN iCOM E73iAS 1 KEYIIN INPUT IDATA 1 S TE OSS LLIT HEN GOTO 190 PRINT ISEND DAIA 17 99 90 ST S 100 INPUT ISEND OK Y or N i BS 110 IF B iYi THEN GOTO 130 ELSE GOTO KEYIN 120SS STS 130 PRINT I SS Sends command to PLC 140 INPUT 1 RS Receives command from PLC 150 PRINT iRECV DATA 1 R 160 IF MIDS RS 4 2 1EXITHEN GOTO 210 Identifies command 170 IF RIGHTS RS 1 lt SiT47 THEN SS 17 GOTO 130 180 GOTO KEYIN LOO CEOSE 1
140. T2048 to T4095 and counters C2048 to C4095 cannot be read Commands are divided with regard to timers and counters If an attempt is made to designate across timers and counters an end code of 15 entry num ber data error will be returned 110 C mode Command Details Section 4 3 Execution Conditions PLC Mode UMArea O Single Multiple Single Multiple RUN MON PROG Write protected Read protected x No OK x OK x x o End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if the specified words exceed the data area boundaries or are not specified in BCD or if the number of words to read is 0 o omami SSS Entry number data error Frame length error Not executable due to CPU Unit CPU error 4 3 7 DM AREA READ RD Reads the contents of the specified number of DM words starting from the specified word D00000 to D09999 Command Format x10 x 10 R D x 108 x 10 x 101 x 10 x 10 x 107 x 10 x 10 x a A Unit No Header Beginning word No of words FCS Terminator BCD code 0000 to 9999 0001 to 9999 Response Format x10 x 10 R D x 16 x 16 x 16 x 16 x 16 x 16 kK d N E Unit No Header End code _
141. The data to be written should consist of two bytes For details regarding data configuration refer to Element Data Configurations on page 163 End code response Refer to 5 1 3 End Codes for information on end codes If the number of items is designated as 0000 hex a normal completion end code will be returned without the write operation being executed The MEMORY AREA FILL command can be executed regardless of the CPU Units operating mode It is the user s responsibility to program steps to pro hibit this command from being executed when the CPU Unit is in RUN mode if such protection is necessary Execute CPU UNIT STATUS READ command code 0601 to read the CPU Unit s mode Refer to 5 3 17 CPU UNIT STATUS READ 06 07 When data is written to the Timer Counter PV Area the Completion Flags will be turned OFF 0 Data cannot be written if the address is out of range If the specified area is force set or reset clear the force set reset to write the I O Memory Area Codes 176 data Data type CS CJ mode CV mode Bytes per memory area memory area element code c code o CIO Area Word Holding Bit Area e po Auxiliary Bit Area C a 5 n Timer Area i 2 ee DM Area C EM Area ou i 0 to C a to AF or a to 97 bank F ie to 5F see note EM a 10 60 to 68 to a 18 EM current Word bank Note Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F FINS Commands Section 5
142. U1G CPULILIP X XA and Y type CP1H CPU Units NSJ Controllers and version 1 of the Serial Communications Units Other changes and corrections are as follows Pages x to xvi Changed and expanded Pages xix and xx Models and manuals added Page xxxiv Added precaution on dispose of the product and batteries Pages 5 149 152 and 223 Added MEMORY CASSETTE TRANSFER command Page 15 Replaced most of page Page 19 Corrected last two rows of table Page 41 Changed last part of note 1 Pages 72 and 78 Changed PC to PLC multiple places Pages 84 227 229 and 231 Added Board column Page 171 Changed Comments section Page 191 Changed description of bits 00 and 01 12 September 2008 Corrections and additions were made throughout the manual to include the following Unit CJ2H CPULILIJ EIP and CP1L M LLUILILIL L1 242 Revision History Revision code Dae Revised content December 2008 Added the CJ series CJ2 CPU Units CJ2H CPULL July 2009 Added the CP series CP1E CPU Units Added the Ethernet option board CP1W CIF41 15 February 2010 Added the CJ series CJ2M CPU Units 243 Revision History 244 Authorized Distributor
143. a Daa Bit statu 5 3 46 CONVERT TO COMPOWAY F COMMAND 28 03 When this command is sent to a CS CJ series CPU Unit with unit version 3 0 or later serial port C on the Controller Section of an NSJ Controller built in serial ports of N type CP1E CPU Units serial port 1 or 2 on an Option Board of a CP series CPU Unit or a serial port on a Serial Communications Unit Board version 1 2 or later the CPU Unit or Serial Communications Unit Board removes the FINS header and sends the enclosed CompoWay F com mand With this command OMRON components connected to a PLC through Com poWay F communications can be accessed from a PLC or PT by sending a FINS message containing a CompoWay F command Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode 230 FINS Commands Command Format Response Format Section 5 3 Command Node Subaddress CompoWay CompoWay F CompoWay F code number 00 F command text ASCII 3030 in SID 0 code ASCII ASCII code ASCII 30 in code ASCIl 28 03 30 30 SAEN Command End code Node Subaddress CompoWay F CompoWay F CompoWay F code number 00 command response code text ASCII 3030 in code ASCII ASCII code ASCII code ASCII code Command Parameters Node Number This is the destination ID number 00 t
144. access right was not obtained Unrecognized Remote 1 O Unit too many I O words or word duplication used The command cannot be executed because a CPU error has occurred in the CPU Unit The UM is read protected or write protected An FCS error occurred in the second or later frame or there were two bytes or less of data in an intermedi ate or final frame for multiple writing The command format did not match the number of bytes in the second or later frame There was an entry number data error in the second or later frame a data length error or data was not set in hexadecimal Aborted due to frame length error in The length of the second and later transmission data frames exceeded the maximum of 128 bytes Check the command and divide it into multiple frames if necessary Register items to read before attempting batch read or obtain access right Check the Remote I O System the number of I O words and the words used Cycle the CPU Unit s power supply Clear write protection by setting pin 1 of the DIP switch on the front of the CPU Unit to OFF Alternatively clear the CPU Unit s password protection using CX Programmer Correct the command data and transfer the command again Note Occurs only for a Serial Communications Unit Board A response will not be received with some errors regardless of the command These errors are listed in the following table A command is received with
145. ad and a normal response will be returned 2 O memory can be read regardless of the operating mode of the CPU Unit FINS Commands Section 5 3 I O Memory Area Codes e memory area memory area element code code A Bi word aay Bit Area oe feonaa Flag PV Enr p DM Area gt N ae EM ae 10 to ae 18 EM bank 0 to Word aie to AF or a to 97 bank F ie to 5F see note to a 18 EMourent Bt ao o o pan e a E a m o E A e bank No Task Flag mK o Bt o ee s o e a ma xRegser R v pe e aoo o a aT 07 Note Ona CJ2 CPU unit only 50 to 5F can be specified for the memory area code of EM banks 0 to F to E8 EM Area EM bank 0 to Bit 20 to 2F bank F 173 FINS Commands Section 5 3 5 3 3 MEMORY AREA WRITE 01 02 Execution Conditions Command Format Response Format Parameters Comments 174 Writes data to the specified number of consecutive words starting from the specified word Access right at UM read DIP switch UM write Network write ener conce a RUN mode MONITOR mode PROGRAM mode OK OK oe 01 02 o Yo y Me Command Beginning address No of items Data for number of items code binary I O memory area code 01 02 Command End code code I O memory area code beginning address number of items command Specify the type of data written the beginning address of t
146. ad only from cyclic task 0 Cox mn OK No OK OK OK OK No End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the program address is not specified in BCD or the operand SV parameters are incorrect An end code of 16 command not supported will be returned if the specified instruction does not exist in the UM Area 00 _ Normalcompleton SOS 4 3 19 TIMER COUNTER SV READ 3 R 124 From the specified program address onwards in cyclic task 0 TIMER COUNTER SV READ 3 finds the specified TC instruction and reads the con stant SV that is set or the word address where the SV is stored The SV that is read is a 4 digit decimal number BCD C mode Command Details Section 4 3 Command Format x 10 x 10 R x10 x 104 x108 x 102 x10 x100 OP1 OP2 OP3 OP4 x 10 x 102x 10 x 10 o E a er Unit No BCD B Program address Timer counter type Timer counter number FCS Terminator Instruction name Timer counter type Timer counter Char Char Char Char number acter 1 acter 2 acter 3 acter 4 HIGH SPEED TIMER T M H W 0000 to 2047 WAIT merw p o Mm wo mensPeeDTmeR T o Mmo oo fToTaLZINGTIMER M o oo Mmo REVERSIBLE COUNTER C N m R mr F h m o Note SP represents a space 20
147. address command and response Specify the unit address of the first Unit whose connection data is to be read If the specified Unit does not exist the connection data is read from the next Unit Specify the following for the unit address CPU Unit 00 hex CPU Bus Unit 10 unit number 10 to 1F hex Special I O Unit 20 unit number 20 to 7F hex Inner Board E1 hex Number of items command Specify the number of items to be read The number of items will be returned in order for the number specified beginning with the unit address set in the unit address parameter Any number between 01 and 19 hexadecimal can be specified If the number of items is not specified 19 hex 25 will be used FINS Commands Section 5 3 Number of Units response The number of Units for which the connection data is being returned If bit 7 is ON 1 it means that the data for the last Unit is being returned The maxi mum setting is 19 hex 25 If the number of items is not specified 19 hex 25 will be used Unit address and model number response These response parameters show the unit address and model number The model number is provided in up to 20 ASCII characters End code response Refer to 5 1 3 End Codes for information on end codes 5 3 17 CPU UNIT STATUS READ 06 01 Execution Conditions Command Format Response Format Reads the operating status of the CPU Unit Access right at UM read DIP switch U
148. ade throughout the manual to include information for new products CS1G H made CPULILIH and CJ1G H CPULILIH In addition the following changes were Page ix Table updated Pages 16 Page 49 Page 115 Page 117 Page 118 Page 120 Page 125 Page 128 Page 132 Page 135 Page 137 21 New models added Response Wait Time description corrected 06 Program missing corrected 02 Parity of checksum corrected SFC removed from 01 No access right Two illustrations added and top illustration reworded Hex added Notes added Sentence added after table Addition made to bottom of page Sentence added toward end of 5 3 8 Pages 139 and 140 Number corrected at end of 5 3 10 and 5 3 11 Page 140 Page 141 Page 143 Page 144 Page 145 Page 151 Page 161 Page 162 Page 178 Page 179 Number of bytes description corrected All clear removed twice and execution changed to cyclic twice Addition made to command format and sentence added to end of 5 3 14 End of CPU Unit model and version description corrected Always 23 added to table Addition made to response format Last two lines removed End of 5 3 28 corrected Note moved Table column removed 241 Revision History August 2002 PC was changed to PLC throughout the manual in the sense of Programmable Controller CJ1M CPU Units and new versions of Serial Communi
149. ae S273 Wiodbus AS C iiss nudae haart gy o daa pectec Geb hadi ve EA IA HosGlink FINS rrur EEr nea eciee TANE ere eee 3 7 5 Sending Commands Using the CMND 490 Instruction SECTION 3 Overview of FINS Commands 28 30 31 31 32 32 32 33 34 35 36 41 42 43 43 44 45 49 50 55 57 58 59 62 66 66 67 67 70 73 74 78 79 81 84 86 86 87 88 89 90 27 FINS Commands FINS Commands 3 1 28 1 2 3 Section 3 1 FINS commands form a command system for message services across differ ent OMRON networks They can be used for various control operations such as sending and receiving data changing operating modes executing forced set and forced reset operations performing file operations and so on FINS commands make it possible to freely communicate with Units in various net works and on CPU Racks by simply specifying the network node and unit FINS commands have the following features 1 They are defined in the application level and do not depend on lower levels i e the physical and data link levels This allows them to be used across a variety of networks and CPU buses Specifically they can be used with Ethernet Controller Link and Host Link networks and between CPU Units and CPU Bus Units Note FINS commands can be sent with UDP IP headers when using Ethernet and with Host Link command headers when using Host Link 2 FINS commands can be used to access various kinds o
150. ally to a PLC via CompoWay F can be accessed from the CPU Unit or PT using CompoWay F commands enclosed in FINS messages e Sent FINS message FINS header FINS command code 2803 hex CompoWay F command e Message after conversion CompoWay F command 67 Serial Gateway Overview Section 3 6 CPU Unit PINS message CompoWay F command _ CompoWay F a sre OMRON instruction or aa CO Po Way command munications PONPON commend OMRON Component PT Program CompoWay F command encapsulated Unit Board mable Termi using FINS command 2803 hex aaa Via network or CPU bus CompoWay F Slave compatible Components Temperature Con Thermac NEO E5GN G components rollers Thermac R Plug in Temperature Control E5ZN lers Digital Controller Boards E5ZM Digital Controllers ES100X Timer Counters Timers Counters H8GN G components Digital Panel Meters Digital Panel Meters K3GN G components K3NX Digital Load Cell Meters K3NV Digital Rotary Pulse Meters K3NR Digital Incrementing Panel K3NP Meters Digital Time Interval Meters K3NC Digital Temperature Process K3NH Meters ZX Communications Interface ZX SF11 Units GamPostioners 3F68L 160 3F68L162 Safety Controles F System Configuration Patterns Sending FINS Messages Using CMND 490 in CPU Unit s Ladder Program The Board Unit converts the FINS messages to CompoWay F protocol for sending in this operation Access from CPU Unit on t
151. ana aa rk A a Sade ee elk XiX XV Intended Audience 1 1 Intended Audience This manual is intended for the following personnel who must also have knowledge of electrical systems an electrical engineer or the equivalent e Personnel in charge of installing FA systems e Personnel in charge of designing FA systems e Personnel in charge of managing FA systems and facilities 2 General Precautions The user must operate the product according to the performance specifica tions described in the operation manuals Before using the product under conditions which are not described in the manual or applying the product to nuclear control systems railroad systems aviation systems vehicles combustion systems medical equipment amuse ment machines safety equipment and other systems machines and equip ment that may have a serious influence on lives and property if used improperly consult your OMRON representative Make sure that the ratings and performance characteristics of the product are sufficient for the systems machines and equipment and be sure to provide the systems machines and equipment with double safety mechanisms This manual provides information for programming and operating the Unit Be sure to read this manual before attempting to use the Unit and keep this man ual close at hand for reference during operation N WARNING It is extremely important that a PLC and all PLC Units be used for the speci fied pur
152. and NSJ Controllers This manual describes programming and other methods to use the functions of the CS CJ series PLCs and NSJ Controllers Provides an outline of and describes the design installation maintenance and other basic opera tions for a Duplex System based on CS1D CPU Units Provides an outlines of and describes the design installation maintenance and other basic opera tions for the CS series PLCs Provides an outlines of and describes the design installation maintenance and other basic opera tions for the CJ series PLCs Describes the following for CJ2 CPU Units e CPU Unit operation e Internal memory e Programming e Settings e Function built into the CPU Unit Also refer to the Hardware User s Manual W472 1X SYSMAC CJ Series CU2H CPU6L EIP CJU2H CPU6L CJ2M CPUL JL CPU Unit Hardware User s Manual SYSMAC CS CJ Series CS1W EIP21 CJU1W EIP21 CJ2H CPU6L1 EIP CU2M CPULIL EtherNet IP Units Operation Manual SYSMAC One NSJ Series NSJ5 TQLIL1 B G5D NSJ5 SQLIL1 B G5D NSJ8 TVLILI B G5D NSJ10 TVLIL1 B G5D NSJ12 TS_IL1 B G5D NSJ5 TQL_IL B M3D NSJ5 SQLIL1 B M3D NSJ8 TVLIL B M3D NSUW ETN21 NSJUW CLK21 V1 NSJW IC101 NSJ Controllers Operation Manual SYSMAC CP Series CP1H X40DLJ L CP1H XA40DL1 L CP1H Y20DT D CP1H CPU Unit Operation Manual SYSMAC CP Series CP1H XLILIUILI LI CP1H XALILILILI L CP1H YUUIUILI U CP1H CPU Unit Programming Manual SYSMAC CP Series
153. ands 10 Command Response Formats Section 2 2 e FCS The 2 character FCS frame check sequence is returned e Terminator Two characters indicating the end of the command and CR CHR 13 are returned If a reception error or an error in executing the command occurs a response is returned with no text o E End code hexadecimal Header code Unit number BCD If a command is longer than 131 characters the command s text is partitioned by sending a delimiter CR code CHR 13 instead of a terminator at the end of each command frame until the last one A terminator is sent at the end of the last frame The procedure is given below for three command frames Note When sending command frames for writing WR WL WC WD etc be care 123 ful not to partition into separate frames data that is to be written into the same word 1 From the host computer attach a delimiter CR at the end of command frame 1 and send the frame 2 When the PLC receives this delimiter CR it will return only a delimiter CR to the host computer 3 From the host computer attach a delimiter CR at the end of command frame 2 and send the frame 4 When the PLC receives this delimiter CR it will return only a delimiter CR to the host computer 5 From the host computer attach a terminator CR at the end of command frame 3 and send the frame 6 When the PLC receives this terminator CR it will return the r
154. ange the current bank number The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Execution Conditions 7 Commands Responses PiCmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected_ o No OK OK OK OK OK OK OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if the specified words exceed the data area boundaries the specified words are not specified in BCD or an invalid bank number is specified An end code of 15 will also be returned if there are no banks and file memory access is not possible or if the number of words to read is 0 00 oman Entry number data error Frame length error Not executable due to CPU Unit CPU error 113 C mode Command Details Section 4 3 4 3 10 ClO AREA WRITE WR Writes data to the ClO Area CIO 0000 to CIO 6148 starting from the speci fied word Writing is done in word units Command Format ee ee ee x 10 x 10 Ws Rx 108 x 102 x 10 x 10 x 16 x 167 x 16 x 16 kJ es ey eee re Unit No BCD Header Beginning word Write data 1 word FCS Terminator code 0000 to 6143 Write data f
155. art FINS message internally CompoWay F compatible OMRON component Note When the NS series PT is con nected serially to the PLC using serial communications mode 1 N NT Links and the NS series PT sends FINS com mands encapsulated in NT Link commands using Smart Active Parts the CPU Unit removes the NT Link header etc from the received command converting it to a FINS command and trans fers the command to the Serial Communications Board Unit The Serial Communications Board Unit uses the Serial Gate way to convert the command into the specified protocol This oper ation enables serially connected devices to access the Serial Communications Board Unit from Smart Active Parts using an NS series PT Note 1 The FINS header contains the following information e Remote destination network address DNA 69 Serial Gateway Overview Section 3 6 e With routing tables that treat serial communications path as a network Network address corresponding to serial port in the routing tables e Without routing tables that treat serial communications path as a net work Network address for specifying actual remote PLC e Remote destination node address DA1 e With routing tables that treat serial communications path as a network 00 hex local PLC s internal communications For serial to serial to serial conversion increment the Host Link unit number by 1 e Without routing tables that treat serial communicatio
156. at UM read DIP switch UM Network write other device protection write protection protection Execution Conditions Command Format RUN mode MONITOR mode PROGRAM mode 207 FINS Commands 21 02 Command Beginning No of code record No records Response Format 21 02 10 bytes Command End code Max No of No of No of Error log code stored records stored records data records Parameters Beginning record number command Section 5 3 10 bytes i Error log data Specify the first record to be read The first record number is 0000 hex Number of records command response Specify the number of records to read The number of read records will be returned with the response Maximum number of stored records response Indicates the maximum number of records that can be stored Always 20 records Number of stored records response Indicates the number of records recorded at the time the command is exe cuted Error log data response The specified error log records will be returned in sequence starting from the beginning record number The total number of bytes required is calculated as follows No of records x 10 bytes The configuration of each error record is as follows 1st byte 10th byte Error code 1 Error code 2 Minute Day Hour Year Month Second Error code 1 2 Refer to 5 3 27 ERROR CLEAR 21 07 for i
157. ay Prohibit Switch turned OFF 3 6 2 Types of Protocol Conversion Type of conversion Destination from FINS address Converting to Serial port Frame before conversion Protocol after conversion using serial communica tions CompoWay F command Target commu nications part ner Processing at Board Unit CompoWay F OMRON Compo number on Board Unit CompoWay F 2803 hex CompoWay F command Converting to Modbus RTU 2804 hex Modbus RTU command 2805 hex Modbus ASCII command Converting to Modbus ASCII User speci User specified fied Converting to Any address Host Link FINS except Board Unit s serial port number command with FINS header removed sent to serial port Modbus RTU command with FINS header removed sent to serial port Modbus ASCII command with FINS header removed sent to serial port Transfers FINS command inside Host Link header and terminator 3 6 3 Converting FINS to CompoWay F Modbus RTU command Modbus ASCII command FINS com mand for Host Link communi cations nent e g Tem perature Controller Digital Panel Meter or Smart Sensor Modbus RTU Slave compatible device including OMRON 3G3JV 3G3MV and 3G3RV Inverters Modbus ASCIl Slave compatible device e g tem perature control ler indicator or power monitor OMRON PLC CS CJ CP NSJ Series or CVM1 CV Series OMRON Components connected seri
158. be deleted in sequence If non existing file names have been specified the PLC will ignore them and the operation will continue 5 3 37 FILE COPY 22 07 Execution Conditions 218 Copies a file from one file memory to another file memory connected to the same CPU Unit Access right at UM read DIP switch UM write Network write other device protection protection protection O m ox oo ox o RUN mode MONITOR mode PROGRAM mode FINS Commands Section 5 3 Command Format ee tae ae eae 2 22 07 12 bytes 12 bytes oe eee a B oh ee pee Command Disk No File name Disk No File name Directory Copy source Directory Copy destination code pare Desinanon length ne A length D ia Response Format 22 07 Command End code code Parameters Disk number command The classification of the copy source and copy destination file memory is specified as follows 8000 hex Memory card 8001 hex EM file memory File name command Specify the file to be copied and a new name for the copy destination file Directory length Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Copy source and copy destination absolute directory path Indicates the absolute path from the root directory I
159. because the output terminals on DC Output Units and other Units will momentarily turn ON when power is turned ON to the PLC Interlock circuits limit circuits and similar safety measures in external cir cuits i e not in the Programmable Controller must be provided by the customer Do not turn OFF the power supply to the PLC when reading or writing a Memory Card Also do not remove the Memory Card when the BUSY indicator is lit Doing so may make the Memory Card unusable To remove a Memory Card first press the memory card power supply switch and then wait for the BUSY indicator to go out before removing the Memory Card If the I O Hold Bit is turned ON the outputs from the PLC will not be turned OFF and will maintain their previous status when the PLC is Switched from RUN or MONITOR mode to PROGRAM mode Make sure that the external loads will not produce dangerous conditions when this occurs When operation stops for a fatal error including those produced with the FALS 007 instruction all outputs from Output Unit will be turned OFF and only the internal output status will be maintained The contents of the DM EM and HR Areas in the CPU Unit are backed up by a Battery If the Battery voltage drops this data may be lost Provide countermeasures in the program using the Battery Error Flag A402 04 to re initialize data or take other actions if the Battery voltage drops When supplying power at 200 to 240 VAC for CS series PLCs
160. byte ID for No 0 ID for No 1 ID for No 15 Reserved for system 32 bytes ID Format Bits 00 to 14 Model ID Bit 15 Unit presence 1 Present 0 Not present Remote I O data response The number of SYSMAC BUS Master Units mounted in remote I O systems is returned in a single byte 00 to 02 hex as follows 00 No of SYSMAC BUS Masters mounted second byte Always 00 Hex first byte 191 FINS Commands Section 5 3 CPU Unit information response The total number of racks CPU Racks Expansion I O Racks connected to the CPU Unit is returned in a single byte 8 bits of data in the configuration shown below Bt 7 6 5 4 3 2 1 0 Not used Number of Racks connected to the CPU Unit CPU Rack Expansion I O Racks 1 to 8 Hex End code response Refer to 5 1 3 End Codes for information on end codes 5 3 16 CONNECTION DATA READ 05 02 Execution Conditions Command Format Response Format Parameters 192 Reads the model number of the specified Units Access right at UM read DIP switch UM Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode 05 02 Number of items Command i ode Unit address 05 02 20 bytes 20 oyes Command End code Model number Model number code Unit address Unit address Number of items Data Unit
161. byte is always 80 hex and the parameter area is specified with the leftmost byte Beginning address command Specify the position in the parameter area for beginning the transfer or com parison The beginning of each parameter area is always 0000 Parameter Areas There are six parameter areas each of which has consecutive word addresses beginning from 0000 The areas that can be written to are shown below along with their parameter area codes Parameter Address range Parameter Address range area code Hex area code Hex PLC Setup Area 8010 0000 to 01FF 512 words VO Table Registration Area I O Table Registration Area 8012 0000 to O4FF 1 280 words 0000 to 1F3F g 8000 Routing Table Area 8013 0000 to 01FF 512 words CPU Bus Unit Setup Area 8000 words 8002 0000 to 143F 5184 words Number of items command and response In the command format the number of items is always FFFF hex so that the entire parameter area is specified In the response format the number of words transferred is indicated when data is transferred When data is com pared the response format indicates the position at which a verification error occurs or the number of words compared Disk number command The classification of the file memory where the file to be transferred or com pared is registered is specified as follows 8000 hex Memory card 8001 hex EM file memory File name command Specify the file
162. can be used in the user program SEND 090 RECV 098 and CMND 490 Memory area data can be sent from the CPU Unit to the host computer by using SEND 090 Command Format Received by the Host Computer The FINS command transmitted to the host computer when SEND 090 is executed is MEMORY AREA WRITE command code 0102 The command format received by the host computer is as shown in the following diagram Refer to MEMORY AREA WRITE 0102 in Section 5 FINS Commands for details Haele EET No ee code Response wait time DA2 SNA SA1 SA2 SID Command code Memory area N aaam Beginning Number of write Write data FCS Terminator write address elements 1 068 char acters max Control Words Control data must be set before SEND 090 is executed The control data is written in the following format starting from the first control word Bits 00 to 07 Bits 08 to 15 Number of send words Destination network address Bits 08 to 10 Serial port number Com Destination unit address Destination node address Bits 00 to 03 No of retries Bits 08 to 10 Comm port number Bit 15 Response setting C 4 Response monitor time unit 0 1 s Number of Send Words Set the total number of words of data to be transferred to the host comput er FINS Commands with Host Link Protocol Section 3 5 Serial Port Number Set the serial port number to which the host computer is connected Destination Network Address Set the network a
163. cations Units Boards were added Page 28 Description of GCT changed Page 35 Note added Page 125 Information added following table 07 May 2003 Changes were made throughout the manual to include information for new products CS1D CPULILIH and CJ1G H CPULILIEV1 Page ix Table updated to correct catalog numbers and add new catalogs Page xiii A caution added regarding back up information Page xiv Corrected CJ Series CPU Units to CJ1 CJI H CJ1M or CS1D CPU Units Page xv A caution added regarding operating differences between CS1 and CJ1 CJI H CJ1M or CS1D CPU Units when using factory settings Page 22 Table corrected to include new CS CJ series models Page 30 00 OA Hex for first read address in graphic corrected to OA 00 Hex Page 55 Order of steps 9 and 10 corrected in graphic Page 93 Bit 1 corrected to Bit 0 in graphic of response format Page 113 Note on flags in end code added Page 119 120 Information on flags in end codes and handling errors changed rage 132 00 corrected to in CV mode memory area code column for CIO Area and rea Page 150 Information on operating status parameters updated for new models Page 151 Reserved for system changed to 1 Duplex error in bit 14 of non fatal error data response Page 163 Table of error codes updated for new models December 2003 Pages xi to xvii PLP information updated Front of manual Information added on unit
164. communications path as a network it 1 Network address To PLC_1 serial port unit address e g 89 eo a a f PT Serial Communications Unit Board Serial communications E g Unit number 0 port 1 path Host Link FINS g Unit number 0 por 2 Node address PLC_2 unit numbers for Host Link Jl 0 to 31 1 i Serial communications path 3 Unit address To E CompoWay F Modbus PLC_2 serial port unit address e g 80 hex Target OMRON Component or Modbus Slave CPU Un PLC_2 No routing tables required to treat serial communications path as a network Specify the addresses as shown in the following example Address Specification Address Contents Example Remote network PLC_2 serial communications A address path network address A Remote node PLC_2 unit number for Host S 1 address Link 1 Remote unit 80 hex 128 decimal f N address ae port unit Calculated from unit number Serial communications 0 port 1 path Host Link FINS Serial Communications Unit Board E g Unit number 2 port 1 PLC_1 a No routing tables required to treat serial communications path as a network f pan Serial Communications Unit Board Serial communications E g Unit number 0 port 1 h a a ak ene Routing tables for treating serial communications path as a network 2 Node address F ee unit numbers for dill L A AA Host Link 0 to 31 1 I Cal
165. configuration of elements 221 FINS Commands Comments Section 5 3 Disk number command The classification of the file memory where the file to be transferred or com pared is registered is specified as follows 8000 hex Memory card 8001 hex EM file memory File name command Specify the file to be transferred or compared For details on the configuration refer to page 168 Directory length Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself MEMORY AREA FILE TRANSFER command code 220A can be executed regardless of the CPU Unit mode It is the user s responsibility to program steps to prohibit this command from being executed when the CPU Unit is in RUN mode if such protection is necessary Execute CPU UNIT STATUS READ command code 0601 to read the CPU Unit s mode Refer to 5 3 17 CPU UNIT STATUS READ 06 07 If data is written to the Timer Counter PV Area the Completion Flags will not be turned OFF The CPU Unit clock data upon completion
166. culated from unit number 0 port 1 A Serial communica 1 Network address To PLC_1 serial 3 Unit address Boro communications path network address A TOPLE Sena pOr Uni Target OMRON Component or Modbus Slave address e g 80 hex 83 Serial Gateway Overview Section 3 6 3 6 10 Explanation To treat the serial communications path as a network the serial port itself is recognized as a Communications Unit and is allocated a network address CPU Unit Peripheral port f Unit address 253 decimal RS 232C port f Unit address 252 decimal Commu Local network table in routing tables nications Ex ae Unit number Network Unit pressed C See note address i i __ 252 n Set correspondence Network Note The unit number is set as a CPU Bus Unit for Communica tions Units but the unit address is set for the serial port Assigned to network address n e Peripheral port 253 decimal e RS 232C port 252 decimal Serial communications path Serial Communications Unit Board Serial port f Unit address U iCommu Local network table in routing tables inications Ex a l Network Unit pressed E a e l U See note as n H Set correspondence Serial communications path Network Note The unit number is set as a CPU Bus Unit for Communica Assigned to network address n tions Units but the unit address 80 hex 81 hex unit number x 4 hex as a
167. d Disabled Disabled Disabled Disabled CLEAR oO O Program area access Operating punk ok Disab Disabled mode STOP Disabled Disabled changes O1 ee Machine configuration reading CPU UNIT DATA READ CONNECTION DATA CPU UNIT STATUS oo OK OK Disabied OK JOK Lal pi_ etockREAd fok ox fox ox ok 20 MESSAGE READ Disabled CLEAR Access rights 0C ACCESS RIGHT OK OK OK Disabled OK OK Disabled ACQUIRE 02 ACCESS RIGHT FORCED ACQUIRE 03 ACCESS RIGHT RELEASE Eroriog 21 lot ERRORCLEAR OK OK Ook _ Disabled 02 ERROR LOG READ J TI gt J J C Z 15 W Command Lists Section 5 1 FINS write 21 40 FINS WRITE ACCESS IOK OK OK OK OK OK OK access log LOG READ 21 41 FINS WRITE ACCESS _ OK OK OK Disabled OK OK Disabled LOG CLEAR o5 FLE DELETE Disabled Disabled o7 FILE COPY Disabled Disabled OA MEMORY AREA FILE IOK OK OK Disabled OK OK Disabled TRANSFER PARAMETER AREA OK note OK note OK Disabled OK OK note Disabled FILE TRANSFER 1 1 1 OK Type PLC status code RUN MONI PRO Write mode TOR GRAM i pro mode mode i tected i from Fle memory 22 o1 FILE NAME READ SINGLE FILE READ os SINGLEFILE WRITE OK Jok Jok _ Disabled OK OK Disabled 04 FILE MEMORY OK OK OK Disabled OK OK Disabled FORMAT 08 FILE NAME CHANGE Disabled Disabled C PROGRAM AREA FILE OK note note Disabled OK Dis Disabled TRANSFER 2 2 abled note
168. d cannot be executed while the UM Area is write protected Data is written from the beginning of the UM Area to the maximum limit of the program area An error will not occur if the command attempts to write program data beyond the maximum size of the program area The program data can be divided into multiple frames in units of 4 characters Execution Conditions Commands Responses Piemos maa Single wutipie Single _ Multiple RUN won PROG Wiiteprotectd Readkprotected o 143 C mode Command Details Section 4 3 End Codes An end code of 14 format error will be returned if the length of the command is incorrect the total size of the program is not a multiple of 8 bytes or the first frame contains no program data An end code of 15 entry number data error will be returned if the specified write data is not hexadecimal End code Hex Normal completion Not executable in RUN mode Not executable in MONITOR mode FCS error Format error Entry number data error Frame length error Not executable Not executable due to CPU Unit CPU error User memory protected Aborted due to FCS error in transmit data Aborted due to format error in transmit data Aborted due to entry number data error in transmit data Aborted due to frame length error in transmit data 4 3 34 I O TABLE GENERATE MI Corrects the registered I O table to match the actual I O table Command Format
169. d code Text Actual response data would be as follows Command Response Text 10 words 20 bytes code code of read data 35 Settings for Sending FINS Commands Section 3 4 3 4 2 Addresses in FINS Commands FINS commands are transmitted across networks and to various devices via network nodes Designate the addresses as follows e Designate the device from which the command is to be sent the network that the device is on and the node through which the command is to tran Sit e Designate the device to which the command is to be sent the network the device is on and the node through which command is to transit Addresses must be provided for the network node and device unit to iden tify them FINS commands include these addresses the transmission source and destination addresses in the command response frames Addresses for FINS Commands Address Designation method CMND 490 operand Designation in frame designation nen frame is created Network address 1 to 127 01 to 7F Hex Local ace address A Hex Node address 1 to 254 01 to FE Hex See note Yes Yes Note The node addresses differ for each network Internal Communications in PLC 00 Hex For Controller Link 01 to 3E Hex 1 to 62 For Ethernet Units with model numbers ending in ETN21 01 to FE Hex 1 to 254 For Ethernet Units with other model numbers 01 to 7E Hex 1 to 126 Unit address eCPU Unit 00 Hex eCPU Bus Unit Unit No 10 Hex Special I O Unit U
170. d transfers the contents of the specified number of consecutive I O memory area words to the specified I O memory area Access right at UM read DIP switch UM write Network write eer a Pron e RUN mode MONITOR mode PROGRAM mode OK OK 01 05 Command Beginning address Beginning address No of items code I O memory area code I O memory area code Source Destination 01 05 Command End code code I O memory area code and Beginning address command Specify the data area to transfer from and the data area to transfer to and specify the positions for beginning the data transfer The memory areas that can be transferred are given in the following table O Memory Area Codes Refer to 5 2 2 I O Memory Address Designations for the specific addresses that can be used Number of items command Specify the number of words of data to transfer Each word consists of two bytes The specified number of words will be transferred in sequence from the source beginning address onwards to the destination beginning address onwards End code response Refer to 5 1 3 End Codes for information on end codes If the number of items is designated as 0000 hex a normal completion end code will be returned without the copy operation being executed It is the user s responsibility to program steps to prohibit this command from being executed when the CPU Unit
171. ddress of the destination node Set 00 to send commu nications within the local network Destination Node Address set the node address of the destination node Set 00 when transmitting within the local PLC Destination Unit Address Set the unit address of the Unit to which the host computer is connected Response Setting Normally this bit is set to O to require a response When a response is not required set this bit to 1 Communications Port Number Set the port number in the CPU Unit which will transmit SEND 090 Number of Retries Set the maximum number of times SEND 090 is to be resent if no re sponse is returned Response Monitor Time If the Response Setting is set to require a response set the response mon itor time Control Word Settings The setting range for each item is shown on the following table Number of send words 0001 to 010B 1 to 267 words Serial port number 00 Do not set 01 Port 1 02 Port 2 Destination network 00 Local network address 01 to 7F Network address 1 to 127 Destination node address 00 Internal communications in PLC 01 to FE Node address of Ethernet Unit with model number ending in ETN21 1 to 254 01 to 7E Node address of Ethernet Unit with other model number 1 to 126 01 to 20 Node address 1 to 32 for Controller Link Destination unit address 00 CPU Unit 10 to 1F Serial Communications Unit unit address 0 to 15 E1 Inner Board Serial Com
172. dress 02 hex Serial port number 0 hex direct serial port unit address specification 058C hex Send destination node address 05 hex Send destination unit address 8C hex 0000 hex Response required Communications port number 0 Resends 0 hex 0000 hex Response monitoring time 2 s 93 Communications Frames Section 3 7 Response Operand Offset vae Meng O OO OOOO D 0 2804 hex Conversion to Modbus RTU FINS command code 2804 hex eee a 0000 hex FINS end code 0000 hex normal 0210 hex Modbus RTU slave address 02 hex FUNCTION code 10 hex DATA WRITE 0002 hex Write data register No 0002 hex frequency reference 0001 hex Number of write data registers 0001 hex 1 register Sending Host Link FINS Commands e Set any FINS command code in S e Be sure to set the Host Link unit number 0 to 31 incremented by one 1 to 32 for the PLC slave corresponding to the send destination node address in C 3 bits 08 to 15 Example of Sending Host Link FINS Commands Using CMND 490 The following example is for sending FINS commands to a CS CJ CP series PLC or an NSJ Controller connected to the Serial Communications Unit through an RS 422A 485 communications path via an Ethernet network Example The CMND 490 instruction is executed in the PLC on the Ethernet The FINS command e g OPERATING MODE CHANGE STOP 0402 hex is sent to the CS CJ CP series PLC or NSJ Controller Host Link unit number 1
173. e Data link status The data links are active Check the status of the data links 03 Wrong PLC The PLC is in PROGRAM Check the modes of the PLC and mode mode computer 04 Wrong PLC The PLC is in DEBUG mode Check the modes of the PLC and mode computer 05 Wrong PLC The PLC is in MONITOR Check the modes of the PLC and mode mode computer 06 Wrong PLC The PLC is in RUN mode Check the modes of the PLC and mode computer 07 Specified The specified node is not the Check node functioning as the node not polling node polling node for the network polling node 08 Step The mode is incorrect Check step status cannot be exe cuted 23 No such 01 File device Unit The specified memory does Mount memory or format EM as file device missing configuration not exist as a file device memory 02 Memory There is no file memory Check the file memory to see if it is missing mounted 03 is no clock ae the model 24 Cannot 01 Table a link tables The data link tables have not a the data link tables Start stop missing been registered or they contain an error 159 Command Lists Check point Probable cause 25 Unit error 02 Memory Contents of error memory being processed 160 03 I O setting I O Unit error configuration The registered I O tables do not agree with the actual I O configuration Section 5 1 The contents of memory Transfer the correct contents to contains an error m
174. e Remote PLC unit e Set 02 hex in bits 08 to 15 address number for Host send destination node unit number for Host Link of Link 1 address of control data C 3 in PLC connected to target Therefore set 1 1 the CMND 490 instruction serial port 1 2 Send destination unit CPU Unit 00 hex e Set 00 hex in bits 00 to 07 of address control data C 3 in the unit address of remote unit CMND 490 instruction on PLC connected to target serial port Serial Communications Unit Use the following equation to unit number calculate the unit address of the serial port 81 hex 4 hex X unit number 6 99 hex 153 decimal Use CX Net to set the local net work tables in the routing tables Network address Serial Communications Unit Shall on ste par ee nications Units work address serial port serial port unit decimal address 153 decimal e Host Link FINS Settings Command Frame Setting Setting location FINS command code e g cae 0402 hex Set in 0402 hex of control operating mode stop operation data S for CMND 490 instruction FINS command parameter e g FFFF hex Setin FFFF hex of control always FFFF hex to change operating data s 1 for CMND 490 mode instruction Response Frame Setting Setting location FINS command code E g ae 0402 hex Stored in D of CMND 490 instruction operating mode stop operation FINS command end code normal end 0000 hex Stored in D 1 of CMND 490 0000
175. e data access CLOCK READ Reads the present year month date minute second and day of the week CLOCK WRITE See note Changes the present year month date minute second or day of the week Message display MESSAGE READ CLEAR Reads and clears messages and reads FAL FALS messages Access rights 0C 01 ACCESS RIGHT ACQUIRE See note Acquires the access right as long as no other device holds it OC 02 ACCESS RIGHT FORCED ACQUIRE _ Acquires the access right even if another device already holds it ACCESS RIGHT RELEASE Releases the access right that has been acquired Error log ERROR CLEAR See note ERROR LOG READ Reads the error log ERROR LOG CLEAR See note Clears the error log pointer 150 Command Lists Section 5 1 Type Command code FINS write access 21 40 FINS WRITE ACCESS LOG READ The CPU Unit automatically keeps a log log of any access for FINS write commands This command reads this log 21 41 FINS WRITE ACCESS LOG CLEAR Clears the FINS write access log See note File memory FILE NAME READ Reads file memory data 22 02 SINGLE FILE READ Reads a specified length of file data from a specified position within a single file 22 03 SINGLE FILE WRITE See note Writes a specified length of file data from a specified position within a single file FILE MEMORY FORMAT See note Formats initializes the file memory 22 05 FILE DELETE See note Deletes specified files stored in the file memory 22 07 F
176. e executed when the PLC is in PROGRAM mode 13 FCS error The FCS is wrong Check the FCS calculation method If there was influence from noise transfer the command again 14 Format error The command format is wrong ora Check the format and transfer the command that cannot be divided has command again been divided or the frame length is smaller than the minimum length for the applicable command 15 Entry number data error The data is outside of the specified Correct the data and transfer the range or too long command again Hexadecimal data has not been specified 16 Command not supported The operand specified in an SV Check search data or the search Read or SV Change command does starting point not exist in the program 103 End Codes Section 4 2 Contents Probable cause Corrective measures code Frame length error Not executable ui Could not create I O table Not executable due to CPU Unit P e error See note ii memory protected Aborted due to FCS error in trans mission data Aborted due to format error in transmission data Aborted due to entry number data error in transmission data The maximum frame length of 131 bytes was exceeded If the frame exceeds 280 bytes the Reception Overflow Flag will be turned ON and there will not be a response The read SV exceeded 9 999 or an I O memory batch read was exe cuted when items to read were not registered for composite command or
177. e same contents specified for DNA DA1 and DA2 in the command that was received will be returned Setting SNA and SN1 is required for response formats only from a CPU Unit on a network SID Source ID The SID that was specified in the command that was received will be returned Command Code Response Code Text The command code response code and text corresponding to the FINS com mand and response formats will be returned FCS Frame Check Sequence A 2 character FCS will be returned Refer to FCS Calculations under 2 2 Command Response Formats for the FCS calculation method Terminator The terminator is a required delimiter at the end of a command The termina tor xCR ASCII 2A OD will be returned Example FINS Command Settings for Sending to CPU Unit on a Network 48 With Host Link communications FINS command transmissions and recep tions are handled in ASCII so hexadecimal values in FINS command frames must be sent as ASCII For example the hexadecimal value 0 would be 30 Hex in ASCII and the hexadecimal value A would be 41 Hex in ASCII The destination network address node address and unit number address are explained using the following network as an example FINS Commands with Host Link Protocol Section 3 5 Ethernet network network address 10 Host computer Controller Link Ethernet Unit o Ethernet Unit Node 1 Node 3 an Node 1 Host Link a ccuseecencaeusede Aeeneceancecc
178. e transmitted in sequence starting from the first file The total number of bytes required is cal culated as follows Number of read files x 22 bytes The configuration for each file data is as follows tst byte 22nd byte 12 bytes o File name Date time File capacity Attribute File Name Specify the name of the file Refer to Volume Labels and File Names on page 168 for the structure of file names Date and Time Indicates the date and time at which the file was created See the note below for details of the configuration File Capacity Indicates the size the number of bytes in four digits hexadecimal of the file Attribute First byte Second byte 4 4a xs Bit 15 a 8 7 6 5 4 3 2 1 0 TEE DE E E Reserved area Read only file Hidden file System file Volume label Subdirectory Archive file ee ee ee eee Note Date and Time Configuration The data and time consists of 4 bytes 32 bits and is configured in the way shown below 213 FINS Commands Section 5 3 1st byte 2nd byte 3rd byte 4th byte i Bit 31 to 2524 to 2120 to 1615 to 11 10 to 5 4 to 0 I 7 bits 4 bits 5 bits 5 bits 6 bits 5 bits J l J J J Year Month Day Hour Minute Second 0 to
179. e unit address of the Unit Board and the specified serial port It is not necessary to consider these addresses in the ladder diagram program Serial Port 1 80 Hex 04 Hex x unit number for Serial Communications Units E4 Hex for Serial Communications Boards and FC Hex CPU Units RS 232C or se rial port 2 on CP1H Option Board Serial Port 2 81 Hex 04 Hex x unit number for Serial Communications Units E5 Hex for Serial Communications Boards and FD Hex CPU Units peripheral port or serial port 1 on CP1H Option Board 2 The gateway count is decremented one for each bridge network that is passed through 41 Settings for Sending FINS Commands Section 3 4 3 4 4 CMND 490 Setting Example S First command word The designated number of bytes of FINS command data from the first com mand word designated by operand S is sent to the designated unit address via the node address on the network address designated by operand C and the response is stored for the number of bytes of data received starting from D CMND S First command word D First response word C First control word In this example a command MEMORY AREA READ 0101 Hex for reading D00010 to D00019 of the PLC at node 02 is sent using CMND 490 D00010 Memory area code 82 Hex address 000A00 Number of elements read 10 OA Hex C First control word s c o0 08 pa po Command code Number of command data bytes s 1 a2 00 o 00 18 Es If
180. earing e Access rights acquisition and release e Error log reading and clearing e File operations e Forced set reset Note When the Ethernet option board CP1W CIF41 is used a FINS command issued from a PLC or computer on the network can be received via the Ethernet option board but cannot be issued via the Ethernet option board 3 2 Using FINS Commands 30 FINS commands addressed to CPU units are issued to CS CJ CP series CPU units and NSJ Controllers by executing the instruction for the FINS com mand SEND RECV CMND instruction from a program of another PLC CPU unit on the network Executing a FINS command addressed to a CPU unit can be used for the following e Issuing and using any command CMND instruction e Using with respect to a host computer connected by Host Link Using FINS Commands Section 3 2 3 2 1 Issuing and using any command CMND 490 instruction The procedure for execution by CMND instruction is described below 1 23 1 Store the command format of the FINS command i e the command data in an I O memory area such as the DM area 2 In the same way store the control data number of bytes of transmission data destination address etc in an I O memory area such as the DM ar ea 3 Designate S first command word D first response word and C first control word for the CMND 490 operands and execute the instruction 4 When the FINS response is returned from the destination node a CS CJ
181. ected to a CS CJ CP NSJ serial Computers Connected to port e g on a CPU Unit Option Board Serial Communications Unit or Serial Ports serial Communications Board are shown in the following table Unit Board Peripheral port RS 232C port CS CJ series CPU Unit FD Hex 253 decimal FC Hex 252 decimal NSJ Controller FC Hex Serial port C on Bonet Section Built in serial ports of See note N type CP1E CPU Units Unit Board Serial port 1 Serial port 2 CS CuJ series Serial E4 Hex E5 Hex Communications Board CS CJ series Serial 80 Hex 04 Hex x unit 81 Hex 04 Hex x unit Communications Unit number number CP series Option Board FD Hex FC Hex See Note Note A FINS command to a host computer cannot be issued from a CP1E CPU unit For the SEND RECV and CMND instructions the CPU Unit will add the proper unit address based on the unit address of the Unit Board and the spec ified serial port It is not necessary to consider these addresses in the ladder diagram program Unit Addresses for Serial The network address and serial port s unit address must be allocated and the Ports on Serial routing table s local network table must be created for Several settings are Communications Boards required when making network settings FINS command system settings for and Units serial communications through a serial port on a CS Series Serial Communi cations Board or CS CJ Series Serial Communications Unit The network address and the
182. ected to the peripheral port or RS 232C port on the CPU Unit or to a serial ports on a Serial Communications Unit Board The Host Link protocol must be used regardless of the point of con nection CPU Unit Directly Connected to Host Computer SEND 090 RECV 098 CMND 490 43 FINS Commands with Host Link Protocol Section 3 5 CPU Unit Directly Connected to Host Computer on a Network SEND 090 RECV 098 CPU Unit CPU Unit Network Controller Link Ethernet etc Note 1 Host Link communications handle ASCII data so data is sent and received in ASCII Hexadecimal values in FINS command and response frames must therefore also be sent and received in ASCII when they are handled using Host Link communications 2 When a FINS command sent from a host computer or the CPU Unit with the CMND instruction is received by a Serial Communications Board or Unit with version number Ver 1 2 or later that PLC acts as the Host Link Master and it can send the FINS command to a Slave PLC through the Host Link system 3 When the Ethernet option board CP1W CF41 is used a FINS command cannot be issued to Host Link via the Ethernet option board Serial Communications Unit Sends FINS command L Ver 1 2 or later CMND A NNS O O Serial MHIC atewa INS Gateway aie FINS PLC Host link Master Host link Host link header terminator o dems Host link header Le ne oh a 3 5 2 Ove
183. ecuted 3G2A6 LK101 LK201 LK202 Host Link Units 19 Precautions when Reusing Programs from Earlier Models Section 2 4 Relationship to the 1 N Host Link 1 1 Host Link Setting The following table shows the allowed Host Link format 1 N Host Link 1 1 Host Link settings for each Host Link model compatibility setting Host link model Host link format compatibility mode A mode CS CJ and C Only the 1 N Host Link format can be used and B mode CVM1 CV C mode C500 C120 Either the 1 N Host Link format or 1 1 Host Link format and D mode C200H can be selected Settings for an Example Unit Replacement Use the following settings when the existing host computer was created for a system with C500 LK103 LK203 Host Link Units and or 3G2A5 LK101 LK201 Host Link Units a new Serial Communications Board or Unit Ver 1 2 or later is being used and the Host Link format is 1 1 Host Link e Host link 1 N format 1 1 format setting 1 1 1 Host Link format e Host link model compatibility mode setting 3 C mode C500 C120 2 4 2 C series Host Link Units with 1 1 Host Link Format Selected Using the CPU Unit s Built in Peripheral Port or RS 232C Port Only the 1 N Host Link format is supported by the CPU Unit s built in periph eral port and RS 232C port A host computer program cannot be used if it was developed for a 1 1 Host Link Using a Pre Ver 1 2 Serial Communications Board or Unit Only the 1 N Host Link format is s
184. ed when reading 121 words or 246 words through CVM1 and CV series CPU Unit built in ports or CVM1 CV series Host Link Units Number of Words 121 121 words O words terminator only Number of Words 246 121 words 125 words O words terminator only The second to last frame contains 125 data words and the last frame contains the terminator only This also applies when the number of words is 246 a multiple of 125 i e 371 words 496 words 621 words etc For responses containing the terminator only OO CR 00 FCS CR carriage return is returned Response Format for MS Command With the MS command STATUS READ the response data format when using CVM1 or CV series built in ports or Host Link Units is different from the response data format when using other Units When a CVM1 CV CPU Unit s built in Host Link port or CVM1 CV Series Host Link Unit is used and an FAL or FALS instruction has not been executed spaces ASCII code 20 hex will be included in the response data for the FAL FALS message With all other Host Link Units the FAL FALS message data is included in the response only when an FAL or FALS instruction has been exe cuted Using a Pre Ver 1 2 Serial Communications Board or Unit The response formats are the same as described above under the heading Using the CPU Unit s Built in Peripheral Port or RS 232C Port Using a Serial Communications Board or Unit with Version Number 1 2 or Later The Seria
185. efer to page 168 Directory length command Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path command Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 7 3 End Codes for information on end codes Comments The file name will not be changed if an existing file name is specified for the new file Even if the name of a file is changed the date of the file will remain unchanged Directory names can also be changed Specify the directory name in place of the file name 5 3 39 MEMORY AREA FILE TRANSFER 22 0A Transfers or compares data between the I O memory areas and the file mem ory Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection Oo n No XK KN RUN mode MONITOR mode PROGRAM mode 220 FINS Commands Section 5 3 Command Format 22 OA 12 bytes Command Parameter Beginning address No of Disk No Filename Directory Absolute
186. eight bytes or less from the to the delimiter Parity overrun or framing error during com mand reception Same even for commands address to other Units A command is received that does not have the character at the beginning of the first frame Incorrect node number Not a local unit BCD or over 31 pF PLC operation S pF PLC operation S The initial command 4 bytes executes the initial processing Other commands are discarded The Communications Error Flag will be turned ON an error code will be registered and receptions will be reset The error will be cleared auto matically if communications restart normally The command is discarded The command is discarded An LF code is received after the delimiter The LF code is discarded 104 C mode Command Details Section 4 3 Command End Code Table The following table shows which end codes can be returned for each C mode command Possible End Codes 4 15 te RR 00 21 RL 00 13 14 15 18 21 e RH 00 13 14 15 18 21 e RC 00 13 14 15 18 21 e RG 00 13 14 15 18 21 e RD Joo 13 14 15 18 21 e RJ 00 13 14 15 18 21 e RE 00 13 14 15 18 21 e WR loo o 13 14 15 18 21 A3 A4 A5 AB wL oo o1 13 14 15 18 21 A3 A4 A5 AB WH loo o 13 14 15 18 21 A3 A4 A5 AB wc joo o1 13 14 15 18 21 A3 A4 A5 AB wD loo o 13 14 15 18 27 AS A4 A5 AB w joo n n5 w o mmm WE 00 01 13 14 15 18 21 A3 A4 A5 AB w o n nsw aas gt
187. elow 55 FINS Commands with Host Link Protocol Section 3 5 56 Note efx x fo rfoje x uxIY NY a Unit No Header ICF code Response wait time Na N NO Ne RSV GCT DNA DA1 DA2 SNA SA1 SA2 SID Command code Text 1 080 characters max i Naaa N FCS Terminator Unit Number The unit number of the Host Link port connected to the host computer is set Header Code The header code in FINS commands sent to the host computer is always set to OF ASCII 4F 46 Response Wait Time The response wait time in FINS commands sent to the host computer is fixed at to 0 ASCII 4F 46 ICF Information Control Field Specifies whether or not a response is required Response required 80 ASCII 38 30 Response not required 81 ASCII 38 31 RSV Reserved Always set to 00 ASCII 30 30 in commands sent to the host computer GCT Gateway Count The number of networks through which the command is relayed subtracted from 2 is set See note Number of networks 0 02 ASCII 30 32 Number of networks 1 01 ASCII 30 31 Number of networks 2 00 ASCII 30 30 Number of networks 7 07 ASCII 30 37 The number of networks is subtracted from 7 for a CS CJ series CPU Unit with unit version 2 0 or later CP series CPU Unit or NSJ Controller DNA DA1 DA2 The addresses for the Host LInk Unit connected to the host computer are set DNA Destinat
188. emory Correct the I O tables or the I O configuration 04 Too many Number of I O in There are too many I O Change the registered I O table so I O points registered I O points and remote I O points that it is within the limit tables registered 05 CPU bus error CPU bus line 06 I O duplication Rack numbers Unit numbers and I O addresses in PLC Setup 07 I O bus I O bus line error 09 SYSMAC BUS 2 error SYSMAC BUS 2 transmission path OA CPU Bus Unit error CPU Bus Unit transmission path 0D SYSMAC _ Word settings BUS No duplication OF Memory Status of mem error ory being processed 10 SYSMAC BUS termina tor missing An error occurred in data transfer between the CPU and a CPU Bus Unit The same number address was set more than once An error occurred in data transfer between the CPU and an I O Unit An error occurred in data transfer on the SYSMAC BUS 2 line An error occurred in data transfer for a CPU Bus Unit The same word is allocated more than once Check Units Boards and cables to be sure they are connected cor rectly and then execute the ERROR CLEAR command Check the PLC Setup and correct the numbers addresses so that each is used only once Check Units Boards and cables to be sure they are connected cor rectly and then execute the ERROR CLEAR command Check Units Boards and cables to be sure they are connected cor rectly and then e
189. en when transferring data from the program area to file memory When the prohibit save to protected memory card and program transfer PLC to computer setting is enabled PROGRAM AREA FILE TRANSFER can not be executed When the prohibit overwriting of protected program setting is enabled FILE PROGRAM AREA TRANSFER cannot be executed 225 FINS Commands Section 5 3 5 3 42 CREATE DELETE DIRECTORY 22 15 Creates or deletes a directory Access right at UM read DIP switch UM write Network write other device protection protection protection Pp No XK KN Execution Conditions RUN mode MONITOR mode PROGRAM mode Command Format 22 5 12 bytes Command Disk No Parameter Directory Directory Absolute directory code name length path Response Format 22 15 Command End code code Parameters Disk number command The classification of the file memory where the directory is to be created or deleted is specified as follows 8000 hex Memory card 8001 hex EM file memory Parameter command Specify either creation or deletion as follows 0000 hex Create 0001 hex Delete Directory name command Specify the name of the directory to be created or deleted For details on the configuration refer to page 168 If the directory name is less than 12 bytes fill unused bytes with 20 hex Directory length command Indicates the length of
190. epe tion oe Cau TIMER iad hall lal ell ial aa le bal Yes tion COUNTER PV READ Cau TIMER Yes Yes Yes Yes Yes Yes tion COUNTER STATUS READ oF DM AREA lca Yes Yes oF READ Cau AR AREA hall hal hall hall hal bl Yes Yes ox READ i CE AREA CE FILE MEM hl ll ial al hl ll ball Leal all ll ball ORY DELUXE READ oe eee MEM No No K No No No No e READ DM AREA No No ial ai ial cl bai No No Yes No READ FIXED DM SIZE No No No No No No No Yes Yes No No No No No CHANGE Cau WR CIO AREA Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes tion WRITE Cau WL LR AREA Yes Yes Yes Yes No Yes No tion WRITE Cau WH ae AREA ee tion ae Cau WC TIMER lal hal hal cll ial all hall all uel ial ball tion COUNTER PV WRITE Cau WD DM AREA Yes eee Yes Yes Yes tion WRITE Cau WJ AR AREA Yes ial sll ical ial Yes Yes Yes ox WRITE ica hae AREA hae TIMER ha hl o ill ll ll lll ball ball bull COUNTER SV READ 1 TIMER Yes Yes Yes Yes No Yes No COUNTER SV READ 2 NA R TIMER Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes No No Yes No COUNTER SV READ 3 NA W TIMER Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes No Yes No COUNTER SV CHANGE 1 23 CVM1 and CV Series c D o g e a 2 c Q e gt E E je O C500 3G2A5 Host Link Unit D xX l n oO wo lt N O m oO N rr O Sin Board c m x a N lt
191. erand if sending the FINS command with CMND 490 If sending the FINS com mand by Host Link communications then put the destination address in the message Unit Addresses Set the unit address for the following purposes e To identify the Unit when there is more than one device connected at the same node on a network e To identify the type of device CPU Unit CPU Bus Unit etc at the desti nation Note The meanings of FINS commands will vary depending on the Unit at the des tination even when the commands have the same command code This is why the Unit at the destination must be identified by the unit address Unit addresses are as follows e CPU Unit 00 Hex e CPU Bus Unit Unit number 10 hex e Special I O Unit Unit number 20 hex e Inner Board E1 Hex CS Series only e Computer 01 Hex e Communications Unit with the specified node address connected to net work with the specified network address Controller Link or Ethernet FE Hex 37 Settings for Sending FINS Commands Section 3 4 Unit address 00Hex UnitNo s40Hex E1Hex nna omens Node Node Node address address address Node address Note Itis also possible to set the serial port No 1 to 4 for the destination device Serial Communications Serial Communications Unit Board CPU Unit Serial port 1 Serial port 1 Serial port 1 Serial port 2 CF sera ee D Ba Serial port 2 Am Unit Addresses for The unit addresses for host computers conn
192. esponse format with a terminator CR attached to the end Command Response Formats Section 2 2 The following diagram shows the command format when there are more than 131 characters Command frame 1 Command frame 2 Command frame 3 D w O Host gt E Computer a E 5 a 5 T i 128 characters max 128 characters max _ aie 2 2 E S S S E E JDE a 3 s 2 a D u D I Response frame Note A delimiter is a CR code CHR 13 sent as a single character to indicate the middle of a command or response Partitioned Responses If a response is more than 131 characters long the response from the PLC is partitioned by returning a delimiter CR code CHR 13 instead of a termina tor at the end of each frame until the last one A terminator is returned at the end of the last frame In the following example procedure the response is partitioned into three frames 1 2 3 1 When the PLC receives the command frame from the host computer it re turns response frame 1 with a delimiter CR at the end to the host com puter 2 Only a delimiter CR is sent from the host computer to the PLC 3 When the PLC receives this delimiter CR it returns response frame 2 with a delimiter CR at the end to the host computer 4 Only a delimiter CR is sent from the host computer to the PLC 5 When the PLC receives this delimiter CR it returns response frame 3 with a terminator CR
193. esponses PLGmos umaa Single Multiple Single Multiple RUN MON PROG Write protected Read protected oK mo ox n mo o OK o OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect The forced set reset cancel data can be 16 bytes long o oman 140 C mode Command Details Section 4 3 4 3 30 PLC MODEL READ MM Reads the model code of the CPU Unit Command Format x 10 x 10 M M Unit No BCD B FCS Terminator Response Format x10 x10 9 M M x 16 x 16 x 16 x 16 x E Unit No BCD Header End code Model FCS Terminator l code code Model code indicates the model in two digits hexadecimal Modelco wooo o fe o oe a tovo o a ovo z vo S w fome OOS a omoose CVM1 CPU21 E Execution Conditions Commands Responses PiLGmos umaa single Multiple Single Multiple RUN MON PROG Write protected Read protected OK No OK No OK OK OK OK OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect End code Hex 00 Normal completion Frame length error Not executable due to CPU Unit CPU error 141 C mode Command Details Section 4 3 4 3 31 TEST TS Returns unaltered one block of data tra
194. esses Set both to 00 ASCII 30 30 regardless of whether or not there is a network relay FINS Commands with Host Link Protocol Section 3 5 Setting SNA and SN1 is required only when sending to a CPU Unit on a net work SA2 Source Unit Address Set the unit address of the Unit physically connected to the host computer The setting changes depending on the connected Unit When connected to the CPU Unit Serial Communications Board or a Serial Communications Unit set 00 to indicate the CPU Unit ASCII 30 30 SID Source ID The SID is used as a counter when resending It should normally be set to 00 ASCII 30 30 Command Code Text set the command code and text according to the FINS command and response formats FCS Frame Check Sequence Set a 2 character FCS Refer to FCS Calculations under 2 2 Command Response Formats for the FCS calculation method Terminator The terminator is a required delimiter at the end of a command Set the termi nator to CR ASCII 2A OD Response Format from a CPU Unit The following response format is used to return responses from the CPU Unit to the host computer Note The length of the response must be not more than 1 115 characters Of this the response data without the response code is 1 076 characters 538 bytes Responses from a CPU Unit Directly Connected to the Host Computer Nene NY NO Ny L Unit No Header cod FINS command code FINS
195. eter 09 20 32 bytes 32 bytes Command End code Message No Message Message code parameter Message number parameter command and response In the command format turn ON 1 the bits of the messages to be read In the response format the bits of the messages being returned will be ON 1 If no bits are turned ON in the command format all bits will be OFF 0 in the response format and no further data will be returned FINS Commands Comments Section 5 3 First byte Second byte E 6 ae We a a 2s Lic cI Oc AS a a 010 0 T 7 i i i a i A Set to 0 Message No 0 a a S O E a a Message No 1 TEETE Message No 2 EEEE EEE Message No 3 a E Message No 4 00 Message read s eea ae ea Message No 5 fC Bee ees a pesue p is Message No 6 ee an Message No 7 Message response Each message is returned in numerical order from smaller to larger accord ing to the message number Each message consists of 32 ASCII characters 32 bytes The total number of bytes of the messages is calculated as fol lows The number of messages read x 32 bytes If a message consists of less than 32 bytes the remainder will be filled with spaces 20 hex If no message has been registered for a message number that has been requested 32 bytes of spaces 20 hex will be returned End code response Refer to 5 1 3 End Codes for information on
196. f devices besides CPU Units Devices such as CPU Units CPU Bus Units personal comput ers boards and Inner Boards can be identified and specified by their unit addresses CPU Bus Unit Inner Board CPU Unit m computer board 3 FINS commands support network relay operations so they can pass through a network hierarchy to access devices on up to three network lev els including the local network Network 2 Network 1 Network 3 Note With CS CJ series CPU Units with unit version 2 0 or later CP series CPU Units or NSJ Controllers devices can be accessed on up to 8 network levels When the destination of a FINS command is a CPU Unit the command can be sent through as many as 8 network levels When the destination of a FINS command is a node other than a CPU Unit the command can be sent through a maximum of 3 network levels FINS Commands Section 3 1 e The following table shows the maximum number of network levels that can be crossed by various PLC models PLC model Network levels Gateway counter setting CS CJ series CPU Unit with It is possible to select a maximum of either 8 lev unit version 3 0 an 4 3 levels Set with CX Programmer Ver CP series CPU Unit 1 NSJ Controller CS CJ series CPU Unit with Setting fixed at 8 levels max unit version 2 0 Pre Ver 20 CS CU series Setting fixed at 3 levels max CPU Units and CVM1 CV series CPU Units 1 Not possible with a CP1E CPU unit e When crossin
197. ferred or compared For details on the configuration refer to page 168 Data length response When data is transferred the data length parameter indicates the number of bytes that have been transferred When data is compared this parameter indi cates the amount of data that was compared with no errors or the number of bytes compared in a normal completion Directory length response Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path response Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 7 3 End Codes for information on end codes The clock data upon completion of a program area to file memory transfer will be recorded as the date of the file that has been transferred This command cannot be executed if any other device holds the access right or when memory is write protected via pin 1 of the DIP switch on the front panel of the CPU Unit PROGRAM AREA FILE TRANSFER command code 220C cannot be exe cuted when the CPU Unit is in the RUN or MONITOR mode Files cannot be overwritt
198. figurations 0 0 00 3 5 2 Overview of Command and Response Frames 3 5 3 Sending Commands from the Computer to the CPU Unit 3 5 4 Sending FINS Commands to the Host Computer from the CPU Unit 3 5 5 Sending Commands from the CPU Unit 3 5 6 Command Format Received by the Host Computer 3 5 7 Response Format Returned by the Host Computer 3 5 8 Flags for Network Communications 000 eee eee 3 5 9 Timing of Commands to Host Computers 3 5 10 Programming Examples cecene eyrin onnaa nen e eee dee Ree Seral Gateway Overview 60 s50ct tsani atau a aa a a a e ra a DON ONEN Gio eaa os aes So eae ae Ca eee eee 3 6 2 Types of Protocol Conversion 0 0 00 c eee ees 3 6 3 Converting FINS to CompoWay F 0 eee eee 3 6 4 Converting FINS to Modbus RTU 2 05 3 6 5 Converting from FINS to Modbus ASCII 3 6 6 Converting from FINS to Host Link FINS 3 6 7 Treating Serial Communications Paths as Networks 3 6 8 Usinga PLC as the Target lt aiacdoidde ii dedoksce peti sat 3 6 9 Using anon PLC Component as the Target 5 0210 Explanatio 2 5 61 c8 eh eae ee oa ete eee oe oe aaa Communications Frames windows eowteu tb eae werent eee a S212 COMPO WAV IE sas thnk ee One ee de SP ae le Coe Fia Modos RIU 24204 oe se oe eee oe seh Space ae Ou de e
199. g up to 3 network levels the CS CJ series CPU Units with unit version 2 0 and later CP series CPU Units and NSJ Controllers can be combined with other models When crossing 4 to 8 network levels configure the system with only unit version 2 0 and later CS CJ series CPU Units CP series CPU Units and NSJ Controllers Other models cannot be combined in the network with CS CJ series CPU Units with unit version 2 0 and later CP series CPU Units and NSJ Controllers If ear lier models are used a routing error end codes 0501 to 0504 will occur and the response may not be returned to the node that sent the com mand For details refer to 1 4 2 Communications through a Maximum of 8 Network Levels in the CS Series PLC Operation Manual or the CJ Series PLC Opera tion Manual Types of FINS Commands There are basically two kinds of FINS commands Those addressed to CPU FINS Commands Units and those addressed to CPU Bus Units Among FINS commands for CPU Units there are commands addressed to the various models of CPU Unit such as the CS CJ CP series CPU Units NSJ Controllers CV series CPU Units C200HX HG HE CPU Units and so on The basic code system is the same but the detailed specifications vary according to the CPU Unit Among FINS commands for CPU Bus Units there are commands addressed to Controller Link Units to DeviceNet Master Units to Ethernet Units and so on CS CJ CP series CPU Units and NSJ Controllers can receive
200. ge any static built up Not doing so may result in malfunc tion or damage e Do not short the battery terminals or charge disassemble heat or incin erate the battery Do not subject the battery to strong shocks Doing any of these may result in leakage rupture heat generation or ignition of the battery Dispose of any battery that has been dropped on the floor or oth erwise subjected to excessive shock Batteries that have been subjected to shock may leak if they are used e UL standards required that batteries be replaced only by experienced technicians Do not allow unqualified persons to replace batteries e Dispose of the product and batteries according to local ordinances as they apply Have qualified specialists properly dispose of used batteries as industrial waste CA GJ EEA EA e With a CJ series PLC the sliders on the tops and bottoms of the Power Supply Unit CPU Unit I O Units Special I O Units and CPU Bus Units must be completely locked until they click into place The Unit may not operate properly if the sliders are not locked in place e Unexpected operation may result if inappropriate data link tables or parameters are set Even if appropriate data link tables and parameters have been set confirm that the controlled system will not be adversely affected before starting or stopping data links e All CPU Bus Units will be restarted when routing tables are transferred from a Programming Device to the CPU Unit
201. ghtmost bits bits O to 7 The required number of bytes in total for each read is calculated as follows Number of words x 2 each word consists of 16 bits End code response Refer to 5 7 3 End Codes for information on end codes Y Comments All words in the specified parameter area must be read at the same time to ensure complete data A maximum of 498 words can be read with each com mand One word 16 bits To read larger parameter areas use multiple commands and specify the beginning word and number of words for each If more than 498 words is specified as the number of elements the maximum number of words will be read and returned with a response code of 1108 hex If the beginning word plus the number of words specified to read exceeds the capacity of the specified area the data read through the end of the area and the actual number of words read will be returned with a response of 1104 hex Except for the routing table area each area must be read or written in its entirety 5 3 8 PARAMETER AREA WRITE 02 02 Writes data to the specified number of consecutive CPU Unit parameter area words starting from the specified word Data can be written to the I O table only when the CPU Unit is in PROGRAM mode Note Some PLC Setup parameters cannot be written in RUN or MONITOR mode Access right at UM read DIP switch UM Network write other device protection write protection protection No ox mw w Executi
202. gnation ON OFF data only when other than word is designated by T C OP1 OP2 x lt l x 10 x 10 x 10 x 10 OP1 re OP3 OP4 J Data break Area classification Word address Bit word FCS Terminator Classification Area classification Word address SP 0000 to 0959 0000 to 0511 0000 to 0511 WR Time To eon e wo k k w ows EMbarks 010 fE M fo of oo00 o 9995 a Note SP represents a space 20 Hex Response Format x10 x100 Q QJM R x 16 x 16 x Unit No BCD Header code End code FCS Terminator Limitations LR 0000 to LR 0199 correspond to data link bits ClO 1000 to CIO 1199 145 C mode Command Details Execution Conditions Commands Responses PiGmos umaa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Section 4 3 The maximum number of items that can be registered is 128 and timer counter word designation is counted as two items lf all of the registered data is correct it will be registered to the table EM can be read through the current bank or bank designation The maximum EM bank number that can be specified is 12 OC Hex Bits and words can be specified in any order and they will be registered in the order that they were specified The data can be divided into multiple frames Cox ox O
203. h Host Link FINS the FINS remote node address is used to specify the target communications partner PLC that is the Host Link slave Therefore the node to which the Board Unit is mounted cannot always be specified depending on the FINS remote node address To specify the Unit at the target requires the FINS remote unit address Therefore the serial port cannot always be specified depending on the FINS unit address The network address for the serial communications path is used to specify from the network the node to which the Board Unit is mounted and the serial port Therefore routing tables must be used to enable the serial communica tions path to be treated as a network Host Link FINS Protocol Conversion and Use of Serial Connection Routing tables are not required to enable serial communications paths to be treated as networks The serial port in the node can be specified without rout ing tables by specifying the network address as the unit address of the serial port 3 7 Communications Frames 3 7 1 CompoWay F Command Frame Frame before Conversion Remote network address DNA Serial port allocated address or local network address STX 02 hex 86 FINSheader header FINS command command Remote Remote M a F node unit address address DA1 DA2 Serial Node No x 10 x 102 ASCII code 2 bytes Command Text port unit Kok MRC SRC ASCII code address 2 00
204. he the Board problem persists replace the Board 04 Unit Unit number The unit number was set Set the rotary switches correctly number error incorrectly being sure the unit numbers are within range and that each number is used only once 01 Undefined Command code The Unit Board does not sup Check the command code command port the specified command code 02 Not Unit model and The command cannot be Check the model number and supported by _ version executed because the model version model version or version is incorrect 01 Destination Routing table The destination network or Register the destination network address node address is not set in the and node in the routing tables 04 Destination node busy 05 Response timeout 03 Controller error 04 Service unsupported 05 Routing table error setting error routing tables 02 No routing Routing table Relaying is not possible Set routing tables in the source tables because there are no routing node designation node and relay tables nodes 03 Routing Routing table There is an error in the Set the routing tables correctly table error routing tables 04 Too many Network An attempt was made to Reconsiruct the networks or relays configuration send to a network that was change the routing tables so that over 3 networks away commands are sent within a range of 3 networks or less 156 Command Lists Section 5 1 Check
205. he Same PLC CPU Bus to Serial Routing tables to treat serial communications path as network OMRON components connected serially to Optional the Serial Communications Board Unit using CompoWay F can be accessed from a CPU Unit in the same PLC Serial Communications Unit Board FINS message Prot CompoWay F 2803 l CompoWay F command RS 485 CompoWay F CompoWay F compatible OMRON component 68 Serial Gateway Overview Section 3 6 Access from CPU Unit PLC on the Network FINS message to Serial Routing tables to treat serial communications path as network OMRON components connected serially Optional to the Serial Communications Board Unit a using CompoWay F can be accessed from compe a CPU Unit in a PLC connected to the net work Network Ethernet Controller Link DeviceNet RS 485 CompoWay F o00 CompoWay F compatible OMRON component Executing Smart Active Parts Using an NS series PT Sending Internal FINS Messages The Board Unit converts the FINS messages to CompoWay F protocol for sending in this operation NS series PT Access via serial communications using Optional CompoWay F is possible from a PT con nected to the network by executing a Smart Active Part that is connected seri ally which automatically sends an internal FINS command Smart Active P
206. he commands are explained in the following section 2 2 Command Response Formats Single frame Commands If a command is not more than 131 characters long communications can be completed by sending a single command frame This is called a single frame command Command Frame Format rs Lint Header code FCS Unit number BCD Must be attached at the beginning of the command e Unit number Set in BCD from 0 to 31 for each Host Link Unit e Header code Specified in two characters e Text Set parameters corresponding to command code e FCS Calculate 2 character FCS frame check sequence at host computer For details on calculating FCS refer to FCS Cal culations later in this section e Terminator Set and CR CHR 13 as two characters to indicate the end of the command Single frame Response lf a response is not more than 131 characters long the communications can be completed by returning one response frame This is called a single frame response Response Frame Format T oo End code hexadecimal Header code Unit number BCD Must be attached at the beginning of the response e Unit number Set in BCD from 0 to 31 for each Host Link Unit e Header code The command code that was received is returned e End code The results error status etc of command execution is returned e Text Returned only if there is read data Error Response Formant Partitioned Comm
207. he contents of the specified number of words starting from the specified word Command Format x10 x10 9 Ro L x 108 x 10 x10 x 10 x 10 x 107 x 10 x 10 x a i Unit No BCD Header Beginning word No of words FCS Terminator code 0000 to 0199 0001 to 0200 Response Format x10 x100 R L x 16 x 16 x 16 x 16 x 16 x 16 RK J a oe Unit No BCD ao End code Read data 1 word FCS Terminator code Read data for number of words read Limitations The text portion of the response s first frame can contain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters 107 C mode Command Details Section 4 3 Execution Conditions PLC Mode UM Area Single Multiple Single _ Multiple RUN MON PROG Write protected Read protected p OK No x x OK x x OK End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if the specified wo
208. he data to be written and the number of items of data to be written 2 digits hexadecimal The memory areas that can be written are given in the following table O Memory Area Codes Refer to 5 2 2 I O Memory Address Designations for the specific addresses that can be used Data Command The data from the specified I O memory area is returned in sequence starting from the beginning address The required number of bytes in total is calculated as follows Number of bytes required by each item x number of items For details regarding data configuration refer to Element Data Configurations on page 163 End code response Refer to 5 1 3 End Codes for information on end codes If the number of items is designated as 0000 hex a normal completion end code will be returned without the write operation being executed The MEMORY AREA WRITE command can be executed regardless of the CPU Unit s operating mode It is the user s responsibility to program steps to prohibit this command from being executed when the CPU Unit is in RUN mode if such protection is necessary Execute CPU UNIT STATUS READ command code 0601 to read the CPU Units mode Refer to 5 3 17 CPU UNIT STATUS READ 06 01 When data is written to the Timer Counter PV Area the Completion Flags will not be turned OFF 0 FINS Commands Section 5 3 I O Memory Area Codes e ee memory area memory area element code z code Bi Word Ruxiaty Bit Area ar
209. he final absolute path No set ting is required to specify the root directory itself Disk data response Indicates the file memory data The configuration is as follows tst byte 26th byte 12 bytes be Date time Total capacity Unused capacity Total No of files ade 212 Volume Label The volume label is the name registered with the file memory For details on the configuration refer to page 168 Date and Time The date and time show the date and time that the volume label was created Total Capacity and Open Capacity The total capacity and open capacity show the total capacity of the file mem ory being used and the number of bytes still available hexadecimal FINS Commands Section 5 3 Total Number of Files The number of files recorded in the absolute directory path Volume labels hidden files system files subdirectories the current directory indicated by and the parent directory indicated by are all counted as files The root directory can contain a volume label but not a current directory or parent directory mark Number of files response The number of files that have been read Bit 15 is ON 1 if the last file is included Bit 15 OFF 0 Without last file Bit 15 ON 1 With last word file Bits 0 to 14 No of files read Bits 0 to 7 second byte Bits 8 to 15 first byte File data response Each file data consists of 22 bytes The specified files will b
210. hex of this value in the s 4 of CMND 490 leftmost byte of S 4 Set 00 hex as the leftmost register No in the rightmost byte of S 4 Register No 0002 hex data e g 0064 6400 hex Set 6400 hex in controller data hex s 5 of CMND 490 Note Set 64 hex as the rightmost regis ter No in the leftmost byte of S 5 Response Frame tem Sting Setting ocan Modbus Slave address e g 02 hex Stored in D 2 of CMND 490 FUNCTION code Write data 10 hex Write data register No e g frequency 0002 hex Stored in D 3 of CMND 490 reference 0002 hex Write data registers e g 1 register 0001 hex Stored in D 4 of CMND 490 ICMND S D Q Command Details Operand Offset Value 0 2804 hex Conversion to Modbus RTU FINS command code 2804 hex 501000 0210 hex Modbus RTU slave address 02 hex FUNCTION code 10 hex DATA WRITE 0002 hex Write data register No 0002 hex frequency reference 0001 hex Number of write data registers 0001 hex 1 register 0200 hex Number of attached data bytes 02 hex 2 bytes Leftmost register No 00 hex 6400 hex Rightmost register No 64 hex Frequency reference value 10 0 Hz when unit is 0 1 Hz blank 00 hex First response storage word D200 0 00 OC hex Number of command data bytes 000C hex 12 bytes decimal 00000 oe 00 OA hex Number of response data bytes 000A hex 10 bytes decimal 2 0002 hex Send destination network ad
211. hex x unit number 3 8C hex of the Serial Communications Unit Unit number 3 that is mounted to the PLC on the Controller Link Network address 2 Node address 5 The fre quency reference value 10 0 Hz set as 100 decimal in units of 0 1 Hz is writ ten The Modbus RTU command is configured from the following elements Modbus RTU slave address 02 FUNCTION code 10 hex DATA WRITE Write start register No 0002 hex frequency reference Write data 0064 hex 100 decimal 91 Communications Frames 92 Section 3 7 instruction FINS message 2804 Modbus RTU command FINS message 2804 Modbus RTU command Serial Communications Unit Unit No 3 port 1 CPU Unit Network Controller Link Network address 2 Conversion Link Unit Node address 5 Example Write data for frequency reference value FUNCTION code 10 hex register No 0002 hex Port 1 unit address 80 hex 4 hex x unit number 3 8C hex List of Settings e FINS Network Settings Value Setting location Example 2 Send destination network Set 02 hex in the control data address C 2 bits 00 to 07 network Controller Link network address of CMND 490 address of PLC to which Note Set 0 hex in the control Serial Communications Unit data C 2 bits 08 to 11 serial is mounted port number of CMND 490 Send destination node 5 Set 05 hex in the control data address C 3 bits 08 to 15 send destina node address in Contr
212. ibes the command and response formats for FINS com mands For each format the data is arranged in order from left to right Command and Response Formats Using CMND 490 When CMND 490 is used to send a FINS command the command is stored in I O memory from the rightmost word to the leftmost word with a single word represented as two boxes four digits hexadecimal in the format diagram In the following example five words of data are written from D00010 Command Format a Command code Beginning write address Number of Write data Variable classification elements to write The command format data is stored in the order shown below when CMND 490 is used Command code Variable classification beginning write address Beginning write address Number of elements to write Write data Write data Command End code code The response format data is stored in the order shown below when CMND 490 is used Command code D 1 00 00 End code 170 FINS Commands Section 5 3 Using Host Link When a FINS command is sent using Host Link communications the Host Communications Link header response wait time destination node address and source node address are all placed before the command format and the frame check sequence FCS and terminator are placed after the command format before sending the command from the host computer Execution Conditions The Execution Conditions tables given for each command tell whether
213. ice Online edit released and then execute the ing is being executed from command another node or ACCESS ACCESS RIGHT ACQUIRE or RIGHT ACQUIRE or ACCESS RIGHT FORCE ACCESS RIGHT FORCE ACQUIRE can be executed to ACQUIRE has been obtain the access right but this may executed by another node adversely affect processing by the node that previously held the access right 01 Service Service was aborted with aborted ABORT command In addition to the above end codes there are also specific flags in the end code word bits 6 7 and 15 that may also be ON If bit 6 or 7 is ON an error has occurred in the destination CPU Unit If bit 15 is ON an error has occurred during a network relay operation The contents of the end code word are shown in the following diagram 161 Command Lists Section 5 1 1 Main code MRES Sub code SRES 1 Fatal CPU Unit error J L 1 Non fatal CPU Unit error 1 Network relay error See following section for details Handling Fatal and Non fatal CPU Errors If bit 6 or 7 is ON an error has occurred in the destination CPU Unit If this occurs refer to the operation manuals for the CPU Unit where the error occurred and remove the cause of the error Example of a CPU Unit Error For example if a battery error occurs in the destination CPU Unit bit 6 in the end code will be ON because a battery error is a non fatal CPU Unit error Basically
214. ils refer to 1 4 4 Write Protection from FINS Commands Sent to CPU Units via Networks in the CS Series PLC Operation Manual or the CJ Series PLC Operation Manual 5 1 3 End Codes The following table lists the main codes and the sub codes which combine to form the end code response code returned for a FINS command The prob able cause and corrections for each error code are also given Depending on the command the destination code will sometimes make a request of another node on a network The other node is referred to as the third node Note In addition to the end codes listed in the following table the specific flags in the end code word bits 6 7 and 15 may also be ON If bit 15 is ON an error has occurred during a network relay operation If bit 6 or 7 is ON an error has occurred in the destination CPU Unit If this occurs refer to the operation manuals for the CPU Unit where the error occurred and remove the cause of the error The contents of the end code word are shown in the following dia gram 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 1 Main code MRES Sub code SRES 1 Fatal CPU Unit error J i 1 Non fatal CPU Unit error 1 Network relay error See following section for details Check point Probable cause 00 Normal 00 Normal completion completion 01 Service Service was canceled Check the capacity of the destina canceled tion area in the third node Data lin
215. in struction always set the unit number for Host Link incremented by one 1 to 32 for the remote destination send destination node address word C 3 bits 08 to 15 of the CMND 490 instruction Do not set the unit num ber of the actual Host Link slave 0 to 31 Using the Host Link unit number without incrementing by one will access the PLC with the entered Host Link unit number less one For example specify remote PLC with Host Link unit number 2 by entering 3 for the remote destination node address If the 2 is entered the PLC with Host Link unit number 1 will be accessed To access a PLC on a Host Link FINS network using the Serial Gateway from CX Programmer however enter the actual Host Link unit number without incrementing by one Select Change PLC click the Display Seri al Gateway Guide Button and set unit number in the Host Link SYSWAY Settings field of the Serial Gateway Guide dialog box Sending Modbus ASCIl Commands e Set the FINS command code of 2805 hex in S indicating conversion to Modbus RTU e In S 1 onwards set the slave address 2 bytes ASCII FUNCTION code 2 bytes ASCII communications data 2 x n bytes ASCII from leftmost bytes to rightmost bytes using ASCII Sending CompoWay F Commands e Set the FINS command code of 2803 hex in S indicating conversion to CompoWay F e In S 1 onwards set the CompoWay F node number 2 bytes ASCII sub address 2 bytes ASCII SID 1 byte ASCII CompoWay F com ma
216. ination or electrical interference or conditions or uses not described in this manual e Nuclear energy control systems combustion systems railroad systems aviation systems medical equipment amusement machines vehicles safety equipment and installations subject to separate industry or government regulations e Systems machines and equipment that could present a risk to life or property Please know and observe all prohibitions of use applicable to the products NEVER USE THE PRODUCTS FOR AN APPLICATION INVOLVING SERIOUS RISK TO LIFE OR PROPERTY WITHOUT ENSURING THAT THE SYSTEM AS A WHOLE HAS BEEN DESIGNED TO ADDRESS THE RISKS AND THAT THE OMRON PRODUCTS ARE PROPERLY RATED AND INSTALLED FOR THE INTENDED USE WITHIN THE OVERALL EQUIPMENT OR SYSTEM PROGRAMMABLE PRODUCTS OMRON shall not be responsible for the user s programming of a programmable product or any consequence thereof xiii Disclaimers CHANGE IN SPECIFICATIONS Product specifications and accessories may be changed at any time based on improvements and other reasons It is our practice to change model numbers when published ratings or features are changed or when significant construction changes are made However some specifications of the products may be changed without any notice When in doubt special model numbers may be assigned to fix or establish key specifications for your application on your request Please consult with your OMRON representative a
217. incorrect An end code of 15 entry number data error will be returned if the program address is not BCD or if the timer counter type or number is out of range including hexadecimal data An end code of 16 command not supported will be returned if the specified instruction does not exist in the UM Area o oman 4 3 22 TIMER COUNTER SV CHANGE 3 W 130 From the specified program address onwards in cyclic task 0 TIMER COUNTER SV CHANGE 3 finds the specified timer counter instruction and changes the 4 digit constant SV BCD that is set or the word address where the SV is stored to a newly designated constant SV or storage word address C mode Command Details Section 4 3 Command Format x10 x10 W x10 x 104 x 10 x 10 x10 x 109 OP1 OP2 OP3 OP4 x 10 x 102 x10 x 109 Unit No BCD oa Program address Timer counter type Timer counter number OP1 OP2 OP3 OP4 x 10 x 102 x 10 x 10 Constant area classification New SV word address FCS Terminator Instruction name Timer counter type Timer counter Char Char Char Char number acter 1 acter 2 acter 3 acter 4 HIGH SPEED TIMER T M H W WAIT mew p o Mm w HIGH SPEED TIMER TMH TOTALIZING TIMER T T I M REVERSIBLE COUNTER C IN T__ R__ mmer m i mMm e cowna f N F e Note
218. ink commands Type Header code I O memory ClO AREA READ Reads the specified number of words beginning with reading the designated ClO word RL LR AREA READ Reads the specified number of words beginning with the designated LR word RH HR AREA READ Reads the specified number of words beginning with the designated HR word RC TIMER COUNTER PV READ Reads the specified number of words of the timer counter PV beginning with the designated word RG TIMER COUNTER STATUS READ Reads the specified number of words of the timer counter status beginning with the designated word DM AREA READ Reads the specified number of words beginning with the designated DM word RJ AR AREA READ Reads the specified number of words beginning with the designated AR word RE EM AREA READ Reads the specified number of words beginning with the designated EM word I O memory WR CIO AREA WRITE Writes the specified data in word units beginning writing with the designated CIO word WL LR AREA WRITE Writes the specified data in word units beginning with the designated LR word WH HR AREA WRITE Writes the specified data in word units beginning with the designated HR word WC TIMER COUNTER PV WRITE Writes the specified timer counter PV data in word units beginning with the designated word DM AREA WRITE Writes the specified data in word units beginning with the designated DM word AR AREA WRITE Writes the specified data in word units beginning with the designated AR word EM AR
219. ion Network Address The network address 00 to 7F Hex of the CPU Unit is set in hexadecimal DA1 Destination Node Address The node address 01 to 7E Hex of the CPU Unit is set in hexadecimal DA2 Destination Unit Address The unit address of the Host Link port is set SNA SA1 SA2 The addresses for the source node e g PLC FA computer are set SNA Source Network Address The network address 00 to 7F Hex of the source is set in hexadecimal FINS Commands with Host Link Protocol Section 3 5 SA1 Source Node Address The node address 01 to 7E Hex of the source is set in hexadecimal SA2 Source Unit Address The unit address of the source is set SID Source ID Automatically set by the CPU Unit using SEND 090 RECV 098 and CMND 490 3 5 7 Response Format Returned by the Host Computer Responses to FINS commands received by the host computer are returned in the format shown below Unit No Header ICF RSV GGT DNA DA1 code DA2 SNA Data AN SA1 SA2 SID FINS command code FINS response code E a NI NS FCS Terminator 1 076 characters Note ICF Information Control Field CO ASCII 43 30 will be returned RSV Reserved 00 ASCII 30 30 is returned GCT Gateway Count 07 ASCII 30 37 is returned DNA Destination Network Address DA1 Destination Node Address DA2 Destination Unit Address The same contents specified for SNA SA1 and SA2 in
220. ions RUN mode MONITOR mode PROGRAM mode Command Format Seabees gee wee eee ee Pena EE ajeede cao sae mies Command Program code No Response Format ate Command End code code Parameters Program number command Always FFFF hex End code response Refer to 5 1 3 End Codes for information on end codes Comments If the CPU Unit s operating mode has already been changed to the intended mode when this command is sent a normal completion will be returned If only the command code or only the command code and program number are to be sent the operating mode will be changed to the PROGRAM mode 5 3 15 CPU UNIT DATA READ 05 01 Reads the following data e CPU Unit model e CPU Bus Unit configuration e CPU Unit internal system version e Remote O data e Area data e CPU Unit information Execution Conditions Access right at UM read DIP switch UM Network write een ove noe write a RUN mode MONITOR mode PROGRAM mode Command Format 05 01 Command code 189 FINS Commands Section 5 3 Response Format The format is as shown below if 00 hex is specified as the data to be read i e from the CPU Unit model to the area data 05 01 20 bytes 20 bytes 40 bytes 12 oyes Command End code CPU Unit CPU Unit For system Area data code model internal system use version The format is as shown below if 01 hex is specified as the data t
221. ions When bits are designated each bit is considered a single element The data for the element is expressed in one byte ON 01 hex OFF 00 hex When data is written this byte is transmitted When data is read this byte is returned 00 Hex OFF 01 Hex ON 163 Designating Command Parameters Section 5 2 164 Bit Data with Forced Status When bits are designated each bit is considered as one element The data for each element is expressed in one byte 8 bits Bit 00 indicates the specified bit data and bit 01 indicates the forced status When reading this one byte is returned L Bit 00 0 OFF 1 ON Bit01 0 No forced status 1 Forced status Word Designations When words are designated each word is considered a single element The data for the element is expressed in two bytes Bits 0 to 15 correspond to bits O to 15 of each word When data Is written these two bytes are transmitted for each word When data is read these two bytes are returned Bits 0 to 7 Bits 8 to 15 Word Data With Forced Status Data Present Value 4 Bytes Word data PV bits 0 to 7 4th byte Word data PV bits 8 to 15 8rd byte Word data PV bits 0 to 7 forced status 2nd byte Word data PV bits 8 to 15 forced status 1st byte 0 Not forced 1 Forced Current EM Bank Number 2 Bytes Bit 15 0 EM not used or all banks con
222. iption Changes were made throughout the manual to include information for new products CJ1G CPU44 45 and CJ1W SCU41 In addition the following changes were made Page 15 added Page 18 Page 45 added Page 57 Page 60 Page 63 Page 85 Page 88 Page 118 Page 125 Page 131 Information on words per frame and the response format for MS commands Note added after first table Information on formats for commands to and responses from the host computer Information on end code 23 changed Description of UM Area Read protected changed Information added under Limitations Text under second format diagram changed Some error names in the response format diagram changed Information on volume labels and file names changed Information under Comments changed Command format diagram changed Pages 154 157 158 160 161 163 164 166 167 Description of directory length changed Pages 155 157 158 160 161 163 165 166 167 Description of absolute directory path changed Page 156 response Information on attribute and date and time added 12 bytes removed from format diagram Pages 158 160 Reference added under file name Page 160 Page 161 names Page 167 Second paragraph under Comments removed Sentence added to first paragraph Reference added under old and new file Changes made to information under directory name Changes were m
223. its with 1 N Host Link Format Selected Using the CPU Unit s Built in Peripheral Port or RS 232C Port Number of Data Words per Frame Note When I O memory data is read with the following commands the number of data words in each response frame is different for a C series Host Link Unit compared to the built in peripheral and RS 232C ports on CS CJ series CPU Units serial port C on NSJ Controllers built in serial ports of N type CP1E CPU Units and serial ports 1 and 2 on the Option Board for CP series CPU Units With a C series Host Link Unit the first frame can contain up to 29 words of data text and the following frames can contain up to 30 words of data text With the built in peripheral and RS 232C ports on CS CJ series CPU Units serial port C on NSJ Controllers built in serial ports of N type CP1E CPU Units and serial ports 1 and 2 on the Option Board for CP series CPU Units the first frame can contain up to 30 words of data text and the following frames can contain up to 31 words of data text Header code Name CIO AREA READ LR AREA READ HR AREA READ TIMER COUNTER PV READ Note The number of data words per response frame is different for the RG command than for the other C mode commands For details see the table Words per Frame for C mode RG Command below RD DMAREAREAD RI AR AREA READ Because the Units do not have the same number of words per response frame the data may not be read properly if a host co
224. ity response The capacity bytes of the file that was read is returned 214 FINS Commands Section 5 3 File position response The position of the first data read is returned Data length response The number of bytes of data read is returned If the last data in the file is included the leftmost bit in this parameter will be ON Data response The specified data is returned in sequence starting from the specified byte Directory length Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 7 3 End Codes for information on end codes Comments By specifying 0000 hex as the file position and data length in the command is possible to see if the file exists 5 3 34 SINGLE FILE WRITE 22 03 Writes a new file to the file memory or appends or overwrites an existing file stored in the file memory Designation can be made to protect existing files if an attempt is made to create a new file of the same name as an existing file
225. k generally indicates the 1 N Host Link 2 Unlike FINS commands C mode commands can only be addressed to a CPU Unit and they cannot be used for message service outside of the lo cal network They cannot be used for functions such as file operations C mode Host Link commands can be sent from a host computer connected to a CS CJ series Host Link Unit Up to 32 PLCs Host Link Units can be con nected to a single host computer For identification each Host Link Unit is assigned a unit number from 0 to 31 The length of a single unit of a command or response exchange is called a frame A single frame contains a maximum of 131 characters of data Char acters are sent and received as ASCII For a CS CJ series PLC a Host Link Unit can be the CPU Unit a Serial Communications Unit or a Serial Communications Board A maximum of 30 words of data can be transferred for the first command frame and a maximum of 31 words of data can be transferred for other com mand frames when reading or writing word data in I O memory When read ing writing more than 30 words of data the data transfer will be processed in multiple transmissions with 30 words in the first and up to 31 words in each of Command Response Formats Section 2 2 the following transmissions until the number of words set in the command has been processed The frame formats for Host Link commands sent from a host computer and responses returned by the PLC receiving t
226. k No x 10 x 10 x 10 x 10 x 16 x 16 x 16 x 16 x E a eee Unit No BCD Header Bank No Beginning word Write data 1 word FCS Terminator de See note 0000 to 9999 a l Write data for number of words to write Note Input 00 to OC to specify bank number 0 to C Input two spaces to specify the current bank Response Format x 10 x 10 W E st ail x a a Unit No BCD Header End code FCS Terminator code Limitations The range that can be designated is E0000 to E9999 A single bank of EM consists of E00000 to E32767 but the range that can be written by this com mand is E00000 to E09999 The maximum EM bank number that can be specified is 12 OC Hex Execution Conditions Commands Responses PiGmos umaa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Pp OK x x No No x x PKK End Codes An end code of 14 format error will be returned if the length of the command is incorrect or the first word of write data is not in the first frame An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundary the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of 15 will also be returned if there are no banks and file memory access is not possible An end code of A5 will be returned instead of 15 fo
227. k status Check the status of the data link 01 Local node 01 Local node Network status Local node is not participat Connect the node to the network error not in network of local node ing in the network 02 Token Maximum node an does not arrive Prk inlet alll the local node to within the timeout address a ee Prk inlet alll address 03 Retries Send was not possible during Execute a communications test failed the specified number of between the nodes and re examine retries the system environment if it fails 04 Too many Number of Cannot send because maxi Check event execution on the net send frames enabled send mum number of event frames work and reduce the number of frames exceeded events per cycle Increase the maximum number of event frames 05 Node Node address Node address setting error Check the settings of the rotary address range occurred switches to be sure that the address error is within range and that each address is set only once in the same network 06 Node Node addresses The same node address has Change the address of one of the address been set twice in the same nodes with the same address duplication network 155 Command Lists Section 5 1 Check point Probable cause 01 Destination INS indicator on The destination node is notin Add the destination node to the net the network 02 Destination node error node not in net Unit work 02 Unit miss Instructi
228. kJ seas N Unit No BCD Header Beginning word Write data 1 word FCS Terminator code 0448 to 0959 Write data for number of words to write Response Format x10 x10 9 W J_s x 16 x 16 x a Unit No BCD gas End code FCS Terminator Execution Conditions 7 Commands Responses PLG Mode Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Pp OK x x N No x x KK End Codes An end code of 14 format error will be returned if the length of the command is incorrect or the first word of write data is not in the first frame An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundary the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of A5 will be returned instead of 15 for non hexadecimal write data in multiple command frames o nomani SOS aa Aborted due to format error in transmit data A Abort dueto erty number data eror in tarsi oala Aborted due to frame length error in transmit data 119 C mode Command Details Section 4 3 4 3 16 EM AREA WRITE WE Writes data to the specified EM Area bank starting from the specified word E00000 to E09999 Writing is done in word units Command Format rf x10 x10 W E Ban
229. l Communications Board or Units Host Link function can be made completely compatible with the existing PLC s Host Link function by setting the appropriate Host Link mode 1 N or 1 1 Host Link and the Host Link model compatibility mode Host Link Model Compatibility Selection Function Serial Communications Boards and Units with version Ver 1 2 and later are equipped with a Host Link model compatibility selection function This function switches the Board or Units Host Link specifications to match the specifica tions of an existing Host Link program that is being reused The following specifications can be switched by the Host Link model compatibility function e Words per Response Frame Sets the number of data words per response frame when receiving the fol lowing I O memory read commands RR RL RH RC RD Ru or RG Precautions when Reusing Programs from Earlier Models Section 2 4 e Sets the response frame format for the STATUS READ command MS which varies when an FAL or FALS instruction has not been executed Host Link Model Compatibility Modes Host link Host link model RR RL RH RC RD RG command MS model Model used as basis for host and RJ commands command compatibility computer s program see note mode Data words per response frame Response 15 frame 2 4 frame 1 frame 2 frame 918 tomat A mode C Series 30 words 31 words 121 125 Variable CS CJ and SRM1 built in ports words words length C CPM
230. ller or CP series CPU Unit the GCT will be decremented from 02 hex by default and from 07 hex if the user selects CX Net 3 The GCT Gateway Count Number of Bridges Passed Through in the FINS header in FINS command response frames should not be checked in the user applications e g in the host computer The GCT is for system use only and verification may fail if attempted from a user application This is particularly important for CS CJ series CPU Unit with unit version 2 0 or later CP series CPU Unit or NSJ Controller 3 4 Settings for Sending FINS Commands Command format Settings for sending FINS commands Network address m Address Node address Unit address Other Response required not required m Number of retries See note 1 m Communications port No See note 1 m Response monitor time See note 1 Gateway count See note 2 Note 1 Set these as operands when executing CMND 490 2 Do not set the gateway count when using CMND 490 34 Settings for Sending FINS Commands Section 3 4 3 4 1 FINS Command and Response Formats Command Format As shown below the command format basically consists of the command code four digits hexadecimal and parameters text Command code See note Text Various kinds of data 4 digits hexadecimal The length depends on the command code 2 bytes Note The command code is a 2 byte code that expre
231. lly running it on the Unit Not checking the program may result in an unexpected opera tion After replacing the CPU Unit a Special I O Unit or a CPU Bus Unit make sure that the required data for the DM Area Holding Area and other memory areas has been transferred to the new Unit before restarting operation Confirm that no adverse effect will occur in the system before attempting any of the following Not doing so may result in an unexpected operation e Changing the operating mode of the PLC including the setting of the startup operating mode e Force setting force resetting any bit in memory e Changing the present value of any word or any set value in memory Do not pull on the cables or bend the cables beyond their natural limit Doing either of these may break the cables Do not place objects on top of the cables or other wiring lines Doing so may break the cables Do not use commercially available RS 232C personal computer cables Always use the special cables listed in this manual or make cables according to manual specifications Using commercially available cables may damage the external devices or CPU Unit Never connect pin 6 5 V power supply on the RS 232C port on the CPU Unit to any device other than an NT AL001 or CJ1W CIF11 Adapter The external device or the CPU Unit may be damaged XX Application Precautions 5 e Before touching a Unit be sure to first touch a grounded metallic object in order to dischar
232. located or local network node address or local network address FINS header FINS command Remote node address DA1 Remote network address DNA unit Serial port allocated address or local network node address or local network address Slave address ASCII code ASCII code 2 characters 4 bytes 88 Remote address Slave address ASCII code 2 characters 4 bytes Modbus ASCII frame FUNCTION code ASCII code 2 characters 4 bytes sees SRC Communications data ASCII code n characters End silent aha of 3 5 characters See note Communications data n bytes FINS command command FINS end code end code fear SRES Modbus RTU command section only FUNCTION code 1 byte Communica tions data n bytes Slave address 1 byte Modbus ASCIl command section only FUNCTION code ASCII code 2 characters 4 bytes Communications data ASCII code n characters CR LF OD hex OA hex Communications Frames Section 3 7 Response Frame Frame before Conversion Modbus ASCIl frame Communications data CR LE ASCII code ASCII code n characters OD hex OA hex characters or error code m i A after Conversion 0 T5 FINSheader header FINS command command FINS end code Remote Remote Remote Etc MRC SRC MRES SRES Modbus ASCII network node unit command section only addres
233. ltiple frames when there are more than 131 characters PLC Modes RUN Tells if the CPU Unit will accept the command when the CPU Unit is in RUN mode PLC Modes MONITOR Tells if the CPU Unit will accept the command when the CPU Unit is in MONI TOR mode PLC Modes PROGRAM Tells if the CPU Unit will accept the command when the CPU Unit is in PRO GRAM mode UM Area Write protected Tells if the CPU Unit will accept the command when the UM Area is write pro tected using the DIP switch on the CPU Unit UM Area Read protected Tells if the CPU Unit will accept the command when the UM Area is read pro tected using a Programming Device Note 1 WR Area words cannot be read or written using C mode commands 2 Timers 2048 to 4095 and counters 2048 to 4095 cannot be read or written and their SV cannot be read or written using C mode commands 3 D10000 to D32767 and E10000 to E32767 cannot be read or written using C mode commands 4 SV can be read and written only in cyclic task 0 Also timer SV can be read and written only when the timer number is not indirectly addressed 4 3 2 ClO AREA READ RR Reads the contents of the specified number of ClO words starting from the specified word Command Format x10 10 Ro x10 x10 x 10 10 10 x10 x 10 10 x L y Unit No BCD Header Beginning word No of words FCS Terminator code 0000 to 6143
234. mand Frame Configuration elel TP TT ET a e ka BA ei E A ne ale a Command Tet Text FINS header automatically attached for CMND 490 Set in word specified for CMND 490 operand S onwards With Host Link communications the header FCS and terminator are attached before and after the frame 3 3 2 FINS Response Frame Configuration delel PPP Pf o ce aby odr an ay He sa oh ao a Caner End Text code code FINS header deleted automatically for CMND 490 Set in word specified for CMND 490 operand D onwards With Host Link communications the header FCS and terminator are added before and after the frame 32 FINS Command and Response Frames Section 3 3 3 3 3 Individual Items in Command Response Frames Note Note ICF The ICF Information Control Field is configured as shown in the following diagram Bit ry i Always 0 See note Response 0 Required 1 Not required Data classification 0 Command 1 Response Sp ee et Bridges 0 Not used 1 Used Always 1 0 Hi ff 6 5 4 3 2 1 1 ojojojojo i Set bits 01 to 05 to 0 when sending a FINS command Do not access these bits when receiving a FINS response RSV RSV Reserved is always 00 hex These bits are used by the system Do not access them in the response GCT When communicating across up to 8 network layers with CPU Unit with unit version 2 0 or later set the GCT Gateway Count Number of Bridges Passed Thro
235. mber of bytes to be written File data Command Specifies the data in sequence from the beginning position in the amount specified in data length Directory length command Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length Absolute directory path command Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 1 3 End Codes for information on end codes Writing a new file or modifying an existing file must be done within the capac ity of the file memory or the SINGLE FILE WRITE command cannot be exe cuted When SINGLE FILE WRITE is executed the clock data of the CPU Unit will be recorded as the date of the file 5 3 35 FILE MEMORY FORMAT 22 04 216 Formats file memory Always execute FILE MEMORY FORMAT command code 2204 before using a memory card or EM area as file memory FINS Commands Execution Conditions Command Format Response Format Parameters Comments Note Section 5 3 Access right at UM read DIP switch UM write Network write other device protection protection protectio
236. meter area to read The parameter area code is designated in two bytes The leftmost byte is always 80 hex and the rightmost byte speci fies the parameter area Beginning word command and response Specify the first word to read The beginning word address specifies the rela tive word address with the beginning of the designated area as 0000 hex 180 FINS Commands Section 5 3 Parameter Areas The areas that can be read are shown below along with their parameter area codes Parameter Address range Parameter Address range area code Hex area code Hex E S PLC Setup Area 8010 0000 to 01FF 512 words VO Table Registration Area I O Table Registration Area 8012 0000 to 04FF 1 280 words 0000 to 1F3F 3 ai 8000 words Routing Table Area 8013 0000 to 01FF 512 words T A CPU Bus Unit Setup Area 8002 0000 to 143F 5184 words Number of words command and response Bits 0 to 14 are used to specify the number of words to be read Each word consists of 16 bits Bit 15 must be OFF 0 in the command format When the content in the response format contains the last word of data in the specified parameter area bit 15 will be ON 1 For example it would indicate that the 512th word of data is contained in the PLC Setup area Data response The data in the specified parameter area will be returned in sequence starting from the beginning word The leftmost bits bits 8 to 15 of each word are read first followed by the ri
237. mmand End code code Year month day hour minute second day of week response The year month day of month hour minute and second are expressed in BCD Year The rightmost two digits of the year 1998 1999 and 2000 are expressed as 98 99 and 00 respectively 2096 and 2097 will be expressed as 96 and 97 Hour 00 to 23 BCD 197 FINS Commands Comments Section 5 3 Day of week As follows vam 00 07 02 03 oa 05 06 End code response Refer to 5 1 3 End Codes for information on end codes If the second and the day of week are not specified 00 BCD will be set as the second and the previous value will be kept for the day If the second is specified but the day of week is omitted the previous setting will not be changed The PLC does not check the day of week from the day of month This means that no error will occur even if the day of month and the day of week do not agree The PLC automatically checks the range of the specified data If any portion of the data is incorrect the clock will not be set 5 3 21 MESSAGE READ 09 20 Execution Conditions Command Format Response Format Parameters 198 Reads messages generated by MSG 195 Access right at UM read DIP switch UM write Network write other device protection protection protection RUN mode MONITOR mode PROGRAM mode 09 20 Command Message No code param
238. mments and program comments Function block sources Built in flash memory Function Block Source Memory Area Data memory RAM DM Area DO to D32767 Data memory initial values Built in flash memory Data memory initial value area Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection OK See note RUN mode MONITOR mode PROGRAM mode Note Data cannot be transferred from the CPU Unit to the Memory Cassette when the user program is included and DIP switch UM protection is set Command Format MEMORY Disk number Parameter Data type designation CASSETTE TRANSFER Response Format Other Memory Cassette Operations Parameter 8000 Hex 22 20 MEMORY End code CASSETTE TRANSFER Reading the Data Type in the Memory Cassette Parameter 8000 Hex 22 20 MEMORY End code Stored data type CASSETTE TRANSFER Parameters Disk number command Specify the disk for transfer or verification Only the Memory Cassette can be specified 8003 hex Memory Cassette 227 FINS Commands Note Section 5 3 Parameter command Specify the transfer or verification method 0000 hex Transfer CPU Unit to Memory Cassette 0001 hex Transfer Memory Cassette to CPU Unit 0002 fei Verify between CPU Unit and Memory Cassette 0003 hex Initialize Memory Cassette 8000 hex Read data type in Memory
239. mputer program originally used with a C series Host Link Unit is reused with a CS series CPU Unit CJ series CPU Unit CP series CPU Unit or NSJ Controller In this case be sure to edit the host computer program so that it is compatible with the frame for mat oO TIMER COUNTER STATUS READ RL RH RC RG RJ Serial Communications Boards and Units with version numbers 1 2 and later are equipped with a Host Link model compatibility selection function that changes the Host Link function s specifications to match the frame format of other Units in the Host Link It is not necessary to edit an existing program if the Host Link model compatibility selection function is set to match the Host Link format used in the program For details see Using a Serial Communica tions Board or Unit with Version Number 1 2 or Later below 15 Precautions when Reusing Programs from Earlier Models oo ee CS CJ Series CVM1 and CV Series Pf ff C series Host Link Units Other Boards and Units 16 Section 2 4 Words per Frame for C mode Commands Except RG Command C200H LK101 LK201 LK202 Host Link Units C500 LK103 LK203 Host Link Units 3G2A5 LK101 LK201 Host Link Units 3G2A6 LK101 LK201 LK202 Host Link Units SRM1 built in ports CPM1 built in ports CPM1A built in ports CQM1 CPUL built in ports C200HS CPUL IL built in ports C200HX HG HE CPUL ILI built in ports C200HW COML IL Communications Board ports
240. munications Board Response setting 0 Required 1 Not required Communications port Pere OOOO S S to 7 0 to 7 number Number of retries 0 to e e 0 to 15 Response monitor time 0000 Default 0001 to FFFF 0 1 to 6 553 5 s unit 0 1 s 51 FINS Commands with Host Link Protocol Section 3 5 RECV 098 52 Note To execute SEND 090 normally programming needs to be written to process the data received by the host computer and return the proper response By using RECV 098 data from the host computer can be written to a mem ory area in the CPU Unit Command Format Received by the Host Computer The FINS command transmitted to the host computer when RECV 098 is executed is MEMORY AREA READ command code 0101 The command format received by the host computer is shown in the following diagram Refer to MEMORY AREA READ 0107 in Section 5 FINS Commands for details Unit No Header ICF RSV GCT DNA DA1 code Response wait time code Beginning Number of read FCS Terminator read address elements Control Words Control data must be set before RECV 098 is executed The control data is written in the following format starting from the first control word Bits 00 to 07 Bits 08 to 15 Number of read words Destination network address Bits 08 to 10 Serial port number Destination unit address Destination node address Bits 00 to 03 No of retries Bits 08 to 10 Comm port number Response monitor time unit 0 1
241. n Po NO OK KN RUN mode MONITOR mode PROGRAM mode 22 04 Command Disk code No 22 04 Command End code code Disk number command The classification of the file memory to be formatted is specified as follows 8000 hex Memory card 8001 hex EM file memory End code response Refer to 5 7 3 End Codes for information on end codes When FILE MEMORY FORMAT command code 2204 is executed all data registered to the file memory will be cleared Before executing this command check to be sure that it is okay to clear the data Refer to file memory applica tion procedures in the CPU Unit s operation manual for details on using file memory FILE MEMORY FORMAT is also used to return EM memory that has been converted to file memory back to its original form Even if only the size of the file memory is changed the entire file memory will be formatted If the current EM bank is specified for file conversion in the PLC Setup when FILE MEMORY FORMAT is executed for the EM Area an Area Missing error end code 1101 will be returned and a PLC Setup setting error will occur in the CPU Unit These errors however will not occur if the current bank is EMO 5 3 36 FILE DELETE 22 05 Execution Conditions Deletes files registered to file memory Access right at UM read DIP switch UM write Network write other device protection protection protection No No RUN mode MONITOR mode PROGRAM
242. n four digits decimal BCD for beginning the search for the specified timer counter Timer Counter Type Command Designate in ASCII characters the timer counter instruction type for reading the constant SV or the word address in which it is stored Timer Counter Number Command Designate in four digits BCD the timer counter instruction number for read ing the constant SV or the word address in which it is stored Data register designation is not possible Constant Area Classification Response The constant or I O memory area classification is returned in ASCII to this parameter SV Word Address Response The constant SV or the word address in which it is stored is returned to this parameter Mm e ow earecy ows m Limitations Timers T2048 to T4095 and counters C2048 to C4095 cannot be read The SV of the first timer counter found after the designated program address will be read If the SV is outside of range for the timer counter type or number an end code of 16 command not supported will be returned 123 C mode Command Details Execution Conditions Commands Responses PiGmos Umaea Single Multiple Single Multiple RUN MON PROG Write protected Read protected Section 4 3 If the SV is a DM or EM indirect address only indirect BCD designations will be read and an end code of 16 command not supported will be returned if the indirect designation is not BCD SV can be re
243. n if more than 498 words are specified To write larger parameter areas use multiple commands and specify the begin ning word for each Except for the routing table area each area must be read or written in its entirety 5 3 9 PARAMETER AREA CLEAR 02 03 Note Execution Conditions Command Format Response Format Parameters Writes all zeros to the specified number of consecutive parameter area words to clear the previous data The I O table can be cleared only when the CPU Unit is in PROGRAM mode Some PLC Setup parameters cannot be written in RUN or MONITOR mode Access right at UM read DIP switch UM Network write other device protection write protection protection Pp N KE NN RUN mode MONITOR mode PROGRAM mode 02 o c 00 00 00 Command Parameter Beginning No of Data code area code word words 02 03 Command End code code Parameter area code command Specify the parameter area to clear Beginning word command Always 0000 Number of words command Specify the number of words to clear One word 16 bits If the number of write words is set to 0000 no words will be written and a normal end code will be returned 183 FINS Commands Section 5 3 Parameter Areas The areas that can be written to are shown below along with their parameter area codes Parameter Address range Parameter Address range area code Hex area code Hex
244. nate in four digits BCD the timer counter number for reading the con stant SV Limitations Timers T2048 to T4095 and counters C2048 to C4095 cannot be read The second word of the instruction must be a constant This command cannot be executed while UM read protection is in effect lf there are multiple relevant instructions in the UM Area a search will be con ducted from program address 0 and the first instruction found will be read SV can be read only from cyclic task 0 Execution Conditions Commands Responses PLG Mode Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected Cox No OK No OK OK OK OK No 121 C mode Command Details Section 4 3 End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the timer counter type or timer counter number is out of range including hexadecimal data An end code of 16 command not supported will be returned if the specified instruction does not exist in the UM Area 00 nomani 4 3 18 TIMER COUNTER SV READ 2 R From the specified program address onwards in cyclic task 0 TIMER COUNTER SV READ 2 finds the specified timer counter instruction and reads the 4 digit constant SV that is set or the word address where the SV is stored Command Format
245. nction Communications code address code data ASCIl ASCII ASCII Command Slave Address Specify the Modbus ASCIl device address Set the address in ASCII between 01 and F7 hex 3031 to 4637 ASCII which is 1 to 247 in decimal Function Code Specify the function code of the Modbus ASCIl command Set the address in ASCII between 01 and FF hex 3031 to 4646 ASCII which is 1 to 255 in dec imal Communications Data Specify the required parameters in ASCII associated with the function code The amount of communications data varies In some cases there is no com munications data Response The response is the same as the command except that it contains an end code 235 FINS Commands Section 5 3 Precautions e FINS Header Destination Address Contents The following settings are required e Destination Network Address DNA e When a routing table is created to treat the serial communications path as a network this is the network address associated with the Serial Communications Unit or Board s serial port by the routing table e When a routing table is not created to treat the serial communications path as a network this is the actual network address used to specify the destination PLC e Destination Node Address DA1 e When a routing table is created to treat the serial communications path as a network set 00 hex for communications within the local PLC or the Host Link unit number 1 for serial serial
246. nd MRC 2 bytes ASCII CompoWay F command SRC 2 bytes 96 Communications Frames Note Section 3 7 ASCII text 2 x n bytes ASCII from leftmost bytes to rightmost bytes using ASCII Set the contents of S 3 when using CompoWay F commands as follows Set the SID 0 as ASCII 30 hex 1 byte in the leftmost byte and the leftmost digit of the CompoWay F command code MRC as ASCII 1 byte in the right most byte Next set the bits of S 4 as follows Set the rightmost digits of the CompoWay F command code MRC as ASCII in the leftmost byte and the leftmost digit of the CompoWay F command code SRC as ASCII 1 byte in the rightmost byte Be sure to set one byte each for the subsequent data without any blank bytes 97 Communications Frames 98 Section 3 7 This section provides detailed descriptions of the C mode commands 4 1 4 3 C mode Command List ARO End CodeSiw oc icycis on ike edie BA C mode Command Details 4 3 4 3 2 4 3 3 4 3 4 4 3 5 4 3 6 4 3 7 4 3 8 4 3 9 4 3 10 4 3 1 4 3 12 4 3 13 4 3 14 4 3 15 4 3 16 4 3 17 4 3 18 4 3 19 4 3 20 4 3 21 4 3 22 4 3 23 4 3 24 4 3 25 4 3 26 4 3 27 4 3 28 4 3 29 4 3 30 4 3 31 4 3 32 4 3 33 4 3 34 4 3 35 4 3 36 4 3 37 4 3 38 4 3 39 About this Section CIO AREA READ RR LR AREA READ RL HR AREA READ RH TIMER COUNTER PV READ RC TIMER COUNTER STATUS
247. nd code will be returned When ACCESS RIGHT FORCED ACQUIRE command code 0C02 is exe cuted while any other device has the access right subsequent commands cannot be executed from the other device This command should generally not be used during normal processing The following table shows which FINS commands can be executed even when another device holds the access right Command Command name Command execution code while another device has access right 0103 Yes a a ae ie C M n C NM E ee 0620 CYCLE TIME READ 0701 CLOCK READ oraz orockware f no 0920 Imessacecen O o o ocot ACCESSRIGHTACQUIRE mo e101 eRoRceRn O o Y 2103 eRRoRLoccen o Y 2141 FINSWRITEACCESSLOGCLEAR no 2208 SNGLEFLEWRTE n 2204 FLEMEMoRY FORM o Y 2205 FeDe O O oo o ooo 2207 meco w 2200 FLENaMECHanaE Ooo o ooo O FINS Commands Section 5 3 Command Command name Command execution code while another device has access right 220A MEMORY AREA FILE TRANSFER I O memory to file transfers only 7208 2200 2218 2220 2001 2302 FORCED SET RESET CANCEL If this command is executed when another device holds the access right any processing being executed by that other device will be aborted If possible wait until all processing has been completed and then execute ACCESS RIGHT ACQUIRE command code 0C01 Refer to 5 3 24 ACCESS RIGHT ACQUIRE 0C 01 When
248. nds 171 F FAL FALS messages 200 fatal error data 194 FCS calculations 13 237 file memory 5 151 154 files changing file names 219 comparing 220 222 224 copying 218 deleting 217 file name configuration 168 reading 211 214 transferring 220 222 224 writing 215 FINS commands 2 4 5 150 152 170 226 addresses 36 command format 35 170 command frame 32 command settings 41 detailed descriptions 149 execution conditions 171 explanation 28 list of 4 150 overview 27 65 response format 35 170 response frame 32 restrictions 153 154 settings for sending 34 timing 59 to CS CJ Series CPU Units 29 types of 29 with Host Link protocol 43 flags for network communications 58 force conditions for C mode commands 102 FORCED RESET KR 138 FORCED SET KS 137 forced set reset 3 101 FORCED SET RESET CANCEL KC 140 H Host Link communications 31 171 command frame 32 response frame 32 Host Link FCS 44 Host Link header 44 Host Link terminator 44 Host Link Units for CS CJ series PLCs 8 HR AREA READ RH 108 HR AREA WRITE WH 116 238 Index I L I O memory accessing 4 150 153 addresses 163 164 reading 2 4 100 101 registering 4 101 table of address designations 165 171 writing 3 100 I O table creating 4 101 I O TABLE GENERATE MD 144 INITIALIZE 148 installation precautions Xvill LR AREA READ RL 107 LR ARE
249. net Unit with other model number 1 to 126 Node address 1 to 62 for Controller Link CPU Unit Serial Communications Unit unit address 0 to 15 Inner Board Serial Communications Board Response required not O e required required 1 Response not required Communications port 0 to 7 0 to 7 number Number of retries 0 to F 0 to 15 Response monitor time 0000 Default 0001 to FFFF 0 1 to 6 553 5 s unit 0 1 s Note To execute RECV 098 normally programming needs to be written to process the command received by the host computer and return the proper data CMND 490 By using CMND 490 controls can be implemented by sending FINS com mands to the host computer Command Format Received by the Host Computer CMND 490 can be used to send any FINS command to the host computer The command format received by the host computer is shown in the following diagram 53 FINS Commands with Host Link Protocol Section 3 5 Unit No No Header code renos wait time N MM DA2 SNA SA1 SA2 SID Command code Data 1 080 characters NG OE Ne max FCS Terminator Control Words Control data must be set before CMND 490 is executed The control data is written in the following format starting from the first control word Destination unit address Destination node address Bits 00 to 03 No of retries Bits 08 to 10 Comm port number Bits 15 Response setting C 5 Response monitor time
250. network the routing table associates this network address with the Serial Communications Unit or Board s serial port e When a routing table is not created to treat the serial communications path as a network this is the unit address of the Serial Communica tions Unit or Board s serial port Destination Node Address DA1 e When a routing table is created to treat the serial communications path as a network the node address is the Host Link unit number 1 val ues 1 to 32 e When a routing table is not created to treat the serial communications path as a network the node address is still the Host Link unit number 1 values 1 to 32 Destination Unit Address DA2 Specifies any unit address other than the serial port The destination of a FINS message must be an address other than the Serial Communications Unit or Board s serial port Command Lists Section 5 1 5 1 2 FINS Command Restrictions Type ead PLC status fae RUN MONI PRO Write mode TOR GRAM i pro mode mode i tected i from network Omenon o 01__MEMORY AREA RED OK K OK OK a JOK OK 4 MULTIPLE MEMORY OK AREA READ 5 MEMORY AREA Disabled TRANSFER Parameter 02 1 PARAMETER AREA area access READ 2 PARAMETER AREA Disabled OK Disabled Disabled WRITE 3 PARAMETER AREA OK OK Disabled OK Disabled Disabled CLEAR PROGRAM AREA Disabled OK READ 7 PROGRAM AREA Disabled Disabled OK Disabled OK Disabled Disabled WRITE PROGRAM AREA Disable
251. nformation on error codes Refer to the relevant operation manual or installation guide for more details Each data record includes the minute second day of month hour 0 to 23 year the rightmost two digits and month in BCD specifying the time that the error occurred End code response Refer to 5 7 3 End Codes for information on end codes Comments The response will contain only the command code and end code if the begin ning record number is higher than the number of records contained in the PLC When the PLC does not have the specified number of records all the records that have been stored in the PLC will be read and an address range overflow error will result 208 FINS Commands Section 5 3 If the data is too large and exceeds the permissible length of the response for mat the part in excess will not be read and a normal response will be returned 5 3 29 ERROR LOG CLEAR 21 03 Execution Conditions Command Format Response Format Comments Clears all error log pointers to 0 Access right at UM read DIP switch UM write Network write other device protection protection protection Oo NOOK KN RUN mode MONITOR mode PROGRAM mode Command format 21 03 Command End code format End code response Refer to 5 1 3 End Codes for information on end codes This command clears the number of error log records that are stored It does not clear data from the err
252. ng table Refer to 5 2 2 I O Memory Address Designations for the specific addresses that can be used Data type CS CJ mode CV mode Bytes per memory area memory area element on a code o Work Area Holding Bit Area Completion Flag ae End code response Refer to 5 1 3 End Codes for information on end codes Comments To force set reset multiple bits flags specify the set reset designation the I O memory area code and the bit flag parameters for the number of bits flags set in the number of bits flags parameter Note If forced set reset OFF release 8000 or forced set reset ON release 8001 is exceeded for a bit flag that does not have forced status only the bit flag s ON OFF status will be affected 229 FINS Commands Section 5 3 5 3 45 FORCED SET RESET CANCEL 23 02 Cancels all bits flags that have been forced ON or forced OFF Access right at UM read DIP switch UM write Network write other device protection protection protection ox o o o o o Execution Conditions RUN mode MONITOR mode PROGRAM mode O mw O o o oo Command Format 23 02 Command code Response Format 23 02 C O a 2 Command End code code End code response Refer to 5 1 3 End Codes for information on end codes Comments The bits flags in the following memory areas can be forced set or forced reset and canceled Memory ars
253. nit No 20 Hex elnner Board E1 Hex Computer 01 Hex Unit connected to network FE Hex Devices on the Same Network Example Address Source address See note 1 Destination address See note 2 FINS command Example value FINS command Example value symbol symbol Network address ISNA 00 Hex IDNA 00 00 Hex Node address S other Unit address Note 1 The transmission source address will be automatically incorporated into the frame if the FINS command is sent with CMND 490 If sending the 36 Settings for Sending FINS Commands Section 3 4 FINS command by Host Link communications then put the source ad dress in the message 2 Set the transmission destination address in the control code C operand if sending the FINS command with CMND 490 If sending the FINS com mand by Host Link communications then put the destination address in the message Devices on Different Networks Example For CPU Unit 00 Hex Address level Source address See note 1 Destination address See note 2 FINS command Example value FINS command Example value symbol symbol Network address Node address Unit address Note 1 The transmission source address will be automatically incorporated into the frame if the FINS command is sent with CMND 490 If sending the FINS command by Host Link communications then put the source ad dress in the message 2 Set the transmission destination address in the control code C op
254. ns path as a net work Node address for specifying actual remote PLC For serial to serial to serial conversion increment the Host Link unit number by 1 e Remote destination unit address DA2 Unit address of serial port 2 The contents of the CompoWay F command enclosed in the FINS mes sage that is sent is as follows Node number subaddress SID command text ASCII must be used STX ETX BCC are not required when sending FINS They are added automatically for serial communications 3 6 4 Converting FINS to Modbus RTU Modbus RTU Slave compatible devices including OMRON Inverters con nected serially to a PLC via Modbus RTU can be accessed from the PLC or PT using Modbus RTU commands enclosed in FINS messages e Sent FINS message FINS header FINS command code 2804 hex Modbus RTU command e Message after conversion Modbus RTU command CPU Unit Modbus RTU command ann A 2804 Modbus RTU command munean Modbus RTU command PT Program Modbus RTU command encapsulated Unit Board using FINS command 2804 hex Via network or CPU bus Modbus RTU RS 232C or RS 422A 485 Inverter etc Modbus RTU Slave compatible OMRON Devices Inverters 3G3JV 3G3MV 3G3RV Temperature Controllers E5CN New version 70 Serial Gateway Overview Section 3 6 System Configuration Patterns Sending FINS Messages Using CMND 490 in CPU Unit s Ladder Program The Board Unit converts the FINS messages to Modbu
255. nsmitted from the host computer Command Format Specify any characters other than the carriage return o x 10 x10 T S 122 characters ee a fee Unit No BCD Header Characters FCS Terminator code Response Format The same characters specified in the command will be returned unaltered if the test is successful Oo x10 x100 T S 122 characters max x oo OOF Z OA Unit No BCD B Characters FCS Terminator Limitations Between 0 and 122 characters can be sent If the command is correct no end code will be returned Execution Conditions 7 Commands Responses PiCmoas Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected x o x No x x x o _ End Codes An end code of 14 format error will be returned if a terminator is not received in the first frame End code Hew Frame length error Not executable due to CPU Unit CPU error 4 3 32 PROGRAM READ RP Reads the contents of the CPU Unit users program area in machine lan guage The contents are read as a block from the beginning to the end Command Format x10 x10 97 R P x E 1 Unit No BCD Header FCS Terminator code Response Format x10 x10 R P x 16 x 16 x E a A a Unit
256. ntents of the specified number of consecutive program area words starting from the specified word Access right at UM read DIP switch UM Network write other device protection write protection protection ox wo Oo o O o O RUN mode MONITOR mode PROGRAM mode 03 06 FF FF Command Progra Beginning word No of code No bytes FINS Commands Section 5 3 Response Format 03 06 FF FF Command Endcode Program Beginning address No of Data code No bytes Parameters Program No command and response Set to FFFF hex Beginning address Command and response For the beginning address the beginning of the program area is specified as a relative address of 00000000 hex The beginning address must be a multiple of four Number of bytes command and response The number of bytes must be a multiple of four and no greater than 992 The leftmost bit bit 15 indicates whether the data at the last address in the pro gram area is included If bit 15 is ON 1 when the response is returned it indi cates that the data at the last address in the program area is included in the read data Bit 15 must be OFF 0 in the command format Bit 15 OFF 0 Without last address data Bit 15 ON 1 With last address data Bits 0 to 14 Number of bytes read Bits 0 to 7 second byte Bits 8 to 15 first byte
257. o Unit No BCD Se End code Status data Message FCS Terminator code The message is attached only when there is a FAL FALS message always 16 characters Status data consists of four digits two bytes hexadecimal The leftmost byte indicates the CPU Unit operation mode and the rightmost byte indicates the size of the program area x 163 x 162 Bit 15 14 13 12 11 10 9 8 0010 000 E Bit Operation mode 918 0 0 PROGRAM mode 1 0 RUN mode 1 1 MONITOR mode x 16 x 16 Bit 7 5 4 3 2 1 0 0 0 010 1 UM not write protected l 0 UM write protected Bit Program area 6 5 4 O O 1 10K steps 0 1 0 20K steps O 1 1 30K steps 0 60K steps oO 1 120K steps 1 1 O 250K steps In the case of a CU2 CPU Unit this is fixed at 111 Parameters Message Response The message for any FAL FALS occurring during command execution will be returned 133 C mode Command Details Section 4 3 Limitations RUN mode and MONITOR mode designations differ from those in STATUS WRITE Execution Conditions Commands Responses PLGmoas Umaea Single Multiple Single Multiple RUN MON PROG Write protected Read protected_ x No x No x x x o End Codes An end code of 14 format error will be returned if the length of the command is incorrect
258. o 99 or XX in the CompoWay F sys tem The characters are specified in ASCII When sending a broadcast trans mission set the node number to XX two X s Subaddress The subaddress is 00 for most models and the value is specified in ASCII as 3030 hex For some models other values must be set CompoWay F SID Service ID The Service ID is 0 for most models and the value is specified in ASCII as 30 hex For some models other values must be set CompoWay F Command Code This is the CompoWay F command code For details refer to the command manual for the CompoWay F Slave CompoWay F Text Command and Response This is the data that follows the command code Response Node Number This is the destination ID number 00 to 99 or XX in the CompoWay F sys tem The characters are specified in ASCII When a broadcast transmission is sent the node number is set to XX two X s Subaddress The subaddress is 00 for most models and the value is specified in ASCII as 3030 hex For some models other values must be set CompoWay F SID Service ID The Service ID is 0 for most models and the value is specified in ASCII as 30 hex For some models other values must be set End Code Response The end code indicates the command frame s execution result The end code is not the same as the response code which is described below 231 FINS Commands Section 5 3 CompoWay F Command Code This is the CompoWay F command code For details
259. o be read i e from the CPU Bus Unit configuration to the CPU Unit information 05 o1 64 bytes Command End code CPU Bus L CPU Unit information code Unit configuration Remote I O data The format is as shown below if nothing is entered as the data to be read i e all data from the CPU Unit model to the CPU Unit information 05 01 20 bytes 20 bytes 40 bytes 12 bytes 64 bytes Command End code CPU ah CPU Unit For system Area data CPU Bus L CPU Unit information code mode internal system use Unit configuration Remote iO data version y Data read for 00 Hex Data read for 01 Hex Parameters Data Command Specify the data to be read as follows Data to be read CPU Unit model CPU Bus Unit configuration CPU Unit internal system Remote I O data version CPU Unit information Area data CPU Unit model and internal system version response Each is returned in not more than 20 bytes in ASCII i e 20 ASCII characters If the model or internal system version requires less than 20 characters the model field will be filled with spaces and the internal system version field will be filled with null codes For system use response Reserved for system use 1st byte 2nd byte 34rh byte EE Reserved for system Largest EM bank number DIP switch data DIP switch data Status of DIP switch on front panel of CPU Unit Pins 0 to 7 corres
260. of bytes required is calculated as follows No of records x 12 bytes The configuration of each error record is as follows 1st byte 12th byte Node Not Command address used code Minute Day Hour Year Month Network Unit econd address address Network address The network address of the node that sent the FINS write command Node address The node address of the node that sent the FINS write command Unit address The Unit address of the Unit that sent the FINS write command Command code The command code of the FINS write command that was received MR and MS Year month day hour minute second day of week The year month day of month hour minute and second are expressed in BCD Year The rightmost two digits of the year 1998 1999 and 2000 are expressed as 98 99 and 00 respectively 2096 and 2097 will be expressed as 96 and 97 Hour 00 to 23 BCD End code response Refer to 5 7 3 End Codes for information on end codes FINS Commands Section 5 3 Comments An end code of 1103 hex address range overflow will be returned if the beginning record number is higher than the number of records contained in the PLC When the PLC does not have the specified number of records all the records that have been stored in the PLC will be read and a normal response will be returned If the data is too large and exceeds the permissible length of the response for
261. oller tion node address of Link for PLC to which Serial CMND 490 Communications Unit is mounted 3 Use to calculate the following Serial Communications Unit unit number unit address for the serial port Serial Communications Unit Port 1 80 hex 4 hex x unit number 3 serial port 8C hex Send destination unit 80 hex 4 hex x Set 8C hex in the control data address unit number 3 8C_ C 3 bits 00 to 07 send destina unit address of serial port hex or 10 unit tion unit address of CMND 490 on Serial Communications number 3 13 hex Alternatively set 13 hex in the Unit and serial port num control data C 3 bits 00 to 07 ber 1 1 hex send destination unit address and set 1 hex in C 2 bits 08 to 11 serial port number Communications Frames Section 3 7 e Modbus RTU Settings Command Frame Tem o Setvaue Setting location FINS command code Converting to 2804 hex Set 2804 hex in controller data Modbus RTU 2804 hex s of the CMND 490 instruc tion Modbus slave address e g 02 hex 02 hex Set 0210 hex in controller data FUNCTION code DATA WRITE 10 Sa ee hex Write data register No e g frequency 0002 hex Set 0002 hex in controller data reference 0002 hex s 2 of CMND 490 Number of write data registers e g 1 0001 hex Set 0001 hex in controller data register s 3 of CMND 490 Number of attached data registers 0200 hex Set 0200 hex in controller data Note Set 02
262. ollows refer to the following diagram Network Address An address that identifies the entire network All nodes on the same network have the same network address Node Address An address that identifies an individual node on a network such as a PLC or host computer 39 Settings for Sending FINS Commands Section 3 4 PLC Node address 8 Computer Node address 11 40 Controller Link Unit Unit Address For a PLC an address that identifies the specific Unit that is participating in the communication in the PLC For a host computer an address that identifies the specific application that is participating in the communication in the com puter L Computer PLC Node address 1 Node address 5 Ethernet network Network address 1 Node address 8 Unit address 12 Hex PLC BE Ethernet Unit Nodoadd a Unit address oqe aaaress 15 Hex Node ad Controller Link Network dress 7 Network address 2 Unit address of serial port 2 of the Serial Communi cations Unit 81 Hex 04 Hex x unit number PLC Node address 5 PLC Node address 3 Communications Unit CPU Unit Controller Link Unit Unitaddress Serial PLC Unit address 12 Hex 0 Hex communications Node address Host Host Link man Link unit number 0 to 31 1 RS 232C port on CPU Unit Settings for Sending
263. on Conditions RUN mode MONITOR mode PROGRAM mode FINS Commands Section 5 3 02 02 oe eS Command Parameter Beginning No of words Data code area code word Command Format Response Format 02 02 Command End code code Parameters Parameter area code command and response Specify the parameter area to write The parameter area code is designated in two bytes The leftmost byte is always 80 hex and the rightmost byte spec ifies the parameter area Beginning word command and response Specify the first word to write The beginning word address specifies the rela tive word address with the beginning of the designated area as 0000 hex Parameter Areas The areas that can be written to are shown below along with their parameter area codes Parameter Address range Parameter Address range area code Hex area code Hex r PLC Setup Area 0000 to 01FF 512 words I O Table Registration Area 0000 to 04FF 1 280 words 8000 0000 to 1F3F 8000 words Routing Table Area 0000 to 01FF 512 words CPU Bus Unit Setup Area 0000 to 143F 5184 words Number of words command Bits 0 to 14 are used to specify the number of words to be written Each word consists of two bytes Bit 15 must be ON 1 when data is written to the last word in the specified parameter area or no data will be written If the number of write words is set to 0000 no words will be written and a normal end code
264. on There is no Unit with the Check the destination unit address ing control data specified unit address 03 Third node Instruction The third node does not exist Check the unit address of the third missing control data node Check the node address of the third node in the send data for CMND 490 Command data Broadcasting was specified Specify only one node for the third node The destination node is busy Increase the number of retries or review the system so that the destination node does not receive so many messages The message was destroyed Increase the number of retries or by noise test communications between nodes to see if there is too much noise Instruction The response monitor time is Increase the length of the response control data too short monitor time Error history The send receive frame was__ Take appropriate measures based discarded on the error history 01 Communi Unit Board An error occurred in the Take appropriate measures based cations control indicators communications controller on the operation manuals for the ler error related Units Boards 02 CPU Unit CPU Unit A CPU error occurred inthe Clear the error from the CPU Unit error indicators at destination CPU Unit based on its operation manuals destination node 03 Controller Board indicators A response was not returned Check network communications error because an error occurred in status and restart the Board If t
265. ontain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Designate 0000 to 2047 for timers and 2048 to 4095 for counters add 2048 to the actual counter number Timers 2048 to 4095 and counters 2048 to 4095 cannot be read Commands are divided among timers and counters for execution If an attempt is made to designate across timers and counters an end code of 15 entry number data error will be returned Execution Conditions 7 Commands Responses PLG Mode Umaea Single Multiple Single Multiple RUN MON PROG Write protected Read protected Cox No OK OK OK OK OK ox ox End Codes An end code of 14 format error will be returned if the length of the command is incorrect and an end code of 15 entry number data error will be returned if 109 C mode Command Details Section 4 3 the specified words exceed the data area boundaries or are not specified in BCD or if the number of words to read is 0 End code Hex Normal completion 13 FCS error 14 Format error 15 Entry number data error 18 Frame length error 1 Not executable due to CPU Unit CPU error 4 3 6 TIMER COUNT
266. or the word address in which it is stored Timer Counter Number Command Designate the timer counter instruction number for reading the constant SV Index register designation is not possible The range that can be designated is the same as for R Constant Area Classification Command Designate the ASCII characters to express the new SV area classification or constant New SV Word Address Command Designate the newly set constant SV or the word address in which it is stored Timers T2048 to T4095 and counters C2048 to C4095 cannot be read The SV of the first timer counter found after the designated program address will be read If the SV is outside of range for the timer counter type or number an end code of 16 command not supported will be returned 129 C mode Command Details Execution Conditions Commands Responses PiGmos Umaea Single Multiple Single Multiple RUN MON PROG Write protected Read protected No No Section 4 3 If the SV is a DM or EM indirect address only indirect BCD designations will be read and an end code of 16 command not supported will be returned if the indirect designation is not BCD The SV can be changed only in cyclic task 0 The maximum EM bank number that can be specified is 12 OC Hex ok No OK No No OK OK End Codes An end code of 14 format error will be returned if the length of the command is
267. or log area 5 3 30 FINS WRITE ACCESS LOG READ 21 40 Execution Conditions Command Format The CPU Unit automatically keeps a log of any access for FINS write com mands regardless of the setting This command reads this log which tells the nodes and time when there was access Access right at UM read DIP switch UM Network write other device protection write protection protection RUN mode MONITOR mode PROGRAM mode 21 40 Command Beginning No of code record No records 209 FINS Commands Response Format Parameters 210 Section 5 3 21 40 12 bytes 12 yes Command End code Max No of No of No of Access log gt 55 Access log code stored records stored records data data records read Beginning record number command Specify the first record to be read The first record number is 0000 hex Number of records command response Specify the number of records to read The number of read records will be returned with the response Maximum number of stored records response Indicates the maximum number of records that can be stored Always 20 records Number of stored records response Indicates the number of records recorded at the time the command is exe cuted Access log data response The specified access log records will be returned in sequence starting from the beginning record number The total number
268. or number of words to write Response Format x10 x10 9 W R x161 x 16 x a IN Unit No BCD Header End code FCS Terminator code Execution Conditions Commands Responses PiCmoas Umawa _Singie_ Multiple Single Multiple RUN MON PROG Write protected Read protected_ p OK x x N No x x KK End Codes An end code of 14 format error will be returned if the length of the command is incorrect or the first word of write data is not in the first frame An end code of 15 entry number data error will be returned if the specified write data exceeds the data area boundaries the beginning word is not speci fied in BCD or the write data is not hexadecimal An end code of A5 will be returned instead of 15 for non hexadecimal write data in multiple command frames o noman S 114 C mode Command Details Section 4 3 4 3 11 LR AREA WRITE WL Writes data to the Link Area CIO 1000 to CIO 1199 starting from the speci fied word Writing is done in word units Command Format TO x 10 x 10 W L sx 108 x 10 x 104 x 10 x 16 x 167 x 16 x 16 kJ ese eu a Unit No BCD Header Beginning word Write data 1 word FCS Terminator code 000 to 0199 Write data for number of words to write Response Forma x10 x100 W L x 161 x 16
269. ost Computer SEND 090 i Sample Send Program L RK KKKKKKKKKKKKKKKKKKKKKK KKK KKK KKK KKK KKK Initial Settings CLOSE 1 ON ERROR GOTO EROPE DIM CHDATAS 300 i Data array declaration OPEN iCOM E73i AS 1 i Opens port 1 Tess Man Process INPUT 1 COMMANDS i Receives data from PLC line TS LEFTS COMMANDS LEN COMMANDS 3 Checks FCS GOSUB FCS IF FCSS lt gt MIDS COMMANDS LEN COMMANDS 2 2 THEN ENDCODES 110041 GOTO RESPONSE CMNDCODES MIDS COMMANDS 27 4 Checks command code IF CMNDCODES lt gt i01021 THEN ENDCODES 10401i2 GOTO RESPONSE FOR I 0 TO VAL i1 amp Hi MIDS COMMANDS 39 4 1 i Sets No of write elements CHDATAS I MIDS COMMANDS 43 1 4 4 PRINT 2Datals 121 CHDAITAS I NEXT I ENDCODES 7 00007 Sets end code to 0000 Hs RESPONSE RSV MID COMMANDS 9 2 DAS MID COMMANDS 19 6 SAS MIDS COMMANDS 13 6 Swaps DNA DA1 DA2 SID MID COMMANDS 25 2 with SNA SA1 and SA2 TSS 7 000F00C01 RSVS 1021 DAS SA SID CMNDCODE ENDCODES GOSUB FCS RESPONSES TS FCSS i i PRINT 1 RESPONSES i Transmits data to PLC line GOTO 140 Creates a response frame Returns received RSV SID without change Hs Hs te s FCS Calculation Subroutine FCS Adds FCS A 0 FOR lt J 1 TO T TUS MIDS ATO wi E A ASC TJS XOR A NEXT J FCSS HEXS A IF LEN FCSS L THEN FCSS 707 FCSS RETURN
270. otocopying recording or otherwise without the prior written permission of OMRON No patent liability is assumed with respect to the use of the information contained herein Moreover because OMRON is con stantly striving to improve its high quality products the information contained in this manual is subject to change without notice Every precaution has been taken in the preparation of this manual Nevertheless OMRON assumes no responsibility for errors or omissions Neither is any liability assumed for damages resulting from the use of the information contained in this publication ae EE Ex CS1 H CPU Units NSJ Series CJ2 CPU Units a 3 CJ2H CPU Units CJ2H CPU6LI EIP CJ2H CPU6 NSJ Controllers NSJ5 TQOO B G5D NSJ5 SQO0 B G5D NSJ8 TVOO B G5D CS1H CPULILIH CS1G CPULILIH NSJ10 TVLIL1 B G5D A CS1D CPU Units i CJ2M CPU Units e e y CS1D CPU Units for CJ2M CPU3 Duplex Systems CJ2M CPU1 NSJ Controllers CS1D CPUOOH S CS1D CPU
271. p NOY NOK FINS Commands Command Format Response Format Parameters Comments Note Section 5 3 03 08 FF FF Command Program code No Clear code 03 08 Command End code code Program No command Set to FFFF hex Clear code command Without interrupt tasks 00 hex With interrupt tasks 10 hex End code response Refer to 5 1 3 End Codes for information on end codes The program area can be cleared even if it is read protected from a Program ming Device When the program area is cleared protection will also be cleared Without Interrupt Tasks In this mode only one single cyclic task 0 is set up Name OO oe O ao Power interrupt task E Scheduledinteruptiask 0 O interrupt task e ae C With Interrupt Tasks In this mode one single cyclic task 0 and one or several interrupt tasks are set up Name Nite task No Power interrupt task C Scheduled interrupt task a TO interrupt task Cyclic task Interrupt tasks and cyclic tasks contain only one END 001 instruction after execution When the Prohibit from overwriting to a protected program setting is enabled this command cannot be executed 187 FINS Commands 5 3 13 RUN 04 01 Note Execution Conditions Command Format Response Format Parameters Comments 5 3 14 STOP 04 02 Note 188 Section 5 3 Changes the CPU Unit s operating mode to MONITOR or
272. pond to bits 0 to 7 ON 1 OFF 0 Largest EM bank Largest number 0 to 19 in CPU Unit s EM area Bank number 190 FINS Commands Section 5 3 Area data response The area data is configured as follows 1st byte 12th byte Not used No of DM words Program Memory card area size size IOM size Timer counter EM size Memory card type size Program area size Maximum size of usable program area K words 1K words 1 024 words IOM size The size of the area CIO WR HR AR timer K bytes 1K bytes 1 024 bytes counter completion flags TN in which bit commands can be used always 23 Number of DM words Total words in the DM area always 32 768 Timer counter size Maximum number of timers counters available x 1 024 always 8 EM non file memory size Among the banks in the EM area the number of Banks 1 bank 32 768 words banks 0 to D without file memory Memory card type 00 No memory card 04 Flash memory Memory card size Size of the memory card 0000 if there is no memory K byte 1 word 2 bytes card CPU Bus Unit configuration response Each CPU Bus Unit has a code assigned to it consisting of two ASCII charac ters two bytes These codes are given in the numerical order according to the unit number of the CPU Bus Units unit 0 to 15 1st byte a 32nd byte a 64th
273. ports CJ2M CPU3L 1 Serial Option Board CS1G H CPULI_JH built in ports CS1G H CPULILI EV1 built in ports CS1D CPULILIH built in ports CJ1G H CPULIL_IH built in ports CJ1G CPULIL built in ports CJ1M CPULJL built in ports CS1W SCB21 V1 41 V1 unit version Pre Ver 1 2 Serial Com munications Board ports CS1W SCU21 V1 unit version Pre Ver 1 2 Serial Communica tions Unit ports CJ1W SCU21 41 unit version Pre Ver 1 2 Serial Communica tions Unit ports P ff CVM1 CPUL IL built in ports CV CPULIL built in ports CV500 LK201 Host Link Unit 121 words 125 words Note There are several exceptions to the number of words per frame values shown in the table above The following responses are returned when reading 246 words of Timer Counter Completion Flags through CS CJ series CPU Unit built in ports CS CJ series Serial Communications Units Boards C200HX HG HE CPU Unit built in ports or C200HS CPU Unit built in ports TaT words T24 words The second to last frame contains 124 data words and the last frame contains 1 word This also applies when the number of words is 246 a multiple of 125 i e 371 words 496 words 621 words etc 17 Precautions when Reusing Programs from Earlier Models Section 2 4 The following responses are returned when reading 121 words of Timer Counter Completion Flags through CS CJ series Unit built in ports 120 words The following responses are return
274. pose and under the specified conditions especially in applications that can directly or indirectly affect human life You must consult with your OMRON representative before applying a PLC System to the above mentioned appli cations 3 Safety Precautions N WARNING The CPU Unit refreshes I O even when the program is stopped i e even in PROGRAM mode Confirm safety thoroughly in advance before changing the status of any part of memory allocated to I O Units Special I O Units or CPU Bus Units Any changes to the data allocated to any Unit may result in unex pected operation of the loads connected to the Unit Any of the following oper ation may result in changes to memory status e Transferring I O memory data to the CPU Unit from a Programming Device e Changing present values in memory from a Programming Device e Force setting resetting bits from a Programming Device e Transferring I O memory files from a Memory Card or EM file memory to the CPU Unit e Transferring I O memory from a host computer or from another PLC ona network N WARNING Do not attempt to take any Unit apart or touch the inside of any Unit while the power is being supplied Doing so may result in electric shock XVI Safety Precautions 3 N WARNING N WARNING N WARNING Caution Caution Caution Do not touch any of the terminals or terminal blocks while the power is being supplied Doing so may result in electric shock
275. possible Change the PLC Setup so that the because automatic data link data link tables can be manually table generation has been written Cannot write data link table specified 03 Cannot Number of files The file cannot be created Delete any unnecessary files or register in file device because the limit has been create more file memory exceeded Number of files The maximum number of Close one or more files and then open files has already been execute the command opened for the system limit 05 Program Program A non existing program Check the program numbers and missing number in number has been specified specify a valid one command data 06 File missing File name The file does not exist at the Correct the file name and then specified file device execute the command 07 Filename _ File name A file with the same name Change the name of the file being already exists inthe specified written and then execute the file device command 08 Cannot Contents of The change cannot be made change memory being because doing so would changed create a problem already exists Command Lists Section 5 1 Chek point Probable cause 22 Not execut 01 Notpossi The mode is incorrect Check the mode able in current ble during Data link status The data link is operating Check the status of the data links mode execution 02 Not Sy The mode is incorrect Check the mode nine whil
276. r EM indirect address only indirect BCD designations will be read and an end code of 16 command not supported will be returned if the indirect designation is not BCD Execution Conditions Commands Responses PLG Mode Umawa Single Multiple Single Multiple RUN MON PROG Write protected Read protected x o OK No No x x No _ No 127 C mode Command Details Section 4 3 End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the program address is not specified in BCD or if the timer counter type or number is out of range including hexadecimal data An end code of 16 command not supported will be returned if the specified instruction does not exist in the UM Area o Nommalcomplefon SSCS 4 3 21 TIMER COUNTER SV CHANGE 2 W From the specified program address onwards in cyclic task 0 TIMER COUNTER SV CHANGE 2 finds the specified timer counter instruction and changes the 4 digit constant SV BCD that is set or the word address where the SV is stored to a newly designated constant SV or storage word address Command Format x 10 x 10 W x 102x102 x10 x 10 OP1 OP2 OP3 OP4 x 102x102 x10 x 10 gt 1 N Unit No BCD A Be Timer counter type Timer counter number
277. r areas write ee a RUN mode MONITOR mode PROGRAM mode Pp mno o o O oo Note Forced status means that the ON OFF status of the bit flag is forcibly retained and writing is prohibited 228 FINS Commands Section 5 3 Command Format 23 01 Command No of Set reset Bit flag Set reset designation Bit flag code bits flags designation I O memory area code I O memory area code Forced set resetdata Forced set reset data Response Format 23 01 Command End code code Parameters Number of bits flags command Specify the number of bits flags to be controlled Set reset designation command Specify the action to be taken for each bit flag Value Operation hex 0000 Forced reset Turns OFF 0 the bit flag and places it in forced a See note 0001 Forced set Turns ON 1 the bit flag and places it in forced A 8000 Forced set reset OFF release Turns OFF 0 the bit flag and releases elie status 8001 Forced set reset ON release Turns ON 1 the bit flag and releases the forced status FFFF Forced set reset release Releases the forced status while retaining the ON OFF status I O memory area code Command Specify the I O memory area of the bit or flag to be controlled Bit Flag command Specify the bit or flag to be controlled The memory areas in which bits flags can be controller are given in the followi
278. r non hexadecimal write data in multiple command frames o nomani SSCS 120 C mode Command Details Section 4 3 4 3 17 TIMER COUNTER SV READ 1 R Reads the constant SV 4 digits BCD written in the operands of designated timer counter instructions from cyclic task 0 If there are multiple timer counter instructions designated in cyclic task 0 TIMER COUNTER SV READ 1 will read the SV of the designated instruction with the lowest program address Command Format x10 x100 R x 10 x 10 x 10 x 10 k d IN Unit No BCD Header Timer counter type Timer counter FCS Terminator code number Instruction name Timer counter type Timer counter Char Char Char Char number BCD acter 1 acter 2 acter 3 acter 4 HIGH SPEED COUNTER T 0000 to 2047 WAIT TIMER WAIT o o WAIT amem e o e HIGHSPEED TIMER T I m W TOTALING TIMER M po o Mo REVERSIBLE COUNTER c N h R me fp i Mm o Note SP represents a space 20 Hex Response Format x10 x10 R x 16 x 16 x 10 x 10 x 10 x 10 x aS Unit No BCD Header Endcode SV of instruction des FCS Terminator code ignated by command constant Parameters Timer Counter Type Command Designate in ASCII characters the type of TC instruction for reading the con stant SV Timer Counter Number Command Desig
279. r parameters to another node or changing contents of the any of these items Transferring or changing data can result in unexpected system operation Tighten the terminal screws on the AC Power Supply Unit to the torque speci fied in the operation manual The loose screws may result in burning or mal function Do not touch the Power Supply Unit when power is being supplied or immedi ately after the power supply is turned OFF The Power Supply Unit will be hot and you may be burned Be careful when connecting personal computers or other peripheral devices to a PLC to which is mounted a non insulated Unit CS1W CLK12 52 V1 or CS1W ETNO1 connected to an external power supply A short circuit will be created if the 24 V side of the external power supply is grounded and the 0 V side of the peripheral device is grounded When connecting a peripheral device to this type of PLC either ground the O V side of the external power supply or do not ground the external power supply at all Operating Environment Precautions Caution Caution Caution Do not operate the control system in the following places e Locations subject to direct sunlight e Locations subject to temperatures or humidity outside the range specified in the specifications e Locations subject to condensation as the result of severe changes in tem perature e Locations subject to corrosive or flammable gases e Locations subject to dust especially iron du
280. rds exceed the data area boundaries or are not specified in BCD or if the number of words to read is 0 End code Hex 00 Normal completion Entry number data error Frame length error Not executable due to CPU Unit CPU error Note The command is provided for compatibility with previous models We recom mend using CIO AREA READ RR whenever possible 4 3 4 HR AREA READ RH Reads the contents of the specified number of HR words starting from the specified word Command Format x10 x 10 R H x 10 x 10 x 10 x 10 x 10 x 10 x 10 x 10 x i Unit No Header Beginning word No of words FCS Terminator BCD code 0000 to 0511 0001 to 0512 Response Format x10 x10 R H x 16 x 16 x 16 x 167 x 16 x 16 x a seed Unit No Header End code Read data 1 word FCS Terminator BCD code Read data for number of words read Limitations The text portion of the response s first frame can contain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words The INITIALIZE and ABORT commands can be sent instead of the delimiter for multiple responses for this command If other commands are sent they will be treated as delimiters Execution Conditions 7 Commands
281. re is no response 4 3 39 Undefined Command IC Response Format Limitations End Codes 148 This response is returned if the header code of a command cannot be decoded x10 x100 a x E 1 a Unit No BCD Header FCS Terminator code This response will be returned as an error for illegal header codes This response will be returned for error frames as well There is no command associated with IC There are no end codes with this command SECTION 5 FINS Commands This section provides detailed descriptions of the FINS commands Sk Command LIS sneri n anne woah EEEE Renee ha et aad oe ee ee erie 150 Sale FINS Commands 4 64 35 hacd Hote eee tee eee de 150 5 1 2 FINS Command Restrictions 0 000 153 Seles sBAdCOdeS ss cars var b Sones sae es sae Ome eee sae eA was 155 5 2 Designating Command Parameters 0 0 163 5 2 1 Designating I O Memory Variable Area Addresses 163 5 2 2 I O Memory Address Designations 0 0000 165 Deo FUNS Commands 2i 0o06 Irea nE sate Sane eene sa aes ed ee sae pares 170 9 321 3ADGOUC IMIS SCCHON s serie te ea a Re Re ee tens Mae 170 5 3 2 MEMORY AREA READ 0101 0 0 2 000 eee 171 5 3 3 MEMORY AREA WRITE 0102 0 0 0 0 0 cae 174 5 3 4 MEMORY AREA FILL 0103 0 0 0 0 eee eee 175 5 3 5 MULTIPLE MEMORY AREA READ 01 04 177 5 3 6 MEMORY AREA
282. rea words MEMORY AREA WRITE See note Writes the contents of consecutive I O memory area words 01 03 MEMORY AREA FILL See note Writes the same data to the specified range of I O memory area words MULTIPLE MEMORY AREA READ Reads the contents of specified non consecutive I O memory area words MEMORY AREA TRANSFER See Copies the contents of consecutive I O note memory area words to another I O memory area Parameter area PARAMETER AREA READ Reads the contents of consecutive access parameter area words 02 02 PARAMETER AREA WRITE See note Writes the contents of consecutive parameter area words PARAMETER AREA FILL CLEAR Writes the same data to the specified See note range of parameter area words Program area o3 Jo PROGRAM AREA READ Reads the UM User Memory area Agree 03 07 PROGRAM AREA WRITE See note _ Writes to the UM User Memory area o3 joss PROGRAM AREA CLEAR See note Clears the UM User Memory area Operating mode 04 01 RUN See note Changes the CPU Unit s operating changes mode to RUN or MONITOR 04 02 STOP See note Changes the CPU Unit s operating mode to PROGRAM Machine configura CPU UNIT DATA READ Reads CPU Unit data tion reading 05 02 CONNECTION DATA READ Reads the model numbers of the device corresponding to addresses Status reading 06 01 CPUUNIT STATUS READ Reads the status of the CPU Unit 20 CYCLE TIME READ Reads the maximum minimum and average cycle time Tim
283. refer to the command manual for the CompoWay F Slave CompoWay F Response Code The CompoWay F response code indicates the results of the service requested by the command code For details refer to the command manual for the CompoWay F Slave CompoWay F Text This is the data that follows the response code Precautions e FINS Header Destination Address The following settings are required e Destination Network Address DNA e When a routing table is created to treat the serial communications path as a network this is the network address associated with the Serial Communications Unit or Board s serial port by the routing table e When a routing table is not created to treat the serial communications path as a network this is the actual network address used to specify the destination PLC e Destination Node Address DA1 e When a routing table is created to treat the serial communications path as a network set 00 hex for communications within the local PLC or the Host Link unit number 1 for serial serial serial conversion e When a routing table is not created to treat the serial communications path as a network this is the actual node address used to specify the destination PLC the Host Link unit number 1 for serial serial gt serial conversion e Destination Unit Address DA2 This is the serial port s unit address Settings for a Serial Communications Board or Unit e Unit addresses for
284. reset The following codes can be used regardless of the operating mode of the CPU Unit hex This code can be used in PROGRAM mode only FFFE Basic I O error PLC Setup error OOA0 to 00A1 SYSMAC BUS error 00D1 to 00D2 Option Board error I O verification error e When the registered I O tables differs from the actual I O tables e When an I O Unit has been added or removed Flash memory error Battery error 0200 to 020F CPU Bus Unit error The rightmost two digits are the unit number in binary of the Unit that has the error e When a error occurs during data transfer between the CPU Bus Unit and CPU Unit e When the CPU Bus Unit has a watchdog timer error Non fatal Inner Board error olo O ololololo lo lo Olo Ol l l l l olo nTn mMm lololol 5 N N Cl gt Ww S rt o a NO TI FINS Commands Section 5 3 0300 to 035F Special I O Unit error The rightmost two digits are the unit number in binary of the Unit that has the error 0400 to 040F CPU Bus Unit setting error The rightmost two digits are the unit num ber in binary of the Unit that has the error 0500 to O55F Special I O Unit setting error The rightmost bi digits are the unit number in binary of the Unit that has the error 0600 to O60F Duplex communications error The rightmost i digits are the unit number in binary of the Unit that has the error 4101 to 42FF System error FAL FAL 006 was executed
285. response code Data FCS Terminator 1 076 characters 538 bytes Responses from a CPU Unit on a Network Nc TS a N Gare No Header code DA2 SNA SA1 SA2 SID FINS command code FINS response code Data FCS Terminator 1 076 characters 538 bytes 47 FINS Commands with Host Link Protocol Section 3 5 Host Link Settings The symbol must be attached to the beginning of the response Unit Number and Header Code The same unit number and header code specified in the FINS command that was received will be returned ICF Information Control Field For a CPU Unit on a network CO ASCII 48 30 will be returned For a CPU Unit connected directly to the host computer 40 ASCII 34 30 will be returned RSV Reserved This section is reserved for the system Do not access the RSV GCT Gateway Count This section is reserved for the system Do not access the GCT The same GCT that was specified in the command that was received will be returned Setting GCT is required in the response format only from a CPU Unit on a net work DNA Destination Network Address DA1 Destination Node Address DA2 Destination Unit Address The same contents specified for SNA SA1 and SA2 in the command that was received will be returned Setting DNA and DA1 is required for response formats only from a CPU Unit on a network SNA Source Network Address SA1 Source Node Address SA2 Source Unit Address Th
286. ries PLC Host Link Slave Note ihn es can be connected to other networks as shown be CPU Units in PLCs connected to Required ay the network can access a PLC on another network via a PLC slave that is connected serially to the Serial Communications Board Unit Network Ethernet Controller via Host Link Link DeviceNet RS 422A 485 Host Link inl er CS Cu series or Used as Host CVM1 CV series PLC Link Master Host Link Slave Network Ethernet Controller LInk DeviceNet Note 1 The FINS header contains the following information 77 Serial Gateway Overview Section 3 6 e Remote destination network address DNA e With routing tables that treat serial communications path as a network Network address corresponding to serial port in the routing tables e Without routing tables that treat serial communications path as a net work Unit address of serial port e Remote destination node address DA1 e With routing tables that treat serial communications path as a network Unit number for Host Link incremented by 1 1 to 32 e Without routing tables that treat serial communications path as a net work Unit number for Host Link incremented by 1 1 to 32 e Remote destination unit address DA2 Any unit address except that for the serial port The destination for the FINS message must not be the serial port of the Board Unit e FINS command code Any 2 When creating
287. rom CIO 0100 to D00010 and later Execute SEND 090 When the instruction for network communications has been completed A202 04 ON CIO 0128 01 will turn ON and the instruction for sending on the network is completed Turns ON when an error is generated during execution of network commu nications When the Communications Port Enabled Flag is ON and execution condi tion ClO 0000 01 is ON execution of the instruction for receiving via the network RECV 098 is started Set the control data D0100 00 oA Number of receive words 10 Serial port 2 Source network address 01 Source node address 04 Source unit address 01 Inner Board Response required Communications port No 4 lt Number of retries 5 D00104 00 30_ Response monitor time 4 8 s 0030 Execute RECV 098 When the execution of network communications instructions has been completed A202 04 ON ClO 0128 03 will turn ON and the instruction for receiving via the network is completed Turns ON when an error is generated during execution of network commu nications Reception data processing When there is no reception error 10 words of data starting from D02000 are stored from D05030 onwards 63 FINS Commands with Host Link Protocol Section 3 5 Programming Example for Host Computer Side BASIC Send 64 LRA KKKKKKKKKKKKKKKKKKKKKKKKK KKK KKK KKK KKK i CS1W SCU21 Serial Communications Unit i Command to H
288. rsion via the network e Under other conditions routing tables are optional The details are provided in the following tables 78 Serial Gateway Overview Section 3 6 Conditions Requiring Routing Tables According to Target Protocol Case Routing tables conversion for treating serial communications path as network PLC CS CJ CP NSJ Series CVM1 Host Link Routing FINS network including Network to Required CV A FINS serial communications path for serial con Serial Gateway version Serial communications path con Serial to Optional nection only serial con version Any component OMRON Compo CompoWay Routing FINS network including Network to Optional except PLC nent F serial communications path for serial con Serial Gateway version Modbus RTU Modbus Serial communications path con Serial to Optional Slave including RTU nection only serial con OMRON Inverter version Modbus ASCIl Modbus Slave ASCII Specifying Address in FINS Command Source Protocol Routing FINS header conversion tables for Remote network Remote node Remote unit treating address address address serial com munica tions path as network PLC CS CJ CP NSJ Host Link Created Network address Host Link unit num Must be the actual Series CVM1 CV Series FINS assigned to the ber incremented by unit address of the serial port accord 1 1 to 32 destination unit ing to the routing See note tables
289. rview of Command and Response Frames When FINS commands and responses are sent or received using Host Link communications the frame must be preceded by a Host Link header and fol lowed by a Host Link FCS and terminator as shown below Host link terminator Command Frame Use the following format to send FINS command frames Host Link header eos Host Link terminator Note A FINS command frame also consists of the response wait time the destina tion node address the source node address and other FINS command for mat data 44 FINS Commands with Host Link Protocol Section 3 5 Response Frame The CS CJ CP series CPU Unit or NSJ Controller that receives the command will return the following response frame to the host computer Note A FINS response frame also consists of the contents set at the time of trans mission and the FINS command response format data 3 5 3 Sending Commands from the Computer to the CPU Unit Command Format from Host Computer Use the following command format to send FINS commands from the host computer to the CPU Unit Note The length of the command must be not more than 1 114 characters FINS commands cannot be partitioned into separate frames for sending Sending Commands to a CPU Unit Directly Connected to the Host Computer Note The following format is also applicable for a host computer connected to a Serial Communications Board or a Serial Communications Unit Header Unit No code Je
290. s RTU protocol for sending in this operation Access from CPU Unit on the Same PLC CPU Bus to Serial Routing tables to treat serial communications path as network eevial Sofunitn Gakions T OMRON Inverters connected serially to Optional are the Serial Communications Board Unit using Modbus RTU can be accessed from a CPU Unit in the same PLC Modbus RTU Slave device z e g OMRON Inverter Access from CPU Unit on Network PLC FINS message to Serial Routing tables to treat serial communications path as network tae OMRON Inverters connected serially to Optional 5 j the Serial Communications Board Unit using Modbus RTU can be accessed from a CPU Unit in a PLC connected to the net work FINS message FINS header Modbus RTU Network Ethernet Controller Link jOdbDuUs comman d RS 485 Modbus RTU Modbus RTU Slave device 55 G SBB e g OMRON P Inverter Fa oo pu 71 Serial Gateway Overview Section 3 6 Executing Smart Active Parts Using an NS series PT Sending Internal FINS Messages The Board Unit converts the FINS messages to Modbus RTU protocol for sending in this operation Access from PT on Ethernet or Routing tables to treat serial serial NT Link communications path as network Access via serial communications using Modbus RTU is possible from a PT con nected to the network by e
291. s address address DNA DA1 Serial port Slave FUNCTION Communications data allocated address code ASCII code n characters ASCII code ASCII code or error code 2 characters 2 characters 4 bytes 4 bytes or local network node address 3 7 4 Host Link FINS Command Frame Frame before Conversion Eo Yh FINS header Eo Yh C e C e Remote Remote Remote Etc MRC SRC network node unit address address address Serial port i f User specified allocated for Host except address i serial or serial port port unit unit address address Frame after Converaton Host Host Link Link header header zode Unit No for FINS header FINS FINS text Host Link command 0 to 31 89 Communications Frames Section 3 7 Response Frame Frame before Conversion l Host Etc Error Host Link Link check Terminator header header code code Unit No for FA FINS header FINS End code FINS text Host Link command 0 to 31 ra FINS header ra End code code FNS O text Remote Remote Remote Etc MRC PE network node unit address address address DNA DA1 DA2 Serial port Unit No User specified allocated for Host address Link or serial 1 port unit 1 to 32 address 3 7 5 Sending Commands Using the CMND 490 Instruction Use the following method to send FINS commands to the Serial Communica tions Board Unit from the PLC Setting CMND 490 Operands S
292. s beyond the and set the correct range accessible area 04 Address Starting address The end address in com Check the area being processed range and number of mand process is beyond the and set the correct range exceeded elements in accessible area command data Data link tables The total number of words is Correct the data link tables beyond the limit 06 Program Program FFFF hex was not specified Specify FFFF hex missing number in command data 09 Relational Command data A large small relationship in Check the command data and error the elements in the command correct the relationship between the data is incorrect elements Data link table A node not set in the Correct the data link tables common link parameters is set as a refresh parameter OA Duplicate 1 O access in Differential monitoring was Abort the current process or wait data access CPU Unit specified during data tracing until it ends before executing the or data tracing was specified command during differential monitoring Data link tables The same node address is Correct the data link tables specified more than once OB Response Number of ele The response format is Check the command format and too long ments in com longer than the maximum correct the number of elements mand data permissible length OC Parameter Parameters in There is an error in one of the Check the command data and error command data ___ parameter se
293. s created to treat the serial communications path as a network this is the network address associated with the Serial Communications Unit or Board s serial port by the routing table e When a routing table is not created to treat the serial communications path as a network this is the actual network address used to specify the destination PLC e Destination Node Address DA1 e When a routing table is created to treat the serial communications path as a network set 00 hex for communications within the local PLC or the Host Link unit number 1 for serial serial serial conversion e When a routing table is not created to treat the serial communications path as a network this is the actual node address used to specify the destination PLC the Host Link unit number 1 for serial serial gt serial conversion e Destination Unit Address DA2 This is the serial port s unit address Settings fora CP1H CPU Unit and CP1L CPU Unit Serial port 1 Slot 1 for optional board Serial port 2 Slot 2 for optional board CPU Unit port Unit address of port Serial port 1 FD hex 253 decimal Serial port 2 FC hex 252 decimal Settings for a Serial Communications Board or Unit e Unit addresses for serial port 1 Unitnumber 0 1 2 3 4 5 6 7 8 9 A BI C D E F Boara Hexadecimal 80 84 88 8C_ 90 94 98 joc ao A4 as AC BO B4 BE BC E4 e Unit addresses for serial port 2 Unitnumber o 1
294. s with the 1 N Host Link format and 1 1 Host Link format 21 Precautions when Reusing Programs from Earlier Models Section 2 4 1 N Format e Command eoori A aes eae CRS Unit number Header FCS Terminator in host link code e Response CECO Unit number Header End FCS Terminator in host link code code 1 1 Format As shown in the following diagrams the 1 1 format is equivalent to the 1 N for mat without the character Host Link unit number and FCS byte Command format Header Terminator code e Response format Lt Header End Terminator code code 2 4 3 C mode Command Support Use the following table as reference when reusing programs for host comput ers developed for earlier Host Link models e If a command is not supported for the new model of PLC consider using another C mode or FINS command e Even if the command is supported differences may exist in the data sizes that can be processed or in the meaning of the values if the models or series vary e Refer to the applicable operation manuals for details 22 Precautions when Reusing Programs from Earlier Models Section 2 4 Note Refer to information on the previous page for commands with Caution in the Frame data size column Header CS CJ C Series code Series C200HE C200HS C120 C500 C1000H C500F C1000HF CQM1 HG HX C2000H Cau CIO AREA ha a iia al Yes tion READ Cau LR AREA Yes Yes Yes Yes tion READ Cau oe AREA p
295. sec utive I O memory area words 01 05 MEMORY AREA TRANSFER See Copies the contents of consecutive I O mem note ory area words to another I O memory area Parameter area PARAMETER AREA READ Reads the contents of consecutive parame access ter area words PARAMETER AREA WRITE See Writes the contents of consecutive parame note ter area words 02 03 PARAMETER AREA FILL CLEAR Clears the specified range of parameter area See note words Program area 03 joe PROGRAM AREA READ Reads the UM User Memory area access ab aak PROGRAM AREA WRITE See Writes to the UM User Memory area note PROGRAM AREA CLEAR See Clears a specified range of the UM User note Memory area Operating mode RUN See note Changes the CPU Uni s operating mode to changes RUN or MONITOR STOP See note Changes the CPU Unit s operating mode to PROGRAM Machine configura CPU UNIT DATA READ Reads CPU Unit data tion reading 05 02 CONNECTION DATA READ Reads the model numbers of the device cor responding to addresses Status reading 06 01 CPU UNIT STATUS READ Reads the status of the CPU Unit 20 CYCLE TIME READ Reads the maximum minimum and average cycle time Time data access 07 01 CLOCK READ Reads the present year month date minute second and day of the week 07 02 CLOCK WRITE See note Changes the present year month date minute second or day of the week Type Command code Message display Access rights 01
296. sing the internal clock for a CS series CS1 CPU Unit turn ON power after installing the battery and set the clock from a Programming Device or using the DATE 735 instruction The clock will not start until the time has been set Not required for CS1 H CJ1 CJ1 H CJ1M or CS1D CPU Units e When using a CS1 H CJ1 CJ1 H CJ1M or CS1D CPU Unit the PLC Setup is set to specify using the mode set on the Programming Console and a Programming Console is not connected the CPU Unit will start in RUN mode This is the default setting in the PLC Setup A CS1 CPU Unit will start in PROGRAM mode under the same conditions e When creating an AUTOEXEC IOM file from a Programming Device a Programming Console or the CX Programmer to automatically transfer X X Application Precautions XX 5 data at startup set the first write address to D20000 and be sure that the size of data written does not exceed the size of the DM Area When the data file is read from the Memory Card at startup data will be written in the CPU Unit starting at D20000 even if another address was set when the AUTOEXEC IOM file was created Also if the DM Area is exceeded which is possible when the CX Programmer is used the remaining data will be written to the EM Area Always turn ON power to the PLC before turning ON power to the control system If the PLC power supply is turned ON after the control power sup ply temporary errors may result in control system signals
297. ss 2 Local PLC internal communications 00 hex Remote unit address _ 3 Serial port unit address 80 hex 128 decimal Calculated from unit number 0 port 1 Serial communications path Host Link FINS Serial Communications Unit Board E g Unit number 0 port 1 Routing tables for treating serial PLC communications path as a network l z i Vetwor 5 80 hex 128 decimal A Calculated from Unit No 0 port 1 Serial communications path 2 Unit address srecom Modbus 1 Network address To serial port unit To serial communications path network address A address e g 80 hex Target OMRON Component or Modbus Slave 82 Serial Gateway Overview Section 3 6 Serial to Serial to Serial Conversion Without Routing Tables With Routing Tables Routing tables to enable the serial communications path to be treated as a network are optional Specify the addresses as shown in the following example Address Specification Address portents Example i 1 rial por 89 hex 137 decimal Remote net linitaddress l ealuated trom PLC 1 unt number 2 port Remote node PLC_2 unit number for s41 Host Link 1 Remote unit PLC_2 serial port en a a p ar F u unit nu Serial communications address unit address 0 port 1 path Host Link FINS Serial Communications Unit Board E g Unit number 2 port 1 PLC_1 No routing tables required to treat serial
298. ss when installing the Units Not connecting to a ground of 100 Q or less may result in electric shock A ground of 100 Q or less must be installed when shorting the GR and LG terminals on the Power Supply Unit e Always turn OFF the power supply to the PLC before attempting any of the following Not turning OFF the power supply may result in malfunction or electric shock e Mounting or dismounting Power Supply Units I O Units CPU Units Option Boards or any other Units e Assembling the Units e Setting DIP switches or rotary switches e Connecting cables or wiring the system e Connecting or disconnecting the connectors N Caution Failure to abide by the following precautions could lead to faulty operation of the PLC or the system or could damage the PLC or PLC Units Always heed these precautions e The user program and parameter area data in the CS1 H CS1D CJ1 H CJ1M and CJ2 CPU Units are backed up in the built in flash memory The BKUP indicator will light on the front of the CPU Unit when the backup operation is in progress Do not turn OFF the power supply to the CPU Unit while the BKUP indicator is lit The data will not be backed up if power is turned OFF e When using a CS series CS1 CPU Unit for the first time install the CS1W BAT01 Battery provided with the Unit and clear all memory areas from a Programming Device before starting to program Not required for CS1 H CJ1 CJ1 H CJ1M or CS1D CPU Units e When u
299. sses the content of the com mand A FINS command must begin with a 2 byte command code If there is also text it is added after the command code Command for Reading I O Memory Memory area area Beginning read read Number of of eee e e ewe ew ew ew ew lee ew ewe ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew ew eH eH I Command code The following data would read 10 words from D00010 01 01 Hex oroime sens oo oa cover 00 OA 00 Hex 000A Hex Hex e e e e e eee e _ lee ee eee eee eee ew a Le ee ew ew ew ew ew ew ew ew ew ew ew ew eB Sl ee ee ee ee ee d Command Memory area First read Number of code code address read elements E eee Parameters Response Format As shown below the response format basically consists of the command code four digits hexadecimal end code and parameters text Command code End code See note Text Various kinds of data ere aceae The length depends on the command code y Note The end code is a 2 byte code that shows the command execution result The first byte shows the general category and the second byte shows the detailed results Example Response from Reading I O Memory 01 01 Hex or orner erat moasona Read data e e ewe ew ew we lee ew ew ew ew ew ew eM ew ew eM eM MW i O l au eee eB ee ew ew ew ew ew ew ee Command code En
300. st or salts e Locations subject to exposure to water oil or chemicals e Locations subject to shock or vibration Take appropriate and sufficient countermeasures when installing systems in the following locations e Locations subject to static electricity or other forms of noise e Locations subject to strong electromagnetic fields e Locations subject to possible exposure to radioactivity e Locations close to power supplies The operating environment of the PLC System can have a large effect on the longevity and reliability of the system Improper operating environments can lead to malfunction failure and other unforeseeable problems with the PLC System Be sure that the operating environment is within the specified condi tions at installation and remains within the specified conditions during the life of the system Application Precautions 5 5 Application Precautions Observe the following precautions when using the PLC System e You must use the CX Programmer programming software that runs on Windows if you need to program more than one task A Programming Console can be used to program only one cyclic task plus interrupt tasks A Programming Console can however be used to edit multitask pro grams originally created with the CX Programmer N WARNING Always heed these precautions Failure to abide by the following precautions could lead to serious or possibly fatal injury e Always connect to a ground of 100 Q or le
301. stant Area Classification Response The constant or I O memory area classification is returned in ASCII to this parameter SV Word Address Response The constant SV or the word address in which it is stored is returned to this parameter Timers T2048 to T4095 and counters C2048 to C4095 cannot be read The SV of the first timer counter found after the designated program address will be read If the SV is outside of range for the timer counter type or number an end code of 16 command not supported will be returned If the SV is a DM or EM indirect address only indirect BCD designations will be read and an end code of 16 command not supported will be returned if the indirect designation is not BCD SV can be read only from cyclic task 0 End Codes 126 An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the program address is not specified in BCD or if the timer counter type or number is out of range including hexadecimal data An end code of 16 command not supported will be returned if the specified instruction does not exist in the program o Normalcompletion S C mode Command Details Section 4 3 4 3 20 TIMER COUNTER SV CHANGE 1 W Changes the SV of the designated timer counter instruction to a new constant SV Command Format
302. t Link FINS command OMRON PLC CS CJ Series ere CVM1 CV Series CX Program mer or other Ss art i application Ne_command munications using CX Via serial network Unit Board FINS command oncaeid using Host Link Server or or CPU bus RS 232C or RS 422A 485 E To other network CPU Unit CMND 490 System Configuration Patterns Access from CX Programmer Sending Internal FINS Messages The Board Unit converts the FINS messages to Host Link FINS for sending in this operation Access from Serially Connected CX Programmer Serial to Serial Routing tables to treat serial communications path as network Serial Communications Unit Board Personal computers e g CX Optional g E Programmer connected seri O 7 ally via tool bus or Host Link CPU Unit cree ot port to the PLC master can access a PLC slave that is connected ink header EINS Termin serially to the PLC master via Host Link RS 422A 485 Host Link Used as Host Link Master CS Cu series or CVM1 CV series PLC Host Link Slave Use the following method to access the serially serial to serial connected PLC from the CX Programmer 74 Serial Gateway Overview Section 3 6 System Configuration Example CX Programmer Ver 5 0 or later Serial Communications Board Unit with unit Ver 1 2 or later Select SCU Unit 0 to 15 in the UNIT field Set the relay PLC Select in the Change PLC Dialog Box
303. t any time to confirm actual specifications of purchased products DIMENSIONS AND WEIGHTS Dimensions and weights are nominal and are not to be used for manufacturing purposes even when tolerances are shown PERFORMANCE DATA Performance data given in this manual is provided as a guide for the user in determining suitability and does not constitute a warranty It may represent the result of OMRON s test conditions and the users must correlate it to actual application requirements Actual performance is subject to the OMRON Warranty and Limitations of Liability ERRORS AND OMISSIONS The information in this manual has been carefully checked and is believed to be accurate however no responsibility is assumed for clerical typographical or proofreading errors or omissions XIV PRECAUTIONS This section provides general precautions for using the CS CJ series Programmable Controllers PLCs and related devices The information contained in this section is important for the safe and reliable application of Programmable Controllers You must read this section and understand the information contained before attempting to set up or operate a PLC system 1 intended Adine e eiieeii neire anr a a raa ean xvi 2 General PrecaullOns coe enne ete he a ar Oaa haa Sa caw eaa xvi 3 Sale by PrecaulONS aese iran tee eee ae en ea ween eee oes xvi 4 Operating Environment Precautions n nnna anaana anenee xviii 5 Application Precautions essan T
304. t begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 7 3 End Codes for information on end codes Comments The file will not be copied if there is already a file of the same name at the destination The file will not be copied if an existing file name is given at the copy destina tion The copy destination file is given the same date as the copy source file 5 3 38 FILE NAME CHANGE 22 08 Changes a registered file name Access right at UM read DIP switch UM write Network write other device protection protection protection Oo NO KOK Execution Conditions RUN mode MONITOR mode PROGRAM mode OK OK 219 FINS Commands Section 5 3 Command Format 12 bytes 22 08 12 bytes Command Disk No Old file name New filename Directory Absolute directory code length path Response Format 22 08 Command End code code Parameters Disk number command The classification of the file memory where the file name to be changed is reg istered is specified as follows 8000 hex Memory card 8001 hex EM file memory Old and new file names command Specify the original file name and a new name for the file For details on the configuration r
305. ter is being transmitted from the port In this case the command transmis sion to the host computer is postponed until the response transmission is completed 2 When a response is not required from the host computer the Communica tions Port Enabled Flag will turn ON when the command to the host computer has passed from the CPU Unit to the port FINS Commands with Host Link Protocol Section 3 5 Response Wait Time Response Required Host computer Serial Communications Board Unit 1 Response wait time 2 1 Communications Port Enabled Flag 0 Command acknowledged t mnd completed No Response Required Host computer Serial Communications Board Unit 1 1 Response wait time 2 1 Communications Port Enabled Flag Command acknowledged Command completed When response wait time has been set in the command format from the host computer commands to the host computer will not be transmitted until the response time has elapsed 1 Transmission of responses to commands from the host computer will be postponed until the command transmission to the host computer has been completed When a response is not required from the host computer the Communica tions Port Enabled Flag will turn ON when the command to the host computer has passed from the CPU Unit to the port 6l FINS Commands with Host Link Protocol Section 3 5 3 5 10 Programming Example 0000 A202 0128 00 04 02 011 KK KEEP 0tz800 1 0128 01
306. ter system and programming to ensure safety in the overall system even if communications errors or malfunctions occur in data link communications or remote I O communications Confirm safety before transferring data files stored in the file memory Mem ory Card or EM file memory to the I O area CIO of the CPU Unit using a peripheral tool Otherwise the devices connected to the output unit may mal function regardless of the operation mode of the CPU Unit Execute online edit only after confirming that no adverse effects will be caused by extending the cycle time Otherwise the input signals may not be readable The CS1 H CJ1 H CJ1M CS1D or CJ2 CPU Unit automatically backs up the user program and parameter data to flash memory when these are written to the CPU Unit I O memory including the DM EM and HR Areas however is not written to flash memory The DM EM and HR Areas can be held during power interruptions with a battery If there is a battery error the contents of these areas may not be accurate after a power interruption If the contents of the DM EM and HR Areas are used to control external outputs prevent inap propriate outputs from being made whenever the Battery Error Flag A402 04 is ON xvii Operating Environment Precautions 4 4 xviii Caution Caution Caution Caution Confirm safety at the destination node before transferring a program PLC Setup I O tables I O memory contents o
307. ter than that set in the Number of Bytes of Response Data is returned the response data will be stored and the remaining area will stay at its previ ous values Control Word Settings The setting range for each item is shown on the following table Number of bytes of com 0002 to 021E 2 to 542 bytes mand data Number of bytes of 0002 to 021E 2 to 542 bytes response data Serial port number 00 CPU Unit Inner Board CPU Bus Unit 01 Port 1 02 Port 2 Destination network 00 Local network address 01 to 7F Network address 1 to 127 Destination node address 00 Internal communications in PLC 01 to FE Node address of Ethernet Unit with model number ending in ETN21 1 to 254 01 to 7E Node address of Ethernet Unit with other model number 1 to 126 01 to 3E Node address 1 to 62 for Controller Link er unit address 10 to 1F M abbelaareiacsiemenanabpasiabcaaall Communications Unit unit address 0 to a setting O a 1 Not required Communications port 0 to 7 0 to 7 number Number of retries 0 to F 0 to 15 Response monitor time 0000 Default 2 s 0001 to FFFF 0 1 to 6 553 5 s unit 0 1 s Note To execute CMND 490 normally programming needs to be written to process the command received by the host computer and return the proper response 3 5 6 Command Format Received by the Host Computer FINS commands sent to the host computer are received at the host computer in the format shown b
308. the CPU Unit can or cannot receive commands when it is in RUN MONITOR or PROGRAM mode when another device has the access right when command protection is in effect and when the DIP switch is protected Access Right at Other The Access right at other device column tells whether the CPU Unit can or Device cannot receive a command when another device has the access right to the CPU Unit Note The access right is the exclusive right of access to a particular device the CPU Unit in this case which prevents interruption by another device i e another Peripheral Device or Unit when multiple commands are executed When another device has the access right the local device cannot execute commands marked by a No in the Access right at other device column Conversely other devices cannot execute this command when the local device has the access right UM Read Protection The UM read protection column tells whether the CPU Unit can or cannot receive the command when UM user memory is protected from a Peripheral Device DIP Switch UM write The DIP switch UM protection column tells whether the CPU Unit can or can Protection not receive a command when UM is write protected by turning ON pin 1 of the DIP switch on the CPU Unit s front panel Network Write Protection The Validate FINS Write Protection via Network parameter in the PLC Setup can be used to set whether the CPU Unit will accept or reject network com mands 5 3 2 MEMO
309. the SV is a DM or EM indirect address only indirect BCD designations will be read and an end code of 16 command not supported will be returned if the indirect designation is not BCD The SV can be changed only in cyclic task 0 The maximum EM bank number that can be specified is 12 OC Hex Execution Conditions 7 Commands Responses PiCmoas Umwea Single Multiple Single Multiple RUN MON PROG Write protected Read protected x No OK No No x x No _ No End Codes An end code of 14 format error will be returned if the length of the command is incorrect An end code of 15 entry number data error will be returned if the program address is not BCD or if the timer counter type or number is out of range including hexadecimal data An end code of 15 entry number data error will be returned if a constant or area classification is out of range including hexadecimal data An end code of 16 command not supported will be returned if the specified instruction does not exist in the UM Area o oman SSCS FOS error 132 C mode Command Details Section 4 3 4 3 23 STATUS READ MS Reads the operating conditions status of the CPU Unit Command Format x10 x10 M S x J 7 Unit No BCD Header FCS Terminator code Response Format rT x10 x10 M S x 16 x 16 x 16 x 16 x 16 x 16 x E N Noo
310. the access right is forcibly acquired by this command the device losing the access right is not notified 5 3 26 ACCESS RIGHT RELEASE 0C 03 Execution Conditions Command Format Response Format Parameters Comments Releases the access right regardless of what device holds it Access right at UM read DIP switch UM Network write ae one oe write ies a RUN mode MONITOR mode PROGRAM mode OC 03 FF FF Command Program code No 0C 03 Command End code code Program number command Always FFFF hex End code response Refer to 5 7 3 End Codes for information on end codes The access right can be released by this command even when the access right is held by another device In that case a normal end code will be returned A normal end code will also be returned if this command is used when the access right is already released 205 FINS Commands Section 5 3 5 3 27 ERROR CLEAR 21 01 Execution Conditions Command Format Response Format Parameters 206 Clears errors or error messages Access right at UM read DIP switch UM write Network write other device protection protection protection No ox O oo O ooo RUN mode MONITOR mode PROGRAM mode OK OK 21 01 Command Error reset code FAL No 21 01 Command End code code Error code to reset command The code of the error to be
311. the command that was received will be returned SNA Source Network Address SA1 Source Node Address SA2 Source Unit Address The same contents specified for DNA DA1 and DA2 in the command that was received will be returned SID Source ID The SID that was specified in the command that was received will be returned Command Code The command code that was specified in the command that was received will be returned The length of the response cannot exceed 1 115 characters Create responses so that the response data without the response code is less than 1 076 characters 538 bytes 57 FINS Commands with Host Link Protocol Section 3 5 3 5 8 Flags for Network Communications This section describes the flags in the Auxiliary Area that are used when exe cuting SEND 090 RECV 098 and CMND 490 Communications Port A Communications Port Enabled Flag turns ON when SEND 090 Enabled Flags RECV 098 and CMND 490 can be executed The Flag will turn OFF during execution of these commands and turn ON again when the command execu tion is completed When creating the ladder diagram use these Flags as input conditions when executing these instructions Were BR O tent SSS A202 Network Communications Automatic Allocation Enabled Flag 09 to 14 Reserved Mo S 08 Communications Port Enabled Flag PortNo 6 00 Communications Port Enabled Flag Pot No0 Communications Port A Communications Port Error Flag will
312. the contents of the CPU Unit s user accessing program at the machine language object level WP PROGRAM WRITE Writes into the CPU Unit s user program area the machine language object sent from the host computer FINS Commands Section 1 3 Type Header code I O table creation MI I O TABLE CREATE Creates an I O table with the contents of the actual I O configuration I O memory area QQMR REGISTER I O MEMORY Registers the I O memory words or bits that are to be registration and read reading QQR READ I O MEMORY Reads the registered I O memory words bits all at once Host Link commu XZ ABORT command only Aborts the operation being performed by a Host Link com nications mand and then returns to the initial status prOcese ing INITIALIZE command only Initializes the transfer control procedures for all Host Link Units IC Undefined command This is the response when the command header code response only cannot be decoded 1 3 FINS Commands The following table lists the FINS commands For details refer to SECTION 5 FINS Commands Type Command aR SR I O memory area ae eo AREA READ Reads the contents of consecutive I O mem access ory area words MEMORY AREA WRITE See Writes the contents of consecutive I O mem note ory area words 01 03 MEMORY AREA FILL See note Writes the same data to the specified range of I O memory area words 01 04 MULTIPLE MEMORY AREA READ Reads the contents of specified non con
313. there are network relays Set 80 ASCII 38 30 when sending an FINS command to a CPU Unit on a network Set 00 ASCII 30 30 when sending to a CPU Unit connected directly to the host computer RSV Reserved Set 00 ASCII 30 30 Setting RSV is required only when sending to a CPU Unit on a network GCT Gateway Count This is the number of networks through which the transmission can be relayed Set 07 ASCII 30 37 Setting GCT is required only when sending to a CPU Unit on a network DNA DA1 DA2 Set the destination network node and unit addresses DNA Destination Network Address Set between 00 and 7F Hex 0 and 127 decimal Setting DNA is required only when sending to a CPU Unit on a network DA1 Destination Node Address Set within the following ranges Setting DA1 is required only when sending to a CPU Unit on a network Ethernet Units with model numbers ending in ETN21 01 to FE hex 1 to 254 Ethernet Units with other model numbers 01 to 7E hex 1 to 126 Controller Link Unit 01 to 20 hex 1 to 32 decimal SYSMAC NET 01 to 7E hex 1 to 126 decimal SYSMAC LINK 01 to 3E hex 1 to 62 decimal DA2 Destination Unit Address Refer to 3 4 2 Addresses in FINS Commands for details on unit addresses In Host Link mode it is assumed that the destination unit is the CPU Unit so set 00 ASCII 30 30 SNA Source Network Address SA1 Source Node Address Set the source network and node addr
314. tions Unit CPU Unit 80 hex 128 decimal A Calculated from unit number 0 port 1 Serial communications R Host Link FINS 1 Network address To serial communications path network address A Target PLC 2 Node address Unit numbers for Host Link 0 to 31 1 m CPU Unit 3 Unit address E g 00 hex for CPU Unit Serial to Serial Conversion Without Routing Tables 80 Routing tables to enable the serial communications path to be treated as a network are optional Specify the addresses as shown in the following example Address Specification Address Contents Example l Remote network 1 Serial communica 80 hex 128 decimal address tions path unit address Calculated from Unit No 0 port 1 s 1 CPU Unit 00 hex 2 Unit No for Host Link incremented by 1 3 Actual remote unit ad dress for FINS command Remote node address Remote unit address Serial communications path Host Link FINS Serial Communications Unit Board E g Unit number 0 port 1 PLC No routing tables required to treat serial communications path as a network z Unit Serial communications 1 Network address path Host Link FINS To serial communications path unit address e g 80 hex Target PLC a 2 Node address Unit numbers for Host Link 0 to 31 1 CPU Unit 3 Unit address E g 00 hex for CPU Unit Serial Gateway Overview Section 3
315. to be transferred or compared For details on the configuration refer to page 168 Directory length command Indicates the length of the absolute directory path The maximum number of characters is 65 To specify the root directory as the absolute directory path specify 0000 hex as the directory length 223 FINS Commands Section 5 3 Absolute directory path command Indicates the absolute path from the root directory It begins with 5C hex and the drive name and colon are not required is used to delimit the lower directory It is not required at the end of the final absolute path No set ting is required to specify the root directory itself End code response Refer to 5 7 3 End Codes for information on end codes Comments The clock data upon completion of a parameter area to file memory transfer will be recorded as the date of the file that has been transferred A file can be transferred to the I O table only when the CPU Unit is in PRO GRAM mode This command cannot be executed if any other device holds the access right Files cannot be overwritten when transferring data from the parameter area to file memory 5 3 41 PROGRAM AREA FILE TRANSFER 22 0C Compares or transfers data between the program area and the file memory Execution Conditions Access right at UM read DIP switch UM write Network write other device protection protection protection No OK_ No SeeNotet No RUN mode
316. to read is 0 00 Nowmalcomplefion SSS Entry number data error Frame length error Not executable due to CPU Unit CPU error 112 C mode Command Details Section 4 3 4 3 9 EM AREA READ RE Reads the contents of the specified number of EM words E00000 to E09999 starting from the specified word in the specified EM bank Command Format x10 x 10 R E Bank No x 10 x 107 x 107 x 10 x 10 x 10 x 10 x 10 x J Unit No BCD Header Bank No Beginning word No of words FCS Terminator code See note 0000 to 9999 0001 to 9999 Note Input 00 01 or OC to specify bank number 0 1 or C Input two spaces to specify the current bank Response Format x10 x10 R E x 16 x 16 x 16 x16 x 16 x 16 x d re Unit No BCD a End code Read data 1 word FCS Terminator code Read data for number of words read Limitations A single bank of EM consists of E00000 to E32767 but the range that can be read by this command is E00000 to E09999 The maximum EM bank number that can be specified is 12 OC Hex The text portion of the response s first frame can contain up to 30 words If more than 30 words are read the data will be returned in multiple frames In the second and later frames the text portion of the response can contain up to 31 words This command cannot be used to ch
317. tomatically for serial communications Serial Gateway Overview Section 3 6 3 6 5 Converting from FINS to Modbus ASClI Modbus ASCIIl Slave compatible devices connected serially to a PLC via Modbus ASCIl can be accessed from the PLC using Modbus ASCIIl com mands enclosed in FINS messages e Sent FINS message FINS header FINS command code 2805 hex Modbus ASCIl command e Message after conversion Modbus ASCIl command FINS message CPU Unit Modbus ASCIl command Modbus CMND 490 Serial Com ASCII Slave DS UENEN Modbus ASCII command encapsulated WarBeard RS 232C or RS 422A 485 Cevige using FINS command 2805 hex Via network or CPU bus System Configuration Patterns Sending FINS Messages Using CMND 490 in CPU Unit s Ladder Program The Board Unit converts the FINS messages to Modbus ASCll protocol for sending in this operation Access from CPU Unit on the Same PLC CPU Bus to Serial Routing tables to treat serial communications path as network Serial Communications Unit Board Slaves connected serially to the Serial Optional CHIND 490 Communications Board Unit using Mod bus ASCII can be accessed from a CPU To Nai Unit in the same PLC conversi ion FINS header 2805 Modbus ASCII Dm Modbus ASCII Slave device Slaves connected serially to the Serial Optional Communications Board Unit using Mod bus ASCII can be accessed from a CPU Unit in a PLC on the network Network Ethernet
318. torque specified in the relevant manuals Incorrect tightening torque may result in malfunction Be sure that all the mounting screws terminal screws and cable connec tor screws are tightened to the torque specified in the relevant manuals Incorrect tightening torque may result in malfunction Leave the label attached to the Unit when wiring Removing the label may result in malfunction if foreign matter enters the Unit Remove the label after the completion of wiring to ensure proper heat dis sipation Leaving the label attached may result in malfunction Use crimp terminals for wiring Do not connect bare stranded wires directly to terminals Connection of bare stranded wires may result in burning Follow the instructions in this manual to correctly perform wiring Double check all wiring and switch settings before turning ON the power supply Incorrect wiring may result in burning Mount terminal blocks and connectors only after checking the mounting location carefully Be sure that the terminal blocks connectors Memory Cards Option Boards expansion cables and other items with locking devices are prop erly locked into place Improper locking may result in malfunction Check switch settings the contents of the DM Area and other prepara tions before starting operation Starting operation without the proper set tings or data may result in an unexpected operation Check the user program for proper execution before actua
319. ts elements SYSWAY 269 words 267 words Ethernet 999 words 996 words Controller Link 999 words 996 words SYSMAC LINK 269 words 267 words DeviceNet 269 words 267 words If more than one network is passed through to read or write data the value for the network with the smallest limit will apply Volume labels are names registered in file memory File names consist of 12 bytes as shown below Be sure to follow this configuration when designating a file name by means of command parameters 8 bytes 1 byte 3 bytes Volume label file name directory name Extension Delimiter Start the file name and extension in the most significant bytes respectively and then fill in any unused bytes with 20 hex If the file name or extension in response data is less than 8 or 3 bytes respec tively unused bytes will be filled with 20 hex It is not permissible to specify 00 hex or E5 hex at the beginning of a file name Codes of 00 hex or E5 hex means erased in DOS It is also not per Designating Command Parameters Section 5 2 missible to specify 7E hex at the first and second characters consecutive of a file name If a file name has no extension fill both the period 2E hex and the extension with 20 hex lf the file name in response data has no extension both the period 2E hex and the extension will be filled with 20 hex 169 FINS Commands Section 5 3 5 3 FINS Commands 5 3 1 About this Section This section descr
320. ttings correct the parameters Data link table There is an error in the file Check the contents of the file file 157 Command Lists Section 5 1 Check point Probable cause 20 Read not possible 21 Write not possible 158 02 Protected The program area is pro Release protection from a Program tected ming Device and then execute the command 03 Table miss Table A table has not been regis Register a table ing tered There is an error in the table the table 04 Data The search data does not missing exist 05 Program Program num A non existing program ee the program numbers and missing ber in command number has been specified specify a valid one data 06 File missing File name and The file does not exist at the Check the path and file name and file device specified file device correct them 07 Data Contents of A data being compared is not Check memory contents and use mismatch memory being the same the correct data compared A file read operation failed Check the contents of the file If the area is protected using a switch setting release protection and then execute the commana If the area is permanently read only 01 Read only The specified area is read only the command cannot be executed 02 Protected Tooo program area is Release protection from a pied Programming Device and then execute the command PLC Setup Writing is not
321. ugh to 07 hex when sending a FINS command Otherwise set the GCT to 02 hex see note when sending When receiving a FINS response GCT is decremented one for each bridge network that is passed through and the resulting value is received This value is for system use do not access it For a CS CuJ series CPU Unit with unit version 2 0 or later CP series CPU Unit or NSJ Controller CX Programmer version 4 0 or higher can be used to set rout ing tables that start the GCT at 07 hex For a CS CJU series CPU Unit with unit version 3 0 or later CX Programmer CX Net Ver 5 0 or higher can be used to set routing tables that start the GCT at either 07 Hex or 02 Hex For details refer to 1 4 2 Communications through a Maximum of 8 Network Levels in the CS Series PLC Operation Manual or the CJ Series PLC Operation Manual DNA Destination network address Specify within the following ranges hex 00 Local network 01 to 7F Remote network address decimal 1 to 127 DA1 Destination node address Specify within the following ranges hex 00 Internal communications in local PLC 01 to 20 Node address in Controller Link Network 1 to 32 decimal 01 to FE Ethernet 1 to 254 decimal for Ethernet Units with model numbers ending in ETN21 FF Broadcast transmission DA2 Destination unit address Specify within the following ranges hex 00 CPU Unit FE Controller Link Unit or Ethernet Unit connected to network 10 to 1F CPU Bus Unit E1
322. ult in death or serious injury Additionally there may be severe property damage N WARNING Indicates a potentially hazardous situation which if not avoided could result in death or serious injury Additionally there may be severe property damage N Caution Indicates a potentially hazardous situation which if not avoided may result in minor or moderate injury or property damage OMRON Product References All OMRON products are capitalized in this manual The word Unit is also capitalized when it refers to an OMRON product regardless of whether or not it appears in the proper name of the product The abbreviation Ch which appears in some displays and on some OMRON products often means word and is abbreviated Wd in documentation in this sense The abbreviation PLC means Programmable Controller PC is used how ever in some Programming Device displays to mean Programmable Control ler Visual Aids The following headings appear in the left column of the manual to help you locate different types of information Note Indicates information of particular interest for efficient and convenient opera tion of the product 1 2 3 1 Indicates lists of one sort or another such as procedures checklists etc OMRON 1999 All rights reserved No part of this publication may be reproduced stored in a retrieval system or transmitted in any form or by any means mechanical electronic ph
323. uncuncces Controller Link network address 5 Sending a Command from a Host Computer to PLC A The following addresses are specified to the CPU Unit at network address 5 node address 3 Destination network address DNA 05 30 35 Destination node address DA1 03 30 33 Destination unit address DA2 00 30 30 Command addressed to CPU Unit Sending a Command from a Host Computer to PLC B The following addresses are specified to the CPU Unit at network address 10 node address 12 Destination network address DNA OA 30 41 Destination node address DA1 OC 30 43 Destination unit address DA2 00 30 30 Command addressed to CPU Unit 3 5 4 Sending FINS Commands to the Host Computer from the CPU Unit With normal Host Link communications FINS commands are sent from the host computer to the CPU Unit Commands can also be sent however from the CPU Unit to the host computer Any FINS command can be sent to the host computer using SEND 090 which sends CPU Unit data to the host computer RECV 098 which receives data from the host computer or CMND 490 Slave initiated communications allows the host computer to be notified unso licited communications when an error is generated for example on a produc tion line controlled by a CPU Unit Since the host computer no longer needs to regularly communicate with the CPU Unit the load on the host computer is reduced When an Ethernet Unit or Controller Link
324. unications Host Link They can be issued from a CPU Unit Special I O Unit or host computer and they can also be sent to any of these The specific commands that can be sent depend on the destination This manual explains commands sent to CS CJ CP series CPU Units and NSJ Controllers when the commands are issued from a CPU Unit or a host computer connected by Host Link When the source of the commands is a CPU Unit the FINS commands are sent by means of CMND 490 SEND 090 RECV 098 When the source is a host computer the FINS commands are issued using Host Link protocol 1 2 C mode Commands The following table lists the C mode Host Link commands For details refer to SECTION 4 C mode Commands Type Header code I O memory ClO AREA READ Reads the specified number of words beginning with the reading designated ClO word LR AREA READ Reads the specified number of words beginning with the designated LR word RH HR AREA READ Reads the specified number of words beginning with the designated HR word RC TIMER COUNTER PV READ Reads the specified number of words of the timer counter PV beginning with the designated word RG TIMER COUNTER STATUS Reads the specified number of words of the timer counter READ status beginning with the designated word DM AREA READ Reads the specified number of words beginning with the designated DM word RJ AR AREA READ Reads the specified number of words beginning with the designated AR word RE
325. upported by Pre Ver 1 2 Serial Communica tions Boards and Units A host computer program cannot be used if it was developed for a 1 1 Host Link Using a Serial Communications Board or Unit with Version Number 1 2 or Later 20 The Serial Communications Boards and Units with version number 1 2 or later can be set to operate in 1 1 Host Link mode so a host computer program developed for a 1 1 Host Link with C series PLCs C200H C1000H and C2000H can be reused in a CS CJ Series Host Link The 1 1 Host Link for Precautions when Reusing Programs from Earlier Models Section 2 4 mat can be selected with the 1 N format 1 1 format setting in the allocated DM Area settings Host link Applicable PLC models format 1 N format With this Host Link C Series Only the 1 N Host Link format is sup format the connec SRM1 built in ports ported by the built in ports on CPU tion configuration CPM1 built Units of CS CJ C200HS C200HX HG host PLC can be ullt in ports HE CPM and CQM10 PLCs as well either 1 1 or 1 N CPM1A built in ports as the ports on Host Link Units and Earlier versions of CQM1 CPULI built in ports Serial Communications Boards these Boards Units C 209HS CPULIL built in ports supported only the Ban 1 N format C200HX HG HE CPULIL built in ports C200HW COML IL Communications Board ports CS CJ Series CJ2H CPUL IL EIP built in ports CJ2M CPU1L built in ports CJ2M CPU3L Serial Option Board CS1G H CPULILJ
326. verted to file memory 1 EM used Bits 0 to 14 Bits 0 to 7 2nd byte Current bank number Bits 8 to 15 1st byte Designating Command Parameters Section 5 2 5 2 2 I O Memory Address Designations Data type Length Memory Memory area Memory Memory Memory area Memory Per on address address address address Men CIO CIO Bit A 000000 000000 to ete 000000 000000 to 1 Area 17FFOF O9FBOF O 614315 a 255515 Work WR ia to 000000 to Area ia 01FFOF ee H00000 to 000000 to ee Area H51115 01FFOF Auxiliary o A00000 to 000000 to Pf to a to Bit Area A44715 read 01BFOF A44715 read OCBFOF only only fer ona to 01 paseo to fear ona to pesror A95915 read OSBFOF A95915 read OEBFOF fer ona fear ona fos Bit with ee 000000 niall to 40 000000 nail to Area eo ie sta 17FFOF O9FBOF eo les ee 614315 n 255515 W00000 to 000000 to Area W51115 01FFOF Holding HR H00000 to 000000 to Bit Area H51115 01FFOF CIO CIO Word CIO 0000 to 000000 to CIO 0000 to 000000 to 2 Area CIO 6143 17FF00 CIO 2555 O9FBOO Work WR B1 W000 to 000000 to Area W511 01FFOO Holding HR HO00 to H511 000000 to Bit Area 01FF00 Auxiliary AR A000 to A447 000000 to a to A447 0B0000 to Bit Area read only 01BF00 read only OCBFOO A448 to A959 01C000 to A448 to A959 OCCOO0O0 to read write 03BF00 read write OEBFOO CIO CIO Word with FO CIO 0000 to 000000 to CO 000000 000000 to
327. ween the I O See note memory area and the file device PARAMETER AREA FILE TRANS Transfers or compares data between the FER See note parameter area and the file device PROGRAM AREA FILE TRANS Transfers or compares data between the UM FER See note User Memory area and the file device DIRECTORY CREATE DELETE Creates or deletes a directory See note MEMORY CASSETTE TRANS Transfers and verifies data between a Mem FER CP1H CP1L CPU Units only ory Cassette and the CPU Unit FORCED SET RESET See note Force sets or force resets bits or releases force set status FORCED SET RESET CANCEL Cancels all bits that have been force set or See note force reset Note These commands will not be accepted and an end code of 2102 hex cannot write due to protection will be returned if the Write Protection from FINS Commands Sent to CPU Units via Networks option is selected in the PLC Setup for a CS CJ series CPU Unit with unit version 2 0 or later for a CP series CPU Unit or for an NSJ Controller s il Z 22 22 22 22 22 22 22 22 22 22 22 22 23 3 Debugging 2 FINS Commands Section 1 3 SECTION 2 Overview of C mode Commands This section provides an overview of C mode Host Link commands 2 1 C Mode Commands 2 1 505024 350 d0aeobidoadsdeedicdveied deketes 2 2 Command Response Formats 000 eee ee eens 2 3 Application Examples 2 062 5a 03 ss 25 b eae oe owed oo SEES 14
328. wing information for CP1E PLCs e CPU Unit operation e Internal memory e Programming e Settings e CPU Unit built in functions e Interrupts e High speed counter inputs e Pulse outputs e Serial communications e Other functions SYSMAC CP Series CP1E CPU Unit Instructions Reference Manual CP1E E L CP1E NL L SYSMAC CXONE ALUUC VU ALULD VU CX One Version 4 0 FA Integrated Tool Package Setup Manual SYSMAC CXONE ALULIC VLI CKONE ALLILID VLJ CS CJ CP NSJ Series CX Integrator Operation Manual SYSMAC WS02 CXLILI VU CX Programmer Operation Manual SYSMAC CX Programmer WS02 CXLILI VU Operation Manual Function Blocks Structured Text SYSMAC WS02 CXLILI VU CX Programmer Operation Manual SFC Cat No W483 Describes each programming instruction in detail W463 Provides an overview of the CX One FA Inte grated Tool Package and CX One installation pro cedures W464 Describes setting and monitoring networks W447 W469 W446 Describes operating procedures for the CX Pro grammer Support Software running on a Win dows computer Describes specifications and procedures required to use function blocks structured text Describes specifications and procedures required to use SFC programming functions Section 1 introduces the C mode commands and FINS commands and explains the relationship between them Section 2 provides an overview of C mode commands Section 3
329. xecute the ERROR CLEAR command Check Units Boards and cables to be sure they are connected cor rectly and then execute the ERROR CLEAR command Check the I O tables and correct the allocations A memory error has occurred For internal memory write the cor in internal memory a mem ory card or EM file memory rect data and then execute the com mand For a memory card or EM file mem ory the file data has been destroyed Execute the FILE MEM ORY FORMAT command If the problem persists replace the memory PT Terminators have not been _ Set the terminators correctly set Command Lists Check point Probable cause Command The specified area is not An attempt was made to clear protection for protected protection on an area that is not 26 Command error 30 Access right error 40 Abort 01 No protec tion Section 5 1 program area protected i e there is no reason to clear protection 02 Incorrect An incorrect password has Specify the correct password password been specified 04 Protected The specified area is Clear protection from a protected Programming Device and then execute the command 05 Service already executing Number of com The node receiving the Wait for current processing to end mands being command is already process or force the end of a current executed ing 5 commands process and then execute the command The service is being Wait for the
330. xecuting a Smart Active Part that is connected seri ally which automatically sends an internal FINS command Serial Communications Unit Board CPU Unit NS series PT Smart Active Parts FINS message sent internally conversion comman OO Note When the NS series PT is con 72 nected serially to the PLC using serial communications mode 1 N NT Links and the NS series PT sends FINS com mands encapsulated in NT Link commands using Smart Active Parts the CPU Unit removes the NT Link header etc from the received command converting it to a FINS command and trans fers the command to the Serial Communications Board Unit The Serial Communications Board Unit uses the Serial Gate way to convert the command into the specified protocol This oper ation enables serially connected devices to access the Serial Communications Board Unit from Smart Active Parts using an NS series PT Note Optional 1 The FINS header contains the following information e Remote destination network address DNA Same as for CompoWay F e Remote destination node address DA1 Same as for CompoWay F e Remote unit address DA2 Same as for CompoWay F 2 The contents of the Modbus RTU command enclosed in the FINS mes sage that is sent is as follows Slave address binary FUNCTION code binary Communications data binary Start and CRC End are not required when sending FINS They are ada ed au
Download Pdf Manuals
Related Search
Related Contents
argumentaire-du-maire-2001 Display Panel Manual - Pages - default 環境管理物質管理標準 O&O Mediarecovery V4 Benutzerhandbuch Cooper Lighting Metalux T5 User's Manual Benoît Capt - Association Lied & Mélodie High Speed Counter Module Type A1SD61 User`s Manual (Hardware) 14ページ:お知らせ[PDFファイル/2326KB] Copyright © All rights reserved.
Failed to retrieve file