1.6.5 Missing SPI Library (Newbee)

I have an UNO r3, trying to load the graphicstest sketch for the Adafruit ST7735 1.8" TFT that uses SPI. The program won't compile because it can't find the SPI library. Here is the error message.

Arduino: 1.6.5 (Windows 8.1), Board: "Arduino/Genuino Uno"

graphicstest.ino:26:17: fatal error: SPI.h: No such file or directory
compilation terminated.
Error compiling.

  1. Where / how do I get / install SPI library?
  2. I also have an Adafruit Feather Huzzah ESP8266 (with WiFi). Do I use the same SPI library for all controllers or a different one for each? If different, where do I find the SPI library for the Feather?

Thanks.

SPI.h (as well as EEPROM and Wire) is included with the board defs. Are you including it correctly? It should be #include <SPI.h>

The SPI library for the ESP8266 will be different - it is probably included with the core though…

Thank you for your quick response. You are right. I found SPI.h in the following directory.
C:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI

There are three includes in the program as follows.
#include <Adafruit_GFX.h> // Core graphics library
#include <Adafruit_ST7735.h> // Hardware-specific library
#include <SPI.h>

The “SPI” is orange, and the program is still giving me the same error message.

hi, i too suffer from the same form of "this is still not working and can't find a solution" flu bug that you do.

perhaps somebody will read this that understands the solution will post it here sooner than much later on.

these items are currently sold on ebay and other locations, the lcd shields.
until a solution is created for getting the uploading to the arduino card successful for these, purchasers are going to experience animosity accordingly to how you just previously experienced, to only get a response months later by myself with no solutions to offer you yet.

anyone else in this boat? lol

thanx in advance

Please provide some more information:

  • What is the sketch you are trying to compile when you encounter this error(post link to where you downloaded it or post the code using code tags(</> button) or attach if too long to post).
  • What version of the Arduino IDE are you using?
  • What do you have selected in Tools > Board

I just successfully compiled the graphicstest program in Arduino IDE 1.6.8 by doing the following:

  • Tools > Board > Arduino/Genuino Uno
  • Sketch > Include Library > Manage Libraries… > Filter your search… > Adafruit ST7735 > Install
  • Sketch > Include Library > Manage Libraries… > Filter your search… > Adafruit GFX > Install
  • File > Examples > Adafruit ST7735 Library > graphicstest
  • Sketch > Verify/Compile

mbishton:
I have an UNO r3, trying to load the graphicstest sketch for the Adafruit ST7735 1.8" TFT that uses SPI. The program won’t compile because it can’t find the SPI library. Here is the error message.

Arduino: 1.6.5 (Windows 8.1), Board: “Arduino/Genuino Uno”

graphicstest.ino:26:17: fatal error: SPI.h: No such file or directory
compilation terminated.
Error compiling.

  1. Where / how do I get / install SPI library?
  2. I also have an Adafruit Feather Huzzah ESP8266 (with WiFi). Do I use the same SPI library for all controllers or a different one for each? If different, where do I find the SPI library for the Feather?

Thanks.

Use “” instead of <>

  1. Either should work, but <> is most correct.
  2. You do realize this thread is >2.5 years old, right?