07-22-2016 01:19 PM
I'm using a PXIe RT 8135. I am sampling analog pressure signals at 10ms and thermocouples at 20ms. I am using network streams to transfer the data from the PXIe to my host computer. I'd like to be able to sync the timestamps of all the data to the 1ms sampling rate and record it to a file.
Looking into the file my 10ms sampling data ending timestamp does not match up with the 20ms timestamp, I am missing data.. I know you have to flush the queues to get the remainder of the data but is there a way to interpolate everything so all the collected data can match to a single timestamp?
Thanks!
Solved! Go to Solution.
07-25-2016 09:22 AM
Hi aokada09,
It looks like you are running into issues that arise from the parallel execution of the two loops you have. There isn't anything necessarily tying the two loops together, so they each iterate at the rates you specified but are allowed to start whenever software (sort of randomly) dictates that they start.
To get solid synchronization, share a sample clock between the two measurements but run the sample clock at 100Hz for the pressure measurement and 50 Hz for the thermocouple measurement. You should be able to use the shared clock in the backplane of the PXIe chassis. This will be as close as possible to synchronized without the use of an additional timing card. The only real source of delay/skew between readings at that point is the physical distance that the clock signal must travel; it will not result in large skew, but there will definitely be some (probably on the scale of high-nanoseconds or low-microseconds). This article gives more information about synchronization and sample clocking:
http://www.ni.com/white-paper/11369/en/
07-27-2016 09:53 AM
Thanks for the info, that helped.