libiec61850  1.6.0
Data Structures | Enumerations | Functions
iec61850_model.h File Reference
#include "iec61850_common.h"

Go to the source code of this file.

Data Structures

struct  IedModel
 Root node of the IEC 61850 data model. This is usually created by the model generator tool (genmodel.jar) More...
 
struct  LogicalDevice
 IEC 61850 data model element of type logical device. More...
 
struct  ModelNode
 abstract base type for IEC 61850 data model nodes More...
 
struct  LogicalNode
 IEC 61850 data model element of type logical node. More...
 
struct  DataObject
 IEC 61850 data model element of type data object. More...
 
struct  DataAttribute
 IEC 61850 data model element of type data attribute. More...
 
struct  DataSetEntry
 
struct  DataSet
 
struct  ReportControlBlock
 
struct  LogControlBlock
 
struct  Log
 
struct  SettingGroupControlBlock
 IEC 61850 data model of setting group control block (SGCB) More...
 
struct  GSEControlBlock
 
struct  SVControlBlock
 

Enumerations

enum  DataAttributeType {
  IEC61850_UNKNOWN_TYPE = -1 , IEC61850_BOOLEAN = 0 , IEC61850_INT8 = 1 , IEC61850_INT16 = 2 ,
  IEC61850_INT32 = 3 , IEC61850_INT64 = 4 , IEC61850_INT128 = 5 , IEC61850_INT8U = 6 ,
  IEC61850_INT16U = 7 , IEC61850_INT24U = 8 , IEC61850_INT32U = 9 , IEC61850_FLOAT32 = 10 ,
  IEC61850_FLOAT64 = 11 , IEC61850_ENUMERATED = 12 , IEC61850_OCTET_STRING_64 = 13 , IEC61850_OCTET_STRING_6 = 14 ,
  IEC61850_OCTET_STRING_8 = 15 , IEC61850_VISIBLE_STRING_32 = 16 , IEC61850_VISIBLE_STRING_64 = 17 , IEC61850_VISIBLE_STRING_65 = 18 ,
  IEC61850_VISIBLE_STRING_129 = 19 , IEC61850_VISIBLE_STRING_255 = 20 , IEC61850_UNICODE_STRING_255 = 21 , IEC61850_TIMESTAMP = 22 ,
  IEC61850_QUALITY = 23 , IEC61850_CHECK = 24 , IEC61850_CODEDENUM = 25 , IEC61850_GENERIC_BITSTRING = 26 ,
  IEC61850_CONSTRUCTED = 27 , IEC61850_ENTRY_TIME = 28 , IEC61850_PHYCOMADDR = 29 , IEC61850_CURRENCY = 30 ,
  IEC61850_OPTFLDS = 31 , IEC61850_TRGOPS = 32
}
 
enum  ModelNodeType { LogicalDeviceModelType , LogicalNodeModelType , DataObjectModelType , DataAttributeModelType }
 

Functions

LIB61850_API int ModelNode_getChildCount (ModelNode *self)
 get the number of direct children of a model node More...
 
LIB61850_API ModelNode * ModelNode_getChild (ModelNode *self, const char *name)
 return a child model node More...
 
LIB61850_API ModelNode * ModelNode_getChildWithIdx (ModelNode *self, int idx)
 return the child node of an array or other structure More...
 
LIB61850_API ModelNode * ModelNode_getChildWithFc (ModelNode *self, const char *name, FunctionalConstraint fc)
 return a child model node with a given functional constraint More...
 
LIB61850_API char * ModelNode_getObjectReference (ModelNode *self, char *objectReference)
 Return the IEC 61850 object reference of a model node. More...
 
LIB61850_API char * ModelNode_getObjectReferenceEx (ModelNode *node, char *objectReference, bool withoutIedName)
 Return the IEC 61850 object reference of a model node. More...
 
LIB61850_API ModelNodeType ModelNode_getType (ModelNode *self)
 Get the type of the ModelNode. More...
 
LIB61850_API const char * ModelNode_getName (ModelNode *self)
 Get the name of the ModelNode. More...
 
LIB61850_API ModelNode * ModelNode_getParent (ModelNode *self)
 Get the parent ModelNode of this ModelNode instance. More...
 
LIB61850_API LinkedList ModelNode_getChildren (ModelNode *self)
 Get the list of direct child nodes. More...
 
LIB61850_API void IedModel_setIedName (IedModel *self, const char *iedName)
 Set the name of the IED. More...
 
LIB61850_API ModelNode * IedModel_getModelNodeByObjectReference (IedModel *self, const char *objectReference)
 Lookup a model node by its object reference. More...
 
LIB61850_API SVControlBlock * IedModel_getSVControlBlock (IedModel *self, LogicalNode *parentLN, const char *svcbName)
 
LIB61850_API ModelNode * IedModel_getModelNodeByShortObjectReference (IedModel *self, const char *objectReference)
 Lookup a model node by its short (normalized) reference. More...
 
LIB61850_API ModelNode * IedModel_getModelNodeByShortAddress (IedModel *self, uint32_t shortAddress)
 Lookup a model node by its short address. More...
 
