Zynq UltraScale+ MPSoC-5EV:CAN驱动问题
1.使用 ifconfig -a
查看CAN驱动是否加载成功
2.启动CAN
设备
ip link set can4 down //关闭CAN
ip link set can4 up //开启CAN
3.设置CAN
波特率
//设置波特率为500K
ip link set can4 type can bitrate 500000
4.使用petalinux
配置Linux
系统中:busybox
自带的 ip
命令并不支持对 can
的操作,所以需要更改为iproute2
;不然会报错:
5.在petalinux
下使用命令进入文件系统
//使用命令进入文件系统
petalinux-config -c rootfs
6.进入 Filesystem Packages --> base -->iproute
选中 iproute2
;保存后退出配置界面
7.重新编译petalinux
:
petalinux-build
8.重新打包合成 BOOT.BIN文件
petalinux-package --boot --u-boot --fpga --force
"欢迎关注个人公众号:Kevin的学习站";一起交流学习自动驾驶和嵌入式相关的知识!