Author Topic: DIY TEC controller  (Read 20287 times)

0 Members and 1 Guest are viewing this topic.

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #25 on: January 24, 2017, 10:47:29 pm »
@Echo88
I'm not convinced a "hardware" solution is the ideal in our case. We will use different stuff inside the chamber, with different thermal mass and sometimes it will also produce heat so fiddling with hardware components for defining PID parameters is just not practical to do.

So my idea is still implementing something my own. I just found a very good explanation of how a PID controller must work. I will do some experiments with a arduino and a h-brigde ... let see how it works.

http://brettbeauregard.com/blog/2011/04/improving-the-beginners-pid-introduction/
 

Offline bertik

  • Contributor
  • Posts: 30
  • Country: ch
    • W's Laser Web Site
Re: DIY TEC controller
« Reply #26 on: January 25, 2017, 01:36:42 pm »
http://brettbeauregard.com/blog/2011/04/improving-the-beginners-pid-introduction/

Just to repeat, Arduino + H-brige PWM Controller using the autotune PID software of your link, has been implemented and tested over a couple of months inside out, it is describend in the link I gave at the beginning of this thread. The software needs however still some finishing touches, for which I need to find some time.
 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #27 on: January 25, 2017, 02:31:18 pm »
@bertik

my plan is to use some big ass off the shelf Arduino shield h-bridge to drive bigger thermal mass than a laser diode (my plan is to use up to 10A).

Because I don't need super temperature stability or accuracy like in laser cooling my plan is to use a more simple setup than yours without any custom PCB, just readily available Arduino shields.

So I'd like to slap together an Arduino a BME280 the TEC and the H-brigde and get it working as soon as possible.

Than after this, if it come out to be a good and easy to reproduce project I may also decide to share all the process (including source code) here.
« Last Edit: January 25, 2017, 02:33:54 pm by mimmus78 »
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #28 on: January 25, 2017, 03:07:01 pm »
The TEC do not like PWM very much, especially at higher currents. So the normal H bridges are really good to drive a TEC. It would need an extra filter inductor or similar to smooth out the PWM signal.  The normal arduino PWM is rather slow and thus a rather large inductor would be needed and one might hear it. 
 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #29 on: January 25, 2017, 08:10:36 pm »
Arduino is capable of 64KHz pwm, even more if overclocked to 20MHz. Eventually if for any reason I can't do filtering at this frequency my plan B is to use a raspberry that will go up to some MHz if needed... hope than to not convert the pwm circuit into a radio ...


 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #30 on: January 25, 2017, 09:09:06 pm »
The Arduino hardware can do fast PWM, but AFAIK the the Arduino software does not support this. The other point is that many H bridges have a limited speed, as they are made for Motors and thus high inductance.
 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #31 on: January 25, 2017, 11:32:50 pm »
Well this can be one reason my project with of the shelf parts can fail... anyway worth trying. It will be still an experiment where I can learn something.

Inviato dal mio Nexus 6P utilizzando Tapatalk

 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #32 on: January 26, 2017, 04:35:30 pm »
Some of the H-Bridges are fast enough to work with a reasonable PWM speed, at least in the 20 KHz range. At least one should check the speed, when choosing a chip of module. Slow PWM can still work if there is a inductor of sufficient size.

AFAIK there is not big deal using PWM directly from the registers and thus fast enough from the Arduino environment.

One should not use PWM without filtering. Using PWM, RC filtering and than analog (linear) control is still more efficient (for cooling) than PWM directly without and filtering.

For the start I would keep the voltage / current low - well below the maximum rating of the TECs. This can also help to improve efficiency, when you don't need the full temperature difference. It also helps to make the control fail safe so no fast HW damage from a SW problem. If needed one can have two TEC in series.
 

Offline TiN

  • Super Contributor
  • ***
  • Posts: 4543
  • Country: ua
    • xDevs.com
Re: DIY TEC controller
« Reply #33 on: January 27, 2017, 09:44:45 am »
a TEC in a winecooler-chamber to get <0,050°C stability?
This stability without a oil bath with stirring oil?
you are kidding.  :popcorn:

My last night test data shows getting 0.05C stability without any oilbath voodoo is easy-peasy :)
I used this setup almost 24/7 over last 2 months to test tempco of over 50 resistors. Cooking article with data results.  :bullshit:



