一. 前言
OK3568-C开发板是飞凌出品的一款高性能开发板。OK3568-C开发板采用核心板+底板的分体式设计,将FET3568-C核心板的全部功能引脚以最便利的方式引出。方便用户二次开发的同时,还添加了接口EMC防护参考设计,简化用户设计,利于现场评估测试。
详见帖子和视频
http://bbs.eeworld.com.cn/thread-1259363-1-1.html
【飞凌OK3568-C开发板360度无死角开箱】 https://www.bilibili.com/video/BV1B94y1t71N/?share_source=copy_web
二. 烧录系统出厂的固件可能不符合需求,所以可以先进行系统升级。
解压OK3568-C_Forlinx Desktop 20.04_用户资料_R3\Linux\工具\DriverAssitant_v5.11.zip
以管理员身份安装DriverInstall.exe
OTG的Type-C口接电脑。
S2拨码开关打到 ON处。
解压RKDevTool_Release_v2.86.zip\RKDevTool_Release_v2.86.zip到全英文路径(否则后面可能无法识别LOADER设备)
打开解压的RKDevTool.exe
按住Recovery按键不松,上电(或者按一下reset按键复位)
识别设备如下,此时可以松开Recovery按键

升级固件->固件
选择OK3568-C_Forlinx Desktop 20.04_用户资料_R3\Linux\镜像\update.img
需要加载一会

点击擦除Flash擦除

点击升级开始升级


烧录完后先不要断电,需要重启两次才能最终完成。
重启后按space按键可以进入uboot设置显示模式。
如果卡在提示pcie错误的地方
failed to initialize host
则多重启几次试试,或者重启按space按键进入uboot修改下显示模式试试。
从上可以看出升级非常简单。
三. 串口登录
接DEBUG处的Type-C接口到PC
用户名和密码分别是
forlinx forlinx和
root root
串口参数
115200-8-n-1

