Electronic load kit - feature ideas? - Page 1
Forum section: electronics / projects

author: c4757p
author_rank: Super Contributor
timestamp: January 23, 2013, 01:54:45 am
content: I'd like to make a kit for a DC electronic load. I'm sure there are a few out there, but I've been restoring a few old Heathkit items lately and I've been so impressed by the general quality (not just the hardware, but the documentation as well) that I decided I want to try to put together something just as good. Usable features for actual work and comprehensive documentation. I want to know - does anybody have thoughts about specifications, features, etc? Tentative specifications:3-digit resolution, constant current ranges from 100uA to 10A50W and 100W options (additional load transistor and circuitry that can be omitted)100V maximum inputOvervoltage and reverse polarity protectionDigitally controlled constant power/constant resistance (low bandwidth, but fine for battery discharge, etc)SCPI over isolated USB (serial emu) for computer control, also optional for reduced costIncluded software supports discharge profiling, cutoff voltage, etcSelf-calibration with external power supply and ammeterAll through-hole constructionAny of this too much, or overkill? Any suggestions for additional features? And I'dlovethoughts on how to design the front panel interface, I want it to be easy to use.

author: robrenz
author_rank: Super Contributor
timestamp: January 23, 2013, 02:12:01 am
content: What happened to constant current?

author: c4757p
author_rank: Super Contributor
timestamp: January 23, 2013, 02:14:29 am
content: QuoteIt is primarily a constant-current load. Other modes are built on top of that. (I guess I should have included that in the list. Will edit)

author: c4757p
author_rank: Super Contributor
timestamp: January 23, 2013, 02:18:38 am
content: Quick question: For the 10A and 1A ranges, is a simple wire shunt acceptable for measuring current? I know the tempco is crap, but a quick look at Mouser suggests that tempco generally is crap for higher-current shunts, even the "proper" ones, unless they are quite expensive. Many multimeters seem to get away with a wire shunt and do just fine. Would the accuracy of that be considered too poor?

author: robrenz
author_rank: Super Contributor
timestamp: January 23, 2013, 04:12:15 am
content: Just because it is just a wire does not mean that it is not made from low tempco material. How accurate do you want the loading to be? from that you can calculate how accurate the shunt needs to be. that must include the tempco of the shunt and its operating temp at max load.

author: c4757p
author_rank: Super Contributor
timestamp: January 23, 2013, 04:28:55 am
content: Yeah, good point, I know. Should have been able to figure it out for myselfI feel a bit foolish since I just commented on another thread about temperature coefficient and pretty much said what you just said...

author: lgbeno
author_rank: Frequent Contributor
timestamp: January 23, 2013, 12:55:40 pm
content: Personally I'd rather have a physically smaller design then have it be all through hole. Tthis would also afford you use of more modern components that are only available in smt. I've been working on some motor stuff and would like to use a load like this to use as a dyno. So basically have two motors, one being driven by a drive then the other one would be rectified and loaded by this electronic load. Then I would change the load dynamically and see how the drive performs.Personally, I would keep to front panel simple and focus on features controlled via USB. It's going to be difficult to do much more than dial in a static constant current setting and monitor current via a front panel. Better to shift the profiling and stuff to USB. I don't know much about scipi but is it a good fit or would you be better suited to custom design a protocol for your load?

author: c4757p
author_rank: Super Contributor
timestamp: January 23, 2013, 01:11:52 pm
content: I still want through-hole. I too find SMD easy, but a lot of people find SMD intimidating. I will attach the few SMD-only parts making the kit myself. It won't be able to be all that small anyway, since it needs a heat sink and fan capable of 50 or 100 W.The front panel will be very simple. Probably just CC, CR, CP. But I wanted to know what people thought would be a good interface for that. Just a rotary encoder? Rotary encoder plus digit selectors? Pot scanned by the ADC? (This is what my old Tektronix oscilloscope does.) Even a keypad? (Probably overkill for just three digits.) Personally I like the encoder plus selector buttons, so you can choose the increment to be 1/10, 1/100, 1/1000 of full range rather than to have to sit there spinning the knob for a while to get to 950mA.SCPI is simple. I could make a custom protocol but there isn't much point in that, and using an established one adds to the feel of polish that I am going for.

