renamed Node to PatrixNode
This commit is contained in:
parent
d975d7d207
commit
e517e3d717
@ -1,16 +1,16 @@
|
|||||||
#ifndef NODE_TEST_H
|
#ifndef PATRIX_NODE_TEST_H
|
||||||
#define NODE_TEST_H
|
#define PATRIX_NODE_TEST_H
|
||||||
|
|
||||||
#include <patrix/display/DisplayMatrix.h>
|
#include <patrix/display/DisplayMatrix.h>
|
||||||
#include <patrix/node/Node.h>
|
#include <patrix/node/PatrixNode.h>
|
||||||
|
|
||||||
DisplayMatrix<32, 8> display;
|
DisplayMatrix<32, 8> display;
|
||||||
|
|
||||||
class NodeTest final : public Node {
|
class NodeTest final : public PatrixNode {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
explicit NodeTest() : Node(true, true, true) {
|
explicit NodeTest() : PatrixNode(true, true, true) {
|
||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,6 +2,6 @@
|
|||||||
|
|
||||||
auto node = NodeTest();
|
auto node = NodeTest();
|
||||||
|
|
||||||
Node &patrixGetNode() {
|
PatrixNode &patrixGetNode() {
|
||||||
return node;
|
return node;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -12,6 +12,6 @@
|
|||||||
#include <patrix/core/mqtt.h>
|
#include <patrix/core/mqtt.h>
|
||||||
#include <patrix/core/system.h>
|
#include <patrix/core/system.h>
|
||||||
#include <patrix/core/wifi.h>
|
#include <patrix/core/wifi.h>
|
||||||
#include <patrix/node/Node.h>
|
#include <patrix/node/PatrixNode.h>
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
#include <patrix/core/clock.h>
|
#include <patrix/core/clock.h>
|
||||||
#include <patrix/core/log.h>
|
#include <patrix/core/log.h>
|
||||||
#include <patrix/core/wifi.h>
|
#include <patrix/core/wifi.h>
|
||||||
#include <patrix/node/Node.h>
|
#include <patrix/node/PatrixNode.h>
|
||||||
|
|
||||||
#include "esp32/rom/rtc.h"
|
#include "esp32/rom/rtc.h"
|
||||||
|
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
#include <ESPAsyncWebServer.h>
|
#include <ESPAsyncWebServer.h>
|
||||||
#include <patrix/core/log.h>
|
#include <patrix/core/log.h>
|
||||||
#include <patrix/core/system.h>
|
#include <patrix/core/system.h>
|
||||||
#include <patrix/node/Node.h>
|
#include <patrix/node/PatrixNode.h>
|
||||||
|
|
||||||
AsyncWebServer server(80);
|
AsyncWebServer server(80);
|
||||||
|
|
||||||
|
|||||||
@ -1,4 +0,0 @@
|
|||||||
#include <patrix/node/Node.h>
|
|
||||||
|
|
||||||
// ReSharper disable once CppUseAuto
|
|
||||||
Node patrixNode = patrixGetNode();
|
|
||||||
4
src/patrix/node/PatrixNode.cpp
Normal file
4
src/patrix/node/PatrixNode.cpp
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
#include <patrix/node/PatrixNode.h>
|
||||||
|
|
||||||
|
// ReSharper disable once CppUseAuto
|
||||||
|
PatrixNode patrixNode = patrixGetNode();
|
||||||
@ -1,9 +1,9 @@
|
|||||||
#ifndef NODE_H
|
#ifndef PATRIX_NODE_H
|
||||||
#define NODE_H
|
#define PATRIX_NODE_H
|
||||||
|
|
||||||
#include <ESPAsyncWebServer.h>
|
#include <ESPAsyncWebServer.h>
|
||||||
|
|
||||||
class Node {
|
class PatrixNode {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
@ -13,14 +13,14 @@ public:
|
|||||||
|
|
||||||
const bool waitForClock;
|
const bool waitForClock;
|
||||||
|
|
||||||
explicit Node(const bool waitForWiFi, const bool waitForOTA, const bool waitForClock)
|
explicit PatrixNode(const bool waitForWiFi, const bool waitForOTA, const bool waitForClock)
|
||||||
: waitForWiFi(waitForWiFi),
|
: waitForWiFi(waitForWiFi),
|
||||||
waitForOTA(waitForOTA),
|
waitForOTA(waitForOTA),
|
||||||
waitForClock(waitForClock) {
|
waitForClock(waitForClock) {
|
||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual ~Node() = default;
|
virtual ~PatrixNode() = default;
|
||||||
|
|
||||||
virtual void setup() {}
|
virtual void setup() {}
|
||||||
|
|
||||||
@ -30,8 +30,8 @@ public:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
extern Node patrixNode;
|
extern PatrixNode patrixNode;
|
||||||
|
|
||||||
Node& patrixGetNode();
|
PatrixNode& patrixGetNode();
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
Loading…
Reference in New Issue
Block a user