Hello Peg,
There are so many questions here a~ I'm new to program like this...
1. I'm using HC908JL8, it's a 32 pin MCU
2. baudrate is 9600, 8bits, no parity, 1 stop bit.
3.I dunno how to find out e bus clock...
I'm not in the office already. so just can remember part of my codes.
void init_SCI(void){
SCBR=0x03; //baudrate 9600,8bit,1stop bit
SCC1=0x40; //enable SCI
SCC2=0xC0;//enable transmitter and reciever
SCC3=0x00;
}
void Outchar(unsigned char letter){
while((CSC1&SCTE)=1){
read_csc1=CSC1;//read_csc1 is a rubish unsigned char, clear SCI transmitter empty bit by reading SCI status register1
SCDR=letter;
}
}
I communicate with the computer using my MCU. It should display a "4" on the window. It's not like i type on another computer here. to test my codes and connection, i just assigned letter=54 here, should be "4" after convert. so i transmit letter directly to SCDR. and in the hyper terminal should be a number"4" displayed there. in one word, i get nothing on my screen...
i dunno whether i ans your question or not. but these are all that i know.. Thanks a lot!
Vero
Message Edited by vero on
2007-06-22 04:49 PM