Skip to content

Commit

Permalink
- parse time values in model configuration file (LIB61850-426)
Browse files Browse the repository at this point in the history
  • Loading branch information
mzillgith committed Nov 21, 2023
1 parent ec9519a commit 7fee3e5
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/iec61850/server/model/config_file_parser.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@

#include "libiec61850_platform_includes.h"
#include "stack_config.h"
#include <inttypes.h>

#define READ_BUFFER_MAX_SIZE 1024

Expand Down Expand Up @@ -452,6 +453,15 @@ ConfigFileParser_createModelFromConfigFile(FileHandle fileHandle)
}
break;

case IEC61850_TIMESTAMP:
case IEC61850_ENTRY_TIME:
{
uint64_t value;
if (sscanf(valueIndicator + 1, "%" SCNu64, &value) != 1) goto exit_error;
dataAttribute->mmsValue = MmsValue_newUtcTimeByMsTime(value);
}
break;

default:
break;

Expand Down

0 comments on commit 7fee3e5

Please sign in to comment.