"There is no science without measurement".The Automatic Test System(ATS)is of great significance to the development and quality assurance of complex electromechanical systems.As an important part of the automatic test system,the modular general test platform has become an important development direction of the test instrument.Based on the new combined automatic test hardware system developed by the research group,this paper designs a set of real-time test equipment bus communication scheme,protocol and driver implementation,focusing on solving the real-time performance of high-speed data transmission and the standardization of interfaces.The main contents of the research include:(1)Research on the overall program.Combined with the hardware characteristics of the test equipment developed by the research group and the specific actual requirements,aiming at the design goals of generalization,simplicity and flexibility,a research framework and scheme of automatic test equipment bus driver is proposed.(2)Real-time improvement of embedded operating system.Research and analyze the reasons for the lack of real-time performance,introduce real-time preemption patches to improve real-time performance,study its key technologies,and complete the system transplantation.(3)Design and realization of bus-driven communication.According to the requirements of real-time and stability,the driver is divided into the kernel operation layer and the user management layer,and the hard interrupt is designed to reduce the response time of communication processing.Analyze and study the trigger characteristics of the bus,and design the transmission mode of concurrency and arbitration.According to the communication requirements of the test application software,standardize the communication protocol,standardize the data type and content,and realize flexible and reliable data transmission without master and slave.(4)Hierarchical design and implementation of bus driver.Extract the commonality of test equipment hardware,abstract hardware resources,and divide drivers into resource managers,front-end module resources,communication session resources and trigger line resources.Hierarchical and modular design and implementation of the driver are implemented to facilitate subsequent maintenance management and function addition.Provide a unified standard interface to decouple hardware devices from test software and reduce development costs.Finally,a test platform is built for test verification and result analysis.The results show that the real-time performance of the operating system is good,and the bus-driven communication is stable and efficient.The communication bit error rate of one million frames is 0 %,the average response time of the message channel is 31 us,and the transmission speed of the data channel can reach 3826 Mbps,reaching the expected target. |