From 297779385fd53e93c33861e2d3107cb88efbde81 Mon Sep 17 00:00:00 2001 From: Drashna Jaelre Date: Thu, 30 Mar 2023 18:27:39 -0700 Subject: Add last activity functions for pointing device (#20079) --- quantum/split_common/transactions.c | 7 ++++--- quantum/split_common/transport.h | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'quantum/split_common') diff --git a/quantum/split_common/transactions.c b/quantum/split_common/transactions.c index ec34bbba60..0ae91ba363 100644 --- a/quantum/split_common/transactions.c +++ b/quantum/split_common/transactions.c @@ -795,13 +795,14 @@ static void haptic_handlers_slave(matrix_row_t master_matrix[], matrix_row_t sla static bool activity_handlers_master(matrix_row_t master_matrix[], matrix_row_t slave_matrix[]) { static uint32_t last_update = 0; split_slave_activity_sync_t activity_sync; - activity_sync.matrix_timestamp = last_matrix_activity_time(); - activity_sync.encoder_timestamp = last_encoder_activity_time(); + activity_sync.matrix_timestamp = last_matrix_activity_time(); + activity_sync.encoder_timestamp = last_encoder_activity_time(); + activity_sync.pointing_device_timestamp = last_pointing_device_activity_time(); return send_if_data_mismatch(PUT_ACTIVITY, &last_update, &activity_sync, &split_shmem->activity_sync, sizeof(activity_sync)); } static void activity_handlers_slave(matrix_row_t master_matrix[], matrix_row_t slave_matrix[]) { - set_activity_timestamps(split_shmem->activity_sync.matrix_timestamp, split_shmem->activity_sync.encoder_timestamp); + set_activity_timestamps(split_shmem->activity_sync.matrix_timestamp, split_shmem->activity_sync.encoder_timestamp, split_shmem->activity_sync.pointing_device_timestamp); } // clang-format off diff --git a/quantum/split_common/transport.h b/quantum/split_common/transport.h index 8f8c38461e..13b1e56814 100644 --- a/quantum/split_common/transport.h +++ b/quantum/split_common/transport.h @@ -127,6 +127,7 @@ typedef struct _split_slave_haptic_sync_t { typedef struct _split_slave_activity_sync_t { uint32_t matrix_timestamp; uint32_t encoder_timestamp; + uint32_t pointing_device_timestamp; } split_slave_activity_sync_t; #endif // defined(SPLIT_ACTIVITY_ENABLE) -- cgit v1.2.3