Hi CT,
Is there a way to set HS-DIO channel (e.g. PXI-6551) using digital data? In what format, WDT, 2DU32, etc.?
Yes, using niHSDIO Write Named Waveform. The formats include 1D U32, 1D U16, 1D U8, and WDT. Also, you should name the waveforms if you are using scripts or want to download multiple waveforms into the hardware.
Along the generation patterns, I need to set certain channels to tristate (Hi-Impedance). Can I set it using samples in my waveform (or digital data) rather than stop generation, call the Set Tristate vi and go back to waveform and continue the generation?
Currently, the only method to tristate your channels is to use niHSDIO Tristate Channels.vi. This may be updated in future releases of the HSDIO driver. For now, with NI-HSDIO 1.3, you must use the niHSDIO Tristate Channels.vi.
Also, why NI does not publish the conversion between 2DU32 and WDT? What's the big deal? (I made a conversion vi myself after some digging, but I think it should be part of niHWS's ready-use-vi's.)
Converting between 2D U32 and a WDT isn't a big deal, you are correct. The next version of the HSDIO driver is planning to include a 1D data to WDT conversion VI. You mention the conversion from 2D U32 to WDT. You probably have multiple devices. May I ask exactly why you want to do this? I know of several cases where somebody might want this, and each one needs to be treated a little differently.
Same thing with getting channel mapping info out of a digital waveform file. Why can't there be an output on the niHWS Retrieve Waveform.vi and niHSDIO Read Waveform.vi to show such information?
When you read with U32 (or U16, U8), the data is already channel mapped (bit 0 goes to channel 0, etc) based on what was entered in the Digital Waveform Editor. There's not really a way to get this information from WDT. What would you do with this information (what kind of format would be most useful)?
Chad AE
Applications Engineer