Ubuntu 10.04下安装SkyEye1.3.1

来源:互联网 发布:mac tmp文件夹 编辑:程序博客网 时间:2024/05/14 20:13

1. 下载SkyEye1.3.1,下载地址为:http://ncu.dl.sourceforge.net/project/skyeye/skyeye/skyeye-1.3.1_rc1/skyeye-1-3-1_rc1.tar.gz

2. sudo apt-get install libgtk2.0-dev pkg-config libatk1.0-dev libpango1.0-dev libfreetype6-dev libglib2.0-dev libx11-dev binutils-dev  libncurses5-dev  libxpm-dev libncurses5-dev

3. sudo aptitude install libxpm-dev

4. gedit arch/arm/mach/skyeye_mach_s3c2410x.c &
    在函数s3c2410x_io_write_word的实现case EINTPEND:的break;下面,也就是case CLKCON:的上面加入下面内容:
        case LOCKTIME:
                io.clkpower.locktime = data;
                break;
        case UPLLCON:
                io.clkpower.upllcon = data;
                break;

    将函数s3c2410x_io_reset的这一句[此步可选,但是改过后装载NandFlash会出现20 ns is too big for current clock rate 202800等错误,如果准备用NandFlash的就不要改mpllcon了,而且改mpllcon需要修改内核代码]:
    io.clkpower.mpllcon = 0x0002c080; /* workaround for linux-2.6.10 by ksh */
    改成:
    /* set cpu frequency to 202.800M, some kernel need to modify file
       arch/arm/mach-s3c2410/time.c->s3c2410_timer_setup
       [if (tcnt > 0xffff) {]->[if (tcnt > 0xffffffff) {] */
    io.clkpower.mpllcon = 0x000a1031;

5. gedit device/touchscreen/skyeye_touchscreen.c &
    在函数touchscreen_register的最后添加以下内容:
    register_option("touchscreen", do_touchscreen_option, "");

6. gedit device/touchscreen/dev_touchscreen_skyeye.c &
    将结构体定义device_default_value skyeye_ts_def的:
#if 0
    改成:
#if 1

    并在最后添加:
    {"s3c2410x",        0x19100300,    0x20,    {19, 0, 0, 0}},

7. gedit common/conf_parser/misc_options.c &
在文件的最后添加:
/*ywc 2005-04-01 dbct option*/
int
do_dbct_option (skyeye_option_t * this_option, int num_params,
        const char *params[])
{
    char name[MAX_PARAM_NAME], value[MAX_PARAM_NAME];
    int i, fd;
    skyeye_config_t *p_cur_skyeye_config = get_current_config();

    for (i = 0; i < num_params; i++) {
        if (split_param (params[i], name, value) < 0)
            SKYEYE_ERR
                ("Error: dbct has wrong parameter /"%s/"./n",
                 name);
        if (!strncmp ("state", name, strlen (name))) {
            if (!strncmp ("on", value, strlen (value))) {
                p_cur_skyeye_config->no_dbct = 0;
#ifndef NO_DBCT
                SKYEYE_INFO ("dbct info: turn on dbct!/n");
#else
                SKYEYE_INFO
                    ("dbct info: Note: DBCT not compiled in. This option will be ignored/n");
#endif
            }
            else {
                p_cur_skyeye_config->no_dbct = 1;
                SKYEYE_INFO ("dbct info: turn off dbct!/n");
            }
        }
        //teawater add for new tb manage function 2005.07.10----------------------------
        if (!strncmp ("tbt", name, strlen (name))) {
            p_cur_skyeye_config->tb_tbt_size = strtoul (value, NULL, 0);
        }
        if (!strncmp ("tbp", name, strlen (name))) {
            p_cur_skyeye_config->tb_tbp_size = strtoul (value, NULL, 0);
        }
    }
    return 0;
}

8. gedit common/conf_parser/skyeye_options.c &
在:
int
do_load_addr_option (skyeye_option_t * this_option, int num_params,
         const char *params[]);
的下面添加:
int
do_dbct_option (skyeye_option_t * this_option, int num_params,
        const char *params[]);

在:
    register_option("load_addr", do_load_addr_option, "Set load base address and mask value for elf file loading./n");
的下面添加:
    register_option("dbct", do_dbct_option, "Set dbct state./n");

9. gedit utils/nandflash_dump/mknandflashdump.c &
    将:
    int     i,j,size,offset,pos;
    改成:
    int     i,j,size,offset;
    long long pos;

    将:
    for(i=0,pos=(offset*528/512);i<statbuf.st_size;i++,pos++)
    改成:
    pos = ( long long)offset * ( long long)528 ;    
         pos = ( long long) pos / ( long long)512;  
        for(i=0; i<statbuf.st_size; i++,pos++)

10. 依次执行下面脚本:
sudo rm -fr /opt/skyeye
./configure
make lib
make
sudo make install
sudo make install_lib

11. gedit ~/.bashrc &
    在文件最后添加:
export PATH=/opt/skyeye/bin:$PATH

至此,成功安装SkyEye1.3.1。

原创粉丝点击