Sonsivri
 
*
Welcome, Guest. Please login or register.
Did you miss your activation email?
December 08, 2016, 08:44:26 08:44


Login with username, password and session length


Pages: [1] 2  All
Print
Author Topic: Variable DC load with PIC18F4550  (Read 4224 times)
0 Members and 1 Guest are viewing this topic.
zed65
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 39
-Receive: 37


« on: August 15, 2013, 08:42:44 20:42 »

I'm planning on building a variable DC load capable of 30v 2amp.
Now i'm using a TIP35C to control the load via PWM-analog from the microcontroller.
Is there a better choice?

Anyone see any fatal mistakes?

Logged
pickit2
Moderator
Hero Member
*****
Offline Offline

Posts: 3816

Thank You
-Given: 567
-Receive: 2049


There is no evidence that I muted SoNsIvRi


« Reply #1 on: August 15, 2013, 11:14:50 23:14 »

how? and why are you using a TIP35C, a logic power fet would be better controlled.
Logged

Note: If you have no posts other than, I want or reporting a dead link Then you can't complain If I remove your post So Stop Leeching
optikon
V.I.P
Hero Member
*****
Offline Offline

Posts: 604

Thank You
-Given: 460
-Receive: 1604


« Reply #2 on: August 16, 2013, 12:32:02 00:32 »

I'm planning on building a variable DC load capable of 30v 2amp.
Now i'm using a TIP35C to control the load via PWM-analog from the microcontroller.
Is there a better choice?

Anyone see any fatal mistakes?



Agree with pickit, power fet better choice. The TIP35C has ~ 130 current gain which means your pic is required to supply about 15mA to the base. You should check that it can do that. Even if it can, thats pretty stressful for a logic output driver. Consider another buffer to drive the base.

If you use power mosfet, the drive requirements are easier.

Also if you stay with TIP35C, 30V@2A is at boundary of DC SOA and this assumes the TC=25C which means, you need to do an excellent job heatsinking and removing heat from the device. If you fall just shy of that, the part will go into thermal breakdown and destroy itself. This is another reason for the power mosfet. Pick one with good margin in the SOA, not near the boundary.
Logged

I can explain this to you. I can't comprehend it for you.
Gallymimu
Hero Member
*****
Offline Offline

Posts: 579

Thank You
-Given: 101
-Receive: 151


« Reply #3 on: August 16, 2013, 03:48:32 03:48 »

I'd also do it with a MOSFET or an array of mosfets (if you are operating in the linear region you have to be VERY careful about safe operating area for the MOSFET.  They will handle MUCH less current when in linear mode.

I'd also wrap an opamp around the mosfet for control.  For instance, a current sense resistor on the output of the mosfet that is monitored by the opamp.  The PIC can send the analog to the non-inverting input of the opamp for a setpoint and then the opamp can drive the mosfet however is necessary to achieve the desired load current.  If you do this be careful as mosfets are hard to stabilize in the linear mode and oscillation is likely and a B*#CH.
Logged
LithiumOverdosE
V.I.P
Senior Member
*****
Offline Offline

Posts: 289

Thank You
-Given: 246
-Receive: 396


« Reply #4 on: August 16, 2013, 04:05:49 04:05 »

Or you could use magnetic saturable reactor for current control.
Logged
Gallymimu
Hero Member
*****
Offline Offline

Posts: 579

Thank You
-Given: 101
-Receive: 151


« Reply #5 on: August 16, 2013, 06:29:07 06:29 »

Or you could use magnetic saturable reactor for current control.

for shizzle? or are you joking
Logged
LithiumOverdosE
V.I.P
Senior Member
*****
Offline Offline

Posts: 289

Thank You
-Given: 246
-Receive: 396


« Reply #6 on: August 16, 2013, 12:23:17 12:23 »

Shizzle?
Logged
zed65
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 39
-Receive: 37


« Reply #7 on: August 16, 2013, 01:21:55 13:21 »

