Software Library API naibrd 1.62
See all documentation at naii.docs.com
FIFO Operation Functions

Functions

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOCount (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outcount)
 Retrieves the number of items in the S/D Buffer Fifo for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOValue (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outvalue)
 Retrieves one value from the S/D Fifo Buffer for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOFloatValue (int32_t cardIndex, int32_t module, int32_t channel, float64_t *outvalue)
 Retrieves one value in floating-point format from the S/D Fifo Buffer for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOLoThreshold (int32_t cardIndex, int32_t module, int32_t channel, uint32_t threshold)
 Sets the number of data words the FIFO will have left before setting the LoThreshold bit in the FIFO status register.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOLoThreshold (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outthreshold)
 Retrieves the count set in the LoThreshold register.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOHiThreshold (int32_t cardIndex, int32_t module, int32_t channel, uint32_t threshold)
 Sets the number of data words the FIFO will receive before setting the HiThreshold bit in the FIFO status register.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOHiThreshold (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outthreshold)
 Retrieves the count set in the HiThreshold register.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOAlmostEmpty (int32_t cardIndex, int32_t module, int32_t channel, uint32_t empty)
 Sets the almost empty mark/threshold to set or to reset the SD channel's FIFO Status "Almost Empty" bit. When the SD channel's FIFO counter is less than or equal to the almost empty mark, the "Almost Empty" bit will be set (1). When the SD channel's FIFO counter is greater than the almost empty mark, the "Almost Empty" bit will be reset (0).
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOAlmostEmpty (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outempty)
 Retrieves the "almost empty" mark/threshold used to set or to reset the SD channel's FIFO Status "Almost Empty" bit. When the SD channel's FIFO counter is less than or equal to the "almost empty" mark, the "Almost Empty" bit will be set (1). When the A/D channel's FIFO counter is greater than the "almost empty" mark, the "Almost Empty" bit will be reset (0).
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOAlmostFull (int32_t cardIndex, int32_t module, int32_t channel, uint32_t full)
 Sets the almost full mark/threshold to set or to reset the SD channel's FIFO Status "Almost Full" bit. When the SD channel's FIFO counter is less than or equal to the almost full mark, the "Almost Full" bit will be set (1). When the SD channel's FIFO counter is greater than the almost full mark, the "Almost Full" bit will be reset (0).
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOAlmostFull (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outfull)
 Retrieves the "almost full" mark/threshold to set or to reset the SD channel's FIFO Status "Almost Full" bit. When the SD channel's FIFO counter is less than or equal to the "almost full" mark, the "Almost Full" bit will be set (1). When the SD channel's FIFO counter is greater than the "almost full" mark, the "Almost Full" bit will be reset (0).
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFODelay (int32_t cardIndex, int32_t module, int32_t channel, uint32_t delay)
 Sets the time delay before samples are taken after the trigger occurs. The LSB of this value is 10.24us. The maximum delay is about 335 ms.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFODelay (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outdelay)
 Retrieves the time delay before samples are taken after the trigger occurs. This LSB of this value is 10.24us.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOSize (int32_t cardIndex, int32_t module, int32_t channel, uint32_t size)
 Sets the number of samples we take after the trigger occurs.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOSize (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outsize)
 Retrieves the number of samples we take after the trigger occurs.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOSampleRateValue (int32_t cardIndex, int32_t module, int32_t channel, float64_t samplerate)
 Sets the time in usec between samples taken (0 to 671078 us) in intervals of 10.24 usec.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOSampleRateValue (int32_t cardIndex, int32_t module, int32_t channel, float64_t *outsamplerate)
 Retrieves the time in usec between samples taken (0 to 671078 us) in intervals of 10.24 usec.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOSampleRate (int32_t cardIndex, int32_t module, int32_t channel, uint32_t samplerate)
 Sets the time between samples taken. The LSB is 10.24us.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOSampleRate (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outsamplerate)
 Retrieves the time between samples taken. The LSB is 10.24us.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFODataType (int32_t cardIndex, int32_t module, int32_t channel, uint32_t datatype)
 Sets the type of data to acquire in the buffer.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFODataType (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outdatatype)
 Retrieves the type of data to acquire in the buffer.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_ClearFIFO (int32_t cardIndex, int32_t module, int32_t channel)
 Clears the S/D FIFO buffers for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOTrigMode (int32_t cardIndex, int32_t module, int32_t channel, uint32_t trigmode)
 Sets the trigger mode to start data buffering.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOTrigMode (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outtrigmode)
 Retrieves the trigger mode to start data buffering.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SoftwareTrigger (int32_t cardIndex, int32_t module)
 Sends a software trigger to all channels.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFORealtimeStatus (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outfifostatus)
 Retrieves the S/D Buffer Fifo Real-time Status for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOLatchedStatus (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outfifostatus)
 Retrieves the S/D Buffer Fifo Latched Status for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_ClearFIFOLatchedStatus (int32_t cardIndex, int32_t module, int32_t channel, uint32_t bit)
 Clears the S/D Buffer Fifo Latched Status for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOIntEnable (int32_t cardIndex, int32_t module, int32_t channel, uint32_t intEnableFifo)
 Set the S/D Buffer Fifo interrupt enable for the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOIntEnable (int32_t cardIndex, int32_t module, int32_t channel, uint32_t *outIntEnableFifo)
 Retrieves the S/D Buffer Fifo interrupt enable for the specified channel.
 

