B&B Electronics MODSCAN32 - Manual User Manual
Page 40

40
Testing Features
Writing Data
In order to write a MODBUS data point in a slave device, the communications with the device must first be
initiated by scanning a series of data points by configuring the correct addressing information and initiating
a polling cycle. Once the data is successfully displayed, double-clicking the address/value portion of the
screen will initiate a dialog box which allows the value to be changed. If the polling cycle has been
configured to represent coil addresses, double-clicking an address will initiate the Change Coil Dialog:
The Change Register Dialog Box may be initiated by configuring the display to represent register data and
double clicking on an address:
Register values may be written using binary, decimal, hexadecimal, or floating-point notation, depending on
the preference selection currently in effect.
Pressing the Update Button in either write data point dialog will initiate the appropriate MODBUS write
command, (05 or 06), during the next scheduled poll.
Message Counters
Each document maintains a counter for each query message transmitted to a modbus slave device and a
counter for each correct response returned from the addresses slave. The counters for a given document
may be reset via a button control accessible via the upper, (data definition), splitter view. A total count of
all message counters from all active documents, (including any OLE Automation client documents), is
displayed via the ModScan status bar.
Viewing Serial Traffic
Use this command to troubleshoot the connection to a particular modbus device. When selected, this option
will display the serial data exchanged between the ModScan application and the slave device associated
with this document. The data display splitter view will show data transmitted to the slave device and data
returned from the slave device as communications occur during the normal polling cycle. This will help to
isolate a problem with possible misinterpretation of the modbus protocol. Data will be displayed in either
decimal or hex, depending upon the preference settings in effect for viewing the modbus data points.
Normal data collection, (if enabled), will continue.
Capturing Data
Use this command to store the results of each modbus query to an ASCII text file. Data is written to the
specified file, (one scan per line), in the format selected for display in the lower splitter view, (i.e. decimal,
hex, float). If an error was encountered during the polling transaction, the error message will be logged to
the file rather than the data. There is no “wrap-around” feature for collecting data. New data is appended
to the file on each query and the file can become very large vary fast if used with a short scan frequency.
The ability to save modbus data directly to a database is an optional feature of ModScan. If the feature is
unavailable, the Database Capture menu selection will be grayed out and not accessible. If enabled, this
command allows you to store the results of each query into an active Microsoft compatible database for
interfacing modbus data with custom designs.