首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 嵌入开发 > WinCE >

WINCE Eboot启动出有关问题

2012-02-03 
WINCE Eboot启动出问题现象:主板上电,启动Eboot时,图片有显示,然后等了一、两分钟,就出现黑屏了串口输出信

WINCE Eboot启动出问题
现象:主板上电,启动Eboot时,图片有显示,然后等了一、两分钟,就出现黑屏了
串口输出信息:
Step ldr

Nand flash id: 0x0000eca1
here
Microsoft Windows CE Ethernet Bootloader Common Library Version 1.1 Built Oct 26 2008 11:02:56
Microsoft Windows CE Bootloader for the Samsung SMDK2440 Version 2.4 Built Oct 26 2008

InitDisplay
GPA IOPORT 0x7ECFFF
Memory Bank 0x22111120
GPFCON 0x8
BP_Init BINFS_RAM_START = 0xa0080000
FMD::FMD_Init - pBSPArgs->nfsblk = 0x0 
FMD::FMD_Init - READ_REGISTER_BYTE(pNFSBLK) = 0x0 
FMD::FMD_Init IPL ..... 
FMD::FMD_Init Done
MID = 0xec, DID = 0xa1 4th Cycle : 0x0
NUMBLOCKS : 1024(0x400), SECTORSPERBLOCK = 256(0x100), BYTESPERSECTOR = 512(0x200) 
MID = 0xec, DID = 0xa1 4th Cycle : 0x0
NUMBLOCKS : 1024(0x400), SECTORSPERBLOCK = 256(0x100), BYTESPERSECTOR = 512(0x200) 
wNUM_BLOCKS : 1024(0x400) 
Press [ENTER] to launch image stored on boot media, or [SPACE] to enter boot monitor.

Initiating image launch in 0 seconds. 
Launching image from boot media ... 
OEMPlatformInit: IMAGE_TYPE_RAMIMAGE
RAM image
RAM image
IsValidMBR: MBR sector = 0x400
OpenPartition: Partition Exists=0x1 for part 0x21.
BP_SetDataPointer at 0x0
ReadData: Start = 0x0, Length = 0x1240800.
Log2Phys: Logical 0x500 -> Physical 0xa00
System ready!
Preparing for download...
+OEMPreDownload.
waitforconnect
INFO: OEMLaunch: Jumping to Physical Address 0x3022BC28h (Virtual Address 0x8022BC28h)...

C

根据串口输出信息,由最后一条调试信息定位到main.c的代码如下:
 // Jump to downloaded image (use the physical address since we'll be turning the MMU off)...
  //
  dwPhysLaunchAddr = (DWORD)OALVAtoPA((void *)dwLaunchAddr);
  OALMSG(TRUE, (TEXT("INFO: OEMLaunch: Jumping to Physical Address 0x%Xh (Virtual Address 0x%Xh)...\r\n\r\n\r\n"), dwPhysLaunchAddr, dwLaunchAddr));
  // Jump...
  //
  Launch(dwPhysLaunchAddr);

当时,我试着重新烧写NK,可仍然会出问题。
串口信息如下:
Step ldr

Nand flash id: 0x0000eca1
her?
Microsoft Windows CE Ethernet Bootloader Common Library Version 1.1 Built Oct 26 2008 11:02:56
Microsoft Windows CE Bootloader for the Samsung SMDK2440 Version 2.4 Built Oct 26 2008

InitDisplay
GPA IOPORT 0x7ECFFF
Memory Bank 0x22111120
GPFCON 0x8
BP_Init BINFS_RAM_START = 0xa0080000
FMD::FMD_Init - pBSPArgs->nfsblk = 0x0 
FMD::FMD_Init - READ_REGISTER_BYTE(pNFSBLK) = 0x0 
FMD::FMD_Init IPL ..... 
FMD::FMD_Init Done
MID = 0xec, DID = 0xa1 4th Cycle : 0x0
NUMBLOCKS : 1024(0x400), SECTORSPERBLOCK = 256(0x100), BYTESPERSECTOR = 512(0x200) 
MID = 0xec, DID = 0xa1 4th Cycle : 0x0
NUMBLOCKS : 1024(0x400), SECTORSPERBLOCK = 256(0x100), BYTESPERSECTOR = 512(0x200) 
wNUM_BLOCKS : 1024(0x400) 
Press [ENTER] to launch image stored on boot media, or [SPACE] to enter boot monitor.

Initiating image launch in 4 seconds. 
Ethernet Boot Loader Configuration:

0) IP address: 0.0.0.0
1) Subnet mask: 255.255.255.0
2) DHCP: Disabled
3) Boot delay: 5 seconds
4) Reset to factory default configuration
5) Startup image: LAUNCH EXISTING
6) Program disk image into SmartMedia card: Enabled
7) Program DM9000 MAC address (00:00:32:12:33:12)
8) Kernel Debugger: DISABLED
9) Format Boot Media for BinFS
A) auto fast format and download image to flash 
E) Erase Reserved Block 
S) download image by serial---(SERIAL) 
B) Mark Bad Block at Reserved Block 
F) Low-level format the Smart Media card
D) Download image now---(ETHNET)
L) LAUNCH existing Boot Media image
R) Read Configuration 
U) DOWNLOAD image now---(USB)
W) Write Configuration Right Now
Z) Fast Format Boot Media for BinFS



