Author Topic: Struggling with DC load  (Read 2687 times)

0 Members and 1 Guest are viewing this topic.

Offline conorheaneyTopic starter

  • Newbie
  • Posts: 5
  • Country: ie
Struggling with DC load
« on: September 18, 2019, 11:19:23 pm »
Hi all,

Hoping ye folks can point me in the right direction. This is my first post and I'm pretty much a beginner in electronics as a hobby, aside from a years worth of dabbling, watching videos, reading, and buying a boat load of kits and components. As a decent sized project to start on, I decided to attempt a programmable DC load. After purchasing the main components I made a start but have quickly discovered that I'm struggling on the analog side.

Attached is a schematic of what I'm working to. Originally everything was on a breadboard (arduino nano, 2.048 precision voltage reference, DAC, op-amp, MOSFET, load resistor (1Ohm 10 watt), and heatsink. All testing is being done against a Tenma power supply set to 5V. Without any calibration at the DAC, I was seeing expected current (+/- 1-3mA) up to about 800mA. Every 100 mA after this, I started to see significant inaccuracy and fluctuations. Wiggling wires also seemed to cause issues  and I measured varying voltage drops between different points on the ground buses. I moved everything to a single ground bus and played around with where I connected the load ground with only minor success.

Thinking it might be something to do with the cheapo breadboards, I (probably badly) moved everything after the DAC onto a through hole prototype board to see if that helped matters (swapping the 1ohm 10 watt for 10 x 10ohm .6 watt resistors in parallel). Maybe it's my soldering or I've somehow mucked up my connections but it seems to be even worse. At lower currents, I'm getting 4-5mA more than expected and only 920mA for expected 1A.

As a last resort, I put a 10uF electrolytic capacitor directly across the load connections and am now seeing the power supply track to within 3-6mA for currents up to about 1.4A with zero fluctuations on power supply current readout.

This has me really muddled as I haven't seen this done in any schematic on the web and kinda seems like cheating  :). I'm more looking for direction here in terms of things to try. Could it be my terrible wiring or soldering, could it just be the power supply itself, is my schematic dodge. Any pointers or guidance in terms of how to diagnose the problem would be very welcome. I have very limited test equipment - just a few Aneng multimeters, a cheap DSO-138 scope that I soldered myself, and a few other bits and bobs.
 

Offline AngraMelo

  • Regular Contributor
  • *
  • Posts: 224
  • Country: br
Re: Struggling with DC load
« Reply #1 on: September 19, 2019, 12:48:17 am »
Hey buddy, Im a beginner as well and I would like to offer my 2 cents.
Whenever Im playing around with opamps I always put myself in the kinda trouble you are in now.

Everything goes up a difficulty level when Im dealing with opamps. Suddenly I need tiny capacitors everywhere, now they are all making low/high pass filters with the resistor and I cant figure out what is going on  |O  :bullshit:. Im just saying that so you dont feel bad! It is part of it! :)

I do have a schematic for a load that works like a charm. Here you go, check this video out, it is very similar to what you are doing:https://www.youtube.com/watch?v=3xp6C67hwsE&t=158s

The schematic might give you an idea of what capacitors you will need for yours
 

Offline Jwillis

  • Super Contributor
  • ***
  • Posts: 1716
  • Country: ca
Re: Struggling with DC load
« Reply #2 on: September 19, 2019, 01:56:47 am »
Here's one of Dave's vids that may help you out understanding how a electronic load works .
 

Offline ledtester

  • Super Contributor
  • ***
  • Posts: 3248
  • Country: us
Re: Struggling with DC load
« Reply #3 on: September 19, 2019, 03:36:13 am »
What's your voltage of your load? And what's the supply voltage for your op-amp?

I've had oscillation problems using a LM324 when the load was < 10 V (like a single cell Li-Ion battery). The same circuit became stable when the load voltage was higher. I posted some videos in this thread:

https://www.eevblog.com/forum/beginners/my-lm324-electronic-load-is-oscillating/msg2505447/#msg2505447

The Youtube description boxes for the videos have full details of the set up.