Detailed Description


Function Documentation

◆ naibrd_SD_ClearFIFO()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_ClearFIFO ( int32_t cardIndex,
int32_t module,
int32_t channel )

Clears the S/D FIFO buffers for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_ClearFIFOLatchedStatus()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_ClearFIFOLatchedStatus ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t bit )

Clears the S/D Buffer Fifo Latched Status for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
bit: (Input) FIFO Status Types to clear (bit-mapped)
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOAlmostEmpty()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOAlmostEmpty ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outempty )

Retrieves the "almost empty" mark/threshold used to set or to reset the SD channel's FIFO Status "Almost Empty" bit. When the SD channel's FIFO counter is less than or equal to the "almost empty" mark, the "Almost Empty" bit will be set (1). When the A/D channel's FIFO counter is greater than the "almost empty" mark, the "Almost Empty" bit will be reset (0).

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outempty: (Output) Almost Empty Mark. (module specific range- see spec).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid card parameter is specified.
  • NAI_ERROR_NOT_OPEN when handle to board is invalid.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOAlmostFull()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOAlmostFull ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outfull )

Retrieves the "almost full" mark/threshold to set or to reset the SD channel's FIFO Status "Almost Full" bit. When the SD channel's FIFO counter is less than or equal to the "almost full" mark, the "Almost Full" bit will be set (1). When the SD channel's FIFO counter is greater than the "almost full" mark, the "Almost Full" bit will be reset (0).

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outfull: (Output) Almost Full Mark. (module specific range- see spec).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid card parameter is specified.
  • NAI_ERROR_NOT_OPEN when handle to board is invalid.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOCount()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOCount ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outcount )

Retrieves the number of items in the S/D Buffer Fifo for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outcount: (Output) FIFO count
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFODataType()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFODataType ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outdatatype )

Retrieves the type of data to acquire in the buffer.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outdatatype: (Output) Data Type to acquire in buffer per table below.
  D0  = Angle Data (16 Bit Hi). 16 bit resolution data 
  D1  = Angle Data (8 Bit Lo). Combine with D0 to form 24 bit resolution data 
  D2  = Velocity Data (16 Bit Hi). 16 bit resolution data 
  D3  = Velocity Data (8 Bit Lo). Combine with D2 to form 24 bit resolution data 
  D4  = Time Stamp. An integer counter that counts from 0 to 65535 and wraps around when it overflows 
  D5  = Reserved 
  D6  = Reserved 
  D7  = Reserved 
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFODelay()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFODelay ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outdelay )

Retrieves the time delay before samples are taken after the trigger occurs. This LSB of this value is 10.24us.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outdelay: (Output) Delay count.
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOFloatValue()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOFloatValue ( int32_t cardIndex,
int32_t module,
int32_t channel,
float64_t * outvalue )

Retrieves one value in floating-point format from the S/D Fifo Buffer for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outvalue: (Output) FIFO floating-point value retrieved.
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOHiThreshold()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOHiThreshold ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outthreshold )

Retrieves the count set in the HiThreshold register.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outthreshold: (Output) Threshold value.
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOIntEnable()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOIntEnable ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outIntEnableFifo )

Retrieves the S/D Buffer Fifo interrupt enable for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outIntEnableFifo: (Input) FIFO Interrupt Enable
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOLatchedStatus()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOLatchedStatus ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outfifostatus )

Retrieves the S/D Buffer Fifo Latched Status for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outfifostatus: (Output) FIFO Status
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOLoThreshold()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOLoThreshold ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outthreshold )

Retrieves the count set in the LoThreshold register.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outthreshold: (Output) Threshold value
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFORealtimeStatus()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFORealtimeStatus ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outfifostatus )

Retrieves the S/D Buffer Fifo Real-time Status for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outfifostatus: (Output) FIFO Status
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOSampleRate()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOSampleRate ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outsamplerate )

Retrieves the time between samples taken. The LSB is 10.24us.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outsamplerate: (Output) Sample Rate
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOSampleRateValue()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOSampleRateValue ( int32_t cardIndex,
int32_t module,
int32_t channel,
float64_t * outsamplerate )

Retrieves the time in usec between samples taken (0 to 671078 us) in intervals of 10.24 usec.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outsamplerate: (Output) Sample Rate value
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOSize()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOSize ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outsize )

Retrieves the number of samples we take after the trigger occurs.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outsize: (Output) Number of Samples.
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOTrigMode()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOTrigMode ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outtrigmode )

