Abstract:In order to carry out the program update and fault diagnosis of electric vehicle more conveniently, an underlying programming protocol stack in line with ISO15765 standards is developed. Referring to the BOSCH ECU online programming progress, the XC2000 programming process is proposed,which include initialization, key authentication, Flash partion erasing, Flash partion writing, etc. The XC2000 Flash driver has been developed to implement Flash block erasing and writing by address, and Bootloader has been developed to implement hardware resource initialization and loading IS015765 protocol stack. An underlying fault diagnosis protocol stack in line with ISO15765 standards is developed to implement reading DTC, clearing DTC, reading data flow, actuator test etc. An electric vehicle diagnosis host computer system is developed, which is tested by the Hardware-in-the-loop Test Bench. And the results show that the electric vehicle diagnosis system based on CAN bus have both ECU online programming and fault diagnosis functions.