Skip to content

Commit

Permalink
Merge pull request emsesp#1405 from proddy/dev2
Browse files Browse the repository at this point in the history
fix standalone compiling
  • Loading branch information
proddy authored Nov 10, 2023
2 parents 52077cb + 3fc36b5 commit 81b654c
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 4 deletions.
3 changes: 3 additions & 0 deletions lib_standalone/Arduino.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include <cstdint>
#include <cstring>
#include <string>
#include <math.h>

#include <algorithm> // for count_if

Expand Down Expand Up @@ -187,4 +188,6 @@ void yield(void);
void setup(void);
void loop(void);



#endif
1 change: 1 addition & 0 deletions lib_standalone/ESP8266React.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ class DummySettings {
String jwtSecret = "ems-esp";
String ssid = "ems-esp";
String password = "ems-esp";
String bssid = "";
String localIP = "";
String gatewayIP = "";
String subnetMask = "";
Expand Down
19 changes: 15 additions & 4 deletions lib_standalone/Preferences.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,20 @@ class Preferences {
return NAN;
}

size_t putString(const char * key, const char * value) {
return 0;
}
size_t putString(const char * key, String value) {
return 0;
}

size_t getString(const char * key, char * value, size_t maxLen) {
return 0;
}
String getString(const char * key, String defaultValue = String()) {
return "";
}

// unused

// void end();
Expand All @@ -59,8 +73,7 @@ class Preferences {
// size_t putULong64(const char * key, uint64_t value);
// size_t putFloat(const char * key, float_t value);
// size_t putBool(const char * key, bool value);
// size_t putString(const char * key, const char * value);
// size_t putString(const char * key, String value);

// size_t putBytes(const char * key, const void * value, size_t len);
// bool isKey(const char * key);
// PreferenceType getType(const char * key);
Expand All @@ -75,8 +88,6 @@ class Preferences {
// uint64_t getULong64(const char * key, uint64_t defaultValue = 0);
// float_t getFloat(const char * key, float_t defaultValue = NAN);
// bool getBool(const char * key, bool defaultValue = false);
// size_t getString(const char * key, char * value, size_t maxLen);
// String getString(const char * key, String defaultValue = String());
// size_t getBytesLength(const char * key);
// size_t getBytes(const char * key, void * buf, size_t maxLen);
// size_t freeEntries();
Expand Down

0 comments on commit 81b654c

Please sign in to comment.