Arduino PID Controller

Coding,Electronics

Hot Plate PID Controller

15 Aug , 2015  

Low and slow cooking requires precise control of temperature and time. Instead of having to do the controls manually, here’s a little electronics project to precisely achieve a preset temperature over the time: a Hot Plate PID Controller.

This project has been built from an Arduino Pro Micro with the following peripherals mounted on the board:

  • Oled display 128 x 64 (Aliexpress, eBay)
  • 2 100K Thermistors, connected via audio jacks  (eBay)
  • 5050 RGB led
  • Piezo Buzzer
  • 3 tactile switches

The display and the switches are used as the main user interface, then the LED and the buzzer give additional indication for when the plate is on and when the time preset has elapsed at the end of the process.

The three audio jacks expose three analog inputs of the pro micro, so that up to three thermistors can be connected to the board, while a terminal block provides input for a +5V supply and the output signal to drive the power electronics.

Board with components and back side connections

Board with components and back side connections

The board took quite a while to make, to use in the best way the Pro Micro exposed pins and to solder the connections on the back using enamelled wire (not the one that strips the insulation with the soldering heat).

The power electronics has been mounted on another panel, and consists of the necessary connectors, a 5V power supply and a Solid State Relay which drives the hot plate with the output signal generated by the Arduino.

Power electronics board

Power Electronics board

The Arduino board and the power electronics have been secured to a food cutting board cut in two halves. The controller board has been tied to the top half while all the power components have been zip tied to the bottom board. Then the two boards have been sandwiched together and bolted to each other to form a solid assembly.

Finished project in test configuration

Finished project

The Software has been completed integrating some very useful libraries and snippets of code:

The Hot Plate PID Controller program has still some minor bugs to rule out, but it is at a good stage for testing the main functionalities. Placing the sensor on the hot plate and aiming for a 80 degrees temperature produces a stable temperature in about 5 minutes, with an initial overshoot and some oscillation around the target temperature (see the post image graph).

I believe that the +/- 5 degrees oscillation is not relevant for cooking, however I’ll have to dust off my control theory notes to see if there is something that can be done about it. For now the temperature control seems good and quite accurate. The real test will have to be done in the terracotta oven.

The program starts by allowing to set cooking time and temperature; when the user is happy with the values, the running mode can be entered: two thermistors are read constantly, one for the meat temperature and one for the oven temperature. The PID controller acts on the latter, driving the output pin to turn on or off the SSR and the hot plate.

When in running mode the user can select three graphical views of the current situation: the first is a little graph that shows oven temperature over time; the second represents the elapsed time and the oven temperatures, while the third is a graphical plot of the meat and oven temperatures.

Temperature Graph display

Temperature Graph display. Plate was set for 80 degrees, some overshoot and oscillation is visible

Bar graph mode

Bar graph display with time and oven temperature

It has been great fun writing a menu system, and the graphical modes. I am sure that with time and usage some more advanced and useful modes will be implemented and the little bugs will be ironed out. First however I have to try this ribs recipe and see if the temperature control is really accurate, or if my sensors are reading a temperature offset from the real one.

Update:

I’ve made some ribs with a terracotta vase and the Hot Plate PID Controller described in this article. I had set the system to go up to 110 degrees centigrade (230F), but when the meat, the grills, the drip pan and the apple wood chips were inside the hot plate was always on and the temperature reached a plateau at 80 degrees centigrade, way below the recipe recommended temperature.

Terracotta vase smoker

Terracotta vase smoker – original idea by Alton Brown

So I left the ribs inside for a whole night, totalling about 20 hours of baking. In the end they were edible, the meat inside remained soft, but all the moisture had dried out and the crust was too thick and hard. Perhaps 6/8 hours would have been enough.

Ribs after 20 hrs cooking

Ribs after 20 hrs cooking

Next I will buy a new, more powerful hot plate to reach higher temperatures for cooking after having verified that this one is not entering some sort of overtemperature protection at the bottom of the oven.

,


Leave a Reply

Your email address will not be published. Required fields are marked *