Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
neOCampus-arduino
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GIS-neOCampus
neOSensor
neOCampus-arduino
Commits
8771460f
Commit
8771460f
authored
2 years ago
by
francois
Browse files
Options
Downloads
Patches
Plain Diff
update
parent
0a7a7912
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
neosensor/libraries/neocampus/wifiParametersMgt.cpp
+16
-0
16 additions, 0 deletions
neosensor/libraries/neocampus/wifiParametersMgt.cpp
with
16 additions
and
0 deletions
neosensor/libraries/neocampus/wifiParametersMgt.cpp
+
16
−
0
View file @
8771460f
...
@@ -29,6 +29,8 @@
...
@@ -29,6 +29,8 @@
#include
<WiFi.h>
#include
<WiFi.h>
#endif
/* ESP8266 */
#endif
/* ESP8266 */
#include
"Preferences.h"
// NVS storage (instead of the DEPRECATED eeprom)
#include
"neocampus.h"
#include
"neocampus.h"
#include
"neocampus_debug.h"
#include
"neocampus_debug.h"
...
@@ -53,6 +55,9 @@ extern bool _need2reboot;
...
@@ -53,6 +55,9 @@ extern bool _need2reboot;
#define CONFIG_JSON_SIZE (JSON_OBJECT_SIZE(20))
#define CONFIG_JSON_SIZE (JSON_OBJECT_SIZE(20))
// NVS namespace for WiFi credentials
#define WIFI_NVS_NAMESPACE "wifiCredentials" // 15 chars max.
// constructor
// constructor
wifiParametersMgt
::
wifiParametersMgt
(
void
)
{
wifiParametersMgt
::
wifiParametersMgt
(
void
)
{
...
@@ -342,6 +347,17 @@ void wifiParametersMgt::_applyDefaults( void ) {
...
@@ -342,6 +347,17 @@ void wifiParametersMgt::_applyDefaults( void ) {
// Whole destruction option
// Whole destruction option
_opt_eraseALL
=
false
;
_opt_eraseALL
=
false
;
/*
* [may.23] now trying to access wifi credentias NVS namespace
*/
Preferences
nvs_area
;
if
(
nvs_area
.
begin
(
WIFI_NVS_NAMESPACE
,
true
)
)
{
// readonly mode
log_debug
(
F
(
"
\n
[wifiParams] opened NVS WiFi credentials namespace ..."
));
log_flush
();
// TO BE CONTINUED
}
/*
/*
* finally structure is initialized
* finally structure is initialized
*/
*/
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment