Вы находитесь на странице: 1из 34

WAGO-I/O-PRO 32 Library

WagoLibHART_02.lib
The library WagoLibHART_02.liboffers a set of function blocks to execute
HART-commands (Revision 5) in a PLC program.
The principal item of this library is program HART_INFO, it identifies
connected HART modules like 750-482 and coordinates the Kbus access.
In addition you find with HART_FDT program that act as counterpart to
WAGO-ModbusTCP-HART-DTM, who enable configuration of HART
devices with every FDT-Frameapplication like WAGOframe.

HART_INFO

Content
WagoLibHART_02.lib

HART_INFO ............................................................................................3
HART_FDT..............................................................................................4
HART_CMD0 ..........................................................................................5
HART_CMD1 ..........................................................................................7
HART_CMD2 ..........................................................................................9
HART_CMD3 ........................................................................................11
HART_CMD6 ........................................................................................13
HART_CMD11.......................................................................................15
HART_CMD12.......................................................................................17
HART_CMD13.......................................................................................19
HART_CMD14.......................................................................................21
HART_CMD15.......................................................................................23
HART_CMD16.......................................................................................25
HART_CMD17.......................................................................................27
HART_CMD18.......................................................................................29
HART_CMD19.......................................................................................31
HART_CMDCustom ..............................................................................33

2 WagoLibHART_02.lib

ml03801e

WAGO-I/O-PRO 32

WagoLibHART_02.lib
HART_INFO
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:

Communication
HART_INFO
Function
Function block
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program X

Inputparameters:
xStart

Data type:
BOOL

Comments:
Set program active

In-/Out parameters:
xReset

Data type:
BOOL

Comments:
Clean up resources

Outputparameters:
dwError

Data type:
DWORD

Comments:

sStatus

STRING

A textual description of programs current state

16#00000001 - 'ERROR: No HART modules found';


16#00000002 - 'ERROR: Number of HART modules
exceed the maximum of 8 modules';
16#00000003 - 'ERROR: HART module number x do not
operate in mode 8(Change mode with
IOCheck)';

Graphic display:

Function description:
This program identifies all connected HART-modules and coordinate the MailBox
communication via KBus.
The current config and state of each HART module is stored in "g_atHARTModules" in
VAR GLOBAL's.
g_atHARTModules : ARRAY [1..8] OF tHART_2AI (* Global List of HART modules *)
This program is the counter part of each HART application, because all other functionblocks need informations provided by HART_INFO.

HART_FDT

HART_FDT
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:

Communication
HART_FDT
Function
Function block
WagoLibHART_02.lib
mod_com.lib
750-841;

Program X

Inputparameters:
tTimeOut

Data type:
TIME

Comments:
Watchdog Timeout, default 10s

In-/Out parameters:

Data type:

Comments:

Outputparameters:
bMsgId
dwError

Data type:
BYTE
DWORD

Comments:

sStatus

STRING

A textual description of programs current state

Current Number of DPV1-Request to proceed.


16#00000001: No HART modules found.
16#00000002: Number of HART modules exceed the
maximum of 8 modules.
16#00000003: HART module number x do not operate in
mode 8 (Change mode with IOCheck).
16#00004xyz: Mailbox-Error -> contact support@wago.com

Graphic display:

Function description:
This program work as gateway for the WAGO-ModbusTCP-HART-GatewayDTM.
It waits for DPV1-Request over Modbus_TCP in PFC-IN-Area at %IW256 to process.
The DPV1-Response will be written to PFC-OUT-Area at %QW256.
Take care for dont using this Memory area in your application.
If an error occours the program performs a auto reset after the given tTimeout..
This program works at 750-841 only!

4 WagoLibHART_02.lib

ml03801e

WAGO-I/O-PRO 32

HART_CMD0
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD0
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD0

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD0:
'Read unique identifier

HART_CMD0

Graphic display:

Function description:
The HART_CMD0 "Read unique identifier".
The function block sends a HART command 0 request to a HART device and
processes the response.
There is no nees to use this functionblock in your application! You find all informations
in "g_atHARTModules"
g_atHARTModules : ARRAY [1..8] OF tHART_2AI;
(* Global List of HART modules - keep current config and state *)
RequestData:
None
ResponseData:
0
1
2
3
4
5
6
7
8
911 ->

6 WagoLibHART_02.lib

-> "254" (expansion)


-> Manufacturer identification code
-> Manufacturer device type code
-> Number of preambles required
-> Universal command revision
-> Device-specific command revision
-> Software revision
-> Hardware revision
-> Device function flags
-> Type:(H)
Device ID number
-> Type:(B)

ml03801e

WAGO-I/O-PRO 32

HART_CMD1
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD1
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD1

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD1: '
Read primary variable

HART_CMD1

Graphic display:

