Constant current source with XTR110AG - Page 1
Forum section: electronics / beginners

author: neuschs
author_rank: Contributor
timestamp: September 13, 2021, 02:33:48 pm
content: Hello to all !At first, please leave a reply, I'am relatively new to bigger curcuit design so please forgive mistakes.Most of the components i've selected in the upcoming curcuit are based on the stock that is available to me.My goal of the project was to create a constant current source with four ranges: 20mA, 100mA, 1A and 10A.(by switching the shunt resistor) With a dual voltage measurment or differential measurment for compensation of wire losses at higher current ranges.Because I've got some XTR110AG (normally used for voltage to current conversion of analog signals used in industry sensors and i/o expanders of plcs) lying around, I started designing a curcuit.Because I am quite interested into statistics, I've tried to analyze my measurments.In the attachement:input_curcuit.jpg, you can see my voltage divider for up to 50V input voltage and the range switching(done by relay) to 0 to 5V by connecting the input directly to the buffer amplifier.In the first prototype I've used Lm324 as OPs, but their offset voltage was a little scary high. So I changed to OP07.To protect the ADC (VOLTAGE_IN flag) i've limited the current with the 4k7 resistor by clamping the voltage via schottky diodes to ground and the reference voltage. - Is this the right procedure ?I've choosen the LT1011 comparator for overrange indication against the STM32L432KC(NUCLEO board).The bigger part and questions:Undercurrent_regulation.jpgi show the connection of the XTR110AG. The internal shunt resistor of the XTR is note precisely known, so I had the need to measure the shunt. (In my case 46 Ohm)But I can't choose my shunt resistors for the different ranges (10, 1, 0.1 Ohm) according. So my idea was to change the span adjust potentiometers for a digital potentiometer and calibrate the different ranges by different digital potentiometer values.I am using two irf9540 in parallel for easier heat ditribution.The switching of the different shunt resistors is done by the schematic shownshunt_switching.jpg.For feedback of the real current i wanted to use a INA138 highside shunt amplifier. (You can see inhigh_side_shunt_measurment.jpg).Reference voltage source is a REF02CP.dac.jpgis for completeness the MCP4921. The weird jumpers across the resistors and the in- and output of the op is for using different reference voltage sources (e.g. a 2.5V one, and the lowest input voltage range of the XTR110AG is 0..5V).Should I filter the analog signal going into the ADC ?I thought about using one of the buffer ops as an active filter.I am happy to hear your thoughts.PS: Buffer caps or on a different picture, I didn't included.And excuse my crappy english !GreeetingsSebi

author: Terry Bites
author_rank: Super Contributor
timestamp: September 13, 2021, 06:57:47 pm
content: Hi, I'm just calming down from trying to make a decent current source so all you amperes are in my prayers today. I've toyed with the unaffordable (even in my youth) XTR110AG before. I dont think its a good the chip for the job and its drifting rapidly into obsolescence. I'm sure TI will make up a 1K batch in 2030 if you have the cash. The nasty problem is the +3930 ppm/°C temperature of copper shunts. Can you live with a 4% change over a 10' temeprature rise? There are expensive solutions to this of course, luxury sense resistors from Vishay, Alpha, Riedon... etc. Its often preferable to switch between separate current sources to get precision across all ranges.If you are digitising your meaurements you can run a calibrate routine and get and rid of the trimpots. Use upstream over current protection to save your circuit. Always buffer and filter the ADC inputs. They dont just keep out of band stuff ruining your day, they are sacrificial in heavy weather conditions where as your ADC or micro platform probably isnt. I'd invest in better something a little better than a Nucleo to get more ADC and DAC channels. Code is cheap.Desined for the job accurate current sense amps with stunning CMRR are much better than the OP07 and resistors and probably cheaper. DIY diff amps always disappoint, trust me.In my current incarnation, I plan to use a "zero drift" sense amplifier. For example a LTC6102HV useable to 100V. And then add a simple control loop (its bound to get more complex!) with a N-MOS follower as shown in my diagram- which comes absolutley with no garuntees or protection components shown! I'm thinking to go higher than 36V i might try a LTC2057HV as the control amp. Use resistors (*) with the lowest tempco, absolute values dont matter as much as drift. This is configured as voltage controlled CCS. Io=Vref/Rset . I'm dreaming of course.....

author: capt bullshot
author_rank: Super Contributor
timestamp: September 13, 2021, 07:22:19 pm
content: Quote from: neuschs on September 13, 2021, 02:33:48 pmOK, using the components that are by chance available is a valid reason for tinkering ... I've done so before, too.But ... I don't see a point in using the XTR110 for this purpose, as you're not using any of its unique features at all. A simple OpAmp would do the job IMO.

author: neuschs
author_rank: Contributor
timestamp: September 13, 2021, 07:57:36 pm
content: Thank for your answer !QuoteThose are no copper shunts, I've choosen TyOhm SMW 2W FT/3 for 1 Ohm and 10 Ohm and for the 0.1 Ohm a Isabellenhütte PBV 0,1 0.5% 10W.QuoteI've got like 6 in DIP package and 10 in SMD packageQuoteSo you would rather choose internal ADCs over external micrchip ones (say tehy have same resolution like in this case) ?QuoteMaybe I have different expectation and plan on the precision of the curcuit (I guess my balancing between the quality of the components is additionally wrong)But just for tinkering around, and having a little fun with it, stuff like the LTC6102HV is a little bit expensive.And might not worth the money for me. Right now the only use for higher precision would bet to gather some diode and transistor curves (with external help).Ranges like 1A and 10A don't need be that precise, i mostly want to use them for driving higher power LEDs and stuff on my bench.At least with the internal shunt the XTR110AG should be relatively precise. But it only goes up to 20mA -.-QuoteWhich value of cutoff frequency should I use for calculation of an active filter (i'm looking for a sallen-key design).My thoughts were that the lowest frequency to allow should be the frequency I want to measure from the DUT (or changes in value, wouldn't call it a specific frequency) muiplied by two Nyquiest stuff ?