add support for ao linearity calibration on at-mio-16e-1 and
authorFrank Mori Hess <fmhess@speakeasy.net>
Sun, 4 Apr 2004 02:22:44 +0000 (02:22 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Sun, 4 Apr 2004 02:22:44 +0000 (02:22 +0000)
at-mio-16e-2

comedi_calibrate/ni.c

index fe9309e3a636db46a3d4d1afc7808f727d04fd3a..fb4205c87cab5123dd0863b028ab84d21e64f7e7 100644 (file)
@@ -659,23 +659,6 @@ static void ni_setup_observables_611x( calibration_setup_t *setup )
        setup->n_observables = num_ao_observables_611x + 2 * num_ai_ranges * num_ai_channels;
 }
 
-static int cal_ni_at_mio_16e_2(calibration_setup_t *setup)
-{
-       ni_caldac_layout_t layout;
-
-       init_ni_caldac_layout( &layout );
-       layout.adc_pregain_offset = 0;
-       layout.adc_postgain_offset = 1;
-       layout.adc_gain = 3;
-       layout.adc_unip_offset = 2;
-       layout.dac_offset[ 0 ] = 5;
-       layout.dac_gain[ 0 ] = 6;
-       layout.dac_offset[ 1 ] = 8;
-       layout.dac_gain[ 1 ] = 9;
-
-       return cal_ni_generic( setup, &layout );
-}
-
 static int cal_ni_daqcard_ai_16xe_50(calibration_setup_t *setup)
 {
        ni_caldac_layout_t layout;
@@ -726,7 +709,26 @@ static int cal_ni_pci_mio_16xe_10(calibration_setup_t *setup)
 
 static int cal_ni_at_mio_16e_1(calibration_setup_t *setup)
 {
-       return cal_ni_at_mio_16e_2( setup );
+       ni_caldac_layout_t layout;
+
+       init_ni_caldac_layout( &layout );
+       layout.adc_pregain_offset = 0;
+       layout.adc_postgain_offset = 1;
+       layout.adc_gain = 3;
+       layout.adc_unip_offset = 2;
+       layout.dac_offset[0] = 5;
+       layout.dac_gain[0] = 6;
+       layout.dac_linearity[0] = 4;
+       layout.dac_offset[1] = 8;
+       layout.dac_gain[1] = 9;
+       layout.dac_linearity[1] = 7;
+
+       return cal_ni_generic( setup, &layout );
+}
+
+static int cal_ni_at_mio_16e_2(calibration_setup_t *setup)
+{
+       return cal_ni_at_mio_16e_1(setup);
 }
 
 static int cal_ni_pci_mio_16e_1(calibration_setup_t *setup)