Initial commit

This commit is contained in:
Tony
2026-04-29 18:53:26 +08:00
commit f4756ce816
45 changed files with 14318 additions and 0 deletions
+38
View File
@@ -0,0 +1,38 @@
#include "gateway_core.hpp"
#include "gateway_runtime.hpp"
namespace {
constexpr const char* kProjectName = "UartRelayer";
constexpr const char* kProjectVersion = "0.1.0";
gateway::BootProfile ReceiverProfile() {
return gateway::BootProfile{
gateway::AppRole::kReceiver,
"receiver",
false,
false,
false,
true,
true,
};
}
} // namespace
extern "C" void app_main(void) {
ESP_ERROR_CHECK(gateway::InitializeRuntimeNvs());
gateway::GatewayCore core(ReceiverProfile());
core.start();
gateway::GatewayRuntime runtime(
core.profile(),
gateway::GatewayRuntimeConfig{
kProjectName,
kProjectVersion,
gateway::ReadRuntimeSerialId(),
},
nullptr);
ESP_ERROR_CHECK(runtime.start());
}