mirror of
https://github.com/apache/nuttx-apps.git
synced 2026-08-01 20:29:00 +00:00
lvgldemo: allow to customize input dev path
Default to /dev/input0, now it's configurable. Signed-off-by: Neo Xu <neo.xu1990@gmail.com>
This commit is contained in:
parent
b4c2e6bf46
commit
c4b6fd77be
2 changed files with 11 additions and 0 deletions
|
|
@ -20,4 +20,11 @@ config EXAMPLES_LVGLDEMO_STACKSIZE
|
|||
int "lvgldemo stack size"
|
||||
default 16384
|
||||
|
||||
config EXAMPLES_LVGLDEMO_INPUT_DEVPATH
|
||||
string "Touchscreen device path"
|
||||
default "/dev/input0"
|
||||
depends on INPUT_TOUCHSCREEN
|
||||
---help---
|
||||
The path to the touchscreen device. Default: "/dev/input0"
|
||||
|
||||
endif # EXAMPLES_LVGLDEMO
|
||||
|
|
|
|||
|
|
@ -129,6 +129,10 @@ int main(int argc, FAR char *argv[])
|
|||
info.fb_path = "/dev/lcd0";
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_INPUT_TOUCHSCREEN
|
||||
info.input_path = CONFIG_EXAMPLES_LVGLDEMO_INPUT_DEVPATH;
|
||||
#endif
|
||||
|
||||
lv_nuttx_init(&info, &result);
|
||||
|
||||
if (result.disp == NULL)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue