-
-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Define Panels with multiple Touch input device #585
Comments
hi, do you mean a second touch controller (if so, please specify the geometry) or just a single touch controller running from a different driver ? |
sorry, my english isn't good. I mean one tft driver definition only and for the touch controller another one. that is... an example Driver ILI9488 only definition of panel (SPI , Parallel ... etc..)
The goal is define the TFT panel with one include and the input part (touch, etc,..) in other because there are many types of them |
if you wish to support multiple touch devices in your project, but only need to enable one of them (no concurrency), then you can try this: #define USE_XPT2046 true
#define USE_FT5x06 false
class LGFX : public lgfx::LGFX_Device
{
lgfx::Bus_SPI _bus_instance;
lgfx::Panel_ILI9499 _panel_instance;
lgfx::Touch_FT5x06 _touch_instance_FT5x06;
lgfx::Touch_XPT2046 _touch_instance_XPT2046;
public:
LGFX(void)
{
// (... ) bus and panel config block
// (...) FT6236 config block without _panel_instance.setTouch()
// (...) XPT2046 config block without _panel_instance.setTouch()
if( USE_XPT2046 )
_panel_instance.setTouch(&_touch_instance_XPT2046 );
else if( USE_FT5x06 )
_panel_instance.setTouch(&_touch_instance_FT5x06);
setPanel(&_panel_instance);
}
}; |
Thank you! |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically closed because it has not had recent activity. Thank you for your contributions. |
Hi!
I've a question. (Maybe I don't know how to do it)
It's possible to define panels (TFT) with different touch input devices?
This is. I need to define TFT but I need to define the touch controller separately.
Thank you
The text was updated successfully, but these errors were encountered: