One thing and one thing only can be done at a time, that is until parallel or "quantum" computers hit the market.

You will want to look at "interrupts" . That is how the impression of doing more than one thing at a time is accomplished. Even your desktop with all of the ram and cpu speed can only do one thing at a time - believe it or not.

http://www.picbasic.co.uk/forum/show...ght=interrupts

Look at the above link for a slick way of using interrupts with PICs or the manual for the old fashion way.