Home

User Manual, Anybus Communicator for Modbus RTU

image

Contents

1. HMS Industrial Networks AB E Germany 49 721 96472 0 Japan 81 45 478 5340 Sweden 46 35 172920 U S A 1 773 404 3486 Dx ge sales hms networks com jp sales hms networks com sales hms networks com us Sales hms networks com User Manual Anybus Communicator for Modbus RTU Rev 2 53 11 HITIS 44 Table of Contents Table of Contents Preface About This Document HowTo Use Ls DOCENA a P 1 portant User Miro rman A AAA AAA AAA P 1 We ated Doce o eds P 2 Document Esto A di P 2 CON enuon S Term O arado P 3 T a A ET E A A T A E E N N EET A E E E A UOTE te P 3 SUPPORT nivae AR E T O A E A P 4 Chapter 1 About the Anybus Communicator for Modbus RTU Eteni E n o E A T a E ree 1 2 TLE E AI A UR 1 3 CONOS NECESA EA AA AA 1 4 SL E E O 1 4 DOUBT COM TAI AAA AAA AAA AAA AA NA AAA 1 4 E A A ES 1 4 VTA ETA REA AAA AA AAA AAA AAA RAE 1 4 Hardware datado A A A E 1 5 SONA lata ton 1 6 AADC COUN RR 1 6 Chapter 2 Basic Operation GTS EA EE A E ERAS AAA O E AER AA 2 1 Data canos Modelado A 2 2 IVA COU ON VV NP ET EN O O 2 2 Dara Ad ir aci 2 3 Sube NEI Ors T NA 2 4 FOTOL VLOG A AS NC 2 4 TINO DUDO DIOSAS AAA AAA AA RATA A 2 4 TEAST OT INN OAC i Nt elt she tele ARO 2 5 E DD GTA T 2 5 Data Representation on Modbus L N ot 2 6 E E saal oda E itt 2 6 R T 2 6 CORTE RAI AMA ias 2 6 SOON CALERO IAS A A eeu atead a 2 6 Chapter 3 Navigating the ABC Config Tool TEAR S T TTT 321 OUT BOW VICI RNA eres eee A eases
2. A Start Network amp Stop Network Icons These icons controls the sub network activity To stop all sub network activity click on the red light To start the sub network again click on the green light B Nodes Transactions To view data blocks associated with a transaction select the transaction in the list The corre sponding data will then appear in the Monitor Section C C Monitor Section This section visualises how data is allocated in the Input Output and General Data areas Colour White Yellow Meaning Not allocated Data allocated by a Response or Consume transaction Blue Data allocated by a Query or Produce transaction Red Grey Collision area has been allocated more than once Reserved illustrates memory consumption area can be allocated if necessary Green Data allocated by Trigger byte Transmit Receive Counter or Control Status Registers Chapter 10 Node Monitor General The Node Monitor can provide valuable information when setting up the communication with the sub network by allowing individual commands to be issued manually and monitoring the response if ap plicable It also provides an overview of the memoty used by a particular node Note The node monitor has a negative influence on the overall performance of the gateway 1 e 1t should be used only when necessaty The Node Monitor behaves somewhat differently in the two protocol modes e Master Mod
3. Stop Log En Sub Network Monitor Add Command Add Mailbox Lo b Broadcaster SS Node Monitor Add Transactions Transaction Chapter 4 Basic Settings Fieldbus Settings aa Select Fieldbus in the Navigation Section to gain access to the parame Ale ABC ters described in this section A KC Sub Network General During start up the fieldbus interface of the gateway is initialized to fit the configuration created in the ABC Config Tool Optionally some initialisation parameters can be set manually to provide better con trol over how the data shall be treated by the gateway Configuration Alphabetic Categorized Fieldbus Type The ABC Config Tool supports a wide range of networking sys tems Make sure that this parameter is set to Modbus RTU Fieldbus Type Basic Settings 4 7 ABC Parameters Select ABC in the Navigation Section to gain access to the parameters H se R described in this section Ad Sub Metwork Interface Currently only serial communications is supported Status Control Word See 13 1 Control and Status Registers VENTE Description Enabled Enable the Control and Status Registers The Data Valid bit in the Control Register must be set to start the sub network communication Enabled but no startup lock This setting is similar to Enabled except that the control system is not required to set the Data Valid bit t
4. Table 4 Read Coil Status 6 HMS INDUSTRIAL NETWORKS AB AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 2 Read Input Status Starting Address 2 byte value where you enter the first address of the requested discrete inputs No of Points 2 byte value where you enter the number of inputs to read l 1 byte value where you enter the number of expected data bytes value where 1 byte value where you enter the number of expected data bytes enter the number of expected data bytes Data Data object where you enter the length of the received data and the destination address Table 5 Read Input Status 3 Read Holding Registers Starting Address 2 byte value where you enter the first address of the requested registers No ofPoints 2 byte value where you enter the number of registers to read 1 byte value where you enter the number of expected data bytes Data Data object where you enter the length of the received data and the destination address Table 6 Read Holding Registers 4 Read Input Registers Starting Address 2 byte value where you enter the first address of the requested registers No of Points 2 byte value where you enter the number of registers to read 1 byte value where you enter the number of expected data bytes Data Data object where you enter the length of the received data and the destination address Table 7 Read Input Registers 5 Force
5. Basic Operation 2 5 Master Mode In this mode the communication is based on a Query Response scheme when the gateway issues a Query on the sub network the addressed node is expected to issue a Response to that Query Nodes are not permitted issue Responses spontaneously 1 e without first recetving a Query There is one exception to this rule the Broadcaster Most protocols offer some way of broadcasting messages to all nodes on the network without expecting them to respond to the broadcasted message This is also reflected in the gateway which features a dedicated Broadcaster node Control System Gateway Sub Network Devices 7 Node 1 ptas lt Response Broadcast Query p CES R y tes lt Response ce Node 2 Query am S y In Master Mode ABC Config Tool comes pre loaded with most commonly used Modbus RTU com mands which can conveniently be reached by right clicking on a node in the ABC Config Tool and se lecting Insert New Command Note however that this does not in any way prevent other protocols based on the same Query Response message scheme to be implemented Generic Data Mode In this mode there is no master slave relationship between the nodes on the sub network and the gate way Any node including the gateway may spontaneously produce or consume a message Nodes do not have to respond to messages nor do they have to wait for a query in order to send one Control System
6. 1 stop bit ON OFF Odd parity 1 stop bit ON ON Physical Interface Interface Type Sw 5 RS 485 OFF RS 232 ON a About the Anybus Communicator for Modbus RTU 1 5 Hardware Installation Perform the following steps when physically installing the gateway 1 Snap the gateway on to the DIN rail See 1 2 DIN rail Connector The DIN rail mechanism works as follows To snap the gateway on first press the 1t downwards 1 to compress the spring in the DIN rail mechanism then push it against the DIN rail as to make it snap on 2 To snap the gateway off push the it downwards 1 and pull it out from the DIN rail 2 as to make it snap off from the DIN rail Connect the gateway to the Modbus RTU network Set the Modbus RTU communication settings using the on board switches Connect the gateway to the serial sub network Connect the gateway to a free COM port on the PC via the PC cable Connect the power cable and apply power a A A A p Start the ABC Config Tool program on the PC The ABC Config Tool software attempts to detect the serial port automatically If not success ful select the correct port manually in the Port menu 8 Configure the gateway using the ABC Config Tool and download the configuration About the Anybus Communicator for Modbus RTU 1 6 Software Installation ABC Config Tool System requirements Pentium 133 MHz or higher 10 MB of free space on the hard driv
7. 20479 Supported Function Codes The following function codes are supported Function Code Modbus Function Associated with Area s 1 Read Coil Input and Output Data Area 0x000 Ox3FF 2 Read Input Discretes 3 Read Holding Registers 4 Read Input Registers 5 Write Coil Output Data Area 0x200 Ox3FF 6 Write Single Register 15 Force Multiple Coils 16 Force Multiple Registers 22 Mask Write Register 23 Read Write Registers Input and Output Data Area 0x000 Ox3FF Coil amp Register Map The Input amp Output Data areas are mapped to coils and registers as follows Register Coil Memory Location Area Comments 1 1 16 0x000 0x001 Input Data area 2 17 32 0x002 0x003 255 4065 4080 Ox1FC 0x1FD 256 4081 4096 Ox1FE 0x1FF 257 1024 4097 16384 reserved 1025 16385 16400 0x200 0x201 Output Data area 1026 16401 16416 0x202 0x203 1279 20449 20464 0x3FC 0x3FD 1280 20465 20480 0x3FE OXx3FF Note Coils are mapped MSB first i e coil 0 corresponds to bit 15 of register 0 Supported Exception Codes Exception Code Name Description 0x01 Illegal function Function code not supported 0x02 illegal data address Invalid address in query 0x03 illegal data value illegal data in request
8. A 10 3 pE a e o rt o ee e a a 10 4 Chapter 11 Data Logger O NON 11 1 L T 11 1 Contrato es 11 2 Chapter 12 Configuration Wizards Eae EEEN E A A AAE A A E E EE E A EEE ated hati tte at cee hom 12 1 Selegtino a Wizard pro les 12 1 Wizard Modbus RTU INAS e 12 2 Chapter 13 Control and Status Registers e tc io tan od od e la DO 13 1 ELA ROS DUE POCO ALIS sie ina AAA AAA AAA AAA EA NAAA 13 1 A E H det a 13 2 Status Register Contents Gateway ETT tdo 13 3 COMA LOVAINA A AA ener scenes 13 3 CUA A tol cae E Death Clad gie eA ated cle 13 3 Srani Code m Cenate Dala uate cda alae neice dees cheated ua ease 13 4 Control Register Contents Control System to GALEANA ai 13 5 ERT AAN A AA ad aad una 13 5 COTO EO OE VAT ta ed hasta 13 5 COMMON COA MES MM E o sas E ela aes 13 5 Chapter 14 Advanced Fieldbus Configuration O E 14 1 M llbos Balto T 14 1 Appendix A Connector Pin Assignments Biclel bus Connector NCC is IRE psec AA AS A 1 S R 1 AE RIGGS SAORI RN Oe EEE bo TR RTE TR NTN Cre CLE RE eter dl PECAR e dee A 2 Table of Contents 5 Sub 1S Fw Ot ICG ranita A 3 COM OT AU TI OVTLTION E os A 3 DIAS RES RS OD OUI AA AAA A 3 TOPO RS ASD ARNG Lo OD A aa A 3 CINDE LOr LIA AD DIE assis sara tose A O A 3 TOA ORURO Vatican A 4 Typical ORAR RIA 22 G T AAA A 4 TIPS UREA SLI A ASA A A 4 AA A A aE E S A 5 Appendix B Technical Specification Mechanical Properties pool B 1 Plectrical Characters B 1 Rayironmenta Character Si dio
9. B 1 Reculatort CO PAS AAA ARAS B 2 Appendix C Troubleshooting Appendix D ASCII Table Preface About This Document How To Use This Document This document contains a general introduction as well as a description of the technical features pro vided by the Anybus Communicator including the PC based configuration software The reader of this document is expected to be familiar with PLC and software design as well commu nication systems in general The reader is also expected to be familiar with the Microsoft Windows op erating system Important User Information The data and illustrations found in this document are not binding We HMS Industrial Networks AB reserve the right to modify our products in line with our policy of continuous product development The information in this document is subject to change without notice and should not be considered as a com mitment by HMS Industrial Networks AB HMS Industrial Networks AB assumes no responsibility for any errors that may appear in this document There are many applications of this product Those responsible for the use of this device must ensure that all the necessary steps have been taken to verify that the application meets all performance and safe ty requirements including any applicable laws regulations codes and standards Anybus is a registered trademark of HMS Industrial Networks AB All other trademarks are the prop erty of their respective holders The exampl
10. Character Visible The length character is visible both in the internal memory buffer and on the sub network e End Character The end character is visible in the internal memory buffer but not on the sub network e End Character Visible The end character is visible both in the internal memory buffer and on the sub network No Character No End or Length character is generated in the internal memory buffer End Character Value End Character value Maximum Data Length The maximum allowed length in bytes of the variable data object If the actual length of the data exceeds this value the message will be discarded a Only relevant for Consume Response transactions b Only used if Object Delimiter is set to End Character or End Character Visible Frame Objects 7 6 Checksum Object Most serial protocols features some way of verifying that the data has not been corrupted during trans fer The Checksum Object calculates and includes a checksum in a transaction Parameter Description Error Check Start byte This parameter specifies the byte offset in the transaction to start checksum calculations on Error Check Type This parameter specifies which type of algorithm to use e CRC 2 bytes CRC 16 with OxFFFF polynome Modbus RTU standard e LRC 1 byte All bytes are added together as unsigned 8 bit values The 2 s complement of the result will be used as a checksum e XOR 1 by
11. Icons The toolbar features icons for the most commonly used functions e New Open amp Save See 3 2 File e Upload from ABC amp Download to ABC See 3 3 Tools Upload e Up one Level Clicking on this icon will move the selection in the navigation section S ES lt o 4 Download re Up one Level e Cut Copy Paste Delete Insert K L These icons ate used for common editing func E tions in the navigation section e Connect Clicking on this icon will cause the ABC Config Tool to attempt to connect to the gateway e Disconnect Clicking on this icon will cause the ABC Config Tool to disconnect from the gateway e Start Logging amp Stop Logging See 3 3 Tools amp 11 1 Data Logger Start Log e Sub Network Monitor Clicking on this icon will launch the Sub network Monitor see 9 1 Sub Network Monitor e Add Command This icon is used to add commands to the currently selected node e Add Mailbox Advanced functionality see 14 1 Mailbox Editor e Add Node amp Add Broadcaster e These icons ate used to add nodes to the configuration g Node e Node Monitor Clicking on this icon will launch the Node Monitor see 10 1 Node Monitor e Add Transaction s T Tr E R 1 These icons are used to add transactions to the currently selected node Add Cut Copy Paste Delete Insert Connect g Disconnect
12. Value Data location Data length 0x02 0x0008 0x0202 0x0008 Apply Changes This will save any changes and exit to the main window Exit Exit without saving Checksum Byte constant Error check type Error check start byte Value CRC 0x0001 0x03 The transaction created in this example are built up as follows The first byte holds the STX 0x02 followed by two bytes specifying the length of the data field in this case 8 The next 8 bytes are data and since this is a query transaction the data is to be fetched from the Output Area which starts at address location 0x202 No swapping will be per formed on the data This is followed by a two byte checksum The checksum calculation starts with the second byte in the transaction The transaction ends with a byte constant the ETX 0x03 Frame Objects General Chapter 7 Each transaction consists of Frame Objects which makes up the serial telegram frame Each Frame Ob ject specifies how the gateway shall interpret or generate a particular part of the telegram There are 5 types of frame objects which are described in detail later in this chapter e Constant Objects e Limit Objects e Data Objects e Variable Data Objects e Checksum Objects Example The following Transaction consists of several frame objects three constants a data object and a checksum object Transaction Adding and Editing Frame Objects To add a frame object to a Transaction ri
13. by a one byte object byte count and a data object data To match the query you need to add a value into the one byte object that 1s two times the No of points value you entered in the query Furthermore the data object needs a starting address and a length where the length should match the one byte object byte count As you can see the requested data is always of the same length and therefore the data object in the response is also always of the same length Should less bytes than specified arrive then the response is considered to have an error and a re transmission of the query will occur if this command is configured for re transmission The same handling is done if more data than expected arrives HMS INDUSTRIAL NETWORKS AB 5 AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 1 3 Modbus commands The following tables list all Modbus commands that are supported by the AB C For each command there is an expla nation about what actions you as user need to take on the query and response Name 22 Mask Write 4X Register Table 3 Modbus Commands 1 Read Coil Status Starting Address 2 byte value where you enter the first address of the requested coils No of Points 2 byte value where you enter the number of coils to read 1 byte value where you enter the number of expected data bytes Data Data object where you enter the length of the received data and the destination address
14. desired Adding amp Managing Commands To add a command to a node right click on the node in the Navigation Section and select Add Com mand A list of commands will appear Select Command Select the desired command in the list and select Add Command nme Name in the Command menu The specified command will be added Read Input Status Read Holding Registers to the no de Read Input Registers Force Single Coil Preset Single Register oe Just like other transactions the frame objects of added command Fetch Comm Event Ctr OS may be edited in the Navigation Parameter Section or using the Preset Multiple Regs peponSave D Transaction Editor Note however that certain frame objects may Mask Wile aX Register be locked for editing Read Write 4X Registers Read FIFO Queue My Custom Command 1 My Custom Command 2 LEPE EEE coo Commands 8 2 Pull Down Menu File This menu features the following entries e Select Add the currently selected Command to the node e Exit Exit without adding a command to the node Command This menu 15 used to manage the commands in the list Add a custom command to the list and open the Add Command new command in the Command Editor See also 8 3 The Command Editor Edit Command Delete Command e Edit Command Edit the currently selected command using the Command Editor See al
15. desired number of buffer entries under Size of logbuffer valid settings range from 1 512 Firmware Download Restores Communicator firmware Factory Restore Block the current configuration in the Gonna cate Block Configuration Click Apply to validate the new settings Creates an error log file Create Error Log Click OK to exit Configuration Wizards General Chapter 12 When creating a new sub network configuration the ABC Config Tool provides a choice between start ing out with a blank configuration or using a predefined template a k a a wizard The wizard automatically creates a sub network configuration based on information supplied by the us er 1 e the user simply has to fill in the blanks Note however that this will only work when the sub network fits the wizard profile in all other cases the Blank Configuration option must be used Selecting a Wizard Profile The following window appears each time the ABC Config Tool is started or upon selecting the New entry in the File menu unless it has been disabled in the Options menu see 3 3 Tools Currently the following wizards are available Highlight the desired wizard and click OK to continue ABCC ExtLink Wizard This wizard is intended for use with the Anybus Com pactCom Modbus RTU fieldbus communication module Wizard Modbus RTU Master This option is suitable for Modbus R
16. e Master Mode The Message Delimiter specifies the time that separates two messages in steps of 10ms If set to 0 zero the gateway will use the standard Modbus delimiter of 3 5 characters the actual number of ms will be calculated automatically based on the currently used communication settings e Generic Data Mode The Message Delimiter specifies the time that separates two messages in steps of 10us Chapter 5 Nodes General In ABC Config Tool a node represents a single device on the network While the gateway doesn t fea ture a scanlist in the traditional sense all nodes and their transactions will be processed in the order they have been defined in the ABC Config Tool The maximum number of nodes that can be created in the ABC Config Tool is 31 Adding amp Managing Nodes Right click on Sub Network in the Navigation Section to gain access to these functions Function Description Paste Paste a node from the clipboard 2 0 Fieldbus d ABC Sub Network Monitor Launch the subnet monitor 9 1 Sub Network Monitor Si Sub Netwark Sub Network Monitor Add Node Add a node to the configuration Add Node f Add Broadcaster Add Broadcaster Add a broadcaster node to the configuration Load Node Sub Network Status Load Node Add a previously saved node Sub Network Status View diagnostic information about the sub network a This function is only available in Master Mode Node Param
17. oe oe ate ae a eae aun eaaee 32 TONA A A a hae a Paced sl gt gait eb eal aes alee tones 3 5 Table of Contents 3 Chapter 4 Basic Settings A A O Des sinscumsae ial Deen 4 6 A ate ached ened d a ak heh koh at et oki wh oie Uh oh ll ai ole 4 7 LOH COT esha Patito cds 4 1 Chapter 5 Nodes T T E E 5 1 Addino E Tee ao 5 1 Node Parini os 5 1 Chapter 6 Transactions TNC E E E E EN E E TEA A E A E A A T 6 1 Addis Nando mo Transicion talle tdo dla 6 1 Transaction Parameters Master Mode uan lesson 6 2 OTRAS OED OO OLAS NADA AA SA 6 2 VS UA REE TES A acd ION AIE O eld dahl taba A A alacant 6 3 Transaction Parameters Generic Data Mode us RA 6 3 A o a A sie E EE E 6 3 E E T da en ea wien 6 4 ERS dalla 6 5 Chapter 7 Frame Objects E a AO 7 1 Addie an dt Edine T rane Objects diia 7 1 Constant Objects Bytes Wo tdy DWOR eranarar rrna 7 2 int IE Byte Word E A ado 7 3 IR a 7 4 variable DIOD GE AA AAA tose 7 4 CASCO Er AS A AS 7 6 Chapter 8 Commands A O 8 1 Addis Marais COMAS A A AA 8 1 ETB EN AS A SE EAN 8 2 NT E AAA eee a taal E ited na ae act eh Aaa iat 8 2 LAR ri A NN IN A O NON 8 3 Ear NA A AIT EE SIET O A EE mr 8 3 Dre IN AVION AAA A A SA AA 8 3 P a ELLA i ROE eee IRE ORT RCE RA TOR 8 4 COMERC AAA AAA ASADAS 8 5 Example Specifying a Modbus RTU Command in Master Mode sss 8 6 Table of Contents 4 Chapter 9 Sub Network Monitor Chapter10 Node Monitor A e o 10 1 Navisatino the Node Non Oria 10 2 STO OG N CHT A NN E
18. system is used to specify the different parts of the serial communication ABC Config Tool Untitled TOX File Transactions 1 Tools View Help D gt E x 4 Devices Configuration M Fieldbus Alphabetic Categorized ABC Wt Sub Network Nodel Read Coil Status Query CQ Response Diagnostics Query CQ Response Node2 pensor T Barcodereader SelectAll DeselectAll T Sensor Transactions 1 ad Frame Editor File Slave Address Function Starting Address HiLo Number of points HiLo Checksum Value Value Value Value Error check type Error check start byte 0x0000 0x0000 CRC 0x0000 Transactions 1 2005 10 27 09 39 Config Line YA DOFO 02F0 D4FO 0100 0300 0500 0110 0310 0510 0120 0320 0520 0130 0330 0530 0140 0340 0540 0150 0350 0550 0160 0360 0560 0170 0370 0570 0180 0380 0580 0190 0390 0590 O1A0 O3A0 05A0 0180 03B0 OSBO D1CO a3co asco 01D0 03D0 05D0 01E0 03E0 05E0 D1FO 03F0 OSFO 0600 v Trigger or Statusbytes Reserved Response S Collision Basic Operation 2 2 Data Exchange Model Internally the data exchanged on the sub network and the data exchanged on the higher level network resides ABC Internal Memory in the same memoty This means that in order to exchange data with the sub network the higher level network simply reads and writes data to memory locations specified using the ABC Config Tool The very same memoty locations can
19. the program is launched English Firmware Download Download firmware to the embedded field bus interface Warning Use with caution HDS Options ABC Config Tool ABC Size of logbuffer Apply Firmware Download Factory Restore Block Configuration Factory Restore Restores the gateway firmware to it s orig inal state does not affect the embedded fieldbus interface Block Configuration When selected the downloaded configu ration will not be executed by the gateway Warning Use with caution Create Error log Creates an error log file View Navigating the ABC Config Tool 3 4 This menu features the following entries Help View 7 Toolbar This entry enables disables the toolbar icons at the top of the v Toolbar main window we Status Bar Status Bar This entry enables disables the status bar at the bottom of the main window This menu features the following entries Contents search For Help On Contents Display the table of contents of the on line help system Note At the time of writing no on line help sys About tem exists R Search For Help On Search for a particular topic in the on line help system Note At the time of writing no on line help system exists About Display general information about the gateway and the current build of ABC Config Tool Navigating the ABC Config Tool 3 5 Toolbar
20. use this feature correctly the control system must first update the data area associated with the Query transaction then increase the trigger byte by one The location of the trigger byte is spec ified by the Trigger byte address parameter Update time 10ms This parameter specifies how often the transaction will be issued in steps of 10ms only rele vant when Update mode is set to Cyclically Transactions 6 3 Parameters Response To gain access to these parameters select a Response transaction in the Navigation Section Parameter Trigger byte Description This parameter is used to enable disable the trigger functionality for the response If enabled the gateway will increase the trigger byte by one when the gateway receives new data from the sub network This can be used to notify the control system of the updated data The location of the trigger byte is specified by the Trigger byte address parameter below Trigger byte address This parameter specifies the location of the trigger byte in the internal memory buffer Valid settings range from 0x000 Ox1FF and 0x400 OXNNN Transaction Parameters Generic Data Mode Produce Transactions To gain access to these parameters select a Produce Transaction in the Navigation Section Parameter Offline options for fieldbus Description This parameter specifies the action to take for this transaction if the higher level net
21. 7 32 0x002 0x003 255 4065 4080 0x1FC 0x1FD 256 4081 4096 0x1FE Ox1FF 257 1024 4097 16384 reserved 1025 16385 16400 0x200 0x201 Output Data area 1026 16401 16416 10x202 0x203 1279 20449 20464 0x3FC 0x3FD 1280 20465 20480 0x3FE 0x3FF Note Coils are mapped MSB first i e coil 0 corresponds to bit 15 of register 0 Supported Exception Codes Exception Code Name Description 0x01 Illegal function Function code not supported 0x02 illegal data address Invalid address in query 0x03 lllegal data value illegal data in request Navigating the ABC Config Tool Main Window Chapter 3 The main window in the ABC Config Tool can be divided in 4 sections as follows HDS ABC Config Tool Untitled File Fieldbus Tools View Help A ENS Devices A Fieldbus ABC Configuration Alphabetic Categorized E Ethernet TCP IP configuration Communicator IP address 192 168 0 1 Default Gateway 0 0 0 0 Subnet Mask 255 255 255 0 TCP IP Settings Enabled Fieldbus Fieldbus Type E 10 Sizes IO Sizes Automatic W Sub Network Y New Node L Read Holding Registers E Query El Response C Preset Multiple Regs El Query E3 Response Profinet lO G 10 Sizes Sets whether the sizes of the lO areas are user defined or automaticly configured 2005 10 24 A Pull down Menus amp Tool Bar The second drop d
22. FEh word 0x00000000 OxFFFFFFFEh dword Note Value must be less than the Maximum Value above Frame Objects 7 4 Data Object Data Objects are used to represent raw data as follows e Produce Query Transactions The specified data block is forwarded from the higher level network to the sub network e Consume Response Transactions The specified data block is forwarded from the sub network to the higher level network To specify the properties of the object select 1t in the Navigation Section enter the desired settings 10 the Parameter section as follows Parameter Description Byte Swapping e No Swapping No swapping is performed on the data e Swap 2 bytes A B C D becomes B A D C e Swap 4 bytes A B C D becomes D C B A Data Length The length of the data block in bytes In case of a Response or Consume transaction incom ing messages where the data size differs from the value specified here will be discarded Data Location The location of the data block in the internal memory buffer Variable Data Object Note Only one Variable Data Object is permitted for each transaction This object is similar to the Data Object except that it has no predefined length Instead an End or Length character specifies the size of the data block as follows Variable Data Object Variable Data Object Data of arbitrary length End Character Length Character 4 bytes of data e Produce Quety T
23. Furthermore each command always consists of a Query and a Response e Example Query DisplayName Slave Address Function Data Checksum Object Type Byte Object Byte Object Data Object Checksum Object Value SlaveAddress ID User User The value of this byte The value of this byte The size and location The checksum type constant will be set using the SlaveAd dress parameter see 5 1 Node Parame ters e Example Response Response DisplayName Slave Address constant will be set using the Command ID field Function of the data associated with this object is determined by the user Data etc can be selected by the user By default this is set to match the Modbus RTU stan dard Checksum Object Type Byte Object Byte Object Data Object Checksum Object Value SlaveAddress ID User Depend This value is linked to the SlaveAddress parameter in the parameter window The value of this byte constant will be set using the Command ID field The size and location of the data associated with this object is determined by the user This object will retrieve its settings from the correspond ing object in the Query By default the Modbus RTU specific frame objects are already in place and a data object is inserted between the function code and the CRC These objects cannot be moved or deleted however
24. Gateway Sub Network Devices Consume wd Produce Node 1 Produce p Consume Produce o Consume Node 2 Consume d Produce In the figure above the gateway Consumes data that is Produced by a node on the sub network This Consumed data can then be accessed from the higher level network This also works the other way around the data received from the higher level network is used to Produce a message on the sub net work to be Consumed by a node Basic Operation 2 6 Data Representation on Modbus RTU General The Input and Output Data areas are mapped to Modbus registers 0 1279 and Coils 0 20479 Supported Function Codes The following function codes are supported Function Code Modbus Function Associated with Area s 1 Read Coil Input and Output Data Area 0x000 Ox3FF 2 Read Input Discretes 3 Read Holding Registers 4 Read Input Registers 5 Write Coil Output Data Area 0x200 Ox3FF 6 Write Single Register 15 Force Multiple Coils 16 Force Multiple Registers 22 Mask Write Register 23 Read Write Registers Input and Output Data Area 0x000 Ox3FF Coil amp Register Map The Input amp Output Data areas are mapped to coils and registers as follows Register Coil Memory Location Area Comments 1 1 16 0x000 0x001 Input Data area 2 1
25. HMS a This led turns green when all transactions have been active at least once This includes any transactions using change of state or change of state on trigger If a timeout occurs on a transaction this led will turn red About the Anybus Communicator for Modbus RTU 1 4 Configuration Switches The configuration switches determines the basic communication settings for the Modbus interface Normally these switches are covered by a plas tic hatch When removing the hatch avoid touching the circuit boards and components If tools are used to open the hatch be cautious EE o EE v EE R a an Ho R o ES RS lt EE RS Note that these settings cannot be changed during runtime i e the gate way must be restarted in order for any changes to have effect Node Address Node Address Sw 1 Sw 2 Sw 3 Sw 4 Sw 5 Sw 6 Sw 7 reserved OFF OFF OFF OFF OFF OFF OFF 1 OFF OFF OFF OFF OFF OFF ON 2 OFF OFF OFF OFF OFF ON OF 126 ON ON ON ON JON ON OFF 127 ON ON ON ON ON ION JON Baudrate Configuration Baudrate Sw 8 Sw 1 Sw 2 reserved OFF OFF OFF 1200 bps OFF OFF ON 2400 bps OFF ON OFF 9600 bps ON OFF OFF 19200 bps standard ON OFF ON ela ON 38400 bps ON ON OFF 0 600 bps ON ON ON Parity amp Stop Bits Parity Sw 3 Sw 4 reserved OFF OFF No parity 2 stop bits OFF ON Even parity
26. If the higher level network uses a different byte order the upper and lower bytes will appear to be swapped Control Codes in Master Mode This table is valid only in Master Mode Code Instruction Data Description 0x00 Disable Node Actual node address Disables the specified node 0x01 Enable Node Actual node address Enables a previously disabled node 0x02 Enable Nodes Actual number of nodes to enable Enables the specified number of nodes start ing from the first node in the configuration Remaining nodes will be disabled Control Codes in Generic Data Mode No Control Codes are currently supported in this mode Chapter 14 Advanced Fieldbus Configuration General The fieldbus interface of the gateway consists of an embedded Anybus S communication interface Nor mally the Anybus S configuration settings are set up automatically by the gateway However advanced users can configure the Anybus S card for specific features This chapter assumes that the reader is fa miliar with the Anybus S and it s application interface For more information about the Anybus S plat form consult the Anybus S Parallel Design Guide The standard initialisation parameters are determined by the sub network configuration Information about the amount of input and output data used for sub network communication is used by ABC Con fig Tool to create the configuration message that sets the sizes of the input and output d
27. Single Coil Query Data Data object with 4 bytes The fieldbus master should enter Coil Address and Force Data in these four bytes Response Data Data object with 4 bytes The slave returns Coil Address and Forced Data in these 4 bytes Table 8 Force Single Coil 6 Preset Single Register Query Data Data object with 4 bytes The fieldbus master should enter Register Address and Preset Data in these four bytes Response Data Data object with 4 bytes The slave returns Register Address and Preset Data in these 4 bytes Table 9 Preset Single register HMS INDUSTRIAL NETWORKS AB 7 AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 7 Read Exception Status ee Data object with 1 byte The slave returns the 8 Exception Status Coils in this byte Table 10 Read Exception Status 11 Fetch Comm Event Counter CN T Response Data Data object with 4 bytes The slave returns Status and Event Count in these 4 bytes Table 11 Fetch Comm Event Counter 12 Fetch Comm Event Log CN 1 byte value where you enter the number of expected data bytes Data Data object with 6 70 bytes The slave returns Status Event Count Mes sage Count and the Event Log in these bytes Table 12 Fetch Comm Event Log 15 Force Multiple Coils Query Coil Address 2 byte value where you enter the reference of the first coil to be forced MO Quantity of Coils 2 byte value where you ente
28. TU based net works See also 12 2 Wizard Modbus RTU Master Blank Configuration This option creates an empty configuration 5 Select Configuration heath yk 4 L ABCC ExtLink Wizard Wizard Modbus Blank Configuration ATU Master Select the desired topic to do and press the OK button A Wizard option will guide you through and explain all steps of a configuration The output from a wizard will result in a working configuration ready to download It is also possible to edit the configuration in the standard configuration tool after Wizard completion The Blank Configuration option will open the standard configuration tool and a configuration can be created from scratch Here it is also possible to open an existing configuration from file or via upload from a Communicator module T Don t show this Window again Wizard Modbus RTU Master Configuration Wizards 12 2 This wizard can be used to create a Modbus RTU based network configuration based on certain infor mation about the sub network The on line help system explains each configuration step in detail e Important Notes Many OEM devices do not fully comply with the Modbus standard For example they may implement a variation of this standard or be limited to the use of specific Modbus commands other than the ones used by this wizard In all cases the user should consult the documentation of the device
29. The configuration switches determines the basic communication settings for the Modbus interface Normally these switches are covered by a plas tic hatch When removing the hatch avoid touching the circuit boards and components If tools are used to open the hatch be cautious E EE EH RS m a EE o ma o E E EE o RS RS Note that these settings cannot be changed during runtime i e the gate way must be restarted in order for any changes to have effect Node Address Node Address Sw 1 Sw 2 Sw 3 Sw 4 Sw 5 Sw 6 Sw 7 reserved OFF OFF OFF OFF OFF OFF OFF 1 OFF OFF OFF OFF OFF OFF ON 2 OFF OFF OFF OFF OFF ON IOF 126 ON ION ON ON JON ON OFF 127 ON ION ON ON ON ION JON Baudrate Configuration Baudrae Sw 8 Sw 1 Sw 2 o reserved OFF oF OFF 1200 bps OFF OFF ON 2400 bps OFF ON OFF 4800 bps OFF ON ON a 9600 bps ON OFF OFF HERH 19200 bps standard ON OFF ON ON ON 38400 bps ON ON OFF 97600 bps ON ON ON Parity 8 Stop Bits Parity Sw 3 Sw 4 reserved OFF OFF No parity 2 stop bits OFF ON Even parity 1 stop bit ON OFF Odd parity 1 stop bit ON ON Physical Interface Interface Type Sw 5 RS 485 OFF RS 232 ON Basic Operation 2 6 Data Representation on Modbus RTU General The Input and Output Data areas are mapped to Modbus registers 0 1279 and Coils 0
30. Tool Download configuration to ABC Upload configuration from ABC Download configuration to ABC start Logging Options Download the current configuration into the gateway Start Logging Start the Data Logger see 11 1 Data Logger Navigating the ABC Config Tool 3 3 Note that when the Data Logger is active this menu entry is changed to Stop Logging Options This will bring out the following window Item Description Warning on Delete A confirmation dialog is displayed each time something is deleted Warning on unsaved data A confirmation dialog is displayed when closing the ABC Config Tool with unsaved data Show Wizard when New menu is selected The Wizard is displayed each time a new configuration is created Language next time the program is launched Selects which language to use The new setting will be active the next time the pro gram is launched Selecting the ABC tab will reveal additional properties Item Description Size of logbuffer By default the Data Logger can log up to 512 entries in each direction If necessary it is possible to specify a different number of entries valid settings range from 1 512 Cick Apply to validate the new settings See also 11 1 Data Logger ABC Config Tool ABC Warning on Delete Warning on Unsaved Configuration Show Wizard Window when New menu is selecte Language nexttime
31. ata areas in the Dual Port RAM of the embedded Anybus S interface It is possible to add fieldbus specific mailbox mes sages to customize the initialisation This is done in the Mailbox Editor see below A mailbox message is a HMS specific command structure used for low level communication with an Anybus S interface Consult the Anybus S Parallel Design Guide and the fieldbus appendix for the de sired fieldbus for further information Mailbox Editor 2 Fieldbus To add a mailbox message to the configuration right click on T startinit c gt c gt o bet Fieldbus specific EndInit and select Insert New Mailbox o UE pen P ABC Insert New Mailbox eh WA Sub Network A mailbox message consists of a Header sec smmm all tion and a data section where the Header con ra Saa Se sists of 16 words 32 bytes and the data 0 7 Z section consists of up to 128 words 256 gt 7 Z i bytes All fields are editable except the Mes E sage information field that 1s fixed to 0x4002 oe E 7 which means that only fieldbus specific mail Ex 0x10 0x00 0x11 0xF0 box messages can be entered here E 0x13 0x10 The mailbox message is presented as two col umns one contains header information A T Allow userto enable disable the other one contains the message data B To add message data simply change the Data size parameter in the header column A and the corresponding number o
32. aximum power consumption is 280mA on 24V Typically around 100mA Environmental Characteristics Relative Humidity The product is designed for a relative humidity of 0 to 95 non condensing Temperature Operating 10 C 10 55 C Non Operating 25 C to 85 C Regulatory Compliance EMC Compliance CE Technical Specification B 2 This product is in accordance with the EMC directive 89 336 EEC with amendments 92 31 EEC and 93 68 EEC through conformance with the following standards EN 50082 2 1993 EN 55011 1990 EN 61000 6 2 1999 EN 61000 4 3 1996 EN 61000 4 6 1996 EN 61000 4 2 1995 EN 61000 4 4 1995 EN 61000 4 5 1995 UL c UL compliance Class A 10V m 10V m all ports 8kV Air Discharge 4kV Contact discharge 2kV Power port TIKV Other ports 0 5kV Power ports DM CM 1kV Signal ports The certification has been documented by UL in file E214107 Appendix C Troubleshooting Problem Solution Problem during configuration Upload Download Serial communication failed Try again The Config Line led turns red in the ABC Config Tool The serial port seems to be available but it is not possible The serial port may be in use by another application to connect to the gateway Exit the ABC Config Tool and close all other applica tions including the ones in the system tray Try again e Select another serial port Try again Poor performance e Right click Sub Net
33. be disconnected in case the maximum number of retries below has been reached The unit is milliseconds ms and the entered value is multiplied by 10 which means that the shortest time is 10 ms Note This setting is not relevant for the Broadcaster node This parameter specifies how many times a timeout may occur in sequence before the node is disconnected Timeout time 10ms This parameter specifies how long the gateway will wait for a response from a node If this time is exceeded the gateway will re transmit the Query until the maximum number of retries see above has been reached The unit is milliseconds ms and the entered value is multiplied by 10 which means that the shortest time is 10 ms Trigger byte address This parameter specifies the location of the trigger byte in internal memory only relevant when Update mode is set to Change of state on trigger Update mode This parameter is used to specify when the transaction shall be sent to the slave e Cyclically The transaction is issued cyclically at the interval specified in the Update time parameter e On data change The transaction is issued each time the data area associated with the transaction has changed Single shot The Query is issued once at start up e Change of state on trigger The Query is issued when the trigger byte value has changed This feature enables the control system to notify the gateway when to issue a particular Query To
34. ce Guide PI MBUS 300 Abbreviations Important abbreviations used in this manual Abbreviation Description AnyBus Communicator Configuration Software HMS INDUSTRIAL NETWORKS AB 3 AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 1 Appendix for Modbus 1 1 Introduction When configured for Modbus protocols the AnyBus Communicator supports Modbus RTU Modbus ASCII and Modbus Generic Some basic knowledge is needed as to understand how to use the Anybus C for configuration of the Modbus network The Modbus standard was created by Modicon for communication between controllers and other devices The trans actions on the Modbus network are of master slave type and are named query and response One single master sends the queries All transactions on the network have got a frame structure where one part is common for both Modbus RTU and Modbus ASCII This is illustrated in figure 1 Figure 1 Modbus frame layout The main difference between Modbus RTU and Modbus ASCII is that in RTU all hexadecimal values are represented with one byte and in ASCII they are represented with two bytes Another difference is the start and stop signs that envelope the frame Modbus RTU Each byte in the Modbus RTU message represents a hexadecimal value between 0 and 255 The frame looks exactly like the one mentioned earlier and there is always an interval of 3 5 silent characters between the fram
35. des on the network are not permitted to issue messages unless they have been addressed by the gateway first For more information about this mode see 2 5 Master Mode Generic Data Mode In this mode there is no master slave relationship between the sub network nodes and the gate way any node on the sub network including the gateway may spontaneously produce or con sume messages For more information about this mode see 2 5 Generic Data Mode Protocol Building Blocks The following building blocks are used in ABC Config Tool to describe the sub network communica tion How these blocks apply to the two protocol modes will be described later in this document Nodes A node represents a single device on the sub network Each node can be associated with a number of Transactions see below Transactions A Transaction represents a complete serial telegram and consists of a number of Frame Objects below Each Transaction is associated with a set of parameters controlling how and when to use it on the sub network Commands Commands are simply pre defined Transactions stored in the ABC Config Tool This simplifies common operations by allowing Transactions to be stored and re used Frame Objects Frame Objects are low level entities used to compose Transactions see above A Frame Object can represent a fixed value a constant a range of values limit objects a block of data or a cal culated checksum
36. directly Protective Earth PE of other nodes may in case of grounding loops etc cause damage to the on board serial transceivers lt is therefore generally recommended to connect it only to Signal Ground if available of other nodes Connector Pin Assignments A 4 Typical Connection RS485 5V RS485 RS485 RS485 RS485 Signal Signal Ground y Ground QnA D JD QM D JD QnA D JD QM D 2 s e e gee Q gee Q gee e Cable 225 a 223 a 22 a BFS A Shield S id Anybus Communicator Node Node Node Node End Node Typical Connection RS422 amp 4 Wire RS485 i 3 RS422 Rx L RS422 Txt 3 i I 1 I 1 RS422 Rx L RS422 Tx I I 470R pon I I RS422 Txt RS422 Rx 120R RS422 Tx RS422 Rx I 1 470R i 1 I Signal Signal Ground y Ground Cable Shield Anybus Communicator Device Note Bias resistors are normally not needed on RS422 but may be required when using 4 wire R5485 Typical Connection RS232 RS232 Tx RS232 Rx no a I 1 I 1 1 1 RS232 Rx RS232 Tx I I i I Signal Signal Ground y Ground Cable Shield Anybus Communicator Device Connector Pin Assignments A 5 Appendix B Technical Specification Mechanical Properties Housing Plastic housing with snap on connection to DIN rail protection class IP20 Dimensions 120 mm x 75 mm x 27 mm Lx W x H inches 4 72 x 2 95 x 1 06 Lx W x H Electrical Characteristics Power Supply Power 24V 10 Power Consumption M
37. e The selected Command Query Transaction is sent to the sub network The response to the Query can be monitored in the Response Section Monitor New Node File Node Command Columns View BeZ BS Command Section Query Sub network Response Section In Area 1 bytes 512 Out Area 1 bytes 512 General Area 0 bytes 1022 ooo DU e Generic Data Mode The selected command Transaction Produce 15 sent to the sub network It is not possible to monitor any responses etc generated by other nodes EO Monitor New Node File Node Command Columns View BESS ws Command Section Produce Sub network Not used In Area 1 bytes 512 Out Area 1 bytes 512 General Area 0 bytes 1022 Node Monitor 10 2 Navigating the Node Monitor Monitor New Node File Node mmand Columns View E eW Read Coil Status Query Slave Address Function Starting Address Hi Lo Number of points HiLo Checksum Value Value Value Error check type Error check start byte G 0x0000 0x0000 CRC Ox0000 Read Coil Status Response Slave Address Function Byte count Checksum In Area 4 bytes 512 Out Area 16 bytes 512 General Area 0 bytes 1004 0 oo 08 DiooDnDonDonDoDoDonDonoonDon on N N A Pull down Menu amp Toolbar Icons See 10 3 Pull Down Menu and 10 4 Toolbar Icons B Command Section This section holds the currently selected command The individual frame objects in the com mand ca
38. e 8 MB RAM Screen resolution of 800x600 16 bit colour or higher Microsoft Windows NT4 2000 XP Internet Explorer 4 01 SP1 or newer Installation Anybus Communicator resource CD Insert the CD and follow the on screen instructions If the installation does not start automati cally right click on the CD drive icon and select Explore Execute setup exe and follow the on screen instructions From website Download and execute the self extracting exe file from the HMS website www anybus com Chapter 2 Basic Operation General The Anybus Communicator gateway is designed to exchange data between a serial sub network and a higher level network in this case Modbus RTU Unlike most other gateway devices of similar kind it does not have a fixed protocol for the sub network and can be configured to handle almost any form of serial communication The gateway can issue serial telegrams cyclically on change of state or based on trigger events issued by the control system of the higher level network i e the fieldbus master or PLC It can also monitor cer tain aspects of the sub network communication and notify the higher level network when data has changed An essential part of the Anybus Communicator package is the ABC Config Tool a Windows appli cation which is used to supply the gateway with a description of the sub network protocol No program ming skills are required instead a visual protocol description
39. elow The trigger byte value will be increased each time a valid transaction has been consumed by the gateway This feature enables the control system to be notified each time new data has been consumed on the sub network Disable Disables the trigger byte functionality Trigger byte address This parameter specifies the location of the trigger byte in the internal memory buffer Valid settings range from 0x000 Ox1FF and 0x400 OXNNN Transaction Editor Transactions 6 5 The Transaction Editor can be used to edit the individual Frame Objects of a Transaction The same settings are also available in the Parameter Section of the Main Window however the Transaction Editor presents the Frame Objects in a more visual manner S Transz on Editor File Byte constant Word constant Data Value Value Data location Data length 0x00 0x0000 0x0200 0x0010 Transaction Ef Byte constant E a constant Frame _f Checksum Objects Y Byte constant COX Checksum Byte constant Error check type Error check start byte Value CRC 0x0000 0x00 To edit the value of a parameter click on it and enter a new value using the keyboard When editing transactions which are based on pre defined commands certain parts of the transaction may not be ed itable The File menu features the following entries Apply Changes Exit Ctrl Q Example Transaction Editor File Byte constant Word constant Data Value
40. es CRC Cycli cal Redundancy Check is used for error checking Multiple Modbus transactions would appear on the physical inter face like this silent transaction 1 silent transaction 2 silent transaction 3 silent SSA Figure 2 Modbus RTU transactions Modbus ASCII Each byte in the Modbus ASCII message represents one hexadecimal digit 1 e 0 9 A F This means that two bytes are used to represent each hexadecimal value 0x00 OxFF For example the value 0x2A is represented like this Ist byte 2 0x32 2nd byte A 0x41 Start and stop characters are added to the frame from Figure 1 A colon is used as start character and CR LF are used as stop characters Longitudinal Redundancy Check LRC is used for error checking A complete Modbus ASCII transaction would appear on the physical interface like this Start Address Function Data Error check Stop QA ANMAT ee 5 Figure 3 Modbus ASCII transactions A HMS INDUSTRIAL NETWORKS AB AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 1 2 AB C as Modbus master When the AB C acts as master on the Modbus network it uses a scan list for communication with the different slaves on the network as described in the Sub network Master section The scan list is defined using AbcCon When Mod bus protocol is selected you add pre defined modbus commands to the scan list simply by selecting them from a list The next chapter describes a
41. es and illustrations in this document are included solely for illustrative purposes Because of the many variables and requirements associated with any particular implementation HMS cannot as sume responsibility or liability for actual use based on these examples and illustrations Warning This is a class A product In a domestic environment this product may cause radio interfer ence in which case the user may be required to take adequate measures ESD Note This product contains ESD Electrostatic Discharge sensitive parts that may be damaged if ESD control procedures are not followed Static control precautions are required when handling the product Failure to observe this may cause damage to the product Related Documents About This Document P 2 Document name Author ABC RTU Installation Leaflet HMS Document History Summary of Recent Changes 2 52 2 53 Change Page s Corrected switch information Physical Interface 1 4 Misc corrections and adjustments Revision List Revision Date Author Chapter Description 2 00 2005 08 25 PeP All Second major release 2 50 2006 04 05 PeP All Major update 2 51 2006 06 01 PeP Minor corrections 2 52 2006 12 22 PeP Minor corrections 2 53 2007 11 23 PeP All Minor updates About This Document P 3 Conventions amp Terminology The following conventions are used throughout th
42. eters To gain access to the parameters described in this section select a node oe Fieldbus in the Navigation Section le ABC RV suUb Metwark Y Broadcaster Slave Address The value entered here may be used to set the node E Llew Moce address in certain commands For more information see 8 3 The Command Editor Chapter 6 Transactions General As mentioned previously transactions are representations of the actual serial telegrams exchanged on the serial sub network While the gateway doesn t feature a scanlist in the traditional sense all nodes and their transactions will be processed in the order they have been defined in the ABC Config Tool Transactions are handled slightly differently in the two protocol modes e Master Mode For regular nodes transactions always come in pairs a Query and a Response The Query is is sued by the gateway while Responses are issued by the slaves on the sub network The Broad caster can only send transactions e Generic Data Mode Transactions can be added as desired for both directions Transactions sent to the sub network are called Transaction Produce and transactions issued by other nodes are called Transaction Consume Theoretically the gateway supports up to 100 transactions The actual number may however be less de pending on the memory requirements of the defined transactions Right click on a node in the Navigation Section t
43. eway towards the fieldbus control system bit s Name Description 15 Send These bits control the handshaking towards the fieldbus control system SR_HS_SEND 14 Confirm See also SR_HS_CONFIRM 13 1 Handshaking Procedure 13 5 Control Register Contents Control System to Gateway 13 Data Valid This bit is set when all transactions have been executed successfully at least once Master Mode Only Once set it will not change 1 Data Valid 0 Data not Valid Note This bit is not used in Generic Data Mode 12 8 Status Code This field holds the last status report from the gateway 0 Data See also 13 3 Status Codes in Master Mode 13 4 Status Code in Generic Data Mode Note Internally this is treated as a Motorola format word 1 e MSB first If the higher level network uses a different byte order the upper and lower bytes will appear swapped Status Codes in Master Mode This table is valid only in Master Mode Code Condition Type DELE Description 0x00 Re transmission Warning Counter The number of re transmissions on the sub Counter Updated network has increased If this problem per sists this may eventually trigger a Single or Multiple Node s Missing condition 0x01 Single Node Missing Error Slave address A single node is missing 0x02 Multiple Nodes Missing Error Number of nodes Multiple nodes are missing 0x03 Buffer Overrun Warning S
44. f bytes will ap pear in the message data column B For more information about fieldbus specific mailbox messages consult the separate Anybus S Fieldbus Appendix for the fieldbus you are using For general information about the Anybus S platform consult the Anybus S Design Guide Connector Pin Assignments Fieldbus Connector Modbus RTU Pin Signal Description Housing Shield Bus cable shield connected to PE 1 2 TxD Transmit data RS 232 3 RxD Receive data RS 232 4 5 GND Ground galvanically isolated 6 5V 5V galvanically isolated 7 A A Line RS 485 8 B B Line RS 485 9 CAN_V Opional CAN external power supply Power Connector Pin Description 1 24V DC 2 GND Notes Use 60 75 or 75XC copper CU wire only The terminal tightening torque must be between 5 7 lbs in 0 5 0 8 Nm Appendix A female PC Connector Configuration Cable Wiring DP9F PC RJ11 ABC Pin Description 1 Signal ground 2 3 RS232 Rx Input 4 RS232 Tx Output DB9F PC Pin Description RS232 Rx Input RS232 Tx Output Signal Ground 1 2 3 4 5 6 9 Connector Pin Assignments A 2 RJ11 ABC 5 female 1 Connector Pin Assignments A 3 Sub network Interface General Information The sub network interface provides for RS232 RS422 and RS485 communications Depending
45. followed by a No Error condition when the cause no longer is detected Conditions of type Warning are however considered informational and may not necessarily be followed by a No Error condition later on Control and Status Registers 13 5 Control Register Contents Control System to Gateway General Information As mentioned previously the Control Register can be used to synchronize data exchange and instruct the gateway to perform certain tasks related to the sub network communication bit s Name 15 Confirm CR_HS_CONFIRM 14 Send CR HS SEND Data Valid Description These bits control the handshaking towards the gateway See also 13 1 Handshaking Procedure 13 3 Status Register Contents Gateway to Control System This bit controls data consistency see 13 2 Data Consistency 1 Output Area valid exchange data on the sub network 0 Output Area not valid do not exchange data on the sub network Note This bit is only relevant if the Control Status Registers are set as Enabled Execute Command If set the specified command will be executed by the gateway see below Control Code Data This field holds commands which can be executed by the gateway see below See also 13 5 Control Codes in Master Mode 13 5 Control Codes in Generic Data Mode Note Internally this is treated as a Motorola format word 1 e MSB first
46. ght click on the Transac tion in the Navigation Section and select one of the entries in the menu that appears The entry called Transaction Editor will launch the Transaction Editor which is used to edit transactions and frame objects in a more visual manner For more information see 6 5 Transaction Editor Configuration Alphabetic Categorized E General Data length 0x0001 Data location 0x0200 Byte swap No swapping Data Object Parameters action Editor 8 Fieldbus a ABC 4 Sub Network R New Node 3 0 Transactions 1 E Lp ED E Edit Transaction Add Data Add Variable Data Add Checksum Add Byte Constant Add Word Constant Add DWord Constant Add Byte Limits Add Word Limits Add DWord Limits Rename St To edit parameters associated with a particular frame object select the frame object in the Navigation Section The settings for that frame object will be displayed in the Parameter Section It is also possible to edit the frame objects in a transaction in a more visual manner using the Transaction Editor see 6 5 Trans Frame Objects 7 2 Constant Objects Byte Word Dword Constant Objects have a fixed value and come in three sizes e Byte 8 bits e Word 16 bits e Dword 32 bits Constants are handled differently depending on the direction of the transaction e Produce Quetry Transactions The gateway will send the value as it is without proce
47. he Navigation Section Parameter Minimum time between broadcasts 10ms Description This parameter specifies how long the gateway shall wait after transmitting a broadcast trans action before processing the next entry in the scanlist The value should be set high enough to allow the slave devices time to finish the handling of the broadcast The unit is milliseconds ms and the entered value is multiplied by 10 which means that the shortest time is 10 ms Note This setting is only relevant for the Broadcaster node Offline options for field bus This parameter specifies the action to take for this transaction if the higher level network goes off line This affects the data that is sent to the sub network e Clear The data destined for the slave devices is cleared set to zero Freeze The data destined for the slave device is frozen e NoScanning The updating of the sub network is stopped Offline options for sub network This parameter specifies the action to take for this transaction if the sub network goes off line This affects the data that is reported to the control system e Clear Data is cleared 0 on the higher level network if the sub network goes offline e Freeze Data is frozen on the higher level network if the sub network goes offline Reconnect time 10ms Retries This parameter specifies how long the gateway shall wait before attempting to re connect a disconnected node A node will
48. he command Each column represents a frame object within the transaction Each column features four rows with the following parameters Query Response Produce Consume The upper right cell indicates the direction of the transaction DisplayName Each column can be named so that the different parts of the command appears in a more user friendly manner when editing its settings in the Transaction Editor or in the Parameter Section of the Main Window ObjectType This row specifies the type of frame object that shall be used for the column Value This row specifies where the frame object shall retrieve its value settings Value Description Depend This setting is only relevant for Responses in Master Mode The value will be retrieved from the corresponding part of the Query transaction ld The value will be retrieved from the Command ID setting see 8 3 Basic Navigation User The settings associated with the object can be edited by the user SlaveAddress The value will be retrieved from the SlaveAddress parameter see 5 1 Node Parameters other settings Other settings are no longer supported 8 6 Commands Example Specifying a Modbus RTU Command in Master Mode In the following example a Modbus RTU command is created in Master Mode In Modbus RTU a transaction always feature the following parts e Slave Address 1 byte e Function Code 1 bytes e A data field e CRC CRC 16
49. in access to the parameters described in this section select Sub Net work in the Navigation Section Communication These parameters specify the actual communication settings used for the sub network Parameter Description Valid Settings Bit rate Selects the bit rate 1200 57600 Data bits Selects the number of data bits 7 8 Parity Selects the parity mode None Odd Even Physical standard Selects the physical interface type RS232 RS422 RS485 Start bits Number of start bits 1 Stop bits Number of stop bits 1 2 Start and End Character Note These parameters are only available in Generic Data Mode Start and end characters are used to indicate the beginning and end of a serial message For example a message may be initiated with lt ESC gt and terminated with lt LF gt In this case the Start character would be 0x1B ASCII code for lt ESC gt and the End character 0x0A ASCII code for lt LF gt Parameter Description Valid settings End Character Value End character for the message ASCII 0x00 OxFF Use End Character Determines if the End character shall be used or not Enable Disable Start Character Value Start character for the message ASCII 0x00 OxFF Use Start Character Determines if the Start character shall be used or not Enable Disable Timing Message Delimiter The parameters in this category differs slightly between the different Protocol Modes
50. ing to the sub network configu ration 3 Wait until the fieldbus control system R Online not yet exchanging data and the gateway are online on the field bus network and shift to state B B Online Not yet exchanging data 4 Wait until the Data Valid bit in the Status Register is cleared by the gate C way Online x Pog exchanging data 5 Set the Data Valid bit in the Control Register 6 When the Data Valid bit in the Status Register is set by the gateway shift to state C 7 If the gateway goes offline on the fieldbus shift to state A C Online Exchanging data Exchanging valid data in both directions If the gateway goes offline on the fieldbus shift to state A Note The gateway cannot spontaneously clear the Data Valid bit in the Status Register Latency The Data Valid bit in the Status Register may in some cases be delayed This latency can be caused by a missing node or a bad connection to a node with a long timeout value assigned to it Therefore the fieldbus control system should not wait for this bit to be set before communicating with the sub network devices it should be considered as an aid for the fieldbus control system to know when all data has been updated Control and Status Registers 13 3 Status Register Contents Gateway to Control System General Information As mentioned previously the Status Register indicates the current status of the gat
51. is document e Numbered lists provide sequential steps e Bulleted lists provide information not procedural steps e The term user refers to the person or persons responsible for installing the Anybus Communi cator in a network e The term gateway refers to the Anybus Communicator e Hexadecimal values are written in the format OxNNNN where NNNN is the hexadecimal value e Decimal values are represented as NNNN where NNNN is the decimal value e As in all communication systems the terms input and output can be ambiguous because their meaning depend on which end of the link is being referenced The convention in this doc ument is that input and output are always being referenced to the master scanner end of the link Glossary Term Meaning ABC Anybus Communicator Broadcaster A protocol specific node in the configuration that handles transactions destined to all nodes RTU Modbus RTU Command A pre defined transaction Configuration List of configured nodes with transactions on the sub network Fieldbus The higher level network to which the communicator is connected Fieldbus Control System Fieldbus master Frame Object Low level entities which are used to describe the different parts of a Transaction Monitor A tool for debugging the gateway and the network connections Node A device in the configuration which defines the communication with a node on the sub network The
52. it is pos sible to add additional objects between the function code and the CRC as desired Name the new command by entering it s name in the Command Name field and enter a suitable func tion code in the Command ID field If the command is allowed to be broadcasted check the Allow Broadcasting checkbox Chapter 9 Sub Network Monitor General The Sub Network Monitor 15 intended to simplify configuration and troubleshooting of the sub net work It s main function is to display the data allocated for sub network communication and detect 1f any area has been allocated twice 1 e if a collision has occurred All configured nodes and their transactions are listed in the middle of the screen B Selecting and de selecting single transactions makes it possible to view any combination of allocated data Note The sub network monitor has a negative influence on the overall performance of the gateway Therefore the monitor functionality should be used with care Operation HDS Sub network Monitor File Columns Y Y Nodel SelectAll Deselect All Read Coil Status Response Node2 Barcodereader Sensor SelectAll DeselectAll SelectAll DeselectAll SelectAll DeselectAll ead Coil Status E Transactions 1 M Transactions 1 tead Coil Status Out Area 0 bytes 512 General Area 0 bytes 989 G G G9 G G 2 22 G G9 G G 52 LH Sa Collision Trigger or Statusbytes Reserved
53. itor Section Fee 8 Multiple e Free The number of columns depends on the width of the window s 8 Multiple The number of columns will be fixed to 8 View This menu specifies the data representation in the Monitor Section Display the data in hexadecimal format we Hex Decimal e Decimal Display the data in decimal format Toolbar Icons The toolbar features icons for the most commonly used functions e Start Node Stop Node These icons corresponds to the functions in the Node menu See also 10 3 Node e Select Command amp Send Command These icons corresponds to the functions in the Command menu See also 10 3 Command Resume Refresh amp Stop Refresh When enabled the data displayed in the Monitor Section will be re freshed cyclically When disabled 1 e stopped the data will have to be refreshed manually using the Refresh icon see below Node Monitor 10 4 y Start Stop Select Send B 2 Stop Resume e Refresh When clicking on this icon the data displayed in the Monitor Section will be re C freshed Refresh Chapter 11 Data Logger General This feature allows the sub network traffic to be logged into a buffer for examination This may provide valuable information when debugging the lowest levels of the sub network communication Note that the logger function is part of the gateway itself and is separate from the ABC Config To
54. lave address A node returned more data than expected 0x04 Other Error Error Slave address Undefined error Ox1F No Error Warning No errors Note Conditions of type Error will eventually be followed by a No Error condition when the cause has been resolved Conditions of type Warning are however considered informational and may not nec essarily be followed by a No Error condition later on Status Code in Generic Data Mode This table is valid only in Generic Data Mode Condition Control and Status Registers 13 4 Description 0x00 Invalid Transaction Error Counter The number of invalid transactions i e received transac Counter Updated tions which doesn t match any of the Consume transac tions defined in the sub network configuration has increased 0x01 Frame Error Warning End character is enabled but a message delimiter timeout occurs prior to receiving it 0x02 Offline Timeout Error Counter The of number of timed out Consume transactions has Counter Updated increased See also 6 4 Consume Transactions Offline timeout time 0x03 Buffer Overrun Warning A node returned more data than expected or the gate way was unable to finish processing a message prior to receiving a new one 0x04 Other Error Error Undefined error Ox1F No Error Warning No errors Note Conditions of type Error will eventually be
55. ll the supported Modbus commands and what you need to think about when using them in the AB C What makes the AB C Modbus specific is the way transactions are used in Modbus commands and what the transac tions consist of One important issue in the AB C is that the data must be of a pre defined length The example below shows how this works Basically if we exclude the start character and stop character in the Modbus frame each Modbus frame consists of two one byte objects one data object maybe some more one or two byte objects and one error check object Lets take an example using Modbus RTU Example Read Holding Register 0x03 to node 0x05 This command is built up like this Query AB C frame One byte One byte Two byte object Two byte object Error check object object object Table 1 Query What you as a user must do here is to enter Starting address and No of points These two parameters are repre sented as two byte objects that you enter values into using AbcCon This command will ask the slave for the same registers every time the command is sent and unless something goes wrong the slave will answer with the same amount of data every time Response AB C frame One byte One byte One byte object Data Object Error check object object object Table 2 Response In the response the data section in the Modbus frame needs to be filled in Here the data section is represented
56. mind that the memory locations occupied by these registers cannot be used for regular data exchange Handshaking Procedure A special handshaking procedure which is illustrated in the two flowcharts below must be followed when accessing these registers to ensure that both parts receive proper information Read Status Register Write to Control Register CR_HS_CONFIRM a SR_HS_CONFIRM m SR_HS_SEND CR_HS_SEND ka Yes Read Status Register Write to Control Register Set CR_HS_CONFIRM to SR_HS_SEND Toggle CR_HS_SEND Control and Status Registers 13 2 Data Consistency The Data Valid bits in the Control and Status Registers are used to ensure data consistency during start up and fieldbus off line on line transitions If the Status Control Word parameter in ABC Config Tool is set to Enabled the gateway will wait for the fieldbus control system to set the Data Valid bit in the Control Register before it starts exchang ing data on the sub network If the same parameter is set to Disabled or Enabled but no startup lock communication will start as soon as the fieldbus goes online State Machine The fieldbus network participation can be described using a state machine as described below A Offline No data exchange 1 Clear the Data Valid bit in the Con trol Register A Offline no data exchange Start 2 Write initial data to the Output Area accord
57. n be edited in a similar way as in the Transaction and Command Editors C Response Section Master Mode only This section holds the response to the selected Command z Monitor Section This section displays the data associated with the node Areas in dark grey are reserved for the Status amp Control Registers and areas displayed in light grey represents the data that is used by the node The data displayed in this section will be refreshed based on the refresh icons in the toolbar For more information see 10 4 Toolbar Icons Node Monitor 10 3 Pull Down Menu File There is only one entry in this menu pa CA This will close the Node Monitor Note however that if the node has Exit been disabled using Stop Node see below it will not resume data exchange until enabled again using Start node Node This menu controls the data exchange for the node This feature can Node help isolate problems associated with a particular node Start Node Stop Node e Start Node Enable the transactions associated with the node e Stop Node Disable the transactions associated with the node Command This menu is used to specify and issue a command manually e Select Command Select a command to be sent on the sub network Command K e Send Command select Command Send the specified command to the sub network send Command Columns This menu specifies the number of columns in the Mon
58. n this document The product and technology described in this document is patent pending in the following countries USA Canada Japan Belgium Denmark Finland France Greece Ireland Italy Luxemburg Monaco Netherlands Portugal Switzerland Lichtenstein Spain United Kingdom Sweden Germany and Austria ANYBUS is a registered trademark of HMS Industrial Networks AB All other trademarks are the property of their respective holders HMS INDUSTRIAL NETWORKS AB AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 About the AnyBus Communicator Modbus Appendix This fieldbus appendix contains fieldbus specific information about the Modbus protocol for the AnyBus Communi cator For more information about the AnyBus Communicator please refer to the AnyBus Communicator User Man ual DOC ABC UM If technical support is required please contact the AnyBus Support Centre Europe Sweden Phone 46 0 35 17 29 20 E mail support hms se Germany Phone 49 721 96472 0 E mail ge support hms networks com North America Phone 1 773 404 2271 Toll Free 888 8 ANYBUS E mail us support hms networks com Japan Phone 81 45 478 5340 E mail jp support hms networks com Conditions for trademark use Please contact HMS for further information Related documents Document name Author Document ID Revision AnyBus Communicator User Manual Edk MaB ABC UM Modbus Protocol Referen
59. network that is logically located on a subsidiary level with respect to the fieldbus and to Sub network which the Anybus Communicator acts as a gateway Transaction A generic building block that is used in the sub network configuration and defines the data that is sent and received on the sub network User Person or persons responsible for installing the Anybus Communicator Higher Level Network In this case Modbus RTU Network Fieldbus About This Document P 4 Support For technical support consult the online FAQ www anybus com or contact the nearest support centre HMS Sweden Head Office E mail support hms networks com Phone 46 0 35 17 29 20 Pax 46 0 35 17 29 09 Online www anybus com HMS America E mail us suppott hms networks com Phone 1 773 404 2271 Toll Free 888 8 Anybus Pax 1 773 404 1797 Online www anybus com HMS Germany E mail ge suppott hms networks com Phone 49 721 96472 0 Fax 49 721 964 7210 Online www anybus com HMS Japan E mail jp support hms networks com Phone 81 45 478 5340 Pak 81 45 476 0315 Online www anybus com Chapter 1 Aboutthe Anybus Communicator for Modbus RTU The Anybus Communicator for Modbus RTU acts as a gateway between virtually any serial application protocol and a Modbus RTU based network Integration of industrial devices is enabled without loss of functionality control and reliability both when retro fitting to existing e
60. o gain access to these functions Adding amp Managing Transactions Function Description Cut Cut a node to the clipboard Copy Copy a node to the clipboard Insert Insert a node from the clipboard Delete Delete a node Node Monitor Add Transaction s Launch the node monitor 10 1 Node Monitor On regular nodes this adds a Query and a Response The two transactions will be grouped in order to increase readability On the Broadcaster a single transaction will be added Add Transaction Consume Add transaction Produce b Add a Consume transaction Add a Produce transaction Add Command Add pre defined transactions to the node Insert New Node Insert a new node above the currently selected one Save Node Insert from File Save the selected node Insert a previously saved node above the currently selected node Rename To increase readability each node can be given a unique name using this function a Only available in Master Mode b Only available in Generic Data Mode Fieldbus d ABC KE Sub Network TIA 9 8 N Cut Copy Insert Delete Node Monitor Add Transaction Consume Add Transaction Produce Add Command Insert New Node Save Node Insert from File Rename Transactions 6 2 Transaction Parameters Master Mode Parameters Query 8 Broadcast To gain access to these parameters select a Query or Broadcast transaction in t
61. o start the sub network communication Disabled This setting completely disables the Control and Status Registers Module Reset This parameter specifies how the gateway will behave in the event of a fatal error Value Description Enabled The gateway will be restarted and no error will be indicated to the user Disabled The gateway will halt and indicate an error Protocol Mode This parameter specifies which protocol mode to use for the sub network Value Description Generic Data Mode This mode is primarily intended for Produce 8 Consume based protocols where there are no Master Slave relationship between the gateway and the nodes on the sub network Master Mode This mode is intended for Query amp Response based protocols where a single Master exchanges data with a number of Slaves See also 2 4 Protocol Modes Statistics The Transmit and Receive Counters indicate how many transactions that have successfully been ex changed on the sub network This feature primarily intended for debugging purposes e Receive Counter Location Specifies the location of the Receive Counter in the internal memory buffer e Transmit Counter Location Specifies the location of the Transmit Counter in the internal memory buffer Both counters are enabled by setting Statistics to Enabled Basic Settings 4 1 Sub Network Parameters 8 Fieldbus A ABC SLI Sub Metwark To ga
62. ol This means that logging can be performed even if the gateway is physically disconnected from the PC running the ABC Config Tool Operation Start amp Stop Logging e Start logging Select Start Logging in the Tools menu ABC Config Tool will then prompt for the desired mode of operation see below e Stop logging Select Stop Logging in the Tools menu This will open the log window see below Modes of Operation Select the desired mode of operation and click OK to start logging data e Log until full Data will be logged until the log buffer is full e Log continuously Data will be logged continuously until logging is stopped by clicking Stop Logging The log buffer will contain the most recent data Log Window The logged data is displayed in Hexadecimal Decimal and ASCI format for both directions The time between the log entries is displayed in a separate column The data may optionally be saved in ASCII text format by clicking Create Text file Click Close to exit Y se E Create Text file Data Logger 11 2 Configuration By default the log buffer can hold 512 bytes of data in each direction To specify a different size for the buffer select e ABC Options in the Tools menu Size ofloghutr 512 Apply A window with various settings will appear Select the ABC Download Firmware tothe Anus tab and enter the
63. on the configuration specified in the ABC Config Tool different signals are activated in the sub network con nectot Bias Resistors RS485 Only When idle RS485 enters an indeterminate state which may cause the serial receivers to pick up noise from the serial lines and interpret this as data To prevent this the serial lines should be forced into a known state using pull up and pull down resistors commonly known as bias resistors The bias resistors forms a voltage divider forcing the voltage between the differential pair to be higher then the threshold for the serial receivers typically gt 200mV Note that bias resistors shall only be installed on one node installing bias resistors on several nodes may compromise the signal quality on the network and cause transmission problems Termination RS485 amp RS422 Only To avoid reflections on the serial lines it is important to properly terminate the sub network by placing termination resistors between the serial receivers near the end nodes The resistor value should ideally match the characteristic impedance of the cable typically 100 120R Connector Pinout DB9F Pin Description RS232 RS422 RS485 1 5V Output 100mA max Y Y Y 2 RS232 Rx V 3 RS232 Tx Y 4 reserved 7 Signal Ground Y Y Y 6 RS422 Rx Y 7 RS422 Rx Y 8 RS485 RS422 Tx Y Y 9 RS485 RS422 Tx Y Y housing Cable Shield Y Y Y a Connecting this signal
64. ory Inputs PLC Memory Outputs Actual Temperature Temperature Setpoint The PLC exchange data between the internal PLC memory and the slaves in this case the ABC on the Modbus RTU network The PLC Memory associated with the ABC is exchanged Data from the Input Data area is copied to PLC Input Memory and PLC Output Memory is copied to the Output Data area NAAA Modbus RTU Input Data Output Data General Data Actual Temperature Temperature Setpoint not used in this example The ABC copies the Output Register of the Temperature Regulator to the Input Data area Setpoint from the Output Data area to the Input Register in the Temperature Regulator Sub Network The ABC copies the Temperature Serial Device Temperature Regulator Output Register Input Register The Temperature Regulator has two Actual Temperature Temperature Setpoint registers holding the Setpoint Temperature and the Actual Temperature respectively Basic Operation 2 4 Sub Network Protocol Protocol Modes The gateway features two distinct modes of operation regarding the sub network communication called Master Mode and Generic Data Mode Note that the protocol mode only specifies the basic commu nication model not the actual sub network protocol Master Mode In this mode the gateway acts as a master on the sub network and the serial communication takes place in a Query Response fashion The no
65. own Menu 4 Checksum Checksum Depend See 8 4 Pull down Menu B Name of Command Actual name of the command in text form C Command Transactions This section holds the actual transactions associated with the command This can either be a Query Response pair or a single transaction depending on the protocol mode etc D Command ID This can be used as desired when building the command e g to specify the function code E Other Settings Setting Description Allow Broadcasting Specifies if it is allowed to broadcast the command only relevant in Master Mode Produce The command is producing data Generic Data Mode only Consume The command is consuming data Generic Data Mode only Commands 8 4 Pull down Menu File This menu features the following entries e Apply Changes Fie Apply Changes e Exit Exit Ctrl Q Exit without saving Save changes and exit to the main window Column The functions in this menu alters the structure of the command e Append Column PP i Column K Add another column to the command Append Column Insert Column Shift 1ns e Insert Column Insert a column at the selected position Delete Column Shit Del e Delete Command Delete the column at the selected posi tion Commands 8 5 Editing a Command As mentioned previously the transaction section in the Command Editor represents the actual transac tions associated with t
66. own menu from the left will change de pending on the current context The Tool Bar provides quick access to the most frequently used functions B Navigation Section This section is the main tool for selecting and altering dif ferent levels of the sub network configuration Entries preceded by a holds further configuration pa rameters or sub menus To gain access to these parame ters the entry must be expanded by clicking There are three main levels in the navigation window namely Fieldbus ABC and Sub network Right clicking on entries in this section brings out addi tional selections related to that particular entry C Parameter Section This section holds a list of parameters or options related to the currently selected entry in the Navigation Section The parameter value may be specified either using a selec tion box or manually depending on the parameter itself Values can be specified in decimal form e g 42 or in hexadecimal format e g Ox2A D Information Section This section holds information related to the currently se lected parameter Config Line OB This menu entry is expanded Eg Fieldbus lll Sterrtlnit nd a Fieldbus specific L hs Endinit Sub entries This menu entry holds additional sub entries parameters Configuration Alphabetic Categorized E Communication Bitrate bits s Data bits Parity Physical standard Start bi
67. quipment as well as when set ting up new installations Sd Modbus RTU Master e g a PLC Sd Modbus RTU Master e g a PLC INVERTER INVERTER Modbus RTU Network Modbus RTU Network PC configuration and monitoring PC configuration and monitoring ye Serial communication device qe Serial communication devices Single Node Serial Sub Network Multi Node Serial Sub Network Sub Network The gateway can address up to 31 nodes and supports the following physical standards e RS 232 e RS 422 e RS 485 Modbus RTU Interface Modbus RTU connectivity is provided through patented Anybus technology a proven industrial com munication solution used all over the world by leading manufacturers of industrial automation products e Galvanically isolated bus interface e Coil and Register access e RS 232 or RS 485 operation e On board configuration switches e 1200 57600bps operation About the Anybus Communicator for Modbus RTU 1 2 External View For wiring and pin assignments see A 1 Connector Pin Assignments A Modbus RTU Connector This connector 15 used to connect the gateway to the fieldbus See also A 1 Fieldbus Connector Modbus RTU B Configuration Switches See also 1 4 Configuration Switches C Status LEDs See also 1 3 Status LEDs D PC connector This connector is used to connec
68. r layer network that communicates with the serial device s on the sub network via the Communicator ieldbus Master fie PLC HMI Etc HAS Wizard Modbus RTU Master Physical standard R5232 Bitrate bits s 9600 Parity None Data bits g Stop bits 4 Step 2 of 6 Select sub network properties Sub network This is where the properties for the sub network are selected Please see the sub network device s manual to determine the appropriate settings for a particular serial device Please see the manual for the sub network device to determine Y Chapter 13 Control and Status Registers General The Control and Status Registers are disabled by default but can be enabled using the ABC Config Tool see 4 7 Status Control Word These registers form an interface for exchanging status information between the sub network and the fieldbus control system The main purpose of these registers is to e Report sub network related problems to the fieldbus control system e Ensure that only valid data is exchanged in both directions e Enable the fieldbus control system to start stop data exchange with selected nodes on the sub network If enabled these registers are located in the Input and Output data areas which means that they can be accessed from the fieldbus just like any other data in these areas Their location can be specified freely however keep in
69. r the number of coils to force ByteCount 1 byte value where you enter the number of data bytes Data Data object where you enter the length of the data to send and the source address The fieldbus master should enter the force data in these bytes Response Data Data object with 4 bytes The slave returns Coil Address and Quantity of Coils forced in these bytes Table 13 Force Multiple Coils 16 Preset Multiple Registers Starting Address 2 byte value where you enter the address of the first register to be preset No of Registers 2 byte value where you enter the number of registers to preset 1 byte value where you enter the number of data bytes Data object with 4 bytes The slave returns Starting Address and No of Registers preset in these bytes Table 14 Preset Multiple Registers 8 HMS INDUSTRIAL NETWORKS AB AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 17 Report Slave ID E 1 byte value where you enter the number of expected data bytes Data Data object where you enter the length of the recieved data and the desti nation address The slave returns slave ID Run Indicator Status and Additional Data in these bytes Table 15 Report Slave ID 20 Read General Reference ees EN CN espe Table 16 Read General reference 21 Write General reference IO Table 17 Write General Reference 22 Mask Write 4X Registers Query Data Data object where
70. ransactions The specified data block will be forwarded from the higher level network to the sub network The control system must supply an End or Length character in order for the gateway to know the size of the data block The End or Length character itself may either be forwarded to the sub network or discarded e Consume Response Transactions The specified data block is forwarded from the sub network to the higher level network The End or Length character will be generated by the gateway automatically if applicable The End or Length character itself may either be forwarded to the higher level network or dis carded Frame Objects 7 5 To specify the properties of the object select 1t in the Navigation Section enter the desired settings 10 the Parameter section as follows Parameter Description Byte Swapping e No Swapping No swapping will be performed on the data e Swap 2 bytes A B C D becomes B A D C e Swap 4 bytes A B C D becomes D C B A Fill unused bytes Enabled Fill unused data with the value specified in Filler byte e Disabled Don t fill Filler byte Filler byte value Only used if Fill unused bytes has been enabled Data Location The offset in the internal memory buffer where the data shall be read from written to Object Delimiter e Length Character Length character is visible in the internal memory buffer but not on the sub network Length
71. s that shall be used on the sub network for information about their serial commu nication requirements and if necessary contact the manufacturer of the device to obtain further information about the serial communication protocol In the event that the wizard doesn t handle a particular Modbus command required by a device it is possible to specify this command manually as a transaction in the ABC Config Tool Using this wizard involves the following steps Step 1 Communicator Type Select Modbus RTU Click Next to continue Tip It is possible to return to a previous menu at any time without losing any set tings by clicking Previous Step 2 Physical Settings Select the physical properties of the sub network Click Next to continue Steps 3 6 Consult the on line help system for fur ther information Wizard Modbus RTU Master Fieldbus Type The type of the Fieldbus connected to the Communicator Modbus RTU DeviceNet 0 v A Modbus Plus Controlnet Modbus TCP Ethernet IP ProfinetlO K Wizard Modbus RTU Master Version 1 14 Revision 1 Next gt Cancel Step 1 of 6 Select the fieldbus type The purpose of this wizard is to help you through the process of creating a project with a Modbus RTU sub network When the Wizard is finished it is possible to continue editing the project in the Configuration Tool The fieldbus is the highe
72. so 8 3 The Command Editor e Delete Command Delete the currently selected command from the list Note that some commands are fixed and cannot be deleted Toolbar Icons The toolbar features icons for the most commonly used functions e Add Command Same as Add Command in the Command menu Add Command e Edit Command my Same as Edit Command in the Command menu Edit Command e Delete Command Same as Delete Command in the Command menu Delete Command Commands 8 3 The Command Editor General The Command Editor is used to define new commands and edit existing ones This makes it possible to build a library of commands which can be stored and re used at a later stage Note that the Command Editor is somewhat protocol dependent in the sense that certain frame objects may not be deleted or altered The examples in this section uses Master Mode The procedures involved are similar in General Data Mode but without the limitations imposed by the Modbus RTU protocol Basic Navigation Open the Command Editor by selecting Edit Command or Add Command from the Command menu Command Editor El lumn Command Name New con Query 1 2 DisplayName Slave Address Function ObjectType Byte Value SlaveAddress Command ID 0x9 O Allow O 4 Checksurn Checksum User Slave Address Function Byte Byte SlaveAddress ID A Pull d
73. ssing it e Consume Response Transactions The gateway will check if the received byte word dword matches the specified value If not the message will be discarded To set the value of the object select it in the Navigation Section enter the desired value in the Parameter section Parameter Description Value Constant value Frame Objects 7 3 Limit Objects Byte Word Dword Limit Objects have a fixed range and come in three sizes Byte 8 bits Word 16 bits Dword 32 bits Limit Objects are handled differently depending on the direction of the transaction Produce Query Transactions This object shall not be used for such transactions value will be undefined Consume Response Transactions The gateway will check if the received byte word dword fits inside the specified boundaries If not the message will be discarded There are 3 types of interval objects Byte 8 bit interval Word 16 bit interval Dword 32 bit interval To set the range of the object select it in the Navigation Section enter the desired range in the Parameter section as follows Parameter Description Maximum Value This is the largest allowed value for the range Range 0x00 OxFFh byte 0x0000 OxFFFFh word 0x00000000 OxFFFFFFFFh dword Note Value must be larger than the Minimum Value below Minimum Value This is the smallest allowed value for the range Range 0x00 OxFEh byte 0x0000 OxFF
74. t 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 A B C D E F G H J K L M N O 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 P Q R S T U V W X Y Z _ 80 81 82 8 84 85 86 87 88 89 90 91 92 93 94 95 a b C d e f g h j k m n 0 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 p q r S t u V W X y Z DEL 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 HMS INDUSTRIAL NETWORKS AB PHONE 46 35 17 29 00 PIELEFELTSGATAN 93 95 FAX 46 35 17 29 09 S 302 50 HALMSTAD e mail info hms networks com SWEDEN web www hms networks com AN YB 7 CS AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 Revision notes Revision Date Description Responsible 0 91 2001 07 30 Updated numbering Edk Preface The data and illustrations found in this manual are not binding We reserve the right to modify our products in line with our policy of continuous product development The information in this manual is subject to change without notice and should not be considered as a commitment by HMS Industrial Networks AB HMS Industrial Networks AB assumes no responsibility for any errors that may appear i
75. t the gateway to a PC for con figuration and monitoring purposes See also A 2 PC Connector E Sub network Connector This connector is used to connect the gateway to the serial sub network See also A 3 Sub network Interface F Power Connector This connector is used to apply power to the gateway See also A 1 Power Connector B 1 Technical Specification G DIN rail Connector The DIN rail mechanism connects the gateway to PE Protective Earth See also 1 5 Hardware Installation B 1 Technical Specification Status LEDs About the Anybus Communicator for Modbus RTU 1 3 Stat Stat o ate atus i j 6 25 0 1 Bus Error Off Normal operation OO O O Red Bus error CRC mismatch gt 10 2 Bus Ready Off Not powered Green Normal operation bus ready Red Bus is off line bus not ready 3 Processing Off Currently not processing query Green flashing Currently processing query 4 Switch Status Off Normal operation Invalid configuration switch setting 5 Subnet Status Off Power off Green flashing Initializing and not running Green Running Red Stopped or subnet error or timeout 6 Device Status Off Power off Alternating Red Green Invalid or missing configuration Green Green flashing Red flashing Initializing Running Contact
76. te All bytes are logically XOR ed together The resulting byte will be used as a checksum e ADD 1 byte All bytes are added together as unsigned 16 bit values The lowest 8 bits in the result will be used as a checksum e AddinvASCll 2 bytes All bytes are added together as unsigned 8 bit values The lowest 8 bits in the result are inversed and used as a checksum represented as hexadecimal ASCII 2 bytes Chapter 8 Commands General As mentioned previously Commands ate actually pre defined transactions that can be stored and re used Just like regular transactions commands consist of frame objects and are representations of the actual serial telegrams exchanged on the serial sub network Adding a command to a node actually results in a transaction s being added according to the directions specified in the command The Frame Objects in such a transaction may retrieve their values not only from parameters in the parameter section but also from other sources such as the SlaveAddress pa rameter see 5 1 Node Parameters In such case the parameters in the parameter section will be ereyed out and cannot be edited directly In Master Mode ABC Config Tool comes pre loaded with commands for most common Modbus RTU functions Additional commands can easily be added using the Command Editor see 8 3 The Com mand Editor In Generic Data Mode no pre defined commands exist but custom ones may be im plemented as
77. te on trigger the memory location specified by this parameter is monitored by the gateway Whenever the trigger byte is updated the gateway will produce the transaction on the sub network This way the control system can instruct the gateway to produce a specific transac tion on the sub network by updating the corresponding trigger byte The trigger byte should be incremented by one for each activation Note This parameter has no affect unless the Update mode parameter is set to Change of state on trigger Consume Transactions To gain access to these parameters select a Consume Transaction in the Navigation Section Parameter Offline options for sub network Description This parameter specifies the action to take for this transaction ifthe sub network goes off line This affects the data that is sent to the higher level network e Clear Data is cleared 0 on the higher level network if the sub network goes offline e Freeze Data is frozen on the higher level network if the sub network goes offline Offline timeout time 10ms This parameter specifies the maximum allowed time between two incoming mes sages in steps of 10ms If this time is exceeded the sub network is considered to be offline A value of 0 disables this feature i e the sub network can never go offline Trigger byte e Enable Enables the trigger byte The location of the trigger byte must be specified in the Trigger byte address b
78. then be exchanged on the sub network The internal memory buffer is divided into three areas gt Output Data 512 bytes based on their function e Input Data 512 bytes Sub Network This area can be read by the higher level net work in this case Modbus RTU Higher Level Network e Output Data 512 bytes This area can be read written by the higher lev el network in this case Modbus RTU General Data e General Data Up to 1024 bytes This area cannot be accessed from the higher level network but may be used for transfers be tween individual nodes on the sub network or as a general scratch pad for data The actual size of this area depends on the amount of data that is exchanged on the sub network The gate way can handle up to 1024 bytes of General Data Memory Map When building the sub network configuration using the ABC Config Tool the different areas described above ate mapped to the memory locations addresses specified below Input Data Output Data General Data 0x000 0x200 0x400 Sub Network Read Write Fieldbus Read Only Sub Network Read Only Fieldbus Read Write Sub Network Read Write Fieldbus Ox1FF 0x3FF 0x22 Basic Operation 2 3 Data Exchange Example In the following example a temperature regulator on the sub network exchanges information with a PLC on the higher level network via the internal memory buffers in the gateway PLC Modbus RTU Master PLC Mem
79. ts Stop bits E Timing Message delimiter 10ms Parameter Section Message delimiter 10ms The time between transaction Information Section Navigating the ABC Config Tool 3 2 Pull down Menu File This menu features the following entries e New kN Create a new configuration New Ctrl N See also 12 1 Configuration Wizards Open Ctri O Save Ctri S e Open Save as Open a previously created configuration Print Ctri P Save Properties Save the current configuration e Save As Exit Save the current configuration under a new name e Print Send details about the current configuration to a printer e Properties This brings out the following window Item Description HDS Name the Configuration Select a Name for the A name for the configuration Select a Name for the Configuration Configuration may be entered here ae S Download Password 6 Upload Password 6 Download Password 6 These fields can be used to me Upload Password 6 password protect the configu ration in the gateway Cancel CAUTION Always keep a copy of the password in a safe place A lost password cannot be retrieved e Exit Close the ABC Config Tool Tools This menu features the following entries Port This entry selects the COM port used for the configuration of the gateway Upload configuration from ABC Upload the configuration from the gateway to the ABC Config
80. work in the Navigation window and select Sub Network Status to see status diagnostic information about the sub network If the gateway reports very many re transmissions check your cabling and or try a lower baud rate set ting for the sub network if possible e Is the Sub Net Monitor in the ABC Config Tool active The sub network monitor has a negative influence on the overall performance of the gateway and should only be used when necessary e Is the Node Monitor in the ABC Config Tool active The node monitor has a negative influence on the overall performance of the gateway and should only be used when necessary No sub network functionality e Use the Data logger functionality to record the serial data communication on the sub network e If no data is being transmitted check the configuration in ABC Config Tool s fno data is received check the sub network cables Also verify that the transmitted data is correct Appendix D ASCII Table NUL SOH STX ETX EOT ENQ ACK BEL BS HT LF VT FF CRIS Si 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 DLE DC1 DC2 DC3 DC4 NAK SYN ETB CAN EM SUB ESC FS GS RS US 16 17 18 19 20 21 22 23 24 235 26 27 28 29 30 31 sp i amp R l 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 0 1 2 3 4 5 6 7 8 9 lt g
81. work goes off line This affects the data that is sent to the sub network e Clear Data is cleared 0 on the sub network if the higher level network goes offline e Freeze Data is frozen on the sub network if the higher level network goes offline NoScanning Stop sub net scanning for this transaction if the higher level network goes offline Update mode The update mode for the transaction e Cyclically The transaction is sent cyclically at the interval specified in the Update Time parameter e On data change The transaction is sent each time its data has changed Single shot The transaction is sent once at startup e Change of state on trigger The transaction is sent when the trigger byte has changed This feature enables the control system to notify the gateway when to issue a particular transaction To use this feature correctly the control system must first update the data area asso ciated with the transaction then increase the trigger byte by one The location of the trigger byte is specified by the Trigger byte address parameter Update time 10ms This parameter specifies how often the transaction will be issued in steps of 10ms only relevant when Update mode is set to Cyclically Parameter Trigger byte address Transactions 6 4 Description This parameter specifies location of the trigger byte in the internal memory buffer If Update mode is set to Change of sta
82. you enter the length of the data to send and the source address The fieldbus master should enter the Reference Address AND mask and OR mask in these bytes Response Data Data object where you enter the number of expected data bytes and the destination address The slave returns Reference Address AND mask and OR mask in these bytes Table 18 Mask Write 4X Registers 23 Read Write 4X Registers CEN Cn esposo A Table 19 Read Write 4X Registers 24 read FIFO Queue CN Table 20 Read FIFO Queue HMS INDUSTRIAL NETWORKS AB 9 AnyBus Communicator Protocol Appendix Modbus DOC ABC APPENDIX MB Rev 0 91 2001 08 01 This page is intentionally left blank 10 HMS INDUSTRIAL NETWORKS AB FJ 77 If you have any comments about this documentation please take a few minutes to fill out this form and let us know about your opinions These comments will help us improve our work and make us aware of what customers of our products may find good faulty or even missing Document title and revision Your name and company Phone E mail Comments Text and illustrations What information is missing or unclear Other comments Send your comments to You may also mail or fax your comments HMS Industrial Networks AB E mail support hms networks com Support Department Fax 46 0 35 172909 Pilefeltseatan 93 95 302 50 Halmstad SWEDEN About the Anybus Communicator for Modbus RTU 1 4 Configuration Switches

Download Pdf Manuals

image

Related Search

Related Contents

Klip Xtreme KNC-080    2009 - Betriebsanleitung ME-SHIFTER F1 - Tom-Tech  Operating Instructions Hydraulic Jacks JH G  KitchenAid KHPS 7510/I hob  Manual de instalación y puesta en servicio SolarBloC midi  SC191DRF  Basico 90.6001 - Krabbel-Hit  Forno TH130.PMD  

Copyright © All rights reserved.
Failed to retrieve file