Using appl_stddrv() – Rockwell Automation 6001-F2E AB STANDARD DRIVER SFTW User Manual
Page 15
Writing Your Own Application Program
Chapter 4
4-2
After you have initialized the Standard Driver with the Open_StdDrv()
function call, you are ready to communicate. You can use the
Appl_StdDrv() function call (Application Library) or the Send_StdDrv()
function call or a combination of both. Use the SendStdDrv() function
call to format commands not supported by the Application Library. See
table 4.B for a list of commands supported by the Application Library.
The Appl_StdDrv() function formats DH-485 messages for the basic
command set and transmits them over the DH-485 network. Use the
Appl_StdDrv() with the selected PLC application symbol and
Appl_StdDrv() message block data structure. The application symbols
and the message block data structure are defined in the STDDRV.H header
files. Use the following format and parameters:
Format for Appl_StdDrv()
The Appl_StdDrv() function call is shown below:
status = Appl_StdDrv(SYMBOL, SD_FB *);
Parameter
Type
Description
SYMBOL
int
identifies the support routine symbol (see table 4.B)
SD_FB
struct
initializes the DH+ function block (see table 4.C)
See appendix D for return
status
values for the Appl_StdDrv()
function.
Parameters for Appl_StdDrv()
Table 4.B below shows the available functions (in the Application
Library) you can use with Appl_StdDrv(). Table 4.C shows the
Appl_StdDrv() message block data structure:
Table 4.B
6001-F2E Support Routines
To do this
Specify this
Diagnostic loop back testing
PLC_DLB
Read diagnostic counters
PLC_DCR
Read diagnostic status
PLC_DS
Reset diagnostic counters
PLC_RC
Basic command set unprotected read
PLC_UPR
Basic command set unprotected write
PLC_UWR
Communicating on DH-485 with
the 6001-F2E Standard Driver
Using Appl_StdDrv()