This project has moved. For the latest updates, please go here.

Replay data from the historian

Nov 26, 2012 at 10:55 PM

Hello. Can we replay data from the historian in the openPDC? We replaied data stored by PMU Connection Tester (.pmuCapture) (358737), and with the Historian Playback Utility we can playback data by the network in a plain-text format. But is there a way to playback/replay history data in C37.118 format? I read this old discussion (218658) but I didn't understand if I have to implement a custom adapter, or if I can just setup a function in the openPDC, a kind of input adapter, for example.

Another way could be generate .pmuCapture files from the historian. Is it possible to do this in a "user way", without implementing new codes in the openPDC?

We're trying to replay some data from old events in the electrical system to test realtime applications with interesting data stored in our openPDC historian.

Thanks!

Coordinator
Nov 29, 2012 at 3:29 PM

Yes - at least using the latest code (nightly build / or openPDC 1.5 SP1 - release candidate will be released this morning).

You would go to the "Custom Input Adapters" screen. To create a new input adapter, press the clear button. Type in a name for the adapter then pick "Local Historian Reader" from the list of available adapters. Set the needed adapter properties:

  • Set the "ArchiveLocation" property to point the folder for your historical .D files.
  • Set the "InstanceName" property to "PPA".
  • Set the "StartTimeContraint" property to the date/time in UTC that represents the desired time to start reading data.
  • If desired, set the "StopTimeConstraint" property to the date/time in UTC of when to stop reading data - leave blank to read until the end of the file.
  • Add "; sourceIDs=PPA; processingInterval=15" to the connection string as extra parameters.

Note that you can change the processingInterval to -1 to make the system read and publish data as fast as possible - a setting of 15 gives a close approximation of normal real-time.

Check the "Enabled" box and save the record. When you click "initialize" the data will start reading.

Suggestions on dealing with analysis / time-stamp issues:

Normally we have running everything in the system as "real-time". This made the archiving and processing of data more natural. However this is not required, the openPDC will process historical data just as well as real-time. You do have to make adjustments though.

For starters, the historian normally archives data in "sequential" order - that means if you have been archiving real-time data and then replay data, you may need to disable your output stream or at least change to "virtual". If you leave the original historian on it will ignore older data since it will think the data is invalid but may archive any "new" data such as statistics and/or alarms. If you want archived data you will need to segregate "runs" of the system into separate "archive outputs". You can do this simply by renaming the existing archive folder (with the openPDC offline) and creating a new "blank" folder with the original name.

Bottom line, would be best not confuse the system by reading historical data through the system then trying to re-archive it. An easy way to do this is to setup a separate openPDC for playback leaving your real-time system in-tact / unchanged.

Second, for output streams you will need to change stream to not the perform time-stamp reasonability checking. To do this, uncheck "Use Local Clock as Real-time" and "Perform Timestamp Reasonability Check" under the advanced properties on the IEEE C37.118 output stream - also check "Ignore Bad Timestamps". Save the record and re-initialize the adapter and any system needing an IEEE C37.118 data feed can get one with historical data - this way you can concentrate "old" data.

FYI, applications getting data through "subscription" using the Gateway Exchange Protocol will not be affected by historical data and should work fine as-is.

Thanks!
Ritchie