CDN36X User Manual
revision 1.30
Serial Receive Object
The
Serial Receive Object
processes the Message Packet bytes, converting them into an input
data value that is returned to the DeviceNet master in an I/O Response Message. The Message
Packet bytes can be converted into a
Short_String
data type (byte array, with 1
st
byte = length).
ASCII characters within the Message Packet representing a numerical value can also be
converted into signed or unsigned integer or real number data types. The
Serial Receive Object
can be configured to search for
Pre-String
and/or
Post-String
byte strings at the beginning and/or
end of the desired data bytes. The data bytes framed by the
Pre-String
and
Post-String
bytes are
then converted into a Short_String, integer, or real number. The following examples show how
the
Serial Receive Object
can be configured to process a Message Packet.
Pre-String
Data
Post-String
Received Message Packet
other bytes
other bytes
‘VALUE = 100 F’
Message Packet Bytes (ASCII)
1) Short_String
data size = 14
Use Data Field
2) Short_String
data size = 5
Use Data Field
3) Short_String
data size = 4
Use Pre-String
Use Data Field
Use-Post-String
4) Integer (USINT)
data size = 1
Use Pre-String
Use Data Field
Use-Post-String
13, ‘VALUE = 100 F’
4, ‘VALU’
8, ‘VALUE = ‘
3, ‘100’
2, ‘ F’
8, ‘VALUE = ‘
0x64
2, ‘ F’
You can configure up to 8
Serial Receive Object
Instances, allowing you to process a received
message packet against 8 different filters. Each enabled Instance parses through the message
packet, consuming bytes based on its configuration. When an Instance is finished, the remaining
message packet bytes are passed to the next enabled Instance. The
Serial Receive Object
sequentially processes a message packet in order of Instance number, starting with Instance 1.
The processing continues until either all message packet bytes have been consumed or all the
enabled Instances are done. If an Instance cannot find a string of message bytes that matches its
configuration, no message packet bytes are consumed and are passed to the next Instance. The
following examples show how the
Serial Receive Object
Instances process a received message
packet.
Received Message Packet
unused bytes
unused bytes
unused bytes
Data
Data
Pre-String
Post-String
Data
Post-String
Data
Pre-String
Instance 1 bytes
Instance 2 bytes
Instance 3 bytes
Instance 4 bytes
MKS Instruments, Inc.
D.I.P. Products Group
14