libIEC61850
1.0.0
Open-source IEC 61850 MMS/GOOSE/SV server and client library
|
Functions | |
IedServer | IedServer_create (IedModel *iedModel) |
Create a new IedServer instance. More... | |
void | IedServer_destroy (IedServer self) |
Destroy an IedServer instance and release all resources (memory, TCP sockets) More... | |
void | IedServer_start (IedServer self, int tcpPort) |
Start handling client connections. More... | |
void | IedServer_stop (IedServer self) |
Stop handling client connections. More... | |
void | IedServer_startThreadless (IedServer self, int tcpPort) |
Start handling client connection for non-threaded mode. More... | |
int | IedServer_waitReady (IedServer self, unsigned int timeoutMs) |
void | IedServer_processIncomingData (IedServer self) |
handle incoming TCP data in non-threaded mode More... | |
void | IedServer_performPeriodicTasks (IedServer self) |
perform periodic background tasks in non-threaded mode More... | |
void | IedServer_stopThreadless (IedServer self) |
Stop handling client connections for non-threaded mode. More... | |
IedModel * | IedServer_getDataModel (IedServer self) |
Return the data model of the server. More... | |
bool | IedServer_isRunning (IedServer self) |
Check if IedServer instance is listening for client connections. More... | |
MmsServer | IedServer_getMmsServer (IedServer self) |
Get access to the underlying MmsServer instance. More... | |
IsoServer | IedServer_getIsoServer (IedServer self) |
get the IsoServer instance for this IedServer object More... | |
void | IedServer_enableGoosePublishing (IedServer self) |
Enable all GOOSE control blocks. More... | |
void | IedServer_disableGoosePublishing (IedServer self) |
Disable all GOOSE control blocks. More... | |
void | IedServer_setGooseInterfaceId (IedServer self, const char *interfaceId) |
Set the ethernet interface to be used by GOOSE publishing. More... | |
IedServer IedServer_create | ( | IedModel * | iedModel | ) |
Create a new IedServer instance.
iedModel | reference to the IedModel data structure to be used as IEC 61850 model of the device |
void IedServer_destroy | ( | IedServer | self | ) |
Destroy an IedServer instance and release all resources (memory, TCP sockets)
self | the instance of IedServer to operate on. |
void IedServer_disableGoosePublishing | ( | IedServer | self | ) |
Disable all GOOSE control blocks.
This will set the GoEna attribute of all configured GOOSE control blocks to false. This will stop GOOSE transmission.
self | the instance of IedServer to operate on. |
void IedServer_enableGoosePublishing | ( | IedServer | self | ) |
Enable all GOOSE control blocks.
This will set the GoEna attribute of all configured GOOSE control blocks to true. If this method is not called at the startup or reset of the server then configured GOOSE control blocks keep inactive until a MMS client enables them by writing to the GOOSE control block.
self | the instance of IedServer to operate on. |
IedModel* IedServer_getDataModel | ( | IedServer | self | ) |
Return the data model of the server.
self | the instance of IedServer to operate on. |
get the IsoServer instance for this IedServer object
self | the instance of IedServer to operate on. |
Get access to the underlying MmsServer instance.
This function should be handled with care. Since direct interaction with the MmsServer can interfere with the IedServer.
self | the instance of IedServer to operate on. |
bool IedServer_isRunning | ( | IedServer | self | ) |
Check if IedServer instance is listening for client connections.
self | the instance of IedServer to operate on. |
void IedServer_performPeriodicTasks | ( | IedServer | self | ) |
perform periodic background tasks in non-threaded mode
The function should be called periodically. If the function is called more often the more accurate are internal timeouts (e.g. for reports).
self | the instance of IedServer to operate on. |
void IedServer_processIncomingData | ( | IedServer | self | ) |
handle incoming TCP data in non-threaded mode
The function should be called periodically. If the function is called more often the response time for incoming messages will be faster. As an alternative the function may only be called if new TCP data is available.
self | the instance of IedServer to operate on. |
void IedServer_setGooseInterfaceId | ( | IedServer | self, |
const char * | interfaceId | ||
) |
Set the ethernet interface to be used by GOOSE publishing.
This function can be used to set the GOOSE interface ID. If not used or set to NULL the default interface ID from stack_config.h is used. Note the interface ID is operating system specific!
self | the instance of IedServer to operate on. |
interfaceId | the ID of the ethernet interface to be used for GOOSE publishing |
void IedServer_start | ( | IedServer | self, |
int | tcpPort | ||
) |
Start handling client connections.
self | the instance of IedServer to operate on. |
tcpPort | the TCP port the server is listening |
void IedServer_startThreadless | ( | IedServer | self, |
int | tcpPort | ||
) |
Start handling client connection for non-threaded mode.
This function will instruct the TCP(IP stack to listen for incoming connections. In order to accept new connection the function IedServer_processIncomingData has to be called periodically.
self | the instance of IedServer to operate on. |
tcpPort | the TCP port the server is listening |
void IedServer_stop | ( | IedServer | self | ) |
Stop handling client connections.
self | the instance of IedServer to operate on. |
void IedServer_stopThreadless | ( | IedServer | self | ) |
Stop handling client connections for non-threaded mode.
self | the instance of IedServer to operate on. |
int IedServer_waitReady | ( | IedServer | self, |
unsigned int | timeoutMs | ||
) |