04-12-2006 04:12 PM
04-13-2006
06:05 PM
- last edited on
12-01-2025
03:32 PM
by
Content Cleaner
I doubt this will satisfy 100% of what you're looking for, but it should at least get the conversation started on developing some techniques we can use to syncronize acquired data playback (again, let's say temperature) with some external source. I don't know much about video playback, so I won't be able to help you much there, but I do know a lot about leveraging LabVIEW technology to play back data in real-time as best possible, while allowing the user (or the video playback itself) to dictate a specific position at any time, pause, etc... My first recommendation would be to save your acquired temperature data as a Waveform. Waveform is more or less like a cluster with three elements: a 1D array of Y-values, an intial time (t0), and the time between samples (dt). You can use these three pieces of information to reconstitute when each sample was acquired and what the timing should be configured for to play these samples back in real time. Search the web for information on writing Waveforms to file and reading them. You should find plenty there (or post somewhere else 😉 ).
After that, we can use a Timed Loop for playback. Timed Loops allow you to set a desired Loop period. They also have a lot of other capabilities, such as setting priorities, handling the fact that your last loop didn't finish on time, etc. Here's a link with more info on Timed Loops. Other than that, Timed Loops can operate like regular while loops.
My next idea is to incorporate a current position that we keep track of. This could be, for instance, the index of the current element in the 1D Y-values array. If you want this to involve user interaction with the front panel (for instance, changing a Slider value to reflect the playback position), then you could use an event structure with a timeout case set to zero. Then update the temperature value and increment the current position in the timeout case.
You might take a look at the example I've written in LabVIEW 7.1 that "acquires" 5 seconds of sine wave data and plays it back in real time. The user can adjust the position or pause the playback at any time. Again, I don't know exactly how this would interface with video feedback. If you have more specifics about what method you will use to playback the video, maybe someone with more expertise in this area could help us out.
12-23-2011 09:02 AM
I realize I'm reviving a dead thread, but I'm very interested in how this turned out, if at all. I am essentially performing crash tests with accelerometers placed on the moving object. The goal is to reach a certain change in rate of speed over time. The accelerometers are enough to tell us that we're reaching the desired acceleration, and the separate video is very good information, but to sync the data with video (in future tests) would be invaluable information we could use to "debug" the mechanics of the crash. Whereas now we have an acceleration curve and a video, we just use educated guesses to pick out the acceleration peaks and dips in the video, it'd be great to know, for sure, exactly when the peaks and dips are.
Thanks
12-23-2011 02:34 PM
I can tell you the result. I wanted to do this on the cheap side and with as little equipment as possible. I ended up using a digital video recorder (normally used for security/surveillance) which was a GE Digia-4 (they have newer models now). I also used an XBOB unit from Decade Engineering (http://www.decadenet.com/) to overlay the text (data) on the video. I used the existing PLC of the process line to send out serial data to the XBOB continuously which matched the current position of the machine. This also matched up well with the existing video cameras we had at the time which were analog video with BNC connections. So PLC serial -> XBOB (which combines camera signal and overlays text sent by PLC) -> digital video recorder. This was my non-Labview solution.
If you have Labview or want to use it, then NI Vision offers this same overlay function block and the ability to save images. Be aware that NI Vision costs something significant and also the Vision runtime is around $400 I think.
03-25-2015 01:20 PM
JF3M, I am working on the same problem to synchronize tracking data to video recordings for my research. I have been hitting multiple dead ends, until I saw this. Would you kindly share the instructions on how to do this??? I will appreciate your help so much.
Thanks.