[ create a new paste ] login | about

Link: http://codepad.org/6xYHJWVl    [ raw code | output | fork ]

C, pasted on Dec 9:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include <ESP8266WiFi.h>
#define WIFI_SSID "xxxxxxxxxxxx"
#define WIFI_PASSWORD "xxxxxxxxxxxx"

void setup() {
    Serial.begin(115200);
    WiFi.mode(WIFI_STA);
    WiFi.begin(WIFI_SSID, WIFI_PASSWORD);
    while (WiFi.status() != WL_CONNECTED) {
        Serial.print('.');
        delay(100);
    }
    wifi_set_sleep_type(LIGHT_SLEEP_T);
}

void loop() {
    Serial.println(WiFi.localIP());
    delay(10000);
}


Output:
1
2
3
4
5
6
7
8
9
10
11
12
Line 24: error: ESP8266WiFi.h: No such file or directory
In function 'setup':
Line 6: error: 'Serial' undeclared (first use in this function)
Line 6: error: (Each undeclared identifier is reported only once
Line 6: error: for each function it appears in.)
Line 7: error: 'WiFi' undeclared (first use in this function)
Line 7: error: 'WIFI_STA' undeclared (first use in this function)
Line 9: error: 'WL_CONNECTED' undeclared (first use in this function)
Line 13: error: 'LIGHT_SLEEP_T' undeclared (first use in this function)
In function 'loop':
Line 17: error: 'Serial' undeclared (first use in this function)
Line 17: error: 'WiFi' undeclared (first use in this function)


Create a new paste based on this one


Comments: