mirror of
https://github.com/ratspeak/microReticulum
synced 2026-11-27 13:52:14 +00:00
WIP: Continued work of persistence and refactoring
This commit is contained in:
1 parent
f9a679ffc2
commit
162dcff6cd
25 files changed
+1026
-315
No files matched your search
+12
-7
@@ -14,7 +14,8 @@
|
||||
using namespace RNS;
|
||||
using namespace RNS::Type::Reticulum;
|
||||
|
||||
/*static*/ std::string Reticulum::storagepath;
|
||||
/*static*/ std::string Reticulum::_storagepath;
|
||||
/*static*/ std::string Reticulum::_cachepath;
|
||||
|
||||
/*static*/ bool Reticulum::__transport_enabled = false;
|
||||
/*static*/ bool Reticulum::__use_implicit_proof = true;
|
||||
@@ -40,9 +41,6 @@ Reticulum::Reticulum() : _object(new Object()) {
|
||||
// Initialkize random number generator
|
||||
RNG.begin("Reticulum");
|
||||
|
||||
// CBA TEST Transport
|
||||
__transport_enabled = true;
|
||||
|
||||
Utilities::OS::setup();
|
||||
|
||||
#ifdef ARDUINO
|
||||
@@ -81,9 +79,11 @@ Reticulum::Reticulum() : _object(new Object()) {
|
||||
*/
|
||||
// CBA MOCK
|
||||
#ifdef ARDUINO
|
||||
storagepath = "";
|
||||
_storagepath = "";
|
||||
_cachepath = "";
|
||||
#else
|
||||
storagepath = ".";
|
||||
_storagepath = ".";
|
||||
_cachepath = ".";
|
||||
#endif
|
||||
|
||||
/* TODO
|
||||
@@ -148,7 +148,8 @@ Reticulum::Reticulum() : _object(new Object()) {
|
||||
RNS.Identity.load_known_destinations()
|
||||
*/
|
||||
|
||||
Transport::start(*this);
|
||||
// CBA Moved to start() so Transport is not started until after interfaces are setup
|
||||
//Transport::start(*this);
|
||||
|
||||
/*
|
||||
self.rpc_addr = ("127.0.0.1", self.local_control_port)
|
||||
@@ -169,6 +170,10 @@ Reticulum::Reticulum() : _object(new Object()) {
|
||||
}
|
||||
|
||||
|
||||
void Reticulum::start() {
|
||||
Transport::start(*this);
|
||||
}
|
||||
|
||||
void Reticulum::loop() {
|
||||
assert(_object);
|
||||
if (!_object->_is_connected_to_shared_instance) {
|
||||
|
||||
Reference in new issue
Block a user