3
所以我今天拿到了Arduino Uno。對於一個項目,我希望能夠通過Wifi控制我的Arduino上的一些繼電器(通過Blynk應用程序)。爲此,我想使用ESP8266-01作爲Wifi屏蔽。將Arduino連接到Blynk與ESP8266
唯一的區別是我使用的是Win10。以下是我的了:
- Arduino的烏諾R3
- 的Arduino IDE 1.8.1
- 包括所有Blynk/ESP庫和安裝ESP8266爲板(通用)
- 上傳空草圖到Arduino
- 如下連接到Arduino/ESP之間。 http://www.teomaragakis.com/hardware/electronics/how-to-connect-an-esp8266-to-an-arduino-uno/(我知道到3.3V至5V的問題,但似乎工作至今)
好了,第一個問題是我不能閃了ESP的固件(從Sunfounder取得)作爲教程說。下載了最新的固件並使用ESP8266Flasher進行了閃存。
另一個問題是,當我嘗試編譯從第一個教程中的代碼,我總是得到錯誤:
C:\Users\Chris\Documents\Arduino\libraries\Blynk\examples\Boards_WiFi\ESP8266_Shield\ESP8266_Shield.ino:5:21: fatal error: ESP8266.h: No such file or directory
至於說我已經安裝的所有庫。不能真正想到要做的事情了。任何幫助將非常感激。來自柏林的最好的問候,Chris。 要關閉我試着上傳到板代碼(包括Arduino板或通用ESP8266不工作)
//#define BLYNK_DEBUG
#define BLYNK_PRINT Serial // Comment this out to disable prints and save space
#include <ESP8266.h>
#include <BlynkSimpleShieldEsp8266.h>
// Set ESP8266 Serial object
#define EspSerial Serial
ESP8266 wifi(EspSerial);
// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "???";
void setup()
{
Serial.begin(115200); // Set console baud rate
delay(10);
EspSerial.begin(115200); // Set ESP8266 baud rate
delay(10);
Blynk.begin(auth, wifi, "???",
"???");
}
void loop()
{
Blynk.run();
}
的???我轉換了我的令牌和數據。
謝謝,這工作。現在我有一些新的錯誤,但至少有一些可以玩的東西。似乎在我閃過ESP時出現錯誤。現在不能讀出Arduino IDE中的串口管理器=) –