Skip to content
Snippets Groups Projects
Commit 8b496b83 authored by francois's avatar francois
Browse files

update

parent e59975c5
No related branches found
No related tags found
No related merge requests found
......@@ -9,7 +9,6 @@
* - ...
*
* ---
* F.Thiebolt jan.23 removed wifiManager.setMinimumSignalQuality(); cause of DHCP issues ??
* F.Thiebolt aug.22 removed WiFiparameters hack :) ... by means of dynamic allocation :|
* F.Thiebolt aug.21 extended checkCLEAR to 5000ms (some ESP32 have huge
* internal capacitor enabled@starup ?!?!)
......@@ -213,10 +212,8 @@ bool setupWiFi( wifiParametersMgt *wp ) {
// set config save notify callback: only usefull for additional parameters
wifiManager.setSaveConfigCallback( cb_exitConfigMode );
/* set minimum signal level
* [jan.23] disabled while trying to overcome DHCP issues :|
* wifiManager.setMinimumSignalQuality(); // min. default is 8%
*/
// set minimum signal level
wifiManager.setMinimumSignalQuality(); // min. default is 8%
/* [aug.20] does not work on ESP32 ... segfault :(
* set custom ip for AP portal
......
......@@ -9,6 +9,9 @@
* (c) F.Thiebolt / neOCampus operation - Université Toulouse 3
*
* ---
* WARNING: [jan.23] WiFiManager 2.0.15-rc1 does not list WiFi networks available !?!?!
* ==> UPGRADE WiFiManager for bsp_update branch <==
* ---
* NOTES:
* - [ESP8266]MEMP_NUM_TCP_PCB= 8 (MAX simulteaneous listening TCP connections)
* - you need to 'deploy' our boards definitions (run the deploy.sh script)
......
#include <WiFiManager.h> // https://github.com/tzapu/WiFiManager
/* Global variables */
const char *mySSID="neOCampus";
const char *mySSIDpw="CHANGE_ME";
void setup() {
delay(3000); // time for USB serial link to come up anew
Serial.begin(115200); // Start serial for output
Serial.println(F("\n\n###\n### Starting simple WiFiManager connection test ...\n###"));
// Arduino libs v2.4.1, to enable printf and debug messages output
Serial.setDebugOutput( true );
WiFi.mode(WIFI_STA); // explicitly set mode, esp defaults to STA+AP
// it is a good practice to make sure your code sets wifi mode how you want it.
//WiFiManager, Local intialization. Once its business is done, there is no need to keep it around
WiFiManager wm;
wm.setDebugOutput(true);
// reset settings - wipe stored credentials for testing
// these are stored by the esp library
// wm.resetSettings();
// Automatically connect using saved credentials,
// if connection fails, it starts an access point with the specified name ( "AutoConnectAP"),
// if empty will auto generate SSID, if password is blank it will be anonymous AP (wm.autoConnect())
// then goes into a blocking loop awaiting configuration and will return success result
Serial.println(F("\tconnection timeout to 5mn ...");
wm.setConnectTimeout(300);
bool res;
// res = wm.autoConnect(); // auto generated AP name from chipid
// res = wm.autoConnect("AutoConnectAP"); // anonymous ap
res = wm.autoConnect(mySSID,mySSIDpw); // password protected ap
if(!res) {
Serial.println("Failed to connect");
// ESP.restart();
}
else {
//if you get here you have connected to the WiFi
Serial.println("connected...yeey :)");
}
}
void loop() {
// put your main code here, to run repeatedly:
Serial.print("+"); delay(1000);
}
# SPDX-License-Identifier: GPL-2.0-or-later
#
# Example OpenOCD configuration file for ESP32-WROVER-KIT board.
#
# For example, OpenOCD can be started for ESP32 debugging on
#
# openocd -f board/esp32-wrover-kit-3.3v.cfg
#
# Source the JTAG interface configuration file
source [find interface/ftdi/esp32_devkitj_v1.cfg]
set ESP32_FLASH_VOLTAGE 3.3
# Source the ESP32 configuration file
source [find target/esp32.cfg]
{
"name":"Arduino on ESP32",
"toolchainPrefix":"xtensa-esp32-elf",
"svdFile":"esp32.svd",
"request":"attach",
"postAttachCommands":[
"set remote hardware-watchpoint-limit 2",
"monitor reset halt",
"monitor gdb_sync",
"thb setup",
"c"
],
"overrideRestartCommands":[
"monitor reset halt",
"monitor gdb_sync",
"thb setup",
"c"
]
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment