Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

F not declared in this scope #76

Open
ChrisWighton opened this issue Apr 1, 2020 · 3 comments
Open

F not declared in this scope #76

ChrisWighton opened this issue Apr 1, 2020 · 3 comments

Comments

@ChrisWighton
Copy link

Hi guys, working on a new project using the ESP8266 for a small wifi module. When trying to build the project we get this error "F not declared in this scope".
We know this is an Arduino function, not something written in on our project but can anyone point us in the right direction as to where this error might be coming from and how to fix it.
We have tried the old turn it off and on again trick and updated Arduino and its libraries already but no success. One computer it works, the other it does not.

Any help would be greatly appreciated.

@d-skinner
Copy link

d-skinner commented May 1, 2020

I'm having the same problem.

MacOS Mojave: version 10.14.6 (18G3020)
Atom 1.45.0

In file included from .platformio/packages/framework-arduinoespressif8266/libraries/ESP8266WebServer/src/ESP 8266WebServer.h:235:0, from src/mavesp8266_httpd.cpp:44: .platformio/packages/framework-arduinoespressif8266/libraries/ESP8266WebServer/src/ESP8266WebServer-impl.h: In member function 'bool esp8266webserver::ESP8266WebServerTemplate<ServerType>::authenticate(const char*, const char*)': .platformio/packages/framework-arduinoespressif8266/libraries/ESP8266WebServer/src/ESP8266WebServer-impl.h:1 25:36: error: there are no arguments to 'F' that depend on a template parameter, so a declaration of 'F' must be available [-fpermissive] if(authReq.startsWith(F("Basic"))){

Is the first error I receive

@guglie
Copy link
Contributor

guglie commented May 12, 2020

You can use this fix (currently in master) f4413b5

basically the following include has to be first

https://github.com/dogmaphobic/mavesp8266/blob/f4413b53168faedef6814ab51de84b533d121205/src/mavesp8266_httpd.cpp#L38

@d-skinner
Copy link

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants