Discussion:
Decoding SMPTE/LTC
(too old to reply)
Adam Crowe
2006-11-07 09:40:09 UTC
Permalink
Hello!I am interested in decoding a SMPTE/LTC time code signal using a digital input of one of the DAQs.I would like to avoid using LABView. Maybe not at the development and testing stage, but definitly for the final product.- Has anyone ever tried this?
- Is it even possible?
- Moreover, if it is - can I reverse the process and generate the signal as well?
With respect,Adam ***@solidrock.co.il
SachaE
2006-11-08 12:10:09 UTC
Permalink
Hi Adam,
&nbsp; according to here :<a href="http://www.philrees.co.uk/articles/timecode.htm#smpte" target="_blank">http://www.philrees.co.uk/articles/timecode.htm#smpte</a> the timing data in SMPTE takes the form of an eight digit twenty-four hour clock. The count consists of 0 to 59 seconds, 0 to 59 minutes and 0 to 23 hours.
Hopefully that link will give you enough information to work out how you could capture the signal and how you have to analyse it to pull the actual information content out.
So in theory, it's just a question of dealing with the 8 digits and de-crypting them. The tricky part is where are you getting the signal from? If it comes in in parallel, and you can control the timing, then you could snapshot the incoming data. If it comes in in serial fashion, then you need to get the timing per bit correct. With either of these, if you're using an M-series card, you can perform correlated digital input (and output) so you can give timing to your digital lines if the signal is matching a TTL signal. Since the frame rate, if encoded to a movie reel for example, isn't necessarily constant, then you could time it with an analog input task and use an external clock matched to the sprocket holes. Also make sure you acquire at atlest twice the minimum width of pulse you're expecting since you need to capture the first digit to show what a 0 actually looks like in the signal.
Since&nbsp;LTC (linear or longitudinal time code) is the audio sync tone version of SMPTE you're more likely to&nbsp;be acquiring on an analog input, and you'd have to get the correct sample rate, and then analyse it for the correct signal content. Theoretically you can play that back out of the analog outputs (if your DAQ card has them), but since you get a stepped effect from any analog output, your resolution will give you an idea of the purity of the tone you'd emit.
Hope that helps
Thanks
Sacha EmeryNational Instruments (UK)Message Edited by SachaE on 11-08-2006 12:07 PM
SachaE
2006-11-09 09:40:12 UTC
Permalink
Hi,
1.&nbsp; given the variable timing, you could do it with a counter - continuous buffered period measurement, and then analyse the data coming out. That way you'll have the first period and can work out the zero representation.
2.&nbsp; to generate, then setup a counter, or an analog input task so you have a fixed reference clock and perform a correlated digital output (so you can write a buffers worth of data that represents the output digital waveform (i.e. if the rate was 1kHz for the reference clock, then 0,0,1,1,1,0,1,0,0,1 would be 2ms low, 3ms high, 1ms low, 1ms high, 2ms low etc.
&nbsp;
Hope that helps
&nbsp;
Thanks
&nbsp;
Sacha EmeryNational Instruments (UK)
&nbsp;

Loading...