Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
01/21/00 13:44
Read: times


 
#1268 - RE: serial port:8databit, evenparity, 2 stopbit
You got only an 11 Bit UART in Mode 3

1 Start Bit, 8 Data Bits, 1 Parity and 1 Stop Bit

The Number of Stop Bits is only important if you transmit a Byte. The Receiver does not depends at the Number of Stop bits because their are recognized as MARK on IDLE (like a little character Delay). With the next Start Bit reception starts again. At the transmitter side sending 2 Stop bits is the same as sending one Stop Bit and then wait at least a single Bit time (depending at your Baudrate). All you have to do is something like this:

Init Prozessor for Mode 3

SEND_CHAR:
MOV C,P ; Get Parity
MOV TB8,C ; Set it as 9th Data Bit
JNB TI,$ ; Wait for transmitter empty (Now the last bit hast been ; send )
NOP NOP NOP NOP NOP NOP NOP NOP ( Wait Stop bit and your minimal Bit Time )
MOV SBUF,A ; Send the character
RET

Greetings Urs

List of 2 messages in thread
TopicAuthorDate
serial port:8databit, evenparity, 2 stopbit            01/01/70 00:00      
RE: serial port:8databit, evenparity, 2 stopbit            01/01/70 00:00      

Back to Subject List