The orange line is temperature of YSI 44031 thermistor in the small die-cast box with TEC on it's bottom side.
Time period on graph is 3 hours.

Yes, this is not a winecooler with large volume, I grant you that.
With bit more care on insulation and larger thermal mass block 0.01C stability should be not hard to achieve.
« Last Edit: January 27, 2017, 10:05:50 am by TiN »
YouTube | Metrology IRC Chat room | Let's share T&M documentation? Upload! No upload limits for firmwares, photos, files.
 

Offline Theboel

  • Frequent Contributor
  • **
  • Posts: 278
  • Country: id
Re: DIY TEC controller
« Reply #34 on: January 28, 2017, 12:46:17 am »
Hi TiN,
What TEC controller do You use ?
 

Offline TiN

  • Super Contributor
  • ***
  • Posts: 4543
  • Country: ua
    • xDevs.com
Re: DIY TEC controller
« Reply #35 on: January 28, 2017, 07:03:42 am »
Using Keithley 2510 I was lucky enough to snag 3 years ago on fleabay and fix and calibrate it.
YouTube | Metrology IRC Chat room | Let's share T&M documentation? Upload! No upload limits for firmwares, photos, files.
 

Offline Theboel

  • Frequent Contributor
  • **
  • Posts: 278
  • Country: id
Re: DIY TEC controller
« Reply #36 on: January 28, 2017, 08:14:21 am »
Using Keithley 2510 I was lucky enough to snag 3 years ago on fleabay and fix and calibrate it.


Ok thats  explain the stability :palm: :palm: :palm:
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #37 on: January 28, 2017, 09:19:50 am »
The Keithley 2510 acts as a really good quality regulator, and this way still shows that thermal setup is capable to get the good stability. However using one the one sensor also used for regulation is kind of cheating - it does not tell very much on how stable the temperature is at other positions in the box. The small box also helps a lot, as this makes it fast (time constant is proportional to the square of the dimensions). A faster system can have more feedback at a given frequency.

If the Ke2510 is using the build in PID function, there are still two points where a special purpose TEC regulator could improve on it:  The nonlinear current to power curve is usually relatively well known and the other side temperature can also be compensated.

The critical part for true stability is the sensor and the part to get the temperature reading, not the output part of the controller. So if you want to build a controller it is about the ADC, not so much the PWM (or DAC) resolution. With a suitable sensor, it is not that difficult to get mK resolution for the temperature reading.

The stability does not even look that good - at least with a second sensor a purpose made TEC controller should get better stability.
 

Offline TiN

  • Super Contributor
  • ***
  • Posts: 4543
  • Country: ua
    • xDevs.com
Re: DIY TEC controller
« Reply #38 on: January 28, 2017, 09:50:40 am »
Last year for some other tempco tests I was using two sensors (one on box wall, connected to 2510 to close the loop, second on resistor body, measured by K2001). Both sensors were same, Honeywell HEL-705 Pt1000 RTDs, and tracked well together.

Edit: datalog here (CSV data there too).
YouTube | Metrology IRC Chat room | Let's share T&M documentation? Upload! No upload limits for firmwares, photos, files.
 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #39 on: January 28, 2017, 10:46:36 am »
Kleinstein Actually I implemented sort of pid controller in python with a raspberry.
It uses two temperature sensors to regulate the temperature and two big ass resistor as heater.
It's used for measuring TCR for some resistors I want to use inside some LTZ1K.
One temperature sensor is "attached" to the resistor, the other temperature sensor sense ambient temperature.
Power to the resistor is calculated considering also variation in ambient temperature.
Despite using digital sensors (lot less precision than a RTD and lot of noise) I got 0.03°C temperature stability with almost no thermal mass.

If I get PWM circuit working, I think I will use 3 temperature sensors for this DIY controller.
One will be attached inside the chamber just above the TEC (and this will represent chamber temperature with the limits we know).
The second will measure temperature of the TEC heat sink.
The third will measure ambient temperature.

Now I still have another problem to solve. How to get info for the "the nonlinear current to power curve"?
I spent 3 minutes with Google, but I find nothing on the subject.


 

