Software Library API naibrd 1.62
See all documentation at naii.docs.com
nai.h File Reference

Go to the source code of this file.

Typedefs

typedef enum nai_status nai_status_t
 
typedef uint8_t nai_intf_t
 
typedef uint32_t nai_maskreg_op_t
 

Enumerations

enum  nai_status {
  NAI_SUCCESS = 0 , NAI_ERROR_INVALID_VALUE = -1 , NAI_ERROR_INVALID_MODE = -2 , NAI_ERROR_INVALID_SIZE = -3 ,
  NAI_ERROR_INVALID_TYPECODE = -4 , NAI_ERROR_INVALID_ADDRESS = -5 , NAI_ERROR_INVALID_ADDRBOUND = -6 , NAI_ERROR_INVALID_COMMAND = -7 ,
  NAI_ERROR_NOT_FOUND = -8 , NAI_ERROR_TIMEOUT = -9 , NAI_ERROR_COMM_ERROR = -10 , NAI_ERROR_LOCK_FAILED = -11 ,
  NAI_ERROR_INVALID_WIDTH = -12 , NAI_ERROR_INVALID_CARD = -13 , NAI_ERROR_INVALID_MODULE = -14 , NAI_ERROR_INVALID_CHANNEL = -15 ,
  NAI_ERROR_OPEN_FAILED = -16 , NAI_ERROR_INVALID_MESSAGE = -17 , NAI_ERROR_MESSAGE_MISMATCH = -18 , NAI_ERROR_OVERFLOW = -19 ,
  NAI_ERROR_NOT_MASTER = -20 , NAI_ERROR_DISCONNECTED = -21 , NAI_ERROR_IN_USE = -22 , NAI_ERROR_FULL = -23 ,
  NAI_ERROR_EMPTY = -24 , NAI_ERROR_NOT_READY = -25 , NAI_ERROR_CONNECTION_LOST = -26 , NAI_ERROR_NOT_OPEN = -27 ,
  NAI_ERROR_PARITY = -28 , NAI_ERROR_FRAMING = -29 , NAI_ERROR_FRAMING_PARITY = -30 , NAI_ERROR_NO_MESSAGE = -31 ,
  NAI_ERROR_WATCHDOG = -32 , NAI_ERROR_BUS_TIMEOUT = -33 , NAI_ERROR_INVALID_RANGE = -34 , NAI_ERROR_WRONG_DEVICE = -35 ,
  NAI_ERROR_BUS_READ_ERR = -36 , NAI_ERROR_BUS_WRITE_ERR = -37 , NAI_ERROR_MORE_DATA = -38 , NAI_ERROR_INVALID_ENCODER_RES = -39 ,
  NAI_ERROR_INVALID_COMMUTATION_POLES = -40 , NAI_ERROR_INVALID_RATIO = -41 , NAI_ERROR_INVALID_IO_PARAM = -42 , NAI_ERROR_BIT_FAILED = -43 ,
  NAI_ERROR_VME_ADDR_TRANSLATION = -44 , NAI_ERROR_BSP_VME_TABLE = -45 , NAI_ERROR_INT_CONNECT_FAILED = -46 , NAI_ERROR_INT_DISCONNECT_FAILED = -47 ,
  NAI_ERROR_1553_MESSAGE_ERROR = -48 , NAI_ERROR_1553_DATA_WRAPAROUND_ERROR = -49 , NAI_ERROR_PERMISSION_DENIED = -50 , NAI_ERROR_UNLOCK_FAILED = -51 ,
  NAI_ERROR_PROTOCOL_FUNCTION_MISMATCH = -52 , NAI_ERROR_FUNCTION_SPECIFIC_ERROR = -53 , NAI_ERROR_NOT_SUPPORTED = -100 , NAI_ERROR_UNKNOWN = -1000 ,
  NAI_ERROR_UNKNOWN_VALUE = -1001 , NAI_ERROR_ETHER_GENERAL_GEN4 = -0x8000 , NAI_ERROR_ETHER_INVALID_MSG_PREAMBLE_GEN4 = -0x8001 , NAI_ERROR_ETHER_INVALID_MSG_SEQ_NUM_GEN4 = -0x8002 ,
  NAI_ERROR_ETHER_INVALID_MSG_TYPECODE_GEN4 = -0x8003 , NAI_ERROR_ETHER_INVALID_MSG_LENGTH_GEN4 = -0x8004 , NAI_ERROR_ETHER_INVALID_MSG_POSTAMBLE_GEN4 = -0x8005 , NAI_ERROR_ETHER_INVALID_PAYLOAD_SIZE_GEN4 = -0x8006 ,
  NAI_ERROR_ETHER_COMMAND_NOT_IMPLEMENTED_GEN4 = -0x8007 , NAI_ERROR_ETHER_INVALID_CONFIG_TYPECODE_GEN4 = -0x8010 , NAI_ERROR_ETHER_INVALID_OPERATION_TYPECODE_GEN4 = -0x8011 , NAI_ERROR_ETHER_INVALID_MB_INFOTYPE_GEN4 = -0x8012 ,
  NAI_ERROR_ETHER_INVALID_MOD_INFOTYPE_GEN4 = -0x8013 , NAI_ERROR_ETHER_INVALID_MOD_ID_GEN4 = -0x8014 , NAI_ERROR_ETHER_OPENING_EEPROM_GEN4 = -0x8015 , NAI_ERROR_ETHER_READING_EEPROM_GEN4 = -0x8016 ,
  NAI_ERROR_ETHER_WRITING_EEPROM_GEN4 = -0x8017 , NAI_ERROR_ETHER_INVALID_PAYLOAD_LENGTH_GEN4 = -0x8018 , NAI_ERROR_ETHER_INFOTYPE_READONLY_GEN4 = -0x8019 , NAI_ERROR_ETHER_READING_MOD_INFO_GEN4 = -0x801A ,
  NAI_ERROR_ETHER_WRITING_MOD_INFO_GEN4 = -0x801B , NAI_ERROR_ETHER_INVALID_MOD_SLOT_NUM_GEN4 = -0x801C , NAI_ERROR_ETHER_FILE_NOT_RECEIVED_GEN4 = -0x8020 , NAI_ERROR_ETHER_EXTRACTING_FILE_GEN4 = -0x8021 ,
  NAI_ERROR_ETHER_FFMAPFILE_NOT_FOUND_GEN4 = -0x8022 , NAI_ERROR_ETHER_FFMAPFILE_INVALID_ENTRY_GEN4 = -0x8023 , NAI_ERROR_ETHER_FLASHFILE_NOT_FOUND_GEN4 = -0x8024 , NAI_ERROR_ETHER_FLASHFILE_LENGTH_MISMATCH_GEN4 = -0x8025 ,
  NAI_ERROR_ETHER_FLASHFILE_CHECKSUM_MISMATCH_GEN4 = -0x8026 , NAI_ERROR_ETHER_FLASHFILE_WRITING_TO_FLASH_GEN4 = -0x8027 , NAI_ERROR_ETHER_EXEMODE_MUST_BE_IN_CFG_MODE_GEN4 = -0x8030 , NAI_ERROR_ETHER_EXEMODE_MUST_BE_IN_OP_MODE_GEN4 = -0x8031 ,
  NAI_ERROR_ETHER_MODULE_LINK_DOWN_GEN4 = -0x8032 , NAI_ERROR_ETHER_INVALID_BLOCK_ID_GEN4 = -0x8100 , NAI_ERROR_ETHER_INVALID_TDR_ID_GEN4 = -0x8101 , NAI_ERROR_ETHER_INVALID_IDR_ID_GEN4 = -0x8102 ,
  NAI_ERROR_ETHER_INVALID_REG_COUNT_GEN4 = -0x8103 , NAI_ERROR_ETHER_BLOCK_NOT_CONFIGURED_GEN4 = -0x8104 , NAI_ERROR_ETHER_TDR_NOT_CONFIGURED_GEN4 = -0x8105 , NAI_ERROR_ETHER_IDR_NOT_CONFIGURED_GEN4 = -0x8106 ,
  NAI_ERROR_SERDES_WRONG_SLOT_NUM = -0x8201 , NAI_ERROR_SERDES_INVALID_SLOT_ID = -0x8202 , NAI_ERROR_SERDES_UNEXPECTED_PAYLOAD_COUNT = -0x8203 , NAI_ERROR_SERDES_MODULE_NOT_FOUND = -0x8204 ,
  NAI_ERROR_SERDES_MIS_ALIGNED_BYTE_ENABLE = -0x8205 , NAI_ERROR_SERDES_INVALID_PARAMETER_VALUE = -0x8206 , NAI_ERROR_SERDES_SYSTEM_NOT_READY = -0x8207 , NAI_ERROR_SERDES_MODULE_NOT_READY = -0x8208 ,
  NAI_ERROR_SERDES_UNABLE_TO_ALLOCATE_MEMORY = -0x8209 , NAI_ERROR_SERDES_COMMAND_NOT_RECOGNIZED = -0x820A , NAI_ERROR_SERDES_TX_FIFO_NOT_EMPTY_TIMEOUT = -0x820B , NAI_ERROR_SERDES_RX_FIFO_PKT_NOT_READY_TIMEOUT = -0x820C ,
  NAI_ERROR_SERDES_DETECT_MODULES_TIMEOUT = -0x820D , NAI_ERROR_SERDES_I2C_DEVICE_NOT_FOUND = -0x820E , NAI_ERROR_SERDES_UNABLE_TO_LOCK_MUTEX = -0x820F , NAI_ERROR_SERDES_UNABLE_TO_UNLOCK_MUTEX = -0x8210
}
 
enum  nai_intf {
  NAI_INTF_VME = 0x00 , NAI_INTF_ETHER = 0x01 , NAI_INTF_PCI = 0x02 , NAI_INTF_PROC = 0x03 ,
  NAI_INTF_I2C = 0x08 , NAI_INTF_ONBOARD = 0xFF
}
 
enum  nai_maskreg_op { NAI_MASKREG_OP_CLEAR = 0x0000 , NAI_MASKREG_OP_SET = 0x0001 , NAI_MASKREG_OP_TOGGLE = 0x0002 }
 

Typedef Documentation

◆ nai_intf_t

typedef uint8_t nai_intf_t

◆ nai_maskreg_op_t

typedef uint32_t nai_maskreg_op_t

◆ nai_status_t

Enumeration Type Documentation

◆ nai_intf

enum nai_intf
Enumerator
NAI_INTF_VME 
NAI_INTF_ETHER 
NAI_INTF_PCI 
NAI_INTF_PROC 
NAI_INTF_I2C 
NAI_INTF_ONBOARD 

◆ nai_maskreg_op

Enumerator
NAI_MASKREG_OP_CLEAR 
NAI_MASKREG_OP_SET 
NAI_MASKREG_OP_TOGGLE 

◆ nai_status

enum nai_status

nai_status

Enumerator
NAI_SUCCESS 
NAI_ERROR_INVALID_VALUE 
NAI_ERROR_INVALID_MODE 
NAI_ERROR_INVALID_SIZE 
NAI_ERROR_INVALID_TYPECODE 
NAI_ERROR_INVALID_ADDRESS 
NAI_ERROR_INVALID_ADDRBOUND 
NAI_ERROR_INVALID_COMMAND 
NAI_ERROR_NOT_FOUND 
NAI_ERROR_TIMEOUT 
NAI_ERROR_COMM_ERROR 
NAI_ERROR_LOCK_FAILED 
NAI_ERROR_INVALID_WIDTH 
NAI_ERROR_INVALID_CARD 
NAI_ERROR_INVALID_MODULE 
NAI_ERROR_INVALID_CHANNEL 
NAI_ERROR_OPEN_FAILED 
NAI_ERROR_INVALID_MESSAGE 
NAI_ERROR_MESSAGE_MISMATCH 
NAI_ERROR_OVERFLOW 
NAI_ERROR_NOT_MASTER 
NAI_ERROR_DISCONNECTED 
NAI_ERROR_IN_USE 
NAI_ERROR_FULL 
NAI_ERROR_EMPTY 
NAI_ERROR_NOT_READY 
NAI_ERROR_CONNECTION_LOST 
NAI_ERROR_NOT_OPEN 
NAI_ERROR_PARITY 
NAI_ERROR_FRAMING 
NAI_ERROR_FRAMING_PARITY 
NAI_ERROR_NO_MESSAGE 
NAI_ERROR_WATCHDOG 
NAI_ERROR_BUS_TIMEOUT 
NAI_ERROR_INVALID_RANGE 
NAI_ERROR_WRONG_DEVICE 
NAI_ERROR_BUS_READ_ERR 
NAI_ERROR_BUS_WRITE_ERR 
NAI_ERROR_MORE_DATA 
NAI_ERROR_INVALID_ENCODER_RES 
NAI_ERROR_INVALID_COMMUTATION_POLES 
NAI_ERROR_INVALID_RATIO 
NAI_ERROR_INVALID_IO_PARAM 
NAI_ERROR_BIT_FAILED 
NAI_ERROR_VME_ADDR_TRANSLATION 
NAI_ERROR_BSP_VME_TABLE 
NAI_ERROR_INT_CONNECT_FAILED 
NAI_ERROR_INT_DISCONNECT_FAILED 
NAI_ERROR_1553_MESSAGE_ERROR 
NAI_ERROR_1553_DATA_WRAPAROUND_ERROR 
NAI_ERROR_PERMISSION_DENIED 
NAI_ERROR_UNLOCK_FAILED 
NAI_ERROR_PROTOCOL_FUNCTION_MISMATCH 
NAI_ERROR_FUNCTION_SPECIFIC_ERROR 
NAI_ERROR_NOT_SUPPORTED 
NAI_ERROR_UNKNOWN 
NAI_ERROR_UNKNOWN_VALUE 
NAI_ERROR_ETHER_GENERAL_GEN4 
NAI_ERROR_ETHER_INVALID_MSG_PREAMBLE_GEN4 
NAI_ERROR_ETHER_INVALID_MSG_SEQ_NUM_GEN4 
NAI_ERROR_ETHER_INVALID_MSG_TYPECODE_GEN4 
NAI_ERROR_ETHER_INVALID_MSG_LENGTH_GEN4 
NAI_ERROR_ETHER_INVALID_MSG_POSTAMBLE_GEN4 
NAI_ERROR_ETHER_INVALID_PAYLOAD_SIZE_GEN4 
NAI_ERROR_ETHER_COMMAND_NOT_IMPLEMENTED_GEN4 
NAI_ERROR_ETHER_INVALID_CONFIG_TYPECODE_GEN4 
NAI_ERROR_ETHER_INVALID_OPERATION_TYPECODE_GEN4 
NAI_ERROR_ETHER_INVALID_MB_INFOTYPE_GEN4 
NAI_ERROR_ETHER_INVALID_MOD_INFOTYPE_GEN4 
NAI_ERROR_ETHER_INVALID_MOD_ID_GEN4 
NAI_ERROR_ETHER_OPENING_EEPROM_GEN4 
NAI_ERROR_ETHER_READING_EEPROM_GEN4 
NAI_ERROR_ETHER_WRITING_EEPROM_GEN4 
NAI_ERROR_ETHER_INVALID_PAYLOAD_LENGTH_GEN4 
NAI_ERROR_ETHER_INFOTYPE_READONLY_GEN4 
NAI_ERROR_ETHER_READING_MOD_INFO_GEN4 
NAI_ERROR_ETHER_WRITING_MOD_INFO_GEN4 
NAI_ERROR_ETHER_INVALID_MOD_SLOT_NUM_GEN4 
NAI_ERROR_ETHER_FILE_NOT_RECEIVED_GEN4 
NAI_ERROR_ETHER_EXTRACTING_FILE_GEN4 
NAI_ERROR_ETHER_FFMAPFILE_NOT_FOUND_GEN4 
NAI_ERROR_ETHER_FFMAPFILE_INVALID_ENTRY_GEN4 
NAI_ERROR_ETHER_FLASHFILE_NOT_FOUND_GEN4 
NAI_ERROR_ETHER_FLASHFILE_LENGTH_MISMATCH_GEN4 
NAI_ERROR_ETHER_FLASHFILE_CHECKSUM_MISMATCH_GEN4 
NAI_ERROR_ETHER_FLASHFILE_WRITING_TO_FLASH_GEN4 
NAI_ERROR_ETHER_EXEMODE_MUST_BE_IN_CFG_MODE_GEN4 
NAI_ERROR_ETHER_EXEMODE_MUST_BE_IN_OP_MODE_GEN4 
NAI_ERROR_ETHER_MODULE_LINK_DOWN_GEN4 
NAI_ERROR_ETHER_INVALID_BLOCK_ID_GEN4 
NAI_ERROR_ETHER_INVALID_TDR_ID_GEN4 
NAI_ERROR_ETHER_INVALID_IDR_ID_GEN4 
NAI_ERROR_ETHER_INVALID_REG_COUNT_GEN4 
NAI_ERROR_ETHER_BLOCK_NOT_CONFIGURED_GEN4 
NAI_ERROR_ETHER_TDR_NOT_CONFIGURED_GEN4 
NAI_ERROR_ETHER_IDR_NOT_CONFIGURED_GEN4 
NAI_ERROR_SERDES_WRONG_SLOT_NUM 
NAI_ERROR_SERDES_INVALID_SLOT_ID 
NAI_ERROR_SERDES_UNEXPECTED_PAYLOAD_COUNT 
NAI_ERROR_SERDES_MODULE_NOT_FOUND 
NAI_ERROR_SERDES_MIS_ALIGNED_BYTE_ENABLE 
NAI_ERROR_SERDES_INVALID_PARAMETER_VALUE 
NAI_ERROR_SERDES_SYSTEM_NOT_READY 
NAI_ERROR_SERDES_MODULE_NOT_READY 
NAI_ERROR_SERDES_UNABLE_TO_ALLOCATE_MEMORY 
NAI_ERROR_SERDES_COMMAND_NOT_RECOGNIZED 
NAI_ERROR_SERDES_TX_FIFO_NOT_EMPTY_TIMEOUT 
NAI_ERROR_SERDES_RX_FIFO_PKT_NOT_READY_TIMEOUT 
NAI_ERROR_SERDES_DETECT_MODULES_TIMEOUT 
NAI_ERROR_SERDES_I2C_DEVICE_NOT_FOUND 
NAI_ERROR_SERDES_UNABLE_TO_LOCK_MUTEX 
NAI_ERROR_SERDES_UNABLE_TO_UNLOCK_MUTEX