# CMOS Inverter circuit

I want to design CMOS Inverter which gives:

0 volt input --> 5 V output

Any positive input voltage above threshold voltage --> 0 V output.

On simulating, it is giving me alternatively +2.5v and -2.5 at output and wave shape is also distorted. Why is it not giving +5 and 0 volt and why do we have distortion here.

Edit: Setting both signals to DC coupling

Now it is showing 5 V signal at oscilloscope, while the probe shows 2.5 V DC. Strange? and still there is distortion.

Note: I have to apply 5 V at input or bigger. Why is that? Threshold voltages of transistors are usually not that big.

The probe shows 2.5V dc because that is the dc equivalent value of a 5V square wave with 50% duty cycle.

The "distortion" is caused by capacitive coupling of the fast transient voltage on the input to the output through the gate capacitance of the MOSFETs. Try using a slower rise/fall time for the input.

I think the thresholds of these transistors are higher than you realize. The circuit seems to be working just fine to me.

• Thank you. I just checked that 2n7000 max threshold voltage is 3.0 volt while BST110 max threshold voltage is 3.5 volt. and I just checked that my CMOS circuit starts giving me output above 3.5 input volt. But i should make sure that my input voltage is equal to the VCC, in order to use it in saturation mode i.e as a switch. Giving input voltage less than VCC and above threshold voltage doesn't give us output voltage equal to VCC, and thus not act as a perfect switch. Besides, distortion is removed when i decreased the rise/fall time, as suggested by you. – Muhammad Naufil Jan 5 at 14:15

Start here.

Figure 1. Channel A is on AC coupling. B is on DC.

Set both to DC coupling.

See if that sorts out the distortion too. If not then add a second image and we'll have a look.

• Done. Have a look please – Muhammad Naufil Jan 5 at 12:42
• (1) Add the name of the simulator into your question. Someone may be familiar with it. I'm not. (2) Is the 7 V squarewave able to fully turn Q1 off when it is connected to +10 V? If you feed it with a 5 V squarewave then $V_G$ will alternate between -5 and -10 V relative to its source so it will never turn off. – Transistor Jan 5 at 13:04