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
Telegram not working on Arduino core for the ESP32 #228
Comments
looks like none of them work. I have problems connecting to HTTPS so this has to be somewhere level below |
I posted an issues on espressif/esp32 repository about this problem but it was closed immediately with comment: |
Can you enable debug logs and see where it fails to connect? |
for me it works in PlatformIO. I don't have much time to update it again but I saw the problem was in connecting HTTPS, simply returned nothing. When I have time I'll update and post the results but I'll leave it to @turbonatta turbonatta for now This is what works for me now UniversalTelegramBot 1.3.0 |
I developed the applications on Arduino IDE. As you know debug capability are very limited. I'll try this evening (Italian time). I suspect maybe the problem is in WiFiClientSecure |
I think the request was to enable debug. Uncomment line 25 of UniversalTelegramBot.h to look like this: Run your program again And post the serial output here. |
Sorry, I misandurstood, :) |
Sorry, I misunderstood, :):) |
Enabling Debug on the library as @mgx0 mentioned is a good start. if it fails at the connect stage we can generate a sample sketch to go back to the Espressif guys with |
This is the serial output with debug enable: |
I am running a simple web server as well to display few sensor data and it works without problem |
Reinstalling previous 1.0.4 core library ESP32: 20:15:38.780 -> ets Jun 8 2016 00:22:57 |
try this:
I'm getting error -1 in httpCode in Core 1.0.5 I guess this is enough to see that this is a general problem with ESP32 core 1.0.5 and not this library |
Thanx mgx0! |
They cannot turn you down with this above. This has nothing to do with external library. Reopen the issue there and post the link here. Or maybe @witnessmenow could help, I'm not very github-experienced |
I think that example is great, I would maybe use something that doesn't crash 1.4 though 😅 If I get some time over the next few days I can raise the issue, but I'm really swamped at the moment so I would really appreciate if someone else could take charge of it! |
I am going to raise the issue, this evening as soon I'll get home, For whatevere reason when I run the test code on 1.0.4 core it did not crush. I got a "404" reply plus some other information from Google and the "-1" error code on 1.0.5 core as seen by mgx0 |
it crashes because of the length of the response. give it https://www.google.com/asdf to make sure you get 404 or you can use for example https://blockchain.info/tobtc?currency=USD&value=500 as the URL but you have to replace the certificate in the sketch |
I raised the issue on espressif repository posting the output of the sample program with the two cores and it was closed right away. 23:10:29.272 -> [D][WiFiGeneric.cpp:374] _eventCallback(): Event: 0 - WIFI_READY I am not sure what to make but it looks like that the certificate is checked before it try to connect. |
I just tested a fresh install of the ESP32 Core and the library is working for me. Do you have a different ESP32 you could try @turbonatta ? I have a feather huzzah that is funny with different versions of the ESP32 core and im not sure why. |
I have two esp32-wroom-devkitc v2 and they both shows the same behaviour |
I finally figure out the problem! I build my project using an example for Universal-Arduino-Telegram-bot found on internet. This example establish a secure connection without using any root certificate. With ESP32 core 1.0.4 the missing certificate generate only a warning, when "Core Level Debug" is on, to improve security by using a certificate. With ESP32 core 1.0.5 it refuse the connection unless you provide a certificate or you execute client.SetInsicure(); I test both solution and the Telegram interface works fine with the same warning to improve security when using SetInsicure(); |
man, thanks so much! I just spent the whole day picking my project apart as I thought I must have broken something – that one line fixed it... |
Hi! What versions of ArduinoJson, UniversalTelegramBot , esp32 core, WiFiClientSecure and Arduino IDE are you using. I have the same error but client.setInsecure and secured_client.setCACert(TELEGRAM_CERTIFICATE_ROOT); don't work for me. |
i would like to know the same, both solutions also don't work for me |
With the latest core 1.0.5 released on Febraruary 23rd 2021 Telegram no longer work.
No error message during compilation on Arduino IDE.
The application compiled with the newest core does not send or received any message on Telegram platform.
Reverting to previous 1.0.4 core fix the problem.
Any suggestion?
The text was updated successfully, but these errors were encountered: