# How does this circuit work / What's its function? (PNP transistors array)

Discussion in 'General Electronics Chat' started by jkcobain, Aug 29, 2016.

1. ### jkcobain Thread Starter Member

Jun 8, 2014
40
5
Hello guys, I need help to find out the function of this circuit. I'm studying the MDB protocol and I found this schematic that I don't understand. I simulated it in proteus, and the output voltage is always zero, either the input is low or high (or probably I'm simulating wrongly). Here it is:

It is part of a serial communication, where (5) is the signal out for the peripheral. And the resistor in the left side comes from the master Tx.

Based on my knowledge, and the other part of the circuit (https://www.namanow.org/images/pdfs/technology/mdb_version_4-2.pdf page 60), I would think it is a kind of pull down resistor, but as I said before, I don't understand the function, and (5) is always zero. I hope you guys can help me.

Thank you very much in advance!!

2. ### RichardO Well-Known Member

May 4, 2013
1,341
429
This circuit acts as a logic inverter with current limiting. If the output is shorted to ground no harm is done to the inverter.

By the way, it is always best to show your the exact circuit you have a question about. In this case, someone will be able to help you learn why your simulation does not work.

atferrari and jkcobain like this.
3. ### jkcobain Thread Starter Member

Jun 8, 2014
40
5
Thank you RichardO! I'm going to read something about that function and hopefully I understand the circuit!

My simulation in proteus:

(Since I didn't even know nor imagine the function, I picked the resistors based on an internet circuit for the same application.)

4. ### RichardO Well-Known Member

May 4, 2013
1,341
429
Now I see. You need to replace your switch with a square wave the goes from 0 volts to 5 volts. This will give a square wave across the 20K resistor.

With R1 equal to 12 ohms the current will limit at about 0.66 volts /12 ohms = 56ma. If you lower R3 to a smaller value such as 100 ohms, the output voltage will drop. Since the current is limited, the output voltage would be 100 ohms * 56ma = 0.56 volts.

5. ### crutschow Expert

Mar 14, 2008
13,505
3,376
You need to do as RichardO suggested.
The switch connection you show will always give a zero output if Tx is 5V since the switch being open is the same as applying 5V to the input.
If you set Tx to ground, then pushing the button will cause a voltage high on the output.

6. ### jkcobain Thread Starter Member

Jun 8, 2014
40
5
Thank you very much! It worked now.

The other mistake is to have the voltage and current probes connected simultaneosly; only current probe works that way, voltage probe always is zero. So I have to measure current and voltage separately.

What I still don't get is the function of Q1, I don't understand why it has to be there. Hope you can help!

7. ### crutschow Expert

Mar 14, 2008
13,505
3,376
As RichardO stated, it's a current limit circuit to avoid zapping transistor Q2 if the output is shorted to ground.
Q1 starts to turn on when the current increases to the point where the voltage across R1 is about 0.65V (Vbe turn-on voltage).
This pulls current away from Q2's base (starves the base), which limits its current.
The current limit is about 0.65V / R1.

jkcobain likes this.
8. ### jkcobain Thread Starter Member

Jun 8, 2014
40
5
I understand, everything is clear now. Thank you very much!!