Hello all!
Im testing Arduino IoT cloud with Portenta H7 with a couple of sensors, but when i try to validate the code, i have this error message (al error messages attached below):
libraries\Arduino_ConnectionHandler\src\Arduino_WiFiConnectionHandler.cpp:93:16: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]
WiFi.begin(_ssid, _pass);
i try to change the way the sketch comunicates the pass & SSID to libraries:
1st way - it is the same as all the examples
const char SSID[] = SECRET_SSID; // Network SSID (name)
const char PASS[] = SECRET_PASS; // Network password (use for WPA, or use as key for WEP)
2nd - i made this change because i see at the destiny function SSID and pass was declared by this way:
char SSID[] = SECRET_SSID; // Network SSID (name)
const char PASS[] = SECRET_PASS; // Network password (use for WPA, or use as key for WEP)
3rd way - IdahoWalker's clue
char SSID[] = SECRET_SSID; // Network SSID (name)
const char* PASS = SECRET_PASS; // Network password (use for WPA, or use as key for WEP)
4th - Same but changing the SSID to pointer.
char* SSID = SECRET_SSID; // Network SSID (name)
const char* PASS = SECRET_PASS; // Network password (use for WPA, or use as key for WEP)
5th
const char* SSID = SECRET_SSID; // Network SSID (name)
const char* PASS = SECRET_PASS; // Network password (use for WPA, or use as key for WEP)
6th EDIT: CORRECT ONE -> i recommend you find the library which is envolved or called (WiFi.h, at this case, to init the WiFi connection) and find the function (begin, at this case). Here, the function is declared:
int arduino::WiFiClass::begin(const char* ssid, const char *passphrase)
So i introduce the code the same:
const char* SSID = SECRET_SSID; // Network SSID (name)
const char *PASS = SECRET_PASS; // Network password (use for WPA, or use as key for WEP)
Here is the code: GitHub - amoya04/Portenta-H7-Arduino-IoT-Cloud: This project is in progress, its pending to made changes because it doesnt compiles..
Could someone help me please?
errorcode_AIoT.txt (11.1 KB)