- Implement `UiScale` in `hal::Configuration`: small screens with no touch can now opt for a more optimized experience (e.g. Cardputer, Waveshare 1.47, Waveshare 1.3", etc.) - Fix for Cardputer UART configuration and added I2C configuration - Fix for software keyboard bug in Gui - Removed deprecated fields from `hal::Configuration` - Updated the simulator devices to use the new HAL config - add `bool tt::hal::hasDevice(Device::Type)` - Cleanup of `AppList` app code - Improve `Gpio` app for small screen devices - Added various ESP32 GCC wrappers to wrap LVGL functions (with manipulations for small screen devices) - Moved `Launcher` assets to `assets/` subfolder - Optimized `Toolbar` for small screen devices - Stop showing `system/` partition in `FileBrowser` because it's read-only and not very useful. Created `config::SHOW_SYSTEM_PARTITION` to override this behaviour. - Hide apps when their required hardware isn't available (I2C, UART, PowerDevice) - Fix for `CYD-2432S032C` DPI setting
50 lines
1.5 KiB
C++
50 lines
1.5 KiB
C++
#pragma once
|
|
|
|
#include <Tactility/app/AppManifest.h>
|
|
#include <Tactility/Dispatcher.h>
|
|
#include <Tactility/hal/Configuration.h>
|
|
#include <Tactility/service/ServiceManifest.h>
|
|
|
|
namespace tt {
|
|
|
|
namespace app::launcher { extern const AppManifest manifest; }
|
|
|
|
/** @brief The configuration for the operating system
|
|
* It contains the hardware configuration, apps and services
|
|
*/
|
|
struct Configuration {
|
|
/** HAL configuration (drivers) */
|
|
const hal::Configuration* hardware = nullptr;
|
|
/** List of user applications */
|
|
const std::vector<const app::AppManifest*> apps = {};
|
|
/** List of user services */
|
|
const std::vector<const service::ServiceManifest*> services = {};
|
|
};
|
|
|
|
/**
|
|
* Attempts to initialize Tactility and all configured hardware.
|
|
* @param[in] config
|
|
*/
|
|
void run(const Configuration& config);
|
|
|
|
/**
|
|
* While technically nullable, this instance is always set if tt_init() succeeds.
|
|
* @return the Configuration instance that was passed on to tt_init() if init is successful
|
|
*/
|
|
const Configuration* _Nullable getConfiguration();
|
|
|
|
/** Provides access to the dispatcher that runs on the main task.
|
|
* @warning This dispatcher is used for WiFi and might block for some time during WiFi connection.
|
|
* @return the dispatcher
|
|
*/
|
|
Dispatcher& getMainDispatcher();
|
|
|
|
namespace hal {
|
|
|
|
/** While technically this configuration is nullable, it's never null after initHeadless() is called. */
|
|
const Configuration* _Nullable getConfiguration();
|
|
|
|
} // namespace hal
|
|
|
|
} // namespace tt
|