DIY编程器网

 找回密码
 注册

QQ登录

只需一步,快速开始

扫一扫,访问微社区

查看: 3886|回复: 2
打印 上一主题 下一主题

Hack a Toaster Oven for Reflow Soldering

[复制链接]
跳转到指定楼层
楼主
发表于 2012-10-6 11:40:21 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
Hack a Toaster Oven for Reflow Soldering




As I get more serious into my electronics hobby, I need to work with more SMD components. Some component packages are very difficult or impossible to solder with a traditional soldering iron. To solve this problem, I decided to hack a toaster oven to become a reflow soldering oven.

Basically, to perform reflow soldering, solder paste is placed on a printed circuit board, and the components to be soldered is placed on top of the solder paste. When the oven heats the solder paste past the melting temperature, the solder paste melts and solders the component to the circuit board.

To control the oven's temperature, I created my own reflow toaster oven controller circuit. This circuit uses an ATmega32U4 microcontroller to monitor the oven's temperature using a thermocouple and AD595AQ, and then control the oven's heating element using a solid state relay. The controller features USB logging/debugging, USB bootloading, a graphic LCD display, and 3 buttons. The firmware features tweaking for all settings, manual temperature control, manual heating element control, and automatic temperature profile control (with a nice temperature history graph display). This circuit will plug into a wall outlet, and the oven will plug into this circuit, while the solid state relay basically acts as a switch between the wall outlet and the oven's heating element. Safety is the main design objective (but some things were limited by cost), and ease of use is the second objective.

Here is a demonstration video:



Some more key features:
  •                 The thermocouple is rated to over 500 degrees Celcius. Soldering using my solder paste requires only up to maybe 250 degrees Celcius.
  •                 The solid state relay is used because they can provide better control than mechanical relays, and they are more reliable. Mechanical relays can wear out because of their mechanical nature, and from internal sparks that occur during switching. I plan on switching the relay at 1 Hz, so this is important.
  •                 The relay is rated for 240V and 25A so it should work with any typical toaster oven in any part of the world. The relay is cooled with a custom made aluminum heat sink and a small cooling fan.
  •                 Everything on this circuit is powered from the wall outlet because I'm using a tiny USB charger as a built-in AC-to-DC converter. This is good since one cable powers everything. A computer is not required to operate it.
  •                 A plastic cover is created to protect the circuit from things touching it accidentally. I can safely handle the circuit without getting shocked.


Included here (see bottom of this step) are all of the project files. This package contains the CadSoft EAGLE 5.11 schematic and PCB files, the PCB gerber files, the source code for the microcontroller firmware (including the bootloader), and some mechanical drawings for the heat sink and plastic shielding.


reflowsolderingtoasteroven_files.zip FS5SX8EGUGDAKR9.zip (1.34 MB, 下载次数: 0)


Step 1Before You Begin


There are several videos in this Instructable. Please watch them in full screen and 720p resolution, because there will be some text that you might want to read. The text content of this Instructable will also include additional notes and links. Most images from the videos will also be uploaded into the gallery. Most images (there are over 150 images in this Instructable) are annoted and sized in such a way that they do not suffer from image compression. The pictures, text, images, and files may not match exactly due to having revisions and different versions, but I'll guarantee that the text and files are in their final versions. I usually learn something new with every one of my projects and I put the important stuff in a final thoughts page and appendix at the end.

         Safety Notes This is probably the most dangerous electronics project I've done to date, involving high voltages and fire hazards. I am not responsible for your safety, and I am not liable for any claims, damages, or other liability. Do this project at your own risk.
  •                  Do not leave anything unattended, you need to know if sparks happen or a fire starts, and either power down everything quickly or evacuate.
  •                  Make sure you have a fire extinguisher handy.
  •                  Make sure that you are using a wall outlet that has a fuse or circuit breaker, just in case something short circuits.
  •                  Please use a GFCI wall outlet if you have one, this is the type of outlet that will cut power if you drop a hair dryer into a bathtub.
  •                  Remember the rule about wires: Any extension cords must be thicker than the cord that is already used on the toaster.
  •                  Once you use the toaster oven for soldering, you shouldn't use it for food again. Once you've put lead in this oven, your food will not be safe in the oven. Remember that lead is a slow accumulating poision, and it can cause mental diseases later.
  •                  Work in a well ventilated area.
  •                  Make sure you are aware of all materials that are near the toaster oven.
  •                  The circuit I've build does not have an ON/OFF switch for a reason. It forces you to completely unplug it when you are done.



Step 2Reflow Soldering Basics



To understand why I need something to precisely control the ovens temperature, you need to understand the stages of reflow soldering. See the graphs in the gallery for a general overview. This kind of graph, sometimes known as a reflow profile, is found in many datasheets so you can solder electrical components safely.

First, please realize that kitchen toaster ovens are terrible at keeping a certain temperature on their own, but it's good enough for cooking. You can't just count on using the temperature dial on the toaster.
Second, remember that heat expands materials and cold contracts materials. Heating too fast or cooling too fast can cause cracks. Uneven temperature distribution can cause things to bend or warp. You don't want things to break, and things that are bent won't solder properly due to poor contact.

