# calculating maximum sense speed of amplified phototransistor circuit

I made the following photo-transistor circuit to sense light with the exact parts shown. Resistors are 5% tolerance 1/4 watt. The circuit does work, but what I would like to know is how do I calculate the bandwidth of the circuit as it is now? By bandwidth, I mean the baud rate (bits per second).

From what I understand from the internet, transistors exhibit miller effect capacitance and logic gates experience propagation delays so is it as simple as multiplying the total miller capacitance by the total resistance of all resistors then adding the nand gate propagation delay? or am I missing something?

VCC here is +5VDC fed from a regulated power supply.

And if my theory is correct, then could I convert the 2.2K base resistor to 100 ohms safely and gain better speed without anything overheating? The reason why I want the resistor in the first place is because in the actual project, the photo-transistor will be manually plugged in after the rest of the circuit is complete and if some goof connects a pin to VCC and its not the ground pin, then the base resistor will be connected to VCC which to me is better than a direct connection from base to VCC.

Sorry, but the people I work with are newbies.

• Use a simulator is my advice. The Miller capacitor interacts with the 470 kohm resistor mainly so lowering the 2k2 will be less than ideal but will clearly result in more gain. – Andy aka May 26 '18 at 9:28

$$f_c \approx \frac{1}{2\pi\cdot R_{FB}C_{FB}}$$
In your case, $C_{FB}$ is indeed the Miller capacitance of Q1. $R_{FB}$ is the $470k\Omega$ feedback resistor. According to the datasheet, the 2N3904 has a collector-base capacitance of approximately $4pF$, which leads to a $BW \approx 85MHz$.
The input of the TIA (the base of Q1) is kept constant. The current through T1 is amplified by the TIA and converted into the output voltage. By decreasing the $2.2k\Omega$ resistor, you will probably not improve speed by much. If you decide to put the phototransistor between $V_{CC}$ and the input instead of ground, I have to warn you that you will probably not get any output. You will reverse the direction of the detected photocurrent, and this will make the output voltage of the TIA swing in the wrong direction.
You may also note that the photodetector has an associated bandwidth by itself. The PT334-6C has a rise and fall time $t_r = t_f \approx 15\mu s$, which is approximately the same as a $BW \approx \frac{0.35}{t_r} \approx 15kHz$. So it is possible that the phototransistor is the most limiting factor for speed in your circuit.