| With the rapid development of social economy and the wide application of advanced technologies of the computer,electronics and other disciplines in the field of automobiles,the performance specifications of automobiles are continuously improved.The running parameters and fault information of electric vehicles can be automatically stored inside the computer by means of the advanced fault diagnostic system of the controller,and this is benefit to monitor all aspects of performance indicators and to ensure the security and stability of the vehicle running.At present,the performance of homemade electric vehicle controllers has already achieved to a higher level,but the fault diagnostic system is still in development and universalized in our country.In this paper,the fault diagnostic system of the D-type DC separately excited motor controller for small electric vehicles are studied,including the design of the system interface and software programming.The C#language are used to compile software for the upper computer of the fault diagnostic system,the.NET Framework 4.5 is chosen as the software operation framework,and the compilation environment is the visual studio 2013.The main function of fault diagnostic system is analyzed and its architecture is established in this paper.Data sending and receiving is the main and important functions and designed by means of the Serial Port.Sending data needs to converted the parameters to hexadecimal communication protocol and sent it to the controller,according to the parameter conversion standards,and the multithreaded programming of serial communication is usually in the employ of data receiving,which will make more easily for some software programming of the upper computer.The design joins the new thread to handle the hexadecimal communication protocol sent out from the controller and converted to visible parameters displayed in the interface,and then it will reach the purpose of obtaining programmable parameters.In addition,a database table is also established,the stored procedure programming of querying,adding and removing fault history data in the diagnosis system is finished,and the operation method is written.The parameter test and actual running test of the designed diagnostic system are completed in Tianjin Qingyuan Electric Vehicle Co.Ltd..The practical problems encountered during testing have been analysis one by one,the improvement action scheme is put forward,then the program revise is finished,and finally the run test is passed successfully. |