You have a few things wrong,
You have a wend without a while.
You have an if without endif. (might be wrong here)
I would guess (I don't use basic on pics) it should be something like,
Code:main Usart_init(9600) Usart_Write_Text (y) loop: if Usart_Data_Ready = 0 then ' do nothing else i = Usart_Read ' Read the received data Usart_Write_Text (j) Usart_Write (i) PORTB = i delay_ms (3000) end if goto loop
Mike.
i have some question here
1. What is the use of line PORTB=i
2. i is a byte and suppose a string of character is going to pic from a computer will the pic be able to receive a string of cheracters at once or just it can receiving one char at a time.
help me please.