ROM,RAM使用情况统计

一般我们的flash分区文件在custom_MemoryDevice.h (custom\system\techain50_cosmos_11b_bb) 目录下。

一般的flash大小为128*64Mb,指的是位,即为128*64M/bit(128*64Mb),也就是我们通常说的小b,
所以,真正计算时,我们要换算为Byte计算,也就是所谓的大B进行计算,即都除8,也就是16*8M/Byte(16*8MB)。前面是ROM,后面是RAM。

 ****************************************************************************
 Step 6: This is an optional step special for NOR-XIP configuration only.
 
         This step configures the FS (file system) region information on NOR FLASH!

         By default, FS region is located the last bank of NOR Flash.
         For specific purpose, user are able to manually configure the
         
         Step 1. Start address of FS region on NOR-flash,
         Step 2. Total FS size on NOR-flash disk
         Step 3. The first drive (or partition) size of FS region. if no additional drive
                 on NOR-flash disk, it should be 0. For more details, please refer to REMIND.
         
         [REMIND]
         ========
         It is special for flash disk which has two drives (or partitions), the
         first leading is user drive, visible on USB disk, the second may be
         system drive, and invisible from USB disk.

         [VERY IMPORTANT NOTICE]
         =======================
         1. Disable this definition and make auto Gen pick default setting from
            Memory Device Excel Database is recommend.
            
         2. Please assign the exact integer value in terms of sectors (one sector equal
            to 512 Bytes) in NOR_BOOTING_NOR_FS_FIRST_DRIVE_SECTORS.
            MUST NOT assign as
            (TOTAL_FS_SIZE - SIZE_OF_SYSTEM_DRIVE), because system will keep
            some spaces for disk management.

 ****************************************************************************
*/

#define NOR_BOOTING_NOR_FS_BASE_ADDRESS           0x00E40000
#define NOR_BOOTING_NOR_FS_SIZE                   0x001C0000
#define NOR_BOOTING_NOR_FS_FIRST_DRIVE_SECTORS    260


 

其中,

0x00E40000:代码段,E40000转换为十进制为:14942208,14942208/1024=14592KB,再除以1024即14.25MB.这就是我们配置的ROM大小。

0x001C0000:文件系统盘,文件系统盘大小+代码段大小=整个flash ROM空间大小。

260:用户盘大小,260*512/1024=130KB 属于文件系统盘中的一部分。

 

1.ROM计算

build\CHERRY_T71_COSMOS_11B\CHERRY_T71_COSMOS_11B_PCB01_gprs_MT6250_S00.CHERRY_W7_T712V_M01_DEMO_121219.bin文件夹下

VIVA
TECHAIN50_COSMOS_11B_BOOTLOADER_V005_MT6250_T750_M00_S03_120811.bin
ROM
EXT_BOOTLOADER
 

以上四个文件的size相加,就是已经使用的ROM空间大小。

 
2.RAM计算方法:
  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值