my code :
#include <reg52.h> #include <stdio.h> #define uchar unsigned char void main() { uchar value; unsigned int address; uchar *data_buf; TMOD=0X20; // timer 1 mode 2 TH1=0xFD; // 9600 baud at 11.0592MHz TCON=0x40; // start baud rate clock SCON=0x52; // enable RX,TX address=0x01CF; value=0x66; *data_buf=value; printf("\nAddress %04xH Value : %02x",address,*data_buf); while (1); }