This commit is contained in:
pascallanger 2016-08-24 15:05:24 +02:00
parent 061c97caca
commit e63f71d3a7

View File

@ -1055,7 +1055,6 @@ ISR(USART_RX_vect)
if(UDR0==0x55) // If 1st byte is 0x55 it looks ok if(UDR0==0x55) // If 1st byte is 0x55 it looks ok
#endif #endif
{ {
idx++;
#ifdef XMEGA #ifdef XMEGA
TCC1.CCB = TCC1.CNT+(6500L) ; // Full message should be received within timer of 3250us TCC1.CCB = TCC1.CNT+(6500L) ; // Full message should be received within timer of 3250us
TCC1.INTFLAGS = TC1_CCBIF_bm ; // clear OCR1B match flag TCC1.INTFLAGS = TC1_CCBIF_bm ; // clear OCR1B match flag
@ -1065,6 +1064,7 @@ ISR(USART_RX_vect)
TIFR1=(1<<OCF1B); // clear OCR1B match flag TIFR1=(1<<OCF1B); // clear OCR1B match flag
TIMSK1 |=(1<<OCIE1B); // enable interrupt on compare B match TIMSK1 |=(1<<OCIE1B); // enable interrupt on compare B match
#endif #endif
idx++;
} }
} }
else else