Thanks for the info, the TIP35C was the beefiest I had in my box at the moment.
I feed it from the PWM via a RC filter to create a 0-5v.
The more I read about transistor/mosfet/IGBT the more I realize that I have A LOT to learn Roll Eyes

Any suggestion of a mosfet?
Logged
Gallymimu
Hero Member
*****
Offline Offline

Posts: 579

Thank You
-Given: 101
-Receive: 151


« Reply #8 on: August 16, 2013, 03:19:58 15:19 »

Shizzle?
http://onlineslangdictionary.com/meaning-definition-of/for-shizzle

simply translates to "For Real?" or "Are you serious"

i.e. saturable reactor would be frequency dependent and not much of a load for DC.  It would also require a significant drive to provide saturating flux on the order of (or a turns ratio of) the load current.  Unless I'm misunderstanding how it would be used, or the suggestion was tongue in cheek.

Posted on: August 16, 2013, 03:16:13 15:16 - Automerged

Thanks for the info, the TIP35C was the beefiest I had in my box at the moment.
I feed it from the PWM via a RC filter to create a 0-5v.
The more I read about transistor/mosfet/IGBT the more I realize that I have A LOT to learn Roll Eyes

Any suggestion of a mosfet?

Yes,

Pick one with a Logic level gate, Rdson doesn't matter so much for linear mode, find one with a set of SOA or Safe Operating Area curves.  Make sure all of your load scenarios fit into the safe operating area.  Make sure it can handle the power dissipation (related to safe operating area but not exactly). Off the cuff you might see 1/10th the usable current in linear mode vs rated max current.  The relationship between Vgs and Rdson is very non-linear and is very sensitive.  Don't expect to be able to set a voltage that corresponds to a load setting without a good feedback mechanism (like an opamp)
Logged
LithiumOverdosE
V.I.P
Senior Member
*****
Offline Offline

Posts: 289

Thank You
-Given: 246
-Receive: 396


« Reply #9 on: August 16, 2013, 04:11:49 16:11 »

Thx for explanation of "shizzle".

You are correct on frequency dependent nature of saturable reactors. I simply suggested it because in the past I usually required adjustable loads for low frequency electromechanical generators. I'm currently interested in the topic of magnetic amplifiers so I simply suggested a general solution that would be consistent with my own past requirements.
Logged
Gallymimu
Hero Member
*****
Offline Offline

Posts: 579

Thank You
-Given: 101
-Receive: 151


« Reply #10 on: August 16, 2013, 06:52:03 18:52 »

Thx for explanation of "shizzle".

You are correct on frequency dependent nature of saturable reactors. I simply suggested it because in the past I usually required adjustable loads for low frequency electromechanical generators. I'm currently interested in the topic of magnetic amplifiers so I simply suggested a general solution that would be consistent with my own past requirements.

Ah, got it.  Yeah it seems like it would be a good solution for low power RF control.  We use the technique for the opposite effect pretty often: to set the flux in the negative direction expanding the range of a pulsed current transformer measurement.
Logged
bigtoy
Active Member
***
Offline Offline

Posts: 152

Thank You
-Given: 127
-Receive: 197


« Reply #11 on: August 22, 2013, 05:36:10 05:36 »

We have some small variable DC loads at work very similar to what you're wanting to build. I'm sorry I cannot post the circuit, but I can tell you this. Use an op-amp to handle driving the gate of the MOSFET. IE, have the processor generate a reference voltage (PWM output and filtered by a big R-C is fine) but then let the op-amp handle the feedback. MOSFETs in their linear region are quite unstable and you'll have a VERY hard time getting your processor to keep up with it (you'd need a very fast feedback control loop in your code). The processor can certainly monitor the voltage and current in the load to display those things, and power (V*I) etc, but let the op-amp do the heavy lifting. An LM358 will do the job and it's cheap. The MOSFET they use is an IRFB4110 (which is not a super-cheap part, but perhaps you can find a cheaper device with similar specs). Hope this helps.
Logged
Gallymimu
Hero Member
*****
Offline Offline

