DDC Reference Sample Code : mtiirq
Download
This sample demonstrates using MTi mode in Multi-function boards to generate an interrupt on matching the command word in received messages.
1. Overview
- This sample uses Triggers with MTi mode for command word match and links the
ACEX_TRG_EVENT_INTERRUPT event to the trigger.
- General Purpose Trigger 1 and 2 are used to demonstrate comparison of two command words. This may be extended to up to 16 command words.
- Upon receipt of a message with a matching command word, the board raises an interrupt that is handled by an interrupt service routine.
- The ISR obtains the source of interrupt by reading the trigger status and IRQ status using
acexTRGGetStatus and prints an appropriate message.
- The sample may be extended to perform data word matching instead of command word.
- To test this sample, two DDC 1553 boards are needed. One, to run this sample as an MTi which must be a multi-function card and another to generate the BC traffic (this may be a single function board as well).
2. APIs Demonstrated
aceInitialize
aceGetHwVersionInfo
aceMTIConfigure
acexTRGReset
aceSetIrqConditions
aceMTIStart
aceMTIStop
aceFree
acexTRGEventSelect
acexTRGConfigure
acexTRGEventEnable
acexTRGEnable
3. Build and Test Details
The sample was built and tested using Visual Studio 2022 on on Windows 11. BU-69092S0-110 v4.9.5 was used with BU-67202U as MTi and BU-67103U as BC.