summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--firmware/drivers/button.c9
-rw-r--r--firmware/target/arm/iriver/h10/lcd-h10_20gb.c4
2 files changed, 12 insertions, 1 deletions
diff --git a/firmware/drivers/button.c b/firmware/drivers/button.c
index 6536a34037..5add6cb817 100644
--- a/firmware/drivers/button.c
+++ b/firmware/drivers/button.c
@@ -704,6 +704,9 @@ static int button_flip(int button)
704#if defined(BUTTON_UP) && defined(BUTTON_DOWN) 704#if defined(BUTTON_UP) && defined(BUTTON_DOWN)
705 | BUTTON_UP | BUTTON_DOWN 705 | BUTTON_UP | BUTTON_DOWN
706#endif 706#endif
707#if defined(BUTTON_SCROLL_UP) && defined(BUTTON_SCROLL_DOWN)
708 | BUTTON_SCROLL_UP | BUTTON_SCROLL_DOWN
709#endif
707#if CONFIG_KEYPAD == RECORDER_PAD 710#if CONFIG_KEYPAD == RECORDER_PAD
708 | BUTTON_F1 | BUTTON_F3 711 | BUTTON_F1 | BUTTON_F3
709#endif 712#endif
@@ -719,6 +722,12 @@ static int button_flip(int button)
719 if (button & BUTTON_DOWN) 722 if (button & BUTTON_DOWN)
720 newbutton |= BUTTON_UP; 723 newbutton |= BUTTON_UP;
721#endif 724#endif
725#if defined(BUTTON_SCROLL_UP) && defined(BUTTON_SCROLL_DOWN)
726 if (button & BUTTON_SCROLL_UP)
727 newbutton |= BUTTON_SCROLL_DOWN;
728 if (button & BUTTON_SCROLL_DOWN)
729 newbutton |= BUTTON_SCROLL_UP;
730#endif
722#if CONFIG_KEYPAD == RECORDER_PAD 731#if CONFIG_KEYPAD == RECORDER_PAD
723 if (button & BUTTON_F1) 732 if (button & BUTTON_F1)
724 newbutton |= BUTTON_F3; 733 newbutton |= BUTTON_F3;
diff --git a/firmware/target/arm/iriver/h10/lcd-h10_20gb.c b/firmware/target/arm/iriver/h10/lcd-h10_20gb.c
index cbada34b2c..834149d2a5 100644
--- a/firmware/target/arm/iriver/h10/lcd-h10_20gb.c
+++ b/firmware/target/arm/iriver/h10/lcd-h10_20gb.c
@@ -169,8 +169,10 @@ void lcd_set_flip(bool yesno)
169 if (!power_on) 169 if (!power_on)
170 return; 170 return;
171 171
172 /* SCN4-0=000x0 (G1/G160) */
173 lcd_write_reg(R_GATE_SCAN_START_POS, yesno ? 0x0002 : 0x0000);
172 /* SM=0, GS=x, SS=x, NL4-0=10011 (G1-G160) */ 174 /* SM=0, GS=x, SS=x, NL4-0=10011 (G1-G160) */
173 lcd_write_reg(R_DRV_OUTPUT_CONTROL, yesno ? 0x0013 : 0x0113); 175 lcd_write_reg(R_DRV_OUTPUT_CONTROL, yesno ? 0x0213 : 0x0113);
174 /* HEA7-0=0xxx, HSA7-0=0xxx */ 176 /* HEA7-0=0xxx, HSA7-0=0xxx */
175 lcd_write_reg(R_HORIZ_RAM_ADDR_POS, y_offset ? 0x8304 : 0x7f00); 177 lcd_write_reg(R_HORIZ_RAM_ADDR_POS, y_offset ? 0x8304 : 0x7f00);
176} 178}