W e will begin with transmission, because it is simple. The transmitter portion of theUAR T includes a data output pin, with digital logic levels as drawn in Figure 4.33. Thetransmitter has a 16-element FIFO and a 10-bit shift register , which cannot be directlyaccessed by the programmer (Figure 4.35). The FIFO and shift register in the transmitterare separate from the FIFO and shift register associated with the receiver . T o output datausing the UAR T , the software will first check to make sure the transmit FIFO is not full (itwill wait if TXFF is 1) and then write to the transmit data register(e.g., UART0_DR_R ).The bits are shifted out in this order: start, b0, b1, b2, b3, b4, b5, b6, b7, and then stop, whereb0is the LSB and b7is the MSB. The transmit data register is write only , which means thesoftware can write to it (to start a new transmission) but cannot read from it. Even thoughthe transmit data register is at the same address as the receive data register , the transmitand receive data registers are two separate registers.
đang được dịch, vui lòng đợi..
