Well the good news is that I have the USART working now. Trouble is, I wanted to use it because it has an input buffer. I assumed it would buffer the two bytes it receives, allowing me to read them later on in the program. The HSERIN command seems to wait until it receives the data, or you can specify a timeout. Surely this is pretty much the same as using the SERIN command? My program has to continue working at the same time as receiving serial data. So, how can I do this? It doesn't look like PICBASIC will allow it. I tried specifying a timeout, but the timeout has to be very short and I still don't receive any serial data. Doesn't this really defeat the purpose of the buffer?
Perhaps i'm using the command wrong. Any help or advice is much appreciated. Perhaps I need to program this bit in ASM, trouble is I can't program in ASM.
Best regards,
Matthew
Bookmarks