⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 scanguide.txt

📁 modbus的仿真软件,visual basic代码。
💻 TXT
📖 第 1 页 / 共 2 页
字号:

1.	ModScan Overview
	1.1	Document/View Architecture
	1.2	Modbus Data Definition
	1.3	Display Formats
	1.4	Connecting to a Modbus Network
		1.4.1	Direct Serial Connections
		1.4.2	Modem Connections
		1.4.3	Network Connections

2.	Menu Commands
	2.1	File menu
	2.2	Connection menu
	2.3	Setup menu
	2.4	View menu
	2.5	Window menu
	2.6	Help menu

3.	Tool & Status Bars
	3.1	Toolbar
	3.2	Format Selections
	3.3	Status Bar

4.	Testing Features
	4.1	Writing Data to the Modbus
	4.2	Message Counters
	4.3	Observing Serial Traffic
	4.4	Capturing Data to Text File
	4.5	User Defined Commands
	4.6	Scripts

5. 	Using ModScan with a Database

6.	Using OLE Automation
	6.1	Overview
	6.2	Automation Routines

7.	Distribution/Registration

	7.1	Pricing
	7.2 	Licensing
	7.3	Support
	7.4	Other Products


1.	ModScan Overview
The ModScan application operates as a MODBUS mastermodbus_protocol device
in either RTU or ASCII transmission modes.  ModScan may be used to access
and modify data points contained in one or more MODBUS slave devices
connected to the PC via a serial port, modem, or network.  ModScan supports
the standard MODBUS message types 01-06, 15 & 16, as well as providing
the ability for you to exercise special features of a slave device by
transmitting custom command strings and observing the response.  ModScan
is a useful test and diagnostic tool for verifying the proper slave
response to MODBUS queries as well as being a low cost data collection
tool for interfacing data into PC database and spreadsheet applications.

1.1	Document/View Architecture
ModScan utilizes the standard Windows Multiple-Document-Interface, (MDI),
architecture for displaying modbus data to the user.  Each document
represents a series, (array), of modbus data points identified by the 
following parameters:

Slave Device Address	Represents the physical device attached to 
				the modbus network
Data Type			Internal data representation, (i.e. input, coil, register)
Data Address		Point address within the device
Length			Number of points to scan/display


Associated with each document is also a timer, which is used to
periodically scan new data from the defined slave and refresh the
display.  The modbus data definition is accessible from the ModScan
menu or via edit controls in the top splitter window of the document
display.  As new data is obtained from the slave device, it is 
written to the bottom splitter window in one of several formats,
depending upon your preference.  The size of each document display
window is adjustable via the splitter control.

1.2	Modbus Data Definition
The upper half of each Document's View represents the data selected for
display, (and possible capture to a historical data file).  In most
testing applications, the ModScan will only be connected to a single
modbus slave device, however, in a multidrop modbus network, there may
be several devices accessible from a single connection.  The "Device Id"
edit control allows you to specify the slave address for the source of
the data.  Likewise, edit controls are available to select the point
type, data address, and number of data points to access.

Notice that the modbus protocol uses a 5-digit representation for the
slave data address which infers the point-type.  For example, 
INPUT STATUS values are always represented in the range 10001-19999:
HOLDING REGISTERS are displayed as 40000-49999.  The ModScan application
uses the standard notation for displaying data in the bottom splitter
window, however the address specified in the upper splitter address edit 
control assumes a 4-digit physical point address.  This address, coupled
with the point-type specifier completely defines the data to be accessed
in the slave device.

The upper splitter window also contains two counters which are used to
tally the number of data requests made from this document to the modbus
connection and the number of valid slave responses received in reply.
A button is available within the display which resets the counters
associated with this document. 

1.3	Display Formats
As data is received from the slave device, it is displayed to the lower
splitter view of the associated document.  Any errors incurred during
the exchange of information will be displayed on the first line.  The
font and colors used to display the data is configurable via the View,
Config menu options.

Modbus register data may be displayed in any of the following formats:

Binary			Data displayed as 16 discrete values.
Decimal			Ranges from -32767 to 32768
Hexadecimal			0000-ffff
Floating Point		IEEE Standard Floating Point Notation
				(Requires two registers per value)
Word-Swapped Floating Point
				Inverted Floating Point used by some processors
Double-Precision Floating Point
				64-bit Floating Point Notation
Word Swapped Dbl Precision
				Inverted 64-bit Float Values


1.4	Connecting to a Modbus Network

1.4.1	Direct Serial Connections
ModScan may be used to obtain data from modbus slave device connected
to the PC in one of three basic physical arrangements.  The most common
connection is via any one of the four available PC serial COM ports.
ModScan uses the standard Win32 software drivers for communication with
the COM ports, thereby providing support for any hardware serial boards
which may be installed in the Windows operating system, (including RS-232,
RS-485, etc.).  You have complete control over the operating characteristics
of the serial connection by selecting the appropriate baud rate, parity,
and control line, (handshaking), properties to match the slave device(s).

1.4.2	Modem Connections
In remote testing situations, the ModScan application may be used to
communicate with a modbus network over a dedicated modem connection.
ModScan supports the TAPI, (telephony application interface), standard 
implemented in Windows and Windows NT.  If selected, the modem connection
dialog allows you to enter a phone number for dialing.  Any TAPI device
configured within the Windows operating system is available for use.

