I think you'll find that while from USB to USART works fine. It's massively buffered by the PC. If you were to send the same text file directly to a com port at 57600, it would take 1/3 as long to transmit.
This is because the PIC waits untill the last buffer full of data is sent via HSEROUT, before allowing it to receive more from the USB. The PC does the buffering, instead of the PIC.
And on the other side of it. This program is only sending 1 byte at a time to the USB. You can send up to 64. If it were buffered at the PIC, it could save incomming 232 data while it's busy sending to USB, then send a larger packet on the next time around. I think this would greatly improve the overall speed.
Theoretically, you should be able to run quasi-full-duplex at 250kbaud, without any problems.
Bookmarks