TUNA Board Tutorialopennvram.org/wordpress/wp-content/uploads/2015/08/TUNA... · 2016-04-10 ·...

Preview:

Citation preview

TUNA Board Tutorial

漢陽大學校

수정일: 2015년 1월 16일

漢陽大學校

OutlineOutline

툴체인 설치 및 환경 설정

U-Boot 빌드

Linux 커널 빌드

뉴메모리 에뮬레이션 테스트

Android 빌드

2

漢陽大學校

툴 체인 설치 및 환경 설정

3

漢陽大學校

Xilinx Toolchain 다운로드Xilinx Toolchain 다운로드

4

Download

http://www.wiki.xilinx.com/Install+Xilinx+Tools에서 툴체인 다운로드

漢陽大學校

Xilinx Toolchain 설치Xilinx Toolchain 설치

툴체인 설치

5

漢陽大學校

Xilinx Toolchain 설치Xilinx Toolchain 설치

6

漢陽大學校

Xilinx Toolchain 설치Xilinx Toolchain 설치

7

漢陽大學校

Xilinx Toolchain 환경 설정Xilinx Toolchain 환경 설정

크로스 컴파일 환경설정 $ export CROSS_COMPILE=arm-xilinx-linux-gnueabi- $ source /opt/Xilinx/SDK/2014.4 settings64.sh

설치한 toolchain에 따라 경로는 다를 수 있음 ex) Xiline ISE toolchain 사용시

$ source /opt/Xilinx/14.7/ISE_DS/settings32(64).sh

8

漢陽大學校

부트 파일 빌드

9

漢陽大學校

Git을 이용하여 소스코드 다운로드 U-boot : $ git clone git://git.xilinx.com/u-boot-xlnx.git Linux Kernel : $ git clone git://git.xilinx.com/linux-xlnx.git

소스코드 다운로드소스코드 다운로드

10

<U-boot>

<Linux Kernel>

漢陽大學校

U-Boot 빌드U-Boot 빌드

To build U-Boot for zc702/zc706 execute: $ make zynq_zc70x_config $ make

완료

11

U-boot 이미지

漢陽大學校

U-Boot 이미지 생성U-Boot 이미지 생성

“mkimage” command not found – U-boot image will not be built $ apt-get install uboot-mkimage

12

漢陽大學校

BOOT.bin 파일 생성BOOT.bin 파일 생성

BOOT.bin 파일 생성시 필요한 파일 FSBL.elf 파일 (First Step Boot Loader)

$ wget http://dmclab.hanyang.ac.kr/wikidata/download/FSBL.elf

system_top.bit 파일 (비트스트림) $ wget http://dmclab.hanyang.ac.kr/wikidata/download/system_top.bit

u-boot.elf 파일 (u-boot) u-boot 파일의 이름을 u-boot.elf로 변경

BOOT.bin 파일 생성 bootimage.bif 파일 생성

$ bootgen -image bootimage.bif -w on -o i BOOT.bin

13

漢陽大學校

Linux 커널 빌드

14

漢陽大學校

리눅스 커널 이미지 생성리눅스 커널 이미지 생성

리눅스 커널 Configuration $ make ARCH=arm xilinx_zynq_defconfig

$ make ARCH=arm menuconfig

리눅스 커널 빌드 $ make ARCH=arm UIMAGE_LOADADDR=0x8000 uImage

15

漢陽大學校

리눅스 커널 이미지 생성리눅스 커널 이미지 생성

arch/arm/boot 디렉토리에 uImage 생성

16

漢陽大學校

Device Tree Blob 생성Device Tree Blob 생성

리눅스 커널 arch/arm/boot/dts에 zynq-zc706.dts 파일이 존재

Device Tree 생성 $ make ARCH=arm zynq-zc706.dtb

arch/arm/boot/dts에 zynq-zc706.dtb 파일 생성

17

메모리 크기 조절

漢陽大學校

램디스크 이미지 생성램디스크 이미지 생성

램디스크 이미지 다운로드 $ wget http://www.wiki.xilinx.com/file/view/arm_ramdisk.image.gz

419243558/arm_ramdisk_image.gz

램디스크 이미지 생성 $ mkimage -A arm -T ramdisk -C gzip -d arm_ramdisk.image.gz

uramdisk.image.gz

18

漢陽大學校

부트파일 복사부트파일 복사

microSD에 부팅에 필요한 파일들을 복사 BOOT.bin uImage uramdisk.image.gz devicetree.dtb

