Object Model

DeviceNet™ is based on an abstract object model. This model defines the organization and implementation of the attributes (data), services (methods, procedures) and the behavior of the individual components of a DeviceNet™ subscriber. The complete definition is part of the corresponding specification that can be obtained from the ODVA. The model provides a four-step addressing schema for each attribute. The first level is the NodeAddress (MAC ID, bus address), the second is the Object Class Identifier, the third level is the Instance Number and the last level is the Attribute Number.

Classes

Each DeviceNet™ module contains a collection of objects where each object has a certain class. The DeviceNet™ standard already contains the definition of many standard classes. These standard classes describe, for example, fundamental properties, the communication behavior or parameters of individual channels of a subscriber. In addition, further manufacturer-specific classes can be defined for a DeviceNet™ module.

The definition of classes can be compared to the definition of STRUCT data types or function blocks included in libraries. When defining a structure, no data are created at first. Only a possible data format is described. If a function block library is inserted into a project, the included function blocks are not executed. The library only contains descriptions of the available function blocks.

Objects and instances

Each DeviceNet™ subscriber contains one or several objects of the different classes. An object is an instance of a class. Depending on the type of class, only one object or several objects of this class can be available. The instances are numbered continuously.

This is comparable with the creation of variables of previously defined STRUCT types. For a library, this corresponds to the insertion of a function block included in the library into the project. After a symbolic name has been entered, an instance of this type is generated in the project.

Attributes

Data (attributes) are combined in an object instance. These attributes describe the different properties of a DeviceNet™ module and can be (partly) read or written by other modules via the bus.

In relation to the STRUCT variables in a project, attributes can be compared with the individual elements of a structure. Reading and writing the individual elements is done by assignments in the program. For function blocks, the inputs and outputs can be seen as attributes.

Standard objects

The standard objects described below are contained in any DeviceNet™ module, provided no other information is available in this document. Some information contained in these objects are, for example, read automatically by a DeviceNet™ master from the particular device when commissioning the bus and are then compared with the required configuration. When establishing the communication connections during the boot process of the system, a master writes objects to the assigned slaves. This informs the slave how it has to use the bus.

Each DeviceNet™ module has an instance of the Identity Object (class identifier 1, instance number 1). Parts of this instance are, for example, the attributes manufacturer code, device type, product code, version identifier, status, serial number and product name. This information can be read out from a device using the DeviceNet service Get_Attribute_Single. The following table shows the structure of the Identity Object.

Identity Object: class identifier 1, instance number 1

Attribute

No.

Attribute name Data format Description Implementation
1 Vendor ID UINT Manufacturer identifier required
2 Device Type UINT Device type required
3 Product Code UINT Product number required
4

Major Revision

Minor Revision

USINT USINT Version identifier required
5 Status WORD General status required
6 Serial Number UDINT Serial number required
7 Product Name STRING(32) Product name required
8 State USINT Current state optional
9 Configuration Consistency Value UINT Device configuration optional
10 Heartbeat Interval USINT Time interval in seconds optional

In addition, DeviceNet™ modules have an instance of the Message Router Object. The Message Router Object is part of a device which explicitly routes messages to other objects. Usually it is not possible to directly access this object within the DeviceNet network.

The instance of a DeviceNet™ object of a device contains the attributes (data) bus address (MAC ID), baud rate, bus off reaction, bus off counter, allocation selection and the MAC ID of the master. These data are also accessed using the Get_Attribute_Single service.

DeviceNet™ modules have at least one Assembly Object. The main task of these objects is to combine different attributes (data) of different Application Objects into one attribute that can be transmitted in one single message.

In addition, DeviceNet™ modules have at least two Connection Objects. Each Connection Object represents one end point of a virtual connection between two subscribers of a DeviceNet network. These virtual connections are named explicit messaging and I/O messaging (refer to the description above). Explicit messages contain the address and value of an attribute as well as a service identifier that describes how the data are handled. In contrast, an I/O message contains only data. The information how the data have to be handled are contained in the Connection Object to which this message is assigned.

The Parameter Object is an optional object and is only used by devices which have adjustable parameters. An own instance is available for each parameter. The Parameter Object provides standardized access to all parameters for the configuration tools. The configuration options are attributes of the Parameter Object and can be, for example, a value range or scaling of channels, texts or limits.

Normally, at least one Application Object exists in each DeviceNet™ module in addition to the objects of the assembly or parameter class. At this point, these objects are not described in detail. A description can be found in the DeviceNet™ Object library.