Chapter 4
Programming
4-24
©
National Instruments Corporation
11. 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 (20 samples have not been read)
Example 8
This example samples one channel on an AMUX-64T.
Use the factory default settings on the AMUX-64T, internal power,
single-board configuration, no temperature setting, and the shield
unconnected. Sample channel 3 on the AMUX-64T to acquire 100 samples
at a sample interval of 10
µ
s. Connect a voltage source to channel 3, and
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 channel 3.
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 pulse = 1;
DIO_Control_Register = 0x0003;
DIO_Output_Register = 0x0003;
DIO_Control_Register = 0x0803;
DIO_Control_Register = 0x0003;
5.
Perform Analog Input Example 1 Steps 8-9.
6.
Call the function
Number_of_Scans
to load the number of scans.
Joint_Reset_Register
AI configuration start = 1;
AI_SC_Load_A_Registers (24 bits)
Number of posttrigger scans - 1 = 99;
AI_Command_1_Register
AI SC Load = 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...