diff options
author | Uros Majstorovic <majstor@majstor.org> | 2022-05-13 12:26:19 +0200 |
---|---|---|
committer | Uros Majstorovic <majstor@majstor.org> | 2022-05-13 12:26:19 +0200 |
commit | 9ccb4db8d59ec9dab33ee8617d462f21a8bb4fa8 (patch) | |
tree | a4f8ba9375a4ee82bae6ddc0cb3a35227f6f9469 /fw/fe310/eos/eve/eve_touch.h | |
parent | 45f0d9b890b086493f9bb06428c46cd802324223 (diff) |
touch controller/eve fixes
Diffstat (limited to 'fw/fe310/eos/eve/eve_touch.h')
-rw-r--r-- | fw/fe310/eos/eve/eve_touch.h | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/fw/fe310/eos/eve/eve_touch.h b/fw/fe310/eos/eve/eve_touch.h index b10fde2..e3e92b0 100644 --- a/fw/fe310/eos/eve/eve_touch.h +++ b/fw/fe310/eos/eve/eve_touch.h @@ -5,7 +5,6 @@ #define EVE_TOUCH_THRESHOLD_X 5 #define EVE_TOUCH_THRESHOLD_Y 5 -#define EVE_TOUCH_TRAVG 3 #define EVE_NOTAG 0 #define EVE_NOTOUCH 0x80008000 @@ -77,7 +76,7 @@ typedef struct EVETouch { int vy; int x0; int y0; - uint64_t t; + uint32_t t; uint16_t eevt; uint8_t tag0; uint8_t tag; @@ -98,15 +97,12 @@ typedef struct EVETouchTimer { typedef void (*eve_touch_handler_t) (EVETouch *, uint16_t, uint8_t, void *); +void eve_touch_init(void); void eve_handle_touch(uint16_t intr_flags); void eve_handle_time(void); -void eve_touch_init(int touch_calibrate, uint32_t *touch_matrix); -void eve_touch_start(void); -void eve_touch_stop(void); - void eve_touch_set_handler(eve_touch_handler_t handler, void *handler_param); -EVETouch *eve_touch_get(int i); +EVETouch *eve_touch_get_obj(int i); int8_t eve_touch_get_idx(EVETouch *touch); uint16_t eve_touch_evt(EVETouch *touch, uint16_t evt, uint8_t tag0, uint8_t tag_min, uint8_t tag_n); @@ -114,11 +110,12 @@ void eve_touch_set_opt(uint8_t tag, uint8_t opt); uint8_t eve_touch_get_opt(uint8_t tag); void eve_touch_clear_opt(void); -void eve_touch_timer_set(EVETouch *touch, uint16_t evt, uint8_t tag0, uint32_t to); -void eve_touch_timer_clear(EVETouch *touch); -uint16_t eve_touch_timer_get_evt(EVETouch *touch); -void eve_touch_timer_set_evt(EVETouch *touch, uint16_t evt); -void eve_touch_timer_start(uint8_t tag0, uint32_t to); -void eve_touch_timer_stop(void); +void eve_timer_set(EVETouch *touch, uint16_t evt, uint8_t tag0, uint32_t to); +void eve_timer_clear(EVETouch *touch); +void eve_timer_set_evt(EVETouch *touch, uint16_t evt); +uint16_t eve_timer_get_evt(EVETouch *touch); +EVETouchTimer *eve_timer_get_obj(void); -EVETouchTimer *eve_touch_timer_get(void); +void eve_timer_start(uint8_t tag0, uint32_t to); +void eve_timer_stop(void); +void eve_touch_clear_tag0(void); |