Posts: 579

Thank You
-Given: 101
-Receive: 151


« Reply #12 on: August 22, 2013, 06:42:03 06:42 »

We have some small variable DC loads at work very similar to what you're wanting to build. I'm sorry I cannot post the circuit, but I can tell you this. Use an op-amp to handle driving the gate of the MOSFET. IE, have the processor generate a reference voltage (PWM output and filtered by a big R-C is fine) but then let the op-amp handle the feedback. MOSFETs in their linear region are quite unstable

Hmm, this sounds really familiar.
Logged
Wizpic
Global Moderator
Hero Member
*****
Offline Offline

Posts: 976

Thank You
-Given: 197
-Receive: 344



« Reply #13 on: August 22, 2013, 07:36:10 07:36 »

I would use an op-amp to control the load, because you can use the feed back to keep the current constant no matter what the voltage is, like said Fet's are not stable in linear mode but with such small current thy should be ok.
Here is a link for that use's a little tiny atmeg with a rotary encoder to control it. This should give you a good idea code and schematics are towards the bottom
http://blog.freesideatlanta.org/2012/08/constant-current-dummy-load-complete.html

Here's another link that just uses an LM324 a fet and it has fine and coarse adjustment a video series if you wanted to watch how it was designed.
http://www.youtube.com/watch?v=afM1aujgAF8
The forum where you can fins the schematics and all info,
http://mjlorton.com/forum/index.php?topic=106.30
I would go this way and just use to panel meters or a pic to display the load/voltage and may be add a data logger to it which all depends on you want to do with it

Logged

When you think, "I can't do anymore. I need a break," that is the time to challenge yourself to keep going another five minutes. Those who persevere for even an extra five minutes will win in life..
zed65
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 39
-Receive: 37


« Reply #14 on: August 24, 2013, 08:37:53 20:37 »

Nice links! It gives me more to think about.
But I want to control the load via a microcontroller so I can discharge a battery down to a certain voltage.
Also I want to draw (say 0.5amps) for one minute then shut off.

The circuits I've found that involves a microcontroller just uses it to display volt/amp on a LCD.
Maybe I should go like the one with a attiny and a DAC.

I must say that my version with the TIP35 works relly well, but as mentioned the TIP get HOT!
Logged
Wizpic
Global Moderator
Hero Member
*****
Offline Offline

Posts: 976

Thank You
-Given: 197
-Receive: 344



« Reply #15 on: August 25, 2013, 12:03:47 00:03 »

I can understand what you want to do, Is the load always 0.5amps ?
You got me the bug now and just for the fun of it I'm going to have a play with a micro version  Cheesy with shut of voltage and current monitor will let you know how it goes

wizpic
Logged

When you think, "I can't do anymore. I need a break," that is the time to challenge yourself to keep going another five minutes. Those who persevere for even an extra five minutes will win in life..
Gallymimu
Hero Member
*****
Offline Offline

Posts: 579

Thank You
-Given: 101
-Receive: 151


« Reply #16 on: August 25, 2013, 02:54:09 02:54 »

Nice links! It gives me more to think about.
But I want to control the load via a microcontroller so I can discharge a battery down to a certain voltage.
Also I want to draw (say 0.5amps) for one minute then shut off.

The circuits I've found that involves a microcontroller just uses it to display volt/amp on a LCD.
Maybe I should go like the one with a attiny and a DAC.

I must say that my version with the TIP35 works relly well, but as mentioned the TIP get HOT!


If the TIP35 works you are better off staying with it,  a MOSFET would dissipate the same power.  A BJT will be easier to control but the voltage output range will be limited by the Vce saturation voltage.  Glad it's working well for you.
Logged
LithiumOverdosE
V.I.P
Senior Member
*****
Offline Offline

Posts: 289

Thank You
-Given: 246
-Receive: 396


« Reply #17 on: August 30, 2013, 11:26:56 11:26 »

