ADC and DAC test.
Copyright (c) 2011-2018 Microchip Technology Inc. and its subsidiaries.
Functions | |
void | classb_analog_io_test (DAC_t *dacptr, ADC_t *adcptr) |
Functional test for the ADC, DAC and analog MUX. More... | |
static void | classb_dac_adc_test (DAC_t *dacptr, ADC_t *adcptr, uint16_t dac_out, uint16_t adc_assert) |
Internal function for analog test. More... | |
|
static |
Internal function for analog test.
This test writes a value to the DAC, and checks that the ADC readouts are within the expected range, which is set with CLASSB_ADC_DEV.
dacptr | Base address for registers of DAC module to test. |
adcptr | Base address for registers of ADC module to test. |
dac_out | Output value to test the DAC with. |
adc_assert | Expected ADC value to measure. |
References abs, CLASSB_ADC_DEV, and CLASSB_ERROR_HANDLER_ANALOG.
Referenced by classb_analog_io_test().