AronHetLam / ATEM_tally_light_with_ESP8266

Wireless tally light for use with ATEM switchers, which connects over WiFi, using an ESP WiFi module.
GNU General Public License v3.0
160 stars 40 forks source link

Won't compile #33

Closed bruce1946 closed 3 years ago

bruce1946 commented 3 years ago

This is the message I get from the IDE:

ATEM_tally_light:261:22: error: 'class WiFiClass' has no member named 'mode'

             WiFi.mode(WIFI_STA); // Disable softAP if connection is successful

Any idea what went wrong? Thanks for your help. I am not sure what the rest of the stuff below here is.

Arduino: 1.8.13 (Windows Store 1.8.42.0) (Windows 10), Board: "LOLIN(WEMOS) D1 R2 & mini, 80 MHz, Flash, Legacy (new can return nullptr), All SSL ciphers (most compatible), 4MB (FS:2MB OTA:~1019KB), v2 Lower Memory, Disabled, WIFI, Only Sketch, 921600"

In file included from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:50:0:

C:\Users\HPz800\Documents\Arduino\libraries\FastLED\src/FastLED.h:14:21: note: #pragma message: FastLED version 3.004.000

 #    pragma message "FastLED version 3.004.000"

                     ^

In file included from C:\Users\HPz800\Documents\Arduino\libraries\FastLED\src/FastLED.h:65:0,

                 from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:50:

C:\Users\HPz800\Documents\Arduino\libraries\FastLED\src/fastspi.h:135:23: note: #pragma message: No hardware SPI pins defined.  All SPI access will default to bitbanged output

 #      pragma message "No hardware SPI pins defined.  All SPI access will default to bitbanged output"

                       ^

In file included from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:43:0:

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer.h: In instantiation of 'class esp8266webserver::ESP8266WebServerTemplate<WiFiServer>':

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:126:24:   required from here

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer.h:80:53: error: no type named 'ClientType' in 'class WiFiServer'

   using ClientType = typename ServerType::ClientType;

                                                     ^

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino: In function 'void setup()':

ATEM_tally_light:228:10: error: 'class WiFiClass' has no member named 'mode'

     WiFi.mode(WIFI_STA);

          ^

ATEM_tally_light:228:15: error: 'WIFI_STA' was not declared in this scope

     WiFi.mode(WIFI_STA);

               ^

ATEM_tally_light:229:16: error: no matching function for call to 'WiFiClass::begin()'

     WiFi.begin();

                ^

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:229:16: note: candidates are:

In file included from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:5:0:

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:60:9: note: int WiFiClass::begin(char*)

     int begin(char* ssid);

         ^

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:60:9: note:   candidate expects 1 argument, 0 provided

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:70:9: note: int WiFiClass::begin(char*, uint8_t, const char*)

     int begin(char* ssid, uint8_t key_idx, const char* key);

         ^

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:70:9: note:   candidate expects 3 arguments, 0 provided

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:79:9: note: int WiFiClass::begin(char*, const char*)

     int begin(char* ssid, const char *passphrase);

         ^

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:79:9: note:   candidate expects 2 arguments, 0 provided

ATEM_tally_light:233:10: error: 'class WiFiClass' has no member named 'hostname'

     WiFi.hostname(settings.tallyName);

          ^

ATEM_tally_light:235:10: error: 'class WiFiClass' has no member named 'setAutoReconnect'

     WiFi.setAutoReconnect(true);

          ^

ATEM_tally_light:251:10: error: 'class WiFiClass' has no member named 'waitForConnectResult'

     WiFi.waitForConnectResult();

          ^

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino: In function 'void loop()':

ATEM_tally_light:261:22: error: 'class WiFiClass' has no member named 'mode'

                 WiFi.mode(WIFI_STA); // Disable softAP if connection is successful

                      ^

ATEM_tally_light:261:27: error: 'WIFI_STA' was not declared in this scope

                 WiFi.mode(WIFI_STA); // Disable softAP if connection is successful

                           ^

ATEM_tally_light:271:22: error: 'class WiFiClass' has no member named 'mode'

                 WiFi.mode(WIFI_AP_STA); // Enable softAP to access web interface in case of no WiFi

                      ^

ATEM_tally_light:271:27: error: 'WIFI_AP_STA' was not declared in this scope

                 WiFi.mode(WIFI_AP_STA); // Enable softAP to access web interface in case of no WiFi

                           ^

ATEM_tally_light:272:22: error: 'class WiFiClass' has no member named 'softAP'

                 WiFi.softAP("Tally Light setup");

                      ^

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino: In function 'void handleRoot()':

ATEM_tally_light:554:18: error: 'class WiFiClass' has no member named 'hostname'

     html += WiFi.hostname();

                  ^

ATEM_tally_light:609:14: error: 'class WiFiClass' has no member named 'isConnected'

     if (WiFi.isConnected()) //As a minimum security meassure, to only send the wifi password if it's currently connected to the given network.

              ^

ATEM_tally_light:610:22: error: 'class WiFiClass' has no member named 'psk'

         html += WiFi.psk();

                      ^

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino: In function 'void handleSave()':

ATEM_tally_light:727:66: error: 'class WiFiClass' has no member named 'psk'

             if (ssid && pwd && (ssid != getSSID() || pwd != WiFi.psk())) {

                                                                  ^

ATEM_tally_light:728:39: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

                 WiFi.begin(ssid.c_str(), pwd.c_str());

                                       ^

In file included from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:5:0:

C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi\src/WiFi.h:79:9: error:   initializing argument 1 of 'int WiFiClass::begin(char*, const char*)' [-fpermissive]

     int begin(char* ssid, const char *passphrase);

         ^

In file included from C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer.h:259:0,

                 from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:43:

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h: In instantiation of 'void esp8266webserver::ESP8266WebServerTemplate<ServerType>::handleClient() [with ServerType = WiFiServer]':

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:349:25:   required from here

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:319:20: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

     _currentClient = client;

                    ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:327:34: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

   if (_currentClient.connected() || _currentClient.available()) {

                                  ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:327:34: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:334:7: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

       if (_currentClient.available()) {

       ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:335:41: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

         if (_parseRequest(_currentClient)) {

                                         ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:335:41: error: '_parseRequest' was not declared in this scope

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:336:11: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

           _currentClient.setTimeout(HTTP_MAX_SEND_WAIT);

           ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:340:11: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

           if (_currentClient.connected()) {

           ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:363:20: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

     _currentClient = ClientType();

                    ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h: In instantiation of 'void esp8266webserver::ESP8266WebServerTemplate<ServerType>::send(int, const char*, const String&) [with ServerType = WiFiServer]':

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:647:39:   required from here

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:446:5: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

     _currentClient.write((const uint8_t *)header.c_str(), header.length());

     ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h: In instantiation of 'void esp8266webserver::ESP8266WebServerTemplate<ServerType>::close() [with ServerType = WiFiServer]':

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:108:9:   required from 'void esp8266webserver::ESP8266WebServerTemplate<ServerType>::begin() [with ServerType = WiFiServer]'

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:245:18:   required from here

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:375:3: error: 'class WiFiServer' has no member named 'close'

   _server.close();

   ^

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h: In instantiation of 'void esp8266webserver::ESP8266WebServerTemplate<ServerType>::send_P(int, const char*, const char*) [with ServerType = WiFiServer]':

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer.h:134:39:   required from 'void esp8266webserver::ESP8266WebServerTemplate<ServerType>::send(int, const char*, const char*) [with ServerType = WiFiServer]'

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:653:489:   required from here

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:463:5: error: using invalid field 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::_currentClient'

     _currentClient.write((const uint8_t *)header.c_str(), header.length());

     ^

In file included from C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer.h:259:0,

                 from C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:43:

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h: In instantiation of 'esp8266webserver::ESP8266WebServerTemplate<ServerType>::~ESP8266WebServerTemplate() [with ServerType = WiFiServer]':

C:\Users\HPz800\Documents\Arduino\ATEM_tally_light_with_ESP8266-3.1\ATEM_tally_light\ATEM_tally_light.ino:126:18:   required from here

C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WebServer\src/ESP8266WebServer-impl.h:91:3: error: 'class WiFiServer' has no member named 'close'

   _server.close();

   ^

Multiple libraries were found for "EthernetUdp.h"

 Used: C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\Ethernet

 Not used: C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\Ethernet

Multiple libraries were found for "WiFiClient.h"

 Used: C:\Users\HPz800\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WiFi

 Not used: C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\WiFi

exit status 1

'class WiFiClass' has no member named 'mode'

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
AronHetLam commented 3 years ago

That's a first... I'm not sure why, but it seems it's getting hold of the wrong WiFi library, that doesn't have the features it needs. Make sure it gets the ESP8266 one. Try turning on verbose mode in settings, and post what it the outputs. To make it look nicer, put it all in ``` post ``` image Then I may be able to see what files exactly it's trying to use.

If you've changed your include statements, you could post those as well.

AronHetLam commented 3 years ago

I would assume you would get the same problems running ESP8266 examples using WiFi

AronHetLam commented 3 years ago

Any update on this issue?

AronHetLam commented 3 years ago

I'll close this as it's been inactive for a while now.