복사가 완료된 microSD를 TUNA보드에 삽입

19

漢陽大學校

터미널 설정

20

漢陽大學校

터미널 장치 드라이버 설치터미널 장치 드라이버 설치

윈도우에서 가상 머신 사용시 호스트 OS에 USB-to-UART 드라이버(CP210x_VCP) 설치 다운로드 :

http://www.silabs.com/products/mcu/pages/usbtouartbridgevcpdrivers.aspx

21

漢陽大學校

드라이버 설치 확인드라이버 설치 확인

가상머신에 USB 연결 후, /dev/ttyUSB0 확인

22

漢陽大學校

터미널 환경 설정터미널 환경 설정

Minicom 환경 설정 $ apt-get install minicom $ minicom –s Serial port setup

23

漢陽大學校

터미널 실행터미널 실행

저장 후 minicom 실행

24

漢陽大學校

뉴메모리 에뮬레이션 테스트

25

漢陽大學校

TUNA 보드 Latency 조절 기능TUNA 보드 Latency 조절 기능

TUNA 보드 2GB의 PL-DRAM 영역에 대하여 read/write latency 조절가능

메모리 입출력에 지연 부가

read/write 각각 16단계(0~15)의 latency level 제공 각 latency 레벨에 따른 latency 차이는 RTL 수정을 통해 가능

Default setting read latency offset = 50ns write latency offset =100ns

RTL은 bit-stream파일로 제공

26

漢陽大學校

TUNA Board 에서 NVRAM Latency 조절 방법TUNA Board 에서 NVRAM Latency 조절 방법

Git에서 NVRAM Latency를 조절하는 소스코드 다운로드 $ git clone https://github.com/ESOS-Lab/HEAPO.git HEAPO_ARM_3.15 디렉토리에 latency_controller.c 확인

latency_controller 빌드 $ export CROSS_COMPILE=arm-xilinx-linux-gnueabi- $ source /opt/Xilinx/SDK/2014.4/settings64.sh $ arm-xilinx-linux-gnueabi-gcc -o latency_controller latency_controller.c

latency_controller 사용법 latency 실행 파일을 TUNA보드에서 실행 latency_controller [READ LATENCY] [WRITE LATENCY]

0~15 사이의 정수값을 인자로 입력 사용예)

현재는 재변경시 reboot 필요

27

漢陽大學校

memtest 모듈: Read 및 Write Testmemtest 모듈: Read 및 Write Test

memtest 모듈 linux kernel 모듈의 모듈 초기화 코드에서 latency 측정 PL-DRAM영역을 디바이스 메모리로 접근 ioremap_nocache()를 이용하여 메모리 매핑 설정 후 입출력 시간 측정 ARM PMU(Performance Monitoring Unit)를 이용해 시간 측정

memtest 모듈 환경 설정 dts 설정에서 메모리 영역은 0x0 ~ 0x40000000으로 설정

memtest 모듈 빌드 Makefile의 커널 소스 경로 및 크로스컴파일러 경로 설정 후, make로 빌드

28

$ wget http://dmclab.hanyang.ac.kr/wikidata/download/memtest.tar$ tar xvf memtest.tar$ vi Makefile$ make

$ wget http://dmclab.hanyang.ac.kr/wikidata/download/memtest.tar$ tar xvf memtest.tar$ vi Makefile$ make

漢陽大學校

memtest 모듈 실행memtest 모듈 실행

memtest 모듈 실행 TUNA보드에서 memtest.ko 모듈 로드

테스트 항목 단일 load/store 인스트럭션 수행 시간: 각 10회씩 수행

ldrb/strb: 1-byte load/store ldrh/strh: 2-byte load/store ldr/str: 4-byte load/store

32-byte(캐시라인 단위) load/store: 8 X (ldr/str)

stride size 변화에 따른 latency 측정 stride size: 4byte ~ 16Kbyte loop 횟수: 1,000,000

29

zynq> insmod memtest.kozynq> insmod memtest.ko

漢陽大學校

HEAPO를 이용한 read latency 측정HEAPO를 이용한 read latency 측정

HEAPO 뉴메모리 사업단에서 개발한 persistent heap layer

TUNA Ported-HEAPO PL-DRAM 영역(0x40000000~0xC0000000)을 ZONE_NVRAM으로 지정 HEAPO를 이용한 모든 메모리 할당은 PL-DRAM에 할당

30

漢陽大學校

HEAPO 커널 빌드HEAPO 커널 빌드

HEAPO Download git clone https://github.com/ESOS-Lab/HEAPO.git

