X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=src%2Fcc1111%2Fao_adc.c;h=ce827e2596ac7b576fc84056507e0e68cecf1dd1;hb=246174b32bb6cf827d240c32d6a51c3513a08c37;hp=1e3d8cabc7b94359645ad1594221f5c7923cc27e;hpb=ce8153472069ed56b24ac36f297ac569d1f767d4;p=fw%2Faltos diff --git a/src/cc1111/ao_adc.c b/src/cc1111/ao_adc.c index 1e3d8cab..ce827e25 100644 --- a/src/cc1111/ao_adc.c +++ b/src/cc1111/ao_adc.c @@ -52,11 +52,11 @@ ao_adc_isr(void) __interrupt 1 uint8_t __xdata *a; sequence = (ADCCON2 & ADCCON2_SCH_MASK) >> ADCCON2_SCH_SHIFT; -#if IGNITE_ON_P2 +#if TELEMETRUM_V_0_1 || TELEMETRUM_V_0_2 || TELEMETRUM_V_1_0 || TELEMETRUM_V_1_1 || TELEMETRUM_V_1_2 || TELELAUNCH_V_0_1 /* TeleMetrum readings */ #if HAS_ACCEL_REF if (sequence == 2) { - a = (uint8_t __xdata *) (&ao_data_ring[ao_data_head].accel_ref); + a = (uint8_t __xdata *) (&ao_data_ring[ao_data_head].adc.accel_ref); sequence = 0; } else #endif @@ -81,10 +81,10 @@ ao_adc_isr(void) __interrupt 1 } #endif -#if IGNITE_ON_P0 +#if TELEMINI_V_1_0 || TELENANO_V_0_1 /* TeleMini readings */ - a = (uint8_t __xdata *) (&ao_data_ring[ao_data_head].pres); -#ifdef TELEMINI_V_1_0 + a = (uint8_t __xdata *) (&ao_data_ring[ao_data_head].adc.pres); +#if TELEMINI_V_1_0 switch (sequence) { case 0: /* pressure */ @@ -138,7 +138,8 @@ ao_adc_isr(void) __interrupt 1 /* Start next conversion */ ADCCON3 = sequence; } -#endif +#endif /* telemini || telenano */ + #ifndef GOT_ADC #error No known ADC configuration set #endif