0

I Found a Firebase example for an Arduino, from Github. I have added the Firebase Arduino library as instructed in the ReadMe document, but the compilation failed, throwing the following error:

In file included from firebase_sample_stream.ino:20:0:
/Users/<username>/Documents/Arduino/libraries/firebase-arduino-master/Firebase.h:24:25: fatal error: ESP8266WiFi.h: No such file or directory
#include <ESP8266WiFi.h>

Not only Firebase library, but also any other libraries. What am I missing here?

Hope someone would have solved this issue.

gre_gor
  • 6,669
  • 9
  • 47
  • 52
ABI
  • 1,536
  • 18
  • 38
  • I take it you also installed the esp8266 board to your arduino software? – Ram Feb 03 '17 at 06:52
  • Yes I installed esp8266 – ABI Feb 03 '17 at 06:55
  • 2
    Did you select it via `Tools -> Board: xxx`? – Ram Feb 03 '17 at 07:00
  • Yes I did, FYI, even before selecting the board, the code should compile which is not happening. – ABI Feb 03 '17 at 07:15
  • 2
    Hmm, it may have changed since I last worked with it, but Arudino would only expose the particular library and it's headers if the corresponding board is selected. – Ram Feb 03 '17 at 07:18
  • 2
    `even before selecting the board, the code should compile which is not happening` wrong. you need to have an ESP8266 board selected or you will get that error. The ESP8266WiFi library can only be included if an ESP8266 board is selected. What do you have selected in the **Tools > Board** menu? – per1234 Feb 03 '17 at 08:26
  • 1
    That Firebase example is supposed to be uploaded to an ESP8266 not an Arduino. – gre_gor Feb 03 '17 at 12:34

1 Answers1

0

You can manually download the file from here and include it in your project. That may work. Or you can add http://arduino.esp8266.com/stable/package_esp8266com_index.json into Additional Board Manager and update the board.

  • from where? I've already added this http://arduino.esp8266.com/stable/package_esp8266com_index.json – ABI Feb 03 '17 at 07:08