Online 2N3055

  • Super Contributor
  • ***
  • Posts: 6600
  • Country: hr
Re: DIY TEC controller
« Reply #40 on: January 28, 2017, 11:04:23 am »
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #41 on: January 28, 2017, 11:15:06 am »
With a TEC there is likely no need for a third sensor on the outside for the ambient temperature, but if will not really hurt. One might want an extra sensor inside the box, closer to the DUT.

The usual TEC follow a rather simple curve: Heat flow is mainly made up from 3 components: thermal conductivity between the two sides - proportional to the temperature difference, ohmic loss and the peltier effect.

This gives a parabola with a maximum cooling near the so called optimum current usually noted in the DS. The other obvious point is zero current. The maximum reachable temperature difference (from the DS) gives the ratio of cooling power to thermal conductivity. This only leaves on unknown scaling factor for the power, that one does not need for the regulator, as it is just a factor in the gain of the whole system.
 

Offline EmmanuelFaure

  • Regular Contributor
  • *
  • Posts: 154
  • Country: 00
Re: DIY TEC controller
« Reply #42 on: January 28, 2017, 06:03:27 pm »
I agree with Kleinstein.
@2N3055 & @mimmus78 : Here's attached a curve plotted for a jellybean 9A TEC.
 

Online 2N3055

  • Super Contributor
  • ***
  • Posts: 6600
  • Country: hr
Re: DIY TEC controller
« Reply #43 on: January 28, 2017, 06:58:15 pm »
I agree with Kleinstein.
@2N3055 & @mimmus78 : Here's attached a curve plotted for a jellybean 9A TEC.

Thanks Emanuel!!  That is pretty much same diagram like I put, but plotted differently.
Basically, like Kleinstein said, it's a parabola.. So, in order to have a predictable controller behaviour, linearization of current controller would be beneficial..

Take care!!
 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #44 on: January 28, 2017, 07:32:03 pm »
I do not have the datasheet for my sample. The I max is the number printed on the body of the peltier right?

Inviato dal mio Nexus 6P utilizzando Tapatalk

 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #45 on: January 28, 2017, 07:36:24 pm »
I think if you operate the peltier not at the limit current you can calibrate the parabola by finding some of the points.

Inviato dal mio Nexus 6P utilizzando Tapatalk

 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #46 on: January 28, 2017, 07:57:39 pm »
The exact shape of the parabola is only important in the regions close to the maximum current. For mode moderate currents it is not that important where the optimum current is. One could find the optimum current from a few test points - depending on how good the thermal contact is, it can be shifted to lower currents compared to the ideal DS value anyway. So an experimental value for the current that yields the bet cooling / lowest temperature might be better anyway.

Form the curves for different temperature differences show the parabola not perfectly parallel. So there seems to a slight deviation from the simple model - without individual temperatures it is hard to tell, if it is a temperature dependent peltier effect, thermal conductivity, or the usually small contribution of thermal EMF times current. Still I don't think one needs to care about the difference.
 

Offline EmmanuelFaure

  • Regular Contributor
  • *
  • Posts: 154
  • Country: 00
Re: DIY TEC controller
« Reply #47 on: January 28, 2017, 11:53:13 pm »
Thanks Emanuel!!  That is pretty much same diagram like I put, but plotted differently.
Basically, like Kleinstein said, it's a parabola.. So, in order to have a predictable controller behaviour, linearization of current controller would be beneficial..

Yup, but mine is computed with actual values :) This one is for a very common 'made in china' TEC1-12709.

To anyone interrested in this, there are the full equations :
http://electronicdesign.com/components/simple-design-equations-thermoelectric-coolers
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14181
  • Country: de
Re: DIY TEC controller
« Reply #48 on: January 29, 2017, 10:30:38 am »
Thanks for the link:
However, the equation for the cold side temperature has one obvious mistake: the last bracket is to much - you can't add thermal resistance to temperature.
 

Offline mimmus78Topic starter

  • Supporter
  • ****
  • Posts: 676
  • Country: it
Re: DIY TEC controller
« Reply #49 on: January 29, 2017, 05:43:48 pm »
Also this link can be usefull:

http://www.meerstetter.ch/compendium/tec-peltier-element-design-guide

Inviato dal mio Nexus 6P utilizzando Tapatalk

 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf