A Simple Serial Interface for the Handy Board or BotBoard
 Microcontroller Packaged Inside of a DB9 Serial Connector Housing
1999
[ Homepage ][ Send me mail ] © Kam Leang

1  Introduction
The following article is about making a simple serial interface between a PC and the Handy Board (HB) or BotBoard microcontroller and showing that it is possible to package all of the electronics inside of a DB9 serial connector housing.  In contrast to other interfaces, which may be bulky (i.e., click to see a comparison of the DB9 connector interface versus the Handy Board serial interface board), the following instructions results in a more convenient interface that can be connected to any 9-pin PC serial port without converting the DB25 to a DB9 connector.  Figure 1 shows a photograph of the finished product made for the Handy Board and BotBoard microcontroller.  Note the compact size of each unit.  Each interface is powered by the microcontroller that it is connected to and its small size makes it easy to carry around.  Note, however, that making the following interface for the HB, you will lose features such as LED indicators and the battery charging option found on the original HB serial interface.  For some (like me!), the compact size of the following interface is worth the loss in features.


Figure 1.  The final product:  a DB9 serial interface for the BotBoard (left) and
the Handy Board (right).  Note the compact size of each unit. (click on image for larger view)

2  Overview and Required Components
In order to communicate with and to program the Handy Board or BotBoard, a PC's RS232 serial transmit signal must be converted to a compatible TTL (0-5V) level of the microcontroller.   Similarly, when the microcontroller wants to communicate with a PC, its TTL level signal must be converted to the PC's RS232 voltage level.  Thus, the serial interface is built around the Maxim Max232 RS232-to-TTL level converter chip. The chip that is used is the MAX232A series, which requires 4 external 0.1uF and one 0.2uF monolithic capacitors.  This is a critical component because other versions require large (size) capacitors, making it impossible to stuff all of the components into a DB9 connector housing.  On the other hand, Maxim's MAX233 chip, which requires no capacitors may seem like a tempting substitute, but its physical dimensions is slightly too big to fit into the desired housing.

Figure 2 shows the  required components to construct the interface.  Table I lists all of the components including the suppliers (Other suppliers may be more convenient than what are listed).

Figure 2.  Required components for building the serial interface.  From left-to-right:  LM78L05 +5V regulator (only for the Handy Board), Maxim Max232A chip, 4 0.1uF and one 0.2uF monolithic capacitors, DB9 housing, female DB9 connector,  and RJ11 connector and cable (Handy Board), or Molex 4-pin connector and cable (BotBoard). (click on image for larger view)


Table I.  A list of components.

Qty
Item
Price
Part No.
Supplier
1
LM78L05 +5V 100mA Regulator (Handy Board only!)
~$0.20
51182
Jameco
1
Maxim 
MAX232ACPE
~$4.00
MAX232ACPE-ND
Digikey
4
0.1uF Monolithic
Capacitors
~$2.00
272-109
Radio Shack
1
0.2uF Monolithic Capacitor
~$0.50
N/A
Radio Shack
1
DB9 Connector
Housing
~$1.00
276-1539
Radio Shack
1
DB9 Female Connector
~$1.00
276-1538
Radio Shack
1
RJ11 4-Conductor Crimp Connector (Handy Board)
~$0.30
A9092-ND
Digikey
1
Molex Connector 4-Conductor (BotBoard)
~$1.50
WM2802-ND
WM2501-ND
Digikey
4ft
4-Conductor Wire
~$0.50
N/A
Radio Shack
 
Total Cost
~$11.00
   
Again, most of the items in Table I can be substituted for others performing the same function, but keep in mind that the smaller the better.  The total cost shown in Table I is a conservative estimate.  It's best to rummage through your junk bin to see if you have any of the items on the list before buying.  If you are building the interface for the BotBoard, a good source of the 4ft 4-conductor wire is from an old serial computer mouse.  For the Handy Board, find an old phone cable, making sure that it contains 4 conductors and if you're lucky, you might find an RJ11 connector attached to one end that is compatible with the Handy Board RJ11 interface.

3  Construction
Constructing the interface unit consists of a few straightforward steps; however, a skilled hand at soldering is mandatory!  There's not much room for mistakes and neatness counts or else your "rat's nest" may not fit inside of the already small housing compartment.

The circuit diagram linking all of the components together for the HB interface is shown in Figure 3.  Note the orientation of the LM78L05 part.  It's shown bottom view up!  The computer side is the DB9 serial connector. Pay attention to the numbering on the pins.  The microcontroller side shown in the figure corresponds to the RJ11 connector for the Handy Board (refer to HB manual for additional info).  If you're making the interface for the BotBoard (refer to the attached circuit diagram), leave out the LM78L05 and substitute the connector for the Molex connector and wire the connections accordingly (consult your BotBoard owner's manual for PWR, GND, Tx, and Rx lines).  Note that the MAX232A chip gets its power from the LM78L05, which regulates power from the 9.6V battery found on the Handy Board.  In the case of the BotBoard, the MAX232A chips get its power directly from the BotBoard's +5V power supply.

Figure 3.  The serial interface circuit diagram for the Handy Board (Click here to view the diagram for the BotBoard).  Note that the microcontroller end is for the Handy Board.  To make your interface for the BotBoard, substitute the RJ11 connector for the Molex connector and wire the connections accordingly (Consult your BotBoard owner's manual for PWR, GND, Tx, and Rx lines).


3.1  Assembly Steps
Use the following simple steps to get started.  Lay out all parts and figure out how to conserve space so that all the components will fit inside of the serial connector housing.  Clear your mind, and make sure to use plenty of solder flux.  Work in a well ventilated area with plenty of lights and be sure to wear proper eye protection.  Some good soothing music playing in the background also helps.

1.  Begin by cutting down the length of the legs on the MAX232A part as shown in Figure 4.  Doing so will make more room for other components as the construction progresses.


    (click on image for larger view)
Figure 4.  Cutting the legs off of the MAX232A part to make more room for other components.

2.  This is the trickiest step.  Solder all of the capacitors to the chip, but do so as shown in Figure 5.  The idea is to take up the lease amount of room as possible.  Notice that I've cut the leads of each capacitor down and positioning them as close to the body of the chip as possible.


(click on image for larger view)

Figure 5.  Soldering the capacitors as close to the MAX232A chip as possible..

3.  Use wire wrapping wire or something with the same fine gauge to make the remaining connections.  If you're building an interface for the Handy Board, cut as much of the LM78L05 legs off as possible and solder the connections using this wire.  Be sure to position it properly so that everything fits together.  If you're making the interface for the BotBoard, you do not need the LM78L05 part.  Simply wire power and ground from the BotBoard to the appropriate connections.    Figure 6 shows the completed unit ready to be enclosed in its housing.


Another view of the guts

Figure 6.  Completed unit ready for the final seal.  Note that the MAX232A chip basically sits sideways to fit inside of the connector housing.  A strain relief at the cable end reduces the chances of pulling apart the guts of your creation during normal operation.  (click on image for larger view)
At this stage, before sealing up the tomb, test the unit by plugging the business end (i.e., DB9 connector) into a PC's serial port and the other end to your desired microcontroller.  Try to download and communicate with your board.  If the unit works, then seal away!  Otherwise, back track and figure out what went wrong...or if I've posted something wrong.  If that's the case, please email me with a complaint.

For a few more pictures of the completed serial interface unit, click below:

  • Interface for the Handy Board
  • Interface for the BotBoard
  • 4   References
    The author would like to acknowledge the following sources of information and their support
    1. Maxim IC company for data sheets and free sample chips.  This article would not have been possible without their help.
    2. Martin, Fred G. "The Handy Board Technical Reference Manual" MIT Press.  1998
    3. Green, Marvin "The BotBoard Owner's Manual V1.03"