ProSoft Technology MVI56E-GSC/ GSCXT User Manual

Page 106

Advertising
background image

Reference

MVI56E-GSC ♦ CompactLogix or MicroLogix Platform

User Manual

Enhanced Generic ASCII Serial Communication Module

Page 106 of 140

ProSoft Technology, Inc.

May 9, 2014

GSC.DATA Array

The GSC.DATA array is composed of two major sub-arrays, GSC.DATA.Port1
and GSC.DATA.Port2. Each sub-array contains all the tags necessary to hold
incoming and outgoing ASCII string data for the application serial ports. The
values in these arrays can be displayed as byte values or ASCII characters.
Setting the tag array Style to ASCII

will show the array elements as alpha-

numeric characters. Setting the tag Style to D

ECIMAL

will allow you to see the raw

byte values held in the array. This is useful to be able to verify non-printing ASCII
code values which do not show as identifiable characters.

GSC.DATA.PortX.ReadLength
This parameter reflects the number of characters received in the last string.

GSC.DATA.PortX.ReadString
The tag arrays, GSC.DATA.PortX.ReadString, are arrays of 4096 single-byte
integer values, capable of holding binary byte values, which can also be
interpreted as ASCII codes for alpha-numeric string characters. Since the port
receive buffer can hold incoming strings of up to 4096 characters, this array has
been sized to allow it to hold the largest possible received string. The ladder logic
will place all application serial port data received in backplane transfers from the
module into this array. If the received string is larger than 200 characters (bytes),
multiple block transfers will be needed to get the entire string into the ReadString
array.

GSC.DATA.PortX.WriteLength
This 16-bit integer tag serves a double purpose. Its primary purpose is to hold the
number of ASCII characters (or number of single-byte integer values) that need
to be transmitted from the application serial port. This tag is also used by the
sample logic as a trigger to know when to send strings though the output data
image block across the backplane (or process network, for remote rack
applications) to the module to be transmitted by the serial port.

Advertising