background image

 

 

4. Modbus communication 

 

4.1 Overview 

 Function that supports Modbus protocol. Modbus protocol specifications have been globally 

disclosed; Modbus protocol is one of the most common types of communication protocol. 

 Modbus protocol does not support messages autonomously output by the IJ Printer such as 

status or printing contents. 

 
 

4.2 Transmission procedure 

 
 
 
 
 
 
 
 
 

No. Name  Size 

Setting 

range 

Description 

1 Transaction 

identifier 

2 bytes  0x0000 to 

0xFFFF 

The IJ Printer returns the transaction 
identifier received from external unit as it is. 
You should use the identifier to manage 
messages for external unit. 

2  Protocol identifier 

2 bytes 

0x0000  Sets protocol identifier. Set protocol identifier 

to 0x0000. The IJ Printer returns the protocol 
identifier received from external unit as it is. 

3  Data length 

 

2 bytes  0x0000 to 

0x00FF 

Sets number of bytes for request data and 
response data. 

4  Data 

3 to 255 

bytes 

Because message format differs according 
to the function code specified, data size is 
variable refer to 4.3 Message format for 
details. 

 
 

4.3 Message format 

 

(1) Function code 

The IJ Printer supports the function code given in the following table. 

 

Function code 

No. 

Function 

code 

Function 

0x10 

Write Multiple Registers 

0x06 

Write Single Register 

0x03 

Read Holding Registers 

0x04 

Read Input Registers 

 
 

Transaction 

identifier 

External unit 

IJ Printer 

Protocol 

identifier 

Data length 

Data 

Transaction 

identifier

 

Protocol 

identifier 

Data length 

Data 

Request message 

configuration 

Response message 

configuration 

Summary of Contents for UX Twin Nozzle

Page 1: ...nication Modbus function For other features of the printer please refer to Instruction manual or Technical manual If the printer is improperly handled or maintained it may not operate smoothly and may become defective or cause an accident It is therefore essential that you read this manual to gain a complete understanding of the printer and use it correctly After thoroughly reading the manual prop...

Page 2: ...tion test 6 3 1 Procedure for connection test 6 4 Modbus communication 9 4 1 Overview 9 4 2 Transmission procedure 9 4 3 Message format 9 4 4 Data configuration 15 4 5 Detail of Data configuration 37 4 6 Modbus communication rule for IJ Printer 39 4 7 Examples of Transmission procedure 40 5 Troubleshooting guide 45 Ethernet is a registered trademark of Xerox Corporation USA Windows is registered t...

Page 3: ...ecause Modbus protocol is one type of protocol commonly used by industrial equipment if Modbus communication is employed for other unit you can create a communications program for the external unit using this asset When the communication program is newly developed its development schedule will be shortened with use of IJP control library 2 Configuration diagram Standard specifications Item Specifi...

Page 4: ...with a provider you should obtain a fixed IP address from the provider 2 If using a telephone line a contract for service such as ADSL is required If not using a telephone line a mobile environment is required You also need a router that supports a mobile card 3 Set the network settings as instructed by the provider s manual 2 2 IJ Printer preparations No Work Remarks 1 Connect the IJ Printer to t...

Page 5: ...3 2 3 LAN cable connection I O section with cover removed Connect the LAN cable ...

Page 6: ...o MAC address Displays IJ Printer s MAC address Example communication environment setup screen 2 5 Usage precautions 1 Functions listed below are not operational during the use of this function List of functions which are not operational during the use of this function 2 Functions listed below are not supported by this function List of functions which are not supported by this function No Screen I...

Page 7: ...twork address segment of the IP address is determined by calculating the logical AND of the IP address and subnet mask Default gateway The default gateway is equipment such as a router that functions as the gateway to the network When there is communication between different networks and there is no unique path for the equipment to be accessed the default gateway is used to connect them Port numbe...

Page 8: ...ctly connect the IJ Printer to the PC with a LAN cable 2 Set the network settings of external unit by steps 2 to 5 Click the Start menu and double click Control Panel View network status and tasks Change adapter settings Local Area Connection The following window is then displayed 3 Click Properties Example using Windows 7 OS ...

