Programmable 4-20mA/0-10V signal transmitter tweaks

Thread Starter

arrain

Joined Mar 28, 2019
20
Hi, I need to design an accurate and durable 4-20mA and 0-10V digital signal transmitter. I found many examples on the web and on this forum, but I can't get them working properly with 0-3.3V input signal. Device's requirements:
  • Rpi zero/nano as a MCU
  • Powered by a Li-Ion battery, through 24V step-up converter for the current loop and 5V linear voltage regulator for the RPI
  • grounded load, typically 600R
  • input control signal from PWM or DAC (0-3.3V)
I designed a circuit, but It seems like it might be over-complicated. U5 is summing input voltage (PWM/DAC) and 0.825V from R1/R2 voltage divider, which sets 4mA offset. U6 converts given input from ground reference to Vcc reference and U7 is the final current regulator, adjusting current at R5. U4 is a simple amplifier with a gain of 3 to output 0-10V signal. Simulation in LTSpice looks promising but it gives a current loop range of about 4.5-19.5mA. These are the things i would like to clarify:
  • R1, R2, R5 are crucial for the precision of the device, but it's hard to find resistance values matching needed ratios. Problem can be solved with trimmer potentiometers but maybe there is other, simpler solution.
  • Most of the circuit comes from the "Art of Electronics" rev 2 (U6 and U7 circuits, photo in the attachment); I don't understand how R3 and R4 affect output current and therefore can't calculate correct resistance values for them, it seems like it's the main cause of the malfunction of the transmitter
  • I found a great example circuit here, but I can't get it working with 0-3.3V properly (with 0-5V either btw), won't describe the attempt here since I am curious how to get my own circuit working. However, it uses only 2 Opamps, thus my previous complaint about complexity of my design
Any feedback about my circuit would help a lot, I'm stuck with a lot of examples found on the web, but can't put them together to meet my requirements. Attachments: circuit and Spice simulation, photo of the circuit from the "Art of Electronics"
 

Attachments

Thread Starter

arrain

Joined Mar 28, 2019
20
Thanks for the chip suggestions, I am definately going to order them and try them out, but does anyone know how to adjust R3 and R4 resistances? It would be really nice to make this circuit working and compare it with the chips you guys are suggesting.
 

Thread Starter

arrain

Joined Mar 28, 2019
20
hi,,
Try it, if its a problem, see what can do.;)
E
EDIT:
@arrain

Modified the circuit for 3.3Vin, I would make the 4k7 , a fixed 3k3 and say 5k trim pot.
Thank you, I guess my struggle is done, two opamps sounds better than three :) There is a chance I will stick with one of those XTR's, learned a lot about opamps though.
 

crutschow

Joined Mar 14, 2008
25,274
That's interesting, I was sure it has to be something with those two resistors, thank you for finding the real cause. LTspice is always one step ahead of me...
If you look at the two input voltages of U7 you will see that they deviate from each other around 4mA, whereas the two voltages should be essentially identical over the full current range if the op amp feedback loop is properly operating.
That showed something was wrong with the op amp operation.
Whether this is a real problem or an op amp model problem can only be determined with a real circuit.
 
Last edited:

Thread Starter

arrain

Joined Mar 28, 2019
20
If you look at the two input voltages of U7 you will see that they deviate from each other around 4mA, whereas the two voltages should be essentially identical over the full current range if the op amp feedback loop is properly operating.
That showed something was wrong with the op amp operation.
Whether this is a real problem or an op amp model problem can only be determined with a real circuit.
That's strange, since U6's inputs are equal and it is the same model as U7. Anyway, I am going to build XTR circuit, the one suggested by ericgibbs and the one I posted. We'll see how much they differ in operation.
 

Thread Starter

arrain

Joined Mar 28, 2019
20
hi,,
Try it, if its a problem, see what can do.;)
E
EDIT:
@arrain

Modified the circuit for 3.3Vin, I would make the 4k7 , a fixed 3k3 and say 5k trim pot.
Could you explain what J1 is responsible for? And is it possible to replace it with some combination of NPN/PNP transistors?
 
Top