??? 02/28/06 16:55 Read: times |
#110925 - thanks and here is my C code of asm... Responding to: ???'s previous message |
ok..thanks..may be I need to look into putchar() src file. it maybe that it is interrupt driven. here is the C program of ASM...
//I need to set TI=1 before calling this.... char senddata (char ch) { do{;}while (!TI); TI = 0; //clear TI SBUF=ch; // MOV SBUF,R1 return SBUF; } //from tutorial ..ASM... CLR TI ;Be sure the bit is initially clear MOV SBUF,R1 ;Send the letter A to the serial port JNB TI,$ ;Pause until the TI bit is set. So I wonder if the compiler C51 assumes I am using interrupt??? and by the way, do we also need to set value of TL1 for serial mode 1 communication ? since we need to set value of TH1 for auto reload. if yes, with what value should TL1 be initialised? |
Topic | Author | Date |
putchar C51 serial communication problem | 01/01/70 00:00 | |
Keil putchar source | 01/01/70 00:00 | |
putchar() reworded | 01/01/70 00:00 | |
TI | 01/01/70 00:00 | |
thanks and here is my C code of asm... | 01/01/70 00:00 | |
should be obvious | 01/01/70 00:00 | |
To be fair | 01/01/70 00:00 | |
C gives higher performance! | 01/01/70 00:00 | |
Initial conditions | 01/01/70 00:00 | |
waiting better than uninten effcy | 01/01/70 00:00 | |
Better? | 01/01/70 00:00 | |
Math? | 01/01/70 00:00 | |
What????? | 01/01/70 00:00 | |
no work to do unitl bytes send | 01/01/70 00:00 | |
OK | 01/01/70 00:00 | |
or... | 01/01/70 00:00 | |
That is better | 01/01/70 00:00 | |
i read about putchar() | 01/01/70 00:00 | |
Try \Keil\C51\LIB\getkey.c | 01/01/70 00:00 | |
Keil Library Source Files | 01/01/70 00:00 | |
ok | 01/01/70 00:00 | |
No and Yes | 01/01/70 00:00 | |
but what about AT cmd | 01/01/70 00:00 | |
No![]() | 01/01/70 00:00 |