posix drivers, mock drivers and struct Driver changes

This commit is contained in:
Ken Van Hoeylandt 2026-10-11 01:20:13 +02:00
parent b9a96ca26d
commit 8c4bfc2260
165 changed files with 997 additions and 353 deletions

View File

@ -182,6 +182,7 @@ if (NOT DEFINED ENV{ESP_IDF_VERSION})
add_subdirectory(Modules/lvgl-window-manager-module)
add_subdirectory(Drivers/gps-generic-module)
add_subdirectory(Drivers/gps-meshtastic-module)
add_subdirectory(Drivers/mock-drivers-module)
# Kernel-only software aggregate; built on sim so its device-lifecycle behavior
# is covered by Drivers/audio-stream-module/tests.
add_subdirectory(Drivers/audio-stream-module)

View File

@ -324,6 +324,5 @@ Driver cl32_v4_keyboard_driver = {
.probe = nullptr,
.api = &cl32_v4_keyboard_api,
.device_type = &KEYBOARD_TYPE,
.owner = &cl32_v04_module,
.internal = nullptr,
};

View File

@ -70,6 +70,5 @@ Driver cl32_v4_light_driver = {
.probe = nullptr,
.api = &CL32_V4_LIGHT_API,
.device_type = &BACKLIGHT_TYPE,
.owner = &cl32_v04_module,
.internal = nullptr,
};

View File

@ -101,7 +101,6 @@ Driver cl32_v4_power_supply_driver = {
.stop_device = nullptr,
.api = &CL32_V4_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &cl32_v04_module,
.internal = nullptr
};
@ -192,6 +191,5 @@ Driver cl32_v4_power_driver = {
.probe = nullptr,
.api = nullptr,
.device_type = nullptr,
.owner = &cl32_v04_module,
.internal = nullptr,
};

View File

@ -422,7 +422,6 @@ Driver papers3_display_driver = {
.stop_device = stop,
.api = &papers3_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &m5stack_papers3_module,
.internal = nullptr
};

View File

@ -144,7 +144,6 @@ Driver papers3_power_supply_driver = {
.stop_device = nullptr,
.api = &PAPERS3_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &m5stack_papers3_module,
.internal = nullptr
};
@ -259,9 +258,9 @@ Driver papers3_power_driver = {
.compatible = (const char*[]) { "m5stack,papers3-power", nullptr },
.start_device = start,
.stop_device = stop,
.probe = nullptr,
.api = nullptr,
.device_type = nullptr,
.owner = &m5stack_papers3_module,
.internal = nullptr
};

View File

@ -672,7 +672,6 @@ Driver tab5_keyboard_driver = {
.probe = probe,
.api = &tab5_keyboard_api,
.device_type = &KEYBOARD_TYPE,
.owner = &m5stack_tab5_module,
.internal = nullptr
};

View File

@ -190,6 +190,5 @@ Driver tab5_power_control_driver = {
.stop_device = stop,
.api = &TAB5_POWER_CONTROL_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &m5stack_tab5_module,
.internal = nullptr
};

View File

@ -225,8 +225,8 @@ Driver sdl_display_driver = {
.compatible = (const char*[]) { "tactility,sdl-display", nullptr },
.start_device = start,
.stop_device = stop,
.probe = nullptr,
.api = &sdl_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &simulator_module,
.internal = nullptr
.internal = nullptr,
};

View File

@ -44,8 +44,8 @@ Driver sdl_keyboard_driver = {
.compatible = (const char*[]) { "tactility,sdl-keyboard", nullptr },
.start_device = start,
.stop_device = stop,
.probe = nullptr,
.api = &sdl_keyboard_api,
.device_type = &KEYBOARD_TYPE,
.owner = &simulator_module,
.internal = nullptr
.internal = nullptr,
};

View File

@ -59,8 +59,8 @@ Driver sdl_pointer_driver = {
.compatible = (const char*[]) { "tactility,sdl-pointer", nullptr },
.start_device = start,
.stop_device = stop,
.probe = nullptr,
.api = &sdl_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &simulator_module,
.internal = nullptr
.internal = nullptr,
};

View File

@ -1,3 +1,4 @@
dependencies:
- Platforms/platform-posix
- Drivers/mock-drivers-module
dts: simulator.dts

View File

@ -1,8 +1,13 @@
/dts-v1/;
#include <tactility/bindings/root.h>
#include <bindings/mock_wifi.h>
/ {
model = "Simulator";
compatible = "root";
wifi0 {
compatible = "mock,wifi";
};
};

View File

@ -199,7 +199,6 @@ Driver unphone_nav_buttons_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &unphone_module,
.internal = nullptr
};

View File

@ -76,7 +76,6 @@ Driver unphone_power_switch_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &unphone_module,
.internal = nullptr
};

View File