author: Harvs
author_rank: Super Contributor
timestamp: January 23, 2013, 10:55:55 pm
content: Have a look at the specs of the 150W BK Precision load, or the old Agilent 6060B. I found that was a good starting point when I started mine (which is now up to rev 3, and cursed to say I'm still changing things.)I note you haven't actually put any specs in the accuracy, regulation, drop out voltage etc. This will govern how expensive and hard it is. From building mine, I figure you've got two ways of doing this, either properly where you get some reasonable accuracy and you'll find it wont be all that cheap. Or to basically do a kit version with uC control of what most people on here have been building, which you can do quite cheaply, but accuracy is going to be poor.Your biggest problem is going to be finding a shunt off the shelf to do what you want. Have a look at this thread:https://www.eevblog.com/forum/projects/source-for-low-tempco-current-sense-resistors/End story was I couldn't find anything like what all the commercial eloads use off the shelf. Once I get more time I'm going to be attempting to make my own out of Cupton wire.I haven't looked into what's available in through hole parts in ages. But can you get decent cheap DACs and ADCs in through hole? Choosing the right DAC and ADC can make the rest of the job a heck of a lot easier.

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 12:24:36 am
content: Sorry, I do have more specs, just didn't list them. (They are of course subject to change at this time, but I doubt they will)1% accuracy from the 100uA range to the 1A range, 5% on the 10A range. I measured the dropout to be around 2-3V for the full 10A load (depending on the choice of MOSFET, I haven't finished choosing), around 1V at the top of the 100uA range. A big chunk of that is the bigass diode I am using for reverse polarity protection - I may consider removing that, or just noting in the assembly instructions that it can be replaced by a wire shunt to lose about 0.8-0.9V of dropout. I was able to come up with equations to adjust for accuracy problems and easily achieve the 1% (I don't really care to get it better than that), and the MCU can easily run these internally. This is what I meant by self-cal. The self-cal routine will run a few choice currents on all ranges and ask for the value to be input from an ammeter, and then it can compute the calibration constants.I plan to usethisfor the 10A and 1A ranges, does that seem OK? (I've been using a piece of copper wire as the shunt, which obviously has abominable temperature coefficient, but otherwise, the 10m value is working fine, I achieve target resolution and accuracy, even with just an LM324 as the driving op amp. No problems multiplying by ten for the 1A range from the same shunt either, it just needs a different set of cal constants.) I'm using regular metal film resistors for the larger ranges - even at 100ppm/deg.C, the drift is only 0.5% for a 50 degree rise, and because of the small values, temperature rise will be small. The highest current on these resistors will be 100mA, and that is through a 1 Ohm resistor, for a 10mW dissipation.I will use the MCP4921 12-bit DAC. $2 in small quantity, through-hole or SMD. (I don't mind a couple SMD parts here or there, as long as the majority are not. I will attach them myself as part of packaging the kits.) 12 bit resolution for a three-digit instrument gives four discrete values per digit to allow room for internal calibration adjustments. For an ADC I will use the built-in 12-bit ADC on the microcontroller (haven't finished selecting one, but it will be one of the PICs with 12-bit ADC resolution). Both will read off an ISL21070 30ppm/deg.C reference.

author: saturation
author_rank: Super Contributor
timestamp: January 24, 2013, 02:06:48 am
content: I wish you success. We could use a cost effective and capable eload that can rival the $350 Chinese Array 3710a eload. What makes kits difficult is that if the Chinese clone it, the price of assembled items can rival western sourced kits very easily.For those interested only is CC, there is this US designed $160 item, no Chinese equivalent because of the niche this device occupies:http://www.westmountainradio.com/product_info.php?products_id=cba4

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 02:25:58 am
content: My dream (probably not really realistic) is that there might be a (niche) market for this sort of thing because of its nature: very well documented kit. Some peoplelikekits - there's a lot of theory in the margin notes in the manual that I'm writing, as well as a pretty complete theory of operation section and full schematics, block diagrams, protocol documentation, example source code, and even a guide to writing custom firmware, and I hope to have the time to write a well-written program to go with it rather than just a quick demo (I'm a pretty competent programmer). Of course they could justcopyit all, seeing as I wouldn't have much legal recourse if they're in China or something.Really, I don't hope to make a living on this sort of thing - it'd be great if I could, though - it'd be nice enough to break even on the development costs. When I get out of school I can get a real job andthendrudge through the rest of my life fighting Chinese knockoffs.Hopefully I can keep doing this as a hobby.

author: Harvs
author_rank: Super Contributor
timestamp: January 24, 2013, 05:33:49 am
content: I recon your spec needs some work.2-3V dropout on the 10A range is far too high. There's a reason why the BK precision load has a fixed 25mOhm resistance + overhead of a hundred odd mV. At 10A that gives a drop out around 350mV, which is still below pretty much anything you need to load. Testing batteries and DC-DC converters often needs loading down to around 0.8V with substantial currents. Other than your reverse protection diode, I don't know where you're loosing all that range? At 2A mine drops out at around 150mV and that's with a 50mOhm shunt.5% on the 10A range is far too wide an accuracy to be honest. But you need to break this down further into regulation, drift etc. Initial absolute accuracy is quite easy to cal out, the problems start occurring when everything gets hot during operation. Quite unlike a DMM, you need an eLoad to be able to hold a high current for a prolonged period of time. e.g. if you wanted to do a 1C discharge test on a D-cell NiMH battery, that's going to be 10A @ 1V continuous for an hour, which you're multimeter wont be accurate for but the commercial eloads are spec'd for this.I'd suggest before you get too far down this track of building a kit, come up with a spec based on what the commercial eloads have (they are spec'd the way they are for a reason.) Then build a error budget and start adding up all your errors and see where you can and can't meet it. You need to include all the circuit errors from voltage references, ADC and DAC INL/DNL, op-amp offset, drift etc etc etc.If you don't do all of this, take the other option of just making something of low accuracy and cheap. I personally don't like the idea of a mid-priced eload kit that you cant rely on.What were you're plans for a case? That's another area I've struggled to come up with a good idea. Making a one off is easy enough in the shed. Making a truck load is also easy enough (i.e. getting it manufactured.) Just making 10-100x odd isn't so simple when you need to deal with large heatsinks.

author: EEVblog
author_rank: Unknown
timestamp: January 24, 2013, 08:57:55 am
content: Quote from: c4757p on January 24, 2013, 12:24:36 am12bit ADC's and DAC's for a 10A FS range load is only 10mA resolution.How do you plan to get uA resolution?Even with a switchable 1A range, that's still only approx 250uA resolution per bit.Or have I missed something?And the cheap Microchip DAC specs aren't that great, just be aware.Dave.

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 12:14:25 pm
content: Harvs,It's in the shitty MOSFET. I'll switch to a different one. Thanks for the input - I obviously don't have enough experience with electronic loads to know that is unacceptable. With a better FET I got it down to 110mV without the diode (In LTSpice, that is, I'm going to have to actually buy the FET to test it properly. I don't have a better one on hand ATM.)That Agilent load doesn't appear to have reverse protection, unless I'm missing something? I just see eight loads in parallel, each with a 15A fuse, and I rather doubt those FETs' body diodes can each handle popping a 15A fuse. Or worse, a reverse-connected source that won't deliver enough current to pop the fuse and just sits there driving them. Do these things generallynothave reverse protection? I can omit it if that's acceptable and it loses 0.8-1V of its dropout.That shunt I selected is rated 50 ppm/deg.C, so even if the temperature rose 100 degrees (doubtful, it'll be dissipating one watt at maximum load, and it's rated for three - though they don't give a temperature rise per watt) it would only be out 0.5%. The 5% was probably overly pessimistic and I will tighten it to match the other ranges after some testing.Dave,There are six ranges total. Three MOSFET/sense resistor assemblies (0.01 Ohm, 1 Ohm, 100 Ohm). They each have a 3k3 gate resistor (bypassed with a 1N4148 out of the gate for fast switching - otherwise if you have the load switched on but nothing connected, then connect something, it will take a large inrush as the gate capacitance is discharged.). The FET is selected by pulling the other two gates to ground, and the sense resistor is selected with an analog mux. This gives 10A, 100mA, 1mA ranges (0.1V full scale on the resistor), and the other three ranges (1A, 10mA, 100uA) come from a switchable 10x gain on the sense resistor.As for the DAC specs, I could dick around with the math, but honestly I'd rather just buy one and test it. 12 bits gives me four times the resolution that I actually need, so I have room to play around with software nonlinearity compensation if necessary. (I may actually have one of the same exact model lying around, now that I think about it...) I think I'm going to actually order the parts for a prototype very soon, then see if I can't tighten up the specs a bit.

author: EEVblog
author_rank: Unknown
timestamp: January 24, 2013, 12:43:58 pm
content: Quote from: c4757p on January 24, 2013, 12:14:25 pmDo you really need small ranges like 1mA and 100uA FS?What are they designed to test?Dave.

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 01:45:55 pm
content: Probably not, but since the range switching circuitry is already there for the 100mA/10mA ranges, I figured I would add it. (I will *not* remove the 100mA/10mA ranges, since with only three digits of resolution they are pretty important for the lower end. The range switching circuitry is cheaper than the circuitry to get a 10mA FS range from just DAC resolution and/or switchable gain.) The cost is just a $0.40 TO-92 MOSFET, a 2N3904*(for the gate pulldown), three resistors (gate, sense, 2N3904 base), and the uA LED on the front panel. I can see it being useful for variable loading of higher-impedance signal sources, tiny charge pumps, etc. I have loaded circuits to that level before on a few occasions, and while just grabbing a resistor out of a bin certainly works at that level, the ability to vary in fine increments of current is handy. Probably not allthatuseful, but it's an easy addition that might be useful for somebody.*I was originally going to use 2N7000 and save on the base resistors, but I've personally killed a few with ESD myself, and since they're so important to making sure the thing doesn't blow the ass out of the DUT by accidentally pulling 10A when you dial in 1mA, I figured I would use something more robust.

author: Harvs
author_rank: Super Contributor
timestamp: January 24, 2013, 02:06:36 pm
content: Quote from: c4757p on January 24, 2013, 12:14:25 pmWell with a "decent" MOSFET, and proper gate drive, you should get down to the MOSFETs Rds(on). That should be fairly in-significant in the grand scheme of things.QuoteIt's a little bit hard to be sure, but I'd say the reverse body diodes will break the fuses. So a little trick I learnt from Jay-Diddy. With the Agilent schematics, go up, find the part no. If it's an Agilent part no, go to the agilent site, then to tech support, then under parts and you can look up the part. If you do that with Q1 and Q2 of the 6060B you'll find it's a "FET assembly". So in all likelyhood, the body diodes of the "assembly", will break the fuses.In this case though, it wouldn't be hard to simply add a low forward voltage diode to pop the fuse on reverse input.QuoteOk, I'm using basically the same shunt except in the 5W version and 50mOhm. Have a look at the datasheet for these, and the IR pics of these with rated input power. They rise something like 200 degrees at the center point. The heating isn't uniform. From my experience actually measuring these under load, you're quite likely to see a 0.5% drift under the conditions you're talking about. As I was saying in the other thread, I was running the 5W 50mOhm @ 100% rated load and seeing a good 1% resistance change, and the larger value 50mOhm version is only 20ppm. That's why I'm trying to find a better solution...As Dave was saying, I don't see the point in having the very low current ranges, it just complicates things. I recon those ranges need a separate instrument that's basically the reverse version of the Keithly precision current source.

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 02:29:24 pm
content: Yeah, Iwasdown to Rds(on). The only MOSFET I had on hand that could handle the power was really terrible (I can't remember what it was now, but it was a cheap one that I tore out of a broken-down off brand ATX power supply...)OK, I will add a diode antiparallel to the input to blow the fuse in case of reverse polarity. I kind of wanted something more non-destructive (no blown fuses, no high current draw), but there's no way I'll get a decent dropout with just a series diode, and I'd rather not get into more complicated active circuits, so I think I'll just go with that. If it's good enough for Agilent it's good enough for meMaybe I'll take some time to see if I can design some cheap series circuit with low dropout, but I'll go with the diode if I have to.If the shunt rises 200C for 5W dissipation I figure I'll be fine at 1W. I'll have to get it and test, though. I'll try to put it in the cooling ventilation path as well.I'm going to be stubborn and keep the low current ranges, at least in the PCB. I can always omit the components later, and I like the idea. It doesn't really add any complexity at all. Not everybody who needs a small current once in a while needs the precision of a Keithley instrument, and personally I think the idea of an instrument like this having a range of a good few orders of magnitude makes perfect sense. Multimeters do it, why not loads?

author: blackdog
author_rank: Frequent Contributor
timestamp: January 24, 2013, 03:34:54 pm
content: Hi all, :-)You can take a look @ "my design" of a active load.I can tell you from experience that it is not simple...I know it is in Dutch, but a lot of picures, on page 3 is the final version of the schematic.http://www.circuitsonline.net/forum/view/106770/1/active+loadYou can see the design changes i made about the cooling of the powertransistor.Most inportand how will it behave, is it stable?I made a modulation input and it is -3db is ~24Khz, terriffic tool to test powersupply's.The Active load is tested @ max 300 Watt's for a short time, transistor temp ~90CAnd @ 200 Watts around 80C for hours..It's uses 4x 0.1 Ohm sense resistor parr. Caddock MP930.Stability of these resistors < 200ppm and its fine.I use just a good 10 turn Spectrol 534 series potmeter in 2 ranges, 2A and 20A.If you want a active load for < 100mA build a dedicated one for that range.I can set the current to 35mA without any problems on the low range,but that not precies because of the drift/ofsett of the ompamp i used and the meters on the instrument.Low range, <100mA ~2% precision.This opamp was carefully selected, low offset / wide dynamic range / no overshoot.You can look for good AD or DA converters wat you want, 16 bit 24 bit...That is not as important as the way the wiring is made, this is a little "Black Art"Especially the sense wires, where do I solder it on the sense resistors.Do not overdesign, it will never finish.Start with the op amp, power transistor, sense resistors.Check that its's AC and DC stable.Design it so that it can be controled by a voltage reference and potentiometer.Later connect your AD/DA control circuit to it.Just my 2 cents :-)Blackdog

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 09:43:32 pm
content: OK, I have a schematic of the analog stuff now (digital, some power supply stuff, and temp sense are missing), though it does need to be cleaned up a bit. Any criticisms? Or anything I missed? (I'm sure I did...)I did remove the low range after all, I gave it some thought and agree that it's pretty much useless. It still goes down to 10mA FS - honestly, that's 100uA steps, it should be more than good enough. I also changed from a switchable gain on the current sense to a switchable attenuation on the current set, after testing and finding that the offset was much better that way.I ended up going to a dual supply op amp to get closer to ground. I'm using an inverter rather than a virtual ground because I don't want to require a power supply more than 12V and it needs more than +6V to have enough headroom to drive the MOSFETs. It's pretty much just the MC64063 reference design, I don't want to spend too much time on a low-current -12V supply...Edit: If anyone notices, I just spotted the two BAT85s clamping to the wrong rail.

author: blackdog
author_rank: Frequent Contributor
timestamp: January 24, 2013, 10:51:54 pm
content: Hi c4757p,Maybe i mised somthing, in the schematics u use a TL034, ist offset can be 3.5mV and one af the ranges is 0 to 18.85 mV.Did you do a error budget on that?The DC level on the 74HC4066 near ground will probaly give you extra DC error.The gain of TL034 (u3b) is high on some rages this wil give you large errors on the Isense out.Kind regarts,Blackdog

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 11:24:47 pm
content: QuoteI just spent some time testing one I have here, and the offset is predictable enough to be compensated for in software. Over the entire temperature range from 10C to 60C it doesn't drift by more than 0.4% in either direction, and even that drift was fairly predictable - I could temperature compensate it (in software) for significantly less than the cost of a better op amp. The coefficients could be pretty easily calculated during the self-cal routine.I may end up changing it, though. The schematic has four op amps, and one needs to have low bias current, and the others need low offset. I went with a quad that had low bias current andpredictableoffset. However, I will need a fifth op amp for the temperature sensor, so I may use the quad for all but the high impedance voltage sense node, and a different one with low bias current but more offset for that. (Both low bias current and low offset sure does make for an expensive op amp!)QuoteWill it? The datasheet just shows impedance, not any sort of offset, the plots don't show any sort of spike near zero, and I'm not drawing any current through any of the switches.Instead of getting a more expensive dual-supply switch, could I bias it down by a diode drop (so its ground sits around -0.7V), and drop all the digital inputs that amount as well? Would 0.7V be enough to make it work well? And will there be any noise issues from putting ground on a regulated rail? (Of course I could decouple the living hell out of it, which may solve that problem.) Unfortunately I don't have one on hand at the moment to test and the datasheet doesn't really say much about tiny voltages. It just claims the thing goes down to 0V.

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 11:34:29 pm
content: I don't have any analog switch ICs on hand, but I just put together a quick single-JFET (J113) switch and didn't notice any voltage error all the way to 0.1 mV. I can't really test much lower, my best meter resolves in 10 uV increments. That's the best test I can do right now. I'm not sure how similarly a dual MOSFET switch like the 4066 behaves to a single JFET (obviously the JFET has much higher impedance, but the only load was the 10 Meg input impedance of the multimeter, so the voltage drop was negligible), but at least that worked.

author: Kevin.D
author_rank: Frequent Contributor
timestamp: January 24, 2013, 11:40:11 pm
content: I like the way you have paralleled the different ranges .There are also ways to get multiple ranges without switching , instead you can have multiple output sockets that you can plug into for each range. Likethis one here .http://electronicdesign.com/site-files/electronicdesign.com/files/archive/electronicdesign.com/files/29/4056/figure_01.gifI kinda like that setup ,one op amp and no switches do all the ranges .One major drawback to not having a range switch though means it's no longer simple to detect which range is currently being used in order to adjust any current meter display you have fitted.

author: c4757p
author_rank: Super Contributor
timestamp: January 24, 2013, 11:47:02 pm
content: I like that setup for an analog load. Definitely kind of old-school, in a good way. It's really annoying, though, when something is digitally controlled - even computer controlled - and there are things the controller can't do. If I can hit a button on the computer to draw 50 mA, I should be able to hit a button to change that to 500 mA.One benefit of that is that it takes more than a button slip to go to the wrong range and blow the ass out of something. For that reason, I've chosen to have my load disengage whenever the range switches are pushed. If you want to change to a higher range, you have to re-engage it after the range switch.One comment about that schematic - they're having you parallel 10/100/1000 to get 9? I think that's kind of silly - not only is it one more resistor than just doing 2.2 + 6.8 in series, it's not exact (9.009) and 2.2+6.8 is. I could see doing it for the 0.9 resistor, since 1/10/100 is more common than 0.22 and 0.68 (and only one resistor has to be high power - 0.22 and 0.68 share the dissipation more evenly), but not for the others.

author: c4757p
author_rank: Super Contributor
timestamp: January 25, 2013, 12:00:08 am
content: Just a thought - even though I'm notcurrentlyplanning on doing any ambient temperature compensation, I think I will include the hardware in case I do. Microchip has an app note (TB3016) for doing a rough temperature measurement with only an external garden-variety diode - some of the newer PICs have an integrated current source that can connect to an active ADC pin, so temperature is calculated from VFat the constant current. Just thought that was kind of coolI may use that in place of a thermistor to measure the heat sink as well, if it's repeatable enough. It has to be relatively stable from part to part, since I can't really expect the kit assembler to probe temperatures as part of the calibration...

author: c4757p
author_rank: Super Contributor
timestamp: January 25, 2013, 01:44:59 am
content: No changes (except for that incorrect clamp diode connection), but cleaned up quite a bit.

author: Skimask
author_rank: Super Contributor
timestamp: January 25, 2013, 09:30:00 am
content: Amazing coincidence...(ok, maybe not amazing, but I think it is)I needed to load down that +/- boost converter I built last week without using a pile of sand resistors, and I just finished beating an electronic load circuit together using Dave's Episode #102 as a base...16 TO92 2N7000's in parallel, 33 each 33ohm 1/2 watt resistors in parallel (one ohm-ish), a 9v battery, and a single turn 100k pot...all just for grins. And it worked first time out! Rotten resolution, touchy as hell with that single turn pot, but works fairly linearly up to the 3 amp limit of my Mastech power supply.Question...In your circuit, doesn't the inherent resistance of the '4066 switches get in the way of the feedback? (e.g. changing the gain values against your will?)

author: blackdog
author_rank: Frequent Contributor
timestamp: January 25, 2013, 10:06:53 am
content: Hi c4757pLet me firts say that i like your way off trying to solve the rangeswitching problem.But, the opamp TL034...Say U3c, max Gain about 130x, say 2mV offset = 260mV error, you have enough dynamic range to compensate this?Say U3a Irange Low, 2mV positive offset, this percentage is a large part of the 18.5 mV.Are you using a 4 quadrant AD to compentate for this errors?If you make this a kit you need at least 20x TL034 of different dates to be shure of its specs.Otherwise you have to use the maximum values ??in the data sheet and make sure your AD and DA converter and software have sufficient range to compensate for the errors.Maybe a LT1013/LT1014 is a option.If you can live with 5.5V max powersupply, maybe a Microchip 6021 series, relative cheap.I think maybe its better to use a 4 wire method for sensing, the ground of R14, R20 and R24 is a big problem.In my electronic load i hat to shift the sense wire 0.5mm to get the optimum point.It will be hard to find your mecca ground point for 3 resistors.Kind regarts,Blackdog

author: Harvs
author_rank: Super Contributor
timestamp: January 25, 2013, 11:05:24 am
content: Quote from: blackdog on January 25, 2013, 10:06:53 amYep, if you read the datasheet for the OAR shunts they're designed to be 4 wire sensed. There's simply no way you're going to get accuracy with a 10mOhm shunt without 4 wire sensing it.I've used the same method for switching ranges (i.e. just disabling a bank of mosfets.)On the Op-amp and range sensing. If you spend the time to go through a lot of older commercial lab equipment schematics (the high end ones that is) before they ended up full of ASICs, and fully understand their front ends (look up the datasheets for each of the opamps specs etc.) You'll find a lot of very clever ideas for solving a number of problems you've got in that design.It requires time and effort, I still highly recommend it though.

author: c4757p
author_rank: Super Contributor
timestamp: January 25, 2013, 12:19:07 pm
content: Quote from: Skimask on January 25, 2013, 09:30:00 amThe voltage dividers are external to the 4066, which just chooses a tap on them. No current runs through it.

author: c4757p
author_rank: Super Contributor
timestamp: January 25, 2013, 12:23:00 pm
content: You are probably right about the four-wire sense. I think I may add a differential amplifier to the 10mOhm sense resistors to sense them properly that way. I just realized I neglected to do a proper differential sense on the "voltage sense" input as well, which kind of defeats the purpose of that...I'd comment on the op amp, but I'll probably end up changing that in the process, so I'll wait...

author: blackdog
author_rank: Frequent Contributor
timestamp: January 25, 2013, 01:47:28 pm
content: Hi c4757p,Thats why we are here =>which kind of defeats the purpose of that...Kind regarts,Blackdog

author: c4757p
author_rank: Super Contributor
timestamp: January 25, 2013, 02:18:38 pm
content: I may skip the differential current sense after all. Just played around with it a bit and found that it makes the circuit significantly more sensitive to the op amp offset - not only will I needmoreop amps, I'll needmore expensiveop amps. Unlike offset in the drive amp, I can't compensate for this offset in software. Not just that, but most of the ones with good enough offset are SMD-only and have a tiny maximum supply voltage - I don't want to have to add more rails either. I already have +12, -12, +5, +3.3, and I may end up with a -0.7V bias for the analog switches. Don't really need +2.5 and -2.5 too! Sadly many of the nice PTH, higher-voltage op amps used in these older load designs are as rare as hen's teeth these days... I am going to try to put together a PCB layout and see how well I can do to minimize the PCB resistance effects. As long as I reference signals to the right spot, I don't need the PCB resistance to be so small it doesn't change the sense resistance, I just need it to be so small that the high temperature coefficient of the copper doesn't affect the signal more than the tempco of the sense resistors. The design does not depend on the sense resistors being exactly 10 mOhm, or even matched in the case of the parallel high-current loads.I will, of course, fix the non-differential voltage sense, that's just stupid.I think I'm going to order a bunch of parts of varying parameters, build up a PCB with IC sockets and try them. I can go back and change to a differential current sense later as well, but I don't think I'll need it. I've got a big pile of copper clad boards here, I can re-spin the prototype layout as much as I need to.

author: c4757p
author_rank: Super Contributor
timestamp: January 25, 2013, 08:56:08 pm
content: Found an MCP6V06 lying around, so I thought I'd test it. It's a single-supply auto-zero with 3uV maximum offset. Turns out it really is perfectly happy running off a single supply, even so ridiculously close to ground, so it can run off the existing +5V rail (that is its maximum).I generated voltages in 10uV steps (I don't have a way to measure that low - the best I have is a Fluke 8050A that resolves in 10uV steps, but with a 10uV step I can't tell 7uV from 14uV - so I rigged up a precision 10uA to 10mA variable source and fed that through a 1%, 1 Ohm resistor). I tested a differential amplifier made from the 6V06 with a gain of 15, and it was spot on all the way through the range. I added another 1 Ohm resistor to add a common mode difference, and it was still perfect. I think that's what I'm going to do - instead of dividing the DAC output, I'll multiply the current sense with an MCP6V06 (actually the dual version, 6V07, with one unit on each of the two ranges) up to nearly full scale on the ADC and DAC, and then use a lower precision op amp (OPA277 - it's actually slightly more expensive but can handle the full MOSFET gate drive voltage) to drive the circuit.I'll retain the poor, unwanted,cheapTL034 for the voltage sense, since I neither require high precision nor have tiny voltages there. Idohave high impedance, though, so its low bias current is good.

author: c4757p
author_rank: Super Contributor
timestamp: January 27, 2013, 02:04:07 pm
content: Well, scratch "all through-hole", I don't have the resources to get PCBs made that are practically the size of a sheet of paper...With basically three digitally-controlled switchable loads, differential voltage sense, USB and a DC/DC converter, the 1/4 watt axial resistors alone take up more space than I want the entire PCB to take, and that's with a pretty tight layout. Guess I'm going to 0805.... I'll still pre-solder the fine things like the SSOP FTDI chip, the QFP microcontroller and a SOT-363 MOSFET.

author: cwalex
author_rank: Frequent Contributor
timestamp: January 28, 2013, 02:20:43 am
content: I wonder if it would even be a problem at all being smt design. People who need an electronic load will probably have more experience with electronics than the average kit builder. I would like to put my hand up for one when the design is finished! smt is fine by me, no need to presolder anythingNice project

author: c4757p
author_rank: Super Contributor
timestamp: January 29, 2013, 01:15:59 am
content: PCB is almost done, so I'm pretty much through changing things in the schematic. Here's the current schematic. I still have to tidy it up a bit before it is documentation grade. Welcome to criticism as always!

author: Harvs
author_rank: Super Contributor
timestamp: January 29, 2013, 03:33:50 am
content: I've only had a quick look over it, but you may want to re-think building a "roll you own" differential amp for the current sense. Have a go at adding up the errors involved in that circuit using real world components. You'll find that buying an off the shelf all in one instrumentation amp will be more accurate despite you using a reasonably expensive op-amp.

author: Harvs
author_rank: Super Contributor
timestamp: January 29, 2013, 03:36:40 am
content: I just saw the page with the voltage sense amp. What error budget have you allowed for this differential amp setup? What resistors are you using?

author: c4757p
author_rank: Super Contributor
timestamp: January 29, 2013, 04:48:38 am
content: With the current sense amplifiers, I have thoroughly tested the circuit on the bench with real components, intentionally mismatched components (out to 10%), ambient temperature up to 100C, and steep temperature gradients across the circuit. The offset, which is the important error in the circuit, had a maximum of 45 uV (yeah, I finally tracked down a meter that will measure that). That corresponds to less than one half LSD. Thermal error was less than 0.5% over the target ambient range of 10C to 70C. (And even if it weren't, I really could lower the maximum temperature, nobody is going to be operating test equipment at 70C.... With the cooling fan moving air over this section ------oh crap, I forgot the switch for the fan----- its temperature will not get that high just off the dissipation in other components.) The rest of the error, depending on component variation, was linear, so it can easily be compensated by the microcontroller (I chose one with hardware multiply/divide specifically for this purpose).I have not fully tested the voltage sense amplifier, because I don't have a suitable op amp at the moment. My op amp supply is severely depleted and I am waiting on some parts. (I left that area of the PCB fairly well separated so I can rip it up if I have to.) Target accuracy is 2-3% - voltage sense is not needed for CC, and most applications of CP/CR/CV don't need very high accuracy. I'd do better, but the requirements (input up to 100V; input impedance loading less than the lowest-range LSD at 100V; small, simple circuit) don't allow much without raising the cost significantly. I'm not exactly building a DMM in my load. Digital compensation will handle imperfect resistor values, and I will use 100ppm/K or less resistors in that section to minimize error across the operating range.I'm not sure I like the input offset of the TL034 - the error could be more significant at lower input voltages. I may look for a lower offset amp, but I'm trying to keep the price from climbing too high. I'm going to order some more parts tomorrow - I may grab a few different op amps to try.I'm sure I'd sound a bit more coherent if I weren't so damn tired...I've been up for the last 36 hours straight. I'll do some more work on that section tomorrow and get back to you.

author: Harvs
author_rank: Super Contributor
timestamp: January 29, 2013, 05:49:15 am
content: Ok, I wrongly assumed the voltage and current measurements were for feedback. Effectively an internal dmm as you said. So you could log input power and the like. If not, you're probably in the realm of overkill with a lot of this.Working out the maximum error of a instrumentation amp is quite easy and straight forward. The thing you have working for you with the current sense is the common mode voltage is significantly less than the differential voltage. This is where the mismatch of resistors really hurt.

author: c4757p
author_rank: Super Contributor
timestamp: January 29, 2013, 12:45:28 pm
content: Quote from: Harvs on January 29, 2013, 05:49:15 amYes. Theycanbe for feedback, but it's just a slow, digital feedback - a constant power mode that can track the falling voltage of a discharging battery, for instance. It's not an analog real-time loop and isn't meant to be anything high-precision.QuoteYep. I didn't mark it on the schematic (KiCad is a bit of a pain in the ass for managing parameters and a BOM - I should have added a label next to them anyway, which I will certainly do in the final version of the schematic), but I have noted in the separate BOM that the resistors in the current sense differential amplifiers should be matched to at worst 0.1%. If I end up selling a fair number of the kits I may actually buy 0.1% resistors, but for now I may just get a pile of 1% or even 5% and hand-match them (I don't care if they're 105K as long as they'reboth105K).

author: Harvs
author_rank: Super Contributor
timestamp: January 29, 2013, 02:53:51 pm
content: Sorry, I used feedback in a different context. I was referring to feedback to the pink squishy thing in front of the computer. Which of course you can use it for that to a degree, but people might be better of connecting a DMM if they own a reasonable 4.5 digit one.Being a kit, you know you could just give them a bunch of cheap 1% metal film resistors and get them to match a pair. Chances are everyone building this will own a DMM and a breadboard, and it's very easy to build a bridge circuit to match a pair of resistor ratios which is what you need. Could be a good little "side" exercise, like in the old transmitter kits where you learn't to build a tune an air core inductor. Then again it would be a lot harder if they're surface mount, but still doable via direct measurement and forget the bridge, but that then requires a half decent ohms range.

author: c4757p
author_rank: Super Contributor
timestamp: January 29, 2013, 11:20:59 pm
content: Quote from: Harvs on January 29, 2013, 02:53:51 pmAh.Current measurement is of course intended for user feedback as well as analog feedback - it definitely would have to display the current it is drawing as well as the set current. Voltage measurement is not displayed on-screen*, but is transmitted to a connected computer and can be used to make plots and such. Of course, a plot doesn't generally need high precision.*I'd love to display all kinds of information, but I can't stand instruments with a cheap, crappy LCD, and I'm not going to make an instrument that I myself can't stand... Since I can't afford to include agoodLCD (graphical, so the information can be arranged nicely, backlit, semi-large and with good contrast), I'm doing an LED display, and those are pretty expensiveper digit, so it's just one readout and some discrete LED indicators.QuoteI like the idea, but sadly, I don't think it's going to work out. A 0.1% resistor costs about as much as the number of 1% resistors you'd have to buy to find a match, so the only way it would be economical is if I could use the remaining resistors that failed the match-up elsewhere on the board. Unfortunately, I think a bridge on a breadboard would be the only way to go (a lot of people have just a 3.5-digit meter, which is barely enough to match that closely), meaning they'd have to be through-hole. I could make just those few through-hole and still have room, but I couldn't fit the rest of them in as well. And if I come up with some convoluted routine to get an SMD resistor into a jury-rigged bridge, people would skip it, throw any old resistor on the board, and then get upset when the thing doesn't work properly.

author: c4757p
author_rank: Super Contributor
timestamp: January 29, 2013, 11:53:41 pm
content: By the way - I'd like to post the PCB on this thread when that's done just like I did the schematic. Any comment on what the best way to do that is? I could just upload the KiCad file, but the problem is that I used a custom library for everything and including all of it would be a bit of a hassle for the poor guy who downloads it. I could upload Gerbers, but it's a really complex board and I'm not sure how much anyone could get out of it without any net names or anything.

author: Harvs
author_rank: Super Contributor
timestamp: January 30, 2013, 12:04:42 am
content: Pdf. Along with a Pdf of the final schematics. Most here, including myself won't go installing a software package just to review someone else's design. You can pick up errors easy enough just looking at a Pdf image.

author: Skimask
author_rank: Super Contributor
timestamp: January 30, 2013, 05:16:56 pm
content: Quote from: c4757p on January 29, 2013, 11:20:59 pmHave you checked out some of the TFT LCD displays (with touch capability) over there on ebay? ~$40 or so for a 3.5" TFT LCD 320x240 RGB with touch screen.I've bought a handful of them over time, cut apart a bunch of CD cases, glued them together, hung a single ended LAN cable out the side, and use those for control/display of various projects. 8 wires for complete control (Vdd @ 3.3v @ ~200mA max, Vss, LCD reset, LCD CS, TP CS, MOSI, MISO, CK). I don't mess around any more with LEDs or character mode LCDs unless code space is at a premium or the graphic LCD is way overkill.QuoteDon't know if this matter or not, but in the last year or so, I've begun using multi channel low R value digital pots (AD8400 series types) a bunch for just this reason. More expensive in terms of PCB space and sometime cost...yes... but, gives me the capability to tweak various things over time. Of course, that assumes the end user has a reasonably accurate method of checking. Or possibly could compare all of those readings with one single high precision resistor to make sure everything else is good...in theory anyways.

author: c4757p
author_rank: Super Contributor
timestamp: January 31, 2013, 12:40:18 am
content: $40 just for a display is way too much, no matter how much I'd love to have a 320x240 RGB display with touch.

author: Skimask
author_rank: Super Contributor
timestamp: January 31, 2013, 12:48:20 am
content: It is a bit spendy, which is why I've got all of mine mounted the way I do, in a homemade "case" with a LAN jack on it. I can move it between multiple projects.As far as that goes, you can get them smaller, without a touch panel, for quite a bit less $$$. The interface on a lot of them is the same (if you use the SPI modes) and the code needs a couple of changes to support the differing resolutions.

author: c4757p
author_rank: Super Contributor
timestamp: January 31, 2013, 01:05:18 am
content: I'm considering using a character LCD instead. The LED display is pretty limited - currently I have three seven-segment displays to show the number, a couple indicators on the side for things like mA/A, run/stop, and "unregulated" (not drawing set current), and that's it. The only two "messages" it shows on the display are "CAL" and "USb" (gotta love that lowercase B..), as well as a couple of self-test failure codes displayed as "E 0", "E 1", and so on. I'm not a big fan of those character LCDs, but they are certainly more versatile. I'd much rather be able to show "Run calibration routine / See manual", a little "USB" or "RMT" in the corner, "Error - Missing temperature sensor", calculated readings like power as well as current, etc. I think it might be worth the slightly crappy display.

author: c4757p
author_rank: Super Contributor
timestamp: January 31, 2013, 03:19:24 am
content: Hmm. Might be a while before this is done. I'm currently in Enclosure and Heat Sink Hell and may end up changing some things around.

author: Harvs
author_rank: Super Contributor
timestamp: January 31, 2013, 05:23:36 am
content: Quote from: c4757p on January 31, 2013, 03:19:24 amFor low volume things that's almost always the hardest problem. Compounded when you need to disapate heat.However, all I can say is take the time and do it properly. That's what'll set yours apart from all the other "pcb with a heatsink hanging off" type things you can buy out there. To be honest it wont make much difference to most people if it's 0.5% or 2% accurate, but if it's not in a nice looking case that's ruggard for hobby use with quality buttons and connectors, then forget it.

author: akcoder
author_rank: Contributor
timestamp: March 24, 2013, 07:41:46 pm
content: c4757p,Any status update on this project? I'm interested in buying/building a DC load.-dan