I am trying to sample PE3 for a Sonar sensor, but my code never enters the ISR. I have updated my vector table with the "ADC_read_fxn" handler, but constantly just end up with "No source available for "0xfffffffe" errors. Any help would be greatly appreciated.
#include "sonar_init.h" float distInch; volatile unsigned int proflag=0; void sonarInit(void) { //SysCtlClockSet(SYSCTL_SYSDIV_5|SYSCTL_USE_PLL|SYSCTL_OSC_MAIN|SYSCTL_XTAL_16MHZ); SysCtlPeripheralEnable(SYSCTL_PERIPH_ADC0); SysCtlPeripheralReset(SYSCTL_PERIPH_ADC0); ADCSequenceDisable(ADC0_BASE,3); ADCSequenceConfigure(ADC0_BASE, 3, ADC_TRIGGER_PROCESSOR, 0); ADCSequenceStepConfigure(ADC0_BASE, 3, 0, ADC_CTL_CH0 | ADC_CTL_IE | ADC_CTL_END); SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOE); GPIOPinTypeADC(GPIO_PORTE_BASE, GPIO_PIN_3); ADCIntRegister(ADC0_BASE,3, &ADC_read_fxn); ADCIntEnable(ADC0_BASE,3);\ ADCIntClear(ADC0_BASE, 3); ADCSequenceEnable(ADC0_BASE,3); IntMasterEnable(); } void main(void) { sonarInit(); while(1){ if (proflag==0){ ADCProcessorTrigger(ADC0_BASE,3); proflag=1; } } } void ADC_read_fxn(void) { ADCIntClear(ADC0_BASE,3); while(!ADCIntStatus(ADC0_BASE, 3, false)); uint32_t rawADC; ADCSequenceDataGet(ADC0_BASE, 3, &rawADC); distInch=rawADC*102.4; proflag=0; }