Steve,
Thank you for the code, it worked beautifully. I did notice that moving the clear command down to the very bottom right before the 'goto main' worked better. I think the data came in so fast that if the timing were off I missed some data streams.
I have a question regarding the clear command. I understand it completely clears the ram which prevents a constant repeating loop of a single data input stream. Is there another way to specifically clear or erase whatever register or ram location the USART uses? I ask because I am running several if then statements that require checking the status of certain variables and if I use the clear command, I lose the original status/data in those variables.
I've tried using RCIF = 0 and RCREG = 0 to no avail. I've also tried the ERASECODE $FAEh to clear the RCREG register, but this command doesn't work in PicBasic Pro with the 18F2525 chip I'm using. Any suggestions?
Again, thanks again for the code, I've been playing with it all day, making mistakes, gaining victories and generally learning a lot in the process.
Bookmarks