I thought I had posted this last night, but I do not see it in the forum. My apologies if this is a duplicate.
I am trying to operate EADC1 in SAR mode, but the EADCVALUE register is always 0.
I am operating DPWM0 at 200KHz to trigger the EADC sampling.
EADCCTRL.bit.EADC_MODE = 2
EADCCTRL.bit.AFE_GAIN = 0
EADCCTRL.bit.SCFE_GAIN_FILTER_SEL = 1
EADCCTRL.bit.SCFE_CLK_DIV_2 = 1
EADCCTRL.bit.SCFE_ENA = 1
EADCCTRL.bit.EADC_ENA = 1
I also set SARCTRL.bit.SAR_RESOLUTION = 3 to get 1 millivolt resolution.
All other fields of SARCNTL are left at reset value.
Do I need to modify any of the other fields of SARCNTL?
Do I need to modify any other register.
I searched online for sample code, but found none. Does anyone know of sample code?