@ -8,7 +8,7 @@
## Higher Priority
- esp_lvgl_port settings has a large stack size (~9kB) to fix stackoverflow when LVGL events (e.g. button click) do actions like file operations do actions like file operations. Can we reduce the callstack?
- Improve posix support: use user home path and system /tmp folder. implement uart/i2c drivers properly.
- Improve posix support: use user home path and system /tmp folder.
- NimBLE looses pairing key after reboot
- Pick different font to improve monochrome screen readability (or change the weight).
- Drivers/audio-codec-module is not a module. Move it somewhere else. Or make it an actual module.

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ads1115.h>
#include <ads1115_module.h>
#include <tactility/check.h>
#include <tactility/delay.h>
@ -131,7 +130,6 @@ Driver ads1115_driver = {
.probe = nullptr,
.api = &ADS1115_API,
.device_type = &ADC_CONTROLLER_TYPE,
.owner = &ads1115_module,
.internal = nullptr
};

View File

@ -995,7 +995,6 @@ Driver audio_stream_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_STREAM_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -137,7 +137,6 @@ static Driver mock_codec_driver = {
.stop_device = mock_stop,
.api = &MOCK_API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -356,7 +356,6 @@ Driver aw88298_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/aw9523b.h>
#include <aw9523b_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -181,7 +180,6 @@ Driver aw9523b_driver = {
.stop_device = stop,
.api = static_cast<const void*>(&aw9523b_gpio_api),
.device_type = &GPIO_CONTROLLER_TYPE,
.owner = &aw9523b_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/axp192.h>
#include <axp192_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -41,8 +40,6 @@ static constexpr TickType_t TIMEOUT = pdMS_TO_TICKS(50);
extern "C" {
extern Module axp192_module;
// region Register helpers
/** Reads a 2-byte ADC register in AXP192's packed 12-bit format: raw = (high << 4) + low. */
@ -354,7 +351,6 @@ Driver axp192_power_supply_driver = {
.stop_device = nullptr,
.api = &AXP192_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &axp192_module,
.internal = nullptr
};
@ -502,7 +498,6 @@ Driver axp192_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &axp192_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/axp192_backlight.h>
#include <axp192_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -118,7 +117,6 @@ Driver axp192_backlight_driver = {
.probe = nullptr,
.api = &AXP192_BACKLIGHT_API,
.device_type = &BACKLIGHT_TYPE,
.owner = &axp192_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/axp2101.h>
#include <axp2101_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -38,8 +37,6 @@ static constexpr TickType_t TIMEOUT = pdMS_TO_TICKS(50);
extern "C" {
extern Module axp2101_module;
// region Voltage encoding
struct Axp2101VoltRange {
@ -464,7 +461,6 @@ Driver axp2101_power_supply_driver = {
.stop_device = nullptr,
.api = &AXP2101_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &axp2101_module,
.internal = nullptr
};
@ -597,7 +593,6 @@ Driver axp2101_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &axp2101_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/axp2101_backlight.h>
#include <axp2101_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -126,7 +125,6 @@ Driver axp2101_backlight_driver = {
.probe = nullptr,
.api = &AXP2101_BACKLIGHT_API,
.device_type = &BACKLIGHT_TYPE,
.owner = &axp2101_module,
.internal = nullptr,
};

View File

@ -1,8 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/axs5106.h>
#include <axs5106_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -235,6 +233,5 @@ Driver axs5106_driver = {
.stop_device = stop,
.api = &axs5106_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &axs5106_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/bm8563.h>
#include <bm8563_module.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
#include <tactility/log.h>
@ -116,7 +115,6 @@ Driver bm8563_driver = {
.stop_device = stop,
.api = &bm8563_rtc_api,
.device_type = &RTC_TYPE,
.owner = &bm8563_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/bmi270.h>
#include <bmi270_module.h>
#include <drivers/bmi270_config_data.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
@ -234,7 +233,6 @@ Driver bmi270_driver = {
.stop_device = stop,
.api = &bmi270_imu_api,
.device_type = &IMU_TYPE,
.owner = &bmi270_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/bq24295.h>
#include <bq24295_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -27,8 +26,6 @@ static constexpr TickType_t TIMEOUT = pdMS_TO_TICKS(50);
extern "C" {
extern Module bq24295_module;
static error_t read_charge_termination(Device* device, uint8_t* out) {
auto* parent = device_get_parent(device);
auto address = GET_CONFIG(device)->address;
@ -178,7 +175,6 @@ Driver bq24295_power_supply_driver = {
.stop_device = nullptr,
.api = &BQ24295_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &bq24295_module,
.internal = nullptr
};
@ -263,7 +259,6 @@ Driver bq24295_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &bq24295_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/bq25896.h>
#include <bq25896_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -72,7 +71,6 @@ Driver bq25896_power_supply_driver = {
.stop_device = nullptr,
.api = &BQ25896_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &bq25896_module,
.internal = nullptr
};
@ -166,7 +164,6 @@ Driver bq25896_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &bq25896_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/bq27220.h>
#include <bq27220_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -118,7 +117,6 @@ Driver bq27220_power_supply_driver = {
.stop_device = nullptr,
.api = &BQ27220_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &bq27220_module,
.internal = nullptr
};
@ -205,7 +203,6 @@ Driver bq27220_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &bq27220_module,
.internal = nullptr
};

View File

@ -1,8 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/button_control.h>
#include <button_control_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
#include <tactility/drivers/gpio.h>
@ -217,6 +215,5 @@ Driver button_control_driver = {
.stop_device = stop,
.api = &button_control_api,
.device_type = &KEYBOARD_TYPE,
.owner = &button_control_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ch422g.h>
#include <ch422g_module.h>
#include <tactility/check.h>
#include <tactility/concurrent/mutex.h>
#include <tactility/device.h>
@ -156,7 +155,6 @@ Driver ch422g_driver = {
.stop_device = stop,
.api = static_cast<const void*>(&ch422g_gpio_api),
.device_type = &GPIO_CONTROLLER_TYPE,
.owner = &ch422g_module,
.internal = nullptr
};

View File

@ -1,8 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/cst328.h>
#include <cst328_module.h>
#include <tactility/check.h>
#include <tactility/delay.h>
#include <tactility/device.h>
@ -289,6 +287,5 @@ Driver cst328_driver = {
.stop_device = stop,
.api = &cst328_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &cst328_module,
.internal = nullptr
};

View File

@ -1,8 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/cst66xx.h>
#include <cst66xx_module.h>
#include <tactility/check.h>
#include <tactility/delay.h>
#include <tactility/device.h>
@ -265,6 +263,5 @@ Driver cst66xx_driver = {
.stop_device = stop,
.api = &cst66xx_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &cst66xx_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/cst816s.h>
#include <cst816s_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -229,6 +228,5 @@ Driver cst816s_driver = {
.stop_device = stop,
.api = &cst816s_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &cst816s_module,
.internal = nullptr
};

View File

@ -1,8 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/cst816t.h>
#include <cst816t_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -247,6 +245,5 @@ Driver cst816t_driver = {
.stop_device = stop,
.api = &cst816t_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &cst816t_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/drv2605.h>
#include <drv2605_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -144,7 +143,6 @@ Driver drv2605_driver = {
.stop_device = stop,
.api = &DRV2605_HAPTIC_API,
.device_type = &HAPTIC_TYPE,
.owner = &drv2605_module,
.internal = nullptr
};

View File

@ -378,7 +378,6 @@ Driver dummy_i2s_amp_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -428,7 +428,6 @@ Driver es7210_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/es7243e.h>
#include <es7243e_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -321,7 +320,6 @@ Driver es7243e_driver = {
.probe = nullptr,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = &es7243e_module,
.internal = nullptr,
};

View File

@ -393,7 +393,6 @@ Driver es8311_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -387,7 +387,6 @@ Driver es8388_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/esp_epaper.h>
#include <esp_epaper_module.h>
#include "esp_epaper_rotate.h"
#include <tactility/check.h>
@ -428,6 +427,5 @@ Driver esp_epaper_driver = {
.stop_device = stop,
.api = &esp_epaper_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &esp_epaper_module,
.internal = nullptr
};

View File

@ -456,7 +456,6 @@ Driver esp32_dac_speaker_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -3,7 +3,6 @@
#include <tactility/driver.h>
#include <tactility/log.h>
#include <tactility/module.h>
#include <esp32_led_strip_module.h>
#include <tactility/drivers/led_strip.h>
#include <tactility/drivers/gpio.h>
@ -241,8 +240,6 @@ static constexpr LedStripApi LED_STRIP_API = {
.get_length = esp32_led_strip_get_length,
};
extern Module esp32_led_strip_module;
Driver esp32_led_strip_driver = {
.name = "esp32_led_strip",
.compatible = (const char*[]) { "espressif,esp32-led-strip", nullptr },
@ -251,7 +248,6 @@ Driver esp32_led_strip_driver = {
.probe = nullptr,
.api = &LED_STRIP_API,
.device_type = &LED_STRIP_TYPE,
.owner = &esp32_led_strip_module,
.internal = nullptr,
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ft5x06.h>
#include <ft5x06_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -266,6 +265,5 @@ Driver ft5x06_driver = {
.stop_device = stop,
.api = &ft5x06_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &ft5x06_module,
.internal = nullptr
};

View File

@ -1,8 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ft6x36.h>
#include <ft6x36_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -268,6 +266,5 @@ Driver ft6x36_driver = {
.stop_device = stop,
.api = &ft6x36_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &ft6x36_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/gc0308.h>
#include <gc0308_module.h>
#include <tactility/device.h>
#include <tactility/drivers/esp32_i2c_master.h>
@ -545,7 +544,6 @@ Driver gc0308_driver = {
.stop_device = stop,
.api = &gc0308_camera_api,
.device_type = &CAMERA_TYPE,
.owner = &gc0308_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/gc9a01.h>
#include <gc9a01_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -358,6 +357,5 @@ Driver gc9a01_driver = {
.stop_device = stop,
.api = &gc9a01_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &gc9a01_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/gdeq031t10.h>
#include <gdeq031t10_module.h>
#include <tactility/check.h>
#include <tactility/delay.h>
@ -722,7 +721,6 @@ Driver gdeq031t10_driver = {
.stop_device = stop,
.api = &gdeq031t10_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &gdeq031t10_module,
.internal = nullptr
};

View File

@ -321,8 +321,6 @@ static constexpr KeyboardApi GPIO_ENCODER_API = {
.read_key = gpio_encoder_read_key,
};
extern Module gpio_encoder_module;
Driver gpio_encoder_driver = {
.name = "gpio_encoder",
.compatible = (const char*[]) { "tactility,gpio-encoder", nullptr },
@ -330,7 +328,6 @@ Driver gpio_encoder_driver = {
.stop_device = stop,
.api = &GPIO_ENCODER_API,
.device_type = &KEYBOARD_TYPE,
.owner = &gpio_encoder_module,
.internal = nullptr
};

View File

@ -167,8 +167,6 @@ static constexpr TrackballApi GPIO_TRACKBALL_API = {
.get_button_pressed = get_button_pressed,
};
extern Module gpio_trackball_module;
Driver gpio_trackball_driver = {
.name = "gpio_trackball",
.compatible = (const char*[]) { "tactility,gpio-trackball", nullptr },
@ -176,7 +174,6 @@ Driver gpio_trackball_driver = {
.stop_device = stop,
.api = &GPIO_TRACKBALL_API,
.device_type = &TRACKBALL_TYPE,
.owner = &gpio_trackball_module,
.internal = nullptr
};

View File

@ -340,6 +340,5 @@ Driver meshtastic_gps_driver = {
.stop_device = stop,
.api = &generic_gps_api,
.device_type = &GPS_TYPE,
.owner = &gps_meshtastic_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/gt911.h>
#include <gt911_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -380,6 +379,5 @@ Driver gt911_driver = {
.stop_device = stop,
.api = &gt911_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &gt911_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/hx8357.h>
#include <hx8357_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -467,6 +466,5 @@ Driver hx8357_driver = {
.stop_device = stop,
.api = &hx8357_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &hx8357_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ili9341.h>
#include <ili9341_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -457,6 +456,5 @@ Driver ili9341_driver = {
.stop_device = stop,
.api = &ili9341_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &ili9341_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ili9488.h>
#include <ili9488_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -382,6 +381,5 @@ Driver ili9488_driver = {
.stop_device = stop,
.api = &ili9488_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &ili9488_module,
.internal = nullptr
};

View File

@ -3,7 +3,6 @@
#if SOC_MIPI_DSI_SUPPORTED
#include <drivers/ili9881c.h>
#include <ili9881c_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -594,7 +593,6 @@ Driver ili9881c_driver = {
.stop_device = stop,
.api = &ili9881c_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &ili9881c_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ina226.h>
#include <ina226_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
@ -108,7 +107,6 @@ Driver ina226_power_supply_driver = {
.stop_device = nullptr,
.api = &INA226_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &ina226_module,
.internal = nullptr
};
@ -280,7 +278,6 @@ Driver ina226_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &ina226_module,
.internal = nullptr
};

View File

@ -3,7 +3,6 @@
#if SOC_MIPI_DSI_SUPPORTED
#include <drivers/jd9165.h>
#include <jd9165_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -527,7 +526,6 @@ Driver jd9165_driver = {
.stop_device = stop,
.api = &jd9165_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &jd9165_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/jd9853.h>
#include <jd9853_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -371,6 +370,5 @@ Driver jd9853_driver = {
.stop_device = stop,
.api = &jd9853_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &jd9853_module,
.internal = nullptr
};

View File

@ -87,8 +87,6 @@ static const KeyboardApi tdeck_keyboard_api = {
.read_key = tdeck_keyboard_read_key,
};
extern Module lilygo_module;
Driver tdeck_keyboard_driver = {
.name = "tdeck_keyboard",
.compatible = (const char*[]) { "lilygo,tdeck-keyboard", nullptr },
@ -96,6 +94,5 @@ Driver tdeck_keyboard_driver = {
.stop_device = stop,
.api = &tdeck_keyboard_api,
.device_type = &KEYBOARD_TYPE,
.owner = &lilygo_module,
.internal = nullptr
};

View File

@ -98,8 +98,6 @@ static const BacklightApi tdeck_keyboard_backlight_api = {
.get_max_brightness = nullptr,
};
extern struct Module lilygo_module;
Driver tdeck_keyboard_backlight_driver = {
.name = "tdeck_keyboard_backlight",
.compatible = (const char*[]) { "lilygo,tdeck-keyboard-backlight", nullptr },
@ -108,6 +106,5 @@ Driver tdeck_keyboard_backlight_driver = {
.probe = nullptr,
.api = &tdeck_keyboard_backlight_api,
.device_type = &BACKLIGHT_TYPE,
.owner = &lilygo_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/t5s3_display.h>
#include <lilygo_t5s3_epd_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -302,7 +301,6 @@ Driver t5s3_display_driver = {
.probe = nullptr,
.api = &t5s3_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &lilygo_t5s3_epd_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/lp5814.h>
#include <lp5814_module.h>
#include <tactility/check.h>
#include <tactility/delay.h>
@ -150,7 +149,6 @@ Driver lp5814_driver = {
.probe = nullptr,
.api = &LP5814_BACKLIGHT_API,
.device_type = &BACKLIGHT_TYPE,
.owner = &lp5814_module,
.internal = nullptr,
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/m5pm1.h>
#include <m5pm1_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -138,7 +137,6 @@ Driver m5pm1_power_supply_driver = {
.stop_device = nullptr,
.api = &M5PM1_POWER_SUPPLY_API,
.device_type = &POWER_SUPPLY_TYPE,
.owner = &m5pm1_module,
.internal = nullptr
};
@ -468,7 +466,6 @@ Driver m5pm1_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &m5pm1_module,
.internal = nullptr
};

View File

@ -4,7 +4,6 @@
// Drivers/TCA8418/Source/Tca8418.cpp (itself ported from
// https://github.com/adafruit/Adafruit_TCA8418, MIT licensed).
#include <drivers/cardputer_adv_keyboard.h>
#include <m5stack_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -276,6 +275,5 @@ Driver cardputer_adv_keyboard_driver = {
.stop_device = stop,
.api = &cardputer_adv_keyboard_api,
.device_type = &KEYBOARD_TYPE,
.owner = &m5stack_module,
.internal = nullptr
};

View File

@ -3,8 +3,6 @@
// https://github.com/m5stack/M5Cardputer-UserDemo/tree/main/main/hal/keyboard (MIT licensed).
#include <drivers/cardputer_keyboard.h>
#include <m5stack_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -308,6 +306,5 @@ Driver cardputer_keyboard_driver = {
.stop_device = stop,
.api = &cardputer_keyboard_api,
.device_type = &KEYBOARD_TYPE,
.owner = &m5stack_module,
.internal = nullptr
};

View File

@ -0,0 +1,11 @@
cmake_minimum_required(VERSION 3.20)
include("${CMAKE_CURRENT_LIST_DIR}/../../Buildscripts/module.cmake")
file(GLOB_RECURSE SOURCE_FILES "source/*.c*")
tactility_add_module(mock-drivers-module
SRCS ${SOURCE_FILES}
INCLUDE_DIRS include/
REQUIRES TactilityKernel
)

View File

@ -0,0 +1,195 @@
Apache License
==============
_Version 2.0, January 2004_
_&lt;<http://www.apache.org/licenses/>&gt;_
### Terms and Conditions for use, reproduction, and distribution
#### 1. Definitions
“License” shall mean the terms and conditions for use, reproduction, and
distribution as defined by Sections 1 through 9 of this document.
“Licensor” shall mean the copyright owner or entity authorized by the copyright
owner that is granting the License.
“Legal Entity” shall mean the union of the acting entity and all other entities
that control, are controlled by, or are under common control with that entity.
For the purposes of this definition, “control” means **(i)** the power, direct or
indirect, to cause the direction or management of such entity, whether by
contract or otherwise, or **(ii)** ownership of fifty percent (50%) or more of the
outstanding shares, or **(iii)** beneficial ownership of such entity.
“You” (or “Your”) shall mean an individual or Legal Entity exercising
permissions granted by this License.
“Source” form shall mean the preferred form for making modifications, including
but not limited to software source code, documentation source, and configuration
files.
“Object” form shall mean any form resulting from mechanical transformation or
translation of a Source form, including but not limited to compiled object code,
generated documentation, and conversions to other media types.
“Work” shall mean the work of authorship, whether in Source or Object form, made
available under the License, as indicated by a copyright notice that is included
in or attached to the work (an example is provided in the Appendix below).
“Derivative Works” shall mean any work, whether in Source or Object form, that
is based on (or derived from) the Work and for which the editorial revisions,
annotations, elaborations, or other modifications represent, as a whole, an
original work of authorship. For the purposes of this License, Derivative Works
shall not include works that remain separable from, or merely link (or bind by
name) to the interfaces of, the Work and Derivative Works thereof.
“Contribution” shall mean any work of authorship, including the original version
of the Work and any modifications or additions to that Work or Derivative Works
thereof, that is intentionally submitted to Licensor for inclusion in the Work
by the copyright owner or by an individual or Legal Entity authorized to submit
on behalf of the copyright owner. For the purposes of this definition,
“submitted” means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems, and
issue tracking systems that are managed by, or on behalf of, the Licensor for
the purpose of discussing and improving the Work, but excluding communication
that is conspicuously marked or otherwise designated in writing by the copyright
owner as “Not a Contribution.”
“Contributor” shall mean Licensor and any individual or Legal Entity on behalf
of whom a Contribution has been received by Licensor and subsequently
incorporated within the Work.
#### 2. Grant of Copyright License
Subject to the terms and conditions of this License, each Contributor hereby
grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free,
irrevocable copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the Work and such
Derivative Works in Source or Object form.
#### 3. Grant of Patent License
Subject to the terms and conditions of this License, each Contributor hereby
grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free,
irrevocable (except as stated in this section) patent license to make, have
made, use, offer to sell, sell, import, and otherwise transfer the Work, where
such license applies only to those patent claims licensable by such Contributor
that are necessarily infringed by their Contribution(s) alone or by combination
of their Contribution(s) with the Work to which such Contribution(s) was
submitted. If You institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work or a
Contribution incorporated within the Work constitutes direct or contributory
patent infringement, then any patent licenses granted to You under this License
for that Work shall terminate as of the date such litigation is filed.
#### 4. Redistribution
You may reproduce and distribute copies of the Work or Derivative Works thereof
in any medium, with or without modifications, and in Source or Object form,
provided that You meet the following conditions:
* **(a)** You must give any other recipients of the Work or Derivative Works a copy of
this License; and
* **(b)** You must cause any modified files to carry prominent notices stating that You
changed the files; and
* **(c)** You must retain, in the Source form of any Derivative Works that You distribute,
all copyright, patent, trademark, and attribution notices from the Source form
of the Work, excluding those notices that do not pertain to any part of the
Derivative Works; and
* **(d)** If the Work includes a “NOTICE” text file as part of its distribution, then any
Derivative Works that You distribute must include a readable copy of the
attribution notices contained within such NOTICE file, excluding those notices
that do not pertain to any part of the Derivative Works, in at least one of the
following places: within a NOTICE text file distributed as part of the
Derivative Works; within the Source form or documentation, if provided along
with the Derivative Works; or, within a display generated by the Derivative
Works, if and wherever such third-party notices normally appear. The contents of
the NOTICE file are for informational purposes only and do not modify the
License. You may add Your own attribution notices within Derivative Works that
You distribute, alongside or as an addendum to the NOTICE text from the Work,
provided that such additional attribution notices cannot be construed as
modifying the License.
You may add Your own copyright statement to Your modifications and may provide
additional or different license terms and conditions for use, reproduction, or
distribution of Your modifications, or for any such Derivative Works as a whole,
provided Your use, reproduction, and distribution of the Work otherwise complies
with the conditions stated in this License.
#### 5. Submission of Contributions
Unless You explicitly state otherwise, any Contribution intentionally submitted
for inclusion in the Work by You to the Licensor shall be under the terms and
conditions of this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify the terms of
any separate license agreement you may have executed with Licensor regarding
such Contributions.
#### 6. Trademarks
This License does not grant permission to use the trade names, trademarks,
service marks, or product names of the Licensor, except as required for
reasonable and customary use in describing the origin of the Work and
reproducing the content of the NOTICE file.
#### 7. Disclaimer of Warranty
Unless required by applicable law or agreed to in writing, Licensor provides the
Work (and each Contributor provides its Contributions) on an “AS IS” BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied,
including, without limitation, any warranties or conditions of TITLE,
NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are
solely responsible for determining the appropriateness of using or
redistributing the Work and assume any risks associated with Your exercise of
permissions under this License.
#### 8. Limitation of Liability
In no event and under no legal theory, whether in tort (including negligence),
contract, or otherwise, unless required by applicable law (such as deliberate
and grossly negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special, incidental,
or consequential damages of any character arising as a result of this License or
out of the use or inability to use the Work (including but not limited to
damages for loss of goodwill, work stoppage, computer failure or malfunction, or
any and all other commercial damages or losses), even if such Contributor has
been advised of the possibility of such damages.
#### 9. Accepting Warranty or Additional Liability
While redistributing the Work or Derivative Works thereof, You may choose to
offer, and charge a fee for, acceptance of support, warranty, indemnity, or
other liability obligations and/or rights consistent with this License. However,
in accepting such obligations, You may act only on Your own behalf and on Your
sole responsibility, not on behalf of any other Contributor, and only if You
agree to indemnify, defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason of your
accepting any such warranty or additional liability.
_END OF TERMS AND CONDITIONS_
### APPENDIX: How to apply the Apache License to your work
To apply the Apache License to your work, attach the following boilerplate
notice, with the fields enclosed by brackets `[]` replaced with your own
identifying information. (Don't include the brackets!) The text should be
enclosed in the appropriate comment syntax for the file format. We also
recommend that a file or class name and description of purpose be included on
the same “printed page” as the copyright notice for easier identification within
third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

View File

@ -0,0 +1,8 @@
description: Mock WiFi driver with a fixed list of access points
compatible: "mock,wifi"
properties:
_unused:
type: int
default: 0

View File

@ -0,0 +1,7 @@
// SPDX-License-Identifier: Apache-2.0
#pragma once
#include <tactility/bindings/bindings.h>
#include <mock/mock_wifi.h>
DEFINE_DEVICETREE(wifi, struct MockWifiConfig)

View File

@ -0,0 +1,14 @@
// SPDX-License-Identifier: Apache-2.0
#pragma once
#ifdef __cplusplus
extern "C" {
#endif
struct MockWifiConfig {
int _unused;
};
#ifdef __cplusplus
}
#endif

View File

@ -0,0 +1,14 @@
// SPDX-License-Identifier: Apache-2.0
#pragma once
#include <tactility/module.h>
#ifdef __cplusplus
extern "C" {
#endif
extern struct Module mock_drivers_module;
#ifdef __cplusplus
}
#endif

View File

@ -0,0 +1,3 @@
dependencies:
- TactilityKernel
bindings: bindings

View File

@ -38,7 +38,7 @@ constexpr size_t MOCK_SCAN_RESULT_COUNT = sizeof(MOCK_SCAN_RESULTS) / sizeof(MOC
constexpr int8_t MOCK_CONNECTED_RSSI = -30;
constexpr const char* MOCK_IPV4_ADDRESS = "192.168.1.2";
struct PosixWifiCtx {
struct MockWifiCtx {
Device* device = nullptr;
Mutex mutex {};
@ -51,9 +51,9 @@ struct PosixWifiCtx {
WifiEventSubscription* subscriptions = nullptr;
};
#define GET_CTX(device) (static_cast<PosixWifiCtx*>(device_get_driver_data(device)))
#define GET_CTX(device) (static_cast<MockWifiCtx*>(device_get_driver_data(device)))
void fireEvent(PosixWifiCtx* ctx, WifiEvent event) {
void fireEvent(MockWifiCtx* ctx, WifiEvent event) {
mutex_lock(&ctx->subscriptionsMutex);
for (WifiEventSubscription* sub = ctx->subscriptions; sub != nullptr; sub = sub->internal.next) {
mutex_lock(&sub->internal.ring_mutex);
@ -339,7 +339,7 @@ error_t apiEventUnsubscribe(Device* device, WifiEventSubscription* sub) {
return result;
}
const WifiApi posix_wifi_api = {
const WifiApi mock_wifi_api = {
.set_radio_on = apiSetRadioOn,
.set_radio_off = apiSetRadioOff,
.get_radio_state = apiGetRadioState,
@ -363,7 +363,7 @@ const WifiApi posix_wifi_api = {
// itself is only touched by apiSetRadioOn()/apiSetRadioOff().
error_t startDevice(Device* device) {
auto* ctx = new(std::nothrow) PosixWifiCtx();
auto* ctx = new(std::nothrow) MockWifiCtx();
if (ctx == nullptr) return ERROR_OUT_OF_MEMORY;
ctx->device = device;
@ -411,16 +411,13 @@ error_t stopDevice(Device* device) {
extern "C" {
extern Module platform_posix_module;
Driver posix_wifi_driver = {
Driver mock_wifi_driver = {
.name = "mock_wifi",
.compatible = (const char*[]) { "posix,mock-wifi", nullptr },
.compatible = (const char*[]) { "mock,wifi", nullptr },
.start_device = startDevice,
.stop_device = stopDevice,
.api = (const void*)&posix_wifi_api,
.api = (const void*)&mock_wifi_api,
.device_type = &WIFI_TYPE,
.owner = &platform_posix_module,
.internal = nullptr
};

View File

@ -0,0 +1,23 @@
// SPDX-License-Identifier: Apache-2.0
#include <tactility/driver.h>
#include <tactility/module.h>
extern "C" {
extern Driver mock_wifi_driver;
static Driver* const mock_drivers[] = {
&mock_wifi_driver,
nullptr
};
Module mock_drivers_module = {
.name = "mock-drivers",
.start = nullptr,
.stop = nullptr,
.drivers = mock_drivers,
.symbols = nullptr,
.internal = nullptr
};
}

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/mpu6886.h>
#include <mpu6886_module.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
#include <tactility/log.h>
@ -207,7 +206,6 @@ Driver mpu6886_driver = {
.stop_device = stop,
.api = &mpu6886_imu_api,
.device_type = &IMU_TYPE,
.owner = &mpu6886_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/nv3031b.h>
#include <nv3031b_module.h>
#include <tactility/check.h>
#include <tactility/delay.h>
@ -374,6 +373,5 @@ Driver nv3031b_driver = {
.probe = nullptr,
.api = &nv3031b_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &nv3031b_module,
.internal = nullptr
};

View File

@ -330,7 +330,6 @@ Driver pdm_mic_driver = {
.stop_device = stop_device,
.api = &API,
.device_type = &AUDIO_CODEC_TYPE,
.owner = nullptr,
.internal = nullptr,
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/pi4ioe5v6408.h>
#include <pi4ioe5v6408_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
#include <tactility/drivers/gpio_controller.h>
@ -210,7 +209,6 @@ Driver pi4ioe5v6408_driver = {
.stop_device = stop,
.api = static_cast<const void*>(&pi4_gpio_api),
.device_type = &GPIO_CONTROLLER_TYPE,
.owner = &pi4ioe5v6408_module,
.internal = nullptr
};

View File

@ -1,7 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Reference: https://github.com/m5stack/StackChan/tree/main/firmware/main/hal/drivers/PY32IOExpander_Class
#include <drivers/py32ioexpander.h>
#include <py32ioexpander_module.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
#include <tactility/log.h>
@ -147,7 +146,6 @@ Driver py32ioexpander_driver = {
.stop_device = stop,
.api = nullptr,
.device_type = nullptr,
.owner = &py32ioexpander_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/qmi8658.h>
#include <qmi8658_module.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
#include <tactility/log.h>
@ -175,7 +174,6 @@ Driver qmi8658_driver = {
.stop_device = stop,
.api = &qmi8658_imu_api,
.device_type = &IMU_TYPE,
.owner = &qmi8658_module,
.internal = nullptr
};

View File

@ -3,7 +3,6 @@
#if SOC_LCD_RGB_SUPPORTED
#include <drivers/rgb_display.h>
#include <rgb_display_module.h>
#include <drivers/software_pixel_mapper.h>
#include <tactility/delay.h>
@ -508,7 +507,6 @@ Driver rgb_display_driver = {
.stop_device = stop,
.api = &rgb_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &rgb_display_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/rx8130ce.h>
#include <rx8130ce_module.h>
#include <tactility/device.h>
#include <tactility/drivers/i2c_controller.h>
#include <tactility/log.h>
@ -163,7 +162,6 @@ Driver rx8130ce_driver = {
.stop_device = stop,
.api = &rx8130ce_rtc_api,
.device_type = &RTC_TYPE,
.owner = &rx8130ce_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/sc2356.h>
#include <sc2356_module.h>
#include <tactility/device.h>
#include <tactility/drivers/esp32_i2c_master.h>
@ -596,7 +595,6 @@ Driver sc2356_driver = {
.stop_device = stop,
.api = &sc2356_camera_api,
.device_type = &CAMERA_TYPE,
.owner = &sc2356_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/ssd1306.h>
#include <ssd1306_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -346,6 +345,5 @@ Driver ssd1306_driver = {
.stop_device = stop,
.api = &ssd1306_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &ssd1306_module,
.internal = nullptr
};

View File

@ -3,7 +3,6 @@
#if SOC_MIPI_DSI_SUPPORTED
#include <drivers/st7121.h>
#include <st7121_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -593,7 +592,6 @@ Driver st7121_driver = {
.stop_device = stop,
.api = &st7121_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7121_module,
.internal = nullptr
};

View File

@ -3,7 +3,6 @@
#if SOC_MIPI_DSI_SUPPORTED
#include <drivers/st7123.h>
#include <st7123_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -593,7 +592,6 @@ Driver st7123_driver = {
.stop_device = stop,
.api = &st7123_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7123_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7123_touch.h>
#include <st7123_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -201,6 +200,5 @@ Driver st7123_touch_driver = {
.stop_device = stop,
.api = &st7123_touch_pointer_api,
.device_type = &POINTER_TYPE,
.owner = &st7123_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7305.h>
#include <st7305_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -416,6 +415,5 @@ Driver st7305_driver = {
.stop_device = stop,
.api = &st7305_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7305_module,
.internal = nullptr
};

View File

@ -3,7 +3,6 @@
#if SOC_LCD_RGB_SUPPORTED
#include <drivers/st7701.h>
#include <st7701_module.h>
#include <tactility/device.h>
#include <tactility/driver.h>
@ -553,7 +552,6 @@ Driver st7701_driver = {
.stop_device = stop,
.api = &st7701_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7701_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7735.h>
#include <st7735_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -384,6 +383,5 @@ Driver st7735_driver = {
.stop_device = stop,
.api = &st7735_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7735_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7789_i8080.h>
#include <st7789_i8080_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -373,6 +372,5 @@ Driver st7789_i8080_driver = {
.stop_device = stop,
.api = &st7789_i8080_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7789_i8080_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7789.h>
#include <st7789_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -384,6 +383,5 @@ Driver st7789_driver = {
.stop_device = stop,
.api = &st7789_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7789_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7789_soft_i8080.h>
#include <st7789_soft_i8080_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -429,6 +428,5 @@ Driver st7789_soft_i8080_driver = {
.probe = nullptr,
.api = &st7789_soft_i8080_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7789_soft_i8080_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7796_i8080.h>
#include <st7796_i8080_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -328,6 +327,5 @@ Driver st7796_i8080_driver = {
.stop_device = stop,
.api = &st7796_i8080_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7796_i8080_module,
.internal = nullptr
};

View File

@ -1,6 +1,5 @@
// SPDX-License-Identifier: Apache-2.0
#include <drivers/st7796.h>
#include <st7796_module.h>
#include <tactility/check.h>
#include <tactility/device.h>
@ -384,6 +383,5 @@ Driver st7796_driver = {
.stop_device = stop,
.api = &st7796_display_api,
.device_type = &DISPLAY_TYPE,
.owner = &st7796_module,
.internal = nullptr
};

View File

@ -326,8 +326,6 @@ static const struct LoraApi sx1262_lora_api = {
// endregion
extern Module sx126x_module;
Driver sx1262_driver = {
.name = "sx1262",
.compatible = (const char*[]) { "semtech,sx1262", nullptr },
@ -335,7 +333,6 @@ Driver sx1262_driver = {
.stop_device = stop,
.api = &sx1262_lora_api,
.device_type = &LORA_TYPE,
.owner = &sx126x_module,
.internal = nullptr
};

Some files were not shown because too many files have changed in this diff Show More