节点文献

基于CANopen-EtherNet/IP的协议转换模块研究

Research of Protocol Conversion Module Based on CANopen-EtherNet/IP

【作者】 许东辉

【导师】 陈在平;

【作者基本信息】 天津理工大学 , 模式识别与智能系统, 2012, 硕士

【摘要】 控制器局域网CAN定义了物理层和数据链路层,但没有在应用层定义报文标识符和数据字节的使用。CANopen是一种基于CAN总线的开放的、标准化的应用层协议,并在国内外的工业自动化领域中得到广泛应用。EtherNet/IP是工业以太网的缩写,是一种开放的、适用于工业环境的通信网络。它采用了以太网TCP/IP协议和工业以太网标准,在应用层则采用CIP协议进行实时I/O控制和点对点的信息交换。因其结合了CIP技术与以太网技术的优点,所以在工业自动化网络领域具有巨大的发展潜力。本文首先分析了CANopen协议规范,主要是DS301V402应用层和通信子协议。然后,对于CANopen协议栈CAN-Festival、 EtherNet/IP协议及其协议栈OpENer进行了分析。课题选用S3C2440A微处理器、MCP2510独立CAN控制器、DM9000E以太网MAC控制器为核心的硬件平台,并设计与实现了电路模块。系统软件平台为基于Linux2.6.30内核的嵌入式操作系统,采用交叉编译。编写基于S3C2440A微处理器和Linux内核的CAN驱动程序,协议栈的驱动程序接口,及支持CANopen协议主站基本功能的主程序,从而实现CAN-Festival协议栈到目标平台的移植,建立一个基于嵌入式Linux平台的CANopen主站。在OpENer协议栈实例的基础上建立一个基于嵌入式Linux平台的EtherNet/IP从站。然后通过建立两个命名管道实现Linux系统下同时运行的EtherNet/IP从站进程与CANopen主站进程之间的双向数据交换,从而实现CANopen网络与EtherNet/IP网络间的通信。最后,通过接入CANopen和EtherNet/IP网络的目标平台上的实验验证了该协议转换模块是可行与有效的。

【Abstract】 Only the physical layer and the data link layer are defined in CAN field bus, but the usage of identifier and data in CAN message are not defined in application layer. CANopen is an open and standardized application layer protocol based on CAN, and it is widely used in industrial automation field both at home and abroad.EtherNet/IP, the abbreviation of industrial Ethernet, is a communication system which is open and suitable for use in industrial environments. It uses Ethernet with TCP/IP protocol and industrial Ethernet standard, and CIP protocol is used to accomplish real-time I/O control and point-to-point information exchange. By merging advantages of CIP and Ethernet technology, it has great development potential in the field of industrial automation network.CANopen protocol specification, especially DS301V402application layer and communication profile, is analyzed first in this paper. Then CAN-Festival, which is a protocol stack of CANopen, is analyzed. EtherNet/IP protocol and its protocol stack OpENer are analyzed too. The core of the hardware platform of the subject consists of S3C2440A microprocessor, MCP2510independent CAN controller and DM9000E Ethernet MAC controller. In addition, the circuit module is designed and implemented. The system software platform is an embedded operating system based on Linux2.6.30kernel and cross compiling is used. CAN driver based on S3C2440A microprocessor and Linux kernel, the driver interface of the protocol stack, and the main program supporting basic functions of a master defined in CANopen protocol are written. Then CAN-Festival protocol stack could be transplanted to the target platform and a CANopen master based on embedded Linux platform could be set up.An EtherNet/IP slave based on embedded Linux platform is set up on the basis of an example of OpENer protocol stack. Then two named pipes are built to achieve bi-directional data exchange between EtherNet/IP slave process and CANopen master process, which are run on Linux at the same time. By this way, communication between CANopen and EtherNet/IP network could be realized. Finally, experiments on the target platform in CANopen and EtherNet/IP network are implemented to verify the feasibility and validity of the protocol conversion module.

节点文献中: