李皓瑜, 唐荣斌, 李开强, 舒庆文. Linux下使用SocketCAN进行CAN总线通信[J]. 云南大学学报(自然科学版), 2014, 36(S2): 35-40. doi: 10.7540/j.ynu.2014a06
引用本文: 李皓瑜, 唐荣斌, 李开强, 舒庆文. Linux下使用SocketCAN进行CAN总线通信[J]. 云南大学学报(自然科学版), 2014, 36(S2): 35-40. doi: 10.7540/j.ynu.2014a06
LI Haoyu, TANG Rongbin, LI Kaiqiang, SHU Qingwen. Design of CAN bus communication using socket CAN on Linux[J]. Journal of Yunnan University: Natural Sciences Edition, 2014, 36(S2): 35-40. DOI: 10.7540/j.ynu.2014a06
Citation: LI Haoyu, TANG Rongbin, LI Kaiqiang, SHU Qingwen. Design of CAN bus communication using socket CAN on Linux[J]. Journal of Yunnan University: Natural Sciences Edition, 2014, 36(S2): 35-40. DOI: 10.7540/j.ynu.2014a06

Linux下使用SocketCAN进行CAN总线通信

Design of CAN bus communication using socket CAN on Linux

  • 摘要: Linux下基于字符设备模型的CAN总线驱动由于种种缺陷而逐渐被人们摒弃,取而代之的是基于网络设备模型的SocketCAN,SocketCAN的出现极大的简化了Linux下CAN总线通信程序的编写.介绍了SocketCAN产生的背景、实现,比较了SocketCAN与传统CAN总线驱动之间的差异和优缺点,并介绍了Linux下SocketCAN相关的工具集使用,以及编写CAN总线通信程序的基本方法.

     

    Abstract: On the basis of character device model on Linux,the CAN bus driver has been abandoned. Beyond the foundation of character device model network equipment model,SocketCAN has replaced it,because of all kinds of defects of CAN bus driver.The emergence of SocketCAN is greatly simplified programming of CAN bus communication on Linux.It is illustrated that the background and implementation of SocketCAN in this paper.Specifially,it is described the strengths and weaknesses of SocketCAN when comparing with the traditional CAN bus driver,as well as the toolsets of ScocketCAN and basic methods of writing program code on Linux.

     

/

返回文章
返回