Function description:
The HART_CMD1 "Read primary variable".
The function block sends a HART command 1 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
0
-> PV units code
14
-> Primary variable

8 WagoLibHART_02.lib

ml03801e

-> Type:(B)
-> Type:(F)

WAGO-I/O-PRO 32

HART_CMD2
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD2
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD2

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD2:
'Read current and percent of range

HART_CMD2

Graphic display:

Function description:
The HART_CMD2 "Read current and percent of range".
The function block sends a HART command 2 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
03 -> Current (mA)
47 -> Percent of range

10 WagoLibHART_02.lib

ml03801e

-> Type:(F)
-> Type:(F)

WAGO-I/O-PRO 32

HART_CMD3
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD3
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD3

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD3:
' Read all variables

HART_CMD3

Graphic display:

Function description:
The HART_CMD3 "Read all variables".
The function block sends a HART command 3 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
03
-> Current (mA)
4
-> PV units code
58
-> Primary variable
9
-> SV units code
1013
-> Secondary variable
14
-> TV units code
1518
-> Third variable
19
-> FV units code
2023
-> Fourth variable

12 WagoLibHART_02.lib

ml03801e

-> Type:(F)
-> Type:(F)
-> Type:(F)
-> Type:(F)
-> Type:(F)

WAGO-I/O-PRO 32

HART_CMD6
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

bPollingAddress
In-/Out parameters:
xStart

Communication
HART_CMD6
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.
BYTE
Polling Adress (015)

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus

STRING

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state

HART_CMD6

Graphic display:

Function description:
The HART_CMD6 "Write polling address".
The function block sends a HART command 6 request to a HART device and
processes the response.
RequestData:
0
-> Polling address -> Type:?
ResponseData:
As in request
Note:
Using the polling address structure of the HART protocol, up to 15 devices
can be connected in a multidrop network. The analog device can be fixed by setting its
polling address to a number other than zero.

14 WagoLibHART_02.lib

ml03801e

WAGO-I/O-PRO 32

HART_CMD11
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:

Communication
HART_CMD11
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Inputparameters:
bModule

Data type:
BYTE

bChannel

BYTE

sTag

STRING(8)

In-/Out parameters:
xStart

Program

Comments:
Position or index of plugged HART module start
with one.
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.
Unit tag

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_C
MD0

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD0:
'Read unique identifier

HART_CMD11

Graphic display:

Function description:
The HART_CMD11 "Read unique identifier associated with input tag".
The function block sends a HART command 11 request to a HART device and
processes the response.
RequestData:
0-5
-> Unit tag(8 Characters) -> Type:(A)
ResponseData:
0
-> "254" (expansion)
1
-> Manufacturer identification code
2
-> Manufacturer device type code
3
-> Number of preambles required
4
-> Universal command revision
5
-> Device-specific command revision
6
-> Software revision
7
-> Hardware revision
8
-> Device function flags
-> Type:(H)
911 -> Device ID number
-> Type:(B)

16 WagoLibHART_02.lib

ml03801e

WAGO-I/O-PRO 32

HART_CMD12
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD12
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
sMessage

STRING
STRING
(32)

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD12:
' Read primary variable

HART_CMD12

Graphic display:

Function description:
The HART_CMD12 "Read message".
The function block sends a HART command 12 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
023

18 WagoLibHART_02.lib

-> Message (32 characters)

ml03801e

-> Type:(A)

WAGO-I/O-PRO 32

HART_CMD13
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD13
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD13

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD13:
'Read tag, descriptor and date

HART_CMD13

Graphic display:

Function description:
The HART_CMD13 "Read tag, descriptor and date".
The function block sends a HART command 13 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
0-5
-> Unit tag(8 Characters)
6-17
-> Unit description(16 Characters)
18-20 -> Unit date

20 WagoLibHART_02.lib

ml03801e

-> Type:(A)
-> Type:(A)
-> Type:(D)

WAGO-I/O-PRO 32

HART_CMD14
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD14
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD14

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD14:
'Read tag, descriptor and date

HART_CMD14

Graphic display:

Function description:
The HART_CMD14 "Read sensor serial number,Units code for sensor limits and
minimum span, Upper sensor limit, Lower sensor limit, Minimum span".
The function block sends a HART command 14 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
0-2
->
3
->
4-7
8-11
12-15

22 WagoLibHART_02.lib

->
->
->

Sensor serial number


Units code for sensor limits and
minimum span
Upper sensor limit
Lower sensor limit
Minimum span

ml03801e

->
->
-> Type:(F)
-> Type:(F)
-> Type:(F)

WAGO-I/O-PRO 32

HART_CMD15
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD15
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
stData

STRING
tHART_
CMD15

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD15:
'Read output information

HART_CMD15

Graphic display:

