Do you think this code will working fine??

define osc 4
include "bs2defs.bas"

wating:
SERIN PORTa.1,N9600,["K"],b1

IF b1 = 51 THEN out ' Ascii 51 = decimal 3 (When you type 3 myvar will be 51)

goto wating ' this line is esential otherwise any key will activate the function

out:

HIGH PORTb.7

PAUSE 300

LOW PORTb.7

goto wating
-----------------------------------------------
I am using PIC16F84a and port RA! Connected to 22k ohm then to the pc serial port. And I am using windows hyper terminal to send the serial signal now my question number tow is what I have to send [k3] or [3] or[k] or 51???

good glass:)