ESPHome
2022.8.0
esphome
esphome
components
lilygo_t5_47
touchscreen
lilygo_t5_47_touchscreen.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
esphome/components/i2c/i2c.h
"
4
#include "
esphome/components/touchscreen/touchscreen.h
"
5
#include "
esphome/core/automation.h
"
6
#include "
esphome/core/component.h
"
7
#include "
esphome/core/hal.h
"
8
9
namespace
esphome
{
10
namespace
lilygo_t5_47 {
11
12
struct
Store
{
13
volatile
bool
touch
;
14
ISRInternalGPIOPin
pin
;
15
16
static
void
gpio_intr
(
Store
*store);
17
};
18
19
using namespace
touchscreen;
20
21
class
LilygoT547Touchscreen
:
public
Touchscreen
,
public
Component
,
public
i2c::I2CDevice
{
22
public
:
23
void
setup
()
override
;
24
void
loop
()
override
;
25
void
dump_config()
override
;
26
27
void
set_interrupt_pin
(
InternalGPIOPin
*
pin
) { this->interrupt_pin_ =
pin
; }
28
29
protected
:
30
InternalGPIOPin
*
interrupt_pin_
;
31
Store
store_
;
32
};
33
34
}
// namespace lilygo_t5_47
35
}
// namespace esphome
setup
void setup()
esphome::lilygo_t5_47::LilygoT547Touchscreen::set_interrupt_pin
void set_interrupt_pin(InternalGPIOPin *pin)
Definition:
lilygo_t5_47_touchscreen.h:27
esphome::InternalGPIOPin
Definition:
gpio.h:79
loop
void loop()
esphome::ISRInternalGPIOPin
Copy of GPIOPin that is safe to use from ISRs (with no virtual functions)
Definition:
gpio.h:66
automation.h
hal.h
esphome::lilygo_t5_47::Store::touch
volatile bool touch
Definition:
lilygo_t5_47_touchscreen.h:13
touchscreen.h
esphome::Component
Definition:
component.h:66
esphome::lilygo_t5_47::LilygoT547Touchscreen::store_
Store store_
Definition:
lilygo_t5_47_touchscreen.h:31
esphome::lilygo_t5_47::Store::pin
ISRInternalGPIOPin pin
Definition:
lilygo_t5_47_touchscreen.h:14
esphome::lilygo_t5_47::Store
Definition:
lilygo_t5_47_touchscreen.h:12
esphome::lilygo_t5_47::LilygoT547Touchscreen::interrupt_pin_
InternalGPIOPin * interrupt_pin_
Definition:
lilygo_t5_47_touchscreen.h:30
esphome::lilygo_t5_47::LilygoT547Touchscreen
Definition:
lilygo_t5_47_touchscreen.h:21
esphome::lilygo_t5_47::Store::gpio_intr
static void gpio_intr(Store *store)
Definition:
lilygo_t5_47_touchscreen.cpp:26
esphome
Definition:
a4988.cpp:4
component.h
esphome::i2c::I2CDevice
Definition:
i2c.h:39
esphome::touchscreen::Touchscreen
Definition:
touchscreen.h:32
i2c.h
Generated by
1.8.13