Closed sim404 closed 2 years ago
Sorry for the inconvenience. Can you provide your sketch for analysis?
Sure, will do. Give me an hour or so please.
Sure, thank you for your assistance.
Meanwhile i tested the Doorbell example. It compiles without issues for me.
Ok, i think i identified two reasons.
Multiple libraries were found for "WiFi.h"
Used: C:\Users\wallis\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi
Not used: C:\Program Files (x86)\Arduino\libraries\WiFi
Well I'm sure you are right re the left overs! When I fired up the desktop to send you the code, even though I'd tried to compile 2/3 times before flagging the issue to you, I tried the whole thing again. Guess what, no errors not even the wifi.h multiple. The other thing I realised afterward, I didn't reboot Arduino after upgrading to 2.9.15. So I'm thoroughly embarrassed now, butt have at least learnt something from it. I'm attaching the code for completeness and who knows, the crudity of it might give people a laugh. Regards, Steve sinricPro_doorbell_vs20github.txt
I am glad that the problem has been solved.
Thank you for providing your code - which actually does not compile for me, because of some missing declarations: sendUdpTelegram()
, waitHere100ms
and ssidToTelegram
In the comment block at the beginning i saw this:
/*
FYI re websockets tmo issue:
sinricProConfig.h contains the following:
// WebSocket Configuration
#define WEBSOCKET_PING_INTERVAL 300000
#define WEBSOCKET_PING_TIMEOUT 10000
#define WEBSOCKET_RETRY_COUNT 2
/*
Please do not modify the internal settings. I am nosey about the reason for this (even it is commented out).
Actually those three declarations are there but below the references to them. Bad practice that I suppose and a reminder that I should move to platformio. The websocket defines are entirely historic and from when I first started using Sinric I had an issue getting sinric to stay connected. I’d forgotten they were still there and will delete. Actually there’s an old GitHub issue I raised on it. It turned out to be a rogue version of nodemcu board. I never normally mess with the *.h files for the reason you’re thinking… Many thanks for you time on the above.
Thank you for the feedback :)
Just one, two notes:
I saw you're setting flag in myConnected()
and myDisconnected()
callback.
This is not necessary. You can make a call to SinricPro.isConnected()
to check the connection state.
It returns true
if connected and false
if not connected.
You can still use the callback's for lighting an LED, or Serial output etc.
I also saw multiple calls to SinricPro.handle()
in the main loop.
This shouldn't be necessary (but it doesn't hurt ;)
Sivar, thanks for the flag tip. I’ll make that change. Point taken re the belt&brace multiple handle calls.
Hi, I just loaded release2.9.15 using Arduino and re-compiled some existing doorbell code and got the errors in the attached .txt file. I'm using latest json and made only a minor change to the existing doorbell code. Reverted to 2.9.14 and it compiles no errors. Your comments please sinricP_err_message310122.txt .