diff options
author | Maurus Cuelenaere <mcuelenaere@gmail.com> | 2008-07-16 12:54:43 +0000 |
---|---|---|
committer | Maurus Cuelenaere <mcuelenaere@gmail.com> | 2008-07-16 12:54:43 +0000 |
commit | e3b2f4ffeda7b804a16125e26918c7cdbcecdac9 (patch) | |
tree | fb4bb916ced47e43c942478fca66495d3b803238 /firmware/target/mips/ingenic_jz47xx/onda_vx747 | |
parent | ffddab1e664ee9c0a1aec69f02a8ebfaeba3fb3e (diff) |
Switch screen 90 degrees clockwise
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18069 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/mips/ingenic_jz47xx/onda_vx747')
-rw-r--r-- | firmware/target/mips/ingenic_jz47xx/onda_vx747/button-onda_vx747.c | 9 | ||||
-rw-r--r-- | firmware/target/mips/ingenic_jz47xx/onda_vx747/lcd-onda_vx747.c | 6 |
2 files changed, 7 insertions, 8 deletions
diff --git a/firmware/target/mips/ingenic_jz47xx/onda_vx747/button-onda_vx747.c b/firmware/target/mips/ingenic_jz47xx/onda_vx747/button-onda_vx747.c index 950fc51d69..b3c0a5fb64 100644 --- a/firmware/target/mips/ingenic_jz47xx/onda_vx747/button-onda_vx747.c +++ b/firmware/target/mips/ingenic_jz47xx/onda_vx747/button-onda_vx747.c @@ -67,13 +67,12 @@ static int touch_to_pixels(short x, short y) y -= 300; /* X & Y are switched */ - x /= 3200 / LCD_HEIGHT; - y /= 3600 / LCD_WIDTH; + x /= 3200 / LCD_WIDTH; + y /= 3600 / LCD_HEIGHT; - x = LCD_HEIGHT - x; - y = LCD_WIDTH - y; + y = LCD_HEIGHT - y; - return (y << 16) | x; + return (x << 16) | y; } int button_read_device(int *data) diff --git a/firmware/target/mips/ingenic_jz47xx/onda_vx747/lcd-onda_vx747.c b/firmware/target/mips/ingenic_jz47xx/onda_vx747/lcd-onda_vx747.c index 05e4d3a9fc..871f2f0861 100644 --- a/firmware/target/mips/ingenic_jz47xx/onda_vx747/lcd-onda_vx747.c +++ b/firmware/target/mips/ingenic_jz47xx/onda_vx747/lcd-onda_vx747.c @@ -61,15 +61,15 @@ static void _display_on(void) { int i; - SLCD_SEND_COMMAND(REG_SOFT_RESET, SOFT_RESET_EN); + SLCD_SEND_COMMAND(REG_SOFT_RESET, SOFT_RESET(1)); SLEEP(700000); - SLCD_SEND_COMMAND(REG_SOFT_RESET, SOFT_RESET_DIS); + SLCD_SEND_COMMAND(REG_SOFT_RESET, SOFT_RESET(0)); SLEEP(700000); SLCD_SEND_COMMAND(REG_ENDIAN_CTRL, 0); SLCD_SEND_COMMAND(REG_DRIVER_OUTPUT, 0x100); SLCD_SEND_COMMAND(REG_LCD_DR_WAVE_CTRL, 0x100); - SLCD_SEND_COMMAND(REG_ENTRY_MODE, 0x1028); + SLCD_SEND_COMMAND(REG_ENTRY_MODE, (ENTRY_MODE_BGR | ENTRY_MODE_VID | ENTRY_MODE_HID)); SLCD_SEND_COMMAND(REG_DISP_CTRL2, 0x503); SLCD_SEND_COMMAND(REG_DISP_CTRL3, 1); SLCD_SEND_COMMAND(REG_LPCTRL, 0x10); |