23 lines
545 B
C++
23 lines
545 B
C++
#include "Logic/FlightDispatcher.hpp"
|
|
#include "esp_log.h"
|
|
|
|
class Application {
|
|
public:
|
|
Application(FlightDispatcher *dispatcher) {
|
|
assert(dispatcher != nullptr);
|
|
_dispatcher = dispatcher;
|
|
ESP_LOGI(_tag, "Application startup complete");
|
|
}
|
|
|
|
void tick() {
|
|
_dispatcher->tick();
|
|
}
|
|
|
|
~Application() {
|
|
ESP_LOGI(_tag, "Application destroyed");
|
|
delete _dispatcher;
|
|
}
|
|
private:
|
|
FlightDispatcher *_dispatcher = nullptr;
|
|
static constexpr const char *_tag = "Application";
|
|
}; |