
Driving a bidirectional pin in this manner requires that the controlling micro-
processor use two port pins (one input, one output), but it allows DC isolation of
the peripheral device or system. In most cases, you will want to use high-speed
optoisolators for an application like this. Either a diode/transistor or logic output
optoisolators may be used, but optoisolator U2, which connects directly to the
bidirectional pin, must have an open-collector output. The pullup resistor on the
bidirectional pin should be chosen to provide sufficient speed (avoiding excessive
rise time) without exceeding the drive capability of the pin. If optoisolator U2