Core2 M5Unified independence + general fixes (#142)

- Change init sequence: I2C is now initialized before "power" init phase, to allow for I2C power control
- I2c HAL: Added read/write support for registers
- Added axp192 code from https://github.com/tuupola/axp192 to Core2 implementation
- Fixes for Core2Power
- Fix for root project CMakeLists.txt
This commit is contained in:
Ken Van Hoeylandt
2025-01-01 18:47:48 +01:00
committed by GitHub
parent 9581978fc7
commit 3214923425
15 changed files with 953 additions and 53 deletions
+5 -5
View File
@@ -6,17 +6,17 @@
namespace tt::hal {
void init(const Configuration& configuration) {
if (configuration.initBoot != nullptr) {
TT_LOG_I(TAG, "Init power");
tt_check(configuration.initBoot(), "Init power failed");
}
tt_check(i2c::init(configuration.i2c), "I2C init failed");
if (configuration.initHardware != nullptr) {
TT_LOG_I(TAG, "Init hardware");
tt_check(configuration.initHardware(), "Hardware init failed");
}
if (configuration.initBoot != nullptr) {
TT_LOG_I(TAG, "Init power");
tt_check(configuration.initBoot(), "Init power failed");
}
if (configuration.sdcard != nullptr) {
TT_LOG_I(TAG, "Mounting sdcard");
if (!configuration.sdcard->mount(TT_SDCARD_MOUNT_POINT )) {