I was looking for something else and stumbled on article you might find of interest.

http://m.eet.com/media/1130553/13338-31705di.pdf
Logged
ritkostar
Newbie
*
Offline Offline

Posts: 7

Thank You
-Given: 20
-Receive: 28


« Reply #18 on: August 30, 2013, 01:06:12 13:06 »

Complete system:

http://www.techome.de/manuals/43606_EL9000_KM.pdf
Logged
Jean de la Rose
Inactive

 Muted
Offline Offline

Posts: 2

Thank You
-Given: 9
-Receive: 0


« Reply #19 on: August 30, 2013, 02:34:15 14:34 »

Open source system by Itead Studio, Overload :
 Features
    3A 12V adjustable electronic dummy load, 10mA and 10mV resolution
    30V Voltmeter, 10mV resolution
    3A Ammeter, 30mV resolution
    Base on Arduino (ATMega328P) , hardware and software open source
Shematic & Software on their site :
http://blog.iteadstudio.com/overload-source-code-release/

Jean
Logged
zed65
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 39
-Receive: 37


« Reply #20 on: January 06, 2015, 03:29:30 15:29 »

Hi, long time since last update.

Now I use a TLV274 op-amp as feedback. Also there is a MCP4822 DAC.
I still use the TIP-35 on a heatsink with a PWM controlled fan.

The specs are: 0-30v / 0-2 amps.
I have a software controlled way to discharge Li-Po battery to storage volt and some other features.



Logged
Vineyards
Active Member
***
Offline Offline

Posts: 130

Thank You
-Given: 36
-Receive: 25


« Reply #21 on: January 08, 2015, 02:54:40 02:54 »

I guess you want to keep it simple and avoid things like DAC's etc. Then you can trim down the system suggested by zed65. Replace the DAC with a second grade sallen key low pass filter, use an opamp to drive the output stage featured in his post. That should solve the problem.
Logged
Wizpic
Global Moderator
Hero Member
*****
Offline Offline

Posts: 976

Thank You
-Given: 197
-Receive: 344



« Reply #22 on: January 08, 2015, 07:33:47 07:33 »

I've had a quick look at it, not downloaded the files yet but will do later when on PC. There is one little thing I noticed which would cause me concern and that is your 4w resistor at 2amps say at 24v the heat would be 48w even at 12v is 24w at 2amps a lot of heat. Not sure what your max voltage is or load but if you are designing something to be universal then the parts need to be able to take it
I will have a closer look a bit later
Logged

When you think, "I can't do anymore. I need a break," that is the time to challenge yourself to keep going another five minutes. Those who persevere for even an extra five minutes will win in life..
zed65
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 39
-Receive: 37


« Reply #23 on: January 10, 2015, 06:00:26 18:00 »

Vineyards: I have a MCP4822 DAC.

Wizpic: Ooops sorry, I forgot to mention that I use a 100w 0.5ohm resitor. I only put the 4w resistor there to get the solderpads.

By the way, the design isn't bulletproof, 30v and 2amp through the 0.5ohm resistor is way to much!
Maybe a software maximum watt could do the trick.
Another thing is that I haven't got the 1-wire temp sensor to work properly, so for now I use a separate board to control the fan.
Logged
Vineyards
Active Member
***
Offline Offline

Posts: 130

Thank You
-Given: 36
-Receive: 25


« Reply #24 on: January 10, 2015, 09:29:05 21:29 »

What seems to be the problem with OW sensor?
Can you post the code?
Logged
Pages: [1] 2  All
Print
Jump to:  


DISCLAIMER
WE DONT HOST ANY ILLEGAL FILES ON THE SERVER
USE CONTACT US TO REPORT ILLEGAL FILES
ADMINISTRATORS CANNOT BE HELD RESPONSIBLE FOR USERS POSTS AND LINKS

... Copyright 2003-2999 Sonsivri.to ...
Powered by SMF 1.1.18 | SMF © 2006-2009, Simple Machines LLC | HarzeM Dilber MC