-
-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* NCS v2.5.0 * no partition for non ZS hardware * partition for dk * PR feedback * here we go * fix partitions * Use NCS Partition manager to put settings in external flash. * lvgl patch ad NCS 2.5 does not include a patch for touch input which causes accidental presses. --------- Co-authored-by: Jakob Krantz <[email protected]>
- Loading branch information
Showing
11 changed files
with
79 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,5 +10,8 @@ build* | |
/tools | ||
/zephyr | ||
__pycache__ | ||
/nrf | ||
/nrfxlib | ||
/test | ||
|
||
/.vscode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#------------------- | ||
# External partition | ||
# ------------------ | ||
lvgl_lfs_partition: | ||
address: 0x0 | ||
region: external_flash | ||
size: 0x200000 | ||
lvgl_raw_partition: | ||
address: 0x200000 | ||
region: external_flash | ||
size: 0x200000 | ||
settings_partition: | ||
address: 0x400000 | ||
region: external_flash | ||
size: 0x100000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
diff --git a/modules/lvgl/input/lvgl_common_input.c b/modules/lvgl/input/lvgl_common_input.c | ||
index 23b61a230e..9e2cfb5019 100644 | ||
--- a/modules/lvgl/input/lvgl_common_input.c | ||
+++ b/modules/lvgl/input/lvgl_common_input.c | ||
@@ -15,7 +15,18 @@ static void lvgl_input_read_cb(lv_indev_drv_t *drv, lv_indev_data_t *data) | ||
{ | ||
const struct device *dev = drv->user_data; | ||
const struct lvgl_common_input_config *cfg = dev->config; | ||
+ struct lvgl_common_input_data *common_data = dev->data; | ||
+ | ||
+ if (k_msgq_get(cfg->event_msgq, data, K_NO_WAIT) != 0) { | ||
+ memcpy(data, &common_data->previous_event, sizeof(lv_indev_data_t)); | ||
+ if (drv->type == LV_INDEV_TYPE_ENCODER) { | ||
+ data->enc_diff = 0; /* For encoders, clear last movement */ | ||
+ } | ||
+ data->continue_reading = false; | ||
+ return; | ||
+ } | ||
|
||
+ memcpy(&common_data->previous_event, data, sizeof(lv_indev_data_t)); | ||
k_msgq_get(cfg->event_msgq, data, K_NO_WAIT); | ||
data->continue_reading = k_msgq_num_used_get(cfg->event_msgq) > 0; | ||
} | ||
diff --git a/modules/lvgl/input/lvgl_common_input.h b/modules/lvgl/input/lvgl_common_input.h | ||
index e9d0ef34f8..2c1b2bd9a5 100644 | ||
--- a/modules/lvgl/input/lvgl_common_input.h | ||
+++ b/modules/lvgl/input/lvgl_common_input.h | ||
@@ -23,6 +23,7 @@ struct lvgl_common_input_data { | ||
lv_indev_drv_t indev_drv; | ||
lv_indev_t *indev; | ||
lv_indev_data_t pending_event; | ||
+ lv_indev_data_t previous_event; | ||
}; | ||
|
||
int lvgl_input_register_driver(lv_indev_type_t indev_type, const struct device *dev); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.