James Newton wrote: > >
> Follow the 'downloads' link. It is right at the bottom. > http://www.wasp.co.za/~tjaart/piclist.html >
> > Tjaart, thanks for the circuit, just to make sure I understand this, the DB9 > (J2) is connected to a peripheral NOT to a PC (because a PC would be driving > pin 3 and reading pin 2). On the incoming side, who cares about -12? No > problem. But on the TD pin, you are actually driving it between <+12 and > >ground not +12 and -12. Right? And this works? How long a cable have you > used? It converts +-12V (on the PC side) to -+5V (note the inversion) on the micro sid e. I have used it on PC's, modems, laptops, notebooks and partridges in pear trees. I have never had a problem and have used it on 15m+ cables. The purpose of the two transistors are purely to invert. Also note that the "RX" and "TX" labels are always as seen from the DCE, so TX and RX will swap over when the PIC becomes a DCE (like when you connect it to a modem). When you connect the PIC to your PC, it is a DTE. Nice and confusing ;) For those PIClisters who are proud owners of SX Keys, open up the DB9 shell, and have a look at the brilliant little trick they use to get TX and RX on the *same* cable. Damn, those guys are clever! It took me a few seconds to notice the 0402 resistor, so look carefully. -- Friendly Regards /"\ \ / Tjaart van der Walt X ASCII RIBBON CAMPAIGN mailto:tjaart@cellpt.co.za / \ AGAINST HTML MAIL |--------------------------------------------------| | GSM Technology for Positioning and Telematics | | Cellpoint Systems SA http://www.cellpt.com | | http://www.wasp.co.za/~tjaart/index.html | | WGS84 -26.0124 +28.1129 Voice +27 (0)11 2545100 | |--------------------------------------------------|