niHSDIO Set Named Waveform Next Write Position VI
- Updated2023-02-21
- 5 minute(s) read
Modifies where to next write within a named waveform.
The niHSDIO Write Named Waveform VI always begins writing at the current write position. Existing data in the waveform is overwritten.
Related Topics
![]() |
instrument handle identifies your instrument session. instrument handle is obtained from the niHSDIO Init Acquisition Session VI, the niHSDIO Init Generation Session VI, or the niHSDIO Init Ext Cal VI. |
||||||
![]() |
waveform name specifies the name to associate with the allocated waveform memory. |
||||||
![]() |
position specifies where to place the write position, in conjunction with offset.
|
||||||
![]() |
offset specifies an offset for the write position within the named waveform. offset is in samples. Before issuing a write waveform command, the offset relative to the start of the waveform must be a multiple of 32 samples for NI 654x/655x devices (64 samples for the NI 6547/6548 in DDR mode) and a multiple of 64 samples for NI 656x devices (128 samples for the NI 656x is in DDR mode). |
||||||
![]() |
error in (no error) describes error conditions that occur before this node runs. This input provides standard error in functionality.
|
||||||
![]() |
instrument handle out passes a reference to your instrument session to the next VI. instrument handle is obtained from the niHSDIO Init Acquisition Session VI or the niHSDIO Init Generation Session VI. |
||||||
![]() |
error out contains error information. This output provides standard error out functionality.
|
Details
position and offset are used together to determine the next write position. position describes an absolute or relative move. offset is the number of samples to shift the next write position. You must always set the write position at a position that is a multiple of 32 samples for NI 654x/655x devices (64 samples for the NI 6547/6548 in DDR mode) or a multiple of 64 samples for NI 656x devices (128 samples for the NI 656x in DDR mode).
The following table shows examples of combinations of position and offset.
Position | Offset | Next Write Position |
---|---|---|
Start of Waveform | 0 | Start of waveform |
Start of Waveform | 5 | Sixth sample of waveform |
Start of Waveform | -1 | ERROR. These settings would try to place write position before start of waveform. |
Current Write Position | 0 | No effect. These settings leave the next write position unchanged. |
Current Write Position | 10 | Shift write position 10 samples ahead from current location. This position setting is valid only if the current write position plus this offset is in the waveform. |
Current Write Position | -10 | Shift write position 10 samples back from current location. This position setting is valid only if the current write position is greater than 10. |
The write position is moved to the end of the most recently written data after each use of the niHSDIO Write Named Waveform VI. Thus you do not need to explicitly use the niHSDIO Set Named Waveform Next Write Position VI. Setting the position beyond the bounds of the allocated space produces an error.