LIB61850_API LogicalDevice * IedModel_getDeviceByInst (IedModel *self, const char *ldInst)
 Lookup logical device (LD) by device instance name (SCL attribute "inst") More...
 
LIB61850_API LogicalDevice * IedModel_getDeviceByIndex (IedModel *self, int index)
 Lookup logical device (LD) instance by index. More...
 
LIB61850_API LogicalNode * LogicalDevice_getLogicalNode (LogicalDevice *self, const char *lnName)
 Lookup a logical node by name that is part of the given logical device. More...
 
LIB61850_API SettingGroupControlBlock * LogicalDevice_getSettingGroupControlBlock (LogicalDevice *self)
 Get the setting group control block (SGCB) of the logical device. More...
 
LIB61850_API void IedModel_setAttributeValuesToNull (IedModel *self)
 unset all MmsValue references in the data model More...
 
LIB61850_API LogicalDevice * IedModel_getDevice (IedModel *self, const char *ldName)
 Lookup logical device (LD) by device name. More...
 
LIB61850_API DataSet * IedModel_lookupDataSet (IedModel *self, const char *dataSetReference)
 Lookup a data set in the IED model. More...
 
LIB61850_API DataAttribute * IedModel_lookupDataAttributeByMmsValue (IedModel *self, MmsValue *value)
 Lookup a DataAttribute instance with the corresponding MmsValue instance. More...
 
LIB61850_API int IedModel_getLogicalDeviceCount (IedModel *self)
 Get the number of logical devices. More...
 
LIB61850_API int LogicalDevice_getLogicalNodeCount (LogicalDevice *self)
 
LIB61850_API ModelNode * LogicalDevice_getChildByMmsVariableName (LogicalDevice *self, const char *mmsVariableName)
 
LIB61850_API bool LogicalNode_hasFCData (LogicalNode *self, FunctionalConstraint fc)
 
LIB61850_API bool LogicalNode_hasBufferedReports (LogicalNode *self)
 
LIB61850_API bool LogicalNode_hasUnbufferedReports (LogicalNode *self)
 
LIB61850_API DataSet * LogicalNode_getDataSet (LogicalNode *self, const char *dataSetName)
 get a data set instance More...
 
LIB61850_API bool DataObject_hasFCData (DataObject *self, FunctionalConstraint fc)
 

Function Documentation

◆ DataObject_hasFCData()

LIB61850_API bool DataObject_hasFCData ( DataObject *  self,
FunctionalConstraint  fc 
)

◆ IedModel_getDevice()

LIB61850_API LogicalDevice* IedModel_getDevice ( IedModel *  self,
const char *  ldName 
)

Lookup logical device (LD) by device name.

Parameters
selfIedModel instance
ldInstthe logical device name (as it is seen from the protocol side - MMS domain name)
Returns
The matching LogicalDevice instance

◆ IedModel_getLogicalDeviceCount()

LIB61850_API int IedModel_getLogicalDeviceCount ( IedModel *  self)

Get the number of logical devices.

Parameters
selfIedModel instance
Returns
the number of logical devices

◆ IedModel_lookupDataAttributeByMmsValue()

LIB61850_API DataAttribute* IedModel_lookupDataAttributeByMmsValue ( IedModel *  self,
MmsValue value 
)

Lookup a DataAttribute instance with the corresponding MmsValue instance.

Parameters
selfIedModel instance
valuethe MmsValue instance (from the MMS value cache)
Returns
the matching DataAttribute instance

◆ IedModel_lookupDataSet()

LIB61850_API DataSet* IedModel_lookupDataSet ( IedModel *  self,
const char *  dataSetReference 
)

Lookup a data set in the IED model.

Parameters
selfIedModel instance
dataSetReferenceMMS mapping object reference! e.g. ied1Inverter/LLN0$dataset1
Returns
The matching DataSet instance

◆ IedModel_setAttributeValuesToNull()

LIB61850_API void IedModel_setAttributeValuesToNull ( IedModel *  self)

unset all MmsValue references in the data model

Parameters
selfthe IedModel instance that holds the model node

◆ LogicalDevice_getChildByMmsVariableName()

LIB61850_API ModelNode* LogicalDevice_getChildByMmsVariableName ( LogicalDevice *  self,
const char *  mmsVariableName 
)

◆ LogicalDevice_getLogicalNodeCount()

LIB61850_API int LogicalDevice_getLogicalNodeCount ( LogicalDevice *  self)

◆ LogicalNode_getDataSet()

LIB61850_API DataSet* LogicalNode_getDataSet ( LogicalNode *  self,
const char *  dataSetName 
)

get a data set instance

Parameters
selfthe logical node instance of the data set
dataSetNamethe name of the data set
Returns
the data set instance or NULL if the data set does not exist

◆ LogicalNode_hasBufferedReports()

LIB61850_API bool LogicalNode_hasBufferedReports ( LogicalNode *  self)

◆ LogicalNode_hasFCData()

LIB61850_API bool LogicalNode_hasFCData ( LogicalNode *  self,
FunctionalConstraint  fc 
)

◆ LogicalNode_hasUnbufferedReports()

LIB61850_API bool LogicalNode_hasUnbufferedReports ( LogicalNode *  self)