mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-19 03:13:14 +00:00
10 lines
330 B
C
10 lines
330 B
C
#include "nb_touch.h"
|
|
#include <esp_check.h>
|
|
|
|
nb_touch_t _Nonnull* nb_touch_create(nb_touch_driver_t _Nonnull* driver) {
|
|
nb_touch_t _Nonnull* touch = malloc(sizeof(nb_touch_t));
|
|
assert(driver->init_io(&(touch->io_handle)) == ESP_OK);
|
|
driver->create_touch(touch->io_handle, &(touch->touch_handle));
|
|
return touch;
|
|
}
|