K9G8G08U0A升级到K9GAG08U0D烧录NK要注意的地方

由于三星的MLC flash 型号为K9G8G08U0A已经停产,可能有些朋友会使用K9GAG08U0D进行替换,由于两个flash的页大小不一样(K9G8G08U0A页大小是2KB,K9GAG08U0D页大小是4K),在烧录NK的时候有些地方要注意一下,下面是s3c6410 WINCE6.0 MLC版本的BSP包的修改方法

nand.cpp文件的WriteRawImageToBootMedia函数

第一个地方

#ifdef NAND_4K
        if (SECTORS_PER_PAGE == 8)
			dwNumPage+=2;  // page No. 0 and 1 use only 2KByte/Page, so add 2 page.
#else
		if (SECTORS_PER_PAGE == 8)
			dwNumPage++;  // page No. 0 and 1 use only 2KByte/Page, so add 1 page.
#endif

第二个地方

#ifdef NAND_4K
			if (dwPage < 4 || IS_SLC)
			{
				nSctBitmap = 0xf;
				nBufCnt = BYTES_PER_SECTOR*4;
			}
#else
			if (dwPage < 2 || IS_SLC)
			{
				//nSctBitmap = 0xf;
				//nBufCnt = BYTES_PER_SECTOR*4;
				if(BYTES_PER_MAIN_PAGE == 2048)//for 2Kpage
				{
					nSctBitmap = 0xf;
					nBufCnt = BYTES_PER_SECTOR*4;
				}
			}

#endif

第三个地方

#ifdef NAND_4K
			if (IS_MLC && dwPage >= 4 && dwPage < 10) dwPage = 10; //for 8K Stepping stone
#else
			if(BYTES_PER_MAIN_PAGE == 2048)//for 2Kpage
			{
				if (IS_MLC && dwPage >= 4 && dwPage < 10) dwPage = 10; //for 8K Stepping stone
			}

#endif



评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值