Code: Select all
char replyBuf[32];
uchar *ptr=replyBuf;
ISR(ADC_vect,ISR_NOBLOCK)
{
ADCSRA&=~(1<<ADIE);
*ptr++=ADCH;
ADCSRA|=(1<<ADIE);
}
This causes usb error . is it longer than 25 cycles??
Code: Select all
char replyBuf[32];
uchar *ptr=replyBuf;
ISR(ADC_vect,ISR_NOBLOCK)
{
ADCSRA&=~(1<<ADIE);
*ptr++=ADCH;
ADCSRA|=(1<<ADIE);
}