分类: 嵌入式
2010-05-27 11:56:52
1、安装虚拟机、新建虚拟机
磁盘大小分配20G应该就够了。
2、安装Ubuntu
新建的虚拟机下插入iso镜像,启动虚拟机安装Ubuntu。安装完后将iso镜像弹出、重启。
3、安装 vmtools及其他补丁
虚拟机安装install vmtools,将打开的文件拷贝到/tmp临时文件夹中,解压缩并安装 ./vmware-install.pl,完成后重启。
重启后升级 Ububtu:apt-get
update
安装vi编辑器:apt-get install vim
安装tftpd-hpa:apt-get install tftpd-hpa //tftp4、修改通过root用户登录。安装vsftpd。(参考另外文章)
5、安装目标Linux
sudo mkdir /camera/mv_pro_5.0
cd /home/ss
chmod 777
mvl_5_0_0_demo_lsp_setuplinux_02_10_00_14.bin
chmod 777
mvl_5_0_0801921_demo_sys_setuplinux.bin
./mvl_5_0_#_demo_sys_setuplinux.bin
安装目录设为 /camera/mv_pro_5.0
./mvl_5_0_0_demo_lsp_setuplinux_#_#_#_#.bin
安装目录设为 /camera/mv_pro_5.0
转到/opt /mv_pro_5.0解 压里面的两个文件
sudo tar -zxvf
mvltools5_0_0801921_update.tar.gz
解压要几分钟 时间
sudo tar -zxvf
DaVinciLSP_02_10_00_14.tar.gz
6、安装
DVSDK软件包
先给权限chmod。
./dvsdk_setuplinux_2_10_01_18.bin
安装 在/camera/ss/dvsdk_2_10_01_18
./xdctools_setuplinux_3_15_01_59.bin
安装 在/camera/ss/dvsdk_2_10_01_18/xdctools_3_15_01_59
./psp_#_#_#_#.bin
安装 在/camera/ss/dvsdk_2_10_01_18/
host $ tar -zxvf
psp_#_#_#_#.tar.gz
完了删除安装文件。
打补丁,将dvsdk_2_10_00_16_patch.tgz解
压在dvsdk下。
为主 机设置工作环境
cd ~/dvsdk_2_10_01_18
vi Rules.make
检查其中的设置,确保和实际路径相符,如:
DEMO_INSTALL_DIR=$(DVSDK_INSTALL_DIR)/dvsdk_demos_2_10_00_17
7、安装
NFS文件系统
安装NFS服 务包:
sudo apt-get install
nfs-kernerl-server
配置文件:
sudo gedit /etc/exports
加入下面一 行:
/camera/ss/ipnc/target/filesys
*(rw,no_root_squash,no_all_squash,sync)
激活后重启 NFS服务:
sudo /usr/sbin/exports -av
sudo
/etc/init.d/nfs-kernerl-server restart
查看防火墙状态:
sudo iptables status
关防火墙:
sudo iptables -F
10、建立 开发环境
Vi /root/.bashrc (最好在普通用户和Root用户都建立)
在最后加入下 面命名:
export PATH="/camera/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/bin:/camera/mv_pro_5.0/montavista/pro/bin:/camera/mv_pro_5.0/montavista/common/bin:$PATH"
运行:
source ~/.bashrc
使环境变量生 效。
在命名行输入 arm+[tab]会 出现交叉编译工具。
root@ss-desktop:/camera/ss/dvsdk_2_10_01_18#
arm
arm2hpdl arm_v5t_le-gprof arm_v5t_le-objcopy
arm_v5t_le-addr2line arm_v5t_le-initdconfig arm_v5t_le-objdump
arm_v5t_le-ar arm_v5t_le-ksymoops arm_v5t_le-prelink
arm_v5t_le-as arm_v5t_le-ld arm_v5t_le-prelink-rtld
arm_v5t_le-c++ arm_v5t_le-ldconfig arm_v5t_le-ranlib
arm_v5t_le-c++filt arm_v5t_le-ldd arm_v5t_le-readelf
arm_v5t_le-cpp arm_v5t_le-libindex arm_v5t_le-shellconfig
arm_v5t_le-g++ arm_v5t_le-libopt arm_v5t_le-size
arm_v5t_le-gcc arm_v5t_le-libtoolize arm_v5t_le-strings
arm_v5t_le-gcov arm_v5t_le-nm arm_v5t_le-strip
11、安装 LSP支持包
方法一:
复制 MontaVista Linux Support Package到工作目录中,里面包含了Davinci的 驱动。
cp -R
/camera/mv_pro_5.0/montavista/pro/devkit/lsp/ti-davinci/linux-2.6.18_pro500/*
/camera/ss/ipnc/ti-davinci/
方法二:(用此方法)
将lsp_ipnc_dm36x_0.7.0.tgz
12、建立文件系统文件夹
在/camera/ss/ipnc/下 解压
ipnc_app_dm365_priv_0.7.0.tgz
ipnc_app_dm365_open_0.7.0.tgz
ipnc_app_dm365_aewb_0.7.0.tgz
修改/camera/ss/ipnc/下Rules.make的路径。
HOME :=
/camera/ss/ipnc
DVSDK_BASE_DIR
:= /camera/ss/dvsdk_2_10_01_18
TFTP_HOME :=
/var/lib/tftpboot
MVTOOL_DIR := /camera/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le
TARGET_FS :=
$(HOME)/target/filesys
KERNELDIR :=
$(HOME)/ti-davinci
BASE_DIR := $(HOME)/av_capture/build
在/camera/ss/ipnc/下新建target,在其下建立filesys、cramfs文件夹,将cramfsImage_ipnc_dm365_0.7.0拷贝到target下。
root@ss-desktop:/camera/ss/ipnc/target# ls13、然后可运行:
rm
-rf /camera/ss/ipnc/target/filesys/root/.esm*
rm
-rf /camera/ss/ipnc/target/filesys/usr/local/etc/*
make
-s sysall
rm
-rf /camera/ss/ipnc/target/rdmnt
rm
/camera/ss/ipnc/target/cramfsUby00
mkdir
/camera/ss/ipnc/target/rdmnt
cp
-av /camera/ss/ipnc/target/filesys/*
/camera/ss/ipnc/target/rdmnt
sudo
mkcramfs /camera/ss/ipnc/target/rdmnt /camera/ss/ipnc/target/cramfsUby00
cp
/camera/ss/ipnc/ti-davinci/arch/arm/boot/uImage /home/ss/uImageUby00
#/var/lib/tftpboot/uImage_00
cp
/camera/ss/ipnc/target/cramfsUby00 /home/ss/cramfsUby00
还有:
# make –s lsp
//incrementally build LSP
# make –s
lspclean //clean all generated files in LSP
# make –s lspall
//clean and rebuild all LSP
# make –s dvsdk
//incrementally build DVSDK
# make –s
dvsdkclean //clean all generated files in DVSDK
# make –s
dvsdkall //clean and rebuild
all DVSDK
# make –s
//incrementally build AV server and IPNC APP
# make –s clean
//clean all generated files in AV
server and IPNC APP
# make –s all
//clean and
rebuild all AV Server and IPNC APP
# make –s sys
//incrementally
build LSP, DVSDK, AV server and IPNC APP
# make –s sysclean
//clean all generated files LSP, DVSDK, AV server and IPNCAPP
# make –s sysall //clean and rebuild all LSP, DVSDK, AV
server and IPNC APP