Echelon OpenLNS User Manual
Page 479
OpenLNS Programmer's Reference
442
switch. In OpenLNS, function blocks are represented by
objects.
Some custom device interfaces support dynamic
LonMarkObject objects, which means that you can add them
to the interface manually. You can determine if an interface
objects by reading the
device interface does not support dynamic function blocks,
this property will be set to 0, and use of the Add method will
cause the LCA, #119 lcaErrInterfaceNotModifyable
exception to be thrown.
If the device interface supports dynamic function blocks, the
value greater than 0, and you can add function blocks to the
interface with this method.
Note that you cannot add LonMarkObjects to a device’s main
property of that
may be set to a non-zero value. The
main interface of a device is stored in its
The custom interfaces of a devices are stored in its Interfaces
object will be set to match the name specified
as the fbName element.
The name assigned to the
objects on each
device must be unique. If you attempt to use a name that is
already used on a device when adding a new
object, the operation will fail, and the LCA, #151
lcaErrUniqueNameRequired exception will be thrown.
Echelon recommends that you make sure all
objects in the OpenLNS database have unique names.
Availability
newLonMarkObject = LonMarkObjects.Add fbName, fbType
Syntax
objectColl.Add name
Element
Description
newLonMarkObjec
t
returned by the
function. This is the newly defined
LonMarkObjects
collection to be
acted upon.
fbName
The name of the function block to be
created. This can be a maximum of
16 characters long, and must conform
to the character restrictions defined
in version 3.3 the LonMark
Application Layer Interoperability
Guidelines. These restrictions are
that the name must not begin with a
number, and it cannot include square