Font Size: a A A

The Design And Implementation Of Gateway Between Ethernet And CAN-Bus Based On RT-Thread

Posted on:2018-01-25Degree:MasterType:Thesis
Country:ChinaCandidate:C Q HuFull Text:PDF
GTID:2518305147998039Subject:Circuits and Systems
Abstract/Summary:PDF Full Text Request
In the industrial control system,CAN bus has high reliability and real-time performance,so the distributed control system based on CAN bus has good stability,which is widely used in industry.However,the field control network uses the centralized management way,the equipment can not realize the communication with the enterprise management network.With the application of Ethernet technology in industrial control,it makes possible that the equipment of the field control network connect to the enterprise management network through the Ethernet.The key to realize the connection between the control network based on CAN bus and the management network based on Ethernet enterprise is to solve the problem of protocol conversion between Ethernet and CAN bus.This paper will address this issue and implement communication between these two different networks.In this paper,through study of the principle of the Ethernet technology and CAN bus and achieves the protocol conversion gateway between Ethernet and CAN bus.The gateway realizes the data conversion between the Ethernet data frame and the CAN message,and makes the equipment in the industrial control field connect to the Ethernet,achieves the enterprise management network controlling of the filed equipment remotely.Firstly,this paper analyzes the gateway-related technologies such as CAN bus and Ethernet technology.And then,in consideration of system functional requests and performance requests,the design chooses STM32F103VE as the main controller of the hardware platform,and designs the Ethernet interface circuit and CAN interface circuit according to the gateway functional requirements.Secondly,on the basis of analyzing the principle of RT-Thread,the design realizes its transplantation on the main controller.And then realizes the Ethernet device driver,CAN device driver and protocol conversion program.Finally is the gateway functional verification and performance analysis.In the design and development of the gateway,the paper presents a software watchdog mechanism for real-time task timeout problems.this mechanism is based on the software timer,which can solve the real-time task's timeout problems by dynamically adjusting the priority of the task.This mechanism is implemented on RT-Thread,so the gateway has better real-time performance and reliability through this mechanism.The Ethernet-CAN gateway designs by this paper realizes the interconnection between Ethernet and CAN bus.It has the advantages of high reliability,real-time and low cost,and is suitable for industrial control occasions.
Keywords/Search Tags:Industrial control, CAN bus, Ethernet, RT-Thread, Software watchdog mechanism, Real-time task
PDF Full Text Request
Related items