Sir, I am having trouble in saving the data received from the rxd of 89c52. when i debug the program and i checked the values and changed the SBUF value and on further checking the values of the temp=SBUF the temp value is still on 0.
unsigned char temp; void serial_read() // read byte { while(RI==0); temp=SBUF; RI=0; }
and there is a doubt that if we return the SBUF value this is not working.
unsigned char serial_read() { while(RI==0); return SBUF; }
Thanks in advance.