I had a PCB made for a homebrew SBC but while waiting for the boards I discovered a bug. I have a 74HC138 output (I believe this is just normal push-pull) that I need to hook up to a CPU pin but I need it to be open-collector so other chips can drive it low as well (basically wire-AND.) Because this is going to be a kludge, I want to reduce the part count as much as humanly possible.
I have what I believe will do the job in 2 transistors: a PNP transistor acting as an inverter and an NPN transistor acting as the open-collector:
Can this be done with a single transistor?