The text of a manual · part 4 of 8
DN120 DeviceNet Gateway User's Manual, pages 28 to 36
Pages 28 to 36 of 71
The original document is the PDF (1.4 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.
For the Microscan DN-120
Page 28
DN120 DeviceNet Gateway User’s Manual
IDENTITY OBJECT The Identity Object is required on all DeviceNet devices. It provides product identification and general information. Identity Object Class Access Attribute 1 Get 2 Get 6 Get 7 Get Instance Access Attribute 1 Get 2 Get 3 Get 4 Get
5
Get
6 7
Get Get
Class Code 01 (0x01) Name
Type
Value
Revision Max Object Instance Max Class Identifier Max Instance Attribute Name
UINT UINT UINT UINT Type
1 1 7 7 Value
Vendor Product Type Product Code Revision Major Revision Minor Revision Device Status
UINT UINT UINT STRUCT of USINT USINT WORD
59 = D.I.P. Products 12 = Communications 1
Serial Number Product Name Length Name
UDINT STRUCT of USINT 6 STRING [6]
4 0 Bit 0 = owned (0 available, 1 allocated) Bit 2 = configured (0 no, 1 yes) Bit 4-7 = vendor specific (0) Bit 8 = minor configuration fault Bit 9 = minor device fault Bit 10 = major configuration fault Bit 11 = major device fault Bit 1, 3, 12-15 = reserved (0) Unique serial number for every device
Common Services Service Code 05 (0x05) 14 (0x0E)
Class No Yes
Microscan Systems, Inc.
Instance Yes Yes
Service Name Reset Get_Attribute_Single
28
Page 29
DN120 DeviceNet Gateway User’s Manual ROUTER OBJECT The Message Router Object provides a messaging connection point through which a Client may address a service to any object class or instance residing in the DN120 device. Router Object Class Access Attribute 1 Get 6 Get 7 Get Instance Access Attribute 2 Get
Class Code 02 (0x02) Name
Type
Value
Revision Max Class Identifier Max Instance Attribute Name
UINT UINT UINT Type
1 7 2 Value
Number of Connections UINT
2
Common Services Service Code 14 (0x0E)
Class Yes
Microscan Systems, Inc.
Instance Yes
Service Name Get_Attribute_Single
29
Page 30
DN120 DeviceNet Gateway User’s Manual
DEVICENET OBJECT The DeviceNet Object contains information about the DN120 DeviceNet interface configuration. DeviceNet Object Class Access Name Attribute 1 Get Revision Instance Access Name Attribute 1 Get/Set MAC ID
Class Code 03 (0x03) Type
Value
UINT Type
2 Value
USINT
Settable only if MAC ID switches > 63. Valid numbers are 0 to 63. Returns last value set or switch value.
2
Get/Set Baud Rate
USINT
Settable only if Baud switch > 2. Valid settings are 0 = 125K, 1 = 250K, 2 = 500K. Returns last value set or switch value.
3
Get/Set Bus Off Interrupt
BOOL
4
Get/Set Bus Off Counter
USINT
0 = hold CAN in OFF state (default) 1 = reset CAN Writing this attribute forces counter value to zero.
5
Get
Allocation Information Choice Byte
STRUCT of BYTE
Master Node Address
USINT bit 0 = explicit msg, set to 1 to allocate bit 1 = polled IO, set to 1 to allocate bit 2 = strobed IO, not supported bits 3-7 = reserved, set to 0 Allocated to this DeviceNet master
Common Services Service Code 14 (0x0E) 16 (0x10) 75 (0x4B) 76 (0x4C)
Class Yes No No No
Microscan Systems, Inc.
Instance Yes Yes Yes Yes
Service Name Get_Attribute_Single Set_Attribute_Single Allocate Master/Slave Release Master/Slave
30
Page 31
DN120 DeviceNet Gateway User’s Manual
ASSEMBLY OBJECT The Assembly Object instances bind attributes of multiple objects to allow data to or from each object to be sent or received over a single connection. Assembly Object Class Access Attribute 1 Get 2 Get Instance Access Attribute 3 Get
Class Code 04 (0x04) Name
Type
Value
Revision Max Class ID Name
UINT UINT Type
2 2 Value
Data Stream note 1
Instance 1 for input data stream. Instance 2 for output data stream.
Common Services Service Code 14 (0x0E) 16 (0x10)
Class Yes No
Instance Yes Yes
Service Name Get_Attribute_Single Set_Attribute_Single
Instance 1 Input Data Stream and Instance 2 Output Data Stream are structured as either an array of bytes or as a Short_String consisting of a single byte length field and N data bytes. The Input Data Stream is the data returned in the Poll Response Message. The Output Data Stream is the data returned in the Poll Command Message. See Chapter 3 for a complete description of the Poll Format. Poll Response: [Status byte][Receive Sequence Number byte][Short_String Length byte][RX data bytes] Poll Command: [Status Clear byte][Transmit Sequence Number byte][Short_String Length byte][TX data bytes]
Microscan Systems, Inc.
31
Page 32
DN120 DeviceNet Gateway User’s Manual
CONNECTION OBJECT The Connection Object instances manage the characteristics of each communication connection. The DN120 is a Group 2 Only Slave device that supports 1 Explicit Message Connection (Instance 1) and 1 Poll Message Connection (Instance 2). Connection Object Class Access Name Attribute 1 Get Revision Instance Access Name Attribute 1 Get State
Class Code 05 (0x05) Type
Value
UINT Type
1 Value
USINT
0 = non-existent 1 = configuring 2 = established 3 = timed out
USINT
0 = Explicit Message 1 = I/O Message 0x83 for Explicit Message 0x82 for I/O Message Explicit Message: 10xxxxxx011 = produced connection id I/O Message: 01111xxxxxx = produced connection id Explicit Message: 10xxxxxx100 = consumed connection id I/O Message: 10xxxxxx101 = consumed connection id 0x21 for Explicit Message 0x01 for I/O Message 67 for Explicit Message See Stream Object for I/O Message 71 for Explicit Message See Stream Object for I/O Message Default 2500 msec 0 = Timeout (Explicit Message default) 1 = Auto Delete 2 = Auto Reset (I/O Message default) 0 for Explicit Message 6 for I/O Message Null for Explicit Message STRUCT for I/O Message 0x20 0x04 0x24 0x01 0x30 0x03 0 for Explicit Message 6 for I/O Message
2
Get
Instance Type
3
Get
Transport Class Trigger USINT
4
Get
Production Connection
UINT
5
Get
Consumed Connection
UINT
6
Get
USINT
7
Get
Initial Communication Characteristics Production Size
8
Get
Consumed Size
UINT
Get/Set Expected Packet Rate Get/Set Timeout Action
UINT USINT
9 12
UINT
13
Get
Production Path Length USINT
14
Get
Production Path
STRUCT of
Get
Log. Seg., Class Class Number Log. Seg., Instance Instance Number Log. Seg., Attribute Attribute Number Consumed Path Length
USINT USINT USINT USINT USINT USINT USINT
15
Microscan Systems, Inc.
32
Page 33
DN120 DeviceNet Gateway User’s Manual 16
17
Get
Consumed Path
STRUCT of
Get
Log. Seg., Class Class Number Log. Seg., Instance Instance Number Log. Seg., Attribute Attribute Number Production Inhibit
USINT USINT USINT USINT USINT USINT UINT
Null for Explicit Message STRUCT for I/O Message 0x20 0x04 0x24 0x02 0x30 0x03 0
Common Services Service Code 05 (0x05) 14 (0x0E) 16 (0x10)
Class Yes Yes No
Microscan Systems, Inc.
Instance Yes Yes Yes
Service Name Reset Get_Attribute_Single Set_Attribute_Single
33
Page 34
DN120 DeviceNet Gateway User’s Manual
SERIAL STREAM OBJECT The Serial Stream Object configures the DN120 serial channel. Serial Stream Object Class Access Name Attribute 1 Get Revision 2 Get Max Object Instance 6 Get Max Class Identifier 7 Get Max Instance Attribute Instance Access Name Attribute 3 Get Receive Data 4 Get/Set Transmit Data
Class Code 64 (0x40) Type
Value
UINT UINT UINT UINT Type
1 1 7 22 Value
Data Format Received message data. Returned in Poll Response Data Format Message data to transmit. Received in Poll Command. USINT Bit 0 – Transmit Channel Blocked Bit 1 – Transmit Buffer Empty Bit 2 – Receive Parity Error (0 to clear) Bit 3 – Receive Buffer Empty Bit 4 – Receive Buffer Overflow Error (0 to clear) Bit 5 – Framing Error (0 to clear) Bit 6 – Transmit Buffer Overflow Error (0 to clear) Bit 7 – CTS Signal State (1 = asserted) USINT 0 = 9600 bps 4 = 600 bps 1 = 4800 bps 5 = 300 bps 2 = 2400 bps 6 = 19200 bps 3 = 1200 bps USINT 0 = no parity 5 = mark (force to 1) 1 = even parity 6 = space (force to 0) 2 = odd parity
5
Get/Set
Status
6
Get/Set
Baud Rate
7
Get/Set
Parity
8 9 10
Get Get Get/Set
Data Size Stop Bits Flow Control
USINT USINT USINT
11 12 13 14
Get/Set Get/Set Get/Set Get/Set
Receive Count Transmit Count Maximum Receive Size Data Format
USINT USINT USINT USINT
15
Get/Set
Block Mode
USINT
16 17 18
Get/Set Get/Set Get/Set
Delimiter USINT Pad Character CHAR Maximum Transmit Size USINT
Microscan Systems, Inc.
7 (parity enabled) or 8 (no parity) 1 0 = none 2 = CTS / RTS 1 = XON / XOFF 4 = CTS Detect Mode Number of bytes in Receive Buffer. Write to clear. Number of bytes in Transmit Buffer. Write to clear Maximum # bytes returned by Receive Buffer read. Bit 0 – String Format (0 = Short_String, 1 = Array) Bit 1 – Strip Parity Bits (0 = retain, 1 = strip) Bit 2 – Pad Justification (0 = left, 1 = right) Bit 3 – Pad Received Message (0 = no, 1 = yes) Bit 0 – Pre/Post Delimiter (0 = Pre-, 1 = Post-) Bit 1 – Strip Delimiter (0 = keep, 1 = strip) Bit 2 – Delimiter Enable (0 = no, 1 = yes) Bit 3 – Enable Receive Sequence Number Bit 4 – Enable Transmit Sequence Number Bit 5 – Re-send (0 = no, 1 = yes) Bit 6 – Synchronization (0 = no, 1 = yes) Delimiter byte value Pad byte value Defines maximum # bytes that can be transmitted.
34
Page 35
DN120 DeviceNet Gateway User’s Manual 19
Get/Set
Idle String
20
Get/Set
Fault String
21 22
Get/Set Get/Set
Status Enable Status Clear Enable
Short_String Byte string transmitted when gateway receives null Poll (no input bytes). Length = 0 for no Idle String. Short_String Byte string transmitted when gateway’s Polled I/O connection times out. Length=0 for no Fault String USINT Nonzero value enables Status input byte. USINT Nonzero value enables Status Clear output byte.
Common Services Service Code 05 (0x05) 14 (0x0E) 16 (0x10)
Class No Yes No
Microscan Systems, Inc.
Instance Yes Yes Yes
Service Name Reset Get_Attribute_Single Set_Attribute_Single
35
Page 36
DN120 DeviceNet Gateway User’s Manual
Chapter 6 – RSNetworx Configuration Example This chapter shows how to set up configure a DN120 gateway using the Rockwell Software RSNetworx software and your gateway’s Electronic Data Sheet (EDS) file. The system configuration uses an Allen-Bradley 1770-KFD DeviceNet adapter (MAC ID 62) to connect the PC running RSNetworx to the DeviceNet network. A SLC500 system with a 1747-SDN DeviceNet Scanner (MAC ID 00) is the DeviceNet master. DN120 gateway has MAC ID 03. L
N 120VAC Input
Fuse 3A
Power Sup.
Slot 0
Slot 1
24vdc output
SLC502
DeviceNet
PLC CPU
Scanner module module
1747-L524 1747-SDN Comm. Comm.
1746-IV8
1746-OB8
1747-P1 120/240VAC Neutral
Slot 2
Slot 3
8 pt. Input 8 pt.Output
GND
DeviceNet network Fuse 1A
24VDC Power Supply
Fuse 6A
+ 24VDC
-to pin 1 DeviceNet connector
GND PC Interface To PC RS232 25
Module
Pin Serial Interface
1747-PIC
For Used with
RS232-PLC
RSLogic Prog.
RS232 serial communication To PC RS232 9 pin to pin 5 DeviceNet connector
120VAC
PS to DeviceNet Dist. Pin Color Description 1 black BUS- (0vdc) 3 clear
Shield (Drain)
5 red
BUS+ (24vdc)
PC Interface Mod.
Serial Interface For
1770-KFD
DIP790 Device
Used with RSLinx,
RS232-DeviceNet
Net Dist. Board
& RSNetWorx Prog.
Terminal Connector
DeviceNet 9 pin DIN RS232 Serial
Gateway Module
Interface to Barcode
DN120
Reader, Scanner
RS232-DeviceNet
Pin Color 1 black 2
Weigh Scale or etc.
RS232 Pin Layout Pin Func. Pin Func. 2 RXD 7 RTS 3 8 TXD CTS 5
DeviceNet Male Connector
4
3 5
GND
Pin 1,4,6,9 are unused
1
2 blue
Description V- (BUS-) data low (CAN L)
3 clear shield (Drain)
4 white data high (CAN H)
5 red
V+ (BUS+)
DeviceNet Connector Pin Color 1 clear shield (Drain) V+ (BUS+)
Description
2 red
3 black
V- (BUS-)
4 white data high (CAN H)
5 blue data low (CAN L)
Figure 1. DN120 Integrated with Allen Bradley SLC500
Microscan Systems, Inc.
36