本是个很简单的topic,但无奈的是很多客户都没有实现。所以只能写一个guide给客户,让他们依葫芦画瓢。

在SD卡上实现hive以及实现binfs最精髓的思想是,在boot stage 1依次加载sd bus driver, sd host driver,而sd host driver会根据总线枚举的结果来加载sd或者mmc的client driver.这个driver就是sd_memory.dll.
另外就是要保证sd memory的驱动得在boot stage 2之前完成加载,不然就不能取得hive.reg之外的注册表。

如果有人也感兴趣在sd/mmc上实现binfs,除了做以上的动作之外还需要修改eboot,让eboot去生成binfs分区,并将ext.bin中binfs分区部的bin数据放到binfs分区中。这个我也已经实现了。有空再表吧...

来些英文的…

Implement WinCE HIVE&ROM

system on NAND or SD system

1.0      Scope

This document details in how toimplement the WinCE6 HIVE&ROM system. Two types of media are widely used in Au1300 system, the NAND flash and the SD card. The document will describe
the steps implementing HIVE&ROM system for both media type.

2.0      Hardware details

NAND flash is connected with Au1300’s static memory controller. The SD card is connected with SD slot.

3.0      Creating HIVE&ROM system

Section 3.1 will describe how to implement HIVE&ROM system on NAND flash disk while section 3.2 describes the similar system way to create HVIE&ROM system
on SD card.

3.1 HIVE&ROM system on NAND flash

3.1.1    Add catalog components

catalog->CEBASE->File Systems and Data Store->File system->ROM-only File System

catalog->CEBASE->File Systems and Data Store->Registry Storage- >Hive-based Registry

catalog->CEBASE-> File Systems and Data Store->Storage Manager ->FAT File System

catalog->CEBASE-> File Systems and Data Store->Storage Manager ->Partition Driver

catalog->Third Party->AVN13xx:MIPSII->Storage->NAND

3.1.2    Step2: Registry settings

Update nand fmd driver registry with following content. The nand fmd driver registry is located /Drivers/Nandfmd/nandfmd.reg.

; HIVE BOOT SECTION

; This file is to be included in platform.reg if required.

[HKEY_LOCAL_MACHINE\Drivers\Builtin\NAND]

"Profile"="NAND"

"IClass"=multi_sz:"{A4E7EDDA-E575-4252-9D6B-4195D48BB865}"

"Order"=dword:0

"FriendlyName"="NAND FLASH Driver"

"Dll"="NANDFMD.dll"

"Prefix"="DSK"

"Index"=dword:1

"Flags"=dword:1000

[HKEY_LOCAL_MACHINE\System\StorageManager\AutoLoad\NAND]

"DriverPath"="Drivers\\Builtin\\NAND"

"LoadFlags"=dword:1

"Order"=dword:0

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\NAND]

"Name"="NAND FLASH Storage"

"DefaultFileSystem"="FATFS"

"PartitionDriver"="mspart.dll"

"Folder"="NAND FLASH"

"AutoPart"=dword:1

"AutoMount"=dword:1

"AutoFormat"=dword:1

[HKEY_LOCAL_MACHINE\init\BootVars]

"SystemHive"="Documents and Settings\\system.hv"

"ProfileDir"="Documents and Settings"

"Flags"=dword:3

"RegistryFlags"=dword:1

"NoDefaultUser"=dword:0

; END HIVE BOOT SECTION

3.2 HIVE&ROM system on SD card

3.2.1    Add catalog components

catalog->CEBASE->File Systems and Data Store->File system->ROM-only File System

catalog->CEBASE->File Systems and Data Store->Registry Storage- >Hive-based Registry

catalog->CEBASE-> File Systems and Data Store->Storage Manager ->FAT File System

catalog->CEBASE-> File Systems and Data Store->Storage Manager ->Partition Driver

catalog->Third Party->AVN13xx:MIPSII->Storage->Removable->Secure Digital/MMC

3.2.2    Step2: Registry settings

Update SDIO host driver registry with following content. The SDIO driver registry is located /Drivers/SDIO/sdio.reg.

;

;

; Alchemy Au1100 SD Controller registry settings

; HIVE BOOT SECTION

; setting for SD bus driver to load driver

[HKEY_LOCAL_MACHINE\Drivers\Builtin\SDHC_Au1100]

"Dll"="SDIO.dll"

"Order"=dword:1

"Prefix"="SDP"

; force the host controller to run in the PIO mode instead of

; of DMA mode.

"PIOMode"=dword:0

; Disable the MMC 8 bit wide data bus for SD0, the eMMC slot, which is slot 1

; for emmc device, dont disable 8 bits bus

; for sd device, only support 4 bits bus

"Disable8BitBus"=dword:1

"Index"=dword:1

"Flags"=dword:1000

[HKEY_LOCAL_MACHINE\Drivers\Builtin\SDBusDriver]

"Dll"="SDBus.dll"

"Order"=dword:0

"Index"=dword:1

"Prefix"="SDC"

"ThreadPriority"=dword:64     ; default thread priority for dispatch thread

"RequestListDepth"=dword:30   ; pre-allocated requests

"Flags"=dword:11000 ; DEVFLAGS_TRUSTEDCALLERONLY

"IClass"=multi_sz:"{20FA98A8-B298-4b32-8D72-C716AEE2FA84}=%b","{6F40791D-300E-44E4-BC38-E0E63CA8375C}=%b"

[HKEY_LOCAL_MACHINE\Drivers\SDCARD\ClientDrivers\Class\SDMemory_Class]

"Dll"="SDMemory.dll"

"Order"=dword:1

"Prefix"="DSK"

"BlockTransferSize"=dword:40  ; send no more than 64 blocks of data per bus transfer

;"SingleBlockWrites"=dword:1  ; alternatively force the driver to use single block access

;"IdleTimeout"=dword:7D0      ; 2000 milliseconds

;"IdlePowerState"=dword:2     ; 0 == D0, 1 == D1, etc.

;"DisablePowerManagement"=""  ; if value present, then disable (remove value to enable)

"Profile"="SDMemory"

"IClass"=multi_sz:"{A4E7EDDA-E575-4252-9D6B-4195D48BB865}",

"{A32942B7-920C-486b-B0E6-92A702A99B35}"

[HKEY_LOCAL_MACHINE\Drivers\SDCARD\ClientDrivers\Class\MMC_Class]

"Dll"="SDMemory.dll"

"Prefix"="DSK"

"BlockTransferSize"=dword:40  ; send no more than 64 blocks of data per bus transfer

;"SingleBlockWrites"=dword:1  ; alternatively force the driver to use single block access

;"IdleTimeout"=dword:7D0      ; milliseconds

;"IdlePowerState"=dword:2     ; 0 == D0, 1 == D1, etc.

;"DisablePowerManagement"=""  ; if value present, then disable (remove value to enable)

"Profile"="MMC"

"IClass"=multi_sz:"{A4E7EDDA-E575-4252-9D6B-4195D48BB865}",

"{A32942B7-920C-486b-B0E6-92A702A99B35}"

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MMC]

"Name"="MMC Memory Card"

"Folder"="MMCCard"

"PartitionDriverName"="MSPART"

"DefaultFileSystem"="FATFS"

"BootPhase"=dword:0

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MMC\FATFS]

"MountAsBootable"=dword:1

"MountAsROM"=dword:1

"MountAsRoot"=dword:1

"AutoFormat"=dword:1

"AutoPart" =dword:1

"AutoMount"=dword:1

"BootPhase"=dword:0

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\SDMemory]

"PartitionDriverName"="MSPART"

"Name"="SD Memory Card"

"Folder"="SDCard"

"DefaultFileSystem"="FATFS"

"BootPhase"=dword:0

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\SDMemory\FATFS]

;  "MountAsBootable"=dword:1

;  "MountAsROM"=dword:1

;  "MountAsRoot"=dword:1

"AutoFormat"=dword:1

"AutoPart" =dword:1

"AutoMount"=dword:1

"BootPhase"=dword:0

[HKEY_LOCAL_MACHINE\Drivers\SDCARD\ClientDrivers\Class\SDMemory_Class\High_Capacity]

"Dll"="SDMemory.dll"

"Prefix"="DSK"

"BlockTransferSize"=dword:40  ; send no more than 64 blocks of data per bus transfer

;"SingleBlockWrites"=dword:1  ; alternatively force the driver to use single block access

;"IdleTimeout"=dword:7D0      ; 2000 milliseconds

;"IdlePowerState"=dword:2     ; 0 == D0, 1 == D1, etc.

;"DisablePowerManagement"=""  ; if value present, then disable (remove value to enable)

"Profile"="SDMemory"

"IClass"=multi_sz:"{A4E7EDDA-E575-4252-9D6B-4195D48BB865}",

"{8DD679CE-8AB4-43c8-A14A-EA4963FAA715}"

[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MMC\BINFS]

"MountSystem"=dword:1

"MountAsROM"=dword:1

"BootPhase"=dword:0

; SDHC Memory Storage class driver

[HKEY_LOCAL_MACHINE\Drivers\SDCARD\ClientDrivers\Class\MMC_Class\High_Capacity]

"Dll"="SDMemory.dll"

"Prefix"="DSK"

"BlockTransferSize"=dword:100  ; send no more than 256 blocks of data per bus transfer

"Index"=dword:1

"BootPhase"=dword:0

;"BlockTransferSize"=dword:40  ; send no more than 64 blocks of data per bus transfer

"SDClockRateOverride"=dword:2625A0         ; 52000000 Hz

;"SingleBlockWrites"=dword:1  ; alternatively force the driver to use single block access

;"IdleTimeout"=dword:7D0      ; 2000 milliseconds

;"IdlePowerState"=dword:2     ; 0 == D0, 1 == D1, etc.

;"DisablePowerManagement"=""  ; if value present, then disable (remove value to enable)

"Profile"="MMC"

"IClass"=multi_sz:"{A4E7EDDA-E575-4252-9D6B-4195D48BB865}",

"{8DD679CE-8AB4-43c8-A14A-EA4963FAA715}"

[HKEY_LOCAL_MACHINE\System\StorageManager\BinFS]

"BootPhase"=dword:0

"Order"=dword:0

"FriendlyName"="BIN Filesystem"

"Dll"="binfs.dll"

"Paging"=dword:1

[HKEY_LOCAL_MACHINE\init\BootVars]

"SystemHive"="\\Hive\\system.hv"

"ProfileDir"="Documents and Settings"

"Flags"=dword:3

"RegistryFlags"=dword:1

"NoDefaultUser"=dword:0

; END HIVE BOOT SECTION

在SD/MMC卡上实现hive (Implement WinCE HIVE&ROM system on NAND or SD system )的更多相关文章

  1. SD/MMC卡初始化及读写流程

    二.MMC/SD卡的模型和工作原理 PIN脚.SD卡总线.SD卡结构.SD卡寄存器.上电过程 SD卡寄存器:  OCR:操作电压寄存器: 只读,32位 第31位: 表示卡上电的状态位   CID: 卡 ...

  2. (linux)MMC 卡驱动分析

    最近花时间研究了一下 MMC 卡驱动程序,开始在网上找了很多关于 MMC 卡驱动的分析文章,但大都是在描述各个层,这对于初学者来讲帮助并不大,所以我就打算把自己的理解写下来,希望对大家有用.个人觉得理 ...

  3. MA8621带SD读卡的USB 2.0高速3端口HUB方案芯片|MA8621中文规格书|USB 2.0方案

    MA8621说明 MA8621是USB 2.0高速3端口集线器的高性能解决方案,带有SD卡控制器,完全符合通用串行总线规范2.0.控制器继承了先进的串行接口技术,当3个DS(下游)端口同时工作时,功耗 ...

  4. 带SD读卡的USB HUB方案芯片MA8621|用于带读卡的USB HUB拓展坞方案芯片MA8621

    MA8621是一款带SD读卡器控制器的USB 2.0高速3端口集线器方案芯片,主要用在USB TYPEC拓展坞或者USB typec扩展底座上面. 1. MA8621功能概述 MA8621是USB 2 ...

  5. 【Android】读取sdcard卡上的全部图片而且显示,读取的过程有进度条显示

    尽管以下的app还没有做到快图浏览.ES文件浏览器的水平,遇到大sdcard还是会存在读取过久.内存溢出等问题,可是基本思想是这种. 例如以下图.在sdcard卡上有4张图片, 打开app,则会吧sd ...

  6. 在大于32GB或64GB容量的SD卡上使用NOOB安装树莓派 - Using NOOB on SD cards larger than 32GB or 64GB for Raspberry Pi

    在树莓派上玩了一小段时间了,因为装的软件包越来越多,所以越来越感觉16G的SD卡没办法长期使用下去.于是采购了几张64G的SD卡,打算周末装上系统.可是按照一般的流程,在Windows下用SD For ...

  7. android学习笔记47——读写SD卡上的文件

    读写SD卡上的文件 通过Context的openFileInput.openFileOutput来打开文件输入流.输出流时,程序打开的都是应用程序的数据文件夹里的文件,其存储的文件大小可能都比较有限- ...

  8. Android开发之SD卡上文件操作

    1. 得到存储设备的目录:/SDCARD(一般情况下) SDPATH=Environment.getExternalStorageDirectory()+"/"; 2. 判断SD卡 ...

  9. Android权限安全(12)apk安装在sd卡上时,如何保证数据安全

    apk安装在sd卡上时,如果把sd卡拿下安在另一个手机B上,那么apk的数据就可以被B里的恶意应用访问了. 下面是android解决这个问题的方案: 绑定设备 1,绑定perDevice使得应用以及应 ...

随机推荐

  1. 这一次,VR离我们真的很近

           从高考作文开始       今年号称是VR元年,虽然目前VR还没能像手机一样走进千家万户,但关于VR设备的关讨论是层出不穷.而今年高考,浙江省的作文题就与VR相关.网上购物.视频聊天等在 ...

  2. Cocoa层粒子发射器动画添加多个cell的一种重构

    在iOS动画之旅第19章中最后的挑战中需要我们在雪花例子发生器中添加多个雪花贴图,也就是多个cell,因为我们不可能将每个cell的参数都重新写一遍,所以有必要写一个helper方法来做这件事: fu ...

  3. Spring的DataSource配置、将Hibernate配置全部写到Spring配置

    DataSource可以集中管理数据库连接,减少维护工作量,使部署更简单: Spring的DataSource配置:(Spring数据源配置)这里使用dbcp,还有很多其他的如c3p0,jdbc,jn ...

  4. 19 Handler 子线程向主线程发送信息

    案例一 Message创建三种方法: package com.example.day19_handler_demo1; import android.os.Bundle; import android ...

  5. java.util.ServiceLoader使用

    近期在项目中需要实现能在配置文件中定义多个统一接口类型的类,可以在程序中获取到所有配置的类,刚开始打算配置到properties中,然后去程序读取,感觉这种方式不太灵活,于是,研究研究java中有没有 ...

  6. 1QPushButton的使用,QLineEdit的使用,设置组件位置,布局(QHBoxLayout,QGridLayout)

     1.新建一个空Qt项目 2 新建一个新的文件(右击项目à添加新文件) 3 配置pro文件属性 SOURCES += \ main.cpp QT += widgets gui 4 编写main.c ...

  7. java中List接口的实现类 ArrayList,LinkedList,Vector 的区别 list实现类源码分析

    java面试中经常被问到list常用的类以及内部实现机制,平时开发也经常用到list集合类,因此做一个源码级别的分析和比较之间的差异. 首先看一下List接口的的继承关系: list接口继承Colle ...

  8. 【Unity Shader实战】卡通风格的Shader(一)

    写在前面 本系列其他文章: 卡通风格的Shader(二) 呜,其实很早就看到了这类Shader,实现方法很多,效果也有些许不一样.从这篇开始,陆续学习一下接触到的卡通类型Shader的编写. 本篇的最 ...

  9. [Mysql]备份同库中一张表的历史记录 insert into ..select

    需求 现在有个这么一个需求,mysql中有个表,数据增长的很快,但是呢这个数据有效期也就是1个月,一个月以前的记录不太重要了,但是又不能删除.为了保证这个表的查询速度,需要一个简单的备份表,把数据倒进 ...

  10. 流量控制闸门——LimitLatch套接字连接数限制器

    Tomcat作为web服务器,对于每个客户端的请求将给予处理响应,但对于一台机器而言,访问请求的总流量有高峰期且服务器有物理极限,为了保证web服务器不被冲垮我们需要采取一些措施进行保护预防,需要稍微 ...