Totally make sense sir. Yes the board is using a murata 3pin ceramic oscillator.
I added CRC code and did DBG1 on every CRC error, it seems communication failure always occurred immediately after CRC error.
I'll find another board with crystal and test again.
Thanks!
I added CRC code and did DBG1 on every CRC error, it seems communication failure always occurred immediately after CRC error.
I'll find another board with crystal and test again.
Thanks!
blargg wrote:Does the 328p board use a crystal oscillator or ceramic oscillator? I've got several 328p boards and they use ceramic resonators, which have lower accuracy and might cause occasional errors.
Also, you could enable CRC checking on the V-USB side, and have it at least ignore packets with incorrect CRCs. Put this in your usbconfig.h:#define USB_RX_USER_HOOK( data, len ) { \
if ( usbCrc16( data, len + 2 ) != 0x4ffe )\
return;\
}