LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Trouble Recording Data Properly Using DMA FIFO

The idea of my program is that a fault will set a DIO pin to high. I want to record voltage data for all 16 AI pins on my sbRIO-9636 and send it to a tdms file. What I want to do, is to only record ~.5 seconds before the fault and ~.5 seconds after the fault. So I made a circular buffer using array functions on the host, and then I simply append ~.5 seconds worth of rows of data once the fault has occured. I also want to record the exact time of the fault. Currently, I have a simple okay button writing to the DIO pin to simulate my fault. My problem is, the longer that I run the host program (ideally it runs continually and I don't start it up when I expect a fault to occur), the closer the beginning times of the data I have collected are to my fault time. For example, running the host program only a couple of seconds, the first time in my tdms file was .57 seconds earlier than the fault time. When running the host program for nearly half an hour, the first time in my tdms file was only .33 seconds earlier than my fault time. I have attached the portions of my code including the FPGA. And help would be greatly appreciated.

Download All
0 Kudos
Message 1 of 2
(2,766 Views)

Hi jbart253,

 

Would you mind posting your project so that I can see how your DMA FIFOs are set up? You can do this easily by going to file--> save as and creating an additional copy with all dependencies. You can save this copy in a new file and zip the file to post on here.

 

A Johnson
Applications Engineer
National Instruments
0 Kudos
Message 2 of 2
(2,719 Views)