Page 9: ...rsion 4 TCP IPv4 5 Select Use the following IP address and enter an IP address other than 192 168 0 1 and 192 168 0 255 the example shown in the figure uses 192 168 0 15 and then enter 255 255 255 0 in the Subnet mask field Click OK ...

Page 10: ...time 24ms in four consecutive lines 1 then external unit settings are completed 1 In default the ping command returns the response for four times For details of the ping command type the following command ping help If Destination host unreachable response is returned for the ping command it means communication has not been established between the IJ Printer and external unit Re check the following...

Page 11: ...identifier Set protocol identifier to 0x0000 The IJ Printer returns the protocol identifier received from external unit as it is 3 Data length 2 bytes 0x0000 to 0x00FF Sets number of bytes for request data and response data 4 Data 3 to 255 bytes Because message format differs according to the function code specified data size is variable refer to 4 3 Message format for details 4 3 Message format 1...

Page 12: ...e into Nozzle 1 0x02 Write into Nozzle 2 0x03 Error response 3 0x01 Write into Nozzle 1 0x02 Write into Nozzle 2 0x03 Write into both Nozzle 1 and Nozzle 2 Operation when a data is read Color of address Device address Description 1 0x01 Read from device 0x02 Read from device 0x03 Read from device 2 0x01 Read from Nozzle 1 0x02 Read from Nozzle 2 0x03 Error response 3 0x01 Read from Nozzle 1 0x02 R...

Page 13: ...ltiple Registers 3 Start address 2 bytes 0x0000 to 0xFFFF Sets writing start address Address is set in word units 4 No of words to be written 2 bytes 1 to 123 Sets number of words to be written 5 No of bytes to be written 1 byte 1 to 246 Sets number of bytes to be written 6 Data to be written 2 to 246 bytes 0x0000 to 0xFFFF Sets data to be written variable length of 2 to 246 bytes 0x00 is added to...

Page 14: ... bytes 0x0000 to 0xFFFF Sets data to be written Response message data configuration normal No Name Size Range Description 1 Device address 1 byte 0x01 to 0x03 Sets device address received as it is 2 Function code 1 byte 0x06 Sets function code received as it is 3 Writing address 2 bytes 0x0000 to 0xFFFF Sets writing address received as it is 4 Data to be written 2 bytes 0x0000 to 0xFFFF Sets data ...

Page 15: ...start address Address is set in word units 4 No of words to be read 2 bytes 1 to 125 Sets number of words to be read Response message data configuration normal No Name Size Range Description 1 Device address 1 byte 0x01 to 0x03 Sets device address received as it is 2 Function code 1 byte 0x03 Sets function code received as it is 3 No of bytes to be read 1 byte 2 to 250 Sets number of data bytes to...

Page 16: ...number of words to be read Response message data configuration normal No Name Size Range Description 1 Device address 1 byte 0x01 to 0x03 Sets device address received as it is 2 Function code 1 byte 0x04 Sets function code received as it is 3 No of bytes to be read 1 byte 2 to 250 Sets number of data bytes to be read 4 Data to be read 2 to 250 bytes 0x0000 to 0xFFFF Sets data to be read variable l...

Page 17: ... the number of the printing items used 00 09 Reserve_1 Reserve is not initially provided but may be added in future 00 0F Reserve_7 00 10 Specify Print message registration number 0 to 2000 Set Print message information at Input Register address 0x0E40 which Print message registration number is specified here When 0 is specified the print message information of the print message which is being edi...

Page 18: ...not initially provided but may be added in future 10 05 Reserve_5 10 06 Print data recall Print data message number 1 to 2000 Set the registered print message number to be recalled 10 07 Reserve_1 Reserve is not initially provided but may be added in future 10 0B Reserve_5 10 0C Print data registration Group number 0 to 99 Register the being edited print message by the specified Group number or by...

Page 19: ...nter character space of the print item 1 10 44 Bold 1 to 9 Sets the bold of the print item 1 10 45 Bar code 0 to 26 Sets the bar code of the print item 1 0 none 1 Code 39 2 ITF 3 NW 7 4 EAN 13 5 DM8x32 6 DM16x16 7 DM16x36 8 DM16x48 9 DM18x18 10 DM20x20 11 DM22x22 12 DM24x24 13 Code 128 Code set B 14 Code 128 Code set C 15 UPC A 16 UPC E 17 EAN 8 18 QR21x21 19 QR25x25 20 QR29x29 22 EAN 13add on 5 2...

