D-Link DE-805TP - 10Mbps Ethernet Mini Hub User Manual

Browse online or download User Manual for Network switches D-Link DE-805TP - 10Mbps Ethernet Mini Hub. Modbus for Field Technicians

  • Download
  • Add to my manuals
  • Print
  • Page
    / 77
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 0
Modbus for Field Technicians
Page 1
Modbus for Field Technicians
Revision 1.0
Any reproduction or re-transmission in whole or in part of this
work is expressly prohibited without the prior consent of Chipkin
Automation Systems Inc.
Copyright Notice
© Copyright 2010 Peter Chipkin who has given permission to Chipkin
Automation Systems to publish this work.
Mailing Address: 3495 Cambie St, # 211, Vancouver, BC , Canada, V5Z 4R3
Thanks to Liz Lucica for all your work in putting this booklet together.
Modbus is a registered trademark of Modicon
.
Page view 0
1 2 3 4 5 6 ... 76 77

Summary of Contents

Page 1 - Modbus for Field Technicians

Modbus for Field Technicians Page 1 Modbus for Field Technicians Revision 1.0 Any reproduction or re-transmission in whole or in par

Page 2 - Page 2

Modbus for Field Technicians Page 10 BUT HERE IS THE IMPORTANT PART Let's say you want to read, for example, the value of holding registe

Page 3 - TABLE OF CONTENTS

