资料准备:
 香橙派官网资料下载链接:http://www.orangepi.cn/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-AIpro.html
 硬件准备
 香橙派ai pro一个
 32G sd卡,带出厂镜像
 电源
 鼠标
 键盘
 hdmi显示屏
测试介绍
 由于香橙派aipro针对的主打的ai,这里针对经常使用硬件接口做一些测试:
 网络、硬盘、hdmi显示、摄像头等
 后续更新在香橙派跑ai算法部分
一、到货开机测试
 1、到货图
 
 
 
2、硬件连接
 手头有鼠标键盘,直接把板子当作pc用,hdmi显示器需要连接靠近usb插座那个插座,电源是最边上那个turb-c接口
 
正常启动的时候风扇会全速转声音有点大,启动后就有调速,声音就没那么大了
 **
 **
 登录
 默认sd卡出厂镜像是ubuntu
 密码Mind@123
 
wifi联网
 
测试网络是否通畅
 ping 百度 ping www.baidu.com
 
测速
 这里使用speedtest
 安装speedtest:sudo apt-get install speedtest-cli
 测速:speedtest-cli
 
 
网速还算正常
二、摄像头测试
 由于手里只有usb接口的uvc摄像头,这里使用的uvc协议的摄像头做测试验证
 使用cheese工具
 安装工具:sudo apt-get install cheese
 测试摄像头:sudo cheese /dev/video0
 /dev/video0 是根据摄像头插上后ubuntu生成的设备文件,获取方法插上摄像头,然后ls /dev/v*
 看对应的摄像头是哪个,一般默认是video0
 
三、稳定性测试
 这里使用的出厂sd卡镜像作为测试
 开机连续运行了10天,系统正常
 查看系统运行时间测试命令:uptime
 
四、ssd硬盘测试
 由于可能涉及存储大的文件,所以买了个m2的ssd硬盘
 这里用的京东京造的512G硬盘
 
硬盘安装
 
查看到硬盘信息 sudo fdisk -l | grep “nvme0n1”
 
硬盘测速
 使用hdparm测试读取速度
 使用dd测试写入速度
 安装hdparm工具:sudo apt-get install hdparm
 查看硬盘设备文件:ls /dev/nvme*
 测试读取速度命令:sudo hdparm -Tt /dev/nvme0n1
 测试写入速度命令:sudo dd if=/dev/nvme0n1 of=tempfile bs=1M count=1000 conv=fdatasync
 查看硬盘文件名
 
测试读取速度
 
测试写入速度
 
五、测试opencv打开摄像头
 opencv默认已经安装,只需安装依赖库
 pip install opencv-contrib-python
 opencv python测试程序testopencv.py:
import cv2cap = cv2.VideoCapture(0)
if not cap.isOpened():print("Cannot open camera")exit()
while(True):
ret, frame = cap.read()
cv2.imshow('Camera', frame)
key = cv2.waitKey(1)
if(key & 0xff == ord('q')):
break;
cap.release()
cv2.destroyAllWindows()
运行测试程序
python testopencv.py

 
六、GPU测试
 这里使用glmark2
 glmark2工具安装:sudo apt install glmark2
 GPU测试命令:glmark2

 
最后得分80分,还算可以
 七、CPU测试
 这里使用sysbench工具加压测试看性能
 安装工具:sudo apt-get install sysbench
 测试命令:sysbench cpu --time=10 --threads=4 --cpu-max-prime=20000 run
 查看cpu信息:lscpu
 
CPU测试
 
八、yolov5测试
 按照用户手册说明,出厂已经安装好yolov5
 demo路径:/home/HwHiAiUser/samples/notebooks
 运行方法:
 执行启动脚本:./start_notebook.sh
 回出现以下打印:
(base) HwHiAiUser@orangepiaipro:~/samples/notebooks$ ./start_notebook.sh 
[W 2024-06-11 22:45:07.353 ServerApp] A `_jupyter_server_extension_points` function was not found in notebook_shim. Instead, a `_jupyter_server_extension_paths` function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
[I 2024-06-11 22:45:07.355 ServerApp] jupyter_lsp | extension was successfully linked.
[I 2024-06-11 22:45:07.368 ServerApp] jupyter_server_terminals | extension was successfully linked.
[I 2024-06-11 22:45:07.384 ServerApp] jupyterlab | extension was successfully linked.
[I 2024-06-11 22:45:08.113 ServerApp] notebook_shim | extension was successfully linked.
[I 2024-06-11 22:45:08.284 ServerApp] notebook_shim | extension was successfully loaded.
[I 2024-06-11 22:45:08.290 ServerApp] jupyter_lsp | extension was successfully loaded.
[I 2024-06-11 22:45:08.293 ServerApp] jupyter_server_terminals | extension was successfully loaded.
[I 2024-06-11 22:45:08.300 LabApp] JupyterLab extension loaded from /usr/local/miniconda3/lib/python3.9/site-packages/jupyterlab
[I 2024-06-11 22:45:08.300 LabApp] JupyterLab application directory is /usr/local/miniconda3/share/jupyter/lab
[I 2024-06-11 22:45:08.301 LabApp] Extension Manager is 'pypi'.
[I 2024-06-11 22:45:08.310 ServerApp] jupyterlab | extension was successfully loaded.
[I 2024-06-11 22:45:08.311 ServerApp] Serving notebooks from local directory: /home/HwHiAiUser/samples/notebooks
[I 2024-06-11 22:45:08.311 ServerApp] Jupyter Server 2.12.5 is running at:
[I 2024-06-11 22:45:08.311 ServerApp] http://127.0.0.1:8888/lab?token=c16d8cad18133675eec04c90ef3c1c0d49a1578b6bc8980b
[I 2024-06-11 22:45:08.311 ServerApp]     http://127.0.0.1:8888/lab?token=c16d8cad18133675eec04c90ef3c1c0d49a1578b6bc8980b
[I 2024-06-11 22:45:08.311 ServerApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 2024-06-11 22:45:08.321 ServerApp]
利用自带的火狐浏览器登录以下网页
http://127.0.0.1:8888/lab?token=c16d8cad18133675eec04c90ef3c1c0d49a1578b6bc8980b

点击运行即可出现结果
 
运行官方的demo速度还行
九、总结
 整体硬件对应常用的ai开发如人脸等模型应用是足够的,后续更新使用香橙派自己的ncu加速模型