Function description:
The HART_CMD15 "Read output information".
The function block sends a HART command 15 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
0
1
2
3-6
7-10
11-14
15
16

24 WagoLibHART_02.lib

-> Alarm select code


-> Transfer function code
-> PV range unit code
-> Upper range value
-> Lower range value
-> DampingValue
(seconds)
-> Write protect code
-> Private-label describtor code

ml03801e

-> Type:(F)
-> Type:(F)
-> Type:(F)

WAGO-I/O-PRO 32

HART_CMD16
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

In-/Out parameters:
xStart

Communication
HART_CMD16
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus
dwFinalAssembly
Number

STRING
DWORD

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state


Represants the resultset of a HART CMD16:
'Read final assmbly number

HART_CMD16

Graphic display:

Function description:
The HART_CMD16 "Read final assembly number".
The function block sends a HART command 16 request to a HART device and
processes the response.
RequestData:
None
ResponseData:
02
-> Final assembly number

26 WagoLibHART_02.lib

ml03801e

-> Type:?

WAGO-I/O-PRO 32

HART_CMD17
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

sMessage

In-/Out parameters:
xStart

Communication
HART_CMD17
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.
STRING
Message to write
(32)

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus

STRING

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state

HART_CMD17

Graphic display:

Function description:
The HART_CMD17 "Write message".
The function block sends a HART command 17 request to a HART device and
processes the response.
RequestData:
023 -> Message (32 characters)
ResponseData:
As in request

28 WagoLibHART_02.lib

ml03801e

-> Type:(A)

WAGO-I/O-PRO 32

HART_CMD18
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

stData

In-/Out parameters:
xStart

Communication
HART_CMD18
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.
tHART_
Request data for HART CMD18:
CMD13

Write tag, descriptor and date

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus

STRING

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state

HART_CMD18

Graphic display:

Function description:
The HART_CMD18 Write tag, descriptor and date.
The function block sends a HART command 18 request to a HART device and
processes the response.
RequestData:
0-5
-> Unit tag(8 Characters)
6-17
-> Unit description(16 Characters)
18-20 -> Unit date
ResponseData:
As in request

30 WagoLibHART_02.lib

ml03801e

-> Type:(A)
-> Type:(A)
-> Type:(D)

WAGO-I/O-PRO 32

HART_CMD19
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

dwFinalAssembly
number
In-/Out parameters:
xStart

Communication
HART_CMD19
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.
DWORD
Request data for HART CMD19:

Write final assambly number

xReset

Data type: Comments:


BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus

STRING

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state

HART_CMD19

Graphic display:

Function description:
The HART_CMD19 "Write final assembly number".
The function block sends a HART command 19 request to a HART device and
processes the response.
RequestData:
02
-> Final assembly number
ResponseData:
As in request

32 WagoLibHART_02.lib

ml03801e

-> Type:?

WAGO-I/O-PRO 32

HART_CMDCustom
WAGO-I/O-PRO Library elements
Category:
Name:
Type:
Library name:
Used Libraries
Applicable to:
Inputparameters:
bModule
bChannel

bHART_CMD
In-/Out parameters:
xStart

xReset
abData
bDataCount

Communication
HART_CMDCustom
Function block X
Function
WagoLibHART_02.lib
mod_com.lib
750-841; 750-842; 750-833;

Program

Data type: Comments:


BYTE
Position or index of plugged HART module start
with one.
BYTE
The channel of the I/O-Module where the HART
device is connected.
Valid values are 1 and 2.
BYTE
The HARD-Command to process
Data type: Comments:
BYTE
A raising edge will start the execution of the
HART command.
When finished or after a timeout xStart is set to
false - Check dwError on the falling edge of
xStart
BYTE
CleanUp
ARRAY [] Additional request data and response data after
OF BYTE execution
BYTE
Number of additional request informations and
response data count after execution.

Outputparameters:
dwError

Data type: Comments:


16#00000301 => 'HART_INFO is not part of your project DWORD

sStatus

STRING

Add HART_INFO program'


16#00000302 => 'Invalid param "bModule" x. Valid values
between 1..64'
16#00000303 => 'Invalid param "bChannel" y. Valid values
between 1..2'
16#00000305 => 'No HART sensor connected to module x on
channel y'
16#00000306 => 'Invalid parameter "bModule" points to a non
HART module'
16#08xxyyzz => 'Response codes from HART module (Wago
module specif.)'
16#0900xxyy => 'Response codes from HART sensor (HART
specif.)'

A textual description of programs current state

HART_CMDCustom

Graphic display:

Function description:
The functionblock "HART_CMDCustom" allows the execution of any HART_CMD.
The function block sends a HART command request to a HART device and returns
the response as array of byte.
The interpretation of the response falls into the scope of user.

34 WagoLibHART_02.lib

ml03801e

WAGO-I/O-PRO 32

Вам также может понравиться