ARM버전의 HEAPO 리눅스 커널 빌드 $ cd HEAPO/HEAPO_ARM_3.15/linux-xlnx $ make ARCH=arm UIMAGE_LOADADDR=0x8000 uImage arch/arm/boot/ 에 uImage 생성

라이브러리 빌드 $ cd HEAPO/HEAPO_ARM/Library make ./install.sh

microSD의 커널 이미지 교체

31

漢陽大學校

HEAPO-based Read Latency 측정HEAPO-based Read Latency 측정

구현 HEAPO library를 이용하여 구현(HEAPO 필요) ARM PMU(Performance Monitoring Unit)를 이용해 시간 측정

다운로드 $ wget http://dmclab.hanyang.ac.kr/wikidata/download/read_test.tar.gz $ tar xvf read_test.tar.gz

빌드 $ arm-xilinx-linux-gnueabi-gcc -O0 -mtune=cortex-a9 -o Read_test –static

Read_test.c v7_pmu.s -L ../../HEAPO/HEAPO_ARM_3.15/Library/ -lpos

실행 사용 $ cd mnt $ insmod user.ko

user mode pmu 활성화

$ ./Read_test32

漢陽大學校

Android 빌드

33

漢陽大學校

준비준비

안드로이드 부팅에 필요한 파일 BOOT.bin uImage devicetree.dtb uramdisk.image.gz

$ wgethttp://dmclab.hanyang.ac.kr/wikidata/download/android/uramdisk.image.gz

init.sh $ wget http://dmclab.hanyang.ac.kr/wikidata/download/android/init.sh

root_fs.tar.gz $ wget http://dmclab.hanyang.ac.kr/wikidata/download/android/root_fs.tar.gz

34

漢陽大學校

microSD 파티션 설정microSD 파티션 설정

Android 파티션 Boot partition: FAT32, boot files Root partition: EXT4, Android root file system Storage partition: EXT4, external storage

파티션 설정 모든 microSD 파티션 언마운트 fdisk 실행 (sdb가 microSD라고 가정)

기존 파티션 전부 삭제 (d command)

35

$ fdisk /dev/sdb$ fdisk /dev/sdb

漢陽大學校

Boot 파티션 생성Boot 파티션 생성

36

Command (m for help): nPartition type:p primary (0 primary, 0 extended, 4 free)e extendedSelect (default p):Using default response pPartition number (1‐4, default 1):Using default value 1First sector (2048‐15523839, default 2048):Using default value 2048Last sector, +sectors or +size{K,M,G} (2048‐15523839, default 15523839): +1GCommand (m for help): tSelected partition 1Hex code (type L to list codes): cChanged system type of partition 1 to c (W95 FAT32 (LBA))

Command (m for help): nPartition type:p primary (0 primary, 0 extended, 4 free)e extendedSelect (default p):Using default response pPartition number (1‐4, default 1):Using default value 1First sector (2048‐15523839, default 2048):Using default value 2048Last sector, +sectors or +size{K,M,G} (2048‐15523839, default 15523839): +1GCommand (m for help): tSelected partition 1Hex code (type L to list codes): cChanged system type of partition 1 to c (W95 FAT32 (LBA))

漢陽大學校

Root 파티션 생성Root 파티션 생성

37

Command (m for help): nPartition type:p primary (1 primary, 0 extended, 3 free)e extendedSelect (default p):Using default response pPartition number (1‐4, default 2):Using default value 2First sector (2099200‐15523839, default 2099200):Using default value 2099200Last sector, +sectors or +size{K,M,G} (2099200‐15523839, default 15523839): +4GCommand (m for help): tPartition number (1‐4): 2Hex code (type L to list codes): 83

Command (m for help): nPartition type:p primary (1 primary, 0 extended, 3 free)e extendedSelect (default p):Using default response pPartition number (1‐4, default 2):Using default value 2First sector (2099200‐15523839, default 2099200):Using default value 2099200Last sector, +sectors or +size{K,M,G} (2099200‐15523839, default 15523839): +4GCommand (m for help): tPartition number (1‐4): 2Hex code (type L to list codes): 83

漢陽大學校

External Storage 파티션 생성External Storage 파티션 생성

38

Command (m for help): nPartition type:p primary (2 primary, 0 extended, 2 free)e extendedSelect (default p):Using default response pPartition number (1‐4, default 3):Using default value 3First sector (10487808‐15523839, default 10487808):Using default value 10487808Last sector, +sectors or +size{K,M,G} (10487808‐15523839, default 15523839):Using default value 15523839Command (m for help): tPartition number (1‐4): 3Hex code (type L to list codes): 83