Solder paste is generally a mixture of flux and microscopic balls of solder. The flux will clean the soldering surfaces when it is heated, and the balls of solder will melt and bond the surfaces.
When doing reflow soldering, you put some solder paste over the pads on the PCB. To make this easier, you can use a stencil made of a thin sheet of plastic, with holes laser-cut into it where you want solder paste (I will cover how to make and use stencils later). Place the components on the pads, then pop it in the oven and let it go through the stages.
  •                  The first stage is preheating to the thermal soak stage. The rate of heating needs to be controlled.
  •                  The second stage is thermal soaking the PCB and all the components. This stage ensures even temperature distribution and activates the flux to clean the surfaces. Note that larger components take more time to heat up, especially components with shielding.
  •                  The third stage is raising the temperature to melt the solder paste to perform the actual soldering.
  •                  Finally everything is cooled at a controlled rate.

This is why I need a controller to control the temperature of the oven automatically, going through all the stages at the right temperature, for the right time duration, and at the right heating or cooling rate.


Step 3Circuit Design and PCB Layout



Please watch the video as I explain how I designed the circuit. I will point out each component, show you where it is, and explain it in detail.


The design files are all included in the project downloads, it's mostly in CadSoft EAGLE 5.11 format, but I've included images as well.

The PCB layout isn't a complicated layout. There are some things I'd like to point out:
  •    The size needs to be under 10 cm by 10 cm so I can get it made by Seeed Studio for cheap (see next step).
  •    There are mounting holes on each corner. Later, I will show you how to make a plastic shield for this circuit, and that shield will be mounted to these holes.
  •    The PCB is designed with holes that the solid state relay will screw directly into. I really wanted a design with no loose objects.
  •    The high power traces are super wide and also the solder mask is removed so solder can be added to increase the track's thickness, allowing for more current.
  •    240V and 120V AC is VRMS, after calculating Vpeak, the recommended PCB trace spacing (according to IPC-2221) at is 2.5mm for 300V to 500V (240VRMS = 339.4Vpeak), 1.25mm for 150V to 300V (120VRMS = 169.7Vpeak). Note that this circuit is not safe over 10000 feet above sea level.
  •    I left a large space for the LCD. I actually have two LCD footprints on this PCB design, the other one has almost the same circuitry but uses SPI instead of I2C, and mounts directly to the PCB instead of using a flat cable. But I didn't write the code for this "other LCD".



Step 4Circuit Assembly Part 1





Here's a shopping list for electrical components:
                                 Qty                                 Sch Ref                                 Name                                 Value                                 Package                                 Rating                                 Notes
                                 1                                 C3                                 Tantalum Capacitor                                 10 uF                                 1206                                 6V or Greater                                 
                                 4                                 C4, C5, C6, C7                                 Ceramic Capacitor                                 0.1 uF                                 0805 or 0603                                 6V or Greater                                 
                                 2                                 C8, C9                                 Ceramic Capacitor                                 22 pF                                 0805 or 0603                                 6V or Greater                                 
                                 1                                 C10                                 Aluminum Caoacitor                                 47 uF or greater                                 6.6mm x 6.6mm                                 6V or Greater                                 
                                 1                                 C11                                 Tantalum Capacitor                                 4.7 uF                                 1206                                 6V or Greater                                 
                                 10                                 C1, C2, C12 to C20                                 Ceramic Capacitor                                 1 uF                                 0805 or 0603                                 6V or Greater                                 
                                 1                                 IC1                                 LM1117                                 3.3V                                 SOT-223                                                                   
                                 1                                 JP1                                 Male Header                                 3x2                                 0.1" Pitch                                                                   Standard 6 Pin ISP Header for AVR
                                 1                                 JP2                                 Screw Terminal                                 2 Pins, SparkFun PRT-08084                                 3.5mm Pitch                                                                   For thermocouple
                                 1                                 Q1                                 Crystal                                 16 MHz                                 HC49 SMD                                 20 pF, +/- 30 PPM                                 
                                 2                                 R1, R2                                 Chip Resistor                                 22 Ω                                 0805 or 0603                                 1/10 W, +/- 10%                                 
                                 4                                 R3, R4, R7, R8                                 Chip Resistor                                 10 kΩ                                 0805 or 0603                                 1/10 W, +/- 10%                                 
                                 1                                 R6                                 Chip Resistor                                 330 Ω                                 0805 or 0603                                 1/10 W, +/- 10%                                 
                                 2                                 S1, S2                                 Button Switch                                 TL3330                                                                                                     
                                 3                                 S3, S4, S5                                 Button Switch                                 TL6120DF                                                                                                     Must be super tall
                                 1                                 USB                                 USB Mini-B Female Connector                                 UX60A-MB-5ST                                 SMD                                                                   My favorite, easy to solder, flat bottom
                                 1                                 LCD                                 LCD COG Graphic Display                                 NHD-C160100DiZ                                 160x100 Pixel                                                                   
                                 1                                 LCD                                 FPC Connector                                 A100284CT, 1-1734592-4                                 14 Pos, 0,5mm Pitch,
                                 Right Angle SMD
                                                                   
                                 1                                 U1                                 AVR Microcontroller                                 ATMega32U4-AU                                 44 TQFP                                                                   
                                 1                                 U2                                 Thermocouple Amplifier                                 AD595AQ                                 14 DIP                                                                   
                                 1                                 U2                                 Chip Socket                                 14 Pins                                 14 DIP                                                                   
                                 1                                 Relay                                 Solid State Relay                                 D2425 by Crydom                                                                   240 VAC, 25 A                                 
                                 1                                 JP2                                 Thermocouple,
                                 type K
                                 GK11M,
                                 by Test Products Int
                                                                   -40 to 510 °C                                 
                                 1                                                                   USB Wall Charger                                                                                                     120V or 240V AC to 5 V DC, 1000 mA                                 Used as wall AC to 5V DC converter
                                 1                                                                   Cooling Fan                                 5V DC                                 40mm x 40mm,
                                 10mm to 17mm thick
                                                                   
                                 1                                                                   AC Extension Cord                                                                   16 AWG or Thicker                                 300V                                 

