// By default, we launch image CE image. If you want to launch
// Eboot, you need to hold down APP4 button (sw803) when it boots.
JumpAddr=0x30200000;
MMU_EnableICache();
Uart_Init();
Uart_SendString(SIGN_ON);
NF_Init();
LcdDisplayPic();
ReadImageFromNand();
Launch(JumpAddr);
}
串口初始化这块需要修改吗?要改什么地方?
我如下写:
void Main(void)
{
// By default, we launch image CE image. If you want to launch
// Eboot, you need to hold down APP4 button (sw803) when it boots.
JumpAddr=0x30200000;
MMU_EnableICache();
Uart_Init();
Uart_SendString(SIGN_ON);
NF_Init();
Uart_SendString("hello world");
// LcdDisplayPic();
// ReadImageFromNand();
// Launch(JumpAddr);
}
// By default, we launch image CE image. If you want to launch
// Eboot, you need to hold down APP4 button (sw803) when it boots.
JumpAddr=0x30200000;
MMU_EnableICache();
Uart_Init();
Uart_SendString(SIGN_ON);
NF_Init();
Uart_SendString("hello world");
// LcdDisplayPic();
// ReadImageFromNand();
// Launch(JumpAddr);
}
// FMD_ReadSector
//
// Read the content of the sector.
//
// startSectorAddr: Starting page address
// pSectorBuff : Buffer for the data portion
// pSectorInfoBuff: Buffer for Sector Info structure
// dwNumSectors : Number of sectors
//
BOOL
FMD_ReadSector(
SECTOR_ADDR startSectorAddr,
LPBYTE pSectorBuff,
PSectorInfo pSectorInfoBuff,
DWORD dwNumSectors
)
{
DWORD i, r = 0;
BYTE ecc0,ecc1,ecc2;
BOOL rc = TRUE;
ECCRegVal eccRegVal; //注意这个结构体,在这里声明的,它有两个成员,后面可以看到,
// BUGBUGBUG: I need to come back to support dwNumSectors > 1
//
// Sanity check
if (!pSectorBuff && !pSectorInfoBuff || dwNumSectors > 1 || !pSectorBuff) {
Uart_SendString("ERROR_INVALID_PARAMETER\n");
return FALSE;
}