Command (m for help): nPartition type:p primary (2 primary, 0 extended, 2 free)e extendedSelect (default p):Using default response pPartition number (1‐4, default 3):Using default value 3First sector (10487808‐15523839, default 10487808):Using default value 10487808Last sector, +sectors or +size{K,M,G} (10487808‐15523839, default 15523839):Using default value 15523839Command (m for help): tPartition number (1‐4): 3Hex code (type L to list codes): 83

漢陽大學校

파티션 생성 확인 및 저장파티션 생성 확인 및 저장

39

Command (m for help): vPartition 1: previous sectors 2099199 disagrees with total 2098565Partition 2: previous sectors 10487807 disagrees with total 10476633Partitions 3: cylinder 967 greater than maximum 966Partition 3: previous sectors 15523839 disagrees with total 15521165Remaining 2047 unallocated 512‐byte sectorsCommand (m for help): wThe partition table has been altered!Calling ioctl() to re‐read partition table.WARNING: Re‐reading the partition table failed with error 16: Device or resource busy.The kernel still uses the old table. The new table will be used atthe next reboot or after you run partprobe(8) or kpartx(8)WARNING: If you have created or modified any DOS 6.xpartitions, please see the fdisk manual page for additionalinformation.Syncing disks.

Command (m for help): vPartition 1: previous sectors 2099199 disagrees with total 2098565Partition 2: previous sectors 10487807 disagrees with total 10476633Partitions 3: cylinder 967 greater than maximum 966Partition 3: previous sectors 15523839 disagrees with total 15521165Remaining 2047 unallocated 512‐byte sectorsCommand (m for help): wThe partition table has been altered!Calling ioctl() to re‐read partition table.WARNING: Re‐reading the partition table failed with error 16: Device or resource busy.The kernel still uses the old table. The new table will be used atthe next reboot or after you run partprobe(8) or kpartx(8)WARNING: If you have created or modified any DOS 6.xpartitions, please see the fdisk manual page for additionalinformation.Syncing disks.

漢陽大學校

파티션 포맷파티션 포맷

40

$ partprobe /dev/sdb$ mkfs.vfat ‐F 32 ‐n boot /dev/sdb1$ mkfs.ext4 ‐L root /dev/sdb2$ mkfs.ext4 ‐L root /dev/sdb3

$ partprobe /dev/sdb$ mkfs.vfat ‐F 32 ‐n boot /dev/sdb1$ mkfs.ext4 ‐L root /dev/sdb2$ mkfs.ext4 ‐L root /dev/sdb3

漢陽大學校

Android용 커널 빌드Android용 커널 빌드

소스 다운

빌드 환경 설정 및 커널 빌드

41

$ git clone git://git.iveia.com/xilinx2/android/kernel/zynq.git$ git clone git://git.iveia.com/xilinx2/android/kernel/zynq.git

$ cd zynq$ export PATH=/opt/Xilinx/14.7/ISE_DS/EDK/gnu/arm/lin/bin:$PATH$ export ARCH=arm$ export CROSS_COMPILE=arm‐xilinx‐linux‐gnueabi‐$ make xilinx_zynq_android_defconfig$ make uImage modules UIMAGE_LOADADDR=0x8000

$ cd zynq$ export PATH=/opt/Xilinx/14.7/ISE_DS/EDK/gnu/arm/lin/bin:$PATH$ export ARCH=arm$ export CROSS_COMPILE=arm‐xilinx‐linux‐gnueabi‐$ make xilinx_zynq_android_defconfig$ make uImage modules UIMAGE_LOADADDR=0x8000

漢陽大學校

Device Tree 수정Device Tree 수정

/arch/arm/boot/dts/zynq-zc706.dts 파일 수정 qspi0: spi@e000d000 섹션에 status = “disabled”; 추가

42

