Repository navigation
Compilation error: 'UserAuth' does not name a type #181
|
Now, I'm in project using SIM800L to access firebase. I'm using Firebase Client library and do run this example code /**
#include <Arduino.h> #include <FirebaseClient.h> #define WIFI_SSID "WIFI_AP" // The API key can be obtained from Firebase console > Project Overview > Project settings. // User Email and password that already registerd or added in your project. void authHandler(); void printResult(AsyncResult &aResult); void printError(int code, const String &msg); DefaultNetwork network; // initilize with boolean parameter to enable/disable network reconnection UserAuth user_auth(API_KEY, USER_EMAIL, USER_PASSWORD); FirebaseApp app; #if defined(ESP32) || defined(ESP8266) || defined(ARDUINO_RASPBERRY_PI_PICO_W) using AsyncClient = AsyncClientClass; AsyncClient aClient(ssl_client, getNetwork(network)); RealtimeDatabase Database; AsyncResult aResult_no_callback; void setup() #if defined(ESP32) || defined(ESP8266) || defined(PICO_RP2040) } void loop() } void authHandler() void printResult(AsyncResult &aResult) } void printError(int code, const String &msg) and i got this error |
Replies: 6 comments 11 replies
|
You should post complete error message. |
|
Please read the documentation especially keyword "OneDrive". https://github.com/mobizt/FirebaseClient?tab=readme-ov-file#dependencies https://github.com/mobizt/FirebaseClient?tab=readme-ov-file#installation |
|
In file included from d:\arduino\libraries\firebaseclient\src\core\authconfig.h:31:0, exit status 1 Compilation error: 'UserAuth' does not name a type I have migrate my project from onedrive, but I'm still got the same error |
|
You make some trebles in Arduino systems. At this time. you have to uninstall OneDrive app from your PC. Next time, install the OndeDrive by excluding the Documents folder from the OndeDrive synching list. |
|
If your Documents folder has belonged to OneDrive, the compiler cannot get to the files inside |
|
I am currently getting this error. The current solution did not work for Arduino IDE. In addition, the error persists when using PlatformIO in VS code and installing the library through that, so the issue seems to be editor agnostic and not tied to the libraries folder as it was for Asima. I am also not using OneDrive or any similar tools. error message: `/home/oj/Arduino/sketch_aug31a/sketch_aug31a.ino:41:1: error: 'UserAuth' does not name a type Compilation error: 'UserAuth' does not name a type` |
You should do clean install the Arduino IDE because it is your Arduino IDE error.
PC restart may be required after uninstalling the OneDrive before installing the Arduino IDE.