Raffaele Rialdi wrote: > All you have to do from your PC software is to let for example the DSR > high. Then you can use a simple resistor or a 7805 to power your PIC > and the MAX232. Now there's a trap for young players! A 7805 has a drop-out voltage of 2 volts, so it only works down to 7V, while its quiescent current is rated at up to 5 mA, which is probably more than your circuit would draw! What you *actually* do is to take a diode from *each* sourcing line (RTS, TXD, DTR) to feed Vdd, which you buffer with a capacitor (100-200 µF) and regulate with a 5.1V Zener or shunt regulator across this. Now, you have also limited your positive excursion on TXD which you feed to the PIC as data through a resistor (10 k ohm or so). You do not need a series resistor as this will only introduce an unpredictable (certainly, not predictable from machine to machine) voltage drop and the RS-232 standard defines current limiting. Rate your Zener however on the possibility of as much as 60mA - this is 300mW at 5V, and of course the smallest usual Zeners are 450mW, so should be no problem. You may similarly derive a -5V supply. In fact, many mice use a -5V supply to power the PIC or Z8, and a positive supply to power the LEDs in the opto-interrupters (in series, of course). This allows an NPN transistor to control the data going back on the PC's RXD line. In general, a PNP transistor on Vdd can switch the RXD against either a resistor or current driver on the negative line. The other status lines should be grounded (*not* connected to either of these derived internal supplies which only wastes current) to prevent cable cross-talk generating spurious signals and possibly causing Status-change interrupts in the PC's UART. I realise most mice do not connect these lines at all which is OK as long as they are not wired in the cable and you use no extension! -- Cheers, Paul B.