4-20mA Current loop - Page 1
Forum section: electronics / beginners

author: jondow
author_rank: Contributor
timestamp: December 31, 2015, 01:52:11 am
content: I need help for calculating an 4-20mA current transmitter. I have a temperature sensor where I get 0.2V at lower range and 1.2V at higher range at the output. Now i want to transformate it in a current. 0.2V=4mA and 1.2V=20mA. Need something like this:https://industrialcircuits.wordpress.com/2014/07/28/industrial-4-20-ma-current-loop-measuring-circuits-basics-i/but dont know how i can calculate it.

author: jeroen79
author_rank: Frequent Contributor
timestamp: December 31, 2015, 09:11:52 am
content: You could make a linear voltage to current converter and add an offset to the input voltage.Just a matter y=a*x+b.

author: jondow
author_rank: Contributor
timestamp: December 31, 2015, 03:03:47 pm
content: delta(I)/delta(U), 16mA / 1VI(Umin)-Umin * a= 4mA - 0.2 * 16 = 0.8mA.=>IOut := 16 * Uin + 0.8 mA.Ok but how to do this as a circuit?

author: IanB
author_rank: Super Contributor
timestamp: December 31, 2015, 03:13:26 pm
content: Quote from: jondow on December 31, 2015, 01:52:11 amCommon industry standards for signal transmission are 4-20 mA or 1-5 V. In both cases note that low scale value is 20% of the full scale value.It turns out that your range of 0.2 V to 1.2 V also fits this pattern (0.2 is 20% of 1.2). This is good for you as you don't need any offset corrections. You can just use your signal as the reference for a variable output constant current driver (e.g. using an op-amp to drive the output current with feedback referenced to the input voltage).Are you familiar with op amp circuits at all? What level of electronics knowledge do you have?

author: Seekonk
author_rank: Super Contributor
timestamp: December 31, 2015, 03:14:59 pm
content: First question is this loop powered or can this conveter have its own power supply.

author: jondow
author_rank: Contributor
timestamp: December 31, 2015, 03:49:27 pm
content: Quote from: Seekonk on December 31, 2015, 03:14:59 pmNo, this circuit should power with the 4mA the sensor. So it dont have own suply.

author: IanB
author_rank: Super Contributor
timestamp: December 31, 2015, 04:04:21 pm
content: Quote from: jondow on December 31, 2015, 03:49:27 pmA 4-20 mA current transmitter has to transmit power. So it needs a power supply. One way to do this is to send three wires to the transmitter. Two of the wires carry the supply voltage to the transmitter (e.g. 24 V), and the third wire carries the 4-20 mA loop signal back to the remote receiver. At the transmitter you have your circuit that derives the 4-20 mA signal from the 24 V supply voltage and the temperature reading from the sensor.

author: ConKbot
author_rank: Super Contributor
timestamp: December 31, 2015, 06:09:11 pm
content: Quote from: IanB on December 31, 2015, 04:04:21 pmI thought a typical 4-20mA loop would a CV power supply with the transmitter and the receiver in series across the output? So you could locate the power supply wherever its most suited (I.e. at the RX if you have a remote sensor and a central receiver, or at the transmitter, if you got a central transmitter and a reciever/display/valve etc) at a remote locations? In either case the transmitter would run on <4mA and shunt the appropriate amount of current for its output, at whatever 'burden voltage' it requires. Same for loop powered recievers/displays, except they pass all the current, just add their own burden voltage.

author: ciccio
author_rank: Frequent Contributor
timestamp: December 31, 2015, 06:18:35 pm
content: Have a look at this:http://www.analog.com/media/en/reference-design-documentation/reference-designs/CN0314.pdfThe schematic applies to both voltage or current output sensors.Analog Devices can sell you a demo board.Or google for "4-20 mA loop transmitter schematic".Happy new year

author: IanB
author_rank: Super Contributor
timestamp: December 31, 2015, 07:08:48 pm
content: Quote from: ConKbot on December 31, 2015, 06:09:11 pmWe don't know too much about the OP's specific application. It may just be for hobby purposes, in which case it might not need the more sophisticated approach that you describe.If you have a stable 24 V supply provided to the transmitter this gives you many more options to power the transmitter circuitry rather than having to derive and convert power from the available 4 mA in the current loop.

author: retrolefty
author_rank: Super Contributor
timestamp: December 31, 2015, 07:46:39 pm
content: Quote from: IanB on December 31, 2015, 04:04:21 pmIn the vast amount of industrial 2-wire 4-20ma control loop field transmitters, the voltage source is coming from the 'house' (or receiver side of the loop. While it saves money to centralize the loop supply voltage, loop power source can be located at either end.

author: IanB
author_rank: Super Contributor
timestamp: December 31, 2015, 08:11:14 pm
content: Quote from: retrolefty on December 31, 2015, 07:46:39 pmYes, I understand it now. I haven't worked much with the details of how instrumentation works.So the receiver puts a voltage across the two wires of the loop, and the remote transmitter in the field regulates the current in the loop according to the measurement. Since a low scale reading on the transmitter corresponds to 4 mA, the transmitter effectively has 4 mA available for use to power its own circuits. It's quite elegant.

author: retrolefty
author_rank: Super Contributor
timestamp: December 31, 2015, 10:51:51 pm
content: Quote from: IanB on December 31, 2015, 08:11:14 pmElegant indeed. By using a current loop, any voltage drop caused by the wiring length is automatically compensated for, such that loops can run a 1,000 ft or more with no decrease in accuracy, a big advantage over passing simple voltage measurement over length.So main advantages are:1. Small amount of power is available (< 4ma) for powering the transmitter, allowing the sensor to be "loop powered"2. Long cable length can be run without effecting accuracy.3. A loop failure alarm is easy to implement if the loop ever goes less then 4 ma as in a broken/open loop wiring.

author: jondow
author_rank: Contributor
timestamp: January 02, 2016, 02:13:30 pm
content: In the attachments I have my schematic and the calculatiing. But how I can get R1,R2, R3, R4?Urmess,min=0,2v at 4mA and 1V at 20mA. Usignal is 0.2V at minumum and 1.2V at maximum.

author: garre
author_rank: Contributor
timestamp: January 02, 2016, 05:55:38 pm
content: Quote from: retrolefty on December 31, 2015, 10:51:51 pmThere is a fourth advantage to current loops. That is one of noise rejection. By using current instead of voltage the input resistance of the signal receiver is very low and thus not as susceptible to electrical interference like high resistance voltage meters..

author: Zero999
author_rank: Super Contributor
timestamp: January 02, 2016, 06:17:38 pm
content: Quote from: jondow on January 02, 2016, 02:13:30 pmWell, the problem with that circuit is the LM317 & LT1677 will take about 8mA.

author: Zero999
author_rank: Super Contributor
timestamp: January 02, 2016, 08:04:40 pm
content: You need to take into account the current taken by the regulator and the op-amp.

author: ciccio
author_rank: Frequent Contributor
timestamp: January 02, 2016, 08:10:08 pm
content: I'm not sure your schematic will work.First, as Hero999 pointed out, the voltage regulator will output 5 V over the two adjustment resistors, totalling 995 ohm, which correspond to 5 mA. This circuit will never draw less than that, so no 4mA.Second, please have a look at the schematic of the Analog Device application I've posted before:http://www.analog.com/media/en/reference-design-documentation/reference-designs/CN0314.pdfor to the many schematics you can find by simply googling.The output transistor (that could not necessary if you use a high current op-amp and play around with the schematic) must drive the 4/20 mA loop directly, not after a voltage regulator. If you set your maximum loop voltage (that means the DC voltage that powers the loop) to 24 V dc, that almost any op-amp will accept as single power supply, you do not need a voltage regulator: what you still need could be a reference for the sensor.If you have problem with analog circuits calculation, there are dedicated componente, like this one from TI :http://www.ti.com/lit/ds/symlink/xtr117.pdfor you can use a simpler schematics, like the one in the attached drawing, with the necessary modifications for your application.

author: jondow
author_rank: Contributor
timestamp: January 02, 2016, 10:41:14 pm
content: Thank you all for your supply. I have replaced the opamp with lt1495, it need only 1.5 µA and changed R5 to 1k and R6 to 2870R. And changed that with the output transistor voltage supply.QuoteThank you for the circuit, but there are no calculatings. How I can calculate them. I have found many circuits on the web but never seen a calculating.

author: Zero999
author_rank: Super Contributor
timestamp: January 03, 2016, 12:31:30 am
content: There's nothing wrong with connecting everything to the output of the regulator. You just need to take the current taken by the regulator into consideration. Fortunately the current used by the LM317 is predictable and easy to calculate. It's simply R1/Vref. Vref can be anywhere between 1.2V to 1.3V so trimming may be necessary.In the circuit I posted. The op-amp changes its output current to try to keep both the inverting and non-inverting inputs at the same voltage. Rs is the load on the op-amp, with Q1 acting as a buffer. In real life, you could omit Q1 and connect the output of each channel of the LM358 in parallel with a couple of resistors.Whatever voltage is applied to the non-inverting input appears across Rs and the current required to power the op-amp also goes through Rs so this is taken into account. The current taken by the op-amp circuit simply becomes Vin/Rs. Obviously there's a minimum current which is equal to the quiescent current of the op-amp and for the LM358 is no more than 1.2mA.In your circuit, you want the current drawn when Vin = 0.2V to be 4mA and when Vin = 1.2V 20mA.dI = 20mA - 4mA = 16mA = 0.016AdV = 1 - 0.2 = 1VUsing Ohm's law to calculate RsRs = dV/dI1.0/0.016 = 62.5The nearest standard E24 value is 62Ohm. If this isn't accurate enough then use 91R and 200R in parallel or 62R in series with 0.51R for Rs.Now with Rs = 62.5 the change in current will be correct 1.2/62.5 - 0.2/62.5 = 0.016A but the total current is too low I = 0.2/62.5= 0.0032A, rather than 0.004AThe easy way round this is to set the current through the LM317 to compensate for this:Ioffset = 0.004 - 0.0032 = 0.0008ACalculate R1 so the current through it is 0.0008AR1 = Vref/Ioffset = 1.25/0.0008 = 15625Ohms. I just used 1k6 as it's the nearest value. You may want to use 1k5 in series with a 220R trimmer resistor for calibration purposes.You should also use the LM317L because it has a lower minimum operating current than the LM317.

author: jondow
author_rank: Contributor
timestamp: January 03, 2016, 05:40:59 pm
content: Thank you Hero999, but there is one thing that we have to consider! I need 4mA when Vin is 0V and when it is 0.2V. Because there must be everytime 4mA to power up the conected sensor. Vin is in a way my sensor that givex me 0.2V at lower range and 1.2V at higher range. But the 4mA have to be always be there.This is done with the 2nd ground, in ciccio attachments is it so done but there is no calculating.There are another links but i dont see the calculating:https://industrialcircuits.wordpress.com/2014/07/28/industrial-4-20-ma-current-loop-measuring-circuits-basics-i/http://sound.westhost.com/appnotes/an011.htmhttps://www.maximintegrated.com/en/app-notes/index.mvp/id/5610

author: Zero999
author_rank: Super Contributor
timestamp: January 03, 2016, 06:29:05 pm
content: I don't understand what you're saying.The fact the current will fall below 4mA when the sensor's voltage drops below 0.2V will just give an error.The only problem I can see, with the circuit I posted, is it won't compensate for any power taken by the sensor.Do you have a part number or datasheet for the sensor?

author: jondow
author_rank: Contributor
timestamp: January 03, 2016, 06:35:21 pm
content: Quote from: Hero999 on January 03, 2016, 06:29:05 pmYes thats what I am talking about. I need a circuit that this do.

author: jondow
author_rank: Contributor
timestamp: January 03, 2016, 08:09:56 pm
content: Now i have used this schematic: Basic, analog input, 2 wire, 4-20 mA loop powered transmitter. Fromhttps://industrialcircuits.wordpress.com/2014/07/28/industrial-4-20-ma-current-loop-measuring-circuits-basics-i/Î have choosen: Rsense=5ohm, R3=10k, Vs=5v.From the equations R2= 2.5MSignal 4,5V max input --->R1=562500Ohm.But it dont work.. I get 0Ma through rsense.

author: Zero999
author_rank: Super Contributor
timestamp: January 03, 2016, 10:48:43 pm
content: Err what is that?Here's what I've come up with. RL represents the current taken by the sensor. It will work so long as the current taken by the sensor is under 3.8mA - the current taken by the op-amp.

author: jondow
author_rank: Contributor
timestamp: January 04, 2016, 08:03:31 pm
content: Where do you get R5. On the schematic IN- goes to ground. not to R5. I am speaking about: Basic, analog input, 2 wire, 4-20 mA loop powered transmitter.Can you write your calculatings? I get other numbers.

author: Seekonk
author_rank: Super Contributor
timestamp: January 04, 2016, 08:33:15 pm
content: Hero, look where the emitter is connected.

author: Zero999
author_rank: Super Contributor
timestamp: January 04, 2016, 08:57:01 pm
content: Quote from: jondow on January 04, 2016, 08:03:31 pmR5 compensates for the op-amp bias currents. It's roughly equal to R3 & R4 in parallel.The circuit works on the same principle as the other circuit I posted. The op-amp adjusts the voltage on its output to keep its inputs at 0V. Because the op-amp can't work when either of its inputs are below 0V, a potential divider consisting of R3 & R4 is used. When the voltage at the non-inverting input is 0V, then the voltage on the negative side of Rs will the same, but opposite polarity to the input voltage. The current through Rs will be equal to -V/Rs. The current taken by the op-amp and your sensor both passes through Rs so this is compensated for. .Quote from: Seekonk on January 04, 2016, 08:33:15 pmAre you talking about my schematic? If so , what's your point?

author: jondow
author_rank: Contributor
timestamp: January 04, 2016, 09:47:34 pm
content: Quote from: Hero999 on January 04, 2016, 08:57:01 pmAh I see. But at Vin=0V I get only 2.6mA.

author: C
author_rank: Super Contributor
timestamp: January 04, 2016, 11:00:51 pm
content: The loop is a power source, a 4-20ma receiver, wire resistance, 4-20Ma transmitter, wire resistance and back to power source.orThe loop is a power source, wire resistance, 4-20Ma transmitter, wire resistance, a 4-20ma receiver and back to power source.Look at the extremes1. 20Ma out what is min voltage needed across your 4-20ma transmitter.2. 4Ma out what is max voltage allowed across your 4-20ma transmitter.3. What Bandwidth of signals is supported.With the limits set by #1 & #2 how linear is the change?In real world all kinds of things happen.V1 could be nice DC or could have all kinds of noise added. A long run could pick up a lot of AC power noise or other noise.Think there is a need to look at more than just static DC

author: Zero999
author_rank: Super Contributor
timestamp: January 04, 2016, 11:18:18 pm
content: Quote from: jondow on January 04, 2016, 09:47:34 pmHow did you calculate that?Then Vin=0 the current taken from the power supply will be equal to the current through the LM317 circuit plus the quiescent current taken by the op-amp and the sensor.

author: jondow
author_rank: Contributor
timestamp: January 04, 2016, 11:56:07 pm
content: From simulating with ltspcie. Because I need everytime 4mA avaliable. I actually have found an working schematic (in the Attachments), but I dont know how to calculate R3, R4, R5, R6. Thats the perfekt working circuit, but wihout explanating how to calculate.

author: Zero999
author_rank: Super Contributor
timestamp: January 05, 2016, 01:25:33 pm
content: I don't have LTSpice on the PC I'm using at the moment so can't see that schematic.Why do you need 4mA when Vin = 0, when the lowest input voltage you expect to see on the sensor is 0.2V? If the sensor becomes disconnected and the output voltage falls below 0.2V, causing the current to fall below 4mA, then this would trigger an error in the current loop monitor and error detection is one of the main advantages of using a current loop.If you need 4mA all the time then why not just scale it from 4mA when Vin = 0V to 20mA when Vin = 1.2V? That would make it much easier to design.

author: v8dave
author_rank: Regular Contributor
timestamp: January 05, 2016, 02:21:45 pm
content: As long as your sensor draws far less than 4mA then simply use an XTR115 or XTR116 to convert the sensor output to current.Texas Instruments have a version of Tina and a model of the XTR115/6 you can use to test your design with.

author: Zero999
author_rank: Super Contributor
timestamp: January 05, 2016, 04:47:30 pm
content: Quote from: v8dave on January 05, 2016, 02:21:45 pmYes, that's a good idea.The problem is, it will still be tricky to get 4mA, when the input voltage is between 0 and 0.2V, then increase it linearly from 4mA to 20mA, as the voltage rises to from 0.2V to 1.2V.It could be possible to set the offset current to 4mA and the gain so the current will be 24mA, when Vin = 1.2V and subtract 0.2V from the input voltage using another op-amp. The input voltage would then be scaled to 0 to 1V but won't be able to go below zero, as the op-amp will have no negative rail. As Vin is between 0V to 0.2V, the output of the op-amp will be still 0V but as the input increases further, the output voltage of the op-amp will be equal Vin - 0.2V.As I said above, to avoid this complexity, the original poster should consider dropping the 4mA between 0V and 0.2V requirement.

author: jondow
author_rank: Contributor
timestamp: January 05, 2016, 04:53:58 pm
content: Quote from: Hero999 on January 05, 2016, 01:25:33 pmOkay have a picture attached. There ist the signal low=2.5V=4ma, high=5V=20ma and 0V=4mA.Quote from: Hero999I cant drop it, because its leading standard for industrial sensors.Quote

author: Zero999
author_rank: Super Contributor
timestamp: January 05, 2016, 05:32:35 pm
content: Quote from: jondow on January 05, 2016, 04:53:58 pmThat only works because the current in R1 gives the minimum current of just under 4mA, with the rest being taken by the op-amp. What about the current taken by your sensor? Any current taken by your sensor will be added on to the 4mA.QuoteI think you've misunderstood.I didn't mean you should scrap minimum current of 4mA. I meant the voltage should be scaled between 0V and 1.2V to 4mA and 20mA. It's starting at 0.2V, rather than 0V, which is creating the additional complexity.

author: jondow
author_rank: Contributor
timestamp: January 05, 2016, 05:51:28 pm
content: Quote from: Hero999 on January 05, 2016, 05:32:35 pmYou are right! But this problem have your schematic too! If I change RL from 2k2 to a lower value then there is additional current added to the 4mA.I canQuote from: Hero999I think thats not a problem, I can scale my Signal voltage from 0V (0%) to 1.2 or 4V or whatever (100%). But i have only one positive supply.

author: Zero999
author_rank: Super Contributor
timestamp: January 05, 2016, 11:48:23 pm
content: Quote from: jondow on January 05, 2016, 05:51:28 pmOf course, changing the value to anything lower will cause it to draw more current. However increasing the value will no longer cause the current to fall.QuoteThat makes it much easier then.

author: v8dave
author_rank: Regular Contributor
timestamp: January 06, 2016, 01:34:31 am
content: Quote from: Hero999 on January 05, 2016, 04:47:30 pmI see your point. I loaded up the simulation in Tina and I could not get any offset or range to work with with 0.2 offset.

author: jondow
author_rank: Contributor
timestamp: January 11, 2016, 04:42:10 pm
content: Have found this Howland-source:http://www.elektronikpraxis.vogel.de/analogtechnik/articles/397228/Have used the 2nd Equations. It works fine with input signal 1 to 5V I have calculated it that at 1V input I have 4mA and at 5V I have 20mA. But i forgot that I must have 4mA at 0V input too!Do you think it is possible to mod this circuit that I get 4mA at input 0V too? I have R1=R3 2750 ohm, R2= 1k, R4 1k1, R5=100.

author: Zero999
author_rank: Super Contributor
timestamp: January 11, 2016, 11:14:01 pm
content: You could scale the input voltage from 0 to 5V to 1 to 5V with a potential divider but you'll need a buffer to mimise the effects of loading.

author: meeder
author_rank: Regular Contributor
timestamp: January 11, 2016, 11:21:37 pm
content: You could use 3.8mA for 0V input. 3.8mA and 22mA are the default error currents for 4-20mA loops. When the instruments is in a fault state it will set the output to either 3.8 or 22mA so the PLC guys can trigger an alarm.

author: jondow
author_rank: Contributor
timestamp: January 16, 2016, 08:42:29 pm
content: I have now found the best working circuit. It works from 2.5V to 5V V_signal. R3 and R4 is a voltage divider sets the voltage at opam minus to 0.5V because lt317_out is 5V. With R5 I set the initial current of 4mA. At v_signal 0V I get 4mA.But how to calculate R1 and R2 to change v_signal maybe from 1V to 5V? How does it work?