Add inital src and cmake

This commit is contained in:
KenwoodFox
2026-05-22 11:44:07 -04:00
parent b36b622268
commit 2124599cac
4 changed files with 32 additions and 0 deletions

3
.gitignore vendored
View File

@@ -86,3 +86,6 @@ dkms.conf
*.out
*.app
# Build and output
_build
build

7
CMakeLists.txt Normal file
View File

@@ -0,0 +1,7 @@
cmake_minimum_required(VERSION 3.20.0)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(timer_fw)
target_sources(app PRIVATE src/main.c)

6
prj.conf Normal file
View File

@@ -0,0 +1,6 @@
CONFIG_GPIO=y
CONFIG_SERIAL=y
CONFIG_CONSOLE=y
CONFIG_UART_CONSOLE=y
CONFIG_LOG=y
CONFIG_LOG_DEFAULT_LEVEL=3

16
src/main.c Normal file
View File

@@ -0,0 +1,16 @@
#include <zephyr/kernel.h>
#include <zephyr/logging/log.h>
LOG_MODULE_REGISTER(timer_fw, LOG_LEVEL_INF);
int main(void)
{
LOG_INF("Timer firmware booted!");
while (1) {
LOG_INF("heartbeat");
k_sleep(K_SECONDS(5));
}
return 0;
}