I had success, though, just playing around with the feedback capacitor. So, some things to try:

- vary the value of C1 - increase it in steps of 100 nF to see if it makes a difference (i.e. changes when the instability begins to occur)
- try a feedback compensation scheme that AngraMelo's schematic shows (which is the same circuit used in my videos); again - play around with the capacitor value; you can try this even in addition to using C1.
- make sure your op-amp supply is adequate (like 12V)
- see if the load voltage changes things
- use a battery as your load supply to see if your power supply is contributing to the problem

 
The following users thanked this post: conorheaney

Online MarkF

  • Super Contributor
  • ***
  • Posts: 2661
  • Country: us
Re: Struggling with DC load
« Reply #4 on: September 19, 2019, 05:26:45 am »
- I would check for oscillations and voltages at the 'sense' resistor, MOSFET gate and op-amp (+) input.
- Check that the op-amps output is not being clipped by its supply voltage being too low.
- Remember the op-amp will adjust its output so that its inputs are equal.  So, the (+)input voltage should match the voltage at the 'sense' resistor.
- The 920mA instead of 1A may be as simple as the 'sense' resistor is not exactly 1 Ω.  Being that low a resistor, 1) apply a current, 2) measure the current and voltage, 3) calculate its resistance.

I don't know what your target load current is, but at some point I would go with a beefier MOSFET in a TO-247 package for better heat dissipation.  Something like a IRFP250.

It is probably better to have a 9V or 12V supply voltage.  I used a 12V supply so I can use a 12V fan for cooling.



I built a DC Load based on Peter's design:
   https://www.eevblog.com/forum/beginners/a-load-off-my-mnd/msg2151265/#msg2151265

Edit:  Updated circuit
848856-0

I have tested it with 5V load voltages but the max voltage across my sense resistor is 500mV for 2.5A.
Your 1.0 Ω sense resistor will require a much higher voltage for the same current selection.

Have a look at his design and performance videos:
Especially the performance one where he is comparing op-amps, oscillations and capacitor choices.

   

   

Also check out J_Diddy_B's project:
   https://www.eevblog.com/forum/projects/dynamic-electronic-load-project/
« Last Edit: October 05, 2019, 05:10:49 pm by MarkF »
 
The following users thanked this post: wilfred, conorheaney

Offline conorheaneyTopic starter

  • Newbie
  • Posts: 5
  • Country: ie
Re: Struggling with DC load
« Reply #5 on: September 19, 2019, 10:41:54 pm »
Thanks for your words of encouragement. Will stay going till (hopefully) I figure this out.
 

Offline conorheaneyTopic starter

  • Newbie
  • Posts: 5
  • Country: ie
Re: Struggling with DC load
« Reply #6 on: September 19, 2019, 10:45:55 pm »
Cheers jwillis. I blame arduino and Daves videos for sending me down this electronics rabbit hole.  :) It is fun though and rewarding when things work out.
 

Offline conorheaneyTopic starter

  • Newbie
  • Posts: 5
  • Country: ie
Re: Struggling with DC load
« Reply #7 on: September 19, 2019, 10:57:12 pm »
Hi ledtester. Thanks for your response and links. Will follow up on them over coming week. Am a bit time poor at the moment.

I'm testing at load voltage of 5V and my supply voltage to my op amp is 5V. Realistically 4.7 when powered from my laptop but closer to 5v when powered from a variable wall wart I purchased.

Will definitely try out all your suggestions and let you know how I get on. Seems strange that it's worse on proto board than on breadboard so wondering if some parasitic capacitance on breadboard could have masked the problem.
 

Offline webgiorgio

  • Regular Contributor
  • *
  • Posts: 70
  • Country: dk
Re: Struggling with DC load
« Reply #8 on: December 07, 2019, 08:39:18 am »
Why isn't the op-amp working as a comparator? I don't see negative feedback resistor...
 

Offline conorheaneyTopic starter

  • Newbie
  • Posts: 5
  • Country: ie
