Arduino Nano 33 IoT - MAX6675 Thermocouple Module

Most beginner temperature sensors give up long before things get interesting - a DHT11 or a DS18B20 will happily quit somewhere around 100°C. If you need to keep an eye on a soldering iron tip, a kiln, a home roaster, or the exhaust of a small engine, you need a completely different kind of sensor: a thermocouple. This tutorial walks you through wiring a MAX6675 Type-K thermocouple module to an Arduino Nano 33 IoT and reading out the temperature, in both Celsius and Fahrenheit, on the Serial Monitor.

Arduino Nano 33 IoT MAX6675 Thermocouple Module

Hardware Preparation

1×Arduino Nano 33 IoT
1×Micro USB Cable
1×MAX6675 Module
1×Breadboard
1×Jumper Wires
1×Recommended: Screw Terminal Expansion Board for Arduino Nano
1×Recommended: Breakout Expansion Board for Arduino Nano
1×Recommended: Power Splitter for Arduino Nano

Or you can buy the following kits:

1×DIYables Sensor Kit (18 sensors/displays)
Disclosure: Some of the links provided in this section are Amazon affiliate links. We may receive a commission for any purchases made through these links at no additional cost to you.
Additionally, some of these links are for products from our own brand, DIYables .

What Exactly Is a Thermocouple?

A thermocouple is simply two different metal wires welded together at one end, called the hot junction. Heat that joint up, and it produces a tiny voltage that rises and falls with the temperature - a quirk of physics known as the Seebeck effect. Because there is no delicate silicon chip sitting at the tip, a thermocouple can survive being stuck directly into flame, molten metal, or an oven far past the point where a normal sensor would melt.

The wire pairing used in this tutorial is Type-K (Chromel and Alumel), the most widely sold thermocouple type around. A Type-K probe is rated from roughly -328°F up to +2300°F, although the specific probe bundled with the MAX6675 module you'll buy is limited to a much narrower range, described below.

MAX6675 Module Pinout

A raw thermocouple only outputs a few millivolts, far too small and far too noisy for the Arduino Nano 33 IoT to read directly. That's the job of the MAX6675 chip: it amplifies the hot-junction voltage, corrects for the temperature at the connector itself, and hands you back a clean 12-bit digital reading over a simple 3-wire interface.

What you actually purchase is a small breakout board carrying the MAX6675 chip, plus an attached Type-K probe about 18 inches long. On the probe, the red wire is positive and the blue wire is negative; both wires clip into the 2-pin screw terminal on the board marked + and -.

Keep these numbers in mind before you go pointing the probe at something really hot:

  • Board operating voltage: 3.0V to 5.5V
  • Digital reading range: 0°C to 1024°C
  • Probe's own safe range: 0°C to 80°C only (the probe itself, not the chip, is the limiting factor)
  • Accuracy: about ±3°C
  • Resolution: roughly 0.25°C per step
MAX6675 Thermocouple Module Pinout

The breakout board exposes five pins:

  • GND: ground pin, connect to the Arduino Nano 33 IoT's GND.
  • VCC: power pin for the module.
  • SCK: serial clock, driven by the Arduino Nano 33 IoT to time each bit of the reading.
  • CS: chip select. Pull this low to tell the module you're ready to read a value.
  • SO: serial data output (sometimes labeled SO/MISO). This is a read-only line - the module only ever talks, it never listens, so there is no MOSI pin at all.

Wiring Diagram

The Arduino Nano 33 IoT runs its logic at 3.3V, and conveniently the MAX6675 module is happy anywhere from 3.0V to 5.5V, so we'll power it straight from the board's 3.3V rail rather than reaching for an external 5V supply.

The wiring diagram between Arduino Nano and 33 IoT MAX6675 Thermocouple Module

This image is created using Fritzing. Click to enlarge image

MAX6675 Module Arduino Nano 33 IoT
VCC 3.3V
GND GND
SCK 4
CS 3
SO 2

Arduino Nano 33 IoT Code

