Chapter 4
Programming
4-26
©
National Instruments Corporation
11. 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;
12. Now start the acquisition with
AI_Start_The_Acquisition
.
AI_Command_2_Register
AI START1 pulse = 1;
13. Poll the AI FIFO not empty flag in the AI_Status_1_Register until not
empty and read the ADC FIFO data in the ADC_FIFO_Data_Register.
Do
{
If (AI FIFO not empty) then
read FIFO data;
} while (100 samples have not been read)
Example 9
This example scans 8 channels on an AMUX-64T.
Use the default settings on the AMUX-64T, internal power, single-board
configuration, no temperature setting, and the shield unconnected. Scan
channels 0 through 7 on the AMUX-64T. Acquire 10 scans at a scan
interval of 200
µ
s and a sample interval of 20
µ
s. Connect a voltage source
to channels 0-3 and ground channels 4-7. Compare the unscaled results to
the applied voltage. Read the samples using polled input.
1.
Perform Analog Input Example 1 Step 1.
2.
Perform Analog Input Example 1 Step 2 for channels 0 and 1. Only
channel 1 has Last channel set to 1.
3.
Perform Analog Input Example 1 Steps 3-6.
4.
Call the function
AI_Initialize_Configuration_
Memory_Output
to output one pulse and access the first value in the
configuration FIFO. This function also configures the DIO circuitry
for the AMUX-64T.
AI_Command_1_Register
AI convert one pulse = 1;
AI_Mode_2_Register
AI external mux present = 1;
Содержание AT-AI-16XE-10
Страница 131: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 2 National Instruments Corporation...
Страница 132: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 3 AT MIO E Series RLPM...
Страница 133: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 4 National Instruments Corporation...
Страница 134: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 5 AT MIO E Series RLPM...
Страница 135: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 6 National Instruments Corporation...
Страница 136: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 7 AT MIO E Series RLPM...
Страница 137: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 8 National Instruments Corporation...
Страница 138: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 9 AT MIO E Series RLPM...
Страница 139: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 10 National Instruments Corporation...
Страница 140: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 11 AT MIO E Series RLPM...
Страница 141: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 12 National Instruments Corporation...
Страница 142: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 13 AT MIO E Series RLPM...
Страница 143: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 14 National Instruments Corporation...
Страница 144: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 15 AT MIO E Series RLPM...
Страница 145: ...Appendix A OKI MSM82C55A Data Sheet AT MIO E Series RLPM A 16 National Instruments Corporation...
Страница 146: ...Appendix A OKI MSM82C55A Data Sheet National Instruments Corporation A 17 AT MIO E Series RLPM...