It is also possible to connect via modem to a remote system utilizing
the built-in networking characteristics of Windows '95 & NT.  To do this,
you will need to configure the ModScan application to connect via a TCP/IP 
connection which has been setup within Windows to automatically dial and
establish a PPP connection with another Windows machine which is connected
directly to the slave device(s) you wish to use.  In this case, ModScan
operates as if it were using a network card connected directly to a
modbus to tcp/ip bridge device.

1.4.3	Network Connections
ModScan allows modbus communications to occur over a TCP/IP network.
This feature requires the use of a modbus to TCP/IP bridge device which
can service network requests from the network and obtain the data from
a connected slave device prior to responding to queries from the ModScan
application.  A bridge device operates as a network server, providing
support to numerous client applications distributed over the network.  
WinTECH Software provides such a server for interfacing to a single
serial modbus network.  Third-party vendors may provide various solutions
for interfacing TCP/IP to modbus devices via other hardware, (i.e. modbus
plus, etc.).  If the interfacing specification for these network bridge
devices is available in the public domain, they may be included in future
releases of the ModScan application.  If you have the need to use ModScan
with a third-party vendor's equipment, please contact the WinTECH Software
support line for consideration.


2.	Menu Commands

2.1	File menu
The File Menu offers the following commands:

New		Creates a new ModScan document.  Each document represents
		a different block of data from a modbus device.
Open		Opens an existing document.	
Close		Closes an open document.
Save		Saves an open document.
SaveAs	Saves an open document to a specified file name.
Print		Prints an open document.
Print Setup	Selects a Printer and Printer connection.
Exit		Exits ModScan

2.2	Connection menu
The Connect menu offers the following commands:

Connect	Attaches the ModScan application to a modbus network,
		enabling data collection.
Disconnect	Detaches the ModScan application from the network,
		freeing up resources for other Windows applications.

2.3	Setup menu
The Setup menu offers the following commands:

Data Definition	Defines the document properties of the modbus data to
			be scanned.
Display Options	Allows the document data to be viewed in a variety of
			formats.
	Show Data	-This default view configuration displays data values 
			as obtained from the modbus slave device.
	Show Traffic-This option allows the serial data stream to be 
			displayed in place of the data points.
	Binary	-Register values are displayed as 16 discrete bits.
	Decimal	-Register values are displayed in decimal format,
			(-32767-32768).
	Hex		-Register Values are displayed in Hexadecimal, 
			(0000-ffff).
	Floating Pt.-Register Values are displayed in floating point 
			notation, (two registers are required).
	Swapped FP	-Register Values are displayed in floating point 
			notation, (least significant register first).
	Dbl Float	-Register Values are displayed in floating point 
			notation, (four registers, (64 bits), are required).
	Swapped Dbl	-Register Values are displayed in floating point 
			notation, (least significant register first).
	Hex Addresses-Displays the addresses of data points in hexadecimal 
			notation..
Extended Options	Provides the ability to write data to a connected
			slave device.
	Force Coils	-Provides the ability to write coil values to a
			designated slave device.
	PreSet Registers-Provides the ability to write register values
			to a designated slave device.
	User Commands-Allows you to define and transmit a custom command.
	Script Files-Begins execution of a test script.
Text Capture	Begins collecting modbus data to a specified text file.
Dbase Capture	Begins collecting data into a defined database table.
Capture Off		Stops data collection.
Reset Counters	Clears all modbus message status counters in all
			documents.


2.4	View menu
The View menu offers the following commands:

Toolbar	Shows or hides the toolbar.
Status Bar	Shows or hides the status bar.
Display Bar	Shows or hides the format toolbar used to select the  display 
		format for modbus registers.
Config	Allows you to customize the appearance of ModScan by 
		selecting the colors and font used.
	Background Color-Selects the color for the ModScan data display
		splitter view.
	Foreground Color-Selects the text color used to display data values.
	Status Color-Selects the color used to show the modbus status line.
	Font	-Selects the font.

2.5	Window menu
The Window menu offers the following commands, which enable you to
arrange multiple views of multiple documents in the application window:

New Window	Creates a new window that views the same document.
Cascade	Arranges windows in an overlapped fashion.
Tile		Arranges windows in non-overlapped tiles.
Arrange Icons	Arranges icons of closed windows.
Window 1, 2, Goes to specified window.

2.6	Help menu
The Help menu offers the following commands, which provide you assistance
with this application: 

Help Topics	Offers you an index to topics on which you can get help.
About		Displays the version number of this application.

3.	Tool & Status Bars

3.1	Toolbar
The toolbar is displayed across the top of the application window, below
the menu bar.  The toolbar provides quick mouse access to many tools
used in ModScan.  The toolbar is detachable and dockable by clicking the 
mouse on the toolbar background and dragging it to the desired location
within the ModScan application window.

3.2	Format Selections
The format toolbar is displayed across the top of the application window,
below the menu bar.  The format toolbar provides quick mouse access to
select the format used by ModScan to display the contents of modbus 
registers.  The toolbar is detachable and dockable by clicking the mouse
on the toolbar background and dragging it to the desired location within
the ModScan application window.

3.3	Status Bar
The status bar is displayed at the bottom of the ModScan window.  To
display or hide the status bar, use the Status Bar command in the View
menu.

The left area of the status bar describes actions of menu items as you
use the arrow keys to navigate through menus.  This area similarly shows
messages that describe the actions of toolbar buttons as you depress them, 
before releasing them.  If after viewing the description of the toolbar
button command you wish not to execute the command, then release the
mouse button while the pointer is off the toolbar button.

The right areas of the status bar indicate the message counters for
all modbus message activity logged by the various active documents.

4.	Testing Features

4.1	Writing Data to the Modbus
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.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -