peak_driver_linux_installation.txt

来自「CANopen源代码」· 文本 代码 · 共 72 行

TXT
72
字号
Linux : Installing the Peak driver for USB/PCI - CAN board-----------------------------------------------------------(Mandrake 10.2 edition 2005, kernel 2.6.11)One of the advantage to use the driver developped by Peak-system isthe common api for all the boards USB or PCI, and the systems : Win32(2k, XP, ...) and Linux (2.4, 2.6)1 - Download the driver-----------------------http://www.peak-system.com/linux/2 - Installation-----------------# Uncompresstar xvzf peak-linux-driver.3.21.tar.gzcd  peak-linux-driver-3.21Read the Peak intallation document.su rootmake cleanmakemake installmodprobe pcan3 - Test--------cd test./receivetest -f=/dev/pcan0  connect the board to generator of can message.If it does not receive the message, put a 120 ohm resistance in the network.======================================What does "make install" ?cp pcan.ko /lib/modules/2.6.11-6mdk/misc/pcan.kocp pcan_make_devices /usr/local/bin/pcan_make_devicesif test -z ; then\        cp /etc/modprobe.conf /etc/modprobe.conf~;\        echo ""                                               >> /etc/modprobe.conf;\        echo "# pcan - automatic made entry, begin --------"  >> /etc/modprobe.conf;\        echo "# options pcan type=isa,sp           # see documentation"  >> /etc/modprobe.conf;\        echo "install pcan /sbin/modprobe --ignore-install pcan; /usr/local/bin/pcan_make_devices 2"                                       >> /etc/modprobe.conf;\        echo "# pcan - automatic made entry, end ----------"  >> /etc/modprobe.conf;\        echo ""                                               >> /etc/modprobe.conf;\fi/sbin/depmodcp pcan.h /usr/include/pcan.hchmod 644 /usr/include/pcan.hmake[1]: Leaving directory `/home/pgr/can_peak_linux_driver/peak-linux-driver-3.21/driver'make[1]: Entering directory `/home/pgr/can_peak_linux_driver/peak-linux-driver-3.21/lib'cp libpcan.so.0.3 /usr/lib/libpcan.so.0.3ln -sf /usr/lib/libpcan.so.0.3 /usr/lib/libpcan.so.0ln -sf /usr/lib/libpcan.so.0 /usr/lib/libpcan.socp libpcan.h /usr/include/libpcan.hchmod 644 /usr/include/libpcan.h/sbin/ldconfigmake[1]: Leaving directory `/home/pgr/can_peak_linux_driver/peak-linux-driver-3.21/lib'make[1]: Entering directory `/home/pgr/can_peak_linux_driver/peak-linux-driver-3.21/test'cp receivetest /usr/local/bincp transmitest /usr/local/bincp bitratetest /usr/local/bin

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?