Hi everyone,
A couple of months ago I made a
post asking about an IC to control an array of Charlieplexed LEDs -this post is not about multiplexing-. After much study and reading (I must emphasize how useful is
The Art of Electronics by Paul Horowitz) I arrived at the configuration that you can see in the schematic below.

There you can see a typical Push-Pull configuration that follows the truth table shown, where:
- H is HIGH or that particular OUT terminal is working as a source
- S-T stands for shoot-through (something totally unwanted)
- L is LOW or that particular OUT terminal is sinking
- Z stands for High Impedance, where that particular OUT terminal is -should- be floating.
So far the simulation runs okay, and only two GPIOS are used to control each OUT.
Now looking for tri-state configurations, I found the following diagram that seems to use BJTs instead of MOSFETs.

Quoting the description of the behavior
When enabled the signal QP12 and QN12 are on the inverter formed by QP11 and QN11 can drive the output.
In the disabled state QP12 and QN12 disconnect the inverter from the supply and the output is in a high impedance state regardless of the input signal.
That led me to simulate the following configuration but, as the first one, with MOSFETs, which led me to this schematic:

Here I don't attach a truth table since the simulated
behavior is the same, only with more components.
Note1: Switches S1, 2, 3, and 4 are just for simulation simplicity, not considered in the final design.
Note2: Reduction of GPIOS might be achieved using an inverter (not gate) with GPIO1 and GPIO2 and shorting GPIO_01 and GPIO_OE2, thus having only a GPIO for enable/disable (~ enable/HIGH-Z) and other to switch between H and L.
Now, my question:
- Are the circuits equivalent? With that I mean, is there an extra functionality that the second design might achieve that I'm not seeing? or more broadly, I'm overlooking something?
- Is there a reason to choose BJTs over MOSFETs when using GPIOS?
- Can the HIGH-Z state be achieved with both MOSFETS off?
Some quick questions that you might be asking:
- Why 12 volts for LEDs?
Line resistance is very high (Simulated by R2), thus to supply the required current and the LEDs Forward voltage a supply of 12V is assumed - How many terminals (out) do you need?
arrays can be as large as 150 LEDs, thus up to13 terminals might be needed. - Can you provide the MOSFET datasheet?
Attached as pdf
I hope everything is clear,