TOHO ELECTRONICS INC.
Contents 1. Before using the product ......................................................................................................................... 4 1.1 On this operation manual ............................................................................................................. 4 1.2 What can be done with communications ...................................................................................... 4 1.3 Positioning communications (priority ranking)..............................
6 MODBUS communications control ...................................................................................................... 20 6.1 Communications procedure........................................................................................................ 20 6.2 Message types ............................................................................................................................ 20 6.
1. Before using the product 1.1 On this operation manual This is an operation manual regarding communications with a TTX-700 (hereinafter referred to as "this product"). 1.2 What can be done with communications With this product, users can write and read items specified in "10. Table of identifiers," such as "reconfiguring, starting, or stopping items that are operable with the front keys" and "reading information displayable on the display.
2. Settings regarding TOHO communications 2.1 Overview Before communications is performed, initial settings must be made on this product. Enter such settings with the keys on the front panel. To switch to a series of setting screens, take the steps described below. For details, see the operation manual furnished with this product.
2.2 Setting a data length 2.3 Setting a stop bit length 2.4 Setting a parity 2.5 Setting whether to conduct a BCC check While in the "Set a communications parameter" screen on the preceding page, operate the ▲ and ▼ keys to make the settings. ]. The initial value is [ Stop bit 1 Stop bit 2 No parity Odd parity Even parity Data length, 7 bits Data length, 8 bits BCC check disabled BCC check enabled 2.
2.7 Setting an address While in the "Set a communications address" screen on the preceding page, operate the ▲ and ▼ keys to make the settings. The initial value is •. Setting range: 1 to 99 stations (It cannot be set to a 0.) 2.8 Setting a response delay Set a time from the time when the high-level computer finished sending a "request message" until the time when it delivers the line and enters an input state.
3. TOHO communications control 3.1 Communications procedure This product returns a "response message" in response to a "request message" from a high-level computer. It therefore does not initiate a transmission. Transmitted by a highlevel computer High-level computer Transmitted by this product Request message Transmitted by a highlevel computer Request message Request message This product Response delay: 0-250ms See "2.8. Set a response delay." See "3.6.1. Communications timing.
3.3 Composition of a request message (transmitted from a high-level computer to this product) n For codes ① to ⑩, see "3.5. Description of codes." n For specific examples of request messages, see "4.1. Examples of reading communications" and "4.2. Examples of writing communications." 3.3.1 Composition of a read request message BCC ETX □ □ □ R □ □ ⑦ BCC data ⑥ End code | ④ Identifier | ③ Contents of the request: read/write ② Address STX ① Start code 3.3.
3.4 Composition of a response message (transmitted from this product to a high-level computer) n For codes ① through ⑩, see "3.5. Description of codes." n For specific examples of request messages, see "4.1. Examples of communications to be read" and "4.2. Examples of communications to be written." 3.4.1 Response message in response to a read request message BCC ETX □ □ □ □ □ □ □ □ ACK □ □ STX ⑦ BCC data ⑥ End code | | ⑤ Numerical data | | | ④ Identifier | ⑧ Acknowledge code ② Address ① Start code 3.
3.5 Description of codes n The codes from ① STX, ② address to ⑩ ERR as indicated below are expressed in ASCII codes. n For the ASCII codes, see "9. Table of ASCII codes." n For conversion to ASCII codes, see "4. Examples of TOHO communications." ① STX This code is needed for the receiver to detect the top of the message. It is affixed to the top of a character string to be sent. ② Address This is the address of the party (this product) with whom a high-level computer communicates.
⑧ ACK It is an acknowledge code. If a message received by this product is error-free, this code will be incorporated in the "response message" from this product and returned. ⑨ NAK It is a negative acknowledge code. If a "request message" received by this product is error-ridden, this code will be incorporated in the "response message" from this product and returned.
3.6 Communications precautions 3.6.1 Communications timing Set a sufficient response delay to make sure that this product is switched over from transmission to reception with regard to a high-level computer in using an RS-485. See the figure in "3.1. Communications procedure" and "2.8. Setting a response delay." 3.6.
3.6.8 Storing data other than a store request message Store all parameters in the EEPROM in either of the two cases described below, even if no store request message is received. 1) If a parameter is changed by key operation 2) If auto-tuning is started and ends normally. 3.6.
4. Examples of TOHO communications 4.1 Examples of communications to be read Example: Request message: This requests this product set at address 27 to read the PV. (High-level computer) In response to that, Response message: This returns PV data (00777).
4.2 Examples of communications to be written Example: Request message: This requests this product set at address 03 to set "the E1F setting to (High-level computer) 011" (write 011). (This sets the function in event 1 to the deviation upper and lower limits + hold.) In response to that, Response message: This returns a notice that the request message has been received. (This product) *Check that it has been written by reading the data separately.
5. Settings regarding MODBUS communications 5.1 Overview Before communications is performed, initial settings must be made on this product. Enter such settings with the keys on the front panel. To switch to a series of setting screens, take the steps described below. For details, see the operation manual furnished with this product.
5.2 Setting a data length 5.3 Setting a stop bit length 5.4 Setting a parity While in the "Set a communications parameter" screen on the preceding page, operate the ▲ and ▼ keys to make the settings. The initial value is [ ]. Stop bit 1 Stop bit 2 No parity Odd parity Even parity Data length, 7 bits Data length, 8 bits * The ASCII mode settings come only in three types: The RTU mode settings come only in three types: , , , and , and . . 5.
5.6 Setting an address While in the "Set a communications address" screen on the preceding page, operate the ▲ and ▼ keys to make the settings. The initial value is •. Setting range: 1 to 247 stations (It cannot be set to a 0.) 5.7 Setting a response delay Set a time from the time when the high-level computer finished sending a "request message" until the time when it delivers the line and enters an input state.
6. MODBUS communications control 6.1 Communications procedure This product returns a "response message" in response to a "request message" from a high-level computer. It therefore does not initiate a transmission. Transmitted by a highlevel computer High-level computer Transmitted by this product Request message Transmitted by a highlevel computer Request message Request message This product Response delay: 0-250ms See "5.7. Set a response delay." See "6.6.1. Communications timing.
6.3 Composition of an RTU request message (transmitted from a high-level computer to this product) n For codes a) through i), see "6.5. Description of RTU codes." 6.3.1 Composition of a read request message a) Slave address 1BH b) Function code 03H c) Register address d) Number of registers e) CRC-16 High level 00H Low level 00H High level 00H Low level 02H High level C6H Low level 31H First register address 2 to 100 (even number only) 6.3.
6.3.
Single a) Slave address 03H b) Function code 06H c) Register address g) e) Data for the first register (a low-level word) CRC-16 High level 00H Low level C0H High level 00H Low level 6FH High level C4H Low level 5AH First register address 6.4.3 Response message in the case of an error a) Slave address 1BH b) Function code 83H h) Error code 02H e) CRC-16 High level E1H Low level 36H ← In the case of an error, the function code for the request message + 80H is entered. 6.
e) CRC-16 This error check code is for detecting message errors. This transmits a CRC-16 (tour redundancy code). The multinomial for generating a CRC-16 used in this product is X16+X15+X2+1. To learn how to calculate the CRC-16, see "6.7. Example of CRC-16 calculations." To affix an error code at the end of the message, affix the low-level byte first, then the high-level byte of the CRC. f) Number of data This specifies the number of registers to be read and written x 2.
6.6 Precautions on RTU communications 6.6.1 Communications timing Set a sufficient response delay to make sure that this product is switched over from transmission to reception with regard to a high-level computer in using an RS-485. See the figure in "5.1. Overview" and "5.7. Setting a response delay." 3.6.2 Interval between requests In transmitting a series of "request messages" from a high-level computer, allow for an interval of 1msec or more or 3.
6.6.8 Changing the settings (SV or SV2) by communications during auto-tuning Even if the settings (SV or SV2) used in control for auto-tuning are changed by communications, the changes (SV or SV2) will not be changed until the auto-tuning ends. 6.7 Example of CRC-16 calculations Following is an example of calculating CRC-16 with VisualBasic6.0. Variables are declared as shown below. VisualBasic6.0 cannot use code-free variables. It therefore uses code-equipped 16-bit integer variables as data.
6.8 Composition of an ASCII request message (transmitted from a high-level computer to this product) n For the codes a) through g), see "6.10. Description of ASCII codes." 6.8.
6.8.
6.9.2 Response message for a write/store request message a) Start code b) Slave address “0” , “3” c) Function code “1” , “0” d) Register address e) Number of registers “:” High level “0” , “0” Low level “0” , “0” High level “0” , “0” Low level “0” , “2” f) LRC “E” , “B” g) End code CR, LF First register address Fixed at 2 6.9.
6.10 Description of ASCII codes n The codes from a) start code to b) slave address to j) error type described below are expressed in ASCII codes. n For ASCII codes, see "9. Table of ASCII codes." n For converting to ASCII codes, see 6.8 and 6.9 "Message composition." a) Start code The receiver side is the code required for detecting the top of the message. It is affixed to the top of a character string to be transmitted.
i) Data portion This specifies data to be written in the register. The data is fixed at 4 bytes. This product will write data without the decimal point. Example: In the case of numerical data Example Significance of the value Proportional band (P) = 1.0 % 0000000AH PV = 1200.0°C 00002EE0H SV = -10.00°C FFFFFC18H In the case of text data, write the ASCII code "□INP" (□ is a space): 2049E50H.
6.11 Precautions on ASCII communications 6.11.1 Communications timing Set a sufficient response delay to make sure that this product is switched over from transmission to reception with regard to a high-level computer in using an RS-485. See the figure in "5.1. Overview" and "5.7. Setting a response delay." 6.11.2 Interval between requests In transmitting a series of "request messages" from a high-level computer, allow for an interval of 1msec or more or 3.
6.11.8 6.12 Changing the settings (SV or SV2) by communications during auto-tuning Even if the settings (SV or SV2) used in control for auto-tuning are changed by communications, the changes (SV or SV2) will not be changed until the auto-tuning ends. Example of LRC calculations Following is an example of calculating LRC with VisualBasic6.0. Variables are declared as shown below. VisualBasic6.0 cannot use code-free variables. It therefore uses code-equipped 16-bit integer variables as data.
7. Specifications 7.1 Communications standard category: Compliant with EIA standard RS-485 7.2 Communications specifications 7.2.1 Communications system Network: ................................... For RS-485, multi-drop system (up to 1 pair, 31 stations) Direction of information: .......... Half duplex Synchronization system: ........... Asynchronous Transmission code: ................... ASCII, 7/8 bit code, except for BBC data (highest-level bit = 0 in 8-bit code) 7.2.2 Interface system Signal line: ....
8. Connections 8.1 Connections for the RS-485 High-level computer (parent station) This product (mobile unit) T/R(A) T/R(A) T/R(B) T/R(B) T/R(A) T/R(B) T/R(A) T/R(B) Communications is such that the connections can be made with the connectors on the sides. Install an end of line resistor at both of the farthest devices in the parent station and the mobile unit. For a resistance value, use one that matches the characteristic impedance of the cable. Provided that the synthesis is set to at least 75Ω.
9.
10. Table of identifiers (codes) MODBUS ADR LowHighlevel W level W Operation mode Identifier Character Name 40000 40001 PV1 Measurement 40002 40003 SV1 Control setting MODBUS ADR LowHighlevel W level W 40004 40005 40006 40007 40008 40009 40010 40011 Use it as a monitor for measurements (PV).
MODBUS ADR Lowlevel W Highlevel W Event setting mode Identifier Character Name R/W 40072 40073 E1F Set an event output function 40074 40075 E1H Set an event output upper limit R/W 40076 40077 E1L Set an event output lower limit R/W 40078 40079 E1C Set an event output sensitivity R/W 40080 40081 E1T Set an event output delay timer R/W 40082 40083 E1B Set an event output special function R/W 40084 40085 E1P Set an event output polarity R/W 40086 40087 CM1 CT monitor 40088
MODBUS ADR Lowlevel W 40122 Highlevel W Screen-less commands Identifier Character 40123 TST Name R/W Timer start stop Description R/W 40124 40125 OM1 Output monitor R R of the output monito ①②③④⑤ ⑤:Control output (1:ON 0:OFF) ④:Cooling output (1:ON 0:OFF) ③:Event output (1:ON 0:OFF) 40126 40127 EM1 DI monitor R R of DI monitor ①②③④⑤ ⑤:DI (1: ON 40128 40129 □AT Start/release AT 40130 40131 STR Store data MODBUS ADR Lowlevel W Highlevel W 0: OFF) Read/write AT start/release Start
TOHO ELECTRONICS INC. Head office: 1-13-21, Tanashioda, Sagamihara Kanagawa 229-1125 Japan.