Trouble with thermocouple max 31855


I really need help!
I am new with arduino so I do not know much about the code. I am trying to build a machine that practically increases and decreases temperature using two resistors and a fan. In order to measure the temperature I chose to use a thermocouple max31855. I have downloaded the library on my computer from here . However when I try to verify my code (I have it attached on the post) I get the following error:

Arduino: 1.6.1 (Windows 7), Board: “Arduino Mini, ATmega328”

C:\Users\Spyros\Documents\Arduino\libraries\Adafruit-MAX31855-library-master\Adafruit_MAX31855.cpp: In constructor ‘Adafruit_MAX31855::Adafruit_MAX31855(int8_t)’:

C:\Users\Spyros\Documents\Arduino\libraries\Adafruit-MAX31855-library-master\Adafruit_MAX31855.cpp:46:3: error: ‘SPI’ was not declared in this scope



C:\Users\Spyros\Documents\Arduino\libraries\Adafruit-MAX31855-library-master\Adafruit_MAX31855.cpp:48:19: error: ‘SPI_MODE0’ was not declared in this scope



C:\Users\Spyros\Documents\Arduino\libraries\Adafruit-MAX31855-library-master\Adafruit_MAX31855.cpp:49:23: error: ‘SPI_CLOCK_DIV4’ was not declared in this scope



C:\Users\Spyros\Documents\Arduino\libraries\Adafruit-MAX31855-library-master\Adafruit_MAX31855.cpp: In member function ‘uint32_t Adafruit_MAX31855::hspiread32()’:

C:\Users\Spyros\Documents\Arduino\libraries\Adafruit-MAX31855-library-master\Adafruit_MAX31855.cpp:168:23: error: ‘SPI’ was not declared in this scope

buffer.bytes = SPI.transfer(0x00);

  • ^*
    Error compiling.
  • This report would have more information with*
  • “Show verbose output during compilation”*
  • enabled in File > Preferences.*
    Please help!
    Thanks in advance
    PCR.ino (8.79 KB)

#include <SPI.h>

Thanks for replying, but what is SPI.h and where can I find it?

On the IDE menu, poke around, you can Import the SPI library.
Will add this to the top of your sketch
#include <SPI.h>

on your arduino IDE

sketch --> import library --SPI