-
Hey there. I'm experimenting with this Arduino library, testing the examples and using a token to authenticate. I do it using:
It works Ok but sometimes I get a token error, and console output shows this in a loop:
I think that's the callback: When this endless loop happens I lose control and it doesn't return to loop(). I tried to use the WDT What can be done to avoid entering this infinite loop in case of this error? Even if the infinite loop is generated, shouldn't the WDT reset the ESP32? This is WDT configuration in setup():
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 4 replies
-
I think you incorrectly use or provide invalid parameter to the function Please make sure you understand the information that provided in the example. There is no blocking process in the library and the error showed from the callback is from the token processing task as long as you call Then it is not possible that the main loop will never execute when the token callback reports the error. The token processing task behind the |
Beta Was this translation helpful? Give feedback.
-
You also should not mix use of authentication methods by providing the following options while using Firebase-ESP-Client/examples/RTDB/Basic/Basic.ino Lines 98 to 99 in f17ea76 |
Beta Was this translation helpful? Give feedback.
-
You should provide both ID token (the second parameter) and the refresh token (fourth parameter) to the function. If you provide empty ID token, library will consider that you are using Email/Password authentication by default. |
Beta Was this translation helpful? Give feedback.
I think you incorrectly use or provide invalid parameter to the function
setIdToken
.Please make sure you understand the information that provided in the example.
Firebase-ESP-Client/examples/Authentications/SignInWithIDToken/SignInWithIDToken.ino
Lines 126 to 130 in f17ea76
There is no bloc…