“EMB-7541”的版本间的差异
来自ARM Wiki
Tangdapeng(讨论 | 贡献) (清空页面) |
Caixiaoyan(讨论 | 贡献) (→接口概览) |
||
(未显示3个用户的113个中间版本) | |||
第1行: | 第1行: | ||
+ | =='''资源特性'''== | ||
+ | [[File:7541-概览图.jpg|thumb|frameless|300px|概览]] | ||
+ | [[File:7541主视图.jpg|thumb|frameless|300px|正面]] | ||
+ | [[File:7541侧视图.jpg|thumb|frameless|300px|侧面]] | ||
+ | * CPU:HiSilicon Hi3519A 2xA53双核处理器 | ||
+ | * Memory:板载2GB DDR4 | ||
+ | * Storage:板载16GB iNAND Flash,1x TF卡槽 | ||
+ | * Ethernet: 1 x LAN,10/100/1000Mbps | ||
+ | * Input:CMOS Sensor:(根据镜头规格设计转接板) | ||
+ | * 2路3000 x 3000@30fps 输入,输出3840 x 2160@30fps | ||
+ | * 4路1080 x 1920@30fps 输入,输出3840 x 2160@30fps | ||
+ | *Display:1xHDMI | ||
+ | *Touch:电容或电阻屏 | ||
+ | * USB Host: 1x USB3.0,1x OTG | ||
+ | * COM: 1x COM232;1x COM485;1x debug | ||
+ | * Audio:1xMic;1xLine out;1xMic(3.5mm四节耳机孔) | ||
+ | * Other I/O: 2xDI,1xDO;2xGyroscope;支持GPIO,I2C,SPI扩展 | ||
+ | * System Control:1xRST BUTTON,1xPWR LED | ||
+ | * RTC:支持 | ||
+ | * Watchdog:支持 | ||
+ | * Power Supply:单电源+ 12V DC | ||
+ | * Temperature:Work :-20℃ ~ +65℃, Storage :-40℃ ~ +85℃ | ||
+ | * Humidity:5% ~ 95%相对湿度,无冷凝 | ||
+ | * Size: 120mm x 80 mm | ||
+ | * OS: Linux | ||
+ | =='''接口布局和尺寸'''== | ||
+ | |||
+ | ===接口概览=== | ||
+ | [[File:正面接口布局.jpg |frameless|700px|EMB-7541 正面接口布局]] | ||
+ | [[File:侧面接口布局.jpg |frameless|700px|EMB-7541 侧面接口布局]] | ||
+ | |||
+ | ===接口引脚定义=== | ||
+ | :*[[EMB-7541-COM|串口,DI/DO(COM0,J1)]] | ||
+ | :*[[EMB-7541-USB|USB接口(USB,OTG)]] | ||
+ | :*[[EMB-7541-LAN|LAN接口(LAN)]] | ||
+ | :*[[EMB-7541-SPEAKER|音频接口(HP,MIC)]] | ||
+ | :*[[EMB-7541-RESET|复位按键(RESET)]] | ||
+ | :*[[EMB-7541-PWR&LED|电源及LED指示灯(LED)]] | ||
+ | :*[[EMB-7541-HDMI|HDMI接口]] | ||
+ | :*[[EMB-7541-Sensor|摄像头接口(J12,J13,J14)]] | ||
+ | :*[[EMB-7541-TF|TF卡接口(TF)]] | ||
+ | :*[[EMB-7541-J2|扩展接口(J2)]] | ||
+ | :*[[EMB-7541-JTAG|JTAG调试接口(JTAG)]] | ||
+ | :*[[EMB-7541-J7&J8|自动光圈调节接口(J7,J8)]] | ||
+ | :*[[EMB-7541-JFP|前面板接口(JFP)]] | ||
+ | |||
+ | ===传感器接口转接板定义=== | ||
+ | [[File:EMB-7540转接板.jpg |thumb|frameless|300px|EMB-7541 转接板]] | ||
+ | :*[[EMB-7540-CAM|camera接口]] | ||
+ | |||
+ | ===机械尺寸=== | ||
+ | |||
+ | [[File:EMB-7541尺寸.jpg|frameless|500px|]] | ||
+ | |||
+ | =='''下载'''== | ||
+ | :*系统烧录工具下载 | ||
+ | ::*[http://norcord.com:8070/f/f0050417373f4042bc1a/?dl=1 HiTool 下载] | ||
+ | :*系统镜像文件下载 | ||
+ | ::*[http://norcord.com:8070/d/395d28214a544f6dadd2/ 系统镜像文件 下载] | ||
+ | :*Sample源码下载(包括SDK库) | ||
+ | ::*[ Sample源码 下载] | ||
+ | |||
+ | =='''烧录方法'''== | ||
+ | |||
+ | ==='''HiTool 烧录方法'''=== | ||
+ | ====适用场景==== | ||
+ | :*适用于一键烧写所有程序镜像到单板flash 上的场景、单板已有 boot 可按地址烧写其他程序镜像到单板 flash 上的场景,以及在空板上只烧写 boot 到单板 flash 上的场景。 | ||
+ | :* 本文只介绍 <eMMC烧录>方法。 | ||
+ | ====环境部署==== | ||
+ | |||
+ | :HiBurn 工具烧写的环境准备如下: | ||
+ | :*步骤 1. PC 与单板之间连接好串口、网线,且因工具烧写需要涉及到与 bootrom 交互,故单板硬件上 bootrom_sel 需要设置为 1,从 bootrom 启动。 | ||
+ | |||
+ | :*步骤 2. 下载HiTool http://norcord.com:8070/f/d711a3ed07054d058c18/?dl=1 把HiTool-BVT-5.0.28.zip 拷贝到 PC 上(PC 要求安装 Win7、XP 操作系统)的某个本地硬盘。在 HiTool-XXX-4.0.15 及以后的版本已经集成了 jre,无需单独安装 JRE,如上面链接提供的版本。如果是老版本工具,请预先安装的 32 位的 jre1.6(如 jre-6u1-windows-i586-p),否则HiTool 可能无法运行。 | ||
+ | ::链接如下:http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase6-419409.html | ||
+ | ::查看当前 PC 安装的 JRE 版本号,可以通过在开始->运行->键入 cmd 中输入 java –version 查看当前已安装的 JRE 版本号,若当前版本为 1.6.0_xx 即可,若当前版本号高于 1.6,则请打开 HiTool 目录下的 HiTool.ini,将其中-XX:MaxTenuringThreshold=31 参数值改为-XX:MaxTenuringThreshold=15,即可支持 1.7 及更高版本的 JRE。。 | ||
+ | |||
+ | :*步骤 3. 解压 HiTool-BVT-X.X.X.zip,双击工具目录下的 HiTool.exe,打开 HiTool 工具,如图 1-1 所示。 | ||
+ | ::[[文件:EMB-7540-HiBurn1-1.jpg|300px| 图1-1 从 HiTool 工具目录打开 HiTool 工具]] | ||
+ | |||
+ | :*步骤 4. 选择单板对应的芯片型号,如图 1-2 所示。 | ||
+ | ::[[文件:7541_burn1.PNG|500px| 图1-2 选择单板对应的芯片型号]] | ||
+ | |||
+ | :*步骤 5. 在欢迎页中选择 HiBurn 工具, 如图 1-3 所示。 | ||
+ | ::[[文件:7541_burn2.PNG|500px| 图1-3 选择 HiBurn 工具]] | ||
+ | |||
+ | :*步骤 6. 参数配置,选择连接单板所用的串口,选择 PC 端使用的网络 IP 地址,配置好单板的MAC 地址、IP 地址、子网掩码以及网关,配置如图 1-4 所示。 | ||
+ | ::[[文件:7541_burn3.png|500px| 图1-4 参数设置]] | ||
+ | <!-- | ||
+ | :*步骤 7. 可选步骤,Hi3516CV300/Hi3559AV100 芯片支持 USB 裸烧,Hi3559V100/Hi3556V100 芯片支持 USB 非裸烧,需要提前在 Windows 平台的 PC 机上,安装好指定的驱动,安装方法如下: | ||
+ | ::1.从 http://zadig.akeo.ie 上下载 zadig.exe 文件,请根据自己的操作系统下载相应的 exe 执行文件,当前最新版本如下(请以实际为准): | ||
+ | :::*zadig_xp_2.2.exe | ||
+ | :::*zadig_2.2.exe | ||
+ | :::以 win7 系统下驱动安装为例(XP 系统下驱动安装与此相同)。 | ||
+ | |||
+ | ::2.打开 zadig_2.2.exe 文件,选择 Options->List All Devices,将 List All Devices 勾上,如图 1-5 所示。 | ||
+ | ::[[文件:EMB-7540-HiBurn1-5.jpg|500px| 图1-5 勾选 List All Devices]] | ||
+ | |||
+ | ::3.单板上电 ,在 红色 方 框 位 置 选 择正确 的 设备 , 然 后在 蓝色 方 框 内选 择驱动 libusbK,点击“Install Driver”或者“Replace Driver”,如图 1-6 所示。(单板上电时,需要进入 USB 模式) | ||
+ | ::[[文件:EMB-7540-HiBurn1-6.jpg|500px| 图1-6 安装 libusbK]] | ||
+ | |||
+ | ::4.LibusbK 安装完成之后,此时单板已自动与主机断开连接,设备管理器已检测不到单板的存在,单板需要重新上电,然后再安装驱动 libusb-win32,安装方法同 libusbK 安装方法。 | ||
+ | ::[[文件:EMB-7540-HiBurn1-7.jpg|500px| 图1-7 安装 libusb-win32]] | ||
+ | |||
+ | ::5.LibusbK 和 libusb-win32 安装完成之后,打开设备管理器,单板重新上电,查看驱动是否安装正确,如图 1-8 为正确安装后的状态。 | ||
+ | ::[[文件:EMB-7540-HiBurn1-8.jpg|500px| 图1-8 驱动正确安装后的设备管理器]] | ||
+ | --> | ||
+ | |||
+ | ====eMMC烧录==== | ||
+ | |||
+ | =====适用场景===== | ||
+ | :适用场景如下:只适用于 eMMC 烧写,不管单板上有没有 boot 都适用,可实现一键烧写所有镜像。 | ||
+ | |||
+ | =====烧写步骤===== | ||
+ | :具体烧写步骤如下: | ||
+ | :*步骤 1. 切换到“烧写 eMMC”页签,如图 5-1 所示。 | ||
+ | ::[[文件:7541_burn4.png|500px| 图5-1 eMMC 烧写界面]] | ||
+ | :::说明: | ||
+ | ::::切换“默认采用 XML 所在路径”的勾选状态,若勾选,则优先在 XML 路径下查找该分区文件。若不勾选,则优先采用绝对路径查找该文件,若找不到,再尝试以在 XML 所在目录下查找该文件,该状态默认被勾选。 | ||
+ | ::::XML 是一个配置文件用于保存分区表信息的,可以将编辑的分区表使用工具上的 Save 按钮保存成一个 XML 文件,下次打开工具时,将 XML 导入进来,分区表信息就直接加载进来。 | ||
+ | |||
+ | :*步骤 2. 配置单板分区信息,点击“浏览”,可选择已设置好的分区表信息,载入工具中,如图 5-2 所示界面。 | ||
+ | ::[[文件:7541_burn5.PNG|500px|图5-2 配置单板分区信息]] | ||
+ | |||
+ | :*步骤 3. 准备单板环境。连接单板的串口和网口,如果单板处于通电状态,给单板下电 。 | ||
+ | |||
+ | :*步骤 4. 烧写单板,点击烧写按钮【Burn】。 | ||
+ | |||
+ | :*步骤 5. 给单板上电,进入烧写过程,等待烧写完成。 | ||
+ | ::*烧写过程的信息会在控制台中显示。 | ||
+ | ::*串口选择是否正确。 | ||
+ | ::*IP 地址设置是否正确,地址是否被占用。 | ||
+ | ::*是否有短接单板上的自举跳线。 | ||
+ | |||
+ | :*步骤 6. 烧写完成,连接终端工具,重启单板。 | ||
+ | |||
+ | ==='''U盘/TF卡升级'''=== | ||
+ | |||
+ | =====适用场景===== | ||
+ | :sd卡烧录简单快速,可用于裸板烧录;U盘烧录必须在有uboot情况下。 | ||
+ | |||
+ | =====烧写步骤===== | ||
+ | :具体烧写步骤如下: | ||
+ | :*步骤 1. 格式化 SD卡(U盘)为 FAT32 格式,若 SD 卡有多个分区时,升级包必须放在第一个分区,否则扫描不到升级包。 | ||
+ | |||
+ | :*步骤 2. 从上面链接处下载系统烧录镜像,把各镜像文件名更改为:u-boot.bin,kernel,rootfs.ext4。 | ||
+ | |||
+ | :*步骤 3. 新建config文件(若下载镜像文件中有config则跳过该步骤),config文件内容如下: | ||
+ | setenv bootargs 'mem=256M console=ttyAMA0,115200n8 root=/dev/mmcblk0p3 rootfstype=ext4 rw rootwait blkdevparts=mmcblk0:1M(u-boot.bin),4M(kernel),32M(rootfs.ext4),-' | ||
+ | setenv bootcmd 'mmc read 0 0x21000000 0x800 0x2000;bootm 0x21000000' | ||
+ | :*步骤 4. 选择升级烧录模式,把JFP(JFP)的3(UPDATE),4(GND)脚用跳帽短接. | ||
+ | :*步骤 5. 把u-boot.bin,kernel,rootfs.ext4,config文件拷贝到SD卡或U盘中(目标文件sample_app.tar.gz也可以拷贝进来,便于系统启动后自动解压sample_app),插入SD卡,上电启动,等待5-20秒即可烧录成功,可在串口中看到如下打印: | ||
+ | ::[[文件:sd_burn_3519a.PNG]] | ||
+ | :注意事项: | ||
+ | u-boot 镜像名称必须为 u-boot.bin。 | ||
+ | 裸烧会自动保存 config 中的 bootargs 和 bootcmd 环境变量,没有 config 文件时,仅会烧写 bootrom 读取的 u-boot 镜像。 | ||
+ | 烧录成功后记得把JFP的3,4引脚跳帽去掉,否则下次启动又会进入升级烧录模式。 | ||
+ | |||
+ | =='''例程环境搭建'''== | ||
+ | ====工具链安装==== | ||
+ | :[http://norcord.com:8070/f/78c2fbce854b478cb66d/?dl=1 下载]工具链arm-himix200-linux.tgz安装包。 | ||
+ | |||
+ | :*1) 将安装包arm-himix200-linux.tgz拷贝到安装了ubuntu环境的PC机上,在PC机的shell中执行下面步骤进行安装: | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | $ tar -zxf arm-himix200-linux.tgz | ||
+ | $ chmod +x arm-himix200-linux.install | ||
+ | $ sudo ./arm-himix200-linux.install | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | <!-- | ||
+ | :*2) 安装 arm-none-eabi 交叉编译器: | ||
+ | ::解压 tar -zxf gcc-arm-none-eabi-4_9-2015q3.tgz,运行 chmod +x gcc-arm-none-eabi-4_9-2015q3.install,然后运行./gcc-arm-none-eabi-4_9-2015q3.install 即可。 | ||
+ | --> | ||
+ | :*2) 执行 source /etc/profile 或者重启电脑让环境变量生效。注意,如果不重启电脑,仅仅source一下,环境变量只在当前shell里生效。 | ||
+ | |||
+ | ====sample环境搭建==== | ||
+ | <!-- | ||
+ | :如果用户是imx477的摄像头,[http://android1.norco.com.cn:8080/Hi3559a-General/samples/sample_imx477.tar.bz2 下载]sample_imx477.tar.bz2文件。 | ||
+ | :如果用户是imx377的摄像头,[http://android1.norco.com.cn:8080/Hi3559a-General/samples/sample_imx377.tar.bz2 下载]sample_imx377.tar.bz2文件。 | ||
+ | :将该文件通过U盘拷贝或者nfs网络拷贝到设备中,在设备串口终端执行下列命令进行安装,然后按照[[#Demo使用 | Demo使用]]例程。这里仅以索尼imx477的例程举例,如果是imx377的摄像头,将下面的名字换成sample_imx377.tar.bz2即可。 | ||
+ | :*1) U盘拷贝安装。 | ||
+ | :先将下载的sample_imx477.tar.bz2文件放在U盘根目录,U盘插上设备的USB口,在设备终端执行下面命令: | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~# mount -t vfat /dev/sda1 /mnt/usb | ||
+ | ~# cd /root/ | ||
+ | ~# tar -jxf /mnt/usb/sample_imx477.tar.bz2 | ||
+ | </syntaxhighlight> | ||
+ | :*2) nfs网络拷贝安装。 | ||
+ | :nfs搭建方式见[[#nfs配置和网络 | nfs配置和网络]],下载sample_imx477.tar.bz2文件放在PC机的/home/nfs目录,在设备终端执行下面命令(PC的IP是192.168.8.xx): | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~# ifconfig eth0 192.168.8.xxx #设备IP和下面电脑IP,192.168.8.xx在同一网段 | ||
+ | ~# mount -t nfs -o nolock -o tcp 192.168.8.xx:/home/nfs /mnt/nfs | ||
+ | ~# cd /root/ | ||
+ | ~# tar -jxf /mnt/nfs/sample_imx477.tar.bz2 | ||
+ | </syntaxhighlight> | ||
+ | --> | ||
+ | |||
+ | =='''Demo使用'''== | ||
+ | <!-- | ||
+ | :[http://android1.norco.com.cn:8080/Hi3559a-General/samples/sample_imx477.tar.bz2 imx477目标文件][http://android1.norco.com.cn:8080/Hi3559a-General/samples/sample_imx377.tar.bz2 imx377目标文件][http://android1.norco.com.cn:8080/Hi3559a-General/samples/sample_src.tar.bz2 源码文件] | ||
+ | :注意用户需要根据自己不同摄像头下载不同的例程。 | ||
+ | --> | ||
+ | ====sample_venc(视频数据编码)==== | ||
+ | |||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~ # ./sample_venc | ||
+ | Usage : ./sample_venc [index] | ||
+ | index: | ||
+ | 0) H.265e@4K@120fps + H264e@1080p@30fps. | ||
+ | 1) H.265e@4K@60fps + H264e@4K@60fp. | ||
+ | 2) Lowdelay:H.265e@4K@30fps. | ||
+ | 3) IntraRefresh:H.265e@4K@60fps + H264e@4K@60fps. | ||
+ | 4) Qpmap:H.265e@4K + H264e@4K@60fps. | ||
+ | 5) Mjpeg@4K@60fps +Jpeg@4K. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行sample_venc (录制) 视频编码样例 | ||
+ | ::2. 使用方法: ./sample_venc [index] | ||
+ | ::3. 参数<索引> | ||
+ | ::4. 0) h265编码,4096×2160分辨率,每秒120帧 + h264编码,1920x1080分辨率,每秒30帧 | ||
+ | ::5. 1) h265编码,4096×2160分辨率,每秒60帧 + h264编码,4096×2160分辨率,每秒60帧 | ||
+ | ::6. 2) Lowdelay(低延时属性):h265编码,4096×2160分辨率,每秒30帧 | ||
+ | ::7. 3) IntraRefresh(P 帧帧内刷新):h265编码,4096×2160分辨率,每秒60帧 + h264编码,4096×2160分辨率,每秒60帧 | ||
+ | ::8. 4) Qpmap(是一种码率控制模式):h265编码,4096×2160分辨率 + h264编码,4096×2160分辨率,每秒60帧 | ||
+ | ::9. 5) Mjpeg(Mjpeg协议编码方式)的4096×2160分辨率,每秒60帧 + Jpeg(Jpeg的编码)的4096×2160分辨率 | ||
+ | |||
+ | ====sample_vdec(视频数据解码)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_vdec | ||
+ | Usage : ./sample_vdec <index> <IntfSync> | ||
+ | index: | ||
+ | 0) VDEC(H265)-VPSS-VO | ||
+ | 1) VDEC(H264)-VPSS-VO | ||
+ | 2) VDEC(JPEG->YUV)-VPSS-VO | ||
+ | 3) VDEC(JPEG->RGB) | ||
+ | IntfSync : | ||
+ | 0) VO HDMI 4K@30fps. | ||
+ | 1) VO HDMI 1080P@30fps. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | :shell 说明: | ||
+ | ::1. 运行sample_vdec (播放) 视频解码样例 | ||
+ | ::2. 使用提示: ./sample_vdec <索引> <Vo接口时序类型> | ||
+ | ::3. 参数<索引>: | ||
+ | ::4. 0) VDEC解码器输入(H265的编码格式图片/视频)--->VPSS(视频输入缓存块)--->VO(图片/视频输出) | ||
+ | ::5. 1) VDEC解码器输入(H264的编码格式图片/视频)--->VPSS(视频输入缓存块)--->VO(图片/视频输出) | ||
+ | ::6. 2) VDEC解码器输入(JPEG数据)--->VPSS(视频输入缓存块)--->VO(YUV图片/视频输出) | ||
+ | ::7. 3) VDEC解码器输入JPEG解码成RGB数据 | ||
+ | ::8. 参数<IntfSync>: | ||
+ | ::9. 0) 输出到HDMI 4096×2160分辨率,每秒30帧 | ||
+ | ::10. 1) 输出到HDMI 1920x1080分辨率,每秒30帧 | ||
+ | |||
+ | ====sample_audio(音频相关)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~ # ./sample_audio | ||
+ | |||
+ | |||
+ | /Usage:./sample_audio <index>/ | ||
+ | index and its function list below | ||
+ | 0: start AI to AO loop | ||
+ | 1: send audio frame to AENC channel from AI, save them | ||
+ | 2: read audio stream from file, decode and send AO | ||
+ | 3: start AI(VQE process), then send to AO | ||
+ | 4: start AI to AO(Hdmi) loop | ||
+ | 5: start AI to AO(Syschn) loop | ||
+ | 6: start AI to Extern Resampler | ||
+ | channel: | ||
+ | 0: mic0 input | ||
+ | 1: mic1 input | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行sample_audio 音频 (编码/解码)样例 | ||
+ | ::4. 使用提示:./sample_audio <索引> | ||
+ | ::5. 以下内容是索引对应的功能 | ||
+ | ::6. 0) 循环音频从输入到输出 (话筒功能) | ||
+ | ::7. 1) 通过音频输入发送音频帧到音频编码通道,保存起来 (录音功能) | ||
+ | ::8. 2) 从文件读取音频流,解码然后发送到输出 (播放功能) | ||
+ | ::9. 3) 通过音频输入声音质量增强处理,然后输出音频 (话筒功能) | ||
+ | ::10. 4) 循环音频输入到HDMI通道音频输出 (话筒功能) | ||
+ | ::11. 5) 循环音频输入到系统音通道音频输出 (话筒功能) | ||
+ | ::12. 6) 通过音频输入重新采样 (录音功能) | ||
+ | ::13. 音频输入通道 | ||
+ | ::14. 0) mic0输入(HeadPhone) | ||
+ | ::15. 1) mic1输入(插针) | ||
+ | |||
+ | ====sample_snap(拍照)==== | ||
+ | |||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_snap | ||
+ | Usage : ./sample_snap <index> | ||
+ | index: | ||
+ | 0)double pipe offline, normal snap. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行sample_snap 拍照 | ||
+ | ::2. 使用说明:./sample_snap <索引> | ||
+ | ::3. 参数<索引> | ||
+ | ::4. 0)双 pipe 离线模式普通拍照 | ||
+ | |||
+ | ====sample_dpu_main(Depth Process Unit,深度图)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~ # ./sample_dpu_main | ||
+ | Usage : ./sample_dpu_main <index> | ||
+ | index: | ||
+ | 0) VI->VPSS->RECT->MATCH. | ||
+ | 1) FILE->RECT->MATCH. | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_dpu_main | ||
+ | ::2. 使用方法:./sample_dpu_main <索引> | ||
+ | ::3. <索引> | ||
+ | ::4. 0) DPU(Depth Process Unit)对输入的左图像和右图像经过校正和匹配计算得出深度图 | ||
+ | ::5. 1) DPU(Depth Process Unit)对读取的文件的左图像和右图像经过校正和匹配计算得出深度图 | ||
+ | |||
+ | ====sample_avs(Any View Stitching,全景拼接)==== | ||
+ | |||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_avs | ||
+ | Usage : ./sample_avs <index> | ||
+ | index: | ||
+ | 0) 2 fisheye stitching, Normal projection. | ||
+ | 1) 4 fisheye stitching, Cube map. | ||
+ | 2) 4 pic no blend stitching. | ||
+ | 3) 2 fisheye stitching, Image stabilizing. | ||
+ | 4) Generate lut. | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_avs | ||
+ | ::2. 使用说明: ./sample_avs <index> | ||
+ | ::3. <index> | ||
+ | ::4. 0) 2个CAM 鱼眼拼接正常显示模式 | ||
+ | ::5. 1) 4个CAM 鱼眼拼接呈现立体显示效果 | ||
+ | ::6. 2) 4个CAM 图片无混合拼接 | ||
+ | ::7. 3) 目前暂不支持 | ||
+ | ::8. 4)生成LUT表 | ||
+ | |||
+ | ====sample_fisheye(鱼眼模式)==== | ||
+ | |||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~ # ./sample_fisheye | ||
+ | |||
+ | Usage : ./sample_fisheye <index> <vo intf> <venc type> | ||
+ | index: | ||
+ | 0) fisheye 360 panorama 2 half with ceiling mount. | ||
+ | 1) fisheye 360 panorama and 2 normal PTZ with desktop mount. | ||
+ | 2) fisheye 180 panorama and 2 normal dynamic PTZ with wall mount. | ||
+ | 3) fisheye source picture and 3 normal PTZ with wall mount. | ||
+ | 4) nine_lattice preview(Only images larger than or equal to 8M are supported). | ||
+ | vo intf: | ||
+ | 0) vo HDMI output, default. | ||
+ | 1) vo BT1120 output. | ||
+ | venc type: | ||
+ | 0) H265, default. | ||
+ | 1) H264. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | :shell 说明: | ||
+ | ::1. 运行 ./sample_fisheye | ||
+ | ::2. 使用说明 ./sample_fisheye <index> <vo intf> <venc type> | ||
+ | ::3. index: | ||
+ | ::4. 0) 2个“半顶装模式”的鱼眼360°全景视频 | ||
+ | ::5. 1) 2个普通“地装的PTZ”鱼眼360°全景视频 | ||
+ | ::6. 2) 2个普通“壁装的PTZ”鱼眼180°全景视频 | ||
+ | ::7. 3) 三个鱼眼原画的普通PTZ 壁装视频 | ||
+ | ::8. 4) 九格预览视频(仅支持大于或等于8m的图像) | ||
+ | ::9. vo intf: | ||
+ | ::10. 0) 默认HDMI输出 | ||
+ | ::11. 1) BT1120输出 | ||
+ | ::12. venc type: | ||
+ | ::13. 0) 默认H265编码 | ||
+ | ::14. 1) H264编码 | ||
+ | |||
+ | ====sample_vio(视频输入输出)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_vio_main | ||
+ | Usage : ./sample_vio_main <index> <intf> | ||
+ | index: | ||
+ | 0)VI(Online) - VPSS(Online) - VO. | ||
+ | 1)VI(Offline)- VPSS(Offline) - VO. LDC+DIS+SPREAD. | ||
+ | 2)VI(Offline)- VPSS(Online) - VO. Double pipe. | ||
+ | 3)VI(Online)- VPSS(Offline) - VO. Double chn. | ||
+ | 4)Resolute Ratio Switch. | ||
+ | 5)GDC - VPSS LowDelay. | ||
+ | 6)Double WDR Pipe. | ||
+ | 7)FPN Calibrate & Correction. | ||
+ | 8)WDR Switch. | ||
+ | 9)90/180/270 Rotate. | ||
+ | 10)Mipi Demux Yuv. | ||
+ | 11)UserPic. | ||
+ | intf: | ||
+ | 0) vo HDMI output, default. | ||
+ | 1) vo BT1120 output. | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_vio | ||
+ | ::2. 使用方法:./sample_vio_main <index> <intf> | ||
+ | ::3. index: | ||
+ | ::4. 0) 在线输入--> 在线视频处理 -->输出 | ||
+ | ::5. 1) 离线输入--> 离线视频处理 -->输出 镜头畸变校正视频防抖和展宽 | ||
+ | ::6. 2) 离线输入--> 在线视频处理 -->输出 双管道 | ||
+ | ::7. 3) 在线输入--> 离线视频处理 -->输出 双通道 | ||
+ | ::8. 4) Resolute Ratio Switch | ||
+ | ::9. 5) 几何畸变矫正 -->视频处理 低延时 | ||
+ | ::10. 6) 双WDR管道 | ||
+ | ::11. 7) FPN标定&矫正 | ||
+ | ::12. 8) WDR 开关 | ||
+ | ::13. 9) 90/180/270 旋转 | ||
+ | ::14. 10) Mipi Demux Yuv | ||
+ | ::15. 11) 设置用户图片 | ||
+ | ::16. intf: | ||
+ | ::17. 0) 默认HDMI输出 | ||
+ | ::18. 1) BT1120输出 | ||
+ | |||
+ | ====sample_vgs(Video Graphics Sub-System,视频图形子系统)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_vgs | ||
+ | |||
+ | /*****************************************/ | ||
+ | Usage: ./sample_vgs <index> | ||
+ | index: | ||
+ | 0) FILE -> VGS(Scale) -> FILE. | ||
+ | 1) FILE -> VGS(Cover+OSD) -> FILE. | ||
+ | 2) FILE -> VGS(DrawLine) -> FILE. | ||
+ | 3) FILE -> VGS(Rotate) -> FILE. | ||
+ | /*****************************************/ | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_vgs | ||
+ | ::4. 使用说明:./sample_vgs <index> <intf> | ||
+ | ::5. index: | ||
+ | ::6. 0) 文件--> 视频图像子系统(缩放) -->文件 | ||
+ | ::7. 1) 文件--> 视频图像子系统(Cover+OSD) -->文件 | ||
+ | ::8. 2) 文件--> 视频图像子系统(画线) -->文件 | ||
+ | ::9. 3) 文件--> 视频图像子系统(旋转) -->文件 | ||
+ | |||
+ | ====sample_tde(Two Dimensional Engine,利用硬件为OSD和GUI提供快速的图形绘制功能)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_tde | ||
+ | Usage : ./sample_tde <intf> | ||
+ | intf: | ||
+ | 0) vo BT1120 output, default. | ||
+ | 1) vo HDMI output. | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_tde | ||
+ | ::2. 使用说明:./sample_tde <intf> | ||
+ | ::3. intf: | ||
+ | ::4. 0) 默认BT1120输出演示 | ||
+ | ::5. 1) HDMI输出演示 | ||
+ | |||
+ | ====sample_hifb(Hisilicon Framebuffer,基于Linux FB 基本功能扩展了一些图形层控制功能)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_hifb | ||
+ | Usage : ./sample_hifb <index> <device> <intf> | ||
+ | |||
+ | |||
+ | /****************index******************/ | ||
+ | please choose the case which you want to run: | ||
+ | 0: ARGB8888 standard mode | ||
+ | 1: ARGB1555 BUF_DOUBLE mode | ||
+ | 2: ARGB1555 BUF_ONE mode | ||
+ | 3: ARGB1555 BUF_NONE mode | ||
+ | 4: ARGB1555 BUF_ONE mode with compress | ||
+ | 5: ARGB8888 BUF_ONE mode with compress | ||
+ | |||
+ | /****************device******************/ | ||
+ | 0) VO device 0#, default. | ||
+ | 1) VO device 1#. | ||
+ | |||
+ | /****************intf******************/ | ||
+ | 0) VO HDMI output, default. | ||
+ | 1) VO BT1120 output. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_hifb | ||
+ | ::2. 使用说明:./sample_hifb <index> <device> <intf> | ||
+ | ::5. <index> | ||
+ | ::6. 请选择一下您想运行的情况之一 | ||
+ | ::7. 0: ARGB8888像素格式标准模式 | ||
+ | ::8. 1: ARGB1555像素格式双缓存模式 | ||
+ | ::9. 2: ARGB1555像素格式单缓存模式 | ||
+ | ::10. 3: ARGB1555像素格式无缓存模式 | ||
+ | ::11. 4: ARGB1555像素格式带压缩的单缓存模式 | ||
+ | ::12. 5: ARGB8888像素格式带压缩的单缓存模式 | ||
+ | ::14. <device> | ||
+ | ::15. 0) 默认输出到超清显示设备DHD0 | ||
+ | ::16. 1) 输出到高清显示设备DHD1(暂未支持) | ||
+ | ::18. <intf> | ||
+ | ::19. 0) 默认HDMI输出 | ||
+ | ::20. 1) BT1120输出(暂未支持) | ||
+ | |||
+ | ====sample_awb_calibration(自动白光平衡测量)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_awb_calibration | ||
+ | Usage : ./sample_awb_calibration <mode> <intf1> <intf2> <intf3> | ||
+ | mode: | ||
+ | 0) Calculate Sample gain. | ||
+ | 1) Adjust Sample gain according to Golden Sample. | ||
+ | intf1: | ||
+ | The value of Rgain of Golden Sample. 深红色区域的锐化增益控制。 | ||
+ | intf2: | ||
+ | The value of Bgain of Golden Sample. | ||
+ | intf3: | ||
+ | The value of Alpha ranging from 0 to 1024 (The strength of adusting Sampe Gain will increase with the value of Alpha) . | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_awb_calibration | ||
+ | ::2. 使用方法:./sample_awb_calibration <mode> <intf1> <intf2> <intf3> | ||
+ | ::3. <mode> | ||
+ | ::4. 0) 计算例子中的增益 | ||
+ | ::5. 1) 根据标准例子来校正例子中的增益 | ||
+ | ::6. intf1: | ||
+ | ::7. 标准例子中的深红色区域的锐化增益控制值 | ||
+ | ::8. intf2: | ||
+ | ::9. 标准例子中的深蓝色区域的锐化增益控制值 | ||
+ | ::10. intf3: | ||
+ | ::11. 0~1024范围的初始值(采样数据的增益强度会随着初始值的值增加而增加) | ||
+ | |||
+ | <!-- | ||
+ | ====sample_modeswitch(模式切换)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_modeswitch | ||
+ | Usage : ./sample_modeswitch <index> <intf> | ||
+ | index: | ||
+ | 0)mode switch wdr to linear for imx290 VI - VO - HDMI. Embeded isp, phychn channel preview. | ||
+ | 1)mode switch linear to wdr for imx290 VI - VO - HDMI+BT1120. Embeded isp, phychn channel preview. | ||
+ | 2)resolution 9M50FPS to 8M30FPS for imx477 VI - VO - HDMI. Embeded isp, phychn channel preview. | ||
+ | 3)resolution 8M30FPS to 9M50FPS for imx477 VI - VO - HDMI. Embeded isp, phychn channel preview. | ||
+ | intf: | ||
+ | 0) vo HDMI output, default. | ||
+ | 1) vo BT1120 output. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_modeswitch | ||
+ | ::2. 使用说明: ./sample_modeswitch <index> <intf> | ||
+ | ::3. index: | ||
+ | ::4. 0) imx290的wdr模式到linear模式切换 | ||
+ | ::5. 1) imx290的linear模式到wdr模式切换 | ||
+ | ::6. 2) imx477的分辨率9M50FPS切换至8M30FPS | ||
+ | ::7. 3) imx477的分辨率8M30FPS切换至9M50FPS | ||
+ | ::8. intf: | ||
+ | ::9. 0) 默认HDMI输出 | ||
+ | ::10. 1) BT1120输出 | ||
+ | --> | ||
+ | |||
+ | ====sample_ive_main(智能加速引擎)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_ive_main | ||
+ | Usage : ./sample_ive_main <index> [complete] [encode] [vo] | ||
+ | index: | ||
+ | 0)BgModel,<encode>:0, not encode;1,encode.<vo>:0,not call vo;1,call vo.(VI->VPSS->IVE->VGS->[VENC_H264]->[VO_HDMI]). | ||
+ | 1)Gmm,<encode>:0, not encode;1,encode.<vo>:0,not call vo;1,call vo.(VI->VPSS->IVE->VGS->[VENC_H264]->[VO_HDMI]). | ||
+ | 2)Occlusion detected.(VI->VPSS->IVE->VO_HDMI). | ||
+ | 3)Motion detected.(VI->VPSS->IVE->VGS->VO_HDMI). | ||
+ | 4)Canny,<complete>:0, part canny;1,complete canny.(FILE->IVE->FILE). | ||
+ | 5)Gmm2.(FILE->IVE->FILE). | ||
+ | 6)MemoryTest.(FILE->IVE->FILE). | ||
+ | 7)Sobel.(FILE->IVE->FILE). | ||
+ | 8)Ann.(FILE->IVE->STDIO). | ||
+ | 9)St Lk.(FILE->IVE->FILE). | ||
+ | a)Svm.(FILE->IVE->STDIO). | ||
+ | b)Cnn.(FILE->IVE->STDIO). | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_ive_main | ||
+ | ::2. 使用说明: ./sample_ive_main <index> [complete] [encode] [vo] | ||
+ | ::3. index: | ||
+ | ::4. 0) 背景模型 | ||
+ | ::5. 1) 高斯模型Gmm | ||
+ | ::6. 2) 遮挡检测 | ||
+ | ::7. 3) 运动检测 | ||
+ | ::8. 4) 边缘检测 | ||
+ | ::9. 5) 高斯模型Gmm2 | ||
+ | ::10 6) 内存测试 | ||
+ | ::11 7) Sobel算子分割 | ||
+ | ::12 8) 图像检索Ann | ||
+ | ::13 9) St和LK光流法 | ||
+ | ::14 a) 分类器SVM | ||
+ | ::15 b) 神经网络Cnn | ||
+ | |||
+ | ====sample_dis(Digital Image Stabilization,数字稳像)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_dis | ||
+ | Usage : ./sample_dis <index> <intf> | ||
+ | index: | ||
+ | 0)DIS-4DOF_GME.VI-VO VENC. | ||
+ | 1)DIS-6DOF_GME.VI-VO VENC. | ||
+ | intf: | ||
+ | 0) vo HDMI output, default. | ||
+ | 1) vo BT1120 output. | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_dis | ||
+ | ::2. 使用说明: ./sample_dis <index> <intf> | ||
+ | ::3. index: | ||
+ | ::4. 0) DIS-4DOF_GME(四自由度 GME 算法,不使用陀螺仪),输入-输出 同时H256格式录像(存储在当前) | ||
+ | ::5. 1) DIS-6DOF_GME(六自由度 GME 算法,不使用陀螺仪),输入-输出 同时H256格式录像(存储在当前) | ||
+ | ::6. intf: | ||
+ | ::7. 0) HDMI 输出 | ||
+ | ::8. 1) BT1120 输出 | ||
+ | |||
+ | ====sample_dsp_main(DSP测试)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_dsp_main | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 四个DSP之DSP0的出图测试。 | ||
+ | |||
+ | ====sample_nnie_main(神经网络硬件加速单元测试)==== | ||
+ | |||
+ | :1. 神经网络,特别是深度学习卷积神经网络进行加速处理的硬件单元测试。 | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./sample_nnie_main | ||
+ | Usage : ./sample_nnie_main <index> | ||
+ | index: | ||
+ | 0) RFCN(VI->VPSS->NNIE->VGS->VO). | ||
+ | 1) Segnet(Read File). | ||
+ | 2) FasterRcnnAlexnet(Read File). | ||
+ | 3) FasterRcnnDoubleRoiPooling(Read File). | ||
+ | 4) Cnn(Read File). | ||
+ | 5) SSD(Read File). | ||
+ | 6) Yolov1(Read File). | ||
+ | 7) Yolov2(Read File). | ||
+ | 8) LSTM(Read File). | ||
+ | 9)Pvanet(Read File). | ||
+ | a) Rfcn(Read File). | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 sample_nnie_main | ||
+ | ::2. 使用说明: ./sample_nnie_main <index> | ||
+ | ::3. index: | ||
+ | ::4. 0) RFCN模型 | ||
+ | ::5. 1) 可训练的图像分割Segnet | ||
+ | ::6. 2) 深度学习的目标检测Alexnet | ||
+ | ::7. 3) 深度学习的目标检测DoubleRoiPooling | ||
+ | ::8. 4) 神经网络Cnn | ||
+ | ::9. 5) 可训练的SSD模型处理 | ||
+ | ::10. 6) 神经网格模型Yolov1 | ||
+ | ::11. 7) 神经网格模型Yolov2 | ||
+ | ::12. 8) LSTM模型 | ||
+ | ::13. 9) Pvanet网络 | ||
+ | ::14. a) Rfcn目标检测 | ||
+ | <!-- | ||
+ | ====vi_bayerdump(用来获取sensor原始图像的工具)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vi_bayerdump -h | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | To see more usage, please enter: ./vi_bayerdump -h | ||
+ | |||
+ | |||
+ | ************************************************* | ||
+ | Usage: ./vi_bayerdump [ViPipe] [nbit] [Compress] [FrmCnt] [ByteAlign] [RatioShow] | ||
+ | ViPipe: | ||
+ | 0:ViPipe0 ~ 7:ViPipe 7 | ||
+ | nbit: | ||
+ | The bit num to be dump | ||
+ | Compress: | ||
+ | Whether to dump compressed raw, default is 0 | ||
+ | FrmCnt: | ||
+ | the count of frame to be dump | ||
+ | ByteAlign: | ||
+ | Whether convert to Byte align, default is 1 | ||
+ | RatioShow: | ||
+ | Whether the file name of raw show ratio info, default is 1 | ||
+ | e.g : ./vi_bayerdump 0 16 0 2 1 1 | ||
+ | ************************************************* | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 vi_bayerdump -h | ||
+ | ::2. | ||
+ | ::3. 注意:此工具仅用于测试使用! | ||
+ | ::4. 获取跟多信息请输入: ./vi_bayerdump -h | ||
+ | ::5. | ||
+ | ::6. | ||
+ | ::7. ************************************************* | ||
+ | ::8. 使用说明:./vi_bayerdump [ViPipe] [nbit] [Compress] [FrmCnt] [ByteAlign] [RatioShow] | ||
+ | ::9. ViPipe: | ||
+ | ::10. ''' '''ViPipe号 0~7范围内 | ||
+ | ::11. nbit: | ||
+ | ::12. ''' '''原始数据的字节宽度 支持8/10/12/14/16bit | ||
+ | ::13. Compress: | ||
+ | ::14. ''' '''解码图像压缩模式: 是否转存原始图像压缩数据,默认是0 0代表不压缩 | ||
+ | ::15. FrmCnt: | ||
+ | ::16. ''' '''获取VI 框架个数 | ||
+ | ::17. ByteAlign: | ||
+ | ::18. ''' '''是否转换为字节对齐, 默认值为1 | ||
+ | ::19. RatioShow: | ||
+ | ::20. ''' '''文件名上是否对比率信息原始展现,默认为1 | ||
+ | ::21. | ||
+ | ::22. ************************************************* | ||
+ | --> | ||
+ | |||
+ | <!-- | ||
+ | ====vi_chn_dump(输入通道视频帧转储)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vi_chn_dump -h | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | To see more usage, please enter: ./vi_chn_dump -h | ||
+ | |||
+ | |||
+ | ********************************************************** | ||
+ | Usage: ./vi_chn_dump [ViPipe] [ViChn] [FrmCnt] [ByteAlign] | ||
+ | 1)ViPipe: | ||
+ | Vi pipe id | ||
+ | 2)ViChn: | ||
+ | vi chn id | ||
+ | 3)FrmCnt: | ||
+ | the count of frame to be dump | ||
+ | 4)ByteAlign: | ||
+ | Whether convert to Byte align , default is 1 | ||
+ | *)Example: | ||
+ | e.g : ./vi_chn_dump 0 0 2 1 | ||
+ | ********************************************************** | ||
+ | |||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 ./vi_chn_dump -h | ||
+ | ::2. ''' ''' | ||
+ | ::3. 注意:此工具仅用于测试!!! | ||
+ | ::4. 获取更多信息请输入 ./vi_chn_dump -h | ||
+ | ::5. | ||
+ | ::6. | ||
+ | ::7. ********************************************************** | ||
+ | ::8. 使用说明: ./vi_chn_dump [ViPipe] [ViChn] [FrmCnt] [ByteAlign] | ||
+ | ::9. 1)ViPipe: | ||
+ | ::10. PIPE 号,范围0~7 | ||
+ | ::11. 2)ViChn: | ||
+ | ::12. vi 通道号 | ||
+ | ::13. 3)FrmCnt: | ||
+ | ::14. 视频帧数 | ||
+ | ::15. 4)ByteAlign: | ||
+ | ::16. 是否转换为字节对齐, 默认值为1 | ||
+ | ::17. | ||
+ | ::18. ********************************************************** | ||
+ | --> | ||
+ | |||
+ | <!-- | ||
+ | ====vo_chn_dump(输出通道视频帧转储)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vo_chn_dump -h | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | To see more usage, please enter: ./vo_chn_dump -h | ||
+ | |||
+ | |||
+ | ************************************************* | ||
+ | Usage: ./vo_chn_dump [VoLayer] [VoChn] [Frmcnt]. | ||
+ | 1)VoLayer: | ||
+ | which layer to be dump 视频输出视频层号。 | ||
+ | Default: 0 | ||
+ | 2)VoChn: | ||
+ | which channel to be dump | ||
+ | Default: 0 | ||
+ | 3)FrmCnt: | ||
+ | the count of frame to be dump | ||
+ | Default: 1 | ||
+ | *)Example: | ||
+ | e.g : ./vo_chn_dump 0 0 1 (dump one YUV) | ||
+ | ************************************************* | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 vo_chn_dump -h | ||
+ | ::2. | ||
+ | ::3. 注意:此工具仅用于测试使用!!! | ||
+ | ::4. 获取更多信息,请输入 ./vo_chn_dump -h | ||
+ | ::5. | ||
+ | ::6. | ||
+ | ::7. ************************************************* | ||
+ | ::8. 使用说明:./vo_chn_dump [VoLayer] [VoChn] [Frmcnt]. | ||
+ | ::9. 1)VoLayer: | ||
+ | ::10. 选择要转储的视频输出视频层号 | ||
+ | ::11. 默认是0 | ||
+ | ::12.2)VoChn: | ||
+ | ::13. 选择要转储的视频输出通道 | ||
+ | ::14. 默认是0 | ||
+ | ::15. 3)FrmCnt: | ||
+ | ::16. 需要转储的视频帧个数 | ||
+ | ::17. 默认1 | ||
+ | ::18.************************************************* | ||
+ | --> | ||
+ | |||
+ | <!-- | ||
+ | ====vo_screen_dump(转储输出屏幕图像数据)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vo_screen_dump -h | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | To see more usage, please enter: ./vo_screen_dump -h | ||
+ | |||
+ | |||
+ | ************************************************* | ||
+ | Usage: ./vo_screen_dump [VoLayer] [Frmcnt]. | ||
+ | 1)VoLayer: | ||
+ | Which layer to be dumped | ||
+ | Default: 0 | ||
+ | 2)FrmCnt: | ||
+ | The count of frame to be dumped | ||
+ | Default: 1 | ||
+ | *)Example: | ||
+ | e.g : ./vo_screen_dump 0 1 (dump one YUV) | ||
+ | ************************************************* | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 vo_screen_dump -h | ||
+ | ::2. | ||
+ | ::3. 注意:此工具仅用于测试使用!!! | ||
+ | ::4. 获取更多信息,请输入:./vo_screen_dump -h | ||
+ | ::5. | ||
+ | ::6. | ||
+ | ::7. ************************************************* | ||
+ | ::8. 使用说明:./vo_screen_dump [VoLayer] [Frmcnt]. | ||
+ | ::9. 1)VoLayer: | ||
+ | ::10. 选择要转储的视频输出视频层号 | ||
+ | ::11. 默认0 | ||
+ | ::12. 2)FrmCnt: | ||
+ | ::13. 需要转储的视频帧个数 | ||
+ | ::14. 默认1 | ||
+ | ::15. ************************************************* | ||
+ | --> | ||
+ | |||
+ | <!-- | ||
+ | ====vo_wbc_dump(回写设备的输出图像数据转储)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vo_wbc_dump | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | usage: ./vo_wbc_dump 0 [frmcnt]. sample: ./vo_wbc_dump 0 5 | ||
+ | |||
+ | Dev(0) HI_MPI_VO_SetWbcDepth errno 0xa00f8010 | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 vpss_chn_dump | ||
+ | ::2. | ||
+ | ::3. 注意:此工具仅用于测试使用!!! | ||
+ | ::4. 使用说明:./vo_wbc_dump 0 [frmcnt]. sample: ./vo_wbc_dump 0 5 | ||
+ | ::5. 第一个参数:回写设备号 | ||
+ | ::6. [frmcnt] 输出视频的帧数 | ||
+ | --> | ||
+ | <!-- | ||
+ | ====vpss_chn_dump(用户从通道获取Cnt个帧处理完成的图像转储)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vpss_chn_dump -h | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | To see more usage, please enter: ./vpss_chn_dump -h | ||
+ | |||
+ | |||
+ | ************************************************* | ||
+ | Usage: ./vpss_chn_dump [VpssGrp] [VpssChn] [FrmCnt] | ||
+ | 1)VpssGrp: | ||
+ | Vpss group id | ||
+ | 2)VpssChn: | ||
+ | vpss chn id | ||
+ | 3)FrmCnt: | ||
+ | the count of frame to be dump | ||
+ | *)Example: | ||
+ | e.g : ./vpss_chn_dump 0 0 1 | ||
+ | e.g : ./vpss_chn_dump 1 4 2 | ||
+ | ************************************************* | ||
+ | |||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 vpss_chn_dump -h | ||
+ | ::2. | ||
+ | ::3. 注意:此工具仅用于测试使用!!! | ||
+ | ::4. 获取更多信息,请输入:./vpss_chn_dump -h | ||
+ | ::5. | ||
+ | ::6. | ||
+ | ::7. ************************************************* | ||
+ | ::8. 使用说明: ./vpss_chn_dump [VpssGrp] [VpssChn] [FrmCnt] | ||
+ | ::9. 1)VpssGrp: | ||
+ | ::10. VPSS GROUP 号 | ||
+ | ::11. 2)VpssChn: | ||
+ | ::12. VPSS 通道号 | ||
+ | ::13. 3)FrmCnt: | ||
+ | ::14. 转储的视频帧个数 | ||
+ | ::15.************************************************* | ||
+ | --> | ||
+ | |||
+ | <!-- | ||
+ | ====vpss_src_dump(转储视频缓存池帧数据)==== | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ./vpss_src_dump -h | ||
+ | |||
+ | NOTICE: This tool only can be used for TESTING !!! | ||
+ | To see more usage, please enter: ./vpss_src_dump -h | ||
+ | |||
+ | |||
+ | ************************************************* | ||
+ | Usage: ./vpss_src_dump [Grp] [Pipe] | ||
+ | 1)VpssGrp: | ||
+ | Vpss group id | ||
+ | 2)Pipe: | ||
+ | Vpss Grp pipe | ||
+ | *)Example: | ||
+ | e.g : ./vpss_src_dump 0 0 | ||
+ | ************************************************* | ||
+ | |||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :shell 说明: | ||
+ | ::1. 运行 vpss_src_dump -h | ||
+ | ::2. | ||
+ | ::3. 注意:此工具仅用于测试使用!!! | ||
+ | ::4. 获取更多信息请输入:./vpss_src_dump -h | ||
+ | ::5. | ||
+ | ::6. | ||
+ | ::7. ************************************************* | ||
+ | ::8. 使用说明:./vpss_src_dump [Grp] [Pipe] | ||
+ | ::9. 1)VpssGrp: | ||
+ | ::10. VPSS GROUP 号 | ||
+ | ::11. 2)Pipe: | ||
+ | ::12. VPSS 组的管道号 | ||
+ | ::13. ************************************************* | ||
+ | --> | ||
+ | |||
+ | =='''其他功能说明'''== | ||
+ | ====nfs配置和网络==== | ||
+ | |||
+ | :1,pc机安装nfs服务,安装前可以先学习下这个网站内容:https://blog.csdn.net/iamplane/article/details/53912176 | ||
+ | :pc机操作示例如下: | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | $ sudo apt-get install nfs-kernel-server | ||
+ | $ sudo apt-get install nfs-common | ||
+ | $ sudo gedit /etc/exports #添加下面内容/home/nfs *(rw,sync,no_root_squash,no_subtree_check) | ||
+ | $ sudo /etc/init.d/rpcbind restart #重启rpcbind | ||
+ | $ sudo /etc/init.d/nfs-kernel-server restart #重启nfs服务 | ||
+ | $ showmount -e #使用此命令后有”/home/nfs“则安装成功 | ||
+ | |||
+ | </syntaxhighlight> | ||
+ | |||
+ | :2,设备debug串口链接到PC机上,串口参数是115200 8N1(详细见[http://android1.norco.com.cn:7070/index.php/EMB-7541-COM 串口接口定义]) | ||
+ | |||
+ | :在设备串口终端上,通过下面命令配置IP eth0: | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # ifconfig eth0 192.168.8.189 | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :在设备串口终端,通过下面命令挂载PC机的/home/nfs目录到设备的/mnt/nfs目录(192.168.8.xx是PC机的IP,和设备eth0的IP处在同一网段即可): | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # mount -t nfs -o nolock -o tcp 192.168.8.xx:/home/nfs /mnt/nfs | ||
+ | ~ # cd /mnt/nfs | ||
+ | ~ # ls #查看PC机共享的内容 | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :这样PC机共享出/home/nfs目录后,在设备的/mnt/nfs目录就可以访问PC机/home/nfs目录的内容。 | ||
+ | <!-- | ||
+ | ====视频网络直播==== | ||
+ | :1,这个demo不是sdk里面自带的,是后期移植的,解码后分辨率只有1920x1080,30帧每秒,如果需要高清直播,需要客户自行移植。 | ||
+ | ::<syntaxhighlight lang="bash" line> | ||
+ | ~# ifconfig eth0 192.168.8.189 | ||
+ | ~# cd /root/ | ||
+ | ~# ./sample_rtsp | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | :2,然后在vlc视频播放器的URL的流媒体栏输入:rtsp://192.168.8.189/stream_chn0.h264既可进行实时视频播放,注意安装vlc的电脑IP和设备IP在同一网段。 | ||
+ | ::[[文件:EMB-7540-rtsp8-1.jpg|500px| 图8-1 VLC输入URL ]] | ||
+ | :3,在ubuntu系统里面,打开video播放器,添加rtsp://192.168.8.189/stream_chn0.h264 即可实时视频播放,ubuntu电脑IP和设备IP在同一网段。 | ||
+ | ::[[文件:EMB-7540-rtsp8-2.png|500px| 图8-2 video输入URL ]] | ||
+ | ::[[文件:EMB-7540-rtsp8-3.png|500px| 图8-3 video直播视频 ]] | ||
+ | --> | ||
+ | ====继电器使用==== | ||
+ | :通过操作GPIO14_2可以控制继电器的断开和闭合。 | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~# echo 114 > /sys/class/gpio/export #导出GPIO14_2 | ||
+ | ~# echo out > /sys/class/gpio/gpio114/direction #设置GPIO14_2方向为输出 | ||
+ | ~# echo 1 > /sys/class/gpio/gpio114/value #控制继电器断开 | ||
+ | ~# echo 0 > /sys/class/gpio/gpio114/value #控制继电器闭合 | ||
+ | ~# echo 114 > /sys/class/gpio/unexport #取消GPIO14_2的导出 | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | ====设置RTC时间==== | ||
+ | :查看当前时间 | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # date | ||
+ | Mon Jan 8 00:00:01 UTC 2018 | ||
+ | </syntaxhighlight> | ||
+ | :设置时间并保存到硬件 | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | ~ # date -s "2019-1-17 11:38:45" #设置系统时间 | ||
+ | ~ # hwclock -w #将时间保存到硬件 | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | ====USB口U盘挂载==== | ||
+ | :将U盘插入USB口,会有很多提示信息,其中比较有用的标识是sda: sda1信息(第一个U盘,后面以此是sdb1,sdc1...),然后通过下面命令进行U盘挂载,进入/mnt/usb目录可以看到U盘内容。 | ||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~ # mount -t vfat /dev/sda1 /mnt/usb #假设看到的提示信息是sda1 | ||
+ | ~ # cd /mnt/usb | ||
+ | ~ # ls #查看U盘内容 | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | ====TF口使用==== | ||
+ | :将TF卡插入到设备TF卡槽内,重启系统,在终端会有mmc1: new high speed SD card at address 0001提示。使用下面命令进行挂载(mmcblk0是系统emmc使用,TF卡为mmcblk1),在 /mnt/mmc目录下可以看到TF卡里面的内容。 | ||
+ | |||
+ | :<syntaxhighlight lang="bash" line> | ||
+ | |||
+ | ~ # mount -t vfat /dev/mmcblk1p1 /mnt/mmc | ||
+ | ~ # cd /mnt/mmc | ||
+ | ~ # ls #查看TF卡内容 | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | ====COM口使用==== | ||
+ | :一个COM232,一个COM485,一个debug调试串口,引脚定义详见串口[http://android1.norco.com.cn:7070/index.php/EMB-7541-COM 接口定义]。 | ||
+ | :软件上COM232口对应的设备是/dev/ttyAMA2,COM485对应的设备是/dev/ttyAMA1,debug串口对应的设备是/dev/ttyS000。 | ||
+ | :调试串口默认参数是115200 8 N 1。 | ||
+ | |||
+ | =='''拼接及NNIE开发说明'''== | ||
+ | ====拼接==== | ||
+ | :*[http://norcord.com:8070/d/05925f2348bd42cd8b33/ 拼接工具和文档 下载] | ||
+ | :下载包中Hi3519AV100_PQ_XXX.tar.gz是板端运行的程序,拷贝到板端后解压,执行脚本./HiIspTool.sh -a sensortype (sensortype为configs目录下的文件名,例如:./HiIspTool.sh -a imx290avs);只有先运行板端程序后才可在PC端运行工具。 | ||
+ | :下载包中HiPQTools_XXX.zip是运行在PC上工具,用来调试图像质量,拼接时需要使用该工具采集图像和标定。 | ||
+ | :下载包中ITTP_Stream_XXX.zip是PC端点播工具,用来远程观看板端采集视频。 | ||
+ | :拼接标定步骤请详细参考《拼接调试指南》。 | ||
+ | |||
+ | ====NNIE==== | ||
+ | :*[http://norcord.com:8070/d/6a4d4b6fb53f4f738b7b/ NNIE工具和文档 下载] | ||
+ | :下载包中HiSVP_PC_XXX.tgz是海思模型转化和仿真工具,目前仅支持caffe模型。 | ||
+ | :用户在caffe框架上训练得到的模型需要使用该工具转化成端板识别的模型,即wk文件。 | ||
+ | :模型转化请参考《HiSVP开发指南》。 |
2022年8月17日 (三) 15:22的最新版本
目录
- 1 资源特性
- 2 接口布局和尺寸
- 3 下载
- 4 烧录方法
- 5 例程环境搭建
- 6 Demo使用
- 6.1 sample_venc(视频数据编码)
- 6.2 sample_vdec(视频数据解码)
- 6.3 sample_audio(音频相关)
- 6.4 sample_snap(拍照)
- 6.5 sample_dpu_main(Depth Process Unit,深度图)
- 6.6 sample_avs(Any View Stitching,全景拼接)
- 6.7 sample_fisheye(鱼眼模式)
- 6.8 sample_vio(视频输入输出)
- 6.9 sample_vgs(Video Graphics Sub-System,视频图形子系统)
- 6.10 sample_tde(Two Dimensional Engine,利用硬件为OSD和GUI提供快速的图形绘制功能)
- 6.11 sample_hifb(Hisilicon Framebuffer,基于Linux FB 基本功能扩展了一些图形层控制功能)
- 6.12 sample_awb_calibration(自动白光平衡测量)
- 6.13 sample_ive_main(智能加速引擎)
- 6.14 sample_dis(Digital Image Stabilization,数字稳像)
- 6.15 sample_dsp_main(DSP测试)
- 6.16 sample_nnie_main(神经网络硬件加速单元测试)
- 7 其他功能说明
- 8 拼接及NNIE开发说明
资源特性
- CPU:HiSilicon Hi3519A 2xA53双核处理器
- Memory:板载2GB DDR4
- Storage:板载16GB iNAND Flash,1x TF卡槽
- Ethernet: 1 x LAN,10/100/1000Mbps
- Input:CMOS Sensor:(根据镜头规格设计转接板)
- 2路3000 x 3000@30fps 输入,输出3840 x 2160@30fps
- 4路1080 x 1920@30fps 输入,输出3840 x 2160@30fps
- Display:1xHDMI
- Touch:电容或电阻屏
- USB Host: 1x USB3.0,1x OTG
- COM: 1x COM232;1x COM485;1x debug
- Audio:1xMic;1xLine out;1xMic(3.5mm四节耳机孔)
- Other I/O: 2xDI,1xDO;2xGyroscope;支持GPIO,I2C,SPI扩展
- System Control:1xRST BUTTON,1xPWR LED
- RTC:支持
- Watchdog:支持
- Power Supply:单电源+ 12V DC
- Temperature:Work :-20℃ ~ +65℃, Storage :-40℃ ~ +85℃
- Humidity:5% ~ 95%相对湿度,无冷凝
- Size: 120mm x 80 mm
- OS: Linux
接口布局和尺寸
接口概览
接口引脚定义
传感器接口转接板定义
机械尺寸
下载
烧录方法
HiTool 烧录方法
适用场景
- 适用于一键烧写所有程序镜像到单板flash 上的场景、单板已有 boot 可按地址烧写其他程序镜像到单板 flash 上的场景,以及在空板上只烧写 boot 到单板 flash 上的场景。
- 本文只介绍 <eMMC烧录>方法。
环境部署
- HiBurn 工具烧写的环境准备如下:
- 步骤 1. PC 与单板之间连接好串口、网线,且因工具烧写需要涉及到与 bootrom 交互,故单板硬件上 bootrom_sel 需要设置为 1,从 bootrom 启动。
- 步骤 2. 下载HiTool http://norcord.com:8070/f/d711a3ed07054d058c18/?dl=1 把HiTool-BVT-5.0.28.zip 拷贝到 PC 上(PC 要求安装 Win7、XP 操作系统)的某个本地硬盘。在 HiTool-XXX-4.0.15 及以后的版本已经集成了 jre,无需单独安装 JRE,如上面链接提供的版本。如果是老版本工具,请预先安装的 32 位的 jre1.6(如 jre-6u1-windows-i586-p),否则HiTool 可能无法运行。
- 链接如下:http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase6-419409.html
- 查看当前 PC 安装的 JRE 版本号,可以通过在开始->运行->键入 cmd 中输入 java –version 查看当前已安装的 JRE 版本号,若当前版本为 1.6.0_xx 即可,若当前版本号高于 1.6,则请打开 HiTool 目录下的 HiTool.ini,将其中-XX:MaxTenuringThreshold=31 参数值改为-XX:MaxTenuringThreshold=15,即可支持 1.7 及更高版本的 JRE。。
eMMC烧录
适用场景
- 适用场景如下:只适用于 eMMC 烧写,不管单板上有没有 boot 都适用,可实现一键烧写所有镜像。
烧写步骤
- 具体烧写步骤如下:
- 步骤 1. 切换到“烧写 eMMC”页签,如图 5-1 所示。
- 步骤 3. 准备单板环境。连接单板的串口和网口,如果单板处于通电状态,给单板下电 。
- 步骤 4. 烧写单板,点击烧写按钮【Burn】。
- 步骤 5. 给单板上电,进入烧写过程,等待烧写完成。
- 烧写过程的信息会在控制台中显示。
- 串口选择是否正确。
- IP 地址设置是否正确,地址是否被占用。
- 是否有短接单板上的自举跳线。
- 步骤 6. 烧写完成,连接终端工具,重启单板。
U盘/TF卡升级
适用场景
- sd卡烧录简单快速,可用于裸板烧录;U盘烧录必须在有uboot情况下。
烧写步骤
- 具体烧写步骤如下:
- 步骤 1. 格式化 SD卡(U盘)为 FAT32 格式,若 SD 卡有多个分区时,升级包必须放在第一个分区,否则扫描不到升级包。
- 步骤 2. 从上面链接处下载系统烧录镜像,把各镜像文件名更改为:u-boot.bin,kernel,rootfs.ext4。
- 步骤 3. 新建config文件(若下载镜像文件中有config则跳过该步骤),config文件内容如下:
setenv bootargs 'mem=256M console=ttyAMA0,115200n8 root=/dev/mmcblk0p3 rootfstype=ext4 rw rootwait blkdevparts=mmcblk0:1M(u-boot.bin),4M(kernel),32M(rootfs.ext4),-' setenv bootcmd 'mmc read 0 0x21000000 0x800 0x2000;bootm 0x21000000'
- 步骤 4. 选择升级烧录模式,把JFP(JFP)的3(UPDATE),4(GND)脚用跳帽短接.
- 步骤 5. 把u-boot.bin,kernel,rootfs.ext4,config文件拷贝到SD卡或U盘中(目标文件sample_app.tar.gz也可以拷贝进来,便于系统启动后自动解压sample_app),插入SD卡,上电启动,等待5-20秒即可烧录成功,可在串口中看到如下打印:
- 注意事项:
u-boot 镜像名称必须为 u-boot.bin。 裸烧会自动保存 config 中的 bootargs 和 bootcmd 环境变量,没有 config 文件时,仅会烧写 bootrom 读取的 u-boot 镜像。 烧录成功后记得把JFP的3,4引脚跳帽去掉,否则下次启动又会进入升级烧录模式。
例程环境搭建
工具链安装
- 下载工具链arm-himix200-linux.tgz安装包。
- 1) 将安装包arm-himix200-linux.tgz拷贝到安装了ubuntu环境的PC机上,在PC机的shell中执行下面步骤进行安装:
1 $ tar -zxf arm-himix200-linux.tgz 2 $ chmod +x arm-himix200-linux.install 3 $ sudo ./arm-himix200-linux.install
- 2) 执行 source /etc/profile 或者重启电脑让环境变量生效。注意,如果不重启电脑,仅仅source一下,环境变量只在当前shell里生效。
sample环境搭建
Demo使用
sample_venc(视频数据编码)
1 ~ # ./sample_venc 2 Usage : ./sample_venc [index] 3 index: 4 0) H.265e@4K@120fps + H264e@1080p@30fps. 5 1) H.265e@4K@60fps + H264e@4K@60fp. 6 2) Lowdelay:H.265e@4K@30fps. 7 3) IntraRefresh:H.265e@4K@60fps + H264e@4K@60fps. 8 4) Qpmap:H.265e@4K + H264e@4K@60fps. 9 5) Mjpeg@4K@60fps +Jpeg@4K.
- shell 说明:
- 1. 运行sample_venc (录制) 视频编码样例
- 2. 使用方法: ./sample_venc [index]
- 3. 参数<索引>
- 4. 0) h265编码,4096×2160分辨率,每秒120帧 + h264编码,1920x1080分辨率,每秒30帧
- 5. 1) h265编码,4096×2160分辨率,每秒60帧 + h264编码,4096×2160分辨率,每秒60帧
- 6. 2) Lowdelay(低延时属性):h265编码,4096×2160分辨率,每秒30帧
- 7. 3) IntraRefresh(P 帧帧内刷新):h265编码,4096×2160分辨率,每秒60帧 + h264编码,4096×2160分辨率,每秒60帧
- 8. 4) Qpmap(是一种码率控制模式):h265编码,4096×2160分辨率 + h264编码,4096×2160分辨率,每秒60帧
- 9. 5) Mjpeg(Mjpeg协议编码方式)的4096×2160分辨率,每秒60帧 + Jpeg(Jpeg的编码)的4096×2160分辨率
sample_vdec(视频数据解码)
1 ~ # ./sample_vdec 2 Usage : ./sample_vdec <index> <IntfSync> 3 index: 4 0) VDEC(H265)-VPSS-VO 5 1) VDEC(H264)-VPSS-VO 6 2) VDEC(JPEG->YUV)-VPSS-VO 7 3) VDEC(JPEG->RGB) 8 IntfSync : 9 0) VO HDMI 4K@30fps. 10 1) VO HDMI 1080P@30fps.
- shell 说明:
- 1. 运行sample_vdec (播放) 视频解码样例
- 2. 使用提示: ./sample_vdec <索引> <Vo接口时序类型>
- 3. 参数<索引>:
- 4. 0) VDEC解码器输入(H265的编码格式图片/视频)--->VPSS(视频输入缓存块)--->VO(图片/视频输出)
- 5. 1) VDEC解码器输入(H264的编码格式图片/视频)--->VPSS(视频输入缓存块)--->VO(图片/视频输出)
- 6. 2) VDEC解码器输入(JPEG数据)--->VPSS(视频输入缓存块)--->VO(YUV图片/视频输出)
- 7. 3) VDEC解码器输入JPEG解码成RGB数据
- 8. 参数<IntfSync>:
- 9. 0) 输出到HDMI 4096×2160分辨率,每秒30帧
- 10. 1) 输出到HDMI 1920x1080分辨率,每秒30帧
sample_audio(音频相关)
1 ~ # ./sample_audio 2 3 4 /Usage:./sample_audio <index>/ 5 index and its function list below 6 0: start AI to AO loop 7 1: send audio frame to AENC channel from AI, save them 8 2: read audio stream from file, decode and send AO 9 3: start AI(VQE process), then send to AO 10 4: start AI to AO(Hdmi) loop 11 5: start AI to AO(Syschn) loop 12 6: start AI to Extern Resampler 13 channel: 14 0: mic0 input 15 1: mic1 input
- shell 说明:
- 1. 运行sample_audio 音频 (编码/解码)样例
- 4. 使用提示:./sample_audio <索引>
- 5. 以下内容是索引对应的功能
- 6. 0) 循环音频从输入到输出 (话筒功能)
- 7. 1) 通过音频输入发送音频帧到音频编码通道,保存起来 (录音功能)
- 8. 2) 从文件读取音频流,解码然后发送到输出 (播放功能)
- 9. 3) 通过音频输入声音质量增强处理,然后输出音频 (话筒功能)
- 10. 4) 循环音频输入到HDMI通道音频输出 (话筒功能)
- 11. 5) 循环音频输入到系统音通道音频输出 (话筒功能)
- 12. 6) 通过音频输入重新采样 (录音功能)
- 13. 音频输入通道
- 14. 0) mic0输入(HeadPhone)
- 15. 1) mic1输入(插针)
sample_snap(拍照)
1 ~ # ./sample_snap 2 Usage : ./sample_snap <index> 3 index: 4 0)double pipe offline, normal snap.
- shell 说明:
- 1. 运行sample_snap 拍照
- 2. 使用说明:./sample_snap <索引>
- 3. 参数<索引>
- 4. 0)双 pipe 离线模式普通拍照
sample_dpu_main(Depth Process Unit,深度图)
1 ~ # ./sample_dpu_main 2 Usage : ./sample_dpu_main <index> 3 index: 4 0) VI->VPSS->RECT->MATCH. 5 1) FILE->RECT->MATCH.
- shell 说明:
- 1. 运行 sample_dpu_main
- 2. 使用方法:./sample_dpu_main <索引>
- 3. <索引>
- 4. 0) DPU(Depth Process Unit)对输入的左图像和右图像经过校正和匹配计算得出深度图
- 5. 1) DPU(Depth Process Unit)对读取的文件的左图像和右图像经过校正和匹配计算得出深度图
sample_avs(Any View Stitching,全景拼接)
1 ~ # ./sample_avs 2 Usage : ./sample_avs <index> 3 index: 4 0) 2 fisheye stitching, Normal projection. 5 1) 4 fisheye stitching, Cube map. 6 2) 4 pic no blend stitching. 7 3) 2 fisheye stitching, Image stabilizing. 8 4) Generate lut.
- shell 说明:
- 1. 运行 sample_avs
- 2. 使用说明: ./sample_avs <index>
- 3. <index>
- 4. 0) 2个CAM 鱼眼拼接正常显示模式
- 5. 1) 4个CAM 鱼眼拼接呈现立体显示效果
- 6. 2) 4个CAM 图片无混合拼接
- 7. 3) 目前暂不支持
- 8. 4)生成LUT表
sample_fisheye(鱼眼模式)
1 ~ # ./sample_fisheye 2 3 Usage : ./sample_fisheye <index> <vo intf> <venc type> 4 index: 5 0) fisheye 360 panorama 2 half with ceiling mount. 6 1) fisheye 360 panorama and 2 normal PTZ with desktop mount. 7 2) fisheye 180 panorama and 2 normal dynamic PTZ with wall mount. 8 3) fisheye source picture and 3 normal PTZ with wall mount. 9 4) nine_lattice preview(Only images larger than or equal to 8M are supported). 10 vo intf: 11 0) vo HDMI output, default. 12 1) vo BT1120 output. 13 venc type: 14 0) H265, default. 15 1) H264.
- shell 说明:
- 1. 运行 ./sample_fisheye
- 2. 使用说明 ./sample_fisheye <index> <vo intf> <venc type>
- 3. index:
- 4. 0) 2个“半顶装模式”的鱼眼360°全景视频
- 5. 1) 2个普通“地装的PTZ”鱼眼360°全景视频
- 6. 2) 2个普通“壁装的PTZ”鱼眼180°全景视频
- 7. 3) 三个鱼眼原画的普通PTZ 壁装视频
- 8. 4) 九格预览视频(仅支持大于或等于8m的图像)
- 9. vo intf:
- 10. 0) 默认HDMI输出
- 11. 1) BT1120输出
- 12. venc type:
- 13. 0) 默认H265编码
- 14. 1) H264编码
sample_vio(视频输入输出)
1 ~ # ./sample_vio_main 2 Usage : ./sample_vio_main <index> <intf> 3 index: 4 0)VI(Online) - VPSS(Online) - VO. 5 1)VI(Offline)- VPSS(Offline) - VO. LDC+DIS+SPREAD. 6 2)VI(Offline)- VPSS(Online) - VO. Double pipe. 7 3)VI(Online)- VPSS(Offline) - VO. Double chn. 8 4)Resolute Ratio Switch. 9 5)GDC - VPSS LowDelay. 10 6)Double WDR Pipe. 11 7)FPN Calibrate & Correction. 12 8)WDR Switch. 13 9)90/180/270 Rotate. 14 10)Mipi Demux Yuv. 15 11)UserPic. 16 intf: 17 0) vo HDMI output, default. 18 1) vo BT1120 output.
- shell 说明:
- 1. 运行 sample_vio
- 2. 使用方法:./sample_vio_main <index> <intf>
- 3. index:
- 4. 0) 在线输入--> 在线视频处理 -->输出
- 5. 1) 离线输入--> 离线视频处理 -->输出 镜头畸变校正视频防抖和展宽
- 6. 2) 离线输入--> 在线视频处理 -->输出 双管道
- 7. 3) 在线输入--> 离线视频处理 -->输出 双通道
- 8. 4) Resolute Ratio Switch
- 9. 5) 几何畸变矫正 -->视频处理 低延时
- 10. 6) 双WDR管道
- 11. 7) FPN标定&矫正
- 12. 8) WDR 开关
- 13. 9) 90/180/270 旋转
- 14. 10) Mipi Demux Yuv
- 15. 11) 设置用户图片
- 16. intf:
- 17. 0) 默认HDMI输出
- 18. 1) BT1120输出
sample_vgs(Video Graphics Sub-System,视频图形子系统)
1 ~ # ./sample_vgs 2 3 /*****************************************/ 4 Usage: ./sample_vgs <index> 5 index: 6 0) FILE -> VGS(Scale) -> FILE. 7 1) FILE -> VGS(Cover+OSD) -> FILE. 8 2) FILE -> VGS(DrawLine) -> FILE. 9 3) FILE -> VGS(Rotate) -> FILE. 10 /*****************************************/
- shell 说明:
- 1. 运行 sample_vgs
- 4. 使用说明:./sample_vgs <index> <intf>
- 5. index:
- 6. 0) 文件--> 视频图像子系统(缩放) -->文件
- 7. 1) 文件--> 视频图像子系统(Cover+OSD) -->文件
- 8. 2) 文件--> 视频图像子系统(画线) -->文件
- 9. 3) 文件--> 视频图像子系统(旋转) -->文件
sample_tde(Two Dimensional Engine,利用硬件为OSD和GUI提供快速的图形绘制功能)
1 ~ # ./sample_tde 2 Usage : ./sample_tde <intf> 3 intf: 4 0) vo BT1120 output, default. 5 1) vo HDMI output.
- shell 说明:
- 1. 运行 sample_tde
- 2. 使用说明:./sample_tde <intf>
- 3. intf:
- 4. 0) 默认BT1120输出演示
- 5. 1) HDMI输出演示
sample_hifb(Hisilicon Framebuffer,基于Linux FB 基本功能扩展了一些图形层控制功能)
1 ~ # ./sample_hifb 2 Usage : ./sample_hifb <index> <device> <intf> 3 4 5 /****************index******************/ 6 please choose the case which you want to run: 7 0: ARGB8888 standard mode 8 1: ARGB1555 BUF_DOUBLE mode 9 2: ARGB1555 BUF_ONE mode 10 3: ARGB1555 BUF_NONE mode 11 4: ARGB1555 BUF_ONE mode with compress 12 5: ARGB8888 BUF_ONE mode with compress 13 14 /****************device******************/ 15 0) VO device 0#, default. 16 1) VO device 1#. 17 18 /****************intf******************/ 19 0) VO HDMI output, default. 20 1) VO BT1120 output.
- shell 说明:
- 1. 运行 sample_hifb
- 2. 使用说明:./sample_hifb <index> <device> <intf>
- 5. <index>
- 6. 请选择一下您想运行的情况之一
- 7. 0: ARGB8888像素格式标准模式
- 8. 1: ARGB1555像素格式双缓存模式
- 9. 2: ARGB1555像素格式单缓存模式
- 10. 3: ARGB1555像素格式无缓存模式
- 11. 4: ARGB1555像素格式带压缩的单缓存模式
- 12. 5: ARGB8888像素格式带压缩的单缓存模式
- 14. <device>
- 15. 0) 默认输出到超清显示设备DHD0
- 16. 1) 输出到高清显示设备DHD1(暂未支持)
- 18. <intf>
- 19. 0) 默认HDMI输出
- 20. 1) BT1120输出(暂未支持)
sample_awb_calibration(自动白光平衡测量)
1 ~ # ./sample_awb_calibration 2 Usage : ./sample_awb_calibration <mode> <intf1> <intf2> <intf3> 3 mode: 4 0) Calculate Sample gain. 5 1) Adjust Sample gain according to Golden Sample. 6 intf1: 7 The value of Rgain of Golden Sample. 深红色区域的锐化增益控制。 8 intf2: 9 The value of Bgain of Golden Sample. 10 intf3: 11 The value of Alpha ranging from 0 to 1024 (The strength of adusting Sampe Gain will increase with the value of Alpha) .
- shell 说明:
- 1. 运行 sample_awb_calibration
- 2. 使用方法:./sample_awb_calibration <mode> <intf1> <intf2> <intf3>
- 3. <mode>
- 4. 0) 计算例子中的增益
- 5. 1) 根据标准例子来校正例子中的增益
- 6. intf1:
- 7. 标准例子中的深红色区域的锐化增益控制值
- 8. intf2:
- 9. 标准例子中的深蓝色区域的锐化增益控制值
- 10. intf3:
- 11. 0~1024范围的初始值(采样数据的增益强度会随着初始值的值增加而增加)
sample_ive_main(智能加速引擎)
1 ~ # ./sample_ive_main 2 Usage : ./sample_ive_main <index> [complete] [encode] [vo] 3 index: 4 0)BgModel,<encode>:0, not encode;1,encode.<vo>:0,not call vo;1,call vo.(VI->VPSS->IVE->VGS->[VENC_H264]->[VO_HDMI]). 5 1)Gmm,<encode>:0, not encode;1,encode.<vo>:0,not call vo;1,call vo.(VI->VPSS->IVE->VGS->[VENC_H264]->[VO_HDMI]). 6 2)Occlusion detected.(VI->VPSS->IVE->VO_HDMI). 7 3)Motion detected.(VI->VPSS->IVE->VGS->VO_HDMI). 8 4)Canny,<complete>:0, part canny;1,complete canny.(FILE->IVE->FILE). 9 5)Gmm2.(FILE->IVE->FILE). 10 6)MemoryTest.(FILE->IVE->FILE). 11 7)Sobel.(FILE->IVE->FILE). 12 8)Ann.(FILE->IVE->STDIO). 13 9)St Lk.(FILE->IVE->FILE). 14 a)Svm.(FILE->IVE->STDIO). 15 b)Cnn.(FILE->IVE->STDIO).
- shell 说明:
- 1. 运行 sample_ive_main
- 2. 使用说明: ./sample_ive_main <index> [complete] [encode] [vo]
- 3. index:
- 4. 0) 背景模型
- 5. 1) 高斯模型Gmm
- 6. 2) 遮挡检测
- 7. 3) 运动检测
- 8. 4) 边缘检测
- 9. 5) 高斯模型Gmm2
- 10 6) 内存测试
- 11 7) Sobel算子分割
- 12 8) 图像检索Ann
- 13 9) St和LK光流法
- 14 a) 分类器SVM
- 15 b) 神经网络Cnn
sample_dis(Digital Image Stabilization,数字稳像)
1 ~ # ./sample_dis 2 Usage : ./sample_dis <index> <intf> 3 index: 4 0)DIS-4DOF_GME.VI-VO VENC. 5 1)DIS-6DOF_GME.VI-VO VENC. 6 intf: 7 0) vo HDMI output, default. 8 1) vo BT1120 output.
- shell 说明:
- 1. 运行 sample_dis
- 2. 使用说明: ./sample_dis <index> <intf>
- 3. index:
- 4. 0) DIS-4DOF_GME(四自由度 GME 算法,不使用陀螺仪),输入-输出 同时H256格式录像(存储在当前)
- 5. 1) DIS-6DOF_GME(六自由度 GME 算法,不使用陀螺仪),输入-输出 同时H256格式录像(存储在当前)
- 6. intf:
- 7. 0) HDMI 输出
- 8. 1) BT1120 输出
sample_dsp_main(DSP测试)
1 ~ # ./sample_dsp_main
- shell 说明:
- 1. 四个DSP之DSP0的出图测试。
sample_nnie_main(神经网络硬件加速单元测试)
- 1. 神经网络,特别是深度学习卷积神经网络进行加速处理的硬件单元测试。
1 ~ # ./sample_nnie_main 2 Usage : ./sample_nnie_main <index> 3 index: 4 0) RFCN(VI->VPSS->NNIE->VGS->VO). 5 1) Segnet(Read File). 6 2) FasterRcnnAlexnet(Read File). 7 3) FasterRcnnDoubleRoiPooling(Read File). 8 4) Cnn(Read File). 9 5) SSD(Read File). 10 6) Yolov1(Read File). 11 7) Yolov2(Read File). 12 8) LSTM(Read File). 13 9)Pvanet(Read File). 14 a) Rfcn(Read File).
- shell 说明:
- 1. 运行 sample_nnie_main
- 2. 使用说明: ./sample_nnie_main <index>
- 3. index:
- 4. 0) RFCN模型
- 5. 1) 可训练的图像分割Segnet
- 6. 2) 深度学习的目标检测Alexnet
- 7. 3) 深度学习的目标检测DoubleRoiPooling
- 8. 4) 神经网络Cnn
- 9. 5) 可训练的SSD模型处理
- 10. 6) 神经网格模型Yolov1
- 11. 7) 神经网格模型Yolov2
- 12. 8) LSTM模型
- 13. 9) Pvanet网络
- 14. a) Rfcn目标检测
其他功能说明
nfs配置和网络
- 1,pc机安装nfs服务,安装前可以先学习下这个网站内容:https://blog.csdn.net/iamplane/article/details/53912176
- pc机操作示例如下:
1 $ sudo apt-get install nfs-kernel-server 2 $ sudo apt-get install nfs-common 3 $ sudo gedit /etc/exports #添加下面内容/home/nfs *(rw,sync,no_root_squash,no_subtree_check) 4 $ sudo /etc/init.d/rpcbind restart #重启rpcbind 5 $ sudo /etc/init.d/nfs-kernel-server restart #重启nfs服务 6 $ showmount -e #使用此命令后有”/home/nfs“则安装成功
- 2,设备debug串口链接到PC机上,串口参数是115200 8N1(详细见串口接口定义)
- 在设备串口终端上,通过下面命令配置IP eth0:
1 ~ # ifconfig eth0 192.168.8.189
- 在设备串口终端,通过下面命令挂载PC机的/home/nfs目录到设备的/mnt/nfs目录(192.168.8.xx是PC机的IP,和设备eth0的IP处在同一网段即可):
1 ~ # mount -t nfs -o nolock -o tcp 192.168.8.xx:/home/nfs /mnt/nfs 2 ~ # cd /mnt/nfs 3 ~ # ls #查看PC机共享的内容
- 这样PC机共享出/home/nfs目录后,在设备的/mnt/nfs目录就可以访问PC机/home/nfs目录的内容。
继电器使用
- 通过操作GPIO14_2可以控制继电器的断开和闭合。
1 ~# echo 114 > /sys/class/gpio/export #导出GPIO14_2 2 ~# echo out > /sys/class/gpio/gpio114/direction #设置GPIO14_2方向为输出 3 ~# echo 1 > /sys/class/gpio/gpio114/value #控制继电器断开 4 ~# echo 0 > /sys/class/gpio/gpio114/value #控制继电器闭合 5 ~# echo 114 > /sys/class/gpio/unexport #取消GPIO14_2的导出
设置RTC时间
- 查看当前时间
1 ~ # date 2 Mon Jan 8 00:00:01 UTC 2018
- 设置时间并保存到硬件
1 ~ # date -s "2019-1-17 11:38:45" #设置系统时间 2 ~ # hwclock -w #将时间保存到硬件
USB口U盘挂载
- 将U盘插入USB口,会有很多提示信息,其中比较有用的标识是sda: sda1信息(第一个U盘,后面以此是sdb1,sdc1...),然后通过下面命令进行U盘挂载,进入/mnt/usb目录可以看到U盘内容。
1 ~ # mount -t vfat /dev/sda1 /mnt/usb #假设看到的提示信息是sda1 2 ~ # cd /mnt/usb 3 ~ # ls #查看U盘内容
TF口使用
- 将TF卡插入到设备TF卡槽内,重启系统,在终端会有mmc1: new high speed SD card at address 0001提示。使用下面命令进行挂载(mmcblk0是系统emmc使用,TF卡为mmcblk1),在 /mnt/mmc目录下可以看到TF卡里面的内容。
1 ~ # mount -t vfat /dev/mmcblk1p1 /mnt/mmc 2 ~ # cd /mnt/mmc 3 ~ # ls #查看TF卡内容
COM口使用
- 一个COM232,一个COM485,一个debug调试串口,引脚定义详见串口接口定义。
- 软件上COM232口对应的设备是/dev/ttyAMA2,COM485对应的设备是/dev/ttyAMA1,debug串口对应的设备是/dev/ttyS000。
- 调试串口默认参数是115200 8 N 1。
拼接及NNIE开发说明
拼接
- 下载包中Hi3519AV100_PQ_XXX.tar.gz是板端运行的程序,拷贝到板端后解压,执行脚本./HiIspTool.sh -a sensortype (sensortype为configs目录下的文件名,例如:./HiIspTool.sh -a imx290avs);只有先运行板端程序后才可在PC端运行工具。
- 下载包中HiPQTools_XXX.zip是运行在PC上工具,用来调试图像质量,拼接时需要使用该工具采集图像和标定。
- 下载包中ITTP_Stream_XXX.zip是PC端点播工具,用来远程观看板端采集视频。
- 拼接标定步骤请详细参考《拼接调试指南》。
NNIE
- 下载包中HiSVP_PC_XXX.tgz是海思模型转化和仿真工具,目前仅支持caffe模型。
- 用户在caffe框架上训练得到的模型需要使用该工具转化成端板识别的模型,即wk文件。
- 模型转化请参考《HiSVP开发指南》。