diff options
Diffstat (limited to 'bootloader')
-rwxr-xr-x | bootloader/mrobe500.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/bootloader/mrobe500.c b/bootloader/mrobe500.c index ee46eb8eb4..c71d43d40e 100755 --- a/bootloader/mrobe500.c +++ b/bootloader/mrobe500.c | |||
@@ -54,13 +54,13 @@ extern int line; | |||
54 | #if 0 | 54 | #if 0 |
55 | struct touch_calibration_point tl, br; | 55 | struct touch_calibration_point tl, br; |
56 | 56 | ||
57 | void touchpad_get_one_point(struct touch_calibration_point *p) | 57 | void touchscreen_get_one_point(struct touch_calibration_point *p) |
58 | { | 58 | { |
59 | int data = 0; | 59 | int data = 0; |
60 | int start = current_tick; | 60 | int start = current_tick; |
61 | while (TIME_AFTER(start+(HZ/3), current_tick)) | 61 | while (TIME_AFTER(start+(HZ/3), current_tick)) |
62 | { | 62 | { |
63 | if (button_read_device()&BUTTON_TOUCHPAD) | 63 | if (button_read_device()&BUTTON_TOUCHSCREEN) |
64 | { | 64 | { |
65 | data = button_get_last_touch(); | 65 | data = button_get_last_touch(); |
66 | p->val_x = data>>16; | 66 | p->val_x = data>>16; |
@@ -74,7 +74,7 @@ void touchpad_get_one_point(struct touch_calibration_point *p) | |||
74 | 74 | ||
75 | #define MARGIN 25 | 75 | #define MARGIN 25 |
76 | #define LEN 7 | 76 | #define LEN 7 |
77 | void touchpad_calibrate_screen(void) | 77 | void touchscreen_calibrate_screen(void) |
78 | { | 78 | { |
79 | reset_screen(); | 79 | reset_screen(); |
80 | printf("touch the center of the crosshairs to calibrate"); | 80 | printf("touch the center of the crosshairs to calibrate"); |
@@ -83,7 +83,7 @@ void touchpad_calibrate_screen(void) | |||
83 | lcd_vline(MARGIN, MARGIN-LEN, MARGIN+LEN); | 83 | lcd_vline(MARGIN, MARGIN-LEN, MARGIN+LEN); |
84 | lcd_update(); | 84 | lcd_update(); |
85 | tl.px_x = MARGIN; tl.px_y = MARGIN; | 85 | tl.px_x = MARGIN; tl.px_y = MARGIN; |
86 | touchpad_get_one_point(&tl); | 86 | touchscreen_get_one_point(&tl); |
87 | reset_screen(); | 87 | reset_screen(); |
88 | printf("touch the center of the crosshairs to calibrate"); | 88 | printf("touch the center of the crosshairs to calibrate"); |
89 | /* get the topright value */ | 89 | /* get the topright value */ |
@@ -91,7 +91,7 @@ void touchpad_calibrate_screen(void) | |||
91 | lcd_vline(LCD_WIDTH-MARGIN, LCD_HEIGHT-MARGIN-LEN, LCD_HEIGHT-MARGIN+LEN); | 91 | lcd_vline(LCD_WIDTH-MARGIN, LCD_HEIGHT-MARGIN-LEN, LCD_HEIGHT-MARGIN+LEN); |
92 | lcd_update(); | 92 | lcd_update(); |
93 | br.px_x = LCD_WIDTH-MARGIN; br.px_y = LCD_HEIGHT-MARGIN; | 93 | br.px_x = LCD_WIDTH-MARGIN; br.px_y = LCD_HEIGHT-MARGIN; |
94 | touchpad_get_one_point(&br); | 94 | touchscreen_get_one_point(&br); |
95 | reset_screen(); | 95 | reset_screen(); |
96 | line++; | 96 | line++; |
97 | printf("tl %d %d", tl.val_x, tl.val_y); | 97 | printf("tl %d %d", tl.val_x, tl.val_y); |
@@ -108,7 +108,7 @@ void mrdebug(void) | |||
108 | int button=0; | 108 | int button=0; |
109 | #if 0 | 109 | #if 0 |
110 | use_calibration(false); | 110 | use_calibration(false); |
111 | touchpad_calibrate_screen(); | 111 | touchscreen_calibrate_screen(); |
112 | use_calibration(true); | 112 | use_calibration(true); |
113 | #endif | 113 | #endif |
114 | 114 | ||
@@ -148,15 +148,15 @@ void mrdebug(void) | |||
148 | else if (button == BUTTON_RC_HEART) | 148 | else if (button == BUTTON_RC_HEART) |
149 | { | 149 | { |
150 | printf("POINT"); | 150 | printf("POINT"); |
151 | touchpad_set_mode(TOUCHPAD_POINT); | 151 | touchscreen_set_mode(TOUCHSCREEN_POINT); |
152 | } | 152 | } |
153 | else if (button == BUTTON_RC_MODE) | 153 | else if (button == BUTTON_RC_MODE) |
154 | { | 154 | { |
155 | printf("BUTTON"); | 155 | printf("BUTTON"); |
156 | touchpad_set_mode(TOUCHPAD_BUTTON); | 156 | touchscreen_set_mode(TOUCHSCREEN_BUTTON); |
157 | } | 157 | } |
158 | #if 1 | 158 | #if 1 |
159 | else if (button&BUTTON_TOUCHPAD) | 159 | else if (button&BUTTON_TOUCHSCREEN) |
160 | { | 160 | { |
161 | if (button&BUTTON_REL) | 161 | if (button&BUTTON_REL) |
162 | continue; | 162 | continue; |