Retrieves the trigger mode to start data buffering.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outtrigmode: (Output) Trigger Mode as specified in table below.
  0x00 = Ext Trig1 
  0x01 = Ext Trig2 
  0x02 = Software Trigger 
  0x10 = Trigger Slope 
  0x20 = Trigger Enable 
  0x40 = Trigger Always 
  0x80 = Clear Trigger Always 
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_GetFIFOValue()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_GetFIFOValue ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t * outvalue )

Retrieves one value from the S/D Fifo Buffer for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
outvalue: (Output) FIFO value
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOAlmostEmpty()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOAlmostEmpty ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t empty )

Sets the almost empty mark/threshold to set or to reset the SD channel's FIFO Status "Almost Empty" bit. When the SD channel's FIFO counter is less than or equal to the almost empty mark, the "Almost Empty" bit will be set (1). When the SD channel's FIFO counter is greater than the almost empty mark, the "Almost Empty" bit will be reset (0).

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
empty: (Input) Almost Empty Mark (module specific range- see spec).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid card parameter is specified.
  • NAI_ERROR_NOT_OPEN when handle to board is invalid.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOAlmostFull()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOAlmostFull ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t full )

Sets the almost full mark/threshold to set or to reset the SD channel's FIFO Status "Almost Full" bit. When the SD channel's FIFO counter is less than or equal to the almost full mark, the "Almost Full" bit will be set (1). When the SD channel's FIFO counter is greater than the almost full mark, the "Almost Full" bit will be reset (0).

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
full: (Input) Almost Full Mark. (module specific range- see spec).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid card parameter is specified.
  • NAI_ERROR_NOT_OPEN when handle to board is invalid.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFODataType()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFODataType ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t datatype )

Sets the type of data to acquire in the buffer.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
datatype: (Input) Data Type to acquire in buffer as specified in table below.
  D0  = Angle Data (16 Bit Hi). 16 bit resolution data 
  D1  = Angle Data (8 Bit Lo). Combine with D0 to form 24 bit resolution data 
  D2  = Velocity Data (16 Bit Hi). 16 bit resolution data 
  D3  = Velocity Data (8 Bit Lo). Combine with D2 to form 24 bit resolution data 
  D4  = Time Stamp. An integer counter that counts from 0 to 65535 and wraps around when it overflows 
  D5  = Reserved 
  D6  = Reserved 
  D7  = Reserved 
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid datatype parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFODelay()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFODelay ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t delay )

Sets the time delay before samples are taken after the trigger occurs. The LSB of this value is 10.24us. The maximum delay is about 335 ms.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
delay: (Input) Count (0 - 32767).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid delay parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOHiThreshold()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOHiThreshold ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t threshold )

Sets the number of data words the FIFO will receive before setting the HiThreshold bit in the FIFO status register.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
threshold: (Input) Number of words(0 - 32767).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid threshold parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOIntEnable()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOIntEnable ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t intEnableFifo )

Set the S/D Buffer Fifo interrupt enable for the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
intEnableFifo: (Input) FIFO Interrupt Enable
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOLoThreshold()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOLoThreshold ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t threshold )

Sets the number of data words the FIFO will have left before setting the LoThreshold bit in the FIFO status register.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
threshold: (Input) Number of words(0 - 32767).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid threshold parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOSampleRate()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOSampleRate ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t samplerate )

Sets the time between samples taken. The LSB is 10.24us.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
samplerate: (Input) Count (0 - 32767).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid samplerate parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOSampleRateValue()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOSampleRateValue ( int32_t cardIndex,
int32_t module,
int32_t channel,
float64_t samplerate )

Sets the time in usec between samples taken (0 to 671078 us) in intervals of 10.24 usec.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
samplerate: (Input) Time in usec (0 to 671078).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid samplerate parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOSize()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOSize ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t size )

Sets the number of samples we take after the trigger occurs.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
size: (Input) Count (0 - 32767).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid delay parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SetFIFOTrigMode()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SetFIFOTrigMode ( int32_t cardIndex,
int32_t module,
int32_t channel,
uint32_t trigmode )

Sets the trigger mode to start data buffering.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
channel: (Input) Channel Number of the channel to access (1 - [max channels for module]).
trigmode: (Input) Trigger Mode to acquire in buffer as specified in table below.
  0x00 = Ext Trig1 
  0x01 = Ext Trig2 
  0x02 = Software Trigger 
  0x10 = Trigger Slope 
  0x20 = Trigger Enable 
  0x40 = Trigger Always 
  0x80 = Clear Trigger Always 
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_INVALID_CHANNEL when invalid channel parameter is specified.
  • NAI_ERROR_INVALID_VALUE when invalid trigmode parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_SD_SoftwareTrigger()

NAIBRDFUNC nai_status_t NAIAPI naibrd_SD_SoftwareTrigger ( int32_t cardIndex,
int32_t module )

Sends a software trigger to all channels.

Parameters
cardIndex: (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1).
module: (Input) Module Number of the module to access (1 - [max modules for board]).
Returns
  • NAI_SUCCESS
  • NAI_ERROR_INVALID_CARD when invalid card parameter is specified.
  • NAI_ERROR_INVALID_MODULE when invalid module parameter is specified.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.