AnsweredAssumed Answered

interrupt vector for mc68hc908qt4

Question asked by Meviltan Mendis on Mar 22, 2007
Latest reply on Mar 27, 2007 by bigmac
how mc68hc908qt4 handles the interrupt.
 
Im facing problem when using the adc interrupt of this particular chip.
 
i have written the code like this
 
interrupt 16 void adc_int (void)
{
/* reading the value of the adr register
}
 
i have done the init adc setting as
void initialise_adc(void) {
 
    ADSCR_AIEN = 1;
    ADSCR_ADCO = 0;
    ADICLK = 0X00;
   ADSCR_CH4 = 0;
   ADSCR_CH3 = 0;
  ADSCR_CH2 = 0;
   ADSCR_CH1 = 0;
   ADSCR_CH0 = 0;
    }
 
in main ()
{
initialise_adc();
}
 
bur during the debug it is giving  the error as
Error - Attempt to set A/D channel to a reserved value
 
please help me on this topic
 
 

Outcomes