Quote Originally Posted by crhomberg View Post
I don't have a choice, the data always comes in groups of 8. The serout is just for debugging, not really needed finally. I must be able to read in 8 bytes and then check if the 1st one is $A0 and the 7th $AF. When that is true I can use the data. The packets come at 4800bps and in bursts relatively far apart (That is how I got away with serin2 until now, it just lost packets from time to time) I need to stop what the program is doing when that 1st byte arrives and then channel in the next 7 into an array or sepparate vars.
Regards
Chris
Put that input on portB and use the 'interrupt on change' feature...
I.E. - you're transmitting, something starts coming in on the serial line. Stop transmitting immediately and start receiving.

What you're trying to do isn't impossible. It's just getting past the PicBasicPro serial commands and using straight hardware and interrupts to handle it in the 'background'.
I suggest playing around with interrupts first, doesn't matter which one, just play with them. Then work your way up to using the serial port, both RX and TX, use some sort of buffering setup.