Enter your selection: u
OEMPlatformInit: initialize USB.
INFO: (unsigned)pUSBCtrlAddr : 0xB1200140
System ready!
Preparing for download...
+OEMPreDownload.
<RSET]
<RSET]
<RSET]
<3:TBD]
pUSBCtrlAddr->OCSR1.out_pkt_rdy = 0x1
Ep3Handler : downPtIndex = 0x32000040
dwDWNAddress = 0xc000000 , dwDWNlength = 0x11e4135.
Please send the Image through USB.

Download BIN file information:
-----------------------------------------------------
[0]: Base Address=0x80200000 Length=0x124063c
-----------------------------------------------------
RAM image
rom_offset=0x0.
ROMHDR at Address 80200044h
Writing single region/multi-region update, dwBINFSPartLength: 19138108 
IsValidMBR: MBR sector = 0x400
OpenPartition: Partition Exists=0x1 for part 0x21.
BP_SetDataPointer at 0x0
WriteData: Start = 0x0, Length = 0x124063c.
Log2Phys: Logical 0x500 -> Physical 0xa00
Updateded TOC!
IsValidMBR: MBR sector = 0x400
OpenPartition: Partition Exists=0x1 for part 0xb.
TOC {
dwSignature: 0x434F544E
BootCfg { 
  ConfigFlags: 0x830
  BootDelay: 0x5
  ImageIndex: 1 
  IP: 0.0.0.0
  MAC Address: 00:00:32:12:33:12
  Port: 0.0.0.0
  SubnetMask: 255.255.255.0
}
ID[0] {
  dwVersion: 0x20004
  dwSignature: 0x45424F54
  String: 'eboot.nb0'
  dwImageType: 0x2
  dwTtlSectors: 0x1F5
  dwLoadAddress: 0x80038000
  dwJumpAddress: 0x80039000
  dwStoreOffset: 0x0
  sgList[0].dwSector: 0x200
  sgList[0].dwLength: 0x1F5
}
ID[1] {
  dwVersion: 0x1
  dwSignature: 0x43465348
  String: ''
  dwImageType: 0x2
  dwTtlSectors: 0x9204
  dwLoadAddress: 0x80200000
  dwJumpAddress: 0x8022BC28
  dwStoreOffset: 0x0
  sgList[0].dwSector: 0xA00
  sgList[0].dwLength: 0x9204
}
chainInfo.dwLoadAddress: 0X00000000
chainInfo.dwFlashAddress: 0X00000000
chainInfo.dwLength: 0X00000000
}
waitforconnect
INFO: OEMLaunch: Jumping to Physical Address 0x3022BC28h (Virtual Address 0x8022BC28h)...

C醀indows CE Kernel for ARM (Thumb Enabled) Built on Jun 24 2004 at 18:25:00
ProcessorType=0920 Revision=0
sp_abt=ffff5000 sp_irq=ffff2800 sp_undef=ffffc800 OEMAddressTable = 8022bae4
DCache: 8 sets, 64 ways, 32 line size, 16384 size
ICache: 8 sets, 64 ways, 32 line size, 16384 size
Sp=ffffc7cc
OEMIoControl: Unsupported Code 0x10100b4 - device 0x0101 func 45
OEMIoControl: Unsupported Code 0x101008c - device 0x0101 func 35
FMD::FMD_Init - pBSPArgs->nfsblk = 0x0 
FMD::FMD_Init - READ_REGISTER_BYTE(pNFSBLK) = 0x0 
FMD::FMD_Init IPL ..... 
FMD::FMD_Init Done
MID = 0xec, DID = 0xa1 4th Cycle : 0x0
NUMBLOCKS : 1024(0x400), SECTORSPERBLOCK = 256(0x100), BYTESPERSECTOR = 512(0x200) 
FMD_OEMIoControl: unrecognized IOCTL (0x71c24).
OEMIoControl: Unsupported Code 0x1010104 - device 0x0101 func 65
OEM: Not clearing storage
FMD(FMD_LB_ReadSector): ECC ERROR - Page #: 0x32181 
BLOCK the bad block : 0x321
Please restart board and burn NK again!FMD(FMD_LB_ReadSector): ECC ERROR - Page #: 0x32101 
BLOCK the bad block : 0x321
Please restart board and burn NK again!FMD_OEMIoControl: unrecognized IOCTL (0x71c54).
FMD_OEMIoControl: unrecognized IOCTL (0x71c54).

信息定位到fmd.cpp文件中,代码为:
if ((READ_REGISTER_ULONG(pNFESTAT0)&0x3) != 0x0){

DWORD i;
SectorInfo si;

// to keep bootpart off of our reserved blocks we must mark it as bad, reserved & read-only
si.bOEMReserved &= ~(OEM_BLOCK_RESERVED | OEM_BLOCK_READONLY);
si.bBadBlock = BADBLOCKMARK;
si.dwReserved1 = 0xffffffff;


si.wReserved2 = 0xffff;

//OALMSG(TRUE, (TEXT("Reserving Blocks [0x%x - 0x%x] ...\r\n"), 0, IMAGE_START_BLOCK-1));
for(i = (startSectorAddr & 0xff00); i<( ((startSectorAddr>>8)+1)<<8) ;i++)
{
FMD_WriteSector(i, NULL, &si, 1);
}

RETAILMSG(1, (TEXT("FMD(FMD_LB_ReadSector): ECC ERROR - Page #: 0x%x \r\n"), startSectorAddr));
RETAILMSG(1,(TEXT("BLOCK the bad block : 0x%x\r\nPlease restart board and burn NK again!"),startSectorAddr>>8));//OEMPlatformInit();
//return FALSE;
}

请大侠们帮忙指点迷津,万分感激!

[解决办法]

探讨

请问fmd.cpp文件是干什么用的?

热点排行