mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-18 10:53:17 +00:00
* **Documentation** * Added new C coding style guide detailing naming conventions for files, directories, macros, constants, variables, functions, and type definitions with illustrative examples. * Updated C++ coding style documentation with clarifications on C naming conventions and header directory organization patterns. * **Refactor** * Updated header include paths throughout the codebase to use lowercase naming conventions consistently.
42 lines
944 B
C++
42 lines
944 B
C++
#include <Tactility/Tactility.h>
|
|
|
|
#include <tactility/driver.h>
|
|
#include <devicetree.h>
|
|
|
|
#ifdef ESP_PLATFORM
|
|
#include <tt_init.h>
|
|
#else
|
|
#include <Simulator.h>
|
|
#endif
|
|
|
|
// Each board project declares this variable
|
|
extern const tt::hal::Configuration hardwareConfiguration;
|
|
|
|
extern "C" {
|
|
|
|
extern void register_kernel_drivers();
|
|
extern void register_platform_drivers();
|
|
extern void register_device_drivers();
|
|
|
|
void app_main() {
|
|
static const tt::Configuration config = {
|
|
/**
|
|
* Auto-select a board based on the ./sdkconfig.board.* file
|
|
* that you copied to ./sdkconfig before you opened this project.
|
|
*/
|
|
.hardware = &hardwareConfiguration
|
|
};
|
|
|
|
#ifdef ESP_PLATFORM
|
|
tt_init_tactility_c(); // ELF bindings for side-loading on ESP32
|
|
#endif
|
|
|
|
register_kernel_drivers();
|
|
register_platform_drivers();
|
|
register_device_drivers();
|
|
|
|
devices_builtin_init();
|
|
tt::run(config);
|
|
}
|
|
|
|
} // extern
|