Page 4
Notice: The information that is provided in this document is believed to be accurate. No responsibility is assumed by AIM for its use. No license or rights are granted by implication in connection therewith. Specifications are subject to change without notice.
DOCUMENT HISTORY The following table defines the history of this document. Appendix A provides a more comprehensive list of changes made with each version. Version Cover Date Created by Description V10.01 10.02.2000 Rolf Heitzmann See Appendix A for details V10.01 Rev A 18.02.2000 Rolf Heitzmann See Appendix A for details...
Page 6
V21.6x Rev. B 06.08.2010 Thomas Jahn New AIM-USA address V21.6x Rev. C 14.09.2010 Jochen Pfaadt See Appendix A for details V21.7x Rev. A 12.2010 Jochen Pfaadt Some cosmetic changes V22.0x Rev. A 07.01.2010 Martin Haag See Appendix A for details V22.1x Rev.
INTRODUCTION 1.1 Welcome Welcome to the Software Library Reference Manual for the AIM MIL-STD-1553 application programming interface. This reference manual, in conjunction with the Programmer's Guide, is intended to provide the software (s/w) programmer with the information needed to develop a host computer application interface to the AIM 1553 interface module.
Page 16
Section 12 contains helpful information enabling the user Trouble- to interpret error messages and steps to take to correct shooting those errors. App A Provides detailed information regarding the history of Document/ the API Library reference software and documentation Software History MIL-STD-1553 Reference Manual...
API S/W Library. In addition, the software and firmware contained on the AIM bus interface 1553 device will be referred to as the Target S/W. Several references will be made within the API S/W Library function description to the Application Interface.
Chapter 1 - Introduction (located in Ai1553i_def.h) Data Types - all variable are assigned an AIM equated data type as shown in Table 1.4-I below (defined in ai_cdef.h): Table 1.3.2-I API S/W Library Data type Naming Conventions Size API S/W Library...
Return Value The value returned via the function is a status/error code defining the success/failure of the function call. The status/error code value is detailed here. MIL-STD-1553 Reference Manual...
"ul_ModuleHandle " - usually the first function parameter. This parameter determines the AIM destination module handle. The handle is returned by ApiOpen() or ApiOpenEx(). "biu" - usually the second function parameter. This parameter determines the Bus Interface Unit (biu) of the selected AIM module.
1.4 Special Board Functionality The AIM boards can be configured with restricted functionality, thus providing the user with only the function(s) required by their application. When the AIM board is delivered with restricted functionality, the application program developer will be restricted to utilize only the API Software Library Reference calls that are applicable to the functional capabilities provided on the AIM board as defined in Table 1.3.5-1.
PCI Local Bus Specification, Revision 2.1, June 1991 1.5.2 AIM Document Family AIM has developed several documents that may be used to aid the developer with other aspects involving the use of the AIM 1553 interface module(s). These documents and a summary of...
Page 24
APU1553 Hardware Manual (USB Bus modules) AEC1553 Hardware Manual (ExpressCard Bus modules) AMCX1553 Hardware Manual (PMC Bus modules) AXC1553 Hardware Manual (XMC Bus modules) ACE1553 Hardware Manual (PXIe Bus modules) ACXX1553 Hardware Manual (PXI Bus modules) MIL-STD-1553 Reference Manual...
There is a separate header AiOs.h file which may also be included to an application. It includes a operating system specific header file like AiOsWindows.h, which provide a set of functions that do the same for each operating system, but have to be encoded a little bit differently. MIL-STD-1553 Reference Manual...
Page 26
Chapter 1 - Introduction THIS PAGE INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Provides a pointer to the interrupt handler function ApiOpen Initializes the AIM module & provides the handle for future board commands ApiOpenEx Initializes the AIM module & stream & provides the handle for future board commands ApiPrintfOnServer Prints message on console output of ANS console ApiSetDeviceConfig...
Page 28
Provides the PCI header information of a board on the local PCI bus. AiVmeInitGenericInterrupt Sets interrupt specific parameters of the board. AiVme1553MapModule Maps a board to the VME bus AiVme1553UnmapModule Removes a board from the VME bus MIL-STD-1553 Reference Manual...
ApiOpen(..)) shall be called after ApiClose(..). Input Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiInt16 ApiConnectToServer( AiUChar * pszNetworkAdress, AiInt16 *w_ServerBoards ); Driver Command: none Purpose: Establishes a network connection to a specified server PC, where the AIM Network Server (ANS) is located. Input Name of the PC, where the ANS is located. Value Description <SrvName>...
ApiOpenEx() API_INT_LS Remove interrupt routine for LS API_INT_HS Remove interrupt routine for HS Interrupt Type Defines the type of interrupt which will be "uninstalled" for the given AIM board. Value Constant Description API_INT_RT interrupt for RT related events API_INT_BC interrupt for BC related events...
AiInt16 ApiDisconnectFromServer( AiUChar * pszNetworkAdress ); Driver Command: none Purpose: Disconnect a previously established network connection from a specified server PC, where the AIM Network Server (ANS) is located. Input Name of the PC, where the ANS is located. Value Description <SrvName>...
Chapter 2 - Library Administration and Initialization Functions 2.1.5 ApiExit Prototype: AiInt16 ApiExit( void ); Driver Command: none Purpose: This function cleans up the library resources so it is safe to unload it. Input Output Return Value Always zero. MIL-STD-1553 Reference Manual...
Page 36
Indicates the Board Type that is setup onboard Indicates the Board Configuration that is setup onboard Indicates the Board Serial Number Indicates the AIM Part Number of the board Indicates the Global RAM size (in 64kBytes steps) Indicates the Shared RAM size (in 64kBytes steps) Indicates for each BIU on the board with which offset its Global RAM starts (relative to the Global RAM Start).
Page 37
If set to 1, IRIG can be switched between intern / extern Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
DMA transfer will be issued. This value is only applicable for system driver version 12 or higher. The memory type of the memory where the data queue headers are located. Value Define Description API_MEMTYPE_SHARED Shared memory API_MEMTYPE_LOCAL Local memory (AyI) MIL-STD-1553 Reference Manual...
Page 39
By default the interrupts are physically enabled and the flag will return 0. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt32 ul_BoardType; AiUInt32 ul_OpenConnections; AiUInt32 ul_ReservedLW6; AiUInt32 ul_ReservedLW7; AiUInt32 ul_ReservedLW8; } TY_API_DRIVER_INFO; The hardware platform group that the device belongs to. Value Define Description TYPE_BOARD_UNKNOWN Unrecognized TYPE_BOARD_AYI TYPE_BOARD_AYX TYPE_BOARD_AMC TYPE_BOARD_AMC_ASP Amc-Asp TYPE_BOARD_AYE TYPE_BOARD_AYE_ASP AyE-Asp TYPE_BOARD_AYX_GNET AyX-Gnet TYPE_BOARD_USB MIL-STD-1553 Reference Manual...
Page 41
The number of connected applications including the current connection. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
All API calls return API_OK in a no error condition. The return value of each API call should be checked if it is not equal to API_OK. Input The error code to be described. Output Return Value A pointer to a string with the error description. MIL-STD-1553 Reference Manual...
Number of applications (processes) that are currently attached to the library. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function returns the open error code, after an unsuccessful call of ApiOpen(...). Input Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiInt16 ApiGetServerInfo( TY_SERVERINFO *pServerInfo ); Driver Command: (none) Purpose: Reads extended information about the AIM boards installed on the AIM Network Server (ANS) PC. Note: The network connection to the server PC already has to be established with the ApiConnectToServer call.
Page 46
Minor version number of the internal RPC interface Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function returns the current target communication status of the Application Interface. Input Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
(maintained by the Application Interface) is returned to the calling function.) Input Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
API S/W Library function is applied. Input Output Return Value Operating System Value Windows Amount of boards found Linux Amount of boards found VxWorks Always 1, due to the fixed memory mapping MIL-STD-1553 Reference Manual...
"pf_IntFunc". Value Constant Description API_INT_RT interrupt for RT related events API_INT_BC interrupt for BC related events API_INT_BM interrupt for BM related events API_INT_REPLAY interrupt for Replay related events API_INT_BC_BRANCH interrupt for BC Branch (e.g. Skip) related events MIL-STD-1553 Reference Manual...
Page 51
Bus Interface Unit 2 on the AIM board API_BIU_8 Bus Interface Unit 8 on the AIM board Interrupt type as defined in parameter "uc_Type" above. Contains the type of interrupt that the AIM board has generated. Value Constant Description API_INT_RT...
Page 52
Bit 28 Bit 27 Bit 26 Bit 25 Bit 24 INT_TYPE INT_TYPE INT_TYPE METI REPLAY INT_TYPE BC_BRANCH INT_TYPE TYPE Bit 23 Bit 22 Bit 21 Bit 20 Bit 19 Bit 18 Bit 17 Bit 16 REPLAY BC_BRANCH MIL-STD-1553 Reference Manual...
Page 53
Monitor Start Interrupt If set to 1, an interrupt was asserted due to a Monitor start trigger event Monitor Stop Interrupt If set to 1, an interrupt was asserted due to a Monitor stop trigger event (1553 protocol only) MIL-STD-1553 Reference Manual...
Page 54
RT_ADDR reserved TRANS_ID reserved REPLAY reserved BC_BRANCH reserved TYPE Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 1553 RT_SUB MODE_CODE / WORD_COUNT 3910 TRANS_ID Reserved REPLAY Reserved BC_BRANCH Reserved MIL-STD-1553 Reference Manual...
Page 55
Interrupt has been generated from onboard DMA controller Interrupt has been generated from onboard ASP (Target-SW) Reserved for internal use AiUInt32 x_Lld.ul_All TYPE Bit 31 Bit 30 Bit 29 Bit 28 Bit 27 Bit 26 Bit 25 Bit 24 1553 3910 INT_SOURCE REPLAY BC_BRANCH MIL-STD-1553 Reference Manual...
Page 56
Interrupt has been generated from BIU8 BUF_INDEX Data Buffer Index Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
API S/W Library function is used for the specified module. This function establishes connectivity between the Application Interface and the AIM board by calling operating system routines to open the AIM board and initialize a shared memory area for host-to-target communication.
Page 58
Chapter 2 - Library Administration and Initialization Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
API S/W Library function is used for the specified module. This function establishes connectivity between the Application Interface and the AIM board by calling operating system routines to open the AIM board and initialize a shared memory area for host-to-target communication.
Page 60
Name of the PC, where the ANS Server is running Value Description "local" Local use of the board <SrvName> Name of the PC, where the ANS (AIM Network Server) is running (e.g. “\\SW-PC-06” or “192.168.0.119”) Output API Board Module Access Handle Note: pul_ ModuleHandle must be used as input for all other functions.
AiInt16 ApiPrintfOnServer( const AiUChar *szMsg ); Driver Command: none Purpose: Prints a message on the console output of the AIM Network Server (ANS). Note: The network connection to the server PC already has to be established with the ApiConnectToServer call.
This value is only applicable for system driver version 12 or higher. The memory type of the memory where the data queue headers are located. Value Define Description API_MEMTYPE_SHARED Shared memory API_MEMTYPE_LOCAL Local memory (AyI) The number of interrupt requests sent to the driver. MIL-STD-1553 Reference Manual...
Page 63
Do not change setting (Interrupts are enabled by default) Enable interrupts Disable interrupts Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Force error message box, if I/O to the board fails with error or range check fails 0xFFFFFFFF DBG_ALL Force all available debug output Note: The default debug level after program start is set to 0x30000000 (DBG_ERROR | DBG_INFO | DBG_PARAMCHK)! Output Return Value MIL-STD-1553 Reference Manual...
Application Interface) is returned to the calling function by the Application Interface. Command Emulation Mode Value Constant Description API_DIS Disable / reset command emulation (default) If an error occurs, the emulation mode is enabled automatically ! API_ENA Enable command emulation permanently API_DIS_ON_ERROR Disable command emulation permanently Return Value MIL-STD-1553 Reference Manual...
Driver Command: None Purpose: Runs the PCI config cycle on the AIM board on the A16 address specified in in->ul_A16Addr, regardless of its protocoll and writes its data into the output parameters px_PCI_Info1 and px_PCI_Info2. Using these output parameters an AVI1553, AVX1553 board or an AMC153 board on an AVC-2 carrier can be initialized using the function AiVme1553MapModule().
Page 67
AiUInt32 ul_BarBaseAddress; // PCI Base Address of BAR reg } TY_PCI_BAR_INFO; As px_PCI_Info1, but it contains the configuration data of the second PMC board of an AVC-2 carrier. For all other boards, this value may be ignored. Return Value MIL-STD-1553 Reference Manual...
Please see Table B-III – Function Note: Support By Boards With ASP for details Parameters used to map this board to the VME bus in function AiVme1553MapModule(). None Return Value Constant Description MIL-STD-1553 Reference Manual...
PCI headers of all boards found. It allows to use the AiPciGetHeader() command to get the PCI header of any board found. this function is not supported for all boards. Please see Table B-III – Function Note: Support By Boards With ASP for details None None Return Value MIL-STD-1553 Reference Manual...
An index of zero returns the first board that was found. None Return Value typedef struct { TY_PCI_CONFIGSPACE_HEADER x_PCIConfHd; TY_PCI_BAR_INFO x_PCIBarInfo[6]; AiUInt32 ul_PCITotalMemorySize; AiUInt32 ul_PCIStartAddress; AiUInt32 ul_A16Address; AiUInt8 uc_VmeHandleCount; AiUInt busNo; AiUInt8 deviceNo; AiUInt8 funcNo; } TY_PCI_INFO; MIL-STD-1553 Reference Manual...
Using this parameter the interrupt vector can be applied to the board. Note: if two PMC boards are driven on the same AVC-2 carrier, both must have the same interrupt level and vector. MIL-STD-1553 Reference Manual...
Page 72
‘*intFuntion’ of type VOID_FUNC is the function pointer which should be called in case of interrupt. This function is a driver internal interrupt function which handles the hardwae interrupt on the AIM board and distributes to the user interrupt functions. The type VOID_FUNC is defined as follows: typedef void VOID_FUNC(void);...
(real, physical A32 address). The memory size for the module in the A32 space is dependant on the amount of memory on the module. The real memory depends on the settings of the PCI-BAR register of the AIM Module. For all requested memory of the AIM Module one image is mapped on the VME-bus.
Page 74
VME CPU, this value shall be set to zero. Pointer to the PCI info element for this board. It determines for which board the additional settings are. To get this parameter please use the output of AiVmeExamineSlot() or AiPciGetHeader() None Return Value Value Description MIL-STD-1553 Reference Manual...
Please see Table B-III – Function Note: Support By Boards With ASP for details This is the structure that was used to map the board to the bus. None Return Value MIL-STD-1553 Reference Manual...
Page 76
Chapter 2 - Library Administration and Initialization Functions THIS PAGE IS INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Function Description ApiCmdIni Initializes AIM board and returns board configuration ApiCmdReset Resets the AIM board and ASP driver software data to initial state ApiCmdBite Performs a selftest on the AIM board ApiCmdDefRespTout Defines the response timeout value (default is 14 µsec)
Page 78
Chapter 3 – System Functions Function Description ApiCmdReadDiscretes Reads from the onboard discrete register ApiCmdWriteDiscretes Writes to the onboard discrete register ApiCmdInitDiscretes Initializes the onboard discrete behaviour MIL-STD-1553 Reference Manual...
API_BITE (0x32) Purpose: This function is used to perform a selftest on the AIM board. The selftest result is reported as part of the returning information. After a Selftest Command the currently active board setups are lost, due to the performed RAM Test.
Page 80
API_BITE_ERR_ADDRESSING Bus Test API_BITE_ERR_BUS Global RAM Test error API_BITE_ERR_GLOBAL_RAM_BM BIU BM area Data Pattern Test API_BITE_ERR_DATA_PATTERN Walking Bit Test API_BITE_ERR_WALKING_BIT Addressing Test API_BITE_ERR_ADDRESSING API_BITE_ERR_BUS Bus Test Shared RAM Test error API_BITE_ERR_SHARED_RAM (at 0x100000 offset) Paging Test API_BITE_ERR_PAGING MIL-STD-1553 Reference Manual...
Page 81
D/A Converter Test, Bus A API_BITE_ERR_DA_CONV_BUSA D/A Converter Test, Bus B API_BITE_ERR_DA_CONV_BUSB Timing Test error API_BITE_ERR_TIMING LS BC Minor Framing API_BITE_ERR_TIMING_MFRM_50 Time 50ms API_BITE_ERR_TIMING_MFRM_10 Time 10ms API_BITE_ERR_TIMING_MFRM_1 Time 1ms LS RT Response Time API_BITE_ERR_TIMING_RT_RESPONSE LS Intermessage Gap API_BITE_ERR_TIMING_IMG MIL-STD-1553 Reference Manual...
Page 82
Monitor Error Count API_BITE_ERR_HS_INT_MON_ERR_CNT_RE mismatch during Replay Test Monitor data mismatch API_BITE_ERR_HS_INT_MON_DATA_REP during Replay Test Timetag Counter Tests Time Tag too slow API_BITE_ERR_HS_INT_TT_SLOW Time Tag too fast API_BITE_ERR_HS_INT_TT_FAST Time Tag Timeout API_BITE_ERR_HS_INT_TT_TIMEOUT (not counting or very slow) MIL-STD-1553 Reference Manual...
Page 83
LS-HS Correlation Time API_BITE_ERR_HS_TIMING_CORR Receiver Timeout API_BITE_ERR_HS_TIMING_RX_TO Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Chapter 3 – System Functions 3.1.2 ApiCmdBiuIntrCheck (obsolete) This function is no longer supported. Please use the functions ApiInstIntHandler and ApiDelIntHandler instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
Value Description 0..31 RT number Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function is used to define the Response Timeout value for Simulator and Bus Monitor operation of the AIM board. The Response Timeout value is the maximum time the Bus Controller will wait for a Status word response from the RT.
3.1.5 ApiCmdExecSys Prototype: AiInt16 ApiCmdExecSys ( AiUInt32 ul_ModuleHandle, AiUInt8 mode, AiUInt8 con ); Driver Command: API_EXEC_SYS (0x3C) Purpose: This function is used to execute a system related function on the AIM board target. Input Value Constant Description API_MODE_TIMETAG_SOURCE Timetag source*...
Page 88
Chapter 3 – System Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Higher Byte of the IRIG day field Lower Byte of the IRIG day field Value of the IRIG hour field (0..23) Value of the IRIG minute field (0..59) Value of the IRIG second field (0..59) Higher Byte of the IRIG milli second field MIL-STD-1553 Reference Manual...
Page 90
IRIG signal is detected. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiInt16 ApiCmdIni( AiUInt32 ul_ModuleHandle, AiUInt8 mode, TY_API_INI_INFO *pini ); Driver Command: API_INI (0x30) Purpose: This function is used to initialize the AIM board after system or power-up reset and to return AIM board specific information. Input Initialization mode Value Constant...
Page 93
API_PBI_DUAL_1553_ONE_BIU MIL1553 dual channel with one BIU API_PBI_SINGLE_1553_DBTE MIL1553 single channel for DBTE Value Constant Description 1, 2, 10 API_PBI_STANDARD Standard PBI API_PBI_PROGRAMMABLE Programmable PBI API_PBI_ELECTRICAL Electrical interface API_PBI_ONBOARD_FOFE Onboard FOFE API_PBI_APX_MILSCOPE With MIL-Scope API_PBI_APX_STANDARD Without MIL-Scope reserved API_PBI_PROGRAMMABLE Programmable PBI MIL-STD-1553 Reference Manual...
Page 94
64bit PMC, with ASP 0x60 64bit API-1 with ASP, based on XSCALE architecture 0x70 PC-Card (Cardbus) 0x75 ExpressCard 0x80 PC104 0x90 PC-PCIX Short Card (APX) 0xA0 USB based Global Memory Size (in 64kBytes steps) Global Memory Base Address MIL-STD-1553 Reference Manual...
Page 95
Internal use only. Internal use only. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Discrete is used as Input Discrete is used as Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
API_LOAD_SREC (0x36) Purpose: This function is used to download strings in S-Record format to the AIM board target. The S-Record ASCII characters are converted into an executable format. this function is not supported for all boards. Please see Table B-III – Function...
Page 98
All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. Note: No further function (except ApiClose) shall be called when starting the downloaded code with ‘mode=2' since the target software is restarted. MIL-STD-1553 Reference Manual...
API_PROG_FLASH (0x37) Purpose: This function is used to perform in-circuit programming of the AIM on-board Flash- Prom devices to update the ASP Driver Software and BIU Firmware. this function is not supported for all boards. Please see Table B-III – Function...
Page 100
API_FLASH_ERR_PROG flash programming error Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Timer/Counter 2 API_TIMER_4 Timer/Counter 3 Timer function type Value Constant Description API_INIT_TIMER Initialize Software Timer API_START_TIMER Start PSC Timer API_STOP_TIMER Stop PSC Timer Timer control (only used in mode 0) Value Constant Description API_DIS Disable API_ENA Enable MIL-STD-1553 Reference Manual...
Page 102
2 - not used Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Bit 8 Reserved (0) Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Note: The bits are only valid if the corresponding discretes are configured as Input with the function ApiCmdInitDiscretes! MIL-STD-1553 Reference Manual...
Page 104
Chapter 3 – System Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt16 *fw_id, AiUInt16 *sw_id, AiUInt16 *lca_id, AiUInt32 *lca_chks ); Driver Command: API_READ_SW_VERS (0x34) Purpose: This function is used to read the Software version numbers of the AIM board target software parts. Input Output Firmware ID (4 digit BCD format) Driver Software version number (4 digit BCD format)
API_RESET (0x31) Purpose: This function initializes the AIM board Hardware and the ASP Driver Software data structures and variables to an initial state. The ApiCmdReset function reports memory configuration information and has to be applied before using any of the API S/W library functions described in the following sections.
Page 107
26-bit global memory pointer (byte address) to bus simulator buffer start address Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
} TY_API_IRIG_TIME Higher Byte of the IRIG day field Lower Byte of the IRIG day field Value of the IRIG hour field (0..23) Value of the IRIG minute field (0..59) Value of the IRIG second field (0..59) MIL-STD-1553 Reference Manual...
Page 109
IRIG signal is detected, the IRIG source is switched automatically to internal. Note: This parameter is not possible on all AIM boards. Please check chapter “Board functionality overview”. If your board does not support INTERN/EXTERN switching it uses “Free Wheeling Mode”...
On BC side the functionaliy is only applicaple if enabled with the function ApiCmdBCModeCtrl()! Note: On RT side the functionaliy is only applicaple if the BC is not running! Input Output Synchronization Counter get structure typedef struct ty_api_sync_cnt_set AiUInt32 ul_SyncCntVal; AiUInt32 ul_SyncCntInit; AiUInt32 ul_SyncCntInitLow; AiUInt32 ul_SyncCntInitHigh; } TY_API_SYNC_CNT_SET MIL-STD-1553 Reference Manual...
Page 111
DAYS Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 DAYS HOURS Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 HOURS MINUTES MIL-STD-1553 Reference Manual...
Page 112
Chapter 3 – System Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Synchronization Counter in steps of 64µs (range from 0..4,19 sec) Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Name of the request for debug and bug check purpose. Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This array must be preallocated with the size of ulDataCount. This array contains the requested values. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
To get the default values of the board memory settings, just call ApiCmdSysGetMemPartition as the first call in your application after a reboot of your computer! Value Description reserved typedef struct ty_api_get_mem_layout TY_API_MEM_BIU_ADDR ax_BiuAddr[8]; TY_API_MEM_SIM_BUF x_Sim[2]; TY_API_MEM_BIU_SIZE ax_BiuSize[8]; TY_API_MEM_BIU_COUNT ax_BiuCnt[8]; TY_API_MEM_BIU_INFO ax_BiuInfo[8]; AiUInt32 aul_GlobalMemSize[2]; } TY_API_GET_MEM_INFO; MIL-STD-1553 Reference Manual...
Page 117
Start address of the BC status queue area Start address of the BC event queue area Start address of the BC transfer descriptor area Start address of the BC high priority instruction list Start address of the BC low priority instruction list MIL-STD-1553 Reference Manual...
Page 118
Size of BC instruction list areas, Replay and BM buffer area (logical BIUs 1..8) typedef struct ty_api_mem_biu_size AiUInt32 ul_BcHipInstr; AiUInt32 ul_BcLipInstr; AiUInt32 ul_BcAcycInstr; AiUInt32 ul_RepBuf; AiUInt32 ul_BmBuf; } TY_API_MEM_BIU_SIZE; Size if the high priority instruction list in bytes Size if the low priority instruction list in bytes MIL-STD-1553 Reference Manual...
Page 119
Information structure how to use the other structure parts of this function typedef struct ty_api_mem_biu_info AiUInt32 ul_Protocol; AiUInt32 ul_StreamNb; AiUInt32 ul_MemoryBank; } TY_API_MEM_BIU_INFO; Protocol of the logical BIU referenced by the index (0..7) Value Constant Description API_PROTOCOL_1553 MIL-STD-1553B API_PROTOCOL_3910 STANAG3910 API_PROTOCOL_EFEX EFEX MIL-STD-1553 Reference Manual...
Page 120
Size of the Global RAM in MBytes for every Global Memory bank (0..1) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
The offset where the allocated buffer starts. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
ApiCmdSysGetMemPartition as the first call in your application after a reboot of your computer! Value Description Normal use case Reserved Enhanced BM activity page typedef struct ty_api_set_mem_layout AiUInt32 aul_SimBufSize[2]; TY_API_SET_MEM_BIU_SIZE ax_BiuSize[8]; TY_API_SET_MEM_BIU_COUNT ax_BiuCnt[8]; } TY_API_SET_MEM_INFO; Sizes of Simulator data buffers for every Global Memory bank (0..1) MIL-STD-1553 Reference Manual...
Page 123
Amount of BC & RT simulator related IDs (logical BIUs 1..8) typedef struct ty_api_set_mem_biu_count AiUInt32 ul_RtBhArea; AiUInt32 ul_RtSqArea; AiUInt32 ul_RtEqArea; AiUInt32 ul_BcBhArea; AiUInt32 ul_BcSqArea; AiUInt32 ul_BcEqArea; AiUInt32 ul_BcXferDesc; } TY_API_SET_MEM_BIU_COUNT; Maximum number of RT buffer header Ids This value shall be a multiple of 256! MIL-STD-1553 Reference Manual...
Page 124
Amount of Global RAM area used by requested partitioning in bytes for each Global Memory bank (0..1) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function is used to combine PXI specific trigger lines with the trigger lines of AIM boards. Any of the 8 PXI trigger lines can be set once to one trigger line of the AIM board, thus a maximum number of 8 trigger line combinations are possible.
Page 126
Onboard BM Trigger of Channel 2 ACX1553-4-3U available API_TRG_BM_CHN3 Only on ACX1553-4-3U available Onboard BM Trigger of Channel 3 API_TRG_BM_CHN4 Only on ACX1553-4-3U available Onboard BM Trigger of Channel 4 API_TRG_BM_HS Only on ACX3910-3U available Onboard BM HS Trigger MIL-STD-1553 Reference Manual...
Page 127
None Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
‘id’ was defined with type API_SYSTAG_FCT_CHECKSUM in function ApiCmdSystagDef() Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
1..255 System Dynamic Data identifier System Dynamic Data Control Value Constant Description API_DIS Disable System Dynamic Data Generation API_ENA Enable System Dynamic Data Generation Reserved API_ENA_INIT Enable System Dynamic Data Generation and initialize System Dynamic Data Word MIL-STD-1553 Reference Manual...
Page 130
Lower Limit of the System Dynamic Data Word 0..4095 Dataset Buffer Start ID (refer to function ApiCmdRamWriteDataset) 0..4095 Dataset Buffer ID (refer to function ApiCmdRamWriteDataset) 0..31 Word Position to build the complement from 0..31 Checksum Start Word Position MIL-STD-1553 Reference Manual...
Page 131
Identical to 'BIT_NB' = 16 Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
API_OK the function ApiGetErrorDescription can be used to obtain an error description. Note: The number of valid Timer Interrupt events is equal to the returned stat value. The number of interrupt events is cleared with every call of this function. MIL-STD-1553 Reference Manual...
Track Multiplex Buffer to store the 1553 data. Thus, providing a means to analyze specific filtered 1553 data transferred over the MILbus. Value Description 0..255 Track Multiplex Buffer Identifier Buffer type Value Constant Description API_TRACK_TYPE_BC BC Message Buffer API_TRACK_TYPE_RT RT Message Buffer API_TRACK_TYPE_MUX_TRACK Multiplexed Track (used for 2 level multiplexing) MIL-STD-1553 Reference Manual...
Page 134
Index in the Track's first word (defined by 'uw_TrackStartPos') Range of Number of Multiplexed Tracks Note: The number of bits selected uc_TrackBLen uw_MultiplexedTrackNb ( max) (uc_TrackBLen) controls the range of (uc_MultiplexedTrackNb) (as shown in the table at right.) 65536 MIL-STD-1553 Reference Manual...
Page 135
If zero is returned, there was not enough memory available on the Target. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Buffer type Value Constant Description API_TRACK_TYPE_BC BC Message Buffer API_TRACK_TYPE_RT RT Message Buffer API_TRACK_TYPE_MUX_TRACK Multiplexed Track (used for 2 level multiplexing) 'uc_BT' Bit 31 Bit 30 Bit 29 Bit 28 Bit 27 Bit 26 Bit 25 Bit 24 MIL-STD-1553 Reference Manual...
Page 137
Delete / Disable Track Definition API_ENA Create Track Definition Value Description 0..31 Data buffer word number of the Track starting location Value Description 0..15 Start bit position of the Track Multiplex Buffer Index in the Track's first word (defined by 'ul_TrackStartPos') MIL-STD-1553 Reference Manual...
Page 138
With this offset the start position of the data to be copied can be set, so the mux word of the track may be outside of these data words. Track definition output structure typedef struct ty_api_track_def_out AiUInt32 ul_TrackBufferStartAddr; } TY_API_TRACK_DEF_OUT; MIL-STD-1553 Reference Manual...
Page 139
If zero is returned, there was not enough memory available on the Target. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
The number of mux states where the memory shall be pre-allocated List of multiplex states where the data buffer memory shall be pre-allocated. Note: It is the responsibility of the user application that this list is of the size given with parameter ‘ul_PreAllocNb’ MIL-STD-1553 Reference Manual...
Page 141
Note: It is the responsibility of the user application that this list is of the size given with parameter ‘ul_PreAllocNb’ Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
If set to 1, the requested multiplex state could not be defined due to low memory Value Constant Description API_DATA_NOT_VALID Returned data is not valid (e.g. track buffer did not receive anything yet) API_DATA_VALID Data is valid Pointer to the Track Multiplex Buffer at the requested Track Index. MIL-STD-1553 Reference Manual...
Page 143
Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
It is the responsibility of the application to make sure that the Track Index does exceed length Track Multiplex Buffer (uw_MultiplexedTrackNb) defined in ApiCmdTrackDef. Value Constant Description API_TRACK_DONT_CLR_UDF Do not clear track update flag API_TRACK_CLR_UDF Clear track update flag after read MIL-STD-1553 Reference Manual...
Page 145
Bit 2 Bit 1 Bit 0 MICROSEC_OF_SEC (0..999999) Pointer to the Track Multiplex Buffer at the requested Track Index. Note: It is the responsibility of the application to make sure that enough memory is provided with this pointer! MIL-STD-1553 Reference Manual...
Page 146
Chapter 3 – System Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Function returns the second 16 multiplex states (17..32) and ul_MoreData = 1 ul_ChunkNb = 2 ul_ChunkSize = 16 Function returns the third 16 multiplex states (only 33..35 are valid, 36..48 are set to 0xFFFF) and ul_MoreData = 0 MIL-STD-1553 Reference Manual...
Page 148
Valid Multiplex State 0xFFFFFFFF Invalid Multiplex State Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 MASK The mask is used to define the discrete outputs that are actually written. A “1” marks the discrete output to be written. MIL-STD-1553 Reference Manual...
Page 150
The bits are only valid if the corresponding discretes are configured as Output with the function ApiCmdInitDiscretes! Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt32 *pul_DllBuild, AiUInt32 *pul_BoardSerialNr, AiUInt8 *puc_BspCompatibility ); Driver Command: API_READ_SW_VERS (0x34) Purpose: This function returns the version numbers of all board software package components for the AIM board. Input Output Firmware Version Number (e.g. "0x00000112" means V1.12) Bit 31 Bit16 Bit15...
Page 152
Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 0 (reserved) MAIN_VERSION Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 MAIN_VERSION MAIN_RELEASE MIL-STD-1553 Reference Manual...
Page 153
System Driver Version V3.10. Build Number of the system driver (BCD coded) Bit 31 Bit16 Bit15 Bit0 BUILD Build Number of the system driver. Version Number of the Application Interface DLL (BCD coded) Bit 31 Bit16 Bit15 Bit0 SPECIAL_VERSION VERSION MIL-STD-1553 Reference Manual...
Page 154
Build Number of the Application Interface DLL (BCD coded) Bit 31 Bit16 Bit15 Bit0 BUILD Build Number of the DLL. Serial Number of the AIM board Compatibility Status of the current BSP components relating to the DLL. Value Constant Description API_BSP_COMPATIBLE BSP components are compatible API_BSP_WRONG_SYS_W95_SW...
Page 155
Chapter 3 – System Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Purpose: This function returns the version numbers of all board software package components for the AIM board. The following structure describes the Version Type information including major version number, a minor version number, a build number, a special major version number and a special minor version number.
Page 157
Note: On 3910/3910Xp streams this reflects the Encoder/Decoder--LCA version! Version information of the BIU3 Onboard IO-LCA Note: Only valid for boards with at least 3 BIUs! Version information of the BIU3 Onboard 1553-Core-LCA Note: Only valid for boards with at least 3 BIUs! MIL-STD-1553 Reference Manual...
Page 158
Version information of the Onboard BIU4 Firmware Version information of the Onboard ASP Target Software Version information of the System Driver Version information of the Application Interface Library Version information of the Onboard Monitor Software Serial Number of the AIM board. MIL-STD-1553 Reference Manual...
Page 159
"puc_BspCompatibility" is always set to "API_BSP_NOT_COMPATIBLE"! Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Output Recording status information structure. typedef struct ty_api_bm_rec AiUInt8 status; AiUInt8 padding1; AiUInt16 padding2; AiUInt32 hfi_cnt; AiUInt32 saddr; AiUInt32 size; } TY_API_BM_REC; Bus Monitor Status Value Description Bus Monitor halted Bus Monitor busy 0 (Reserved) 0 (Reserved) MIL-STD-1553 Reference Manual...
Page 161
When the hfi_cnt value is incremented, the BM buffer contents have been copied from the Global RAM to the application buffer (see parameter 'lpBuf'). Start Address (Byte-Address) of the AIM board BM recording buffer which contains the recording buffer entries to be copied from the Global RAM to the application buffer area.
Global RAM of the AIM board area. Start Address of the AIM board Replay buffer in the Global RAM area to copy the replay buffer entries from the application buffer area (parameter 'lpBuf') to the Global RAM area of the AIM board.
Page 163
Pointer to application buffer area (replay data) Output Amount of bytes written Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 164
Chapter 3 – System Functions THIS PAGE IS INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Sets up the physical MILbus coupling mode ApiCmdCalSigCon Enables/disables 1 Mhz square wave calibration test signal ApiCmdCalTransCon Controls the data rate of MILbus (500 kbps or 1 Mbps). ApiCmdCalXmtCon Modifies the output amplitude of the MILbus/test signal MIL-STD-1553 Reference Manual...
API_CAL_BUS_PRIMARY Primary MILbus API_CAL_BUS_SECONDARY Secondary MILbus Note: Not all coupling modes are available on all AIM devices. Please check the capter “Board functionality overview” for details. Note: On boards where API_CAL_CPL_ISOLATED is not available it is internally wrapped to the mode API_CAL_CPL_WRAP_AROUND_LOOP.
Page 167
Decoder without relying on the external MILbus. Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function is used to enable/disable a 1 MHz square wave calibration test signal on the selected MILbus of the AIM board. The amplitude of the square wave signal depends on the setting of the appropriate D/A converter controlled by the library function ApiCmdCalXmtCon.
AiInt16 ApiCmdCalXmtCon ( AiUInt32 ul_ModuleHandle, AiUInt8 biu, AiUInt8 bus, AiUInt8 amp ); Driver Command: API_CAL_XMT_CON (0xD4) Purpose: This function is used to control the transmitter output amplitude of the selected MILBus transceiver on the AIM board via the voltage control pins. Input Value Constant Description API_CAL_BUS_PRIMARY...
Data Buffer Store Mode For Receive Operation the following options are valid: Value Constant Description API_BSM_RX_DISCARD Discard error messages from current Data Buffer API_BSM_RX_KEEP_CURRENT Keep error messages at the current Data Buffer 0xFFFFFFFF - Do not modify this parameter MIL-STD-1553 Reference Manual...
Page 173
Do not modify this parameter The Buffer Queue Mode is only processed, if the “Buffer is Note: valid”. The Buffer Queue Modes affect the Current Buffer Index and thus (in the future) the Status- and Event Queue Operation of the BC! MIL-STD-1553 Reference Manual...
Page 174
0xFFFFFFFF Do not modify this parameter Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Please use ApiCmdSystagDef instead. Input Output 1760 Control description typedef struct ty_api_c1760_con AiUInt8 mode ; AiUInt16 buf_id ; AiUInt8 c01; AiUInt8 c02[16]; } TY_API_C1760_CON; 1760 mode for the selected message buffer Value Constant Description API_DIS disable API_ENA enable MIL-STD-1553 Reference Manual...
Page 176
2..32 Wordposition in selected message buffer Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Write Buffer Data Words to Data Buffer Index relative to the Data Buffer Queue Base Index of the specified Buffer Header Identifier. Value Description 1..32 Amount of Data Buffer Words to write Buffer Data Words to write MIL-STD-1553 Reference Manual...
Page 178
Returning absolute Data Buffer Index Corresponding Data Buffer Address Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Buffer Index relative to the Data Buffer Queue Base Index of the specified Buffer Header Identifier. API_BUF_READ_FROM_LAST 0xffff Read from last Data Buffer Index that received data Value Description 1..32 Amount of Data Buffer Words to read Buffer Data Words to read MIL-STD-1553 Reference Manual...
Page 180
Corresponding Data Buffer Address to parameter ‘rid’ Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Buffer Index relative to the Data Buffer Queue Base Index of the specified Buffer Header Identifier. Value Description 1..32 Data Word position in Buffer to write Value Description 0..15 Bit position in Data Word Value Description 1..16 Amount of Bits to write MIL-STD-1553 Reference Manual...
Page 182
Chapter 5 – Buffer Functions Data Word to write Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Prototype: AiInt16 ApiCmdRamRead ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt8 len, AiUInt16 *ram_data ); Purpose: This function is no longer supported. Please use the functions ApiReadMemData and ApiReadBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
5.1.7 ApiCmdRamReadByte (obsolete) Prototype: AiInt16 ApiCmdRamReadByte ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt8 *val ); Purpose: This function is no longer supported. Please use the functions ApiReadMemData and ApiReadBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
32 Dataset Buffer Words to read Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
5.1.9 ApiCmdRamReadLWord (obsolete) Prototype: AiInt16 ApiCmdRamReadLWord ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt32 *val ); Purpose: This function is no longer supported. Please use the functions ApiReadMemData and ApiReadBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
5.1.10 ApiCmdRamReadWord (obsolete) Prototype: AiInt16 ApiCmdRamReadWord ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt16 *val ); Purpose: This function is no longer supported. Please use the functions ApiReadMemData and ApiReadBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
Prototype: AiInt16 ApiCmdRamWrite ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt8 len, AiUInt16 *ram_data ); Purpose: This function is no longer supported. Please use the functions ApiWriteMemData and ApiWriteBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
5.1.12 ApiCmdRamWriteByte (obsolete) Prototype: AiInt16 ApiCmdRamWriteByte ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt8 val ); Purpose: This function is no longer supported. Please use the functions ApiWriteMemData and ApiWriteBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
32 Dataset Buffer Words to write Output Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
5.1.14 ApiCmdRamWriteLWord (obsolete) Prototype: AiInt16 ApiCmdRamWriteLWord ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt32 val ); Purpose: This function is no longer supported. Please use the functions ApiWriteMemData and ApiWriteBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
5.1.15 ApiCmdRamWriteWord (obsolete) Prototype: AiInt16 ApiCmdRamWriteWord ( AiUInt32 ul_ModuleHandle, AiUInt32 addr, AiUInt16 val ); Purpose: This function is no longer supported. Please use the functions ApiWriteMemData and ApiWriteBlockMemData instead. This function will be removed in future BSP versions. MIL-STD-1553 Reference Manual...
Purpose: This function is used to read a data block from AIM board memory in avoidance of AIM board command and acknowledge interface access. This is necessary to access the board memories in case of interrupt. The function does a direct access to the AIM board memory at the specified offset address .
Page 194
Amount of bytes actually read. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Purpose: This function is used to read a byte/word/longword data value from AIM board memory in avoidance of AIM board command and acknowledge interface access. This is necessary to access the board memories in case of interrupt. The function does a direct access to the AIM board memory at the specified offset address .
Page 196
Chapter 5 – Buffer Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Purpose: This function is used to write a data block to AIM board memory in avoidance of AIM board command and acknowledge interface access. This is necessary to access the board memories in case of interrupt. The function does a direct access to the AIM board memory at the specified offset address .
Page 198
Chapter 5 – Buffer Functions Amount of bytes actually written. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Purpose: This function is used to write a data value to AIM board memory in avoidance of AIM board command and acknowledge interface access. This is necessary to access the board memories in case of interrupt. The function does a direct access to the AIM board memory at the specified offset address .
Page 200
Be sure to have allocated enough memory referenced by this pointer within the application! Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Links a BC transfer to a FIFO. The FIFO becomes the source of the BC message buffer data transmitted. ApiCmdRTSAAssignFifo Links an RT data transmission to a FIFO. The FIFO becomes the source of the RT message buffer data transmitted. MIL-STD-1553 Reference Manual...
Note: See Section 1.3.5 for the range allowed for this parameter. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Number of Buffer’s in one FIFO 2..128 Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
0xFFFF Reload under run Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Amount of Data Word’s to reload Data to write Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Remote Terminal Address Value Description 1..30 RT Subaddress Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
BC for a specific RT ApiCmdBCStart Starts the execution of pre-defined BC transfers within minor/major frame structure and defines minor fame timing ApiCmdBCStatusRead Reads execution status of the BC ApiCmdBCXferCtrlFehler! Enables/Disables the BC Transfer Textmarke nicht definiert. MIL-STD-1553 Reference Manual...
Page 208
Defines all transfer properties including source/destination information, error insertion and interrupt generation ApiCmdBCXferDefErr Defines a transfer error injection on the fly. ApiCmdBCXferDescGet Get a transfer descriptor value ApiCmdBCXferDescMod Modify a transfer descriptor value ApiCmdBCXferRead Reads status of an individual BC transfer MIL-STD-1553 Reference Manual...
API_BC_INSTR_STROBE BC external Strobe Instruction If this instruction is executed, the BC trigger output of the board is pulsed. After this operation, the instruction execution continues with the following instruction. MIL-STD-1553 Reference Manual...
Page 210
Reserved Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
DAYS Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 DAYS HOURS Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 HOURS MINUTES MIL-STD-1553 Reference Manual...
Page 212
Value Description 0..999999 Microseconds of second Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 214
If an error occurred during a RT-BC or RT-RT transfer, the BC terminates the transfer with the error detection. Thus, the possible remainder of the transfer after the error will not be stored in the buffer. MIL-STD-1553 Reference Manual...
Page 215
Value Description 1..256 Amount of allocated contiguous Data Buffers 26-bit BC Buffer Header Address (Byte-Address) 26-bit BC Data Buffer Queue Base Pointer (Byte-Address) 26-bit BC Status Queue Base Pointer (Byte-Address) 26-bit BC Event Queue Base Pointer (Byte-Address) MIL-STD-1553 Reference Manual...
Page 216
Chapter 7 – Bus Controller Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt32 bq_addr; AiUInt32 sq_addr; AiUInt32 eq_addr; } TY_API_BC_BH_INFO; Value Description 0..2047 Assigned Data Buffer Identifier Status Queue Entry Identifier Event Queue Entry Identifier Value Description 1..256 Amount of allocated contiguous Data Buffers 26-bit BC Buffer Header Address (Byte-Address) MIL-STD-1553 Reference Manual...
Page 218
26-bit BC Event Queue Base Pointer (Byte-Address) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Disable Dynamic Data Generation API_ENA Enable Dynamic Data Generation BC Buffer Header ID Note: See Section 1.3.5 for the range allowed for this parameter. BC Dynamic Tagging Mode Value Constant Description API_DYTAG_STD_MODE Function Mode API_DYTAG_EFA_MODE Tagging Mode MIL-STD-1553 Reference Manual...
Page 220
Stepsize used to increment or decrement the dynamic Data Word 5, 6 Reserved ‘tag_fct’ Value Description 1..6 0..31 Word Position of the Data Buffer Word Parameter description for Tagging Mode (‘mode’ = 1) Applicable for up to 4 dynamic words ‘bc_dytag[0..3]’! Note: MIL-STD-1553 Reference Manual...
Page 221
Word Position of the dynamic Data Word Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Note: This instruction may be used to implement larger delays, if it is the only instruction within a minor frame (the delay time is then determined by the minor frame time). API_BC_INSTR_STROBE BC external Strobe Instruction MIL-STD-1553 Reference Manual...
Page 223
The maximum delay time is appr. 16ms 15..0 reserved Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt16 tag_fct; AiUInt16 min; AiUInt16 max; AiUInt16 step; AiUInt16 wpos; } TY_API_BC_DYTAG; Parameter description for Function Mode (‘mode’ = 0) Applicable for up to 2 dynamic words (‘bc_dytag[0..1]’, structure Note: indexes bc_dytag[2..3] are reserved! MIL-STD-1553 Reference Manual...
Page 225
The function is applied to the Function Word ‘min’ which is written to the Transfer Data Buffer. 6..0 API_DYTAG_FCT_DISABLE Disable API_DYTAG_FCT_SAWTOOTH_16 16-bit Sawtooth API_DYTAG_FCT_SAWTOOTH_8_LOW 8-bit Sawtooth in Data Bits 7..0 API_DYTAG_FCT_SAWTOOTH_8_HIGH 8-bit Sawtooth in Data Bits 15..8 MIL-STD-1553 Reference Manual...
Page 226
Word Position of the dynamic Data Word Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
1..64 Sequence of Minor Frame Identifiers Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
That means during this time, no instructions will be executed. After the delay time is expired, the instruction execution continues with the following instruction. Note: This instruction may be used to implement larger delays, if it is the only instruction within MIL-STD-1553 Reference Manual...
Page 229
The maximum delay time is appr. 16ms 15..0 reserved Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
The address of the buffer header of this transfer Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 232
Do not halt on exception API_BC_HLT_HALT_ON_XFER_ERR Reserved for Halt on Transfer Error API_BC_HLT_HALT_ON_STAT_EXCEPT Reserved for Halt on Status Word Exception API_BC_HLT_HALT_ON_ERR_EXCEPT Reserved for Halt on Transfer Error and Status Word Exception API_BC_HLT_HALT_ON_ANY_INT Halt on any Interrupt 5..7 Reserved MIL-STD-1553 Reference Manual...
Page 233
RT transfer type Status Word 1 represents the status response for the Transmit Command word) API_BC_RSP_NO_SW2_EXPECTED No Status Word 2 expected (RT-RT transfer type only, Note: for RT-RT transfer type Status Word 2 represents the status response for the Receive Command word) MIL-STD-1553 Reference Manual...
Page 234
Gap Mode is switched off for this transfer and a default Intermessage gap of app. 11s is generated. Note: The idle time of the physical bus is 2.0µs less than this time due to the gap measurement definition of MIL-STD-1553B. MIL-STD-1553 Reference Manual...
Page 235
Error in word ‘WPOS’ at bit ‘BPOS’ position with positive deviation in ‘contig’ Reserved API_ERR_TYPE_BUS_SWITCH Bus Switching Support The BIU disables the physical decoder device on the alternate bus, if the current transfer is in fast gap mode (RT-Validation Test 5.2.1.8) MIL-STD-1553 Reference Manual...
Page 236
125ns deviation 187.5ns deviation 156.25ns deviation 218.75ns deviation Note: Values 2 and 3 are not available for all AIM devices. Please check the chapter “Board functionality overview” and look for “Error Injection of High Resolution Zero Crossing Deviation”. Note: The resolution is: 1Mbit: 0.5µs per Half Bit...
Page 237
Chapter 7 – Bus Controller Functions All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Driver Command: API_BC_HALT (0x79) Purpose: This function is used to stop execution of BC Transfers on the AIM board. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.
API_BC_INI (0x70) Purpose: This function is used to initialize the Bus Controller mode of the AIM board. This must be the first BC function called. Defines the number of retries which shall be performed by the BC, if a transfer is erroneous.
Page 240
API_BC_XFER_BUS_PRIMARY Primary Bus API_BC_XFER_BUS_SECONDARY Secondary Bus Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
To start the BC operation / Transfer execution of the specified BC Instruction Table (tbl) function ApiCmdBCStart shall called with smod API_BC_START_INSTR_TABLE. Using parameters dest_cnt and dest_offset it is possible to write specific parts or entire ctbl to the Instruction list area of the Global memory. MIL-STD-1553 Reference Manual...
Page 242
/* Firmware Opcode */ AiUInt8 res; /* Reserved */ AiUInt32 par1; AiUInt32 par2; AiUInt32 laddr; /* Instruction Address for Label */ } TY_API_BC_FW_INSTR; Instruction Label (eg. For 228ehavior228on228ly of jump destination, start of a transfer sequence, etc ) MIL-STD-1553 Reference Manual...
Page 243
Global RAM, if RMFC is set to 1. To achieve an equidistant minor framing after a major frame change, please insert a change minor frame time instruction to re-synchronize the minor frame timing of the BC. MIL-STD-1553 Reference Manual...
Page 244
Decrement and Jump on zero, if Major Frame Counter (MFC register in Firmware) is not zero then instruction execution continues with the following instruction, if zero then jump to Instruction Table entry which is identified by <label>. MIL-STD-1553 Reference Manual...
Page 245
This parameter returns the instruction address for the label thus operates as output parameter. Converted instruction array (image) from BC Instruction Table (tbl). Each entry is stored as a 32-bit word, the format is according to the AIM 1553/3910 Firmware Specification.
Returning Line (entry number) where the label was found. (0 = first line) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
TY_API_MEM_INFO, refer to function ApiCmdSysMemLayout). Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
1..64 Sequence of Minor Frame Identifiers Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
1..512 Sequence of Minor Frame Identifiers Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Description Disable the functionality referenced with parameter ‘ul_BcMode’ API_DIS Enable the functionality referenced with parameter ‘ul_BcMode’ API_ENA ul_BcMode Value Description 1, 2 BC Transfer ID Note: See Section 1.3.5 for the range allowed for this parameter. Reserved MIL-STD-1553 Reference Manual...
Page 251
Chapter 7 – Bus Controller Functions 0 (reserved) 0 (reserved) None Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt16 uw_Padding2; AiUInt32 ul_Reserved1; AiUInt32 ul_Reserved2; AiUInt32 ul_Reserved3; } TY_API_BC_SRVW; Value Constant Description Send modecode “Last Vector Word” on API_SEND_SRVW_ON_SA0 RT sub address 0 API_SEND_SRVW_ON_SA31 Send modecode “Last Vector Word” on RT sub address 31 Reserved (0) MIL-STD-1553 Reference Manual...
Page 253
Reserved (0) Reserved (0) Reserved (0) None Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
ApiCmdBcXferDef was set to ‘API_BC_SRVW_ENABLE’. This value is for rare special cases. Last Vector Word received from the specified RT Amount of Service Requests issued by the specified RT Return Value MIL-STD-1553 Reference Manual...
Page 255
BC transfers which shall be used as ‘vector word driven’ transactions have to be marked with the ApiCmdBCXferDef command (refer to parameter ‘sxh’) accordingly. Only BC-RT and RT-BC transfer types can be defined to be ‘vector word driven transactions’. MIL-STD-1553 Reference Manual...
Continue BC operation (only applicable API_BC_START_CONTINUE_ON_BC_H with predefined BC Instruction Table, BC operation must be already started with API_BC_START_INSTR_TABLE) Note: Value 8 is not available on devices with a multi channel firmware. Please see chapter “Limitations for specific boards” for details. MIL-STD-1553 Reference Manual...
Page 257
Major Frame, then zero is returned. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
See Section 1.3.5 for the range allowed for this parameter Note: 'glb_msg_cnt' and Global BC Message Counter 'glb_err_cnt' are cleared on restart of the AIM board Bus Controller when the Global BC Error Counter ApiCmdBCStart' function is called. MIL-STD-1553 Reference Manual...
Page 259
ApiCmdBCStart with parameter ‘cnt’ > 0 ) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Enable BC Transfer (restore original BC Transfer type) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 262
Word Count / Mode code field for Command Word Transfer Interrupt Control Value Constant Description API_BC_TIC_NO_INT No Interrupt API_BC_TIC_INT_ON_XFER_END Interrupt on End of Transfer API_BC_TIC_INT_ON_XFER_ERR Interrupt on Transfer Error API_BC_TIC_INT_ON_STAT_EXCEPT Interrupt on Status Word Exception 4..7 API_BC_TIC_NO_INT Reserved MIL-STD-1553 Reference Manual...
Page 263
Word. Since such transfer is inserted after decoding of a previous Transmit Vector Word mode code ‘xid’ shall not be used in the ApiCmdBCFrameDef command Note: Values 2 and 3 are not applicable, when using the functions ApiCmdBCInstrTblIni, ApiCmdBCInstrTblGen and ApiCmdBCInstrTblGetAddrFromLabel!!! MIL-STD-1553 Reference Manual...
Page 264
The idle time of the physical bus is 2.0µs less than this time due to the gap measurement definition of MIL-STD-1553B. Note: The minimum Intermessage gap time achieved using the Standard Gap Mode is equal to the minimum gap time achieved in the Transfer Wait Time Mode. MIL-STD-1553 Reference Manual...
Page 265
Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 reserved (0) MERR INSTR SREQ Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 reserved (0) BRCV BUSY DBCA TERM MIL-STD-1553 Reference Manual...
Page 266
(RT-Validation Test 5.2.1.8) Note: The error type 9 (Bit Count High) is not supported together with Modecodes without data!!! Sync Field Error Half-Bit-Pattern (6 LS-Bits) (38hex = 111000 Sync Pattern) MIL-STD-1553 Reference Manual...
Page 267
125ns deviation 187.5ns deviation 156.25ns deviation 218.75ns deviation Note: Values 2 and 3 are not available for all AIM devices. Please check the chapter “Board functionality overview” and look for “Error Injection of High Resolution Zero Crossing Deviation”. Note: The resolution is: 1Mbit: 0.5µs per Half Bit...
Page 268
- err.config = 0 Thus, the BC inserts automatically a word count high error and the sync error is inserted at the additional word, which shall be appropriate set in the buffer, to generate the expected command word. MIL-STD-1553 Reference Manual...
Page 269
Chapter 7 – Bus Controller Functions Attention for transfers with 32 data words: Since the maximum buffer size for AIM boards is 32 words, the following data buffer id (relating to this transfer) has to be used to define the additional word.
See description of ApiCmdBCXferDef for a detailed description of supported error modes. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
See description of ApiCmdBCXferDescMod for supported values. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Command word 1 Command word 2 Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Entry Type to find Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 0 (reserved) STAT ‘ ’ ‘ ’ ‘ ‘ ’ ’ ‘ ’ ‘ ’ ‘ ’ ‘ ’ MIL-STD-1553 Reference Manual...
Page 274
Bit 2 Bit 1 Bit 0 0 (reserved) RBUS ERR_REPORT Buffer Status Value Constant Description API_BUF_NOT_USED Buffer not used API_BUF_FULL Buffer full API_BUF_EMPTY Buffer empty reserved Received Bus Flag Value Constant Description API_RCV_BUS_SECONDARY Secondary Bus API_RCV_BUS_PRIMARY Primary Bus MIL-STD-1553 Reference Manual...
Page 275
All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. ‘msg_cnt’, ‘err_cnt’, ‘lvw’ and ‘srvreq_cnt’ are cleared on restart of the AIM Note: board Bus Controller when the ApiCmdBCStart’ function is called.
Bit 2 Bit 1 Bit 0 0 (reserved) STAT ‘ ’ ‘ ’ ‘ ‘ ’ ’ ‘ ’ ‘ ’ ‘ ’ ‘ ’ BIU number, if board was opened with function ApiOpen(). Otherwise reserved (0). MIL-STD-1553 Reference Manual...
Page 277
Reserved (0) Number of Transfers executed Number of Transfer errors Last vector word that has been received This value is only available, if Service Request / Vector Word mechanism is enabled with the functions ApiCmdBCIni() and ApiCmdBCXferDef(). MIL-STD-1553 Reference Manual...
Page 278
Description API_RCV_BUS_SECONDARY Secondary Bus API_RCV_BUS_PRIMARY Primary Bus Error Report Field Value Constant Description API_BC_REPORT_NO_ERR No error API_BC_REPORT_ERR_FRAME_COD Coding or Framing error API_BC_REPORT_ERR_SW1_NOT_RCV Status Word 1 not received API_BC_REPORT_ERR_SW2_NOT_RCV Status Word 2 not received 4..15 reserved Command Word MIL-STD-1553 Reference Manual...
Page 279
All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. ‘msg_cnt’, ‘err_cnt’, ‘lvw’ and ‘srvreq_cnt’ are cleared on restart of the AIM Note: board Bus Controller when the ApiCmdBCStart’ function is called.
Page 280
Chapter 7 – Bus Controller Functions THIS PAGE INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
ApiCmdRTSAMsgRead Reads the execution status for an RT SA/Mode code ApiCmdRTStart Starts the RT operation for all assigned RTs ApiCmdRTStatusRead Reads the execution status of the general RT operation and the RT global message and error counters MIL-STD-1553 Reference Manual...
RT Buffer Header ID. The RT Buffer Header specified should first be assigned to an RT Transfer using the function ApiCmdRTSACon. Buffer Header ID Note: See Section 1.3.5 for the range allowed for this parameter. Assigned Data Buffer Identifier MIL-STD-1553 Reference Manual...
Page 283
Discard error messages from the current Data Buffer API_BSM_RX_KEEP_CURRENT Keep error messages at the current Data Buffer For Transmit RT Operation the following options are valid: Value Constant Description API_BSM_TX_KEEP_SAME Keep the same Data Buffer at transfer error Reserved MIL-STD-1553 Reference Manual...
Page 284
If an error occurred during a RT- Receive transfer, the RT terminates the transfer with the error detection. Thus, the possible remainder of the transfer after the error will not be stored in the buffer. MIL-STD-1553 Reference Manual...
Page 285
Description 0..2047 Assigned Data Buffer Identifier Status Queue Entry Identifier Event Queue Entry Identifier Value Description 1..256 Amount of allocated contiguous Data Buffers 26-bit RT Buffer Header Address (Byte-Address) 26-bit RT Data Buffer Queue Base Pointer (Byte-Address) MIL-STD-1553 Reference Manual...
Page 286
26-bit RT Event Queue Base Pointer (Byte-Address) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Description 0..2047 Assigned Data Buffer Identifier Status Queue Entry Identifier Event Queue Entry Identifier Value Description 1..256 Amount of allocated contiguous Data Buffers 26-bit RT Buffer Header Address (Byte-Address) 26-bit RT Data Buffer Queue Base Pointer (Byte-Address) MIL-STD-1553 Reference Manual...
Page 288
26-bit RT Event Queue Base Pointer (Byte-Address) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Disable Dynamic Data Generation API_ENA Enable Dynamic Data Generation RT Buffer Header ID Note: See Section 1.3.5 for the range allowed for this parameter. RT Dynamic Data Generation Mode Value Constant Description API_DYTAG_STD_MODE Function Mode API_DYTAG_EFA_MODE Tagging Mode MIL-STD-1553 Reference Manual...
Page 290
Stepsize used to increment or decrement the dynamic Data Word 5, 6 Reserved ‘tag_fct’ Value Value 1..6 0..31 Word Position of the Data Buffer Word Parameter description for Tagging Mode (‘mode’ = 1) Applicable for up to 4 dynamic words ‘bc_dytag[0..3]’! Note: MIL-STD-1553 Reference Manual...
Page 291
Word Position of the dynamic Data Word Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Disable RT API_DIS Enable RT API_ENA Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt16 tag_fct; AiUInt16 min; AiUInt16 max; AiUInt16 step; AiUInt16 wpos; } TY_API_RT_DYTAG; Parameter description for Function Mode (‘mode’ = 0) Applicable for up to 2 dynamic words (‘bc_dytag[0..1]’, structure Note: indexes bc_dytag[2..3] are reserved! MIL-STD-1553 Reference Manual...
Page 294
6..0 API_DYTAG_FCT_DISABLE Disable API_DYTAG_FCT_SAWTOOTH_16 16-bit Sawtooth API_DYTAG_FCT_SAWTOOTH_8_LOW 8-bit Sawtooth in Data Bits 7..0 API_DYTAG_FCT_SAWTOOTH_8_HIGH 8-bit Sawtooth in Data Bits 15..8 Value Value 0..n Initial value of dynamic Function Word Only applicable if ‘tag_fct’-Bit 7 = 1! Note: MIL-STD-1553 Reference Manual...
Page 295
Word Position of the dynamic Data Word Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Subaddress Type Value Constant Description API_RT_TYPE_RECEIVE_SA Receive Subaddress API_RT_TYPE_TRANSMIT_SA Transmit Subaddress API_RT_TYPE_RECEIVE_MODECODE Receive Mode code API_RT_TYPE_TRANSMIT_MODECODE Transmit Mode code The buffer header index of this RT/SA combination The address of the buffer header of this RT/SA combination MIL-STD-1553 Reference Manual...
Page 297
Chapter 8 – Remote Terminal Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 299
Gap Error Half Bits (0.5µs per Half Bit) Zero Crossing Error 125ns deviation 187.5ns deviation 156.25ns deviation 218.75ns deviation Note: Values 2 and 3 are not available for all AIM devices. Please check the chapter “Board functionality overview” look “Error Injection of High Resolution Zero Crossing Deviation”.
Page 300
Amount of Bit Count Error Bits Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 302
STAT STAT STAT STAT STAT Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 STAT STAT STAT STAT STAT STAT STAT STAT Value Description RX Modecode disabled RX Modecode enabled MIL-STD-1553 Reference Manual...
Page 303
STAT STAT STAT Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 STAT STAT STAT STAT STAT STAT STAT STAT Value Description TX Message ID disabled TX Message ID enabled MIL-STD-1553 Reference Manual...
Page 304
HS Modecode disabled HS Modecode enabled Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Subaddress and buffer initialization for the selected RT API_RT_SA_USAGE_UPDATE Update transmit buffer Value Description 0..31 Remote Terminal Address Remote Terminal Operation Control Value Constant Description API_DIS Disable RT Operation API_ENA Enable RT Simulation Value Description 1..30 RT Subaddress MIL-STD-1553 Reference Manual...
Page 306
Description 1..2047 Assigned Data Buffer Identifier Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This command is used to stop the Remote Terminal operation for all assigned RTs. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
If a “No Response” condition occurs due to the bus respond control, Note: the current RT will discard the transfer without any operation. Value Description 4..63.75 Remote Terminal Response Time Value (Range: 4..63.72µs in steps of 0.25µs MIL-STD-1553 Reference Manual...
Page 309
BC Command. See Figure 9-1. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
RT Last Command Word – See Figure 9-2. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
RT Last Status Word – See Figure 9-1. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Remote Terminal Address that is affected 0xFFFFFFFF Affect all RTs 0..31 Remote Terminal Address that is affected ul_RtMode Value Description Reserved API_RT_RSP_BOTH_BUSSES Respond to both busses API_RT_RSP_PRI_BUS Respond only to bus A API_RT_RSP_SEC_BUS Respond only to bus B MIL-STD-1553 Reference Manual...
Page 313
Chapter 8 – Remote Terminal Functions 0 (reserved) None Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Note: msg_cnt and err_cnt are Last Command Word received – See Figure 9-2. cleared on restart of the AIM board Remote Terminals when the Number of messages transferred – ApiCmdRTStart' function is called. Number of message errors detected . MIL-STD-1553 Reference Manual...
Page 315
Chapter 8 – Remote Terminal Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiInt16 ApiCmdRTMsgReadAll ( AiUInt32 ul_ModuleHandle, AiUInt8 biu, TY_API_RT_MSG_ALL_DSP *pall_dsp ); Driver Command: API_RT_MSG_READ_ALL (0x9E) Purpose: This function is used to read the Transfer-/Error counter values of all Remote Terminals on the AIM board. Entire RT Status information typedef struct ty_api_rt_msg_all_dsp_rt AiUInt32 rt_msg; AiUInt32 rt_err; }TY_API_RT_MSG_ALL_DSP_RT;...
Next RT 1553 Status Word – See Figure 9-1. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
2µs can be achieved in 1 Mbit Transmission Mode (min. 4µs Response Time). Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Remote Terminal Address Response Time in µs. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
0..31 Mode code Number Buffer Header ID Note: See Section 1.3.5 for the range allowed for this parameter. Subaddress Type Value Constant Description API_RT_TYPE_RECEIVE_SA Receive Subaddress API_RT_TYPE_TRANSMIT_SA Transmit Subaddress API_RT_TYPE_RECEIVE_MODECODE Receive Mode code API_RT_TYPE_TRANSMIT_MODECODE Transmit Mode code MIL-STD-1553 Reference Manual...
Page 321
See Figure 9-1 for the Status word format. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 323
Gap Error Half Bits (0.5µs per Half Bit) Zero Crossing Error 125ns deviation 187.5ns deviation 156.25ns deviation 218.75ns deviation Note: Values 2 and 3 are not available for all AIM devices. Please check the chapter “Board functionality overview” look “Error Injection of High Resolution Zero Crossing Deviation”.
Page 324
Amount of Bit Count Error Bits Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
TY_API_RT_SA_MSG_DSP *psa_dsp ); Driver Command: API_RT_SA_MSG_READ (0x9C) Purpose: This function is used to read the execution status of the specified RT Subaddress/Mode code of the selected AIM board Remote Terminal (identified by its RT Address). Value Description 0..31 Remote Terminal Address...
Page 326
Error Report Field Value Constant Description API_RT_REPORT_NO_ERR No error API_RT_REPORT_ERR_FRAME_COD Coding or Framing error API_RT_REPORT_ERR_RSP_TIMEOUT Response Timeout error Last Status Word – See Figure 9-1. Last Command Word – See Figure 9-2. Current Data Buffer Pointer (Byte-Address) MIL-STD-1553 Reference Manual...
Page 327
Value Description 0..999999 Microseconds of second Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
TG_API_RT_STATUS_READ(0x9A) Purpose: This function is used to read the execution status of the specified RT Subaddress/Mode code of the selected AIM board Remote Terminal (identified by its RT Address), including status queue information RT Status input information typedef struct ty_api_rt_sa_msg_read_in AiUInt32 ul_RtAddr ;...
Page 329
Indicates the data buffer queue size set with ApiCmdRTBHDef(). This queue size also indicates how many status queue entries are valid Actual Buffer/Status Queue Identifier of the transfer that is currently processed Reserved (0) Number of Transfers executed Number of Transfer errors Reserved (0) Reserved (0) Reserved (0) MIL-STD-1553 Reference Manual...
Page 330
Bit 16 reserved Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 STATUS_WORD Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 STATUS_WORD MIL-STD-1553 Reference Manual...
Page 331
Bit 1 Bit 0 MICROSEC_OF_SEC (0..999999) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This command is used to start the Remote Terminal operation for all assigned RTs. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Global RT Message Counter Global RT Error Counter Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 334
Chapter 8 – Remote Terminal Functions THIS PAGE INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
ApiCmdBMTCIIni Defines the next Trigger Control Block to be evaluated for the next trigger ApiCmdBMTIWIni Arms the BM with the Triggers to be evaluated ApiCmdDataQueueOpen Creates a Data Queue on the ASP ApiCmdDataQueueClose Closes the Data Queue MIL-STD-1553 Reference Manual...
Page 336
Allocate a list of buffers to receive APE MIL-Scope data. ApiFreeScopeBuffer Free a buffer scope data buffer. ApiProvideScopeBuffers Provide a list of scope buffers to the system driver. ApiWaitForScopeFinished Block the current execution thread until the data is available. MIL-STD-1553 Reference Manual...
Starting with the entry number 0 only active RT Subaddress/Mode codes are reported. In the last active entry number+1, ‘fnd’ is set to zero. Note that activity is recorded by the AIM board whenever the Bus Monitor is enabled, independent from the occurrence of the trigger event.
Page 338
IWGAP ISYNC LBIT HBIT MANCH NRESP Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Continuous Capturing (Recording). In Recording Mode the Buffer Full Interrupt is enabled, so that every time the AIM board Bus Monitor has captured a certain amount of data an interrupt is asserted (Half Buffer Full Interrupt).
Page 340
Number of messages stored after each Trigger Start event in Capture Only mode (cap_mode = 1). 0 (Reserved) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt16 uc_DytagStep; } TY_API_BM_DYTAG_MON_DEF; Value Description 1..64 Dytag Monitor Identifier Dytag Monitor Control Value Constant Description API_DIS Disable Dytag Monitor API_ENA Enable Dytag Monitor Value Description 0..31 Remote Terminal Address Value Description 1..30 RT Subaddress 0..31 Modecode MIL-STD-1553 Reference Manual...
Page 342
0 (Reserved) 0 (Reserved) 0 (Reserved) none Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt32 uc_Id; } TY_API_BM_DYTAG_MON_READ_CTRL; Value Description 1..64 Dytag Monitor Identifier BM Dytag Monitor Activity information typedef struct ty_api_bm_dytag_mon_act AiUInt32 ul_Stale; AiUInt32 ul_Bad; AiUInt32 ul_Good; } TY_API_BM_DYTAG_MON_ACT; Stale Dytag Counter (32-bit) Bad Dytag Counter (32-bit) Good Dytag Counter (32-bit) MIL-STD-1553 Reference Manual...
Page 344
Chapter 9 – Bus Monitor Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Message Capture Enable / Filter bits for RT Transmit Mode codes Bit31...0 correspond to MC31...MC0. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Start Trigger Mask pattern Start Trigger Compare pattern Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Driver Command: API_BM_HALT (0xB8) Purpose: This command is used to stop the AIM board Chronological Bus Monitor operation. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.
Illegalize bits for RT Transmit Mode codes Bit31...0 correspond to MC31...MC0. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Driver Command: API_BM_INI (0xB0) Purpose: This function is used to initialize the chronological Bus Monitor of the AIM board. Execution of this function will: (1) Enable the capturing of all RT Transmit and Receive Subaddresses and Mode codes. (This can later be modified using the ApiCmdBMFilterIni function.)
BM Message Filter Recording setup structure typedef struct ty_api_bm_ini_msg_flt_rec AiUInt16 cw; AiUInt8 pos1; AiUInt8 pos2; } TY_API_BM_INI_MSG_FLT_REC; Filter Command Word (MS-Byte first) Value Description First Data Word position in message ‘cw’ 1..Word Count Field of CW If Word Count Field is 0 MIL-STD-1553 Reference Manual...
Page 351
Be sure that pos1 <= pos2! Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt8 smod, AiUInt8 res ); Driver Command: API_BM_INI_INTR (0xB1) Purpose: This function is used to enable/disable the Interrupts and Output Strobes related to the Bus Monitor mode of the AIM board. Interrupt Mode Value Constant Description API_BM_MODE_NO_INT No interrupt API_BM_MODE_HFI_INT...
Format 3 API_BM_MSG_FLT_FORMAT_4 Format 4 Size of the allocated buffer in Words Number of messages to read ‘con’ Value Description 0..2 Read all messages Read ‘max_msg’ messages >0 Pointer to application buffer area (used to store recording data) MIL-STD-1553 Reference Manual...
Page 354
Message Filter Recording starts with the Monitor Trigger message. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Format 3 - Same as Format 2. To be used when not in Message Filter Recording mode. The basic structure of all for formats includes a Message Header and Message Data: Message Header Message Data Next Message Header Next Message Data The specific content for each Format is defined in the following sections. MIL-STD-1553 Reference Manual...
Illegal command word Bit10 to Bit0 from Status Word of MILbus Value Description 1..32 Amount of Data Words following the Message Header – – – – Value Description 0..999 Message Time in micro-seconds Message Data (LS-Byte always first) MIL-STD-1553 Reference Manual...
GERR Global Error PERR Parity Error TBUSY Terminal Busy Value Description 1..32 Amount of Data Words following the Message Header – – – – Value Description 0..999 Message Time in micro-seconds – – Message Data (LS-Byte always first) MIL-STD-1553 Reference Manual...
Message error bit set API_BM_MSG_ERR_SW_EXCEPT Status word exception error API_BM_MSG_ERR_HCNT High wordcount error API_BM_MSG_ERR_LCNT Low wordcount error API_BM_MSG_ERR_ILLEGL Illegal command word Value Description Primary Bus Secondary Bus – – Value Description 1..32 Amount of Data Words following the Message Header MIL-STD-1553 Reference Manual...
BM data while in either the Standard Capture mode, Selective Capture Mode or Recording Mode. Format 3 output is to be used when not in Message Filter Recording mode (ApiCmdBMCapMode ‘cap_mode’ not equal to 3 (API_BM_CAPMODE_FILTER)) addition the ApiCmdBMIniMsgFltRec should not be used. MIL-STD-1553 Reference Manual...
Message error bit set API_BM_MSG_ERR_SW_EXCEPT Status word exception error API_BM_MSG_ERR_HCNT High wordcount error API_BM_MSG_ERR_LCNT Low wordcount error API_BM_MSG_ERR_ILLEGL Illegal command word Value Description Primary Bus Secondary Bus Value Description 1..32 Amount of Data Words following the Message Header MIL-STD-1553 Reference Manual...
Page 361
Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 STATUS_WORD Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 STATUS_WORD For RTRT transfers this reflects the transmit RT status word MIL-STD-1553 Reference Manual...
Page 362
Bit 9 Bit 8 STATUS_WORD Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 STATUS_WORD For RTRT transfers this reflects the receive RT status word Message Data (LS-Byte always first) MIL-STD-1553 Reference Manual...
Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 ALTER LCNT HCNT STAT TADDR ILLEGL Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 IWGAP ISYNC LBIT HBIT MANCH NRESP MIL-STD-1553 Reference Manual...
Page 364
Chapter 9 – Bus Monitor Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Page 366
IWGAP ISYNC LBIT HBIT MANCH NRESP Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Value Constant Description API_BM_SIGN_POS Positive entry offset (ptype=0 and ptype=1) API_BM_SIGN_NEG Negative entry offset (ptype=1 and ptype=2) Number of entries (353ehavior or negative offset) Value Description 0..20000h Number of entries relative to the selected Buffer Pointer Read Mode MIL-STD-1553 Reference Manual...
Page 368
Defines which bits are relevant for the search operation. BM Entry Find information typedef struct ty_api_bm_stack_fnd AiUInt8 efnd; AiUInt8 padding1; AiUInt16 padding2; AiUInt32 eptr; AiUInt32 entry; } TY_API_BM_STACK_FND; Value Constant Description API_BM_ENTRY_NOT_FOUND Entry not found API_BM_ENTRY_FOUND Entry found 0 (reserved) 0 (reserved) MIL-STD-1553 Reference Manual...
Page 369
For efnd = 1: Monitor Buffer Entry as described for ApiCmdBMStackEntryRead’ Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Pointer Read Mode (where m is the bus monitor size / 4) 0..n Long word address offset to read from, relative to the start of the monitor memory area BM Stack Entry Data typedef struct ty_api_bm_stack_dsp AiUInt32 entry; } TY_API_BM_STACK_DSP; MIL-STD-1553 Reference Manual...
Page 371
Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 ALTER LCNT HCNT STAT TADDR ILLEGL Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 IWGAP ISYNC LBIT HBIT MANCH NRESP MIL-STD-1553 Reference Manual...
Page 372
Bit 1 Bit 0 BUS_WORD µ µ Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Monitor Buffer End Address Note: If Etp > Monitor Buffer End Address, then the Monitor Buffer Fill Pointer of the AIM board Bus Monitor wraps around to the Monitor Buffer Start Address. MIL-STD-1553 Reference Manual...
Driver Command: API_BM_START (0xB7) Purpose: This command is used to start the AIM board Chronological Bus Monitor operation. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.
AiInt16 ApiCmdBMStatusRead ( AiUInt32 ul_ModuleHandle, AiUInt8 biu, TY_API_BM_STATUS_DSP *pdsp ); Driver Command: API_BM_STATUS_READ (0xB9) Purpose: This command is used to read the current execution status of the AIM board Chronological Bus Monitor. BM Status information typedef struct ty_api_bm_status_dsp AiUInt8 men;...
Page 377
‘glb_err_cnt’ except that the the count is restricted to the secondary bus traffic. Global BM Error Counter (Primary Bus) The Global BM Error Counter returns the same information than the parameter ‘glb_err_cnt’ except that the the count is restricted to the primary bus traffic. MIL-STD-1553 Reference Manual...
Page 378
API_OK the function ApiGetErrorDescription can be used to obtain an error description. Note: All count parameters and bus load parameters are cleared on restart of the AIM board Bus Monitor when the ApiCmdBMStart’ function is called. MIL-STD-1553 Reference Manual...
All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. Note: As a default swxm is set to 0x07FF with the ApiCmdBMIni function. MIL-STD-1553 Reference Manual...
Value Constant Description API_BM_TRG_ERR_CONDITION Trigger on Error Condition (Static) API_BM_TRG_EXTERNAL_EVENT Trigger on External event (Static) API_BM_TRG_RECEIVED_WORD Trigger on Received Word (Dynamic) API_BM_TRG_DATA_VALUE Trigger on Data Value (Dynamic) API_BM_TRG_HS_EVENT Trigger on High Speed Event (only valid for STANAG3910 boards) MIL-STD-1553 Reference Manual...
Page 381
Next Trigger Control Block Index if trigger condition becomes true for this Trigger Control Block. ‘tt’ Value Description 0xFF disabled for Static Trigger 0xFF disabled for Static Trigger 0..254 Sequence Trigger 0/1 modified do not modify Sequence Trigger 0/1 0..254 Sequence Trigger 0/1 modified do not modify Sequence Trigger 0/1 MIL-STD-1553 Reference Manual...
Page 382
‘tt’ Value Description Used to define which bits of the received data/Command/Status Word are relevant for the Trigger condition check Used to define which bits of the received Data Word are relevant for the Trigger condition check MIL-STD-1553 Reference Manual...
Page 383
Specifies the lower limit value of the range to be checked Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Description API_RT_TYPE_RECEIVE_SA Receive Subaddress API_RT_TYPE_TRANSMIT_SA Transmit Subaddress API_RT_TYPE_RECEIVE_MODECODE Receive Mode code API_RT_TYPE_TRANSMIT_MODECODE Transmit Mode code Time Tag Mode Value Constant Description API_BM_TTMODE_LOW_HIGH Store Low and High Timetag 0 (Reserved for Trigger Block Function) Trigger Control Block Index MIL-STD-1553 Reference Manual...
Page 385
Chapter 9 – Bus Monitor Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Sequence Trigger 0 Control Block Index (= dynamic Trigger) Value Constant Description API_DIS Disable >0 Trigger Control Block Index Sequence Trigger 1 Control Block Index (= dynamic Trigger) Value Constant Description API_DIS Disable >0 Trigger Control Block Index MIL-STD-1553 Reference Manual...
Page 387
Chapter 9 – Bus Monitor Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
See description of the parameter px_Queue->uc_Id in the function ApiCmdDataQueueOpen. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Note: All stored data within the data queue will be lost! Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Generic Data Queue for ASP data. APX and ACX cards only. API_DATA_QUEUE_ID_MIL_SCOPE MILScope Recording Queue. APX and ACX cards with MILScope only. API_DATA_QUEUE_ID_BM_REC_BIU5 BIU 5 recording API_DATA_QUEUE_ID_BM_REC_BIU6 BIU 6 recording API_DATA_QUEUE_ID_BM_REC_BIU7 BIU 7 recording API_DATA_QUEUE_ID_BM_REC_BIU8 BIU 8 recording MIL-STD-1553 Reference Manual...
Page 391
Note: The filename may also specify a Named Pipe, which has to be created by the application in advance. Note: Named pipes cannot be set for local AND remote at the same time! API_DATA_QUEUE_BUFTYPE_HANDLE Reserved > > 0 (reserved) MIL-STD-1553 Reference Manual...
Page 392
> QueueId Value Description 0..11, 64..n Number of kBytes reserved on the AIM 13 ..24 board (in Local RAM) for the data queue API_SCOPE_QUEUE_SIZE For Milscope the queue size is fixed 96kb Note: For proper use, it is recommended to set the data queue size to at least 4096 (4 MB) for the BIU2 queue on 3910 boards! >...
Amount of bytes to be read from the data queue A value of 0 in ‘ul_BytesToRead’ can be used to read the data queue Note: status ! Pointer to the TY_API_DATA_QUEUE_READ structure typedef struct ty_api_data_queue_status AiUInt32 ul_Status; MIL-STD-1553 Reference Manual...
Page 394
High-part of the 64bit amount of bytes that is currently stored in the data queue > > Low-part of the 64bit amount of bytes that has been read from the data queue since it was created. > > MIL-STD-1553 Reference Manual...
Page 395
High-part of the 64bit amount of bytes that has been read from the data queue since it was created. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function is used to flush all 1553 messages from the indicated queue while in the Record with Queuing mode. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function is used to stop the queueing of 1553 messages while in the Record with Queuing mode. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Monitor Buffer is not allowed in the Record with Queuing mode. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
AiUInt32 ttag; } TY_API_QUEUE_BUF; Value Description 0..31 Remote Terminal Address (Receive RT for RT-RT transfers) Value Description 1..30 RT Subaddress (SA of Receive RT in RT-RT transfers) 0..31 Mode code (MC of Receive RT in RT-RT transfers) MIL-STD-1553 Reference Manual...
Page 400
Interword gap error API_BM_MSG_ERR_BOTH_CHN Transmission on both MILbus channels API_BM_MSG_ERR_MODECODE Reserved mode code error API_BM_MSG_ERR_EARLY_RESP Early response or gap too short API_BM_MSG_ERR_BIT_SET Message error bit set in status word (e.g. on RT address mismatch) API_BM_MSG_ERR_SW_EXCEPT Status word exception error MIL-STD-1553 Reference Manual...
Page 401
Bit 0 MICROSECONDS_OF_SECOND (0..999999) Return Value This function returns API_Ok or API_ERR_QUEUE_EMPTY if no error occurred. If the return value is not equal to API_OK or API_ERR_QUEUE_EMPTY the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This function is used to start the queueing of 1553 messages from the stream of 1553 traffic. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Driver Command: TG_API_SCOPE_SETUP (0xF7) Purpose: Note: This function is only usable with AIM’s MIL-Scope module. This function is used to setup and initialize the MIL-Scope. There are two ADC channels available onboard. Both ADCs can be programmed separately. After calling this function with a different coupling than before, the application has to wait about 10 milli seconds for the Relais to settle before starting the scope.
Packages in one buffer are consecutively numbered with IDs from 0 to n. Equally, all samples in one buffer are consecutively numbered with IDs from 0 to n. This is the sample layout in one of these sample packages, where samples are sorted chronologically from ID 0 to 2: MIL-STD-1553 Reference Manual...
Page 405
Pointer to the list of TY_API_SCOPE_SETUP structure elements typedef struct ty_api_scope_setup AiUInt32 ul_CouplingPri; AiUInt32 ul_CouplingSec; AiUInt32 ul_SamplingRate; AiUInt32 ul_CaptureMode; AiUInt32 ul_OperationMode; AiUInt32 ul_SingleShotBuf; } TY_API_SCOPE_SETUP; > > Coupling mode of the primary ADC channel ( MilScope PBI 1.x and PBI 2.x ) MIL-STD-1553 Reference Manual...
Page 406
(e.g. 255 = every 256 sample will be stored) > > Capture Mode This parameter defines the capture mode of the MILScope. The MILScope is actually started and stopped with the function ApiCmdDataQueueControl(), ApiCmdScopeStart() on APE cards respectively. Value Constant Description MIL-STD-1553 Reference Manual...
Page 407
100 MHz mode on channel B > > Reserved (0) Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Purpose: This function is used to start APE milscope. Note: This function is only usable with AIM’s APE MIL-Scope module. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.
Purpose: This function returns the current statue of the APE-MIL-Scope. The function of not yet filled buffers is returned as well. Note: This function is only usable with AIM’s APE MIL-Scope module. Current MIL-Scope status. Enum Value Description SCOPE_STATUS_WAIT_FOR_TRIGGER...
This function is used to stop the APE MIL-Scope and the MIL-Scope thread. This function should be called when the MIL-Scope is no longer used. Note: This function is only usable with AIM’s APE MIL-Scope module. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.
Purpose: This function is used to reset all APE-MIL-Scope settings to the default state. Note: This function is only usable with AIM’s APE MIL-Scope module. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.
Purpose: This function is used to define a trigger condition for the APX, ACX MIL-Scope. Note: This function is only usable with AIM’s APX, ACX MIL-Scope module. Note: Every 3 valid sample is checked for the trigger condition. This means, that...
Page 413
The time resolution is calculated from the sampling rate, which is setup with parameter px_ScopeSetup->ul_SamplingRate in the function ApiCmdScopeSetup(). Value Description 0..262143 Delay Time in steps of 1µs > > Trace Before Trigger This value defines the time the data is captured before a trigger occurres. Ul_TrgDelay Value Description MIL-STD-1553 Reference Manual...
Page 414
Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
TY_API_SCOPE_TRG_EX * px_ScopeTrg ); Purpose: This function is used to define a trigger condition for the APX, ACX, APE MIL- Scope. Note: This function is only usable with AIM’s APX, ACX, APE MIL-Scope module. typedef struct ty_api_scope_trg AiUInt32 ul_TrgMode; AiUInt32 ul_TrgSrc;...
Page 416
Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 reserved (0) Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 reserved (0) DIS_FDBT 0: The Trigger is enabled immediately MIL-STD-1553 Reference Manual...
Page 417
MILScope modules this value must be set to zero. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Scope. The coupling of channel A and B must be set to internal. It is not allowed to have any BC or RT simulation running during the calibration process. The AIM board must be physically disconnected from the external bus.
Page 419
The offset which will be added to all channel B values if 100 MHz sampling mode is used on secondary channel. Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Note: This function is only usable with AIM’s APE MIL-Scope module. Note: The hardware needs to be set into a defined state before this function to determine the offset compensation is run.
Page 421
The offset which will be added to all channel A values when scope is used in mode API_SCOPE_COUPLING_EXTERN and 30V measurement range. > > The offset which will be added to all channel B values when scope is used in mode API_SCOPE_COUPLING_EXTERN and 30V measurement range. MIL-STD-1553 Reference Manual...
Page 422
Chapter 9 – Bus Monitor Functions Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
MILScope setup. Before this function is called the function ApiCmdScopeSetup must be called. Note: This function is only usable with AIM’s APE MIL-Scope module. User-definable ID of the buffer. The MIL channel the buffer is determined for.
ApiCmdScopeSetup must be called. Note: This function is only usable with AIM’s APE MIL-Scope module. Number of scope buffers to create for the list. In single channel mode, this has to be a multiple of 2, while in dual channel mode this has to be a multiple of 4.
ApiProvideScopeBuffers. Also, if the buffer has been provided before, it has to be completed or canceled by calling ApiCmdScopeStop. Note: This function is only usable with AIM’s APE MIL-Scope module. A pointer to the scope buffer to free. Return Value All API functions return API_OK if no error occurred.
The handler calls are automatically searialized on board level so that only one handler is called at a time. Note: This function is only usable with AIM’s APE MIL-Scope module. Number of buffers in the array paxBuffers.
Page 427
Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description.. MIL-STD-1553 Reference Manual...
TY_API_SCOPE_WAIT_STATE* pWaitResultFlags); Purpose: In single shot mode this function blocks the current execution thread until all the buffers are filled or the specified timeout occurred. Note: This function is only usable with AIM’s APE MIL-Scope module. Time-out in milliseconds. Value Description Infinite blocking Function returns at once.
ApiCmdReplayStart Starts the Replay of data in the Replay buffer ApiCmdReplayStop Stops the Replay of data in the Replay buffer ApiCmdReplayStatus Reads the status of the Replay activity ApiCmdReplayRT Disables replay of one or more specific RT(s) MIL-STD-1553 Reference Manual...
This flag has no function if the parameter “alt” is set to 1, which Note: implicitly sets the “rlt” to 1. If set to 1, the replay file must contain the full IRIG time tag. These entries are performed from the monitor in tag mode 0 only. MIL-STD-1553 Reference Manual...
Page 431
0 (Reserved) Replay file size in Bytes Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
Enable RT for Replay ‘mode’ Value Description 0..31 Return Value All API functions return API_OK if no error occurred. If the return value is not equal to API_OK the function ApiGetErrorDescription can be used to obtain an error description. MIL-STD-1553 Reference Manual...
This command is used to start the AIM board Replay operation. Note: When using an AIM 3910 board, the HS replay mechanism will also be started, if it was initialized with the corresponding HS replay initializing command (only available for AIM 3910 boards).
Buffer Transmitted Interrupt occurs) When the rpi_cnt value is incremented new Replay datas should be reloaded to the Shared RAM and should be copied from the Shared RAM to the Global RAM of the AIM board area using the library function ApiWriteRepData’.
Page 435
Chapter 10 – Replay Functions Start Address of the AIM board Replay buffer in the Global RAM area to copy the replay buffer entries from the Shared RAM area to the Global RAM area of the AIM board. - (not used) Initial value calculated from the file size (refer to ApiCmdReplayIni, parameter ‘fsize’) and...
This command is used to stop the AIM board Replay operation. Note: When using an AIM 3910 board, the HS replay mechanism will also be stopped, if it was started with the ApiReplayStart function. This is to avoid synchronization problems between LS and HS replay! Return Value All API functions return API_OK if no error occurred.
Write data to output channel of IO module ApiCmdGenIoOutChnRead Read data from output channel of IO module ApiCmdGenIoInChnRead Read data from input channel of IO module ApiCmdGenIoSysSTaskCtrl Enable /Disable Sampling Task ApiCmdGenIoTestSeq Handle sequences of discrete signal changes MIL-STD-1553 Reference Manual...
Setup HW access address for Input channel type in ‘addr’ Setup HW access address for Output channel type in ‘addr’ Init HW with value defined in parameter ‘addr’ Channel / IO Model selection For ‘BoardType’= Value Description API_GEN_IO_INIT_TYPE (n/a) API_GEN_IO_APX_TYPE APX Onboard Discrete model Reserved MIL-STD-1553 Reference Manual...
Page 439
Init value to be used for IO initialization For ‘BoardType’ = Value Description API_GEN_IO_APX_TYPE 0x0F Program APX Discretes to Input or Output Bits 7..4 = Inputs, Bits 3..0 = Output API_GEN_IO_DIG_TYPE 0x0000 Output Init value (set all Output Discretes) Return Value MIL-STD-1553 Reference Manual...
‘chn’ Value/ Description Range write all discrete output channels at once write inverted ‘val’ to all output channels write ‘val’ to the selected output channel (set/reset bit) 1..32 toggle the selected output channel for ‘res’ msec 1..1000 MIL-STD-1553 Reference Manual...
Page 441
Output data value Init value to be used for IO initialization For ‘genio_type’ = 1 ‘chn’ Value/Range Description 0x00000000 32-bit value (set all discrete channels) 0xFFFFFFFF 1..32 0 / 1 reset bit / set bit Return Value MIL-STD-1553 Reference Manual...
Description API_GEN_IO_INIT_TYPE Init ASP Driver structures and IO access API_GEN_IO_APX_TYPE APX Discrete I/O type Channel selection For ‘BoardType’ = 1 Value Description Read all discrete output channels at once 1..32 read from single discrete output channel Reserved MIL-STD-1553 Reference Manual...
Page 443
Chapter 11 – General I/O Functions Read Input data value For ‘genio_type’ = 1 ‘chn’ Value/Range Description 0x00000000.. 32-bit register value 0xFFFFFFFF 1..32 0 / 1 Discrete input / bit value Return Value MIL-STD-1553 Reference Manual...
Description API_GEN_IO_INIT_TYPE Init ASP Driver structures and IO access API_GEN_IO_APX_TYPE APX Discrete I/O type Channel selection For ‘BoardType’ = 1 Value Description Read all discrete input channels at once 1..32 read from single discrete input channel Reserved MIL-STD-1553 Reference Manual...
Page 445
Chapter 11 – General I/O Functions Read Input data value For ‘genio_type’ = 1 ‘chn’ Value/Range Description 0x00000000.. 32-bit register value 0xFFFFFFFF 1..32 0 / 1 Discrete input / bit value Return Value MIL-STD-1553 Reference Manual...
‘rsync’ (can only be applied when Sampling Task been activated before ‘con’=API_ON ) For ‘BoardType’ = 1 Value Description Read all discrete input channels at once 1..32 read from single discrete input channel MIL-STD-1553 Reference Manual...
Page 447
2000 1000 ms 1 Hz Control of test functions: Only for BoardType = 1 and con = (API_ON+2) Value Description Enable Test signal (with pulse frequency = ‘rate’ / 2) 1..16 Disable Test signal Reserved. Return Value MIL-STD-1553 Reference Manual...
/* Timeline 0..10.000 in steps of ms */ AiUInt32 tm_ms[MAX_GENIO_TEST_SEQ_ARRAY_SIZE]; /* Identify IP slot number and Board Type, define required operation */ AiUInt32 genio_type_op[MAX_GENIO_TEST_SEQ_ARRAY_SIZE]; /* Define the toggle Bits (set to 1) */ AiUInt32 chn_val[MAX_GENIO_TEST_SEQ_ARRAY_SIZE]; } TY_API_GENIO_TEST_SEQ_ARRAY; typedef struct TY_API_GENIO_TEST_SEQ_ARRAY ax_Seq[4]; } TY_API_GENIO_TEST_SEQ_TBL; MIL-STD-1553 Reference Manual...
Page 449
Discrete Event, as defined by bits 8..11 Execute Acylcilc Transer as per address in ‘chn_val’ Sequence event If genio_type_op Bit31 = 0: Bits Value Description Modify Discrete Out bit(s) marked by ‘1’ 31..0 If genio_type_op Bit31 = 1: acyclic start address pointer MIL-STD-1553 Reference Manual...
Page 450
Chapter 11 – General I/O Functions Status of the four sequences Value Description Not yet started In progress Finished Return Value MIL-STD-1553 Reference Manual...
Error reporting design and result of error message on AIM BOARD performance Complete list of Driver Command Codes and the associated API S/W Library function call. Specific questions regarding troubleshooting the AIM API S/W Library should be directed to either our Customer Support on-line help at or one of the following www.aim-online.com...
Figure 12.1-3 Example “Error in function “ Error Message Once this type of error message is generated, the user should then return to the user’s program, locate the function call in question and correct the specified error. MIL-STD-1553 Reference Manual...
Page 453
Otherwise AIM support should be notified. If the ApiIo function verifies all parameters passed to it are valid and within range it then sets up command buffers to be sent to the Target S/W and calls the appropriate OS driver via the _ApiIo API S/W Library function.
After either of the two error messages as shown in Figures 12.1-4 and 12.1-5 are received, an error message routine will be called to interpret the error code and acknowledgment codes returned by the Target S/W. Another error message will immediately follow which is shown in MIL-STD-1553 Reference Manual...
ApiIo function, an error message “ERROR in function “ message as shown in Figure 12.1-2 will occur with ApiIo as the function name. Since the error code is reserved for Target S/W errors, it will be interpreted as (unknown) by the ApiIo function. MIL-STD-1553 Reference Manual...
The following error messages occurred when ApiCmdCalCplCon was issued after the Target module had been closed (ApiClose). Figure 12.1-7 Example Target S/W / Host API S/W Library Function Error Reporting D3h = Driver Command Code for ApiCmdCalCplCon MIL-STD-1553 Reference Manual...
s microseconds AIM Compact PCI I-Architecture Acknowledge addr address Additional Data Word (from the High Speed Status Frame) AIM Peripheral Component Interconnect Mezzanine (PCM) Card AIM Notebook Architecture AIM Network Server AIM PCI I-Architecture Application Program Interface Appendix ARINC...
Page 462
NetBIOS Network Basic Input/Output System No operation – indicates no executable code Physical Address MIL-STD-1553 Databus Analyzer Software for Windows Physical Bus Interface Personal Computer PC/AT Personal Computer/Advanced Technology Peripheral Component Interconnect Peripheral Component Interconnect Mezzanine Card...
Page 463
Chapter 13 - Notes status word mask TATC Trace After Trigger Counter Trigger Control Block UINT unsigned integer Versa Module Eurocard Virtual Device Driver Vmebus Extensions for Instrumentation word count Windows Driver Model wpos word position transfer identifier MIL-STD-1553 Reference Manual...
Buffer Header ID an ID number associated with the Buffer Header structure Data Buffer an area of memory on the AIM device (global RAM) assigned by the programmer to accommodate transfer(s) to/from the BC or RT Driver Command command used by the AIM Target s/w to control the Target device...
Page 465
The maximum time the Bus Controller will wait for a Status word response from the RT before indicating a “Response Timeout”. Value Single Stream indicates the AIM 1553 board supports one dual redundant MIL-STD- 1553 data stream S-Record An S-record file consists of a sequence of specially formatted ASCII character strings.
Page 466
Chapter 13 - Notes THIS PAGE INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Page 467
Appendix A – Document/Software History APPENDIX A DOCUMENT/SOFTWARE HISTORY MIL-STD-1553 Reference Manual...
Page 468
Appendix A – Document/Software History THIS PAGE INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Table A-II Summary of Version Changes for each S/W Library Function – This table includes notations for both s/w and documentation changes. MIL-STD-1553 Reference Manual...
Page 471
Changed parameter ‘res2’ to ‘sxh’ for Status Word Exception ApiCmdBCXferDef Handling Changed parameter ‘rsp1’ to ‘rsp’ Changed parameter ‘rsp2’ to ‘res2’ (removed) Changed description of the above parameters Changed constants of parameter ‘rsp’ Added extended description for 500 Kbit transmission mode MIL-STD-1553 Reference Manual...
Page 472
Changed parameter name ‘asp_drv_id’ to ‘pbi_id_biu1’ Changed parameter name ‘asp_fw_id’ to ‘pbi_id_biu2’ Changed parameter name ‘lca_chks’ to ‘res2’ Added description for parameter “rlt” ApiCmdReplayIni ApiCmdReplayStatus Corrected documentation error value descriptions for Api_REP_HALTED’ and Api_REP_BUSY’ were wrong Added description for parameter “bqm” ApiCmdRTBHDef MIL-STD-1553 Reference Manual...
Page 473
Corrected description for parameter ‘smod’ ApiCmdRTSACon Corrected description for “buffer header” Extended description for parameter “clr” ApiCmdRTSAMsgRead ApiCmdRTStatusRead Value descriptions for Api_RT_STATUS_HALTED’ and Api_RT_STATUS_BUSY’ were wrong Corrected description for parameter ‘mode’ ApiCmdSystagDef ApiEnableErrMsg Removed ApiReadBiuData Renamed to ApiReadMemData Added parameter ‘memtype’ MIL-STD-1553 Reference Manual...
Page 474
ApiCmdBMTCBIni ApiCmdBMTIWIni ApiCmdQueueIni ApiCmdQueueRead ApiCmdReplayIni ApiInstIntHandler Corrected uc_Module to show capability for up to 8 boards. Added METI and STPM interrupts in ul_Lla for BM interrupts. Corrected uc_Type to show values 3 and 4 (API_INT_REPLAY and API_INT_BC_BRANCH) MIL-STD-1553 Reference Manual...
Page 475
Added note to indicate that delay instructions are not allowed for acyclic instruction table definitions. ApiCmdBCInstrTblGetAddrFrom Added Label ApiCmdBCInstrTblIni Added ApiCmdBCStart Function changed added parameter ‘saddr’ extended description for parameter ‘smod’ Clarified which modes were applicable to Standard Framing Mode and BC Instruction Table Mode. MIL-STD-1553 Reference Manual...
Page 476
Changed description for parameter ‘hid’ ApiCmdRTBHDef Changed description for parameter ‘min’ ApiCmdRTDytagDef Changed description for parameter ‘rt_hid’ ApiCmdRTEnaDis Added Changed description for parameter ‘hid’ ApiCmdRTGlobalCon Added RT Bus Respond Control ‘bus’ ApiCmdRTIni Changed description for parameter ‘hid’ ApiCmdRTSACon MIL-STD-1553 Reference Manual...
Page 477
V19.0x Incorporated BSP 0800 Rev.A Added description for “padding” variables ApiCmdBCStatusRead ApiCmdBCAcycPrep ApiCmdRTStatusRead ApiCmdBMStatusRead ApiCmdBMStackpRead ApiCmdBMStackEntryFind ApiCmdBMTCBIni V19.0x General Corrected phone number Rev B Changed page I to a common layout V19.0x General Small corrections Rev C MIL-STD-1553 Reference Manual...
Page 478
General Corrected chapter 1.3.3.1 (description of module parameter) General Corrected chapter 3 (chapter references) Added chapter ‘1.3.4 Function Calling Convention’ General ApiCmdReadDiscretes Added ApiCmdWriteDiscretes ApiCmdInitDiscretes ApiCmdBCBHRead Added ApiCmdBCGetMajorFrameDefinition ApiCmdBCGetMinorFrameDefinition ApiCmdBCGetXferDef ApiCmdBCGetDytagDef ApiCmdRTBHRead Added ApiCmdRTGetSimulationInfo ApiCmdRTGetSABufferHeaderInfo ApiCmdRTGetDytagDef ApiCmdRTGetSAConErr MIL-STD-1553 Reference Manual...
Page 479
ApiSysSetMemPartition Added note in description for parameter ‘data_p’ ApiReadMemData ApiWriteMemData ApiReadBlockMemData ApiWriteBlockMemData Moved description of parameter ‘px_SrvReqVecCon’ from ApiCmdBCSrvReqVecCon Output section to Input section ApiCmdQueueFlush Corrected purpose section ApiCmdQueueRead Corrected purpose section Corrected description of structure ‘TY_API_QUEUE_BUF’ MIL-STD-1553 Reference Manual...
Page 480
ApiCmdScopeTriggerDef ApiCmdBiuIntrCheck Corrected constant MAX_IR_EVENT_BUF Corrected description of parameter ‘sector’ ApiCmdProgFlash Corrected description of parameter ‘perrtype’ ApiCmdRTGetSAConErr Corrected chapter “1.4.2 AIM Document Family” V19.5x General Rev A ApiCmdIni Extended structure TY_API_INI_INFO (old: bt[2], new: bt[4]) Extended description of parameter ‘bt’...
Page 481
Removed note that the number of network connections was restricted to one. Added description for parameter ‘biu’ INCOMPATIBILITY ApiDelIntHandler ApiGetBoardInfo Added Added description for parameter ‘biu’ INCOMPATIBILITY ApiInstIntHandler Extended 467ehavior467on for parameter ‘uc_Biu’ Changed structure element ‘ul_Lld’ to ‘x_Lld’ and extended its description MIL-STD-1553 Reference Manual...
Page 482
Extended parameter ‘mode’ with values 4 and 5 Extended description for parameter ‘dest_offset’ Extended parameter ‘op’ with value 0x11 (API_BC_FWI_EFEX_XFER) Extended parameter ‘par1/par2’ with value 0x11 (API_BC_FWI_EFEX_XFER) and extended description for API_BC_FWI_XFER Corrected description of structure ‘TY_API_BC_ERR’ ApiCmdBCXferDef Extended description for parameter ‘contig’ MIL-STD-1553 Reference Manual...
Page 483
Corrected name of parameter ‘rt_dytag’ (was ‘bc_dytag’) ApiCmdRTDytagDef Corrected description for parameter ‘con’ ApiCmdRTEnaDis Corrected description for parameter ‘type’ (constants ApiCmdRTGetSAConErr API_ERR_TYPE_BIT_CNT_LOW and API_ERR_TYPE_BIT_CNT_HIGH were swapped) Extended description for parameter ‘contig’ Changed parameter ‘ul_HSMC[8]’ to ‘ul_HSMC’ ApiCmdRTGetSimulationInfo MIL-STD-1553 Reference Manual...
Page 484
from 2..1024 to 0, 2..65536 ApiCmdTrackRead Extended purpose Extended “uc_DataValid” with flag “NOMEM” Extended range of parameter ‘uc_TrackId’ from 0..31 to 0..63 Extended range of parameter ‘uw_MultiplexedTrackIndex’ from 1..1024 to 0..65535 value for ‘read all multiplexed tracks’ MIL-STD-1553 Reference Manual...
Page 485
Corrected functions to meet the requirements of the ApiCmdScopeTriggerDef current LCA and HW implementation. Added ul_TrgFlags ApiCmdSysGetMemPartition ty_api_mem_biu_size Changed documentation error of Corrected discretes for AMC with new HW Revision >= 3 Appendix B Added recording queue ids. ApiCmdDataQueueRead ApiCmdDataQueueOpen MIL-STD-1553 Reference Manual...
Page 486
Functions that state limitations for AMC devices should refere Whole document to the chapter “Board functionality overview”. Declared as obsolete. ApiCmdCalTransCon Added and modified to support the new APE MIL-Scope ApiCmdScopeStart ApiCmdScopeStatus ApiCmdScopeStop ApiCmdScopeReset ApiCmdScopeTriggerDefEx ApiCreateScopeBuffer ApiCreateScopeBufferList ApiFreeScopeBuffer ApiProvideScopeBuffers ApiWaitForScopeFinished V22.6x Added ApiCmdBCXferDefErr MIL-STD-1553 Reference Manual...
Page 487
ApiGetBoardInfo Rev. C Array pci is reserved ApiCmdIni ApiBHModify Corrected range for ul_CurrentBufferIndex ApiCmdBCAcycSend Send on timetag is not available on boards with Multichannel Firwmare. V22.9x Added new functions ApiCmdBCXferDescGet Rev. D ApiCmdBCXferDescMod Corrected ERR_REPORT description. ApiCmdRTSAMsgReadEx MIL-STD-1553 Reference Manual...
Page 493
Appendix A – Document/Software History V22.9x V22.9x V22.9x V22.8x V22.8x V22.7x V22.6x V22.5x Rev. D Rev. C Rev. A Rev. B Rev. A Rev. A Rev. A Rev. A GenIo Functions ApiCmdGenIoAddrInit ApiCmdGenIoOutChnWrite ApiCmdGenIoOutChnRead ApiCmdGenIoInChnRead ApiCmdGenIoSysSTaskCtrl !NEW! ApiCmdGenIoTestSeq MIL-STD-1553 Reference Manual...
Page 494
Appendix A – Document/Software History THIS PAGE IS INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Page 495
Appendix B – Document/Software History APPENDIX B FUNCTIONALITY OVERVIEW MIL-STD-1553 Reference Manual...
Page 496
Appendix B – Document/Software History THIS PAGE INTENTIONALLY LEFT BLANK MIL-STD-1553 Reference Manual...
Due to the architecture and technology of the USB link the performance of the USB devices is different from other PCI based AIM devices. This needs careful thought and consideration when migrating or developing applications, which make use of an explicit interrupt handling.
Memory Banks Default amount of memory (MB) Maximum global memory (MB) Error Injection of High Resolution Zero Crossing Deviation Support of PXI Trigger and PXI TT Clear Functionality MB per channel MIL-STD-1553 Reference Manual...
(MB) Error Injection of High Resolution Zero Crossing Deviation Support of PXI Trigger and PXI TT Clear Functionality MB per channel Depending on the hardware configuration Depending on jumper settings MIL-STD-1553 Reference Manual...
ApiCmdGenIoAddrInit ApiCmdGenIoOutChnWrite ApiCmdGenIoOutChnRead ApiCmdGenIoInChnRead ApiCmdGenIoSysTaskCtrl ApiCmdGenIoTestSeq Functions that are not listed in this table are supported on all devices. : Supported MIL-STD-1553 Reference Manual...
ApiCreateScopeBuffer ApiCreateScopeBufferList ApiFreeScopeBuffer ApiProvideScopeBuffer ApiWaitForScopeFinished GenIo functions ApiCmdGenIoAddrInit ApiCmdGenIoOutChnWrite ApiCmdGenIoOutChnRead ApiCmdGenIoInChnRead ApiCmdGenIoSysSTaskCtrl Functions that are not listed in this table are supported on all devices. : Supported MIL-STD-1553 Reference Manual...
ApiInstIntHandler ApiDelIntHandler Functions that are not listed in this table are supported on all devices. : Supported X : Supported with performance limitations. MIL-STD-1553 Reference Manual...
Need help?
Do you have a question about the MIL-STD-1553 and is the answer not in the manual?
Questions and answers