/* * This Arduino Nano 33 IoT code was developed by newbiely.com * * This Arduino Nano 33 IoT code is made available for public use without any restriction * * For comprehensive instructions and wiring diagrams, please visit: * https://newbiely.com/tutorials/arduino-nano-iot/arduino-nano-33-iot-max6675-thermocouple-module */ #include "max6675.h" #define SCK_PIN 4 // The Arduino Nano 33 IoT pin connected to SCK pin of MAX6675 module #define CS_PIN 3 // The Arduino Nano 33 IoT pin connected to CS pin of MAX6675 module #define SO_PIN 2 // The Arduino Nano 33 IoT pin connected to SO pin of MAX6675 module MAX6675 thermocouple(SCK_PIN, CS_PIN, SO_PIN); void setup() { Serial.begin(9600); // the MAX6675 needs a moment after power-up before its first conversion is valid delay(500); } void loop() { // read the temperature in Celsius from the thermocouple float temperature_C = thermocouple.readCelsius(); // read the temperature in Fahrenheit from the thermocouple float temperature_F = thermocouple.readFahrenheit(); Serial.print("Temperature: "); Serial.print(temperature_C); // print the temperature in °C Serial.print("°C"); Serial.print(" ~ "); // separator between °C and °F Serial.print(temperature_F); // print the temperature in °F Serial.println("°F"); // the MAX6675 takes about 220ms per conversion, so wait before reading again delay(500); }

Detailed Instructions

If you are new to the Arduino Nano 33 IoT, be sure to check out our Getting Started with Arduino Nano 33 IoT tutorial. Then, follow these steps:

  • Wire up the MAX6675 module and the Arduino Nano 33 IoT exactly as shown in the diagram above.
  • Plug the Arduino Nano 33 IoT into your computer with a USB cable.
  • Open the Arduino IDE.
  • From the board menu, pick Arduino Nano 33 IoT and select the matching COM port.
  • Click the Library Manager icon in the left-hand sidebar.
  • Search for MAX6675 and look for the library published by Adafruit.
  • Press Install to add it to your IDE.
  • Search for MAX6675 library created by Adafruit and click the Install button.
Newbiely | Arduino IDE 2.3.8
──
File
Edit
Sketch
Tools
Help
Arduino Nano 33 IoT
Library Manager
Type:
All
Topic:
All
MAX6675 library by Adafruit
Arduino library for interfacing with MAX6675 thermocouple amplifier More info
1.1.2
INSTALL
Newbiely.ino
···
1 void setup() {
Output
Serial Monitor
Ln 1, Col 1
Arduino Nano 33 IoT on COM15
1
  • Paste the code above into a new sketch in the Arduino IDE.
  • Hit Upload to compile the sketch and push it onto the Arduino Nano 33 IoT.
  • Touch the probe tip to something warm (a mug of hot water works fine for testing) and watch the numbers climb.
  • Open the Serial Monitor to watch the live readings.
Newbiely | Arduino IDE 2.3.8
──
File
Edit
Sketch
Tools
Help
Arduino Nano 33 IoT
Newbiely.ino
···
8 Serial.println("Hello World!");
Output
Serial Monitor
Message (Enter to send message to 'Arduino Nano 33 IoT' on 'COM15')
New Line
9600 baud
Temperature: 24.50°C ~ 76.10°F Temperature: 24.75°C ~ 76.55°F Temperature: 25.00°C ~ 77.00°F Temperature: 26.25°C ~ 79.25°F Temperature: 28.50°C ~ 83.30°F Temperature: 31.75°C ~ 89.15°F Temperature: 34.00°C ~ 93.20°F Temperature: 35.25°C ~ 95.45°F Temperature: 35.50°C ~ 95.90°F Temperature: 35.50°C ~ 95.90°F
Ln 11, Col 1
Arduino Nano 33 IoT on COM15
2

Note: the MAX6675 chip needs about 220ms between conversions, so hammering it with reads any faster than that will just return the same stale value.

Code Explanation

  • Bring in the driver for the module:
#include "max6675.h"
  • Create a thermocouple object, telling it which three pins carry SCK, CS, and SO:
MAX6675 thermocouple(SCK_PIN, CS_PIN, SO_PIN);
  • Ask the module for a reading in Celsius:
float temperature_C = thermocouple.readCelsius();
  • Or ask for the same reading already converted to Fahrenheit:
float temperature_F = thermocouple.readFahrenheit();
  • Print both values to the Serial Monitor, then pause briefly before the next reading so the chip has time to settle:
Serial.print("Temperature: "); Serial.print(temperature_C); Serial.print("°C ~ "); Serial.print(temperature_F); Serial.println("°F"); delay(500);

Video Tutorial

※ OUR MESSAGES

  • As freelancers, We are AVAILABLE for HIRE. See how to outsource your project to us
  • Please feel free to share the link of this tutorial. However, Please do not use our content on any other websites. We invested a lot of effort and time to create the content, please respect our work!