Solder these components to the PCB, follow the PCB design.

To get a PCB, download the project files, and send the Gerber files to a PCB manufacture. I used Seeed Studio 's Fusion PCB Service, it'll cost you $29 for 10 pieces.

Most components are 0805 (but can be substituted with 0603), everything on the PCB can be hand soldered. Surface mount soldering is easy, as demonstrated in my video:


There are several special connections you need to make, see the diagrams in the gallery about the following:
  •                  You need to solder a thick extension cord to the circuit. I live in North America, so one wire is "hot" and one wire is "neutral". Your country might use a slightly different system, but if you don't mix up the wires, this circuit should also work for your country.
  •                  As I mentioned before, a cheap USB charger is used as 5V DC power supply that converts AC power to DC power. After you hack that charger (the instructions will be in another "Instructable Step"), the diagrams show you where to make the connection.
  •                  I used velcro to attach the LCD to the PCB. Connect the flat cable into the FPC connector. Solder the backlight wires to the connection for the backlight.

You need to put a lot of solder onto the wide exposed AC tracks so it can handle the large amount of electrical current.

Clean the PCB using alcohol or flux cleaner. Leaving flux on the PCB might cause inaccurate readings from the AD595AQ.

The schematic has some notes on it, I hope you read them.


Step 5USB Wall Charger Hack








Find the USB wall charger I used. It has to be small, works with 120V AC and 240V AC (so it works in both North America and other places), and supplies 5V DC at 1000mA.

Cut it open, I used a saw to cut off the two ends.

Unfolded it. Soldered two wires for the AC power input (polarity doesn't matter, so I used two black wires). Solder another two wires to the USB port where the 5V DC output and DC ground is, I used a black wire for ground and red for 5V since polarity is important here.

I suggest you use 22 gauge stranded wire for all of this. 24 gauge is acceptable. Stranded wire is flexible.

Insulate the entire device. I used electrical tape for this. A huge heat shrink tube would also be acceptable.

Connect your new wires to the appropriate locations on the controller PCB, as shown in my diagrams.


Step 6Thermocouple Modification


You can avoid this step if your thermocouple does not have any special connectors on the end. Try buying the K type thermocouple from Adafruit Industries (product ID 270), or SparkFun version (SEN-00251). The one I used is a GK11M from Test Products Int.
The thermocouple I used has a special plug. Nobody sells the actual socket for this plug (it's really designed for a specific hand-held device).

So I had to connect some wires to the thermocouple, and then plug the wires into the terminal block.

Remember that polarity is very important here so I used red wire for where there is a plus sign (chromel side) and black wire for the negative sign (alumel side).

Remember to use the same type of wire for both wires. If you use copper for the red wire, you must use the exact same copper for the black wire. It doesn't have to be copper but both wires must be the same material, because different metals would have a small voltage difference that will mess up the voltage readings.

Please read the appendix about how thermocouples work.


Step 7Heat Sink





The manufacture for this solid state relay actually sells the appropriate heat sinks designed specifically for their relays, they are somewhat expensive. But I'm a cheapskate DIY loving university student who has access to free scrap metal at school, so I built my own heat sink.

From the datasheet, there is a graph (see in gallery) that shows what the thermal resistance of the heat sink needs to be. I'm going to use 25 degrees C as room ambient temperature, and 15A. If you look at the graph, you might think a 4 C/W heat sink is enough.

Why do I think I can make a heat sink that's suitable? This HS351 heat sink is 3 C/W:

It's just a simple tiny piece of aluminum. I think my heat sink will be just as effective, plus I have a cooling fan. The heat sink I made also makes it easy for the entire circuit to sit on a surface, unlike the small heat sink that you can buy.

During the first test, I used the relay with a 120V AC, 1300 watt toaster oven, in a basement room that's at about 18 degrees C, at maximum power output for 20 minutes. The temperature of the relay and heat sink was measured using an infrared temperature measuring gun and it never reached over 30 degrees Celcius. This shows my heat sink is sufficient.

         Enough Rambling, How to Build the Heat Sink:
  •                  Buy some sheet aluminum that you can cut, bend, and drill (or punch)
    •                                  Before continuing, please note that the cooling fan I used, I basically found in the trash, so I don't know where you can get one EXACTLY like it. Just make sure it's 40mm x 40mm square, around 15mm thick, and runs on 5V DC. The dimensions of my heatsink depends slightly on the size of the fan, so be smart about adjusting the dimensions a bit if the fan you get won't fit.
  •                  Buy some heat sink compound, you need this stuff to conduct heat between the metals, it will fill up any microscopic gaps where heat doesn't transfer.
  •                  Cut out the pieces of aluminum according to the mechanical drawings you've downloaded
  •                  Drill the holes so you can attach the fan with screws (#4 or #6 machine screws)
  •                  Drill the holes you need for the relay as well (#6 or #8 machine screws)
  •                  Bend the aluminum sheets only after all cuts have been made and all holes have been drilled
  •                  At this point, you should attach the cooling fan (#4 or #6 machine screws)
  •                  You need to apply some heat sink compound between each layer before screwing them together
  •                  Screw all the aluminum pieces together after applying the heat sink compound (#6 or #8 machine screws)



Step 8Final Circuit Assembly




Look at the diagrams while doing the next few steps.

Now you can screw the relay into the bottom side of the PCB, the relay should have come with the screws you need already. Check the orientation of the relay, but the hole spacing is slightly different on each side so it's not really possible to screw it in backwards.

Solder the fan's wires to the PCB, watch your polarity. (I didn't have any connectors, but if you want, use a polarized Molex or JST connector for this)

Solder the modified USB charger's wires to the PCB, watch your polarity. (I didn't have any connectors, but if you want, use a polarized Molex or JST connector for this)

Use a flux cleaner to clean the flux off the PCB. I have this spray can that is absolutely magical at this job. I've discovered that the flux actually affects the thermocouple readings greatly so cleaning it is important.

Tuck away anything that is loose, and secure it. I tucked everything under the PCB and secured it down with electrical tape.


Step 9Programming and Using the Bootloader


Please watch this video, where I show you how to compile the bootloader, how to flash the bootloader into the microcontroller, how to use the bootloader, and how to install the driver you need.


To actually do any of the things in the video, you need to have a working GNU tool chain setup. Follow some of these general AVR tutorials, which should get you started:
All of the code you see in the video is included in this project's download files


Step 10Firmware


All of the source code are included in this project's download files. They are completely commented.
The code is composed of several components:
  •                  A virtual serial port is implemented using the code provided by PJRC . If you need the drivers, go to their site.
  •                  I wrote three functions to communicate to the LCD via I2C, then several more functions to initialize the LCD and draw stuff on the LCD. There's also a 8x5 pixel font that is stored in flash memory so I can write text easily to the LCD. (The font is generated by a custom tool I wrote, but you can also find a similar font on Newhaven Display's website)
  •                  One file handles the behaviour of the menus, another file handles gathering temperature reading sample, another file is responsible for saving/loading data from EEPROM memory.
  •                  The main file handles calculations for temperature control, and automatically going through the reflow soldering stages. It also handles initialization of the various AVR internal hardware like timers.

There are some major details I need to point out here:
  •                  When you use "%d" with "printf", the argument is taken as a signed 16 bit integer even if the variable is not, so I wrote "str_from_int" to overcome this limitation. I also wrote "str_from_double" for convenience, as using "%f" doesn't offer much formatting control and "dtostrf" makes the code messy.
  •                  The LCD, NHD-C160100DiZ, has a datasheet that says that the maximum I2C clock frequency it can use is 400 KHz. This is false, it will not respond at that frequency and will freeze the I2C bus completely. I've also tried 280 KHz and it still would not work. Finally I used 100 KHz, and it started working.
  •                  The LCD's frame rate is ridiculously slow because of my relatively slow microcontroller (running at 8 MHz), the low I2C bus frequency (100 KHz), and the fact that a lot of font data is stored in flash memory instead of RAM.
  •                  I'm using PWM to control the solid state relay. My reasoning is that I can control the heating element as if I was controlling the brightness of a LED. The PWM frequency has to be low, for the reasoning behind this, see the appendix.
  •                  The PWM value used is ranged between 0 to 65535. So OCR value 0 means 0% duty cycle, OCR value 5000 means 7.6% duty cycle, OCR value 40000 means 61% duty cycle, and OCR value 65535 means 100% duty cycle.
  •                  The AD595AQ chip outputs a square wave instead of a constant voltage, the top of the square wave is the voltage that should be read as the temperature. I'm not sure if this is intentional and a part of the AD595AQ's design (I can't figure this out from the datasheet), or if it's my fault somehow. Regardless of the reasoning, the sensor reading routines I wrote accounts for this and will sample only the top of the square waves, it also does averaging.
  •                  The raw sensor value is ranged between 0 and 1023 because the ADC on the AVR has 10 bits of resolution. 1023 means the reading is 3.3V because the analog reference voltage is 3.3V. According to the datasheet of the AD595AQ, the output voltage for 320 degrees celcius is 3.227V (0 degree is 0.027 volts, by the way, pretty close to 0, the AD595AQ is supposed to output 10 mV per degree Celcius). From these numbers, I know that 1 degree celcius is 3.125 raw ADC reading units, and 1 raw ADC reading unit is about 0.32 degrees Celcius. These conversion calculations are hard coded into my source code. You should remember the constant of 0.32 when dealing with the log files.
  •                  A PID controller is used to calculate the appropriate amount of power to deliver to the heating element. The user is able to edit the PID constants using the user interface.
  •                  This PID controller is not a typical PID controller, it is assisted by using information that is already known about the toaster oven's characteristics. You are allowed to input the highest steady temperature that the oven can achieve, and how long it takes to achieve that temperature. From this information, the controller knows how to estimate the correct amount of power to deliver. The PID controller is used to tweak this estimation, which corrects for the non-linearity of the estimation.
  •                  Note: Use the "manual PWM control" mode to measure the highest temperature you can achieve and how long it takes to achieve it. Do this by going into that mode from the menu, and turn up the PWM to max, and then save the log reading (or use a stop watch).
  •                  There are error checking in the temperature profile and device settings. The software won't allow you to make edits that do not make sense, and if something is wrong, it'll ask you to correct it before continuing.

Refer to the previous "Instructable Step" about the bootloader to see how to compile and bootload the application code, there is even a video in there.


Step 11Plastic Shield




Please see the mechanical drawings in the project downloads. Cut a sheet of 2mm thick acrylic (cheaper) or polycarbonate (stronger) to the square shape and drill the appropriate holes.
Note that the picture is missing a hole that exists in the drawing. That hole is so you can access the screw terminals.

I hot glued some 0.25" long #8 machine screws to the buttons so they will stick out over the plastic shield.

Before you attach the sheet of plastic over the PCB, you need to program the AVR microcontroller first, that's actually in another "Instructable Step". When you finish that, use 1" long #4 machine screws and nuts to attach the plastic shield to the PCB. (I didn't have any stand-offs, use stand-offs if you want)

This will go over the PCB and protect it from things falling onto it, and protect your fingers from the uninsulated areas on the PCB. But if you actually tried to stick your finger under there, you can still get hurt. Keep this thing away from people who don't understand it.

This step comes after all of the software tasks, because it's not possible to use the ISP header if the plastic cover was on.


Step 12Toaster Oven Modification





You need to modify a toaster oven. The goal of the modification is to connect the top and bottom heating elements directly to the AC power cord, instead of the toaster oven's own control dials. Please watch this video presentation where I show you how to perform this modification in a safe manner.


To summarize my steps:
  •                 Disassemble the toaster oven, and clean out the food crumbs if it's used
  •                 Find the wires for the heating elements and the AC power cord, and disconnect them from the dials
  •                 Connect the heating elements directly to the AC power cord. Do this in a safe manner using safe materials.

I want to repeat my safetly notes:
  •                 My oven is a 1300 watt oven, and its AC power cord uses 16 gauge wire. Your extension cord must be 16 gauge or thicker to safely handle the same amount of electrical current.
  •                 The wires used inside have a heat resistant insulation so they will not melt if they touch the hot oven enclosure. If you use any plastic insulation, the insulation may melt or burn, and cause a short circuit. You can't use electrical tape for the same reason.
  •                 Solder cannot be used inside because it will get very hot
  •                 Things are mounted securely so they don't touch the hot oven enclosure

Further performance enhancing modifications were made after testing, which are discussed later.


Step 13Menu Usage



Watch this video where I show you how to use the menu (warning: kind of boring)


There are three buttons, the top button is used as "select" or "add", the middle button is used as "next menu item" or "exit current mode", the bottom button is used as "subtract".
The main menu offers 4 options:
  •                 "auto mode" is for automatically going through a reflow soldering process
  •                 "manual temperature control" is used to keep the oven at a steady temperature
  •                 "manual PWM control" is used to deliver a steady amount of power to the heating element
  •                 "edit settings" is where you can adjust the PID constants, the oven's maximum temperature and the time it takes to achieve the maximum temperature
  •                 While in "auto mode", you can set the characteristics of the temperature profile, and then press "select" while on the "start" menu item to start. Press the "exit current mode" button" to stop the cycle. Once started, you'll see the current temperature, target temperature, current stage, and a temperature history graph being drawn on the LCD.

The screen refresh rate is slow, keep that in mind, you might need to hold down the button for a second before it responds.


Step 14Testing, Tuning, Logging





In the following video, I show you how I test my circuit, how to log the temperature data during the testing, and how to use this data to configure the settings.


To Summarize:
  •    Power up the circuit, the firmware should run.
  •    Plug in the modified toaster oven. Insert the thermocouple inside the toaster oven. I tied a knot to secure it in such a way that it doesn't contact the metal inside.
  •    Connect to your computer via a USB cable. It should show up as a virtual serial port. Install the driver if you need to.
  •    Use the menu to run "manual PWM control". Set the power output to maximum by setting the PWM duty cycle to maximum.
  •    Turn it off when the temperature does not increase any more.
  •    Use a serial termial to watch the log file. Save the log and open it up it a spreadsheet application like Excel.
  •    Calculate the maximum temperature that was reached and calculate how long it took to reach it. The raw sensor values needs to be multiplied by 0.32 to be converted into degrees Celcius.
  •    Use the "edit settings" submenu to adjust the values.

  Notes I Made During First Test
  •    You might have noticed that I placed the oven on top of a sheet of wood. This is safe, as most kitchen counters are made of laminated wood.
  •    The maximum temperature reached greatly varies with the distance to the heating elements, as does the time it takes to reach that temperature. This is obviously expected but not to the extent I witnessed, 2 inches meant a difference of 100 degrees. I wish I had a thermal imaging camera to visualize this. So don't worry if the data in the video showed the temperature rising too slow, I can just move the thermocouple up to speed it up.
  •    Due to the above observation, I plan on using ceramic tiles to raise my PCBs up a bit while performing the actual reflow soldering. Ceramic or bricks can handle the high temperatures without problems. A steel solution can also be considered. Do not try to use wood for this.
  •    I measured the temperature of the relay and heat sink during operation and they never reached over 25 degrees during the entire duration of the test (120V AC, 1300 watts, 20 minutes on full power, inside a cold 18 degree basement room). I think this means the heat sink is effective.
  •    The constant pulses to the heating elements caused the fluorescent lighting in my basement to dim and brighten repeatedly. I'll also note that I've very happy with how effective the PWM control is at controlling the power output.
  •    The temperature readings are accurate and stable while temperature is increasing, but it is sometimes buggy and noisy while the temperature is decreasing. The majority of the reflow soldering process involves raising the temperature so this isn't a major concern. It must have something to do with how thermocouples work.
  •    The thermocouple's insulation does indeed handle the extreme temperature inside, but it did become darker. It is supposed to be rated to 510 degrees C, I think it lives up to that.
  •    Oven thermometers heat up slower but stays hot for longer. The reading from the thermocouple is pretty much instant.

  Data Format
From this serial port, data is sent in comma-seperated-value format. You can use a serial terminal to log this data into a .csv file and then open it in a spreadsheet program. Remember that raw ADC readings must be multiplied by 0.32 to convert it to degrees Celcius, and PWM OCR values are between 0 and 65535.

In "manual temperature control" mode, the text you see will look like
1, 234, 567, 559,
2, 237, 567, 564,
3, 232, 567, 536,
4, 235, 567, 524,

The format is
time in seconds, raw ADC reading, target ADC reading, PWM OCR value

In "manual PWM control" mode, the text you see will look like
1, 567, 559,
2, 567, 564,
3, 567, 536,
4, 567, 524,

The format is
time in seconds, raw adc reading, PWM OCR value,
Note: Use this mode to measure the highest temperature you can achieve and how long it takes to achieve it.

In "auto" mode, the text you see will look like
0, 1, 567, 559, 524,
0, 2, 567, 564, 559,
1, 3, 524, 559, 559,
1, 4, 567, 524, 564,
1, 5, 564, 559, 559,
1, 6, 567, 564, 524,
2, 7, 567, 559, 559,
2, 8, 567, 559, 564,
2, 9, 564, 559, 559,
3, 10, 567, 559, 559,
3, 11, 564, 559, 564,

The format is
stage number, total time in seconds, raw ADC reading, target raw ADC reading, PWM OCR value,
time doesn't reset if the stage changes

  Tweaking Run through the auto mode a few times to test it, remember to save the log data to help you. If it doesn't keep the temperature steady or heat/cool at an unsteady rate, then adjust the PID constants from the "edit settings" submenu.

If the temperature tends to rise too fast, then lower the P constant. If the temperature doesn't rise fast enough, then raise the P constant.

Adjusting the I and D constant will affect overshooting or oscillating behaviour. This takes experimentation.

If all else fails, try to just turn up the P constant up really high and set I and D to 0, this will effectively stop the software from using PWM and just turn on the relay if the measured temperature is below the desired temperature.

  Test Run After tuning and performance optimization, you should run the "auto mode" reflow cycle just to see what the temperature curve looks like. I did this with a junk PCB populated with a single resistor just as a test. In the pictures, you can see I didn't do the cleanest job because I applied the paste with the syringe tip directly without a stencil. But the solder did melt and the component is soldered in place perfectly.


Step 15Performance Improvements




The very first test showed that the temperature reached 225 degrees Celcius in 520 seconds, and 260 degrees Celcius in 900 seconds. This is a little too slow.

I then raised the rack about 1.5" closer to the top heating element, and sealed most of the holes and tiny seams inside the oven using aluminium tape. This isn't the smartest idea since I had no idea what temperature the adhesive can withstand, but it seems to be OK.

After these changes, the temperature reached 225 degrees Celcius in 360 seconds, and 260 degrees Celcius in 570 seconds.

Then I applied a layer of aluminium tape to the front glass door, covering the bottom 2/3 of the glass door. I then performed another test: 225 degrees Celcius in 320 seconds, and 275 in 560 seconds.

This is just fast enough for reflow soldering according to the temperature timeline that I am following, but more improvements would need to be made.

I stuffed the inside of the oven with a layer of pink fiberglass insulation. This stuff is not electrically conductive and can handle a temperature of 500 degrees Celcius. It is safe for use in my situation.

I also found a large brick to place in the oven. The purpose of the brick is to occupy volume so there is less air inside the oven to heat. The brick is covered with aluminium foil to stop it from absorbing heat too fast. This brick actually did not get very hot, it is actually cooler than the surface of the glass door. It does its job exactly as I expected it to.

I am very happy with the final results: 225 degrees Celcius in 300 seconds, and 275 degrees in 540 seconds. I can reach the end of the "soak" stage in just 3.5 minutes.


Step 16Solder Paste Stencil


Here is a video showing you how to generate a Gerber file that you can use to create a solder paste stencil using CadSoft EAGLE 5.11


To Summarize:
  •                  Open up your PCB drawing in Eagle. The solder paste layer is the "tCream" and "bCream" layers, for the top and bottom. Enable these layers to look at them. This is where solder paste will be placed, and where the holes will be cut into your stencil.
  •                  I recommend you print out those layers with 1:1 scale on paper, so you can check that the footprints will match your components.
  •                  Open up the CAM processor, set it to generate for only the tCream layer (or bCream) and the dimension layer. Make sure it's generating a Gerber RS274X file. "Pos coord" and "optimize" should be enabled. The file extension should be ".gtp" for Gerber Top Paste. Run the job.
  •                  You can double check the file you generated in a Gerber file viewer. Once you are happy, send it to somebody with a laser cutter, who will use the file to cut your stencil.
Other Notes:
  •                  You can place multiple designs together by cloning your design in Eagle. Do this if you want to make two or more stencils per sheet of plastic.
  •                  If your board is a single sided design, you only need one file. If you have a double sided design, you need one for each layer.
  •                  According to SparkFun, 4 mil thick stencils are good for 0805 or 1206 sized components and 3 mil thick stencils are good for finer pitched components. The thickness of the stencils determines the thickness of the solder paste that is applied.
  •                  If you don't want to spend the money on a stencil, you can also carefully manually apply the solder paste to your PCB using a toothpick, or buy the paste in a syringe.
I only know three companies that can make affordable stencils for hobbyists (if you know more, post in the comments):
  •                  Pololu, they sell robot parts but can also do laser cutting for you, they can make Mylar stencils for you
  •                  Ohararp, they make Kapton stencils using a laser cutter
  •                  QuickStencil, they sell complete reflow soldering kits with custom laser-cut steel stencils, expensive
When designing a PCB that you intend on soldering by reflow, you need to consider the following:
  •                  large copper planes will dissipate heat fast, when a pad is on a plane, it usually uses "thermals" to lower the heat transfer between the pad and the plane.
  •                  The area that the paste covers is usually as big as the pad. But for chips with a exposed bottom pad, only about one quarter of the center pad should be covered with paste.
  •                  Having a solder stop mask is the best way of preventing solder bridges between pins.
  •                  You can pre-bridge solder jumpers by putting solder paste over it before reflowing. This is useful if you use stencils to "mass produce" with a default jumper setting.



Step 17Performing Reflow Soldering





Watch the following video presentation, where I show you how to perform reflow soldering:


Here are some other tutorials from other websites: Shopping:
  •                  Purchase some solder paste, I got some leaded paste from Deal Extreme. SparkFun sells them too (TOL-10448). I also got a syringe tube of Chip Quik solder paste.
  •                  Keep the paste sealed and cool, I put it in a zip lock bag and then in my fridge. This stuff is kind of expensive.
  •                  Tweezers are a must, also get one of these suction component placement tools (see picture in gallery). I got mine from eBay.

Summary of Steps:
  •                  Secure your PCB to a surface first. Do this by surrounding it with other PCBs that are the same thickness so the entire surface is still flat. Use some tape to do this.
  •                  Then secure your stencil over the PCB, making sure everything is aligned. Tape it down.
  •                  Apply the solder paste using a squeegee (credit cards work for this if you are a cheapskate like me). Pass over it twice, the first time should be soft to make sure that the paste covers everything, the second time should be hard to scrape off the extra paste.
  •                  Save the extra paste, put it back in the container. Clean the stencil later using rubbing alcohol and paper towel. Don't take too long as alcohol can cause some plastics to warp out of shape.
  •                  Remove the stencil carefully. Inspect the paste job.
  •                  Place the components onto the paste using your tweezers or that special suction pen tool thing.
  •                  Put the PCB into the oven. Stick the thermocouple into the oven as close to the PCB as possible (don't let the thermocouple touch anything conductive). Run "auto mode". The default settings I put in are shown in the reflow profile graph I've shown in the gallery.

If you notice that the cooling is too slow, you can open the door just a bit, while watching the LCD display so you don't cool too fast.

After it's finished, take it out of the oven and your circuit should be all soldered.

You need to clean your PCB using alcohol or flux cleaner, unless you are using "no clean" solder paste.

         Potential Problems:
  •                  Large components might not be soldered well due to their huge heat capacity. If you have a large component that didn't reach the right temperature, make a note so you increase the thermal soak time for the next attempt.
  •                  If you get solder bridges, you should use a de-soldering wick to remove the bridge. Try using less solder paste next time, or use a thinner stencil.
  •                  Solder paste not melted? The temperature didn't reach the melting point at that location. Do a few adjustments to the settings and do a few tests to make sure the solder will melt.
  •                  If you have melted solder but the component didn't really make a joint, consider adding more solder and flux. The temperature might be too low. The component might also be dirty. Also, remember that if the component doesn't sit flat or is warped, it can't be soldered well.
  •                  If you see too many little balls of solder that are just sitting around, you might be pre-heating for too long or your solder paste has gone bad. This is sometimes caused by the lack of flux, or the pre-heating period dried out all the flux for too long.
  •                  If your solder paste is dried out, buy some liquid flux and stir it in.



Step 18Final ThoughtsThe AD595AQ chip is a old chip and it costs $20 each. Newer designs should use a newer and cheaper alternative. Example: MAX31855 or MAX6675

I did find some other relays with similar ratings but the only way they can achieve those ratings is by using a heat sink or with a cooling fan. So I decided the "puck" shaped relay is a great idea since it makes it easy to mount.

A full enclosure would have been the best idea. The plastic shield offers enough protection for me to handle my circuit, but I am still able to be shocked if I tried to stick my finger underneath the plastic.

For the toaster oven I chose, I have to raise the PCB closer to the heating element. See my test results from before. I did this using ceramic tiles or a brick. This lowers the amount of air that needs to be heated as well, which should speed up the rate of heating (adding same amount of energy into less volume). However, solids have more heat capacity than air, which should actually slow down the rate of heating as (it takes in more energy). But since it'll take more time for the solid to suck the energy out of the air, the final effect should still be that it makes the air get hotter faster.

This project can easily be ported to the ATMega328P, which is important if you really want to use an Arduino. Please note that my circuit is running on 3.3V, and although a 16 MHz crystal is used, it's actually running at 8 MHz. I might design an "Arduino Shield" version of my circuit later.

I have seen similar projects using mechanical relays that simply turn on and off the heating element, with the slow reaction time of the heating element, this apparently works well enough.

I am capable of building my own AC to DC converter circuit, but I just don't feel like it's worth the effort for this project. I would have had to squeeze it in the PCB design as well.

The heat sink is not grounded. I did not find any reliable documents that indicates that it is safe to ground the heat sink. It probably is safe to ground it, but you might not be using a grounded extension cord. My toaster oven isn't grounded.

Arduino Leonardo's bootloader (currently in beta as the date of this page) should also work, but I don't want to rewrite a lot of instructions.

This Instructable has so many videos because I'm experimenting with different methods of presentation. I've used computer screen capture, panning around in CadSoft EAGLE with both the schematic and PCB side-by-side, 720p video recordings with my new smartphone, slide shows, and fooled around with video editing a lot. I like using videos to get my thoughts out in the order I want to present in, and then providing a text and picture summary, which I can use to fill in gaps that the videos did not cover.


Step 19Appendix



         PWM Frequency and the Solid State Relay The solid state relay is built using a TRIAC (or something similar, like two thyristors) because it needs to handle large alternating currents. Remember that we are trying to put 120V AC at 60 Hz (these numbers are North American) through this relay.

Wikipedia on thyristorshttp://en.wikipedia.org/wiki/Thyristors
omega.com: Solid State Relays (pdf)

Once you trigger a thyristor, it starts to conduct, but it will not stop conducting until the voltage reaches zero.

This also means if you tried to power the heating element with a DC power source, once the relay has been triggered, it will stay on forever. So do not attempt to use a DC power source. (Also, if you did use DC, you would probably fry the USB charger).

The fact that thyristors won't stop conducting will make high frequency PWM ineffective as the PWM duty cycle won't correlate to the power delivered to the heating element. When a pulse from the PWM output ends, it doesn't mean the AC current is turned off.

If a low PWM frequency is used, then you have more control over how much power is being delivered. If the PWM frequency is 1 Hz, PWM duty cycle at 50%, and the AC power is 60 Hz, then you are basically saying "I want to let about 30 out of 60 oscillations through per second". The relay will try to turn it self off 60 times per seconds at regular intervals, unless you keep the input signal high.

The gallery includes a few diagrams that illustrates what I'm saying in terms of voltages and waveforms.

The Crydom solid state relay is actually more complicated because it has special zero-cross triggering. This means the relay will conduct immediantly after the voltage is zero (instead of at any time) and turn off immediantly when the voltage is zero again if the trigger is removed. What I am saying still applies. The output waveform will always start at 0V and end at 0V, which is good for equipment that doesn't like being turned on too fast.

There are special solid state relays that can control the output waveform according to a linear input (and thus, filtered high frequency PWM can be used). But these cost more, and the heating element doesn't react fast enough for this to be useful anyways.

         How Thermocouples Work Wikipedia about thermocouples http://en.wikipedia.org/wiki/Thermocouple
Maxim application note 4026 http://www.maxim-ic.com/app-notes/index.mvp/id/4026

I used a K type thermocouple, with the AD595AQ thermocouple amplifier chip. The K type thermocouple is made of a junction between chromel and alumel, where a small voltage is generated proportional to the temperature difference at the junction. The AD595AQ is designed to amplify the small voltage between the chromel and alumel to a voltage that is 10 mV per degrees Celcius. The AD595AQ features "cold junction compensation", which basically it means it can use room temperature as the reference voltage.

Remember how I said you must use the same metal for the wire that connects the thermocouple to the terminal block? For example, using copper, the voltage beween the alumel and copper would be cancelled out by the voltage between the chromel and copper, while the left over voltage would be proportional to the temperature. As another example, if you used copper connected to the chromel and steel to connect the alumel end, then your final voltage reading would be the voltage between the alumel and chromel plus the voltage beween the copper and steel, which is not accurate.

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友 微信微信
收藏收藏2 分享分享 支持支持 反对反对
沙发
发表于 2015-10-25 22:36:33 | 只看该作者
感谢楼主提供这么好的交流平台
板凳
发表于 2017-2-11 15:20:04 | 只看该作者
真是牛人啊!
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|文字版|手机版|DIY编程器网 ( 桂ICP备14005565号-1 )

GMT+8, 2024-12-24 00:25 , 耗时 0.106627 秒, 20 个查询请求 , Gzip 开启.

各位嘉宾言论仅代表个人观点,非属DIY编程器网立场。

桂公网安备 45031202000115号

DIY编程器群(超员):41210778 DIY编程器

DIY编程器群1(满员):3044634 DIY编程器1

diy编程器群2:551025008 diy编程器群2

QQ:28000622;Email:libyoufer@sina.com

本站由桂林市临桂区技兴电子商务经营部独家赞助。旨在技术交流,请自觉遵守国家法律法规,一旦发现将做封号删号处理。

快速回复 返回顶部 返回列表