Page 1 of 1

AVR-CDC How detect end of paket (paket length>8)?

Posted: Wed Jan 30, 2008 11:00 am
by Oleg
PC terminal program send variable lentgh paket (up to 256 byte).
Old MCU software (RS232 interface) detect end of paket use transfer timeout (MODBUS protocol).
Now I use AVR-CDC, how detect last 8byte frame in report d'not use timeout?

PS: I'm sorry, my english is poor.

Posted: Sun Feb 03, 2008 6:16 pm
by christian
Any real time protocol with tight time constraints gets into troubles with USB -> serial converters since the timing can usually not be exactly preserved.

USB CDC sends data on the stream endpoint when it is available. If no data is available, no data is sent. If the time resolution after going through the USB driver and the (non real-time) operating system is acceptable, this should still work.