libiec61850  1.2.0
Typedefs | Enumerations | Functions
Client side control service functions

Typedefs

typedef struct sControlObjectClient * ControlObjectClient
 
typedef void(* CommandTerminationHandler) (void *parameter, ControlObjectClient controlClient)
 Private a callback handler that is invoked when a command termination message is received. More...
 

Enumerations

enum  ControlModel {
  CONTROL_MODEL_STATUS_ONLY, CONTROL_MODEL_DIRECT_NORMAL, CONTROL_MODEL_SBO_NORMAL, CONTROL_MODEL_DIRECT_ENHANCED,
  CONTROL_MODEL_SBO_ENHANCED
}
 

Functions

ControlObjectClient ControlObjectClient_create (const char *objectReference, IedConnection connection)
 Create a new client control object. More...
 
void ControlObjectClient_destroy (ControlObjectClient self)
 
char * ControlObjectClient_getObjectReference (ControlObjectClient self)
 
ControlModel ControlObjectClient_getControlModel (ControlObjectClient self)
 
bool ControlObjectClient_operate (ControlObjectClient self, MmsValue *ctlVal, uint64_t operTime)
 Send an operate command to the server. More...
 
bool ControlObjectClient_select (ControlObjectClient self)
 
bool ControlObjectClient_selectWithValue (ControlObjectClient self, MmsValue *ctlVal)
 Send an select with value command to the server. More...
 
bool ControlObjectClient_cancel (ControlObjectClient self)
 
void ControlObjectClient_setLastApplError (ControlObjectClient self, LastApplError lastAppIError)
 
LastApplError ControlObjectClient_getLastApplError (ControlObjectClient self)
 
void ControlObjectClient_setTestMode (ControlObjectClient self, bool value)
 
void ControlObjectClient_setOrigin (ControlObjectClient self, const char *orIdent, int orCat)
 
void ControlObjectClient_useConstantT (ControlObjectClient self, bool useConstantT)
 Use a constant T parameter for all command (select, operate, cancel) of a single control sequence. More...
 
void ControlObjectClient_enableInterlockCheck (ControlObjectClient self)
 
void ControlObjectClient_enableSynchroCheck (ControlObjectClient self)
 
void ControlObjectClient_setInterlockCheck (ControlObjectClient self, bool value)
 Set the value of the interlock check flag when a control command is sent. More...
 
void ControlObjectClient_setSynchroCheck (ControlObjectClient self, bool value)
 Set the value of the synchro check flag when a control command is sent. More...
 
void ControlObjectClient_setCommandTerminationHandler (ControlObjectClient self, CommandTerminationHandler handler, void *handlerParameter)
 

Detailed Description

Typedef Documentation

typedef void(* CommandTerminationHandler) (void *parameter, ControlObjectClient controlClient)

Private a callback handler that is invoked when a command termination message is received.

This callback is invoked whenever a CommandTermination+ or CommandTermination- message is received. To distinguish between a CommandTermination+ and CommandTermination- please use the ControlObjectClient_getLastApplError function.

Parameters
selfthe ControlObjectClient instance
handlerthe callback function to be used
handlerParameteran arbitrary parameter that is passed to the handler
typedef struct sControlObjectClient* ControlObjectClient

Enumeration Type Documentation

Enumerator
CONTROL_MODEL_STATUS_ONLY 
CONTROL_MODEL_DIRECT_NORMAL 
CONTROL_MODEL_SBO_NORMAL 
CONTROL_MODEL_DIRECT_ENHANCED 
CONTROL_MODEL_SBO_ENHANCED 

Function Documentation

bool ControlObjectClient_cancel ( ControlObjectClient  self)
ControlObjectClient ControlObjectClient_create ( const char *  objectReference,
IedConnection  connection 
)

Create a new client control object.

A client control object is used to handle all client side aspects of a controllable data object.

Parameters
objectReferencethe reference of the controllable data object
connectionthe connection instance where the control object has to be reached
Returns
the newly created instance or NULL if the creation failed
void ControlObjectClient_destroy ( ControlObjectClient  self)
void ControlObjectClient_enableInterlockCheck ( ControlObjectClient  self)
Deprecated:
use ControlObjectClient_setInterlockCheck instead
void ControlObjectClient_enableSynchroCheck ( ControlObjectClient  self)
Deprecated:
use ControlObjectClient_setSynchroCheck instead
ControlModel ControlObjectClient_getControlModel ( ControlObjectClient  self)
LastApplError ControlObjectClient_getLastApplError ( ControlObjectClient  self)
char* ControlObjectClient_getObjectReference ( ControlObjectClient  self)
bool ControlObjectClient_operate ( ControlObjectClient  self,
MmsValue ctlVal,
uint64_t  operTime 
)

Send an operate command to the server.

Parameters
selfthe control object instance to use
ctlValthe control value (for APC the value may be either AnalogueValue (MMS_STRUCT) or MMS_FLOAT/MMS_INTEGER
operTimethe time when the command has to be executed (for time activated control). If this value is 0 the command will be executed instantly.
Returns
true if operation has been successful, false otherwise.
bool ControlObjectClient_select ( ControlObjectClient  self)
bool ControlObjectClient_selectWithValue ( ControlObjectClient  self,
MmsValue ctlVal 
)

Send an select with value command to the server.

Parameters
selfthe control object instance to use
ctlValthe control value (for APC the value may be either AnalogueValue (MMS_STRUCT) or MMS_FLOAT/MMS_INTEGER
Returns
true if select has been successful, false otherwise.
void ControlObjectClient_setCommandTerminationHandler ( ControlObjectClient  self,
CommandTerminationHandler  handler,
void *  handlerParameter 
)
void ControlObjectClient_setInterlockCheck ( ControlObjectClient  self,
bool  value 
)

Set the value of the interlock check flag when a control command is sent.

Parameters
selfthe ControlObjectClient instance
valueif true the server will perform a interlock check if supported
void ControlObjectClient_setLastApplError ( ControlObjectClient  self,
LastApplError  lastAppIError 
)
void ControlObjectClient_setOrigin ( ControlObjectClient  self,
const char *  orIdent,
int  orCat 
)
void ControlObjectClient_setSynchroCheck ( ControlObjectClient  self,
bool  value 
)

Set the value of the synchro check flag when a control command is sent.

Parameters
selfthe ControlObjectClient instance
valueif true the server will perform a synchro check if supported
void ControlObjectClient_setTestMode ( ControlObjectClient  self,
bool  value 
)
void ControlObjectClient_useConstantT ( ControlObjectClient  self,
bool  useConstantT 
)

Use a constant T parameter for all command (select, operate, cancel) of a single control sequence.

NOTE: Some non-standard compliant servers may require this to accept oper/cancel requests

Parameters
selfthe ControlObjectClient instance
useContantTenable this behaviour with true, disable with false