Skip to content

Commit

Permalink
- fixed examples that have control handlers with old signature
Browse files Browse the repository at this point in the history
  • Loading branch information
mzillgith committed Apr 25, 2020
1 parent 0bc0145 commit a6bad96
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions demos/beaglebone/beagle_demo.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ connectionIndicationHandler(IedServer server, ClientConnection connection, bool
}

static CheckHandlerResult
performCheckHandler(void* parameter, MmsValue* ctlVal, bool test, bool interlockCheck, ClientConnection connection)
performCheckHandler(ControlAction action, void* parameter, MmsValue* ctlVal, bool test, bool interlockCheck, ClientConnection connection)
{
if (controllingClient == NULL) {
printf("Client takes control -> switch to remote control operation mode\n");
Expand Down Expand Up @@ -101,7 +101,7 @@ updateLED3stVal(bool newLedState, uint64_t timeStamp) {
}

static ControlHandlerResult
controlHandlerForBinaryOutput(void* parameter, MmsValue* value, bool test)
controlHandlerForBinaryOutput(ControlAction action, void* parameter, MmsValue* value, bool test)
{
if (test)
return CONTROL_RESULT_OK;
Expand Down Expand Up @@ -151,7 +151,7 @@ static int ledOffTimeMs = 1000;
static int32_t opCnt = 0;

static ControlHandlerResult
controlHandlerForInt32Controls(void* parameter, MmsValue* value, bool test)
controlHandlerForInt32Controls(ControlAction action, void* parameter, MmsValue* value, bool test)
{
if (test)
return CONTROL_RESULT_OK;
Expand Down
2 changes: 1 addition & 1 deletion examples/server_example_61400_25/server_example_61400_25.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ void sigint_handler(int signalId)


bool
controlHandlerForIntegerOutput(void* parameter, MmsValue* value, bool test)
controlHandlerForIntegerOutput(ControlAction action, void* parameter, MmsValue* value, bool test)
{
if (MmsValue_getType(value) != MMS_INTEGER)
return false;
Expand Down
2 changes: 1 addition & 1 deletion examples/server_example_basic_io/server_example_basic_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ sigint_handler(int signalId)
}

static ControlHandlerResult
controlHandlerForBinaryOutput(void* parameter, MmsValue* value, bool test)
controlHandlerForBinaryOutput(ControlAction action, void* parameter, MmsValue* value, bool test)
{
if (test)
return CONTROL_RESULT_FAILED;
Expand Down
2 changes: 1 addition & 1 deletion examples/server_example_goose/server_example_goose.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ void sigint_handler(int signalId)
}

void
controlHandlerForBinaryOutput(void* parameter, MmsValue* value)
controlHandlerForBinaryOutput(ControlAction action, void* parameter, MmsValue* value)
{
uint64_t timestamp = Hal_getTimeInMs();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ clientAuthenticator(void* parameter, AcseAuthenticationParameter authParameter,
}

static CheckHandlerResult
performCheckHandler (void* parameter, MmsValue* ctlVal, bool test, bool interlockCheck, ClientConnection connection)
performCheckHandler (ControlAction action, void* parameter, MmsValue* ctlVal, bool test, bool interlockCheck, ClientConnection connection)
{
void* securityToken = ClientConnection_getSecurityToken(connection);

Expand All @@ -99,7 +99,7 @@ performCheckHandler (void* parameter, MmsValue* ctlVal, bool test, bool interloc
}

static void
controlHandlerForBinaryOutput(void* parameter, MmsValue* value, bool test)
controlHandlerForBinaryOutput(ControlAction action, void* parameter, MmsValue* value, bool test)
{
MmsValue* timeStamp = MmsValue_newUtcTimeByMsTime(Hal_getTimeInMs());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ sigint_handler(int signalId)
}

ControlHandlerResult
controlHandlerForBinaryOutput(void* parameter, MmsValue* value, bool test)
controlHandlerForBinaryOutput(ControlAction action, void* parameter, MmsValue* value, bool test)
{

if (MmsValue_getType(value) == MMS_BOOLEAN) {
Expand Down
2 changes: 1 addition & 1 deletion examples/tls_server_example/tls_server_example.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ sigint_handler(int signalId)
}

static ControlHandlerResult
controlHandlerForBinaryOutput(void* parameter, MmsValue* value, bool test)
controlHandlerForBinaryOutput(ControlAction action, void* parameter, MmsValue* value, bool test)
{
if (test)
return CONTROL_RESULT_FAILED;
Expand Down

0 comments on commit a6bad96

Please sign in to comment.