What sort of problems do you envisage with this opamp configuration? Is my design reasonable however?
I think there must be some advantages in opamp - most notably component count! (and maybe need for temp compensation??)
First of all, that op amp isn't rated to put out 100mA. In fact, they say the typical short circuit current is 105mA and can be as low as 70mA. Though you could use an external buffer transistor.
An op amp solution could certainly work. You'd have to play around with it a bit, though, it can be tricky to get right. (So can this, though!) Keep trying. It's not an unreasonable solution.
Another problem with the op amp solution is that the amplifier may saturate when set to zero output current (particularly with a buffer transistor, which permits it to only source and not sink), making the switching messy and slow. This could possibly be solved with a properly biased class AB output buffer. It needs to be able to sink current as well as source to allow it to balance itself at one particular point, rather than just "anything less than the transistor's threshold will do".
Yep, component count and the lower temperature dependence.
I will try to study your circuit. I am amazed that you came up with this in minutes. I dont undestand all of it.
I came up with it quickly because it's closely related to a couple things I've worked on recently. Hold on a minute, I'll write up an explanation of it. I don't want to just dump a complex circuit on you and say "off you go now!"
Working backwards, because it's less dangerous than
walking backwards: Q1 acts as a simple voltage-controlled current source: the base voltage is duplicated at the emitter (minus V
BE), and Ohm's law gives the output current.
D1+D5 acts as the voltage reference, with R3 as the load. A Zener diode can clamp and unclamp very fast. C1 and R4 compensate the capacitance of the K(D5)/B(Q1) node, allowing it to switch quickly. (C1 without R4 injects large current pulses through Q1's base.)
M2 and M1 act as a totem-pole switch to control that voltage reference. Q2 acts as a phase inverter, giving the input signal and its inverse to switch the totem pole transistors - it is operated between the active region and cutoff (never saturating), allowing it to run quickly. Q3/Q4 and Q5/Q6 drive the MOSFET gates.
M2's gate must be pulled about 4V above its source to switch it on, and its source must be able to reach the power supply voltage. Because of this, D4 is used to create a lower "power supply" for the output stage, giving some headroom above that to swing the gate.
Temperature compensation: Simple - the Zener diode is chosen to have the lowest temperature coefficient possible (5.6V and 5.1V are good), and D5 cancels out Q1be. Looking at the
datasheet shows that 5.1V is slightly better, so you might try that instead.