登录 免费注册 首页 | 行业黑名单 | 帮助
维库电子市场网
技术交流 | 电路欣赏 | 工控天地 | 数字广电 | 通信技术 | 电源技术 | 测控之家 | EMC技术 | ARM技术 | EDA技术 | PCB技术 | 嵌入式系统
驱动编程 | 集成电路 | 器件替换 | 模拟技术 | 新手园地 | 单 片 机 | DSP技术 | MCU技术 | IC 设计 | IC 产业 | CAN-bus/DeviceNe

【笔记】在skyeye上运行uboot

作者:rayxp 栏目:驱动编程
【笔记】在skyeye上运行uboot

参考<新手手记:一步一步教你在skyeye上运行uboot>
http://www.linuxfans.org/nuke/modules.php?NAME=Forums&file=viewtopic&t=100716
我添加两点该文档没提到的地方
--------------------------------------------------------

发信人: RayXP (``~~~~~>_<~~~~```), 信区: ETech
标  题: 在skyeye上运行uboot的笔记
发信站: 郁金香BBS站 (2006年05月12日20:39:29 星期五), 站内信件

1.安装skyeye
skyeye是一个基于各种ARM系列CPU的,SOC和主板级的模拟器。
下载地址:
    https://gro.clinux.org/frs/?group_id=327&release_id=632
        skyeye-1.0.0.tar.bz2    (版本1.0.0,安装请参考README)
    需要注意下面几点:
          1.需要添加GTK支持,安装直接  #make
          2.生成二进制文件在binary/skyeye
          3.  #./skyeye需要skyeye.conf配置文件与交叉编译好的二进制文件

(http://www.linuxfans.org/nuke/modules.php?NAME=Forums&file=viewforum&f=58)

2.u-boot下载
uboot是一个可以在各种cpu(arm,mips,powerpc)的主板上运行的引导程序.
下载地址:
      ftp://ftp.denx.de/pub/u-boot/u-boot-1.1.4.tar.bz2
uboot已支持的板子在  u-boot-1.1.4/board ,具体配置参考Makefile文件xxxx_config



3.我尝试了两个不同版本的arm交叉编译器:
     在arm交叉编译器2.95.3版本和
         ELDK(Embedded linux development kit)下编译成功


4.u-boot几点需要修改的
  Makefile
   #cat -n Makefile |grep "arm-linux-"
   60  CROSS_COMPILE = arm-linux-
     需要修改成
   60  CROSS_COMPILE = /usr/local/arm/2.95.3/bin/arm-linux-
   #cat -n Makefile |grep "_config"|grep "7312"
   1583  ep7312_config   :       unconfig
   1584          @./mkconfig $(@:_config=) arm arm720t ep7312
      是arm720t的处理器,还有可以使用#make ep7312_config进行配置
   # vi cpu/arm720t/config.mk
    把PLATFORM_CPPFLAGS +=$(call cc-option,-mapcs-32,-mabi=apcs-gnu)
    改成PLATFORM_CPPFLAGS +=$(call cc-option,-mapcs-32,$(call
cc-option,-mabi=apcs-gnu),)


5.编译u-boot
#make distclean      一定要删除上次编译生成的目标文件
#make ep7312_config
#make
#file u-boot
u-boot: ELF 32-bit LSB executable, ARM, version 1 (ARM), statically linked,
not stripped


6.编写一个skyeye.conf配置文件
#vi skyeye.conf

cpu: arm720t
mach: ep7312
mem_bank: map=I, type=RW, addr=0x80000000, size=0x00010000
#skyeye for uboot FLASH 16M bank 1
mem_bank: map=M, type=RW, addr=0x00000000, size=0x01000000,
file=./u-boot.bin,boot=yes
#skyeye for uboot SDRAM 16m bank 1
mem_bank: map=M, type=RW, addr=0xc0000000, size=0x01000000

7.在skyeye上仿真EP7312运行u-boot
#/opt/skyeye/binary/skyeye -f skyeye.conf -e u-boot

运行结果
------------------------- SkyEye -V1.0 ---------------------------
Usage: SkyEye [options] program [program args]
Default mode is STANDALONE mode
------------------------------------------------------------------
Options:
-e exec-file        the (ELF executable format)kernel file NAME.
-d                  in GDB Server mode (can be connected by GDB).
-f skyeyeconf-file  the skyeye.conf file NAME.
-h                  This Help DISPLAY
------------------------------------------------------------------
debugmode= 0, fileNAME = skyeye.conf, server TCP PORT is 12345
cpu info: armv4, arm720t, 41807200, ffffff00, 1
mach info: NAME ep7312, mach_init addr 0x808bde8
SKYEYE: use arm7100 mmu ops
Loaded RAM   ./u-boot.bin
exec file "u-boot"'s format is elf32-little.
load section .text: addr = 0xc0f80000  size = 0x000160f0.
load section .glue_7: addr = 0xc0f960f0  size = 0x00000000.
load section .glue_7t: addr = 0xc0f960f0  size = 0x00000000.
load section .rodata: addr = 0xc0f960f0  size = 0x000046ec.
load section .data: addr = 0xc0f9a7dc  size = 0x00000b63.
load section .u_boot_cmd: addr = 0xc0f9b340  size = 0x000003f0.
not load section .bss: addr = 0xc0f9b730  size = 0x000043a4 .
not load section .stab: addr = 0x00000000  size = 0x000317f4 .
not load section .stabstr: addr = 0x00000000  size = 0x0000ecc9 .
not load section .comment: addr = 0x00000000  size = 0x000007de .
start addr is set to 0xc0f80000 by exec file.




U-Boot 1.1.4 (May 12 2006 - 20:16:22)

U-Boot code: C0F80000 -> C0F9B730  BSS: -> C0F9FAD4
RAM Configuration:
Bank #0: c0000000 16 MB
FLASH: 16 MB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Hit any key to stop autoboot:  0
cs8900 Ethernet chip not found?!
BOOTP broadcast 1

[root@localhost u-boot-1.1.4]# /opt/skyeye/binary/skyeye -f skyeye.conf -e
u-boot
------------------------- SkyEye -V1.0 ---------------------------
Usage: SkyEye [options] program [program args]
Default mode is STANDALONE mode
------------------------------------------------------------------
Options:
-e exec-file        the (ELF executable format)kernel file NAME.
-d                  in GDB Server mode (can be connected by GDB).
-f skyeyeconf-file  the skyeye.conf file NAME.
-h                  This Help DISPLAY
------------------------------------------------------------------
debugmode= 0, fileNAME = skyeye.conf, server TCP PORT is 12345
cpu info: armv4, arm720t, 41807200, ffffff00, 1
mach info: NAME ep7312, mach_init addr 0x808bde8
SKYEYE: use arm7100 mmu ops
Loaded RAM   ./u-boot.bin
exec file "u-boot"'s format is elf32-little.
load section .text: addr = 0xc0f80000  size = 0x000160f0.
load section .glue_7: addr = 0xc0f960f0  size = 0x00000000.
load section .glue_7t: addr = 0xc0f960f0  size = 0x00000000.
load section .rodata: addr = 0xc0f960f0  size = 0x000046ec.
load se    n .data:' - try 'help'dc  size = 0x00000b63.
EP7312 # ommand 'At_cmd: addr = 0xc0f9b340  size = 0x000003f0.
not load section .bss: addr = 0xc0f9b730  size = 0x000043a4 .
not load section .stab: addr = 0x00000000  size = 0x000317f4 .
not load section .stabstr: addr = 0x00000000  size = 0x0000ecc9 .
not load section .comment: addr = 0x00000000  size = 0x000007de .
start addr is set to 0xc0f80000 by exec file.




U-Boot 1.1.4 (May 12 2006 - 20:16:22)

U-Boot code: C0F80000 -> C0F9B730  BSS: -> C0F9FAD4
RAM Configuration:
Bank #0: c0000000 16 MB
FLASH: 16 MB
*** Warning - bad CRC
参与讨论
昵称:
讨论内容:
 
 
相关帖子
Redhat Fedord4编译器有些问题
解决linux设备驱动示例程序不能编译问题
学习LINUX与计算机网络通信有关系吗?
ucLinux内核裁减的途径和方法的讨论
请问大虾 ,usb无线网卡的移植问题
免费注册为维库电子开发网会员,参与电子工程师社区讨论,点此进入


Copyright © 1998-2006 www.dzsc.com 浙ICP证030469号