Kernel and buildscript improvements (#477)
* **New Features** * Centralized module management with global symbol resolution * Level-aware logging with colored prefixes and millisecond timestamps * **Breaking Changes** * ModuleParent hierarchy and getModuleParent() removed * Logging API and adapter model replaced; LogLevel-driven log_generic signature changed * **Improvements** * Unified, simplified module registration across build targets * Tests updated to reflect new module lifecycle and global symbol resolution
This commit is contained in:
committed by
GitHub
parent
1a61eac8e0
commit
a935410f82
@@ -2,19 +2,8 @@ cmake_minimum_required(VERSION 3.20)
|
||||
|
||||
file(GLOB_RECURSE SOURCES "Source/*.c**")
|
||||
|
||||
if (DEFINED ENV{ESP_IDF_VERSION})
|
||||
|
||||
idf_component_register(
|
||||
SRCS ${SOURCES}
|
||||
INCLUDE_DIRS "Include/"
|
||||
REQUIRES TactilityKernel driver
|
||||
)
|
||||
|
||||
else ()
|
||||
|
||||
add_library(PlatformEsp32 OBJECT)
|
||||
target_sources(PlatformEsp32 PRIVATE ${SOURCES})
|
||||
target_include_directories(PlatformEsp32 PUBLIC Include/)
|
||||
target_link_libraries(PlatformEsp32 PUBLIC TactilityKernel)
|
||||
|
||||
endif ()
|
||||
idf_component_register(
|
||||
SRCS ${SOURCES}
|
||||
INCLUDE_DIRS "Include/"
|
||||
REQUIRES TactilityKernel driver
|
||||
)
|
||||
@@ -9,7 +9,7 @@
|
||||
#include <tactility/drivers/gpio.h>
|
||||
#include <tactility/drivers/gpio_controller.h>
|
||||
|
||||
#define TAG LOG_TAG(esp32_gpio)
|
||||
#define TAG "esp32_gpio"
|
||||
|
||||
#define GET_CONFIG(device) ((struct Esp32GpioConfig*)device->config)
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
#include <tactility/error_esp32.h>
|
||||
#include <tactility/drivers/esp32_i2c.h>
|
||||
|
||||
#define TAG LOG_TAG(esp32_i2c)
|
||||
#define TAG "esp32_i2c"
|
||||
#define ACK_CHECK_EN 1
|
||||
|
||||
struct InternalData {
|
||||
|
||||
@@ -2,19 +2,7 @@ cmake_minimum_required(VERSION 3.20)
|
||||
|
||||
file(GLOB_RECURSE SOURCES "Source/*.c**")
|
||||
|
||||
if (DEFINED ENV{ESP_IDF_VERSION})
|
||||
|
||||
idf_component_register(
|
||||
SRCS ${SOURCES}
|
||||
# INCLUDE_DIRS "Include/"
|
||||
REQUIRES TactilityKernel driver
|
||||
)
|
||||
|
||||
else ()
|
||||
|
||||
add_library(PlatformPosix OBJECT)
|
||||
target_sources(PlatformPosix PRIVATE ${SOURCES})
|
||||
# target_include_directories(PlatformPosix PUBLIC Include/)
|
||||
target_link_libraries(PlatformPosix PUBLIC TactilityKernel)
|
||||
|
||||
endif ()
|
||||
add_library(PlatformPosix OBJECT)
|
||||
target_sources(PlatformPosix PRIVATE ${SOURCES})
|
||||
#target_include_directories(PlatformPosix PUBLIC Include/)
|
||||
target_link_libraries(PlatformPosix PUBLIC TactilityKernel)
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
#include <tactility/freertos/task.h>
|
||||
#include <tactility/log.h>
|
||||
|
||||
#define TAG LOG_TAG(freertos)
|
||||
#define TAG "freertos"
|
||||
|
||||
/**
|
||||
* Assert implementation as defined in the FreeRTOSConfig.h
|
||||
|
||||
Reference in New Issue
Block a user