Page 1 of 1

wifi headache issue with const char * (SOLVED)

Posted: Sun Nov 24, 2019 12:22 am
by mikronauts
problem:

I need to attach to different AP's so the requirement for const char * for ssid and password is making using the Arduino ide impossible.

Later I will move to the IDF but the Arduino IDE is much faster than the IDF.

does anyone have any suggestions?

I have already tried different ways of casting, and also tried

const char *ssid, *sspw;

and pointing them to my char arrays, but it did not work... I suspect due to different handling of const (presumably flash arrays) vs array in ram.

Re: wifi headache issue with const char *

Posted: Sun Nov 24, 2019 12:53 am
by mikronauts
nvs would be an ideal solution if it would only return a const char * to the value.

Re: wifi headache issue with const char * (SOLVED)

Posted: Sun Nov 24, 2019 1:54 am
by mikronauts
updating to esp32 1.0.4 in board manager fixed that issue