Read cip data – Rockwell Automation 1768-EWEB EtherNet/IP Web Server Module User Manual User Manual

Page 95

Advertising
background image

Publication ENET-UM527E-EN-P - October 2006

Create Custom Web Pages 95

Read CIP Data

There are two ASP functions you can use to read CIP data.

Function:

CIPMessage(path, service, class, instance,

attribute, member, data, returntype)

The

CIPMessage

function performs the CIP service specified by the

service

parameter on an object or object instance specified by the

class

,

instance

,

attribute

, and

member

parameters, using the

data passed in the

data

parameter (if necessary) and returning the

value with a type specified by the

returntype

parameter (if

appropriate).

Parameters:

Example:

For example, a GET_ATTRIBUTE_ALL to the identity object of a
device in slot 1 of the local chassis:

<% CIPMessage("1,1", 1, 1, 1, 0, 0,"","STRING"); %>

This ASP call returns a string similar to:

01 00 0E 00 03 00 0C 0C 70 30 63 2E 08 00 1D 31 37 35

36 2D 4C 31 2F 41 20 31 37 35 36 2D 4D 30 2F 30 20 41

52 47 5F 31 32 5F 33 38

If You Want

Use This ASP Function

See Page

Connected messaging

CIPMessage

96

Unconnected messaging

CIPMessageUnconnected

96

Parameter

Description

path

The path is a CIP path, with no spaces, and segments separated by commas. This is the
same as the path parameter in the read-controller-tag functions.

service

The service identifies the CIP function to perform.

class

The class, instance, attribute, and member parameters identify the object for the service.

If a service does not use an instance, attribute, and/or member, pass the parameters as 0.

instance

attribute

member

data

The data to be passed. If no data is passed in the request, set the data parameter to an
empty string.

returntype

The returntype parameter is the same as the tagtype parameter used in the
read-controller-tag functions, except when a returntype of “STRING” is specified, the data
returned from the service is written to the browser as a space-delimited string of
hex digits.

Advertising
This manual is related to the following products: