ETC II Modbus Communications Protocol Reference Guide SATEC Ltd. BG0595 Rev. A1 Every effort has been made to ensure that the material herein is complete and accurate. However, the manufacturer is not responsible for any mistakes in printing or faulty instructions contained in this book. Notification of any errors or misprints will be received with appreciation. For further information regarding a particular installation, operation or maintenance of equipment, contact the manufacturer or your local representative or distributor. Modbus is a trademark of Modicon, Inc. 2 Table of Contents 1 GENERAL .......................................................................................... 5 2 MODBUS PROTOCOL IMPLEMENTATION...................................... 6 2.1 2.2 2.3 2.4 2.5 2.6 2.7 Transmission Modes ....................................................................................... 6 Address Field .................................................................................................. 6 Function Field ................................................................................................. 6 Exception Responses ..................................................................................... 6 Modbus Register Addresses .......................................................................... 6 Data Formats .................................................................................................. 7 Password Protection ....................................................................................... 7 3 DATA SERVER .................................................................................. 8 3.1 3.2 Data Server Features ..................................................................................... 8 Using Real-time Data Exchanges ................................................................... 9 3.2.1 Configuring Real-time Data Exchanges ...................................................................... 9 3.2.2 Accessing Real-time Data Exchanges ........................................................................ 9 3.2.3 Accessing Data Log Files ......................................................................................... 10 3.3 Using Status Event Exchanges and Event Logs .......................................... 11 3.3.1 Configuring Event Exchanges................................................................................... 11 3.3.2 Accessing the Event Log File.................................................................................... 11 3.4 Using Data Write Exchanges ........................................................................ 12 4 MODBUS REGISTER MAP .............................................................. 13 4.1 Data Server Registers .................................................................................. 13 Real-time Data Exchange Block ..................................................................... 13 Data Write Exchange Block ............................................................................ 13 Data Log Transfer Blocks ............................................................................... 13 Event Log Transfer Blocks .............................................................................. 14 4.2 Device Control and Status Registers ............................................................ 14 Device Mode Control Registers (factory set) .................................................. 14 Device Diagnostics Register (bit map) ........................................................... 14 Device Authorization Register ........................................................................ 15 Factory Diagnostic Registers .......................................................................... 15 4.3 Device Setup Registers ................................................................................ 15 Factory Device Settings and Identification ..................................................... 15 Device Options Setup ..................................................................................... 15 Time/Date Setup ............................................................................................. 16 Clock Setup and Status .................................................................................. 16 Modem Setup.................................................................................................. 16 Communication Ports Setup ........................................................................... 17 Network Setup ................................................................................................ 17 Dial-up/GPRS Modem Setup (future) ............................................................. 18 Password Setup .............................................................................................. 18 Expert Power Service Setup ........................................................................... 18 Internet Service Provider (ISP) Accounts ....................................................... 18 SNTP Client Setup (future) ............................................................................. 18 Data Server Setup .......................................................................................... 19 Gateway Setup ............................................................................................... 19 Device Routing Table ..................................................................................... 20 Routing IP Table ............................................................................................. 20 3 5 DATA FORMATS ............................................................................. 22 Timestamp ...................................................................................................... 22 Event Type ID ................................................................................................. 22 Event Data ...................................................................................................... 22 Device Diagnostics (bitmap) ........................................................................... 22 Shared Access Rules ..................................................................................... 23 4 1 General This document specifies a subset of the Modbus serial communications protocol used to transfer data between a master computer station and the ETC II. The document provides the complete information necessary to develop third-party communications software capable of communication with the ETC II. Additional information concerning communications operation, configuring the communications parameters, and communications connections is found in "ETC II Installation and Operation Manual". IMPORTANT Most of the advanced features are configured using multiple setup parameters that can be accessed in a number of contiguous registers. When writing the setup registers, it is recommended to write all the registers at once using a single request. 5 2 Modbus Protocol Implementation For detailed information about Modbus protocol, Modbus message framing and error checking, refer to the "Modicon Modbus Protocol Reference Guide". It can be downloaded from the Modicon's Web site at www.modicon.com. The following paragraphs outline some issues concerning the implementation of the Modbus protocol in the ETC II. 2.1 Transmission Modes The ETC II can be set up to communicate on a Modbus network using ASCII or RTU transmission mode. Refer to the "ETC II Installation and Operation Manual" on how to select the transmission mode in your device. 2.2 Address Field The address field contains a user assigned address of the instrument (1-247) on a Modbus network. Broadcast mode using address 0 is not supported. 2.3 Function Field The Modbus functions implemented in the ETC II are shown in Table 2-1. Function 04 can be used in the same context as function 03. Table 2-1 Modbus Function Codes Code (decimal) 03 04 06 16 081 1The Meaning in Modbus Read holding registers Read input registers Preset single register Preset multiple registers Loop-back test Action Read multiple registers Read multiple registers Write single register Write multiple registers Communications test ETC II supports only diagnostic code 0 - return query data. 2.4 Exception Responses The instrument sends an exception response when an error is detected in the received message. To indicate that the response is notification of an error, the high order bit of the function code is set to 1. Implemented exception response codes: 1 2 3 10 - Illegal function Illegal data address Illegal data value Gateway is busy. Remote access is temporarily unavailable. When the character framing, parity, or redundancy check detects a communication error, processing of the master's request stops. The instrument will not act on or respond to the message. 2.5 Modbus Register Addresses The ETC II Modbus registers are numbered in the range of 0 to 65535. From the Modbus applications, the ETC II Modbus registers can be accessed by simulating holding registers of the Modicon 584, 884 or 984 Programmable Controller, using a 5-digit “4XXXX” or 6-digit “4XXXXX” addressing scheme. To map the ETC II register address to the range of the Modbus holding registers, add a value of 40001 to the ETC II register address. When a register address exceeds 9999, use a 6digit addressing scheme by adding 400001 to the ETC II register address. 6 2.6 Data Formats The ETC II uses two data formats to pass data between a master application and the device: 16-bit short integer and 32-bit long integer formats. Data logged by the ETC II Data Server is collected from instruments in 16-bit short integer format. 2.7 Password Protection The ETC II has a password protection option allowing you to protect your setups and logs from being changed or cleared through communications. You can disable or enable password protection through communications or via the Terminal. For details, refer to the ETC II “Installation and Operation Manual”. When password protection is enabled, the user password you set in the ETC II should be written into the device authorization register (44378-44379) before another write request is issued. If the correct password is not supplied while password protection is enabled, the ETC II will respond to all write requests with the exception code 01 (illegal operation). It is recommended to clear the password register after you have completed your changes in order to activate password protection. 7 3 Data Server 3.1 Data Server Features The Data server allows the user to save the time required for polling multiple devices, especially via slow serial interfaces, by utilizing the ETC II non-volatile memory for automatic acquiring data. The user application can then read blocks of ready data directly from the ETC II memory without the need to wait until slow devices respond to master requests. The Data server can also perform a delayed write of data so the application needs not to wait until the device would be accessible, but rather can write data to the ETC II memory exchanges, and then the ETC II takes responsibility for delivering data to the target devices. The Data server can also periodically poll device status registers and record events to a log file or give alerts on specific events. The following table lists the configurable Data server options. Table 3-1 Data Server Options Description Data server enabled Continuous polling Data polling interval Data logging interval, polls Range 1=enabled, 0=disabled 1=enabled, 0=disabled 1-1000 min 0-1000, 0=logging disabled When the Data server is enabled, it acquires data from the connected devices either continuously, or on a periodic basis. If continuous polling is disabled, the devices are requested periodically at predefined poll intervals. If continuous polling is enabled, the ETC II retrieves data from the devices in turn without pauses. Acquired real-time data is normally stored in the ETC II exchanges (memory blocks) and is periodically refreshed at programmed intervals. The ETC II provides up to 250 real-time data exchanges of 1 to 114 registers long. These exchanges can be directly accessed by the master application. If the user wishes, acquired data can be periodically moved to historical circular files where it will be kept for a long time until it is overwritten by newer data. Data is stored to historical files at regular intervals. The logging interval is always represented as a whole number of data polling intervals even if the polling itself is not synchronized with polling intervals like in the event of continuous polling. Since the ETC II tries to synchronize polling devices with the beginning of an hour, it is recommended to program a logging interval in such a manner that it would be a whole divisor of 60 minutes. Historical records can be accessed one record at a time either in an arbitrary order, or in a sequential manner. The ETC II also provides up to 250 write data exchanges, of 1 to 12 registers long, and up to 250 status event data exchanges of 1 register long. Table 3-2 gives a summary of the available data exchanges. Table 3-2 Data Server Exchanges Exchange Type Real-time data exchange Status event exchange Data write exchange Number of Exchanges 250 250 250 Exchange Block Size, registers 1-114 1 1-12 NOTE: The real-time, status event and write data exchanges with the same exchange number are internally linked in the ETC II to the same device ID. If you change the device ID for one of the exchanges, the same ID will be taken for other configured exchanges that have the same exchange number. 8 3.2 Using Real-time Data Exchanges 3.2.1 Configuring Real-time Data Exchanges Real-time data exchanges are used for periodic retrieving data from the connected devices. The following table shows the parameters that should be configured before enabling a data exchange. Table 3-3 Real-time Data Exchange Setup Description Exchange number Start device register address Exchange block size, registers Device ID Polling enabled RTC update enabled (optional) Range 0-249 0-65535 1-114 1-247 1=enabled, 0=disabled 1=enabled, 0=disabled A data exchange can store from 1 to 114 contiguous 16-bit registers retrieved from a single device. A block of registers for an exchange is defined by the start register address and the exchange block size. Refer to Modbus guides for specific devices for available address ranges. You can individually enable or disable polling data for a specific exchange. If the device has an onboard real-time clock, you can enable periodic RTC updates from the ETC II clock. Each data exchange utilizes 6 extra registers for time stamping and identification as shown in Table 3-4, so the actual memory required for one data exchange is 6 + exchange block size. The total size of all exchanges should not exceed 9000 registers. Table 3-4 Data Exchange Record Description Range Record heading Record status 0=no data, -1=corrupted record, 1-65534 = device response code Record time, seconds since 1/1/1970 Record sequence number Data block (variable size) Data registers (up to 114) 0- 65535 If data logging is globally enabled in the Data server, the retrieved data is periodically moved from the data exchange to a log file in the same format, as it is stored in the exchange (see Table 3-4). Each exchange is provided with a separate data log file. A data record is always preceded by a status register that indicates whether the data is healthy. Each record may be identified in a file by a unique 16-bit sequence number that is incremented modulo 65536 with each new record. 3.2.2 Accessing Real-time Data Exchanges Real-time data exchanges occupy a single continuous block of registers without gaps and are located in the ETC II memory in the address range of 0 to 9000. Since exchanges may have different size, the location of each exchange in the memory depends on the size of all preceding exchanges. Use the following formula to define the location of the data exchange: N 1 ExchangeN Address (Exchangen Block Size 6) n0 Note that a location of the exchange in the memory is changed when you change the data exchange setup, so the previously acquired data would be lost. 9 3.2.3 Accessing Data Log Files Each data exchange is provided with a separate circular data log file. The Data server allocates a total of 1.5 Mbytes of non-volatile memory for all data log files, which will be equally divided between all active exchanges. File transfers are performed through two blocks of registers: a master request block and a read-only file transfer block, which are shared by all files. After a master application has written the request with a file exchange number (and possibly a file position) into the file request block, the requested data is available for a read through the file transfer block registers. File transfer functions allow changing the file position in order to point to the desired record in a selected log file. The sequence number of the first (oldest) record available in a file may be inspected via the file request block after the file exchange number is written into the block. The file transfer block occupies 120 registers in the address range of 9000 to 9119. The following table shows a layout of the data log request block. Refer to Table 3-3 for the file transfer block layout. Table 3-5 Data Log Request Block Description Function Record sequence number (with functions 3, 11) First (oldest) record sequence number Exchange number Range 3 = set file position 5 = reset file position 11 = read record 0-65535 0-65535 0-249 Data log files can be read either in a sequence record-by-record, or in a random order. Every write to the file request block fills the file transfer block with the data of the record pointed to by the file read pointer. If you want to begin reading a file from a particular record, which sequence number is known, you can change the pointer position by issuing the Set-File-Position request with the desired sequence number. If you want to read a file from the beginning, write the Reset-File-Position request that moves the pointer to the oldest file record. If you use the Read-Record request that does not change the file position, then you will continue reading the file from the record following the one you have read the last time you accessed the file. You need not explicitly move the file position to the following record if you want to continue reading a file in sequence after you have uploaded the current record. Instead, continue reading the record data through the file transfer block: each access to the file transfer block automatically advances the file pointer to the next record. That’s why you should read all data in the file transfer block by a single request: the next read will give you the following file record. The file transfer is completed after you have read the last record of the file. Before storing a file record to your database, always check the record status word. This word set to 0 indicates that the file read pointer does not point to any record within the file, and you should not store any record that has this word set to 0 or to -1. The following gives a summary of steps you should perform to read a data log file: 1) If you want to begin reading a file from a particular record or from the first record, use either the Set-File-Position request with the desired record sequence number, or the Reset-FilePosition request; otherwise use the Read-Record request. 2) Read the record data from the file transfer block. The file pointer will be moved to the next file record. 3) Repeat step 2 until all the file records are read, i.e., until the record status word indicates the end-of-file. 10 3.3 Using Status Event Exchanges and Event Logs 3.3.1 Configuring Event Exchanges The Data server can provide recording binary events asserted by the connected devices and give a notification to the eXpertPower server. The Data server can periodically poll device status registers and detect a change in the status bits to recognize asserted device events. A binary event mask specifies the critical event bits. Whenever the Data server detects a change in the status bits selected by the event mask, it records an event record to the circular Event log file. If the eXpertPower service is enabled in the ETC II, this event will initiate a connection to the eXpertPower server. Polling status events is performed via the status event exchanges. The Data server provides up to 250 event exchanges, each one of 1 register long, with a separate event mask. Table 3-6 shows the setup parameters that are used for configuring status event exchanges. Table 3-6 Status Event Exchange Setup Description Exchange number Device status register address Event mask Device ID Polling enabled Options flags: Bit 0 – Auto reset enabled (1=enabled, 0=disabled) Bit 1 – Register type: 0=coils (Modbus request type 1) 1=holding register (Modbus request type 3) Range 0-249 0-65535 0x00000000–0x0000FFFF 1-247 1=enabled, 0=disabled The Data server supports the auto reset option you can use to clear a latched device status register after it has been read. In most devices, critical events are latched into a status register, so the new events are not generated until the register is explicitly cleared by a master application. Since status registers may be implemented in the device either as coils, or as holding registers, you should specify a register type for each event exchange via the option flags. 3.3.2 Accessing the Event Log File All event records are stored in a single circular event log file. Along with device status events, the file may contain the ETC II self-diagnostic events. File transfers are performed through two blocks of registers: a master request block and a read-only file transfer block. The file transfer block occupies 12 registers in the address range of 10000-10011. Tables 3-7 and 3-8 show a layout of the event log request block and a layout of the event log record. Table 3-7 Event Log Request Block Description Function Record sequence number (with functions 3, 11) Range 3 = set file position 5 = reset file position 11 = read record 0-65535 Table 3-8 Event Log Record Layout Description Event Log status Event sequence number Event type ID Device ID Event time, seconds since 1/1/1970 Event data Range 0 = no new events, 1 = have new events, -1 = record corrupted 0-65535 F2 (See Section 5) 0-247 F1 (See Section 5) F3 (See Section 5) 11 The event log file is accessed in the same manner as data log files. Refer to Section 3.2.3 for details. 3.4 Using Data Write Exchanges The Data server can provide remote writing data to serviced devices upon user requests. Up to 250 write exchanges are supported with a size of 1 to 12 registers. Table 3-9 shows configuration parameters that can be defined for each write exchange. Table 3-9 Write Exchange Setup Description Exchange number Start device register address Exchange block size, registers Device ID Write enabled Range 0-249 0-65535 1-12 1-247 1=enabled, 0=disabled Configured data exchanges are accessed via the data write exchange block. It occupies 14 registers in the address range of 9200 to 9213. Table 3-10 shows the write exchange layout. Table 3-10 Write Exchange Block Description Exchange number Write flag Range 0-249 0 – Data has been written 1 – Data is waiting to be written Data register 1 ... Data register 12 To send data to a device via a write exchange, write data to the write exchange block with the write flag being set to 1. The write flag is automatically cleared after the data has been successfully transferred to the device. Always check this flag before writing new data to the exchange to ensure it is empty, otherwise previously written data may be lost. 12 4 Modbus Register Map 4.1 Data Server Registers Address Point ID Description Real-time Data Exchange Block 0-9000 Data Exchange #1 … … Data Exchange #N Exchange Layout (120 registers maximum): +0,1 Record status +2,3 +4,5 +6 Record time, seconds since 1/1/1970 Record sequence number Data register ... +119 Data register Data Write Exchange Block 9200-9213 +0 Exchange number +1 Write flag +2 Data register ... Data register +13 Data Log Transfer Blocks 9120-9135 File Request Block +0 Function +1 +2-12 +13 +14 +15 9000-9119 Record sequence number (with functions 3, 11) Reserved First (oldest) record sequence number Next sequence number to be used Data exchange number Options/Range Type R/W Notes UINT32 R Device response: function code or exception code (See 2.3-2.4) UINT32 UINT32 UINT16 R R R 0-65535 UINT16 R 0-249 0 – Data has been written 1 – Data is waiting to be written 0-65535 UINT16 UINT16 R/W R/W UINT16 R/W 0-65535 UINT16 R/W 3 = set file position 5 = reset file position 11 = read file UINT16 R/W 0-65535 UINT16 R/W 0-249 UINT16 UINT16 UINT16 R R R/W 0=No data, -1=corrupted record, 1-65534 = device response code F1 0-65535 0-65535 Units sec Defines accessed exchange number 3 - changes the file position 5 - sets the file position at the first (oldest) record 11 - opens the file for reading from the present file position The record sequence number with function 11 does not change the file position Write – sets new exchange number Read – returns exchange number File Transfer Block 13 Address Point ID +0,1 Description Record status +2,3 +4,5 +6 Record time, seconds since 1/1/1970 Record sequence number Data register ... +119 Data register Event Log Transfer Blocks 10016-10031 File Request Block +0 Function +1 +2-12 +13 +14 +15 10000-10009 +0,1 +2,3 +4,5 +6,7 +8,9 +10,11 Record sequence number (with functions 3, 11) Reserved First (oldest) record sequence number Next sequence number to be used Reserved File Transfer Block Event log status Event sequence number Event type ID Device ID Event time, seconds since 1/1/1970 Event data Options/Range 0= No new data, -1=corrupted record, 1-65534 – device response code F1 0-65535 0-65535 Units Type UINT32 R/W R sec UINT32 UINT32 UINT16 R R R 0-65535 UINT16 R 3 = set file position 5 = reset file position 11 = read file UINT16 R/W 0-65535 UINT16 R/W UINT16 UINT16 R R UINT32 R UINT32 UINT32 UINT32 UINT32 UINT32 R R R R R 0 - no new events, 1 – data is valid, -1 – current record corrupted 0-65535 F2 0-247 F1 sec F3 Notes Device response: function code or exception code (See 2.3-2.4) 3 - changes the file position 5 - sets the file position at the first (oldest) record 11 - opens the file for reading from the present file position The record sequence number with function 11 does not change the file position 4.2 Device Control and Status Registers Address Point ID Description Device Mode Control Registers (factory set) 44134 ETC options 44135 Modem 44136-44165 Reserved 44166-44326 Reserved Device Diagnostics Register (bit map) 44326-44327 Device self-diagnostics flags. 14 Options/Range Units Type R/W Notes Bit0 = 1 - COM5 enabled Bit1 = 1 - IP-LINK enabled 0 = disabled, 1 = enabled UINT16 R The secondary master port may be either COM5, or IP-LINK enabled UINT16 UINT16 UINT16 R F4 UINT32 R/W Address Point ID Description When read: 0 = no faults logged, 1 = a fault bit has been set at least once since the last reset. When written: 0 = clear a fault bit, 1 = no effect. 44328-44341 Reserved Device Authorization Register 44378-44379 When write: 8-digit password. When read: 0 = access permitted, -1 = authorization required. 44380-44385 Reserved 44386-45951 Reserved Factory Diagnostic Registers 45952-46079 Factory diagnostic registers Options/Range Units Type R/W INT32 R/W UINT32 R Type R/W UINT32 UINT32 CHAR16 UINT16 UINT16 UINT16 R R R R R R UINT16 UINT16 UINT16 UINT16 R R R R 0x0500 0x00F0 0x0000-0xFFFF UINT16 UINT16 UINT16 R R R Bit 0 = Bit 2 = Bit 3 = Bit 4 = Bit 5 = Bit 6 = 0-200 0-24 UINT16 R/W 0 - 99999999 (write) 0/-1 (read) Notes 4.3 Device Setup Registers Address Point ID Description Factory Device Settings and Identification 46080-46207 +0, 1 Device serial number +2, 3 Device model ID +4-11 Device model name +12-19 Reserved +20 Device firmware version number +21 Device firmware build number +22,23 Reserved +24 Boot loader version number +25 Boot loader build number +26 RF firmware version number +27 RF firmware build number +28-95 Reserved +96 Ethernet MAC address 0-1 +97 Ethernet MAC address 2-3 +98 Ethernet MAC address 4-5 +99-128 Reserved Device Options Setup 46256-46271 +0 Log output +1 +2 Number of XP faults for reset Global reset timer (in hours) Options/Range 2014 “ETC II” Dumping to console, Server Log XP log IPLINK log Data Server log Sharing log Units Notes Null-terminated string 0 – never (50 - default) 0 – never (24 - default) 15 Address Point ID +3-15 Time/Date Setup 46400-46415 +0 Description Reserved Options/Range Local time offset, min 0-+/-720 +1 Daylight savings time (DST) option +2 +3 DST start month DST start week of the month +4 +5 +6 DST start weekday DST end month DST end week of the month +7 +8 DST end weekday Clock synchronization source (future) 0 = DST disabled (standard time only), 1 = DST enabled 1 - 12 1 - 4 = 1st, 2nd, 3rd and 4th week, 5 = the last week of the month 1-7 (1= Sun, 7 = Sat) 1 - 12 1 - 4 = 1st, 2nd, 3rd and 4th week, 5 = the last week of the month 1-7 (1= Sun, 7 = Sat) 0xfffe = SNTP, 0xffff = none +9-15 Clock Setup and Status 46416-46447 +0, 1 +2, 3 +4 +5 +6 +7 +8 +9 +10 +11 +12 Reserved +13-31 Modem Setup 46448-46479 +0,1 +2,3 +4,5 +6,7 +8,9 +10,11 +12,13 Reserved 16 Local time, in seconds, since Jan 1, 1970 Fractional seconds, µsec Fractional seconds, milliseconds Seconds Minutes Hour Day of month Month Year (calendar year minus 2000) Weekday Daylight savings time status Device IP Address Network subnet mask Network default gateway Number of dial attempts Connection timeout, sec Delay between redials, sec Idle connection timeout, sec Units µsec Type UINT16 R/W R/W Notes UINT16 R/W Offset in minutes from UTC (Universal Coordinated or Greenwich Mean time) UINT16 R/W UINT16 UINT16 R/W R/W UINT16 UINT16 UINT16 R/W R/W R/W UINT16 UINT16 R/W R/W UINT16 F1 0-999 0-59 0-59 0-23 1-31 1-12 0-99 1-7 (Sun = 1, Sat = 7) 0 = standard time, 1 = daylight savings time is active sec µsec UINT32 UINT32 UINT16 UINT16 UINT16 UINT16 UINT16 UINT16 UINT16 UINT16 UINT16 R R R/W R/W R/W R/W R/W R/W R/W R R UINT16 0x01000000-0xFFFFFFFF 0x00000001-0xFFFFFFFF 0x00000000-0xFFFFFFFF 0–1000, 0-dial forever 0-9999 0-9999 0-9999 UINT32 UINT32 UINT32 UINT32 UINT32 UINT32 UINT32 R/W R/W R/W R/W R/W R/W R/W Address Point ID Description +14,15 Number of rings before answer +16-23 Modem init string +24-31 Reserved Communication Ports Setup 46464-46575 +0 Communication protocol +1 Interface +2 Device address +3 Baud rate +4 Data format +5 +6 +7 +8 +9-15 46464-46479 46480-46495 46496-46511 46512-46527 46528-46575 Network Setup 46576-46703 +0, 1 +2, 3 +4, 5 +6, 7 +8, 9 +10,11 +12,13 +14-31 Port direction Receive timeout (COM4 master and COM5 only) Minimum delay before sending data Inter-character timeout Reserved COM2 Setup (future) COM3 Setup COM4 Setup COM5 Setup Reserved Device IP Address Network subnet mask Network default gateway Use DHCP TCP service port Primary DNS IP address Secondary DNS IP address Reserved Options/Range 0-2 “ATZ0&F” Units Type UINT32 CHAR16 R/W R/W R/W 0 = Modbus RTU, 1 = Modbus ASCII, 2 = DNP3.0, 7=IEC 60870-5 0 = RS-232, 1 = RS-422, 2 = RS485, 3 = infrared, 4 = dialup modem, 8 = GSM/GPRS/CDMA2000 Modbus: 1-247 DNP3.0: 0–65532 IEC 60870-5: 1-254 (1 octet), 1-65532 (2 octets) 1 = 300 bps, 2 = 600 bps, 3 = 1200 bps, 4 = 2400 bps, 5 = 4800 bps, 6 = 9600 bps, 7 = 19200 bps, 8 = 38400 bps, 9 = 57600 bps, 10 = 115200 bps 0 = 7 bits/even parity, 1 = 8 bits/no parity, 2 = 8 bits/even parity 0 = master, 1 = slave (COM4 only) 500-30000 ms 0-1000 (default = 5) ms 1-1000 (default = 4) ms UINT16 R/W UINT16 R/W UINT16 R/W UINT16 R/W UINT16 R/W UINT16 UINT16 UINT16 UINT16 R/W R/W R/W R/W 0x01000000-0xFFFFFFFF 0x00000001-0xFFFFFFFF 0x00000000-0xFFFFFFFF 0 = NO, 1 = YES 502 = Modbus/TCP, 20000 = DNP3.0/TCP 0x00000000-0xFFFFFFFF 0x00000000-0xFFFFFFFF UINT32 UINT32 UINT32 UINT32 UINT32 R/W R/W R/W R/W R/W UINT32 UINT32 UINT16 R/W R/W R/W Notes Null-terminated string 0 - default 500 - default 17 Address Point ID Description Dial-up/GPRS Modem Setup (future) 46640-46671 +0,1 Device IP Address +2,3 Network subnet mask +4,5 Network default gateway +6,7 Number of dial attempts +8,9 Connection timeout, sec +10,11 Delay between redials, sec +12,13 Idle connection timeout, sec +14,15 Number of rings before answer +16-23 Modem initialization string +24,25 Auto-reset period, hours +26-31 Reserved Password Setup 46704-46715 +0,1 Communications password (8 digits) +2 Password protection enabled +3 Reserved +4-11 ETC II local Login name Expert Power Service Setup 46768-46783 +0,1 Expert Power server IP Address +2,3 Expert Power server TCP service port +4,5 Expert Power client enabled +6,7 Expert Power client interval +8,9 Expert Power client time to next session +10 Security Key +11-15 Reserved Internet Service Provider (ISP) Accounts 46784-46879 +0-15 ISP telephone number +16-31 Login name +32-47 Login password 46784-46831 Account No1 46832-46879 Account No2 SNTP Client Setup (future) 46880-46895 +0,1 SNTP client enabled +2,3 Polling interval +4-7 Reserved +8,9 Primary SNTP server IP address +10,11 Secondary SNTP server IP address 18 Options/Range Units Type R/W 0x01000000-0xFFFFFFFF 0x00000001-0xFFFFFFFF 0x00000000-0xFFFFFFFF 0–1000, 0-dial forever 0-9999 0-9999 0-9999, 0 = never 0-20, 0 = never answer “AT&F&D1&C1” 1-24, 0 = never UINT32 UINT32 UINT32 UINT32 UINT32 UINT32 UINT32 UINT32 CHAR16 UINT32 R/W R/W R/W R/W R/W R/W R/W R/W R/W R/W 0 - 99999999 0 = disabled, 1 = enabled UINT32 UINT16 UINT16 CHAR16 R/W R/W R/W R/W UINT32 UINT32 UINT32 R/W R/W R/W UINT32 UINT32 UINT16 R/W R W CHAR32 CHAR32 CHAR32 R/W R/W R/W UINT32 UINT32 UINT32 UINT32 UINT32 R/W R/W R/W R/W R/W “” 0x01000000-0xFFFFFFFF 0-65535 (5001 – default) 0=client disabled, 1=client enabled 1- 99999 (0 = close client) 1- 99999 0-7 (0 = disabled) 0=disabled, 1=enabled 60-86400 0 0x01000000-0xFFFFFFFF 0x01000000-0xFFFFFFFF min min s Notes Null-terminated string Default = 600 s Default = 192.36.143.151 Default = 130.149.17.21 Address Point ID +12-15 Data Server Setup 46928-46943 +0 +1 +2,3 +4,5 +6 +7 +8 +9-15 46944-46959 +0 +1 +2,3 +4,5 +6 +7 +8 Description Reserved Real-time Data Exchange Setup Exchange number Reserved Start device register address Exchange block size, registers Device ID Polling enabled RTC update enabled (optional) Reserved Status Event Exchange Setup Exchange number Reserved Device status register address Event mask Device ID Polling enabled Options flags (bitmap) +9-15 46960-46975 +0 Reserved Write Data Exchange Setup Exchange number +1 +2,3 +4,5 +6 +7 +8-15 46976-46991 +0 +1 +2 +3 +4-15 Gateway Setup 46992-46999 Reserved Start device register address Exchange block size, registers Device ID Write enabled Reserved Data Server Options Polling interval Logging interval, polls Data Server Enabled Continuous polling Reserved Options/Range Units Type R/W Notes 0-249 UINT16 R/W Write an exchange number before reading the setup registers 0-65535 1-114 1-247 1=enabled, 0=disabled 1=enabled, 0=disabled UINT32 UINT32 UINT16 UINT16 UINT16 R/W R/W R/W R/W R/W 0-249 UINT16 R/W UINT16 UINT32 UINT32 UINT16 UINT16 UINT16 R/W R/W R/W R/W R/W 0-249 UINT16 R/W 0-65535 1-12 1-247 1=enabled, 0=disabled UINT16 UINT32 UINT32 UINT16 UINT16 R/W R/W R/W R/W UINT16 UINT16 UINT16 UINT16 R/W R/W R/W R/W 0-65535 0x00000000–0x0000FFFF 1-247 1=enabled, 0=disabled Bit 0 – auto reset: 0=disabled 1=enabled Bit 1 – register type: 0=holding register (request 3) 1=coils (request 1) 1-1000 0-1000, 0=logging disabled 1=enabled, 0=disabled 1=enabled, 0=disabled min Write an exchange number before reading the setup registers Lower 16 bits are used Write an exchange number before reading the setup registers 1 min default 1 - default 0- default 0- default 19 Address Point ID +0 +1 +2 +3 +4 +5 +6-7 Device Routing Table 47000-47249 +0 +1 +246 +247-249 Routing IP Table 47250-47299 +0,1 +2,3 +30,31 +32-49 47300-52149 Description ETC II device address Gateway device address range start Gateway device address range end Shared device access enabled 1, 2 Temporarily override device access restrictions Routing table enabled 2 Reserved Device 1 rout path 1 Options/Range 1-247 1-247 1-247 0=enabled, 1=disabled 0=disabled, 1=enabled 0=disabled, 1=enabled Type UINT16 UINT16 UINT16 UINT16 UINT16 UINT16 R/W R/W R/W R/W R/W R/W R/W UINT16 R/W UINT16 R/W UINT16 R/W 0x00000000-0xFFFFFFFF 0x00000000-0xFFFFFFFF UINT32 UINT32 R/W R/W 0x00000000-0xFFFFFFFF UINT32 R/W Bits 0–3 - destination port: 0=none, 1=Ethernet, 4=COM4, 5=COM5 Bits 4-7 - shared device access rule (see F5) 2 Bits 8-15 - IP entry number in the Routing IP Table for the Ethernet port Device 2 rout path … Device 247 rout path Reserved IP Address 1 IP Address 2 … IP Address 16 Reserved Reserved Units Notes 99 default 1 default 247- default 0 - default Active only within current session 0 - default 1 Shared device access allows several clients to simultaneously access device registers either for a read or a write. It is normally enabled, so different clients can poll data registers in the same device without collisions. However, simultaneous file accesses to the same device could destroy device file buffers so both clients may receive corrupted data. To prevent such collisions, the user can disable shared device accesses so the ETC II will reject any additional requests addressed to a device that is being accessed by another client. In this event, the ETC II will return an exception response with the error code 10 = “Gateway is busy” until the first client closes the session or points to a different device. 2 Starting with V21.5.4. If the routing table is enabled in the ETC II and shared device access is also enabled, then the ETC II manages shared device accesses according to the access rules defined in the routing table individually for each device. 20 21 5 Data Formats Format Code Timestamp F1 Value Local time in a UNIX-style format. Represents the number of seconds since midnight (00:00:00), January 1, 1970. The time is valid after January 1, 2000. Event Type ID F2 0x1400-0x1463 0x5D00 0x5E00 0x6000 0x6200 0x6300 Event Data F3 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 24 25 26 27 28 29 Device Diagnostics (bitmap) F4 Bit 0 = 1 Bit 1 = 1 Bit 2 = 1 Bit 3 = 1 Bit 4 Bit 5 = 1 Bit 6 Bit 7 = 1 Bit 8 = 1 Bit 9 = 1 Bit 10 = 1 Bit 11 = 1 Bit 12 = 1 22 Description Data Server Events Status polling event (masked), low byte = exchange number. Event data contains the event status value Self-Check Diagnostics Event Action/Cause (See F3 for Event data contents) Self-Update Event RTC DST/Standard time update Run-time Error Run-time exception Hardware Diagnostics Event Action/Cause (See F3 for Event data contents) External Event Action/Cause (See F3 for Event data contents) Power down Reserved RAM/Data error CPU Watchdog reset Reserved CPU exception Reserved Software Watchdog Power up Device reset Configuration reset RTC fault Configuration fault XP fault counter Reset Timer expired MASTER EEPROM fault Event Log corrupted Data Log corrupted Data Server setup Reserved C Library error RTOS Kernel fatal error Task error Reserved Reserved Reserved XP session started XP session completed successfully XP session failed Reserved Permanent fault RAM/Data error CPU Watchdog reset Reserved CPU exception Reserved Software watchdog Power down Device reset Configuration reset RTC fault Configuration fault Notes Format Code Value Bit 13 Bit 14 Bit 15 Bit 16 Bit 17 Bit 18 Bit 19 Bit 20 Bit 21 Bit 22 Bit 23 Shared Access Rules F5 0 1 2 =1 =1 =1 =1 Description Notes Reserved Reserved Master EEPROM fault Reserved Reserved Reserved Reserved C Library error RTOS Kernel error Task error Reserved No access limitation PM296 Family (PM171, PM172, PM295, PM296/RPM096) locked registers: 1120-1791 3916-4035 4608-5930 6144-6655 28160-28927 29440-32896 35456-35743 SA300 Family (SA300, EM610, BFM136, PM174, PM175) locked registers: 3072-3259 63120-65151 23
* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project
advertisement