hit counter script
Siemens SITRANS F Operating Instructions Manual

Siemens SITRANS F Operating Instructions Manual

Communication modules modbus rtu rs485
Hide thumbs Also See for SITRANS F:

Advertisement

Communication Modules
Modbus RTU RS485
Operating Instructions
06/2010
SITRANS F

Advertisement

Table of Contents
loading

Summary of Contents for Siemens SITRANS F

  • Page 1 Communication Modules Modbus RTU RS485 Operating Instructions 06/2010 • SITRANS F...
  • Page 3 Modbus RTU RS485 System integration Functions codes Operating Instructions Technical data Modbus holding registers Appendix Add-on module for use with transmitter types SITRANS F M MAG 6000, SITRANS F M MAG 6000 I and SITRANS F M MASS 6000. 06/2010 A5E00753974-04...
  • Page 4 Note the following: WARNING Siemens products may only be used for the applications described in the catalog and in the relevant technical documentation. If products and components from other manufacturers are used, these must be recommended or approved by Siemens. Proper transport, storage, installation, assembly, commissioning, operation and maintenance are required to ensure that the products operate safely and without any problems.
  • Page 5: Table Of Contents

    Table of contents Introduction..............................5 Purpose of the Operating Instructions ...................5 Document history ...........................5 Modbus RTU technology .......................6 Further Information ........................7 Safety notes............................... 9 Installation in hazardous area ......................9 Hardware Installation ..........................11 MAG/MASS 6000 IP67 or 19"......................11 MAG 6000 I ..........................12 MASS 6000 Ex d..........................13 Connecting ..............................
  • Page 6 Table of contents External input ..........................50 Sensor characteristics......................... 51 Product identity ........................... 52 A.10 Service info ..........................52 A.11 Display settings ........................... 53 A.12 Flowmeter status......................... 57 Appendix..............................59 Units ............................59 Units and point positioners......................59 Modbus Coils ..........................64 Error information .........................
  • Page 7: Introduction

    See also For more information about SITRANS F C and SITRANS F M transmitters and sensors, please refer to the appropriate Operating Instructions available on the flowdocumentation homepage (http://www.siemens.com/flowdocumentation) or on the SITRANS F literature CD- ROM.
  • Page 8: Modbus Rtu Technology

    Features The SITRANS F Modbus RTU Communication modules comply with the MODBUS Serial Line Protocol. Among other things this implies a Master-Slave protocol at level 2 of the OSI model. A node (the master) issues explicit commands to one of the slave-nodes and processes responses.
  • Page 9: Further Information

    Product information on the Internet The Operating Instructions are available on the CD-ROM shipped with the device, and on the Internet on the Siemens homepage, where further information on the range of SITRANS F flowmeters may also be found: Product information on the internet (http://www.siemens.com/flow)
  • Page 10 Introduction 1.4 Further Information Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 11: Safety Notes

    Safety notes CAUTION Correct, reliable operation of the product requires proper transport, storage, positioning and assembly as well as careful operation and maintenance. Only qualified personnel should install or operate this instrument. Note Alterations to the product, including opening or improper repairs of the product, are not permitted.
  • Page 12 Safety notes 2.1 Installation in hazardous area Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 13: Hardware Installation

    Hardware Installation This chapter describes the HW installation procedure for the add-on module on Siemens Flow Instruments USM-II transmitters. The Module can be installed into SITRANS F C MASS 6000 and SITRANS F M MAG 6000 transmitters. Note Not allowed for use in hazardous areas The Communication module is NOT allowed for use in hazardous areas.
  • Page 14: Mag 6000 I

    2. Press the add-on module in the direction shown until it stops and is firmly seated in position 3. The installation is completed MAG 6000 I The installation of the add-on module on a SITRANS F M MAG 6000 I is completed as follows: 1. Open the transmitter WARNING...
  • Page 15: Mass 6000 Ex D

    Installation in hazardous area The communication module is NOT approved for use in hazardous area. The installation of the add-on module on a SITRANS F C MASS 6000 Ex d is completed as follows: 1. Disconnect the equipment from the supply circuits...
  • Page 16 Hardware Installation 3.3 MASS 6000 Ex d 2. Remove the rear cover by loosening the safety tap allen screw and turn the rear cover counter-clockwise 3. Remove the electronics using the holes provided 4. Remove the flat cable from the plate 5.
  • Page 17 Hardware Installation 3.3 MASS 6000 Ex d 6. Insert the add-on module as shown. Note The label on the add-on module must face upwards and the connector outwards 7. Press the add-on module into position and connect the flat cable connector. Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 18 Hardware Installation 3.3 MASS 6000 Ex d Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 19: Connecting

    Connecting On the electrical termination boards for USM-II transmitters, additional input/output terminals have been reserved for add-on module functions. The numbering range of these terminals is as follows, but how many are actually used depends on the type of add-on module. Additional terminals reserved for add-on modules: ●...
  • Page 20: Wiring

    Connecting 4.1 Wiring Wiring Figure 4-1 Modbus USMII connection Table 4- 1 Connection layout Terminal number MODBUS RTU RS485 Data + Data - Shield NOTICE Temination Connecting 91,92 and 93,94 will add termination. This must be carried out if the device is the last on the segment.
  • Page 21: System Integration

    System integration This chapter provides information on how to integrate the flowmeter in a Modbus RTU automation and control system. The chapter shows the necessary steps in order to put the system into operation. After finishing the steps, the system is ready to go into normal operation in the Modbus RTU automation control system.
  • Page 22: Navigating The Modbus Display Menu

    System integration 5.2 Navigating the Modbus display menu Navigating the Modbus display menu 1. Power up the device. If the device has been installed correctly a new menu entry has appeared in the local user interface of the device (between the "Reset mode" and the "Service mode"...
  • Page 23 System integration 5.2 Navigating the Modbus display menu Table 5- 1 Menu items Item Value Description Device 1-247 Device address [Factory setting: 1] Communication Address Baud rate 1200, 2400, 4800, 9600, 19200, Communication speed 38400, 57600, 76800, 115200 [Factory setting: 19200] Even, 1 stopbit Parity/framing Communication parameters...
  • Page 24 System integration 5.2 Navigating the Modbus display menu Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 25: Functions Codes

    Broadcast communication is not secured by the normal check mechanisms and shall be limited to very few uses. A SITRANS F Modbus slave only recognizes (and accepts) few Modbus RTU commands/function codes.
  • Page 26: Read Coils

    Functions codes 6.2 Read coils Read coils Command messages The read coils functions (01hex x) allow the master to request information from the slave. The command message of a coil read is structured as shown below. Each row in the table compares to a byte in the message –...
  • Page 27 Functions codes 6.2 Read coils Table 6- 3 Read coil normal response messages Message byte Example Slave address xxhex Function code 01hex Bit count xxhex Coil status byte(s) xxhex xxhex Next coil status byte(s) xxhex xxhex Last coil status byte(s) xxhex xxhex CRC-16...
  • Page 28: Read Multiple Registers

    Functions codes 6.3 Read multiple registers Read multiple registers Command messages The multiple register read functions (03hex) allows the master to request information from the slave. The command message of a multiple register read is structured as shown below. Each row in the table compares to byte in the message – top byte (Slave address) is transmitted first.
  • Page 29 Functions codes 6.3 Read multiple registers Table 6- 6 Read multiple registers normal response messages Message byte Example Slave address xxhex Function code 03hex Byte count xxhex Starting register Upper xxhex Lower xxhex Next register Upper xxhex Lower xxhex Last register Upper xxhex Lower...
  • Page 30: Write Single Coil

    Functions codes 6.4 Write single coil ● Query: 1,3,11,190,0,2,166,11 (Hex 01,03,0B,BE,00,02,A6,0B) ● Response: 1,3,4,189,216,115,34,251,77 (Hex 01,03,04,BD,D8,73,22,FB,4D) ● Sensor temperature = −0.10569 °C Write single coil Command messages The write coil functions (05hex) allow the master to control single bits in the slave. The command message of a coil write is structured as shown below.
  • Page 31: Write Multiple Registers

    Functions codes 6.5 Write multiple registers Table 6- 9 Write coil normal response messages Message byte Example Slave address xxhex Function code 05hex Coil address Upper xxhex Lower xxhex New coil value Upper FFhex or 00hex Lower 00hex CRC-16 Lower xxhex Upper xxhex...
  • Page 32 Functions codes 6.5 Write multiple registers The initial slave address is 1. Address 0 (broadcast) and other values between 1 and 255 can be used. The function code of this message is 10hex (write multiple registers). The starting register is the first register to be written to. The quantity indicates how many consecutive 16-bit registers are to be written to.
  • Page 33 Functions codes 6.5 Write multiple registers Message byte Example Starting register Upper xxhex Lower xxhex Quantity Upper xxhex Lower xxhex CRC-16 Lower xxhex Upper xxhex Exception responses The exception response message contains the same slave address as the command message. The function code of the exception message is actually a value of 80 hex plus the original function code of 10 hex.
  • Page 34: Report Slave Id Command

    6.6 Report slave ID command Report slave ID command All SITRANS F slaves will respond to a Report Slave ID command (Command 17) request from the master by giving in formation about device type, vendor, revision level etc. in a...
  • Page 35: Exception Handlng

    Run Indicator 0xFF Product Code 25 (0x19) Transmitter Code No 083H0222 Capability bits 0x01, 0xFF, 0x00 Manufacturer name Siemens Product name MASS 6000 Product major rev Product minor rev MODBUS module name MODBUS RTU MODBUS module No 0xFF MODBUS module major rev...
  • Page 36 Functions codes 6.7 Exception handlng If an exception code 04 is received, further requests have to be done to narrow down the exact problem. If any doubts about the address that failed, "Last Coil/HoldReg ErrorAddr" can be read. This will return the faulty address. MODBUS MODBUS No.
  • Page 37: Technical Data

    Technical data Table 7- 1 Technical data Device type Slave Baud rates 1200, 2400, 4800, 9600, 19200, 38400, 57800 bits/sec Number of stations Recommended: max. 31 per segment without repeaters Device address range 1-247 Protocol RTU (Other Modbus protocols like ASCII, Plus or TCP/IP are not supported.) RS485, 2 wire Electrical interface...
  • Page 38 Technical data Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 39: Modbus Holding Registers

    Modbus holding registers In the following the holding registers for the USM II Modbus RTU module are described. Figure A-1 Modbus Holding Registers Memory Map ● The minimum value of a writable "holding register" value can be read by adding 10000 to the address of the value.
  • Page 40: Modbus Driver Settings

    Modbus holding registers A.2 MODBUS driver settings Table A- 2 Process data, MASS 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:03001 3000 Float Absolute Massflow (kg/s) 4:03003 3002 Float Absolute Volumeflow (m3/s) 4:03005 3004 Float Absolute Density (kg/m3)
  • Page 41: Modbus Application Settings

    Slave ID MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:00601 Byte Slave ID: 0x2A = Siemens • 4:00602 Byte Run indicator: 0x00 = not running • 0xFF = running • 4:00603 Byte Product code 24 = MAG 6000 •...
  • Page 42: Basic Settings

    Modbus holding registers A.4 Basic settings Table A- 5 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:00641 String Table A- 6 MODBUS module version MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:00650...
  • Page 43 Modbus holding registers A.4 Basic settings MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02032 2031 Byte Error level: 1 = Warning • 2 = Permanent • 3 = Fatal • 4:02033 2032 Byte Zero adjust mode 0 = Auto •...
  • Page 44: Totalizer

    Modbus holding registers A.5 Totalizer MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02031 2030 Byte Noise filter: 1 = min. • • • • 5 = max. • 4:02032 2031 Byte Error level: 1 = Warning •...
  • Page 45: Output

    Modbus holding registers A.6 Output Table A- 11 Totalizer, MASS 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02101 2100 Byte Totalizer 1 selection: 1 = Massflow • 2 = Fraction A • 3 = Fraction B •...
  • Page 46 Modbus holding registers A.6 Output MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02206 2205 Byte Digital Output 1 function: 0 = Off • 1 = Pulse • 2 = Frequency • 3 = Error Level •...
  • Page 47 Modbus holding registers A.6 Output MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02222 2221 Float Limit Digital Hysteresis (1/100%) 4:02224 2223 Byte Relay Output 1 function: 0 = Off • 3 = Error Level •...
  • Page 48 Modbus holding registers A.6 Output Table A- 13 Output, MASS 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02201 2200 Byte Current Output 1 selection: 0 = Off • 1 = Massflow • 2 = Fraction A •...
  • Page 49 Modbus holding registers A.6 Output MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02209 2208 Byte Pulse 1 width: 0 = 64 us • 1 = 130 us • 2 = 260 us • 3 = 510 us •...
  • Page 50 Modbus holding registers A.6 Output MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02216 2215 Byte Limit Digital selection: 0 = Off (read only) • 1 = Massflow • 2 = Fraction A • 3 = Fraction B •...
  • Page 51 Modbus holding registers A.6 Output MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02237 2236 Float Batch Compensation (m3) 4:02239 2238 Float Batch Lead constant 4:02241 2240 Byte Batch Time error on/off: 0 = Off •...
  • Page 52: External Input

    Modbus holding registers A.7 External input External input Table A- 14 External input, MAG 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02301 2300 Byte Input Function: 0 = Off • 1 = Start Batch •...
  • Page 53: Sensor Characteristics

    Modbus holding registers A.8 Sensor characteristics Sensor characteristics Table A- 16 Sensor characteristics, MAG 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02401 2400 Float Sensor size (m) 4:02403 2402 Float Calibration factor 4:02405 2404 Float Correction factor...
  • Page 54: Product Identity

    Modbus holding registers A.9 Product identity Product identity Table A- 18 Product identity, MAG 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02501 2500 String Converter type 4:02511 2510 String Converter code no. 4:02521 2520 String Converter serial no.
  • Page 55: Display Settings

    Modbus holding registers A.11 Display settings Table A- 21 Service info, MASS 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02701 2700 Double word Operating time (s) 4:02703 2702 Byte array USM II Error pending list See Error information (Page 66) 4:02730 2729...
  • Page 56 Modbus holding registers A.11 Display settings MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02903 2902 Byte Display line 2: 0 = Text for line 3 • 1 = Volumeflow • 2 = Volumeflow % •...
  • Page 57 Modbus holding registers A.11 Display settings Table A- 23 Display settings, MASS 6000 MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02901 2900 Byte Language: 0 = English • 1 = Deutsch • 2 = Français •...
  • Page 58 Modbus holding registers A.11 Display settings MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:02904 2903 Byte Display line 3: 1 = Massflow • 2 = Massflow % • 3 = Volumeflow • 4 = Volumeflow % •...
  • Page 59: Flowmeter Status

    Modbus holding registers A.12 Flowmeter status A.12 Flowmeter status Table A- 24 Flowmeter status MODBUS MODBUS No. of bytes Data type Description Read / write register address 4:03201 3200 Word System status: bit0=RunIndicator • bit1=ErrorPendingOn • bit2=ErrPendChanged • bit3=Batching • bit4=BatchPaused •...
  • Page 60 Modbus holding registers A.12 Flowmeter status Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 61: Appendix

    Appendix Units The following standard SI Units are used in USMII transmitters: SITRANS F M ● Volume flow: m /sec. ● Totalisers: m SITRANS F C ● Mass flow: kg/sec. ● Volume flow: m3/sec. ● Density: kg/m3 ● Temperature: °C ●...
  • Page 62 Appendix B.2 Units and point positioners Unit Description t / min metric ton per minute lb / min pound per minute mg / min milligram per minute g / min gram per minute 21 ... 31 kg / min kilogram per minute kg/h kilogram per hour ton/h...
  • Page 63 Appendix B.2 Units and point positioners Unit Description kL / min kiloliter per minute ML/ min megaliter per minute bbl / min barrel per minute / min cubic meter per minute / min cubic feet per minute / min cubic inch per minute USGPM US gallon per minute USMGPM...
  • Page 64 Appendix B.2 Units and point positioners Unit Description USkGPD kilo US gallon per day UKkGPD kilo imperial gallon per day 64 ... 255 Reserved Table B- 3 Density Units Unit Description kg/m kilogram per cubic meter t / m metric ton per cubic meter lb / m pound per cubic meter mg / m...
  • Page 65 Appendix B.2 Units and point positioners Table B- 5 Totalizer units for volumeflow Unit Description cubic meter milliliter liter hectoliter kiloliter megaliter USBBL barrels cubic meter cubic feet cubic inch US gallon USMG mega US gallon Imperial gallon UKMG mega Imperial gallon USkG kilo US gallon UKkG...
  • Page 66: Modbus Coils

    Appendix B.3 Modbus Coils Modbus Coils In the following the coils for the USM II MODBUS RTU module are described. Figure B-1 Modbus Coils Memory Map Communication settings Table B- 7 Communication settings MODBUS register MODBUS address Data type Description Read/ write 0:00001...
  • Page 67 Appendix B.3 Modbus Coils Totalizer Table B- 9 Totalizer MODBUS register MODBUS address Data type Description Read/ write 0:00010 Coil Reset totalizer 1: Write: 0 = No effect • 1 = ResetRead: • – always 0 0:00011 Coil Hold totalizer 1: Write: 0 = Run •...
  • Page 68: Error Information

    Appendix B.4 Error information Batch Table B- 10 Batch MODBUS MODBUS Data type Description Read/ register address write 0:00014 Coil Start Batch: Write: 0 = Stop Batch • 1 = Start BatchRead: • – 0 = Stopped – 1 = Not stopped 0:00015 Coil Pause Batch:...
  • Page 69: Run Indicator

    Appendix B.5 Run indicator Error Number A list of all error numbers can be found in the relevant SITRANS F M / SITRANS F C Operating Instructions. No error is represented by 0x7F. • 0: Information Category • 1: Warning •...
  • Page 70: Crc Calculation

    Appendix B.6 CRC calculation Only the internally broadcasted flow-value is checked. The expected broadcast-rate is read at power up. If a broadcast is not received after 10 times the expected broadcast rate, the broadcast rate is re-read from the USM (it may have been changed since power up). If the broadcast rate was not changed (and the rate was not zero), the Run Indicator is set OFF.
  • Page 71 Appendix B.6 CRC calculation C programming example /* Table of CRC values for high-order byte */ static __flash 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,...
  • Page 72 Appendix B.6 CRC calculation 0x3B, 0xFB, 0x39, 0xF9, 0xF8, 0x38, 0x28, 0xE8, 0xE9, 0x29, 0xEB, 0x2B, 0x2A, 0xEA, 0xEE, 0x2E, 0x2F, 0xEF, 0x2D, 0xED, 0xEC, 0x2C, 0xE4, 0x24, 0x25, 0xE5, 0x27, 0xE7, 0xE6, 0x26, 0x22, 0xE2, 0xE3, 0x23, 0xE1, 0x21, 0x20, 0xE0, 0xA0, 0x60, 0x61, 0xA1, 0x63, 0xA3, 0xA2, 0x62, 0x66, 0xA6, 0xA7, 0x67, 0xA5, 0x65, 0x64, 0xA4, 0x6C, 0xAC, 0xAD, 0x6D, 0xAF, 0x6F,...
  • Page 73: Data Type Mapping

    B.7 Data type mapping Data type mapping Some standard datatypes are defined in the SITRANS F protocol. Most of these datatypes are not present in the MODBUS® RTU protocol as it defines ‘Registers’ and ‘Coils’ for all variables. A register in this context is always 16 bit long. This will prove restrictive for the parameters found in Siemens Flow products and therefore a number of approaches have been adopted to overcome this restriction.
  • Page 74 Appendix B.8 Float definition Table B- 12 Float definition Value (decimal) IEEE FP B MSB Register N Register N + 1 high high 100.0 42C80000h 55.32 425D47AEh 40000000h 3F800000h -1.0 BF800000h Example Read absolute massflow (4:03001): ● Query: 01,03,0B,B8,00,02,46,0A ● Response: 01,03,04,40,C3,52,93,62,C8 ●...
  • Page 75: Glossary

    Glossary Cyclic Redundancy Check. Used for error-checking in MODBUS RTU Modbus master A ModBus device, which is able to access data in one or more connected ModBus slaves. Modbus slave A ModBus device, which is able to respond to requests from a single ModBus master. RS232 Refers t communication standard defined by EIA/TIA-232.(Physical layer) RS485...
  • Page 76 Glossary Modbus RTU RS485 Operating Instructions, 06/2010, A5E00753974-04...
  • Page 77: Index

    Index Function codes, 25 Application settings, 41 Hazardous areas, 11 Basic settings MAG 6000, 42 Input MASS 6000, 43 MAG 6000, 52 MASS 6000, 52 Installation Hardware, 13 MAG 6000 19", 14 Cable specifications, 19 MAG 6000 I, 15 Communication modes, 8 MAG 6000 IP67, 14 Contact person, 9 MASS 6000 19", 14...
  • Page 78 Index MAG 6000, 54 MASS 6000, 54 Read coils, 26 Read multiple register, 28 Report Slave ID, 34 Run Indicator, 69 Safety notes, 11 Sensor characteristics MAG 6000, 53 MASS 6000, 53 Service info MAG 6000, 54 MASS 6000, 55 Slave ID, 41 System integration, 21 TAG, 42...
  • Page 80 For more information www.siemens.com/flow Siemens Flow Instruments A/S Subject to change without prior notice *A5E00753974* Nordborgvej 81 Order No.: A5E00753974 DK-6430 Nordborg Lit. No.: A5E00753974-04 © Siemens AG 06.2010 All rights reserved www.siemens.com/processautomation...

Table of Contents