Hello,
I'm using opendnp3 release 3.x to implement an outstation in C/C++.
During general interrogation requested by the master, objects sent by the outstation have timestamp properly set to local time.
I have difficult to send unsolicited variation to the master with timestamp in local time.
I verified that local timestamp has correct offest respect to UTC.
Here is a code snip:
Analog myAn;
case ((int)GroupVariation::Group32Var7):
DNPTimeStamp = DNPTime(GetTimeStampMilliseconds(true), TimestampQuality::SYNCHRONIZED);
dValue = (double)iRegValueToUpdate;
AnalogQualityFlag.Set(AnalogQuality::ONLINE);
myAn = Analog(dValue, AnalogQualityFlag, DNPTimeStamp);
builder.Update(myAn, pDnp3->Addr, EventMode::Detect);
pGw->outstation->Apply(builder.Build());
break;
I'm not able to identify the error.
Any help is appreciated.
Matteo Chiappa