Contents
Introduction
The Arduino Nano-based soldering station is a comprehensive, feature-rich tool designed for precision and ease of use in soldering tasks. Leveraging the compact and powerful Arduino Nano microcontroller. This versatile soldering station is ideal for hobbyists, DIY enthusiasts, and professionals seeking a reliable and customizable solution for their soldering needs.
Features
Rotary Encoder Support: Designed to interface seamlessly with rotary encoders for precise temperature control.
Built-in Beeper: Includes an onboard beeper for audio feedback, enhancing user interaction.
Memory Buttons: Equipped with built-in memory buttons allowing the user to store and recall frequently used temperature settings.
Supports up to 7 buttons, with 3 buttons integrated on the board.
Debouncing: Built-in debouncing mechanism for all buttons to ensure accurate and reliable button presses.
Temperature Reading: Utilizes a MAX6675 module for accurate temperature readings from a K-type thermocouple, ensuring precise temperature control.
LCD Header: Includes a header designed for an I2C LCD module, allowing for easy connection and display of temperature readings and settings.
Motion Sensing: Integrates motion sensing using the soldering iron’s mercury switch to detect movement. This feature can be used to automatically manage power or temperature settings based on activity.
Dimmable LCD Backlight: Provides a dimmable backlight for the LCD, offering adjustable visibility in various lighting conditions.
Feedback LED Header: Includes a header for connecting a feedback LED, which can be used for status indication or alerts.
Working Principle of Arduino-Based Smart Soldering Station
The Arduino-based smart soldering station operates by integrating various components to control and monitor the soldering process, ensuring precision and efficiency. Here’s a detailed explanation of its working principle:
- Microcontroller (Arduino Nano)
Core Function: The Arduino Nano serves as the central processing unit. It reads inputs from various sensors and controls the output to maintain the desired temperature.
Programming: The Arduino is programmed with a code that handles all operations, from reading the temperature to updating the display and controlling the heating element. - Temperature Sensing (MAX6675 Module and K-type Thermocouple)
Thermocouple: The K-type thermocouple is attached to the soldering iron’s tip and measures the temperature.
MAX6675 Module: This module converts the analog signals from the thermocouple into digital values that the Arduino can read.
Reading Temperature: The Arduino reads the digital temperature data from the MAX6675 module periodically to monitor the current temperature of the soldering iron. - User Interface (Rotary Encoder and Buttons)
Rotary Encoder: Used for setting the desired temperature. Rotating the encoder changes the target temperature, while pressing it can select or confirm settings.
Buttons: Additional buttons can store and recall frequently used temperature settings, allowing for quick adjustments. - Display (I2C LCD)
LCD Module: An I2C LCD module displays the current and target temperatures, along with other status information.
Display Updates: The Arduino updates the LCD in real-time to reflect any changes in temperature or settings. - Control Logic
Temperature Control: The Arduino compares the current temperature (from the thermocouple) with the target temperature set by the user. It then adjusts the power to the heating element to reach and maintain the target temperature.
PID Control (optional): For precise temperature control, a Proportional-Integral-Derivative (PID) algorithm can be implemented. This helps in maintaining a stable temperature by minimizing overshoot and oscillations. - Feedback and Alerts (Beeper and LEDs)
Beeper: Provides audio feedback for button presses, temperature reach, or any errors.
Feedback LED: Indicates the status of the soldering station, such as power on, heating, or standby mode. - Motion Sensing (Mercury Switch)
Mercury Switch: Detects the movement of the soldering iron. If no movement is detected for a predefined period, the Arduino can put the soldering station into standby mode to save energy and enhance safety.
Automatic Standby: The Arduino continuously monitors the mercury switch. Lack of movement triggers the standby mode, reducing the iron’s temperature to a safe level. - Debouncing Mechanism
Button Debouncing: Software debouncing is implemented to ensure that button presses are accurately registered, avoiding false triggers due to mechanical noise.
Workflow
- Initialization: When powered on, the Arduino initializes all components, including the LCD, MAX6675 module, and input devices.
- User Input: The user sets the desired temperature using the rotary encoder. The current and target temperatures are displayed on the LCD.
- Temperature Monitoring: The Arduino continuously reads the temperature from the MAX6675 module.
- Control Signal: Based on the temperature reading, the Arduino adjusts the power to the heating element to maintain the set temperature.
- Feedback: The LCD displays real-time temperature information, and the beeper provides audio feedback. LEDs indicate operational status.
- Motion Detection: The mercury switch monitors motion. Lack of movement triggers standby mode to reduce the temperature.
- Memory Functions: The user can store and recall temperature settings using the dedicated buttons.
This integrated approach ensures that the soldering station operates efficiently, providing precise temperature control and user-friendly interaction, making it a powerful tool for both hobbyists and professionals.
PCB Manufacturer
PCBWAY is a highly skilled company specializing in PCB manufacturing. They offer their services at incredibly low prices, such as providing 10 PCBs for only $5. Additionally, new members receive a $5 bonus. The website allows customers to upload their Gerber Files and place orders.
PCBWAY is known for producing PCBs of exceptional quality and maintaining high standards, which is why many people trust them for their PCB and PCBA
Below are some of my PCB’S manufactured by PCBWAY and I am fully satisfied by their Quality of service they provide
Circuit Diagram
Schematic Diagram
PCB Diagram
3D Diagram
Source Code or Programming
/* Forrasztópáka projekt v 1.2
Ez a kód encoderrel változtatja a beállított hőmérséklet értéket, amit folyamatosan összevet a tényleges értékkel
amit a max6675 IC szolgáltat egy K type thermocoupleon keresztül( pákába építve)
LCD:
sda -> A4
scl -> A5
Encoder:
SW-> D4
DT-> D2
CLK -> D3
beeper: D13
thermocouple:
SO-> D12
CS-> D11
CLK-> D10
FET -> D6
motion sense-> D7
LCD Dimmer-> D5
Feedback Led -> D8
Memo1-> A0
Memo2-> A1
Memo3-> A2`
Memo4-> A3
Memo5-> A6
Memo6-> A7
Memo7-> D9
nano
pwm pins 3, 5, 6, 9, 10, and 11
interrupt pins 2,3
*/
bool higanyKapcsolo = false; // ha van higanykapcsoló a pákafejben akkor ez legyen "true", ha nincs, akkor "false".
int dimm = 250; //háttérvilágítás értéke: 0-255 (0%-100%)
#include "max6675.h"
#include <LiquidCrystal_I2C.h>
#include <Encoder.h>
#include <Wire.h>
#include <SPI.h>
#include <PID_v1.h>
double Setpoint, Input, Output = 0;
double Kp = 15, Ki = 4, Kd = 1.5;
PID myPID(&Input, &Output, &Setpoint, Kp, Ki, Kd, DIRECT);
const byte thermocoupleSO = 12;
const byte thermocoupleCS = 11;
const byte thermocoupleCLK = 10;
MAX6675 thermocouple(thermocoupleCLK, thermocoupleCS, thermocoupleSO);
const byte encoderPinA = 2;
const byte encoderPinB = 3;
Encoder myEnc(encoderPinA, encoderPinB);
LiquidCrystal_I2C lcd(0x27, 16, 2);
const int fetPin = 6;
const int heatingLed = 8;
const int motion = 7;
const int dimmer = 5;
const int encoder_sw = 4;
const int memopin_1 = A0;
const int memopin_2 = A1;
const int memopin_3 = A2;
const int memopin_4 = A3;
const int memopin_5 = A6;
const int memopin_6 = A7;
const int memopin_7 = 9;
const int beeper = 13;
int setTemp = 0;
int actual = 0;
bool lowTempMode = false;
unsigned long previousMillis = 0;
unsigned long previousMillis2 = 0;
void setup() {
myPID.SetMode(AUTOMATIC);
pinMode(beeper, OUTPUT);
pinMode(fetPin, OUTPUT);
pinMode(heatingLed, OUTPUT);
Serial.begin(250000);
lcd.begin();
lcd.backlight();
while (!Serial) delay(1); // wait for Serial on arduino etc
lcd.setCursor(0, 0);
lcd.print("* Paka Projekt *");
lcd.setCursor(0, 1);
lcd.print("*v2.3 by Szabi*");
//on_beep_delayal();
for (int i = 255; i >0; i--) {
analogWrite (dimmer , i);
delay(20);
}
myEnc.write(480);
lcd.clear();
}
void loop() {
if (lowTempMode == true) {
Setpoint = 100;
lcd.setCursor(0, 0);
lcd.print(" Low Temp Mode");
lcd.setCursor(0, 1);
lcd.print("****************");
unsigned long currentMillis = millis();
if (currentMillis - previousMillis2 >= 120000) {
previousMillis = currentMillis;
timer_beep();
for (int j = 0; j < 8; j++) {
for (int i = 255; i > 0; i--) {
analogWrite (dimmer , i);
delayMicroseconds(750);
}
for (int i = 0; i < 255; i++) {
analogWrite (dimmer , i);
delayMicroseconds(750);
}
}
}
}
else {
if (digitalRead(memopin_1) == LOW) { //ha megnyomod az egyes memo gombot, akkor a Setpoint 220C° re ugrik (440/2) ez általános kis alkatrészes forrasztáshoz kellhet
myEnc.write(440);
}
else if (digitalRead(memopin_2) == LOW) { //ha megnyomod az kettes memo gombot, akkor a Setpoint 300C° re ugrik (440/2) ez nagyobb hőkapacitású alkatrészek forrasztásához kellhet
myEnc.write(600);
}
else if (digitalRead(memopin_3) == LOW) { //ha megnyomod az hármas memo gombot, akkor a Setpoint 380C° re ugrik (440/2) Ez pl ground plane-k ónozásához kellhet
myEnc.write(760);
}
/*
else if (digitalRead(memopin_4) == LOW) {
myEnc.write(500);
}
else if (digitalRead(memopin_5) == LOW) { //zárlatos ez a debounce circuit
myEnc.write(500);
}
else if (digitalRead(memopin_6) == LOW) { //zárlatos ez a debounce circuit is
myEnc.write(500);
}
else if (digitalRead(memopin_7) == LOW) {
myEnc.write(500);
}
*/
int newPosition = myEnc.read() / 2;
if (newPosition > 450)
{
newPosition = 450;
}
if (newPosition < 150)
{
newPosition = 150;
}
setTemp = newPosition;
actual = thermocouple.readCelsius() * 0.93; // a szorzás után kell írni a kompenzálást ha nem ugyan anyi a valós hőmérséklet, mint a mért.
delay(150); //ezt a delayt hagyd benne, mert valamiért nélküle befagy a program és túlheviti a pákát.
Setpoint = setTemp;
lcd.setCursor(0, 0);
lcd.print("SetTemp:");
lcd.setCursor(9, 0);
lcd.print(setTemp);
lcd.setCursor(14, 0);
lcd.print("C");
if (actual < 100)
{
lcd.setCursor(0, 1);
lcd.print("Actual: ");
lcd.setCursor(9, 1);
lcd.print("Low");
lcd.setCursor(14, 1);
lcd.print("-");
}
else
{
lcd.setCursor(0, 1);
lcd.print("Actual: ");
lcd.setCursor(9, 1);
lcd.print(actual);
lcd.setCursor(14, 1);
lcd.print("C");
}
}
Input = actual;
myPID.SetTunings(Kp, Ki, Kd);
myPID.Compute();
int Out = (int)Output;
analogWrite(fetPin, Out);
analogWrite(heatingLed, Out);
/*
//serial plotterhez:
Serial.print(setTemp);
Serial.print(" ");
Serial.println(actual);
*/
if (higanyKapcsolo == true) { //Ha van higanykapcsolónk
if (TimeTrigger(60000, higanykapcsolo_mozdult_e())) // ha eltelt 1 perc, és nem használtuk a pákát
{
lowTempMode = true; // alacsony hőmérsékletű módba kapcsolunk a pákahegy kimélése céljából.
}
else
{
lowTempMode = false;
}
}
}
//************-----------------------------------------timer()--------------------------------------***********
bool TimeTrigger(unsigned long interval, bool Reset)
{
unsigned long currentMillis = millis();
if ( Reset == true) {
previousMillis = currentMillis;
}
if (currentMillis - previousMillis >= interval) {
return true;
}
else {
return false;
}
}
//************-----------------------------------------timer() vége--------------------------------------*********
//-----------------------------------------higanykapcsolo_mozdult_e()--------------------------------------
bool higanykapcsolo_mozdult_e()
{
static int buttonState = 0;
static int lastButtonState = 0;
buttonState = digitalRead(motion);
if (buttonState != lastButtonState)
{
lastButtonState = buttonState;
return true;
}
else
{
return false;
}
}
//-----------------------------------------higanykapcsolo_mozdult_e() vége--------------------------------------
//************-----------------------------------------bekapcsolás hang--------------------------------------***********//
void on_beep_delayal()
{
int frek1 = 1750; //Tone1 Hz
int ido1 = 500000 / frek1;
int frek2 = 2500; //Tone2 Hz
int ido2 = 500000 / frek2;
int frek3 = 3000; //Tone3 Hz
int ido3 = 500000 / frek3;
int frek4 = 3250; //Tone4 Hz
int ido4 = 500000 / frek4;
int hossz = 120; //csippanás hossza
int hossz2 = 500;
int ismetlodes = 1;
int koz = 50; //eltelt idő a két csippanás között
for ( int k = 0; k < ismetlodes; k++)
{
delay(koz);
for (int i = 0; i < hossz; i++)
{
digitalWrite(beeper, HIGH);
delayMicroseconds(ido1);
digitalWrite(beeper, LOW);
delayMicroseconds(ido1);
}
}
for ( int k = 0; k < ismetlodes; k++)
{
delay(koz);
for (int i = 0; i < hossz; i++)
{
digitalWrite(beeper, HIGH);
delayMicroseconds(ido2);
digitalWrite(beeper, LOW);
delayMicroseconds(ido2);
}
}
for ( int k = 0; k < ismetlodes; k++)
{
delay(koz);
for (int i = 0; i < hossz; i++)
{
digitalWrite(beeper, HIGH);
delayMicroseconds(ido3);
digitalWrite(beeper, LOW);
delayMicroseconds(ido3);
}
}
for ( int k = 0; k < ismetlodes; k++)
{
delay(koz);
for (int i = 0; i < hossz2; i++)
{
digitalWrite(beeper, HIGH);
delayMicroseconds(ido4);
digitalWrite(beeper, LOW);
delayMicroseconds(ido4);
}
}
}
//************------------------------------------------------------------------------------------------------------***********//
//************-----------------------------------------timer_beep()--------------------------------------***********//
void timer_beep()
{
int frek1 = 4000; //Tone1 Hz
int ido1 = 500000 / frek1;
int hossz = 100; //csippanás hossza
for (int j = 1; j <= 3; j++) {
delay(50);
for (int i = 0; i < hossz; i++)
{
digitalWrite(beeper, HIGH);
delayMicroseconds(ido1);
digitalWrite(beeper, LOW);
delayMicroseconds(ido1);
}
}
}
//************-----------------------------------------timer_beep () vége--------------------------------------***********//
Manufacturing Files
Gerber File
Bill Of Materials
Order Directly from PCB WAY
I have already uploaded all these required manufacturing files in PCBWAY website. You can easily go to the below link and place you order, and get your Own Home Automation PCB manufactured from one of the best pcb manufacturer PCBWAY