分类: LINUX
2008-04-07 21:40:10
Linux
【平台信息】
目标板(Nano2410)------------------------
CPU: S
SDRAM: HY57V561620(32MB)
FLASH: K
NET: CS8900
HOST---------------------------------------
Linux Realse Version: Fecora Cor 8 (FC8)
CrossCompiler: gcc-
从启动信息可以看出没有加载成功LCD驱动
io scheduler cfq registered
s
s
lp: driver loaded but no devices found
LCD为三星的3.5寸TFT屏. 分辨率320x240
内核代码修改步骤:
1. 修改文件/linux
加入头文件#include
添加代码
static struct s
{
/* Config for 240x320 LCD */
.lcdcon5 = S
S
S
S
S
.type = S
.width = 320,
.height = 240,
.pixclock = 100000, /* HCLK/10 */
.xres = 320,
.yres = 240,
.bpp = 16,
.left_margin = 16,
.right_margin = 6,
.hsync_len = 9,
.upper_margin = 4,
.lower_margin = 6,
.vsync_len = 16,
}
};
static struct s
.displays = nano2410_lcd_cfg,
.num_displays = ARRAY_SIZE(nano2410_lcd_cfg),
.default_display = 0,
.gpccon = 0xaa955699,
.gpccon_mask = 0xffc003cc,
.gpcup = 0x0000ffff,
.gpcup_mask = 0xffffffff,
.gpdcon = 0xaa95aaa1,
.gpdcon_mask = 0xffc0fff0,
.gpdup = 0x0000faff,
.gpdup_mask = 0xffffffff,
.lpcsel = ((0xCE6) & ~7) | 1<<4,
};
在函数smdk2410_init()中加入
s
在内核配置时,启用graphic device里面的frambuffer.并打开boot logo
重新编译内核,看看启动信息
……
io scheduler cfq registered
Console: switching to colour frame buffer device 30x40
fb0: s
……
同时可以看到LCD上出现了一只可爱的小企鹅~~~
在uboot中设置boot command中的console=tty .可以讲启动信息在LCD上显示.
tov_tw2008-12-04 09:58:09
老兄,小弟按您的方法,的确可以看到 Console: switching to colour frame buffer device 30x40 fb0: s3c2410fb frame buffer device 但是还是白屏。 請問2.6.24內核配置时,有个 Device Drivers Graphic support Backlight & LCD device support <*> Lowlevel LCD support <*> Samsung LTV350QV LCD Panel 开启这两项,是否就可以支援LCD了呢?