PJRC.COM Offline Archive, February 07, 2004
Visit this page on the live site

skip navigational linksPJRC
Shopping Cart Checkout Shipping Cost Download Website
Home MP3 Player 8051 Tools All Projects PJRC Store Site Map
You are here: 8051 Tools PAULMON Monitor Manual Using Serial Port Search PJRC

PJRC Store
8051 Dev Board, $79
LCD 20x2 Display, $11
Serial Cable, $5
12 Volt Power, $8
More Components...
8051 Tools
Main Page
Software
PAULMON Monitor
Development Board
Code Library
89C2051 Programmer
Other Resources

Reclaiming the Serial Port From PAULMON2

Many applications require the 8051's built-in UART, but PAULMON2 uses the UART for communication. One approach to developing programs which require the serial port is to build a simple circuit which routes the TXD and RXD signals to one interface circuit when PAULMON is in use, and to another interface circuit when PAUMON is not is use (when the program under development is running).

Here is one simple circuit that accomplishes this using 7 NAND gates. The 74HC00, 74LS00, 7400, CD4011 or other similar chips should work for this application. Be sure to check the pinouts before wiring

serial port mux using nand gates
Figure 1: Simple Serial Port Mux Using NAND Gates

The SELECT line should be connected to a port pin on the 8051. When the 8051 is reset, the port pins default to a high state, which causes the circuit to route the TXD/RXD signals to the serial port used for development with PAULMON. The first line code in the application program (downloaded to RAM using PAULMON) should clear the SELECT pin, so the the TXD/RXD signals are routed to the serial port that the program needs to use. If the processor is RESET (returning the system to PAULMON), the port pin will return high when the 8051 resets, and PAULMON will be ready for another code download, memory editing, etc.

A similar circuit can be constructed using a DPDT relay (don't forget a transistor to drive the coil), with pullup resistors on the various signal lines so that they will remain at a logic high when they are physically disconnected by the relay contacts.

This simple technique does require extra circuitry on the development board, and one extra port pin, which won't be used in the final application. However, it does allow the use of PAULMON to develop the code and once the downloaded program is running with the SELECT line low, the program need not know that PAULMON uses the other serial port.


PAULMON2 Documentation, Paul Stoffregen
http://www.pjrc.com/tech/8051/pm2_docs/serial-port.html
Last updated: November 28, 2003
Status: Finished
Suggestions, comments, bug reports??? <paul@pjrc.com>