> From: "Larry P. Thomas WA0GWA" > I'm working on some PIC devices and intend to use some I2C code to > code up the slave routines. I found routines to let me use PC > parallel port as master to test my slave devices but the references > I found all use some sort of hardware on the PC port such as a > 74LS05 to aid in the bidirectional I2C implimentation. Since some of > the parallax products seem to use I2C to talk between the PC and the > target system without any extra hardware at the PC end, I was > wondering if anybody had any info on how to do this. The hardware > is simple enough, I just was trying to avoid a trip to the city to > get the parts for the I2C PC port interface. I haven't really checked what protocol the Parralax products use, but I'm convinced it is not I2C. The problem is that I2C requires a bidirectional line for the SDA which can also be pulled low when the slave device does an acknowledge. That is why all implementations of I2C on the PC parallel port usually require a little bit of external hardware. It is definetely possible to implement your own serial protocol directly on the parallel port because there are 5 input and many output pins on the PC parallel port which you can interface to directly. The outputs of the PC printer port is given below. The signals marked with a - are inverted. The ones who's direction are marked OUT, actually mean that you can use them as inputs from your PC side. FUNCTION DIR PRINTER 25 Way -STROBE IN 1 1 -DATA 1 IN 2 2 +DATA 2 IN 3 3 +DATA 3 IN 4 4 + DATA 4 IN 5 5 + DATA 5 IN 6 6 + DATA 6 IN 7 7 + DATA 7 IN 8 8 + DATA 8 IN 9 9 - SELECT IN 36 17 - AUTO LF IN 14 14 - INIT IN 31 16 -ACK OUT 10 10 +BUSY OUT 11 11 +PAPER END OUT 12 12 +SELECT OUT 13 13 -FAULT OUT 32 15 GND 19-30 18-25 I can recommend you try and get the IBM Parallel Port FAQ. This FAQ is an excellent guide towards interfacing with the IBM PC Parallel Printer Port. It overcomes some of the IBM documentation errors and has been compiled from a cross correlatation of various sources including schematics to get a consistent and workable picture. It all contains information about hardware pinouts, differences between various types of adapted cards and lots of information about the setting of the software registers etc. It was compiled by Zhahai Stewart You can get it via email from There is a plain text version as well as an HTML version of the FAQ available on the net. The plain ASCII version is available at: Hypertext version: and More information on the Parallel Port available: Some more information on hardware/software interfacing using the PC parallel (printer) port is available from : Additional information about the Parallel Port can be obtained from : And also at: Look for the files *lpt.faq; ibmlpt.faq, tomlpt.faq, and krislpt.faq I hope that all these URL's are still valid, and that this info will help. Good luck Werner -- Werner Terreblanche http://www.aztec.co.za/users/werner wterreb@plessey.co.za (work) OR werner@aztec.co.za (home) Plessey SA, PO Box 30451, Tokai 7966, Cape Town, South Africa Tel +27 21 7102251 Fax +27 21 721278 Cell +27 837255164 ------------------------------------------------------------