Serial Port Complete - Latest Microcontroller projects

(lily) #1
Using Special-function USB Controllers

 

: 


 


Figure 15-4 shows a circuit that can serve as a virtual COM port. The USB
controller is an FT232R, which interfaces to a PIC18F4520 microcontroller.
The PIC18F4520’s asynchronous serial output (TX) connects to the FT232R’s
asynchronous serial input (RXD), and the FT232R’s asynchronous serial out-
put (TXD) connects to the PIC18F4520’s asynchronous serial input (RX).
The example circuit uses the RTS# and CTS# handshaking lines on the
FT232R. These lines can connect to any otherwise unused port pins on the
PIC18F4520. If needed, the FT232R’s other status and control pins can con-
nect to other port pins on the PIC18F4520.
Attach the USB connector to a port on a PC and follow the on-screen instruc-
tions to install FTDI’s drivers. (See FTDI’s website for a detailed driver-installa-
tion guide.) When the drivers are installed, the Device Manager shows a new
COM port, and the port is ready for use.
In a similar way, any microcontroller with an asynchronous serial port (and
additional port pins if needed) can interface to an FT232R and function as a
USB virtual COM port.

Figure 15-4: This USB virtual COM port uses an asynchronous serial interface to a PIC
microcontroller.
Free download pdf