# Designing a 2-op-amp instrumentation amplifier

I have to design an instrumentation amplifier using 2 op-amps and I have the following specifications:

1. Use an LM324 quad op-amp
2. Use a single power supply of 7 V to power the op-amp and build the reference voltage.
3. Build a reference voltage using A3 from the schematic in order to:
3a. maximize the output dynamic of the instrumentation amplifier.
3b. Take into consideration the common-mode input dynamic.
3c. Allow both positive and negative inputs.
3d. Let's just say I need a gain of K for the instrumentation amplifier

I'm having problems designing the reference voltage. I considered the reference voltage to be half of the voltage output swing of the op-amp to maximize the output dynamic, but i do not understand how to take into account the common-mode input dynamic.

As per the data sheet, the common mode input dynamic is [0,7(supply)-1.5]. I understand that the common mode input dynamic tells us how much voltage you can apply to both the inverting and non-inverting pin in common to remain in the linear region of the op-amp. So, as per this all the inputs of the three op-amps should be within the common-mode. So do I calculate the voltages of all the inputs and constraint them to be within the common-mode range?

The output voltage of the instrumentation amplifier is given by the following:
After setting R1=R4 and R3=R2
Vo= K(V+ - V-) + Vref
where K is the gain given by (1+R2/R1)

Question:
How do i design the voltage reference in order to account for the input common mode range?
p.s
Any references on designing a single-rail instrumentation amplifier or on the common-mode input voltage range effects would be helpful.

it is necessary that both the input signals must be within the input common mode voltage range (Due to the inverting and non-inverting pin having the same voltage). So if i wanted to allow both negative and positive inputs like maybe a sine wave i would have to provide an offset to the input signals entering and ensure they are within the input common mode swing (maybe offset = half of the input common mode swing)
Vref does depend on the input common mode swing it seems to give us a lower bound for the Vref,
https://i.stack.imgur.com/67XE8.jpg

• Is this an educational (student/class) set of requirements? It helps to know.
– jonk
Oct 29, 2022 at 9:50
• @jonk yes i am a student in college, this is for my lab design. Oct 29, 2022 at 9:53
• What is the useful input common mode range of the op-amp? And for the output too? It's in the datasheet. Oct 29, 2022 at 10:21
• ti.com/lit/an/sboa281/sboa281.pdf
– user173271
Oct 29, 2022 at 11:32
• @James i did see this, but it does not mention how they accounted for the input common mode range for the Vref Oct 29, 2022 at 11:34

do I calculate the voltages of all the inputs and constraint them to be within the common-mode range?

No. $$\V_-\$$ and $$\V_+\$$ must be given. The inverting pins of A1 and A2 follow exactly the inputs (assuming linear and ideal operation - see diagram below), so the differential inputs must respect the common mode input range. Ideally, $$\V_{REF}\$$ has no effect on these inputs and it doesn't affect the voltages at the inverting pins of A1 and A2.

How do i design the voltage reference in order to account for the input common mode range?

You don't. You design $$\V_{REF}\$$ to make the output stay within the output voltage specs, given the differential gain and differential input voltage range. Ideally, the output voltage of this amplifier is not affected by the common mode voltage of the inputs.

Summary: to do 3a, better specs for 3b and 3c are needed. What is the "input dynamic"?

Further information (this goes beyond the given task). $$\V_{X}\$$ is affected by both $$\V_{REF}\$$ and $$\V_{-}\$$, so A1 output must also remain within the specs of the opamp, given these inputs.

You may find the equation for $$\V_{X}\$$ by applying superposition to the circuit formed by $$\R_{3}\$$, $$\R_{4}\$$ and A1, as follows:

1. Set $$\V_{REF} = 0\$$ and you have the first term for $$\V_{X}\$$ (non-inverting amplifier)
2. Set $$\V_{-} = 0\$$ and you have the second term for $$\V_{X}\$$ (inverting amplifier)
• Thank you for your answer, things seem to make sense now. So, it is only necessary that both the input signals must be within the input common mode voltage range (Due to the inverting and non-inverting pin having the same voltage). So if i wanted to allow both negative and positive inputs like maybe a sine wave i would have to provide an offset to the input signals entering and ensure they are within the input common mode swing (maybe offset = half of the input common mode swing). Oct 29, 2022 at 13:05
• Exactly. Perfect summary. Oct 29, 2022 at 13:07
• So basically, Vx the output of the first op-amp must also remain within the output voltage swing as an additional constraint along with the Vo=k(v1-v2)+Vref constraint. Oct 29, 2022 at 13:50
• It must. I've added details on how to calculate it. Oct 29, 2022 at 13:56
• That is why I decided to add the information, even without this internal constraint being mentioned so far. Oct 29, 2022 at 14:36

How do I design the voltage reference in order to account for the input common mode range?

You look at the LM324 data sheet: -

I've chosen the LM324-N version but, different versions say the same. The thing to note is that the upper limit for the input voltage range is V+ - 1.5 volts. So, in your circuit this will be 5.5 volts (7 volt supply).

You may think that's a bit of a jump going from a power rail (V+) of 30 volts with an upper input voltage range of 28.5 volts then making the assumption that it will be the same on a 7 volt power supply. This comes with experience; a lot of modern op-amps just say something like Vcc - 1.5 volts and that is fairly unambiguous but, I know from years of using these devices that it applies at any Vcc level.

So, that's the upper limit of your input common-mode voltage range.

The lower limit is simply 0 volts (as per the data sheet extract above).

So, I would be aiming to provide a reference voltage of about 2.75 volts thus allowing maximum symmetrical swing on an input. As a footnote, the output swing is pretty similar too: -

So, depending on output loading (and that includes feedback resistors), the LM324 is capable of typically working up to within 2 volts of the Vcc power rail. So, that means a typical upper limit of 5 volts (7 volt supply) and a typical lower limit of close to 0 volts. So, if you were thinking in terms of the output being centred at some voltage (the reference voltage), you might choose 2.5 volts instead of 2.75 volts.

• "So, I would be aiming to provide a reference voltage of about 2.75 volts thus allowing maximum symmetrical swing on an input. ". I dont understand what you did here, how does this allow a maximum symmetrical swing on an input. Oct 29, 2022 at 11:44
• @BonPi The value came from ((7-1.5)-0)/2 = 2.75, which represents the middle of the allowed input range (from the first table in the answer) Oct 29, 2022 at 11:49
• @devnull It makes perfect sense to me to place the Vref at the center of the Output Dynamic , but why do we do the same for the input dynamic? Oct 29, 2022 at 11:50
• @BonPi for a 7 volt supply, the legal limits for the input voltage is between 0 volts and +5.5 volts so, you want to have a mid-point bias of 2.75 volts thus allowing maximum symmetrical variation of input voltages from that mid-point. In effect, that midpoint becomes your "new 0 volt" point. Oct 29, 2022 at 11:51
• @BonPi you are designing an InAmp and, a manufactured InAmp has exactly the same issues. The inputs are floating and need biasing to some voltage level between 0 volts and 5.5 volts to make it work correctly. Whether it's your InAmp or an AD20, the target circuit that uses the InAmp has to bias the inputs correctly. Oct 29, 2022 at 12:46