Download Print this page

Advertisement

Quick Links

INSTRUCTION MANUAL
IM154-U v0.94
EMC series
EMC h series MULTIMETERS MODBUS-RTU COMMUNICATION PROTOCOL
MODBUS PROTOCOL
Modbus is a master-slave communication protocol able to support up to 247 slaves organized as a bus or as a star
network;
The physical link layer can be RS232 for a point to point connection or RS485 for a network.
The communication is half-duplex.
The network messages can be Query-Response or Broadcast type.
The Query-Response command is transmitted from the Master to an established Slave and generally it is followed by an
answering message.
The Broadcast command is transmitted from the Master to all Slaves and is never followed by an answer.
MODBUS use two modes for transmission.
A) ASCII Mode: uses a limited character set as a whole for the communication.
B) RTU Mode:
binary, with time frame synchronization, faster than the ASCII Mode, uses half so long data block than
the ASCII Mode.
EMC analyzers employ RTU mode.
GENERIC MESSAGE STRUCTURE:
START
ADDRESS
FUNCTION
OF
FIELD
FRAME
START OF FRAME
= Starting message marker
ADDRESS FIELD
= Includes device address in which you need to communicate in Query-Response mode. In case
FUNCTION CODE
= Includes the operation code that you need to perform.
DATA FIELD
= Includes the data field.
ERROR CHECK
= Field for the error correction code.
END OF FRAME
= End message marker.
Mode RTU communication frame structure:
START OF FRAME
= silence on line for time >=4 characters
ADDRES FIELD
= 1 character
FUNCTION CODE
= 1 character
DATA FIELD
= N characters
ERROR CHECK
= 16 bit CRC
END OF FRAME
= silence on line for time >=4 characters
Wait time for response :
- typical
: 150 mS
- worst case : 300 mS.
protocol communication
EMC
ELECTRICAL MULTIFUNCTION METER COMMUNICATION PROTOCOL
DATA
ERROR
CODE
FIELD
CHECK
the message is a Broadcast type it includes 00.
instruction manual
END
OF
FRAME
IM154-U v0.94
pag. 1 / 12

Advertisement

loading
Need help?

Need help?

Do you have a question about the EMC Series and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Summary of Contents for Contrel EMC Series

  • Page 1 INSTRUCTION MANUAL IM154-U v0.94 EMC series ELECTRICAL MULTIFUNCTION METER COMMUNICATION PROTOCOL EMC h series MULTIMETERS MODBUS-RTU COMMUNICATION PROTOCOL MODBUS PROTOCOL Modbus is a master-slave communication protocol able to support up to 247 slaves organized as a bus or as a star network;...
  • Page 2: Crc Generation

    CRC GENERATION Example of the CRC-16 generation with "C" language: static unsigned char auchCRCHi [ ] = { 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81,...
  • Page 3 READING OF THE REGISTERS ( Function Code $ 03) Reads the binary contents of holding registers ( 2X references) in the slave. Broadcast is not supported. The Query message specified the starting register and quantity of register to be read. QUERY: START ADDRESS...
  • Page 4 SETUP OF THE EMC PARAMETERS (Function Code $ 10 ) Write values into a sequence of holding registers (2X references). WARNING: It is possible to write more than one variable at the same time only if their addresses are consecutive and the variables on the same line cannot be divided.
  • Page 5 DIAGNOSTIC (Function Code $ 08) This function provides a test for checking the communication system. Broadcast is not supported. The instrument’s protocol has only the sub-function 0 of the diagnostics sub-functions set of the standard modbus protocol. The Query and the Response messages are the following: QUERY: START ADDRESS...
  • Page 6 REPORT SLAVE ID (Function Code $ 11) This function returns the type of the instrument and the current status of the slave run indicator. Broadcast is not supported. The Query and the Response messages are the following: QUERY: START ADDRESS FUNCTION ERROR FIELD...
  • Page 7 ERROR MESSAGE FROM SLAVE TO MASTER When a slave device receives a not valid query, it does transmit an error message. RESPONSE: START ADDRESS FUNCTION ERROR ERROR FIELD CODE CODE CHECK FRAME FRAME START OF FRAME = Starting message marker. ADDRESS FIELD = EMC device address ( 01...F7 HEX) (1 byte).
  • Page 8 TABLE OF EMC REGISTERS The following table shown all the EMC registers. All registers are 16-bit integer type (signed or unsigned). MEASURED VALUES (Function code $ 03) Register HEX Word Description M. U. Type $1000 3-PHASE SYSTEM VOLTAGE (Unsigned) $1002 PHASE VOLTAGE L (Unsigned) $1004...
  • Page 9 ENERGY COUNTERS MODBUS DATA REGISTERS FOR ENERGY COUNTERS Register HEX Word Description M. U. Type 100*Wh $103E 3-PHASE SYS. ACTIVE ENERGY T1 (Unsigned) [100*VARh $1040 3-PHASE S. REACTIVE ENERGY T1 (Unsigned) 100*Wh $1042 3-PHASE SYS. ACTIVE ENERGY T2 (Unsigned) [100*VARh $1044 3-PHASE S.
  • Page 10 WRITE EMC PARAMETERS (Function code $10) RESET WRITE Value Register HEX Description MSB word LSB word $11B0 RESET ENERGY COUNTERS $11B0 $55AA $11B2 RESET MAX. ISTANTANEOUS VALUES $11B2 $55AA $11B4 RESET MAX AVG (max demand) VALUES $11B4 $55AA $11B6 RESET ALL VALUES (MAX and counters values) $11B6 $55AA DIGITAL OUTPUTS MANAGEMENT...
  • Page 11 READ EMC SETTING AND STATUS (Function code $03) Register HEX Word Description Range MSB BYTE VALUE MEANING: DIGITAL OUTPUT DO1 SETTINGS. 1 = ACTIVE ENERGY PULSE OUTPUT $109A MSB byte: DO1 function mode 2 = 3PHASE ALARM MODE (table A) LSB byte: DO1 alarm parameter 3 = MAX/MIN L123 ALARM MODE (table B) 4 = BY_REMOTE CONTROLLED...
  • Page 12 - if the RS232/485 converter is not our model EMI-1, be sure the turnaround-time is set in range 1 to 2 mS ISO 9001:2000 elettronica srl CERTIFICATE N. 9105.C035 Contrel elettronica srl - 26900 LODI - ITALY - via S. Fereolo, 9 Tel. +39 0371 30207/30761/35386 Fax. +39 0371 32819 E-mail: contrel @contrel.it www.contrel.it protocol communication instruction manual IM154-U v0.94...