Re: Struggling with DC load
« Reply #9 on: February 28, 2020, 09:21:17 pm »
Over 6 months later and a few (nay lots  :)) of attempts and I may have finally cracked this. The LM324 combined with my power supply voltage (USB from laptop to arduino to opamp) was definitely preventing me going above around 1.2A to 1.3A. When measuring the voltage at the gate of the mosfet, I was only hitting ~3.5V which happened to be ~1.2 V below the power supply voltage coming from Arduino (4.7V).

Could the oscillations and drops at the higher levels be down to this?

As I didn't have single supply rail to rail opamps, I liberated an AD8542 from an old circuit board. I rebuilt the circuit on combination of breadboard and veroboard. The veroboard has mosfet, heatsink, and 10 parallel resistors making 1ohm. All other circuitry, including aduino, precision voltage reference, DAC, and opamp is still on breadboard.

In addition to MCP4922 DAC I added an ADS1115 ADC to the circuit. In code, when I set a desired DAC code 0-2000 for a desired current of 0-2000ma, I first set the  and then measure the voltage at the top of the feedback resistor, adjusting the DAC code up or down until I am within sub mv of the desired output. Allowing for inaccuracies in my VREF, DAC and ADS1115, and multimeter I seem to be getting to within about +-1mv of my desired current when reading voltage across sense resistor using my multimeter which is an Aneng AN8008.

My TENMA 72-2535 power supply shows higher current output the higher the set current. It's reading is about 32ma out at 2A. Could this be down to lead resistance at higher currents? I'll do some more digging to measure current using multimeter but as of now, I'm delighted to have gotten things to this point.

Thanks yourself and everyone else for their help.


 

Offline Jwillis

  • Super Contributor
  • ***
  • Posts: 1716
  • Country: ca
Re: Struggling with DC load
« Reply #10 on: February 28, 2020, 10:40:22 pm »
You have a lot of shunt resistors all having a varying range of resistance between them and temperature drift . This has a great influence on the op amp. The  output to the mosfet  can vary  and won't be consistent . It will tend to drift around all over the place even with slight changes in ambient temperature around the resistors . Try one single shunt resistor with a higher wattage.
Doing some experimenting on my EL I found this drifting got worse with the more resistors I put in parallel.  I tried my build my own shunt resistors with a short piece of high tensile steel wire and stability improved . This of course is rather unorthodox because I can't determine the temperature coefficient of the wire I'm using. I would rather have some Manganin.   
 

Offline thm_w

  • Super Contributor
  • ***
  • Posts: 7202
  • Country: ca
  • Non-expert
Re: Struggling with DC load
« Reply #11 on: February 29, 2020, 02:19:48 am »
The wattage, temperature coefficient, and tolerance of the resistors is going to be more important than the number of resistors in parallel.
OP can calculate the worst case offset if they know these values.

Over 6 months later and a few (nay lots  :)) of attempts and I may have finally cracked this. The LM324 combined with my power supply voltage (USB from laptop to arduino to opamp) was definitely preventing me going above around 1.2A to 1.3A. When measuring the voltage at the gate of the mosfet, I was only hitting ~3.5V which happened to be ~1.2 V below the power supply voltage coming from Arduino (4.7V).

As you mentioned you were not using rail-to-rail output opamp, the LM324 states: "Output Voltage Swing 0 V to V+ −1.5 V"
So 5V - 1.5V = 3.5V at the gate.
Profile -> Modify profile -> Look and Layout ->  Don't show users' signatures
 

Online MarkF

  • Super Contributor
  • ***
  • Posts: 2661
  • Country: us
Re: Struggling with DC load
« Reply #12 on: February 29, 2020, 03:39:30 am »
I used a single 0R2Ω sense resistor.

   https://www.mouser.com/ProductDetail/Vishay-Dale/LVR05R2000FE12?qs=sGAEpiMZZMtbXrIkmrvidDnVsdYYat5oizNYG50X9KQ%3D

I'm able to get a stable 2.5A max load current and the sense resistor barely gets warm. 
The (+) input to the op-amp is between 0V and 0.5V. 
This requires a 10:1 voltage divider to drive with a 5V control voltage.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf