From: travisutk Date: Mon, 21 Dec 2009 18:37:25 +0000 (+0000) Subject: Forgot to #ifdef some glitching code on 2274. X-Git-Url: http://git.rot13.org/?p=goodfet;a=commitdiff_plain;h=6a72fa1ddf413cea756da86b79f9cb10c66e0a06 Forgot to #ifdef some glitching code on 2274. Thanks to Bert for catching this. git-svn-id: https://svn.code.sf.net/p/goodfet/code/trunk@249 12e2690d-a6be-4b82-a7b7-67c4a43b65c8 --- diff --git a/firmware/apps/glitch/glitch.c b/firmware/apps/glitch/glitch.c index e3b226d..7de962c 100644 --- a/firmware/apps/glitch/glitch.c +++ b/firmware/apps/glitch/glitch.c @@ -24,11 +24,11 @@ void glitchsetup(){ glitchsetupdac(); - WDTCTL = WDTPW + WDTHOLD; // Stop WDT - TACTL = TASSEL1 + TACLR; // SMCLK, clear TAR - CCTL0 = CCIE; // CCR0 interrupt enabled + WDTCTL = WDTPW + WDTHOLD; // Stop WDT + TACTL = TASSEL1 + TACLR; // SMCLK, clear TAR + CCTL0 = CCIE; // CCR0 interrupt enabled CCR0 = glitchcount; - TACTL |= MC1; // Start Timer_A in continuous mode + TACTL |= MC1; // Start Timer_A in continuous mode _EINT(); // Enable interrupts #endif } @@ -38,10 +38,10 @@ void glitchsetupdac(){ glitchvoltages(glitchL,glitchH); } -// Timer A0 interrupt service routine +// Timer A0 interrupt service routine interrupt(TIMERA0_VECTOR) Timer_A (void) { - +#ifdef DAC12IR switch(glitchstate){ case 0: P1OUT|=1; @@ -58,7 +58,8 @@ interrupt(TIMERA0_VECTOR) Timer_A (void) //Do nothing. break; } - CCR0 += glitchcount; // Add Offset to CCR0 + CCR0 += glitchcount; // Add Offset to CCR0 +#endif }