High-Speed Digitizers

cancel
Showing results for 
Search instead for 
Did you mean: 

Data format of data written with hsdl vi's

I used to record data with the NI HSDL vi's with the 16 -> 12 bit compression. I changed my record program and use DAQmx now. DAQmx can also be set to use compression. I can restore 12 bit data recorded with DAQmx into 16 bit data.
 
I still have some old data files. I prefer not to use the NI HSDL DLL anymore. It seems that the HSDL vi records the data in an other format than DAQmx. Can somebody supply me with the data format of HSDL
 
Regards,
Christiaan Lievers
0 Kudos
Message 1 of 2
(6,071 Views)
Hi Christiaan,
 
The HSDL VI stores the 16 bit samples that is read form the DMA channel in 16 -> 12 compression in the following way:
it trows away the unused 4 bits (usally with 12 bit boards) then is stores two 12 bit samples is 3 bytes (24 bit).
 
If you used the same setup as the xamples then the first 4 bytes contain the length of the header. Read this header as a string and then use the VI's in the hsdl.llb to decode this in to the correct scaling information. After the header all samples follow. each 12 bit is one sample. so you will need to do some bit operations to get the correct samples.
 
Hope this helps
 
Karsten
0 Kudos
Message 2 of 2
(6,049 Views)