char movR = 0x01;
char movL = 0x03;
char movU = 0x05;
char movD = 0x07;

unsigned short data = 0, ro = 0;
unsigned short *rec;

void main()
{
 TRISB=0XFF;
 
 rec=&ro;
 
 Soft_Uart_Init(PortA, 1, 2, 9600, 0);

 while(1)
 {

   if(PORTB.F1==0){ Soft_Uart_Write(movR); }
   if(PORTB.F2==0){ Soft_Uart_Write(movL); }
   if(PORTB.F3==0){ Soft_Uart_Write(movU); }
   if(PORTB.F4==0){ Soft_Uart_Write(movD); }
 }
 
}