diff --git a/src/goose/goose_subscriber.c b/src/goose/goose_subscriber.c index f1d1e8ea..2bc01782 100644 --- a/src/goose/goose_subscriber.c +++ b/src/goose/goose_subscriber.c @@ -109,6 +109,12 @@ GooseSubscriber_isTest(GooseSubscriber self) return self->simulation; } +uint32_t +GooseSubscriber_getConfRev(GooseSubscriber self) +{ + return self->confRev; +} + bool GooseSubscriber_needsCommission(GooseSubscriber self) { diff --git a/src/goose/goose_subscriber.h b/src/goose/goose_subscriber.h index db35050c..d575355e 100644 --- a/src/goose/goose_subscriber.h +++ b/src/goose/goose_subscriber.h @@ -125,6 +125,17 @@ GooseSubscriber_getSqNum(GooseSubscriber self); bool GooseSubscriber_isTest(GooseSubscriber self); +/** + * \brief returns the confRev value of the last received GOOSE message + * + * \param self GooseSubscriber instance to operate on. + * + * \return the confRev value of the last received GOOSE message. If the message does not contain such + * a value the result is always 0 + */ +uint32_t +GooseSubscriber_getConfRev(GooseSubscriber self); + bool GooseSubscriber_needsCommission(GooseSubscriber self); diff --git a/src/vs/libiec61850-wo-goose.def b/src/vs/libiec61850-wo-goose.def index f1cdcb39..9041e69f 100644 --- a/src/vs/libiec61850-wo-goose.def +++ b/src/vs/libiec61850-wo-goose.def @@ -498,3 +498,4 @@ EXPORTS SVControlBlock_create SVControlBlock_addPhyComAddress GSEControlBlock_addPhyComAddress + GooseSubscriber_getConfRev \ No newline at end of file diff --git a/src/vs/libiec61850.def b/src/vs/libiec61850.def index aca168eb..6012f5a5 100644 --- a/src/vs/libiec61850.def +++ b/src/vs/libiec61850.def @@ -522,3 +522,4 @@ EXPORTS SVControlBlock_create SVControlBlock_addPhyComAddress GSEControlBlock_addPhyComAddress + GooseSubscriber_getConfRev \ No newline at end of file