summaryrefslogtreecommitdiff
path: root/firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c
diff options
context:
space:
mode:
authorKarl Kurbjun <kkurbjun@gmail.com>2007-04-21 04:48:20 +0000
committerKarl Kurbjun <kkurbjun@gmail.com>2007-04-21 04:48:20 +0000
commit8a1fd8c686d2a4b8be36754e545338a476150e6a (patch)
treef69fd8be012099a8de228bd197346e4b11cf8e4a /firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c
parentdd0f1c7db1e73859805f9d9aa343bb6e04dd739e (diff)
downloadrockbox-8a1fd8c686d2a4b8be36754e545338a476150e6a.tar.gz
rockbox-8a1fd8c686d2a4b8be36754e545338a476150e6a.zip
Commit FS#6929 - Gigabeat bootloader improvements by Barry Wardell and myself. This build fixes the problems seen with the latest builds on the Gigabeat X. Added View IO Ports under the Debug menu for the Gigabeat. Make sure you grab the latest bootloader from the Wiki as the old bootloader will not work properly with new builds.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13225 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c')
-rw-r--r--firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c b/firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c
index 1bb68f9686..11edcfecb1 100644
--- a/firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c
+++ b/firmware/target/arm/s3c2440/gigabeat-fx/lcd-meg-fx.c
@@ -53,6 +53,23 @@ unsigned int LCDBASEL(unsigned int address)
53/* LCD init */ 53/* LCD init */
54void lcd_init_device(void) 54void lcd_init_device(void)
55{ 55{
56#ifdef BOOTLOADER
57 /* When the Rockbox bootloader starts, we are changing framebuffer address,
58 but we don't want what's shown on the LCD to change until we do an
59 lcd_update(), so copy the data from the old framebuffer to the new one */
60 int i;
61 unsigned short *buf = (unsigned short*)FRAME;
62
63 memcpy(FRAME, (short *)((LCDSADDR1)<<1), 320*240*2);
64
65 /* The Rockbox bootloader is transitioning from RGB555I to RGB565 mode
66 so convert the frambuffer data accordingly */
67 for(i=0; i< 320*240; i++){
68 *buf = ((*buf>>1) & 0x1F) | (*buf & 0xffc0);
69 buf++;
70 }
71#endif
72
56 LCDSADDR1 = (LCDBANK((unsigned)FRAME) << 21) | (LCDBASEU((unsigned)FRAME)); 73 LCDSADDR1 = (LCDBANK((unsigned)FRAME) << 21) | (LCDBASEU((unsigned)FRAME));
57 LCDSADDR2 = LCDBASEL((unsigned)FRAME); 74 LCDSADDR2 = LCDBASEL((unsigned)FRAME);
58 LCDSADDR3 = 0x000000F0; 75 LCDSADDR3 = 0x000000F0;