手册中介绍了使用桌面操作连接WIFI,这里就介绍下使用命令行进行操作
sudo su
输入密码forlinx切换到root
ifconfig可以看到mlan0即对应WIFI
mlan0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether 14:13:33:b3:2c:29 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
sudo ip link set mlan0 up 启用网卡
wpa_supplicant -B -i mlan0 -c<(wpa_passphrase "wifiname" "password") 连接WIFI
//wpa_supplicant -B -i mlan0 -c<(wpa_passphrase "qiqiqiqi" "cqmygysdss")
dhclient mlan0 自动获取IP
此时再ifconfig看到获取到了IP
mlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.31.14 netmask 255.255.255.0 broadcast 192.168.31.255
ether 14:13:33:b3:2c:29 txqueuelen 1000 (Ethernet)
RX packets 281 bytes 9268 (9.2 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 23 bytes 2612 (2.6 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
ping www.baiud.com 测试连接外网OK
root@ok3568:~# ping www.baidu.com
PING www.a.shifen.com (120.232.145.144) 56(84) bytes of data.
64 bytes from 120.232.145.144: icmp_seq=1 ttl=51 time=24.3 ms
64 bytes from 120.232.145.144: icmp_seq=2 ttl=51 time=26.5 ms
^C
--- www.a.shifen.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 24.286/25.415/26.544/1.129 ms
root@ok3568:~#
五. SSH登录
前面连接了WIFI后则同一网络下的PC主机可以通过无线网络SSH登录开发板。
之前ifconfig看到的开发板IP为
192.168.31.14
我这里使用CRT



如果提示如下则修改

vi /etc/ssh/sshd_config
#PermitRootLogin prohibit-password改为
PermitRootLogin yes

再重启
六. 配置VNC远程桌面
在没有HDMI显示器和鼠键时可以使用VNC远程桌面进行桌面环境访问,实现轻办公开发的使用需求。
sudo apt update
sudo apt upgrade
sudo apt install xfce4 xfce4-goodies xorg dbus-x11 x11-xserver-utils -y
sudo apt install tigervnc-standalone-server tigervnc-common -y
输入vncserver回车
root@ok3568:~# vncserver
提示输入密码
You will require a password to access your desktops.
Password:
Verify:
提示如下输入n
Would you like to enter a view-only password (y/n)? n
/usr/bin/xauth: file /root/.Xauthority does not exist
New 'ok3568:1 (root)' desktop at :1 on machine ok3568
Starting applications specified in /etc/X11/Xvnc-session
Log file is /root/.vnc/ok3568:1.log
Use xtigervncviewer -SecurityTypes VncAuth -passwd /root/.vnc/passwd :1 to connect to the VNC server.
编辑启动文件
vi ~/.vnc/xstartup
输入如下内容
#!/bin/sh
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
exec startxfce4
添加可执行权限
chmod +x ~/.vnc/xstartup
输入vncserver -localhost no回车
提示如下
root@ok3568:~# vncserver -localhost no
New 'ok3568:2 (root)' desktop at :2 on machine ok3568
Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/ok3568:2.log
Use xtigervncviewer -SecurityTypes VncAuth,TLSVnc -passwd /root/.vnc/passwd ok3568:2 to connect to the VNC server.
PC端安装VNCviewer
File->New Connection
输入IP和端口,端口5902时上面提示的ok3568:2 (root)




apt-get install mesa-utils
glxinfo |grep rendering 输出如下direct rendering: Yes
glxgears
查看帧率

sudo apt install glmark2
glmark2

详见视频
【飞凌OK3568-C开发板GPU性能测试】 https://www.bilibili.com/video/BV1Fw411z7eD/?share_source=copy_web&vd_source=30f88a61ba48d80acfe41f622b10a844
八. 玩转3D晒车游戏sudo apt install torcs
/usr/games/torcs

详见视频
【飞凌OK3568-C开发板玩转3D赛车游戏】 https://www.bilibili.com/video/BV1UN4y1r7gz/?share_source=copy_web&vd_source=30f88a61ba48d80acfe41f622b10a844
九. 板上C开发-sqlite3构建与性能测试得益于开发板强劲的性能和可以运行完整的Ubuntu系统,我们完全可以直接板上进行开发,避免交叉开发的繁琐。
sudo apt install git
sudo apt install make
sudo apt install gcc
sudo apt install tcl-dev
sudo apt install zlib1g-dev
git clone https://github.com/sqlite/sqlite.git
cd sqlite/
mkdir build
cd build
../configure
time make sqlite3.c

time make
大概要30min,sqlite3代码是非常多的,还是可以接受的

运行
./sqlite3

测试
time make test


git clone https://github.com/FFmpeg/FFmpeg.git
cd FFmpeg/
./configure
time make -j8 && make install

打开ffmpeg

打开ffprobe

性能测试
ffmpeg -benchmark -i big_buck_bunny_720p_10mb.mp4 -f null -
网络视频播放器Demo
apt install lrzsz
rz导入视频pocket_video.mp4
PC端从如下地址下载安装VLC
ifconfig查看开发板ip为192.168.31.14
PC上ipconfig查看ip为 192.168.31.64
ffmpeg -re -i pocket_video -an -vcodec copy -f rtp rtp://192.168.31.64:5004
打印如下
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709, progressive), 1024x576 [SAR 1:1 DAR 16:9], q=2-31, 1428 kb/s, 24 fps, 24 tbr, 90k tbn (default)
Metadata:
creation_time : 2022-12-07T13:35:33.000000Z
handler_name : Core Media Video
vendor_id : [0][0][0][0]
SDP:
v=0
o=- 0 0 IN IP4 127.0.0.1
s=No Name
c=IN IP4 192.168.31.64
t=0 0
a=tool:libavformat 60.15.101
m=video 5004 RTP/AVP 96
b=AS:1428
a=rtpmap:96 H264/90000
a=fmtp:96 packetization-mode=1; sprop-parameter-sets=Z2QAH6zZgEAEmwFqAgICgAAAAwCAAAAYB4wYzQ==,aOl4ssiw; profile-level-id=64001F
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press [q] to stop, [?] for help
复制如下部分

在PC端新建demo.sdp文件,粘体上述内容

然后使右键点击该sdp文件用VLC打开。
看到开始播放


详见视频
十一. 总结1. 开发板性能强劲,接口丰富,非常适合二次开发和评估使用。
2. 接口有EMC,ESD防护设计,利于现场评估测试。
3. 官方资料非常完善,是学习首选。
4. 官方技术支持非常不错。