You Are Here: Home » AVR ATmega Projects » The Reflow Soldering Oven with LCD Display using ATmega32

The Reflow Soldering Oven with LCD Display using ATmega32




Introduction

Our project consists of making a reflow soldering device using a normal toaster oven with a graphical LCD display for control and GUI. Soldering is an important and difficult task for custom printed circuit board design especially for integrated circuits that come as chip packages that are impossible to solder by hand. This is particularly true for ball grid arrays (BGA) and small-pitch quad flat packs. If one chooses to design a custom printed circuit board around these chips, then the designer may wish to also purchase a stencil of the designed board that would allow him to squeegee solderpaste precisely on the SMD pads. The designer would then carefully place the components on the board, and heat the solderpaste with a heat gun or a reflow soldering oven. The problem with soldering ovens is that they are expensive and cost thousands of dollars. We have decided to come up with a cheap and working solution to the problem by using a normal toaster oven and controlling it through a microcontroller along with an LCD display that guides the user through the soldering process and constantly provides feedback on the state of the system while reflow soldering. The input to the system would be via a conventional keypad and would consist of target temperature point at specific times that the user would enter based on the solderpaste’s recommended tempearture profile. The system would interpolate the temperatures for the in-between time intervals and follow the curve generated by the input. The system would also fulfill the appropriate safety requirements and have the capability of aborting the process in case of a mishap.

Reflow Soldering Oven

 

High Level Design

Rationale and source:
The source of the project was one of the team members Ko Ihara who as part of his M.Eng. project worked on designing a circuit board and came up with the idea of using a toaster oven for reflow soldering. The project idea fully complies with the requirements of the course and the challenging part is coming up with a workable PID feedback control to make the toaster oven follow the temperature curve and heat up or cool down at appropriate times. The Atmel mega32 chip is sufficient for this project as the speed of the chip and the number of I/O pins suffices our needs. Another thing about the project is that it would benefit future students in the course since they would be able to solder boards with less pain and high efficiency and safety.

Logical structure:
The project can be divided into three parts namely the LCD display, the oven control and lastly the temperature sensor inside the oven. The following block diagram shows the logical structure of the system.

The microcontroller sends a digital signal to the solid state relay switch which controls the on/off state of the oven for appropriate heating and cooling. The temperature sensor device inside the oven makes a voltage divider circuit in series with a resistor, the voltage signal is connected to the atmel mega32 ADC (analog to digital converter) input. The ADC output is used as a feedback by the program to measure temperature inside the oven and to control the relay state. At the same time, the state of the system is updated in real time on the LCD and the user can see the progress. The keypad is used for input and the LCD provides step by step instructions to the user during the input process. The oven control hardware containing the relay switch is inside a metal box with the fuse circuit in place. It has the three pin plug connections for connecting the oven and the AC voltage supply. It also has harness plugs for connecting the digital input to the microcontroller.

Hardware/Software tradeoffs:
The LCD RAM was emulated in software through a buffer as it was not possible to read it in real time from the RAM.

Relationship with Standards:
In the United States, the alternative-current electric power transmission was standardized by Westinghouse in the 1890s and the 115/230 VAC standard for home appliance was adopted since the early 1900s. We could not find an IEEE standard that is specifically relevant to the power distribution method. As for the FCC regulation, our project has nothing to do with that.

Trademarks and Patents:
There are several patents associated with the design of a solder reflow oven, such as U.S. patent 6794616 by Lakhi Nandlal Goenka in 2004. However, these are IPs are specific to the detailed design of the oven, not the general concept of reflow soldering itself. There are several companies like Harotec/ SAB and Novastar that make reflow ovens but these are expensive devices targeting high-end commercial markets where as our project is intended towards hobbyists and students who can not afford these products.

Program/Hardware Design

HARDWARE:

MCU:
The microcontroller that we used is an Atmel MEGA32 chip. It was soldered on the custom prototype board provided for this course. We are using all the four ports A-D for I/O and therefore all of those were soldered on the board. The MCU is programmed via the STK 500 board.

LCD and Keypad:
The keypad used is the same as for previous labs. It is connected to PORT C and is debounced to nullify the vibrating effect of the buttons due to their mechanical nature. The LCD used for the project is a 128 x 64 pixel graphical display model manufactured by Crystalfontz America, Inc. It has a 20 pin interface with a 5.0 V requirement for logic and 8.0 V requirement for the LCD display. The LCD is soldered on a prototype board along with the keypad. It is connected to PORT B and PORT D (6 pins out of 8) of the mcu. Both ports are used as output providing the necessary signals to the LCD for the control. The LCD has a KS0108B controller built in it and is divided into two columns of 64 x 64 pixels with a column select pin to switch between them. Each column is further divided into 8 pages with each page consisting of 8 rows of 64 pixels each. The LCD RAM that corresponds to 128 x 64 pixels or 1K bytes is addressed in a way that all 8 rows belonging to the same column (y axis, not to be confused with the two columns mentioned above) in a page can be read or written at a time. The pixels are set on high logic and cleared on low. The set p and hold times for addresses or data were of the order of nanosecond which means that the LCD interaction could be easily done in real time. The LCD was powered through a voltage divider circuit using the Maxim ICL7660CPA reverse voltage generator which is also soldered on the prototype board.

Relay Box:
The relay switch used for the project was sampled from Omron Electronics and has the maximum rating of 75 A at 24 to 240 AC which is more than enough for a normal toaster oven. The relay switch was placed in a heat sink metal box with three input plug connectors mounted inside to connect the toaster oven and the AC power supply. The digital input was connected via harness plugs that were drilled into the box. The signal for the solid state relay switch was given through PORTD5 via the prototype board.

Thermistor:
The temperature device used was an NTC thermistor with temperature range from -40 to 300 Celsius. The device was placed inside the oven and connected to the voltage divider circuit on the prototype board. The thermistor was connected in series with a 2K ohm resistor and was powered through an LM711 op amp which acted as a buffer or voltage forwarding device. The variable voltage output from the circuit is fed to the mega32 via pin A0 that goes into the ADC on the chip.

The system is fairly easy to replicate, however care must be taken when connecting the various signals especially the relay box as it requires dealing with live 240 AC supply and must be done by trained personnel. Pleases refer to appendix B and the pictures for an illustration of our hardware design. For further assistance, refer to the data sheets of the various components in appendix E.

PortFunction
PORTA0Thermistor voltage

Table 1: MEGA32 PORTA Connections

PortFunction
PORTB0DB0 (LCD)
PORTB1DB1 (LCD)
PORTB2DB2 (LCD)
PORTB3DB3 (LCD)
PORTB4DB4 (LCD)
PORTB5DB5 (LCD)
PORTB6DB6 (LCD)
PORTB7DB7 (LCD)

Table 2: MEGA32 PORTB Connections

PortFunction
PORTC0Pin 1 (Keypad)
PORTC1Pin 2 (Keypad)
PORTC2Pin 3 (Keypad)
PORTC3Pin 4 (Keypad)
PORTC4Pin 5 (Keypad)
PORTC5Pin 6 (Keypad)
PORTC6Pin 7 (Keypad)
PORTC7Pin 8 (Keypad)

Table 3: MEGA32 PORTC Connections

PortFunction
PORTD0CS1 (LCD)
PORTD1CS2 (LCD)
PORTD2Reset (LCD)
PORTD3R/~W (LCD)
PORTD4D/~I (LCD)
PORTD5Relay signal
PORTD7Enable (LCD)

Table 4: MEGA32 PORTD Connections

PROGRAM:

The software design of the system can be divided into three main categories. LCD display functionality, control flow of the system and PID control.

LCD Display Functionality:
The LCD functionality is one of the most important features of our system since all the interaction between the user and the soldering system is performed via the LCD. The main function for the LCD display is the setpixelxy() procedure which takes in three arguments row, column and a flag value. The flag determines if the pixel at position row (0-63 vertically) column (0-127 horizontally) is set or cleared with 1 being set and 0 being cleared. The LCD as mentioned before doesn’t allow a single pixel to be written and only allows a byte to be written in the corresponding page. For this reason, the LCD RAM has to be read first and the pixel position in that byte has to be updated with the new setting. We tried reading the LCD on the fly but it was not accomplished and therefore an LCD buffer of the same size as the RAM (1K) was created in the mcu’s eprom memory. This buffer in the software was used as a virtual RAM for the LCD which was updated and read whenever the display was updated. The next step was to implement alphanumeric characters for displaying data. Bitmaps were created for characters from 0-Z and also for some special characters like space, period hyphen etc. These bitmaps are displayed on the LCD using wrappers like putbyte() and putchars() which set the corresponding pixels. Another function was the drawline() function which takes in four parameters x1, y1 ,x2,y2 and draws a line between them. This function was taken from the video code provided by Professor Land for lab 4. The following graph shows our LCD display model.

 

For more detail: The Reflow Soldering Oven with LCD Display using ATmega32

Leave a Comment

You must be logged in to post a comment.

Read previous post:
How Cable Television Works
How Cable Television Works

Adding Channels In the early 1950s, cable systems began experimenting with ways to use microwave transmitting and receiving towers to...

Close
Scroll to top