Page 20: ...rate division factor 1 to 999 Sets the pulse rate division factor 19 A9 Speed compensation 0 1 Sets the speed compensation 0 Disable 1 Enable 19 AA Line speed 0 to 9999 Sets the line speed Set value is multiplied by 1 10 and reflected to IJ Printer Example 1234 123 4 m min 19 AB Distance between print head and work 0 to 99 Sets the distance between print head and work 19 AC Print Target width 0 to...

Page 21: ...itution rules Day 0 1 19 CD Substitution rules Hour 0 1 19 CE Substitution rules Minute 0 1 19 CF Substitution rules No 1 to 99 Sets the substitution rules No of the Calendar block 1 19 D0 Substitution rules Week number 0 1 Sets the substitution rules of the Calendar block 1 19 D1 Zero suppression Week number 0 to 2 Sets the zero suppression of the Calendar block 1 19 D2 Substitution rules Day of ...

Page 22: ...bstitution character Minute 0x0020 to 0xFFFF 1C 1D Substitution character Week number 0x0020 to 0xFFFF 1C BB Substitution character Week number 0x0020 to 0xFFFF 1C BC Substitution character Day of week 0x0020 to 0xFFFF 1C D0 Substitution character Day of week 0x0020 to 0xFFFF 1C D1 Reserve_1 Reserve is not initially provided but may be added in future 1C D3 Reserve_3 1C D4 Time count condition Ran...

Page 23: ... limit of the count block 1 20 07 Range Lower limit 20th digit 0x0020 to 0xFFFF 20 08 Range Upper limit 1st digit 0x0020 to 0xFFFF Sets the range Upper limit of the count block 1 20 1B Range Upper limit 20th digit 0x0020 to 0xFFFF 20 1C Update In progress 0 to 999998 Sets the update In progress of the count block 1 20 1D 20 1E Update Units 1 to 999999 Sets the update Units of the count block 1 20 ...

Page 24: ...ion Count block 8 24 7F 24 80 Adjust print parameters Calendar offset 0 1 Sets the calendar offset 0 Offset from yesterday 1 From today 24 81 DIN print 0 1 Sets the DIN print 0 Disable 1 Enable 24 82 EAN Prefix 0 1 Sets the EAN prefix 0 Edit message 1 Print format 24 83 Barcode printing 0 1 Sets the barcode printing 0 Normal 1 Reverse 24 84 QR Error correction level 0 1 Sets the QR error correctio...

Page 25: ...orientation 0 to 3 Sets the change character orientation 0 Disable 1 Reverse direction printing 2 normal or inverted 3 Character orientation 0 or 3 24 B2 Change mode 0 1 Sets the change mode 0 OFF normal forward 1 OFF inverted reverse 24 B3 Reverse print 0 1 Sets the reverse print 0 right justified 1 left justified 24 B4 Print signal type 0 1 Sets the print signal type 0 print complete 1 print in ...

Page 26: ...dded in future 25 AF Reserve_32 25 B0 Operation management Ink operating time 0 to 9999 Sets the ink operating time 25 B1 Ink alarm time 0 to 9999 Sets the ink alarm time 25 B2 Print count 0 to 999999999 Sets the print count 25 B3 25 B4 Reserve_1 Reserve is not initially provided but may be added in future 25 B7 Reserve_4 25 B8 Circulation control Ink filter use time 0 to 65099 Sets the ink filter...

Page 27: ...r 26 01 Number after the change 1 to 2000 26 02 Reserve_1 Reserve is not initially provided but may be added in future 26 0F Reserve_14 26 10 Manage group Group number 1 to 99 Creates the group of the selected number and name 26 11 Group name 1st digit 0x0020 to 0xFFFF 26 12 Group name 2nd digit 0x0020 to 0xFFFF 26 1B Group name 11th digit 0x0020 to 0xFFFF 26 1C Group name 12th digit 0x0020 to 0xF...

Page 28: ...ets the control status 0 stop 1 start 2C 72 Print count 0 to 99999 Sets the print count 2C 73 2C 74 Reserve_1 Reserve is not initially provided but may be added in future 2C 7F Reserve_12 2C 80 Reserve Reserve_1 Reserve is not initially provided but may be added in future 2C FF Reserve_128 2D 00 User pattern Fixed size User pattern registration 01 0x0000 to 0xFFFF Status of User pattern registrati...

Page 29: ... by the fixed address User pattern data Free size of the registered User pattern character 00 will be set here from 0x6510 to 0x6791 65 11 Horizontal size User pattern character 00 1 to 320 65 12 Pattern data User pattern character 00 0x0000 to 0xFFFF 65 13 Pattern data User pattern character 00 0x0000 to 0xFFFF 67 90 Pattern data User pattern character 00 0x0000 to 0xFFFF 67 91 Pattern data User ...

Page 30: ...r occurred during Modbus communication Refer to 4 5 1 Details of Analysis information for details Analysis information 1 Function code is obtained when error is caused Analysis information 2 Classification code is obtained when error is caused Analysis information 3 Error factor is obtained when error is caused Analysis information 4 0x0000 Fixed 00 05 Analysis information 2 Classification code 0x...

Page 31: ...e 00 51 Ink alarm time 0 to 9999 Gets the ink alarm time 00 52 Print count 0 to 999999999 Gets the print count 00 53 00 54 Cumulative operation time 0 to 999999 Gets the cumulative operation time 00 55 00 56 Ink makeup ink type 1 to 999 Gets the ink makeup ink type 00 57 Ink viscosity 0 to 999 Gets the ink viscosity 00 58 Ink pressure nozzle 1 0 to 999 Gets the ink pressure Ink pressure multiplied...

Page 32: ...00 83 03 3C Fault warning message 90 03 43 03 44 Reserve Reserve_1 Reserve is not initially provided but may be added in future 0A FF Reserve_1980 0B 00 Communicati on environment setup State at power up 0 to 2 Gets the state at power up 0 Comm port is OFF 1 Comm port is ON 2 OFF fixed 0B 01 Communication and signal error 0 1 Gets the communication and signal error 0 Warning 1 Fault 0B 02 Baud rat...

Page 33: ... item for Communication buffer 0 1 Gets the empty buffer fault 0 Disable 1 Enable 0B 16 Timing of Fault Function item for Communication buffer 0 1 Gets the timing of fault 0 Print Start 1 Print Complete 0B 17 Data Number at Fault Function item for Communication buffer 0 to 9 Gets the data number at fault 0B 18 Start output Function item for SOP 04 0 1 Gets the start output 0 Disable 1 Enable 0B 19...

Page 34: ... 0B D7 Heating unit use time 0 to 65099 Gets the heating unit use time 0B D8 MV1 use time 0 to 65099 Gets the MV1 use time 0B D9 MV2 use time 0 to 65099 Gets the MV2 use time 0B DA MV3 use time 0 to 65099 Gets the MV3 use time 0B DB MV4 use time 0 to 65099 Gets the MV4 use time 0B DC MV5 use time 0 to 65099 Gets the MV5 use time 0B DD MV6 use time 0 to 65099 Gets the MV6 use time 0B DE MV7 use tim...

Page 35: ...ime 0B F4 Recovery pump 1 use time 0 to 65099 Gets the recovery pump 1 use time 0B F5 Recovery pump 2 use time 0 to 65099 Gets the recovery pump 2 use time 0B F6 Makeup filter 2 use time 0 to 65099 Gets the makeup filter 2 use time 0B F7 Air filter L use time 0 to 65099 Gets the air filter L use time 0B F8 Air filter R use time 0 to 65099 Gets the air filter R use time 0B F9 Reserve_1 Reserve is n...

Page 36: ...are M 32nd digit 0x0020 to 0xFFFF 0C 80 Print controller software S 1st digit 0x0020 to 0xFFFF Gets the print controller software S version When the version is V01 00 V01 00 Engine software S is obtained 0C 81 Print controller software S 2nd digit 0x0020 to 0xFFFF 0C 9E Print controller software S 31st digit 0x0020 to 0xFFFF 0C 9F Print controller software S 32nd digit 0x0020 to 0xFFFF 0C A0 1st l...

