Software Library API naibrd 2.24.0
See all documentation at naii.docs.com
AR-579 Transmit and Receive Operation Functions

Functions

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_SetTxEnable (int32_t cardIndex, int32_t module, int32_t channel, bool_t enable)
 Enables or disables the Transmitter of the specified channel. The enabling of the transmitter should occur after configuration of the channel is completed by the user. In particular, make sure to set the Tx Mode with naibrd_AR579_SetTransmitSendMode() prior to enabling the transmitter. Otherwise, the module may exhibit undefined behavior.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_GetTxEnable (int32_t cardIndex, int32_t module, int32_t channel, bool_t *p_outenable)
 Reads the state of the Transmitter of the specified channel.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_SetRxEnable (int32_t cardIndex, int32_t module, int32_t channel, bool_t enable)
 Enables or disables the receiver of the channel specified.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_GetRxEnable (int32_t cardIndex, int32_t module, int32_t channel, bool_t *p_outenable)
 Reads the receiver enabled / disabled status of the channel specified.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_LoadTxFifo (int32_t cardIndex, int32_t module, int32_t channel, int32_t txCount, const uint32_t *p_buffer, int32_t *p_outtxCount)
 This function will write multiple 32-bit words of data to the transmit FIFO of the specified channel. A pointer to a buffer and length are passed as parameters. The actual number of words placed in the buffer is returned. If the available space in the FIFO is less than the number of messages being placed in the FIFO, the messages are not placed in the FIFO and instead, the available space in the FIFO is returned in the output variable.
 
NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_ReadRxFifo (int32_t cardIndex, int32_t module, int32_t channel, bool_t timeStampEnabled, int32_t rxCount, uint32_t *p_outstatus, uint32_t *p_outdata, uint32_t *p_outtimeStamp, int32_t *p_outrxCount)
 This function reads the 32-bit ARINC-579 data from the receive FIFO of the specified channel for the number of words (of data) specified (up to 1024).
 

Detailed Description

Function Documentation

◆ naibrd_AR579_GetRxEnable()

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_GetRxEnable ( int32_t cardIndex,
int32_t module,
int32_t channel,
bool_t * p_outenable )

Reads the receiver enabled / disabled status of the channel specified.

Parameters
cardIndex: (Input) Logical Card Index assigned to connect 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]).
p_outenable: (Output) Receiver enabled (1) or disabled (0).
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_AR579_GetTxEnable()

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_GetTxEnable ( int32_t cardIndex,
int32_t module,
int32_t channel,
bool_t * p_outenable )

Reads the state of the Transmitter of the specified channel.

Parameters
cardIndex: (Input) Logical Card Index assigned to connect 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]).
p_outenable: (Output) Transmit enabled (1) or disabled (0).
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_AR579_LoadTxFifo()

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_LoadTxFifo ( int32_t cardIndex,
int32_t module,
int32_t channel,
int32_t txCount,
const uint32_t * p_buffer,
int32_t * p_outtxCount )

This function will write multiple 32-bit words of data to the transmit FIFO of the specified channel. A pointer to a buffer and length are passed as parameters. The actual number of words placed in the buffer is returned. If the available space in the FIFO is less than the number of messages being placed in the FIFO, the messages are not placed in the FIFO and instead, the available space in the FIFO is returned in the output variable.

Parameters
cardIndex: (Input) Logical Card Index assigned to connect 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]).
txCount: (Input) Number of 32-bit words of data in p_buffer.
p_buffer: (Input) Arinc messages.
p_outtxCount: (Output) Number of 32-bit words placed on Tx FIFO. Or if there is not enough room in the FIFO, this value will indicate how much room there is available and status will return NAI_ERROR_FULL.
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 p_buffer is not a valid pointer and/or txCount is less than zero.
  • NAI_ERROR_FULL when there is not enough room in the FIFO, p_outtxCount will indicate how much room there is.
  • NAI_ERROR_NOT_SUPPORTED when function is not supported.

◆ naibrd_AR579_ReadRxFifo()

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_ReadRxFifo ( int32_t cardIndex,
int32_t module,
int32_t channel,
bool_t timeStampEnabled,
int32_t rxCount,
uint32_t * p_outstatus,
uint32_t * p_outdata,
uint32_t * p_outtimeStamp,
int32_t * p_outrxCount )

This function reads the 32-bit ARINC-579 data from the receive FIFO of the specified channel for the number of words (of data) specified (up to 1024).

Parameters
cardIndex: (Input) Logical Card Index assigned to connect 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]).
timeStampEnabled: (Input) Indicate if timestamp is enabled (NAI_TRUE = enabled, NAI_FALSE = disabled).
rxCount: (Input) Number of 32-bit words to attempt to read from the receive FIFO. Note that the user should provide arrays for p_outstatus, p_outdata and p_outtimestamp that are large enough to hold the requested number of ARINC messages.
p_outstatus: (Output) Pointer to a user-supplied array that will contain message status words.
p_outdata: (Output) Pointer to a user-supplied array that will contain 32-bit ARINC words.
p_outtimeStamp: (Output) Pointer to a user-supplied array that will contain timestamps.
p_outrxCount: (Output) Number of ARINC messages actually read from FIFO.
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_AR579_SetRxEnable()

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_SetRxEnable ( int32_t cardIndex,
int32_t module,
int32_t channel,
bool_t enable )

Enables or disables the receiver of the channel specified.

Parameters
cardIndex: (Input) Logical Card Index assigned to connect 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]).
enable: (Input) Enable (1) or disable (0) the receiver.
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_AR579_SetTxEnable()

NAIBRDFUNC nai_status_t NAIAPI naibrd_AR579_SetTxEnable ( int32_t cardIndex,
int32_t module,
int32_t channel,
bool_t enable )

Enables or disables the Transmitter of the specified channel. The enabling of the transmitter should occur after configuration of the channel is completed by the user. In particular, make sure to set the Tx Mode with naibrd_AR579_SetTransmitSendMode() prior to enabling the transmitter. Otherwise, the module may exhibit undefined behavior.

Parameters
cardIndex: (Input) Logical Card Index assigned to connect 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]).
enable: (Input) Transmit enable (NAI_TRUE) or disable (NAI_FALSE).
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.