Chapter 4
Programming
4-16
©
National Instruments Corporation
7.
Convert_Signal
selects the convert signal for the acquisition.
Joint_Reset_Register
AI configuration start = 1;
AI_SI2_Load_A_Register
AI SI2 special ticks -1 = 1999;
AI_SI2_Load_B_Register
AI SI2 ordinary ticks -1 = 1999;
AI_Mode_2_Register
AI SI2 reload mode = 1;
AI_Command_1_Register
AI SI2 load = 1;
AI_Mode_2_Register
AI SI2 initial load source = 1;
Joint_Reset_Register
AI configuration start = 0;
AI configuration end = 1;
8.
Perform Analog Input Example 1 Step 4.
9.
The function
AI_Interrupt_Enable
enables interrupts for the
acquisition.
Interrupt_A_Enable_Register
AI FIFO interrupt enable = 1;
AI error interrupt enable = 1;
Interrupt_Control_Register
MSC IRQ pin = 0;
MSC IRQ enable = 1;
10. Call
AI_Arming
to arm the analog input counter.
AI_Command_1_Register
AI SC arm = 1;
AI SI arm = 1;
AI SI2 arm = 1;
AI DIV arm = 1;
11. Install the interrupt service routine to handle the interrupt.
Interrupt_Service_Routine()
read FIFO data;
increment sample counter;