Page 37: ...10 its Group number and Message name are obtained 0E 41 Group number 0 to 99 0E 42 Message name 1st digit 0x0020 to 0xFFFF 0E 4D Message name 12th digit 0x0020 to 0xFFFF 0E 4E Reserve_1 Reserve is not initially provided but may be added in future 0E 52 Reserve_5 0E 53 Print message registration 001 0x0000 to 0xFFFF Status of Print message registration Registered or NOT is obtained by bit informati...

Page 38: ...to 48 Gets the shift code rule count of the current message 0E FE Count block count 0 to 8 Gets the count block count of the current message 0E FF Count characters count Count block 1 0 to 20 Gets the count characters count for 8 blocks of the current message 0F 00 Count characters count Count block 2 0 to 20 0F 05 Count characters count Count block 7 0 to 20 0F 06 Count characters count Count blo...

Page 39: ...sis information 2 Classification code 0x0000 No classification assigned 0x0001 Index 0x0002 Print description 0x0003 Delete of Print contents 0x0004 Print data Recall 0x0005 Print data Register 0x0006 Print format 0x0007 Print specification 0x0008 Calendar conditions 0x0009 Substitution rules 0x000A Time count 0x000B Shift code 0x000C Count conditions 0x000D Various print setup 0x000E Online Offli...

Page 40: ... number show the available number of bytes as pattern data The below mentioned is an example of Holding Registers where User patterns are registered User pattern registration 01 shows 16 status of User pattern registration 000 through 015 starting from the upper bit Subsequently the same data structure as that of User pattern registration 01 will follow The construction rule of User pattern data i...

Page 41: ...r when the writing operation is made on the Registers of which addresses are NOT consecutive When the Start 0x0001 is written on Start Stop control flag the written data is held and there will be NO writing operation onto Holding Registers When the Stop 0x0002 is written on Start Stop control flag all the data held on Holding Registers will be reflected to IJ Printer 5 Character codes are the same...

Page 42: ...bytes to be written 0x02 9 Data to be written 0x0005 No Name Response data 1 Transaction identifier 0x0000 2 Protocol identifier 0x0000 3 Data length 0x0006 4 Data Device address 0x01 5 Function code 0x10 6 Start address 0x1042 7 No of words to be written 0x0001 External unit IJ Printer Holding Register writing request Holding Register writing response 1 Write 7x10 on Character size of Item 1 of N...

Page 43: ...er writing function code 0x10 Request message data of Holding Register writing 0000 0000 0009 01 10 0000 0001 02 0001 Response message data of Holding Register writing 0000 0000 0006 01 10 0000 0001 Hexadecimal notation Holding Register writing request Holding Register writing response 2 Write 6 on Character count of Item 1 of Nozzle 1 by Holding Register writing function code 0x10 Request message...

Page 44: ...e 5 Write DEF456 on Print contents of Item 101 of Nozzle 2 by Holding Register writing function code 0x10 Request message data of Holding Register writing 0000 0000 001F 02 10 0084 000C 18 0000 0044 0000 0045 0000 0046 0000 0036 Response message data of Holding Register writing 0000 0000 0006 02 10 0084 000C Hexadecimal notation Holding Register writing request Holding Register writing response 6 ...

Page 45: ...sponse 2 Write 3 on Character count of Item 101 of Nozzle 2 by Holding Register writing function code 0x10 Request message data of Holding Register writing 0000 0000 0009 02 10 0020 0001 02 0003 Response message data of Holding Register writing 0000 0000 0006 02 10 0020 0001 Hexadecimal notation Holding Register writing request Holding Register writing response 3 Write Year Month and Day of Calend...

Page 46: ... 01 04 0000 0008 Response message data of Input Register reading 0000 0000 0013 01 04 10 0031 0031 0030 0030 0000 0000 0000 0000 Hexadecimal notation Input Register reading request Input Register reading response External unit IJ Printer 1 Select Nozzle 1 and Nozzle 2 respectively and write 50 on Character height by Holding Register writing function code 0x10 Request message data of Holding Regist...

Page 47: ...ent Set IJ Printer to an IP address of the same network segment Is IP address which was set to IJ Printer the duplicate of other device on the network If there is a possibility of the duplicate IP address please disconnect LAN cable and change IP address Is communication blocked by the security software Please temporarily disable Firewall protection of Windows or the security software retry Is IP ...

Reviews: