Let's Make Robots!

Arduino Oven Controller PID

Set A Temperature For an Oven Using a Relay
TC_Relay_Controls.tar4.08 KB
pid_control_result.PNG253.58 KB

This is my Arduino temperature-ramp PID controller, which is running on a hot plate (up to 325 C) and which shall also be tested on a furnace (up to 650 C).  This controller integrates some interesting stuff that I didn't make, using libraries I didn't write, but perhaps this will be useful to someone.


Common furnace PID controllers focus on reaching temperature set-points and are manually set.  This controller allows a final temperature set-point and a rate to be specified using serial commands to an Arduino.

An example command "S300 R10" would set a final temperature of 300C and a rate of 10C/minute, starting from the current temperature.  A PID controller aims to match the moving temperature ramp.

The challenge for this controller is to make the relay not switch excessively -- I want to avoid wear on the relay, as it's switching a lot of power and is rated for 100,000 events at its rated power.


  • McLaughlin Engineering Thermocouple Shield and Max31855 Library
  • Omega K-type Thermocouple (I'm using 0.010" bare wire)
  • Relay or Power Switch Tail II on Arduino Pin 7
  • Arduino

Arduino Source Code Follows and is attached as "TC_Relay_Controls.tar"


Results for a Hot Plate

The above plot shows a hot-plate test to its maximum temperature.


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Now I've got my eyes open in the lab for a nice hotplate to hack into. Thanks for the "Something Else."

Nice project :-) Being an HVACR tech since many years, I didn't know that the Arduino was capable of doing such a task. I have K-Type thermocouple and I would like to try this too. Thanks for sharing and for the tip. Cheers.

I just started using thermocouples, so I took a look around for a "toy" thermocouple application that I could use to check my temperature readings. The idea was that when I get a questionable reading from a thermocouple, I can toss in a second or third sensor to confirm.  As it turns out it was pretty educational - I hadn't realized that the thermocouple contact chemistry could be important.