......qspi0: spi@e000d000 {

compatible = "xlnx,ps7‐qspi‐1.00.a";status = "disabled";reg = <0xE000D000 0x1000>;interrupts = <0 19 4>;interrupt‐parent = <&gic>;speed‐hz = <200000000>;bus‐num = <1>;

......

......qspi0: spi@e000d000 {

compatible = "xlnx,ps7‐qspi‐1.00.a";status = "disabled";reg = <0xE000D000 0x1000>;interrupts = <0 19 4>;interrupt‐parent = <&gic>;speed‐hz = <200000000>;bus‐num = <1>;

......

漢陽大學校

Device Tree Blob 생성Device Tree Blob 생성

43

$ scripts/dtc/dtc ‐I dts ‐O dtb ‐o devicetree.dtb \arch/arm/boot/dts/zynq‐zc706.dts$ scripts/dtc/dtc ‐I dts ‐O dtb ‐o devicetree.dtb \arch/arm/boot/dts/zynq‐zc706.dts

漢陽大學校

Android 소스 다운Android 소스 다운

44

$ curl https://dl‐ssl.google.com/dl/googlesource/git‐repo/repo > ~/bin/repo$ chmod a+x ~/bin/repo$ mkdir ‐p ~/scm/android$ cd ~/scm/android$ repo init ‐u git://git.iveia.com/xilinx2/android/platform/manifest.git ‐b zynq‐android‐2.0$ repo sync$ repo forall ‐c git checkout aosp/aosp/master

$ curl https://dl‐ssl.google.com/dl/googlesource/git‐repo/repo > ~/bin/repo$ chmod a+x ~/bin/repo$ mkdir ‐p ~/scm/android$ cd ~/scm/android$ repo init ‐u git://git.iveia.com/xilinx2/android/platform/manifest.git ‐b zynq‐android‐2.0$ repo sync$ repo forall ‐c git checkout aosp/aosp/master

漢陽大學校

Android Build 환경 설정Android Build 환경 설정

패키지 설치 및 라이브러리 경로 설정

45

$ sudo apt‐get install git gnupg flex bison gperf build‐essential \zip curl libc6‐dev libncurses5‐dev:i386 x11proto‐core‐dev \libx11‐dev:i386 libreadline6‐dev:i386 libgl1‐mesa‐glx:i386 \libgl1‐mesa‐dev g++‐multilib mingw32 tofrodos \python‐markdown libxml2‐utils xsltproc zlib1g‐dev:i386 \libswitch‐perl

$ sudo ln ‐s /usr/lib/i386‐linux‐gnu/mesa/libGL.so.1 /usr/lib/i386‐linux‐gnu/libGL.so

$ sudo apt‐get install git gnupg flex bison gperf build‐essential \zip curl libc6‐dev libncurses5‐dev:i386 x11proto‐core‐dev \libx11‐dev:i386 libreadline6‐dev:i386 libgl1‐mesa‐glx:i386 \libgl1‐mesa‐dev g++‐multilib mingw32 tofrodos \python‐markdown libxml2‐utils xsltproc zlib1g‐dev:i386 \libswitch‐perl

$ sudo ln ‐s /usr/lib/i386‐linux‐gnu/mesa/libGL.so.1 /usr/lib/i386‐linux‐gnu/libGL.so

漢陽大學校

Oracle JDK6 다운로드Oracle JDK6 다운로드

http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase6-419409.html#jdk-6u45-oth-JPR

46

漢陽大學校

JDK 설치JDK 설치

Oracle JDK6 설치

환경 설정

47

$ chmod +x jdk‐6u45‐linux‐*$ mkdir /usr/lib/jvm$ cp jdk‐6u45‐linux‐x64.bin /usr/lib/jvm/$ cd /usr/lib/jvm/$ ./jdk‐6u45‐linux‐x64.bin

$ chmod +x jdk‐6u45‐linux‐*$ mkdir /usr/lib/jvm$ cp jdk‐6u45‐linux‐x64.bin /usr/lib/jvm/$ cd /usr/lib/jvm/$ ./jdk‐6u45‐linux‐x64.bin

$ update‐alternatives ‐‐install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.6.0_45/bin/java" 1 $ update‐alternatives ‐‐install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk1.6.0_45/bin/javac" 1$ update‐alternatives ‐‐install "/usr/bin/javaws" "javaws" "/usr/lib/jvm/jdk1.6.0_45/bin/javaws" 1 

$ update‐alternatives ‐‐config java $ update‐alternatives ‐‐config javac$ update‐alternatives ‐‐config javaws

$ update‐alternatives ‐‐install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.6.0_45/bin/java" 1 $ update‐alternatives ‐‐install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk1.6.0_45/bin/javac" 1$ update‐alternatives ‐‐install "/usr/bin/javaws" "javaws" "/usr/lib/jvm/jdk1.6.0_45/bin/javaws" 1 

$ update‐alternatives ‐‐config java $ update‐alternatives ‐‐config javac$ update‐alternatives ‐‐config javaws

漢陽大學校

Android 빌드Android 빌드

48

$ . build/envsetup.sh$ lunch full‐eng$ make ‐j<N>

$ . build/envsetup.sh$ lunch full‐eng$ make ‐j<N>

漢陽大學校

Makefile.zynq 생성Makefile.zynq 생성

Makefile.zynq을 다음과 같이 편집

49

OUT_DIR:=out/target/product/genericROOT_IMG:=root.imgROOTFS:=rootfsROOT_DIRS=lib/modules tmp media mnt sdcard.PHONY: dummy$(ROOT_IMG): dummy

rm ‐rf $@sudo rm ‐rf $(ROOTFS)cp ‐r $(OUT_DIR)/root $(ROOTFS)cp ‐r $(OUT_DIR)/system $(ROOTFS)cd $(ROOTFS) && mkdir ‐p $(ROOT_DIRS)sudo chown ‐R root:root $(ROOTFS)sudo genext2fs ‐d $(ROOTFS) ‐b $$((250*1024)) ‐m 0 ‐N 

$$((64*1024)) $(ROOT_IMG)sudo chown $(shell id ‐u):$(shell id ‐g) $(ROOT_IMG)

# Phony target forces the rootfs image file to be rebuilt on each makedummy:

OUT_DIR:=out/target/product/genericROOT_IMG:=root.imgROOTFS:=rootfsROOT_DIRS=lib/modules tmp media mnt sdcard.PHONY: dummy$(ROOT_IMG): dummy

rm ‐rf $@sudo rm ‐rf $(ROOTFS)cp ‐r $(OUT_DIR)/root $(ROOTFS)cp ‐r $(OUT_DIR)/system $(ROOTFS)cd $(ROOTFS) && mkdir ‐p $(ROOT_DIRS)sudo chown ‐R root:root $(ROOTFS)sudo genext2fs ‐d $(ROOTFS) ‐b $$((250*1024)) ‐m 0 ‐N 

$$((64*1024)) $(ROOT_IMG)sudo chown $(shell id ‐u):$(shell id ‐g) $(ROOT_IMG)

# Phony target forces the rootfs image file to be rebuilt on each makedummy:

漢陽大學校

root.img 파일 생성root.img 파일 생성

genext2fs 설치

root.img 생성

root.img 마운트 및 복사

50

$ sudo apt‐get install genext2fs$ sudo apt‐get install genext2fs

$ make ‐f Makefile.zynq$ make ‐f Makefile.zynq

$ mkdir tmp1$ mkdir tmp2$ sudo mount ‐t ext4 /dev/sdb2 tmp2$ sudo mount ‐o loop root.img tmp$ sudo cp ‐r tmp1/* tmp2/

$ mkdir tmp1$ mkdir tmp2$ sudo mount ‐t ext4 /dev/sdb2 tmp2$ sudo mount ‐o loop root.img tmp$ sudo cp ‐r tmp1/* tmp2/

漢陽大學校

ramdisk 생성ramdisk 생성

ramdisk.image 다운로드 $ wget

http://dmclab.hanyang.ac.kr/wikidata/download/android/ramdisk.image

ramdisk.image 마운트 및 수정

umount 및 uramdisk.image.gz 생성

51

$ sudo mount ‐o loop ramdisk.image tmp$ sudo mount ‐o loop ramdisk.image tmp

$ sudo umount tmp$ gzip ramdisk.image$ mkimage ‐A arm ‐T ramdisk ‐C gzip ‐d ramdisk.image.gz uramdisk.image.gz

$ sudo umount tmp$ gzip ramdisk.image$ mkimage ‐A arm ‐T ramdisk ‐C gzip ‐d ramdisk.image.gz uramdisk.image.gz

漢陽大學校

부팅부팅

microSD의 boot파티션에 다음 파일 적재 BOOT.bin: 리눅스 부팅에 사용한것과 동일 uImage: Android용 linux kernel image devicetree.dtb: 수정된 device tree 파일 uramdisk.image.gz init.sh

microSD의 android root partition에 root file system 생성

52

漢陽大學校

ReferenceReference

http://www.wiki.xilinx.com/Build+Kernel http://www.wiki.xilinx.com/Building+Android+BSP+on+ZC702 http://www.wiki.xilinx.com/Android+4.2.2+On+Zynq+Getting+Started+

Guide http://www.wiki.xilinx.com/Building+Android+4.2.2+BSP+on+ZC702 http://www.wiki.xilinx.com/Build+and+Modify+a+Rootfs

53

Recommended