Modbus for Field Technicians Page 11 The same discussion applies to the other data types. Publicly we number them from 1. Privately (inside th

Page 4

Modbus for Field Technicians Page 12 4. WHAT ABOUT SCALING IN MODBUS Modbus does not provide a method for transporting large or Floa

Page 5 - MODBUS - INTRODUCTION

Modbus for Field Technicians Page 13 message there is no way of telling whether you are looking at two consecutive 16 bit words,

Page 6 - Page 6

Modbus for Field Technicians Page 14 6. BYTE/WORD ORDER – AN AMBIGUOUS NIGHTMARE It takes two bytes to make a 16 bit word. These bytes can be

Page 7 - Page 7

Modbus for Field Technicians Page 15 This is ambiguous. Here is how you resolve this –  Apply common sense - Which value is correct.  Read

Page 8 - DATA TYPE

Modbus for Field Technicians Page 16 7. BIT ORDER – SOMETIMES IT’S A PROBLEM TOO In older Modicon PLC’s bits were numbered 1-16. All modern s

Page 9 - Page 9

Modbus for Field Technicians Page 17 8. MODBUS AND GATEWAYS A gateway is a device that makes data read using one protocol available using ano

Page 10 - Page 10

Modbus for Field Technicians Page 18 9. WHAT ABOUT ERRORS / EXCEPTIONS Modbus has a limited way of reporting errors. A server / sl

Page 11 - Page 11

Modbus for Field Technicians Page 19 Code Name / Meaning 1 ILLEGAL FUNCTION The function code received in the query i

Page 12 - Page 12

Modbus for Field Technicians Page 2

Page 13 - Page 13

Modbus for Field Technicians Page 20 10. THERE CAN ONLY BE ONE MASTER ON A MODBUS SERIAL TRUNK Modbus is a poll-response type of protocol. A

Page 14 - Page 14

Modbus for Field Technicians Page 21 11. MULTIPLE CLIENTS OF A MODBUS SLAVE We are frequently asked how you deal with a situation where you ha

Page 15 - Page 15

Modbus for Field Technicians Page 22 Figure 2: Using a FieldServer with an appropriate configuration solves this problem whether you

Page 16 - Page 16

Modbus for Field Technicians Page 23 Figure 3: Each client is on its own port. Thus each client does not see poll messages fro

Page 17 - 8. MODBUS AND GATEWAYS

Modbus for Field Technicians Page 24 Figure 4: The slave responds. The FieldServer relays the response to client#1. The FieldServe

Page 18 - Page 18

Modbus for Field Technicians Page 25 Figure 5: If any client requests the same data (client#1 or #2) and the data has not expired then the

Page 19 - Page 19

Modbus for Field Technicians Page 26 Figure 7: The slave responds, the response is relayed to the client doing the polling (Client#2 in thi

Page 20 - Page 20

Modbus for Field Technicians Page 27 12. OLD DEVICE – SLOW PROCESSORS – LIMITED CAPABILITY Many older devices have old microprocessors that c

Page 21 - Page 21

Modbus for Field Technicians Page 28

Page 22 - Page 22

Modbus for Field Technicians Page 29 MODBUS RS232, RS485 AND TCP/IP

Page 23 - Page 23

Modbus for Field Technicians Page 3 TABLE OF CONTENTS MODBUS - Introduction ...

Page 24 - Page 24

Modbus for Field Technicians Page 30 14. HOW MODBUS IS TRANSPORTED There are 3 main physical layers for Modbus. RS232 : One master and one

Page 25 - Page 25

Modbus for Field Technicians Page 31 15. MODBUS ON RS232 RS232 requires a minimum of 3 conductors to connect the two devices. Rx, Tx and Grou

Page 26 - Page 26

Modbus for Field Technicians Page 32 16. MODBUS ON RS485 Search the Internet on RS485 you will find Bob Perrins’s article called

Page 27 - Page 27

Modbus for Field Technicians Page 33 Tip #2 – Connection Order Always connect the ground reference conductor first if you are connecting a de

Page 28 - Page 28

Modbus for Field Technicians Page 34 Tip Advice #5 – Cable Type Cable selection does make a difference. All cables offer impedance (resist

Page 29 - Page 29

Modbus for Field Technicians Page 35 Wrong in the sense – to determine the value of terminating resistors now requires measurements

Page 30 - Page 30

Modbus for Field Technicians Page 36 Tip #6 – Number of Devices per Trunk How do you put more than 32 devices on a single RS485 trunk? The

Page 31 - 15. MODBUS ON RS232

Modbus for Field Technicians Page 37 Source: Ten Ways to Bulletproof RS-485 Interfaces National Semiconductor Application Note 1057 John Gold

Page 32 - 16. MODBUS ON RS485

Modbus for Field Technicians Page 38  A single Modbus message can only read consecutive data points. If you need to read 40001 and 40003 you

Page 33 - Page 33

Modbus for Field Technicians Page 39 Thus at 19200 baud it takes approx to read 125 registers. Poll = 10 bytes at 1920 per sec Server laten

Page 34 - Page 34

Modbus for Field Technicians Page 4 20. Converting Modbus 16 bit numbers to 32 bit numbers ... 66 21. How Re

Page 35 - Page 35

Modbus for Field Technicians Page 40  Biasing, Idle State Biasing, Fail Safe Biasing, Anti Aliasing There are a whole string of terms

Page 36 - Page 36

Modbus for Field Technicians Page 41  Line Drive On / Off To use two wires for RS485 each device’s transmitter and receiver must b

Page 37 - Page 37

Modbus for Field Technicians Page 42 Getting worse. Making the connections to the RS485 terminals, drops instead of connections starts to

Page 38 - Page 38

Modbus for Field Technicians Page 43 Worst. Avoid Star configurations. They are so much harder to debug when it gets tricky. (Showing TX condu

Page 39 - Page 39

Modbus for Field Technicians Page 44

Page 40 - Page 40

Modbus for Field Technicians Page 45 MODBUS RESOURCES, TESTING AND TROUBLE SHOOTING

Page 41 - Page 41

Modbus for Field Technicians Page 46 17. WHAT TO TAKE TO SITE WITH YOU Here is a list of tools and resources you should carry

Page 42 - Page 42

Modbus for Field Technicians Page 47 5. CAS Modbus Scanner – free download CAS Modbus Scanner is a utility to retrieve coils, inputs, holdi

Page 43 - Page 43

Modbus for Field Technicians Page 48 8. Lcom DB9-Terminal blocks (or similar) http://www.l-com.com/item.aspx?id=8141 Male and Female

Page 44 - Page 44

Modbus for Field Technicians Page 49 11. Terminating Resistors Take 52.3, 75, 100, 120 and 150 Ohm resistors with you

Page 45 - Page 45

Modbus for Field Technicians Page 5 MODBUS - INTRODUCTION

Page 46 - Page 46

Modbus for Field Technicians Page 50 12. Gender Benders 13. Ethernet Patch cables 14. Hub A hub is not a switch. A hub can be used

Page 47 - Page 47

Modbus for Field Technicians Page 51 Appendix 18. TROUBLE SHOOTING MODBUS TCP/IP REQUIRED TOOLS Hub or Supervised Switch Wireshark – Free Dow

Page 48 - Page 48

Modbus for Field Technicians Page 52 HOW TO CAPTURE WITH WIRESHARK 1. Capture – Main Menu 2. Interfaces – On Capture Menu a) You get a li

Page 49 - Page 49

Modbus for Field Technicians Page 53 3. A list of packets accumulates on the screen. 4. Apply a Display Filter. More on display filters la

Page 50 - Page 50

Modbus for Field Technicians Page 54 5. Find the packet you are interested in. Click on it to select it. A breakout of the selected packet’s d

Page 51 - Appendix

Modbus for Field Technicians Page 55 6. You can break out the level of detail by expanding the sections of the packet. Think of a Modbus

Page 52 - Page 52

Modbus for Field Technicians Page 56 7. Drill down to see the Modbus info Before you start a capture you can specify a capture filter. The e

Page 53 - Page 53

Modbus for Field Technicians Page 57 CAPTURE FILTERS Here are some sample filters Examples: Capture only traffic to or from IP address 172.18

Page 54 - Page 54

Modbus for Field Technicians Page 58 Capture traffic to a range of IP addresses: dst net 192.168.0.0/24 or dst net 192.168.0.0 ma

Page 55 - Page 55

Modbus for Field Technicians Page 59 DISPLAY FILTERING Useful Hint : Any capture filter can be used as a display filter. You can use the exp

Page 56 - Page 56

Modbus for Field Technicians Page 6 Because it is so commonly used, because it is so limited, because some vendors went to a l

Page 57 - CAPTURE FILTERS

Modbus for Field Technicians Page 60 From the drop down list of protocols there is one specifically related to Modbus. They are sh

Page 58 - Page 58

Modbus for Field Technicians Page 61 19. USING THE CAS MODBUS SCANNER Add a connection Choose from Serial or Ethernet

Page 59 - Expression Builder

Modbus for Field Technicians Page 62 Add devices. The device number is the Modbus Device Number. Add requests – polls for data. You can m

Page 60 - Page 60

Modbus for Field Technicians Page 63 You can add multiple connections. More than one of each type. Each connection can have one or

Page 61 - Page 61

Modbus for Field Technicians Page 64 Once connections, devices and requests have been defined you can scan for data, exit or edit the settings

Page 62 - Page 62

Modbus for Field Technicians Page 65 Data is displayed here in various formats. When displayed as floats or 32 bit integers

Page 63 - Page 63

Modbus for Field Technicians Page 66 20. CONVERTING MODBUS 16 BIT NUMBERS TO 32 BIT NUMBERS Often the Vendor documentation does not re

Page 64 - Page 64

Modbus for Field Technicians Page 67 Example: In the move below if DA_B01_REG[21] == 1 and DA_B01_REG[22] == 2 Then DA_B01_INT32[21] == 13107

Page 65 - Page 65

Modbus for Field Technicians Page 68 Example: DA_B01_REG[21] == 1 and DA_B01_REG[22] == 2 Function In Use Value found in DA_B01_INT32[21]

Page 66 - NUMBERS

Modbus for Field Technicians Page 69 21. HOW REAL (FLOATING POINT) AND 32-BIT DATA IS ENCODED IN MODBUS RTU MESSAGES The article discusses

Page 67 - Page 67

Modbus for Field Technicians Page 7 Inputs Think Binary inputs. Also known as Inputs. Also known as 1xxxx inputs (xxxx is the place h

Page 68 - Page 68

Modbus for Field Technicians Page 70 For example, the number 123456.00 as defined in the IEEE 754 standard for single-precision 32-bit floatin

Page 69 - THE IMPORTANCE OF BYTE ORDER

Modbus for Field Technicians Page 71 Furthermore, both a “byte swap” and a “word swap” would essentially reverse the sequence of the

Page 70 - Page 70

Modbus for Field Technicians Page 72 As a rule of thumb, the family of a device’s microprocessor determines its endianness. Typica

Page 71 - DETERMINING BYTE ORDER

Modbus for Field Technicians Page 73 PRACTICAL HELP The FieldServer Modbus RTU drivers offer several function moves that handle 32-bit integer

Page 72 - Page 72

Modbus for Field Technicians Page 74 The following table shows the FieldServer function moves that copy a single 32-bit floating point value to

Page 73 - PRACTICAL HELP

Modbus for Field Technicians Page 75 Notice that different byte and word orderings require the use of the appropriate FieldServer

Page 74 - Page 74

Modbus for Field Technicians Page 76 22. HUBS VS SWITCHES – USING WIRESHARK TO SNIFF NETWORK PACKETS Gotcha #1 : Use a hub not a switch Why:

Page 75 - Page 75

Modbus for Field Technicians Page 77 Gotcha #2 : Mixing 10 and 100 mbits/sec can cause problems. Not all hubs copy 10mbit messages to

Page 76 - NETWORK PACKETS

Modbus for Field Technicians Page 8 2. THERE ARE (WERE) A MAX OF 9999 POINTS OF EACH DATA TYPE When Modbus was invented they thought 9,999 i

Page 77 - Page 77

Modbus for Field Technicians Page 9 3. 5 DIGIT VS 6 DIGIT ADDRESSING If 40001 is the 1st, 40002 the 2nd …. We get to 49,999

Comments to this Manuals

No comments