Diagnostic instrument communication mode switching method and device, storage medium and program product

By obtaining the service ID of the CAN protocol in the diagnostic device, we can judge the communication speed level and automatically switch the communication mode, from Bluetooth to WIFI, the problem of inefficient communication in scenarios such as ECU flashing is solved, and faster data transmission and lower maintenance costs are achieved.

CN119545401APending Publication Date: 2025-02-28LAUNCH TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411794108.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-06
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

In some scenarios where high-speed communication is required, such as during the ECU flashing process, the communication efficiency of traditional diagnostic instruments is low and the data transmission speed is slow, resulting in a long flashing time. The communication mode switching requires manual intervention, which increases the operation complexity and error rate.

Method used

By obtaining the service ID of the CAN protocol during communication between the diagnostic instrument and the lower computer, we judge the communication speed level, and switch the corresponding diagnostic instrument communication mode according to the level, and switch from Bluetooth mode to WIFI mode to improve communication efficiency.

Benefits of technology

It realizes efficient data transmission in high-speed communication scenarios such as ECU flashing and writing, significantly reduces flashing time, simplifies operational processes, reduces maintenance costs, and improves communication stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119545401A_ABST
    Figure CN119545401A_ABST
Patent Text Reader

Abstract

The invention discloses a diagnostic apparatus communication mode switching method and device, a storage medium and a program product, relates to the technical field of data processing, and discloses a diagnostic apparatus communication mode switching method comprising the following steps: obtaining a service ID of a CAN protocol in a communication process of a diagnostic apparatus and a lower computer; judging a communication speed level according to the service ID; and switching a corresponding diagnostic apparatus communication mode according to the communication speed grade. According to the method, whether the ECU flashing function is executed or not is identified according to the specific service ID in the diagnosis communication protocol, so that the current Bluetooth communication mode is automatically switched to the WIFI mode with the faster speed, the communication efficiency is improved, the ECU flashing time is greatly shortened, the operation is simplified, manual intervention is reduced, the communication stability is enhanced, and the maintenance cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and in particular to a diagnostic instrument communication mode switching method, device, storage medium and program product. Background Art

[0002] In the process of modern automobile diagnosis and maintenance, the communication efficiency and stability of the diagnostic instrument are key factors affecting the maintenance efficiency and quality.

[0003] The communication mode of traditional diagnostic instruments is usually fixed. For example, the default Bluetooth communication can meet basic diagnostic functions, such as code reading, code clearing, data flow, and other diagnostic functions that do not have strict requirements on speed and time. It cannot be dynamically switched according to actual communication needs, resulting in some scenarios that require high-speed communication. For example, during the ECU flashing process, the data transmission speed of Bluetooth communication is relatively slow, and there is a certain communication delay. The communication efficiency is low, and the flashing time required is long. Especially when flashing multiple ECUs, the problems of time and efficiency are more prominent. In addition, the switching of communication modes usually requires manual intervention, which increases the complexity and error rate of operations, seriously affects the efficiency of maintenance and diagnosis, and reduces the user experience.

[0004] In response to the above problems, the market and technology urgently need a new communication technology or solution to improve the speed and efficiency of diagnostic instruments when performing large data transmission tasks such as flashing ECUs, so that it can be widely used in various diagnostic scenarios.

[0005] The above contents are only used to assist in understanding the technical solution of the present application and do not constitute an admission that the above contents are prior art. Summary of the invention

[0006] The main purpose of this application is to provide a diagnostic instrument communication mode switching method, device, storage medium and program product, aiming to solve the technical problems of low communication efficiency, slow data transmission speed and long flashing time in certain scenarios requiring high-speed communication, such as during ECU flashing.

[0007] To achieve the above-mentioned purpose, the present application proposes a method for switching the communication mode of a diagnostic instrument, the method comprising:

[0008] Get the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer;

[0009] Determine the communication speed level according to the service ID;

[0010] The corresponding diagnostic instrument communication mode is switched according to the communication speed level.

[0011] In one embodiment, the step of obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer includes:

[0012] Initialize the working mode of the CAN controller to send and receive data;

[0013] Construct a request message and send it to the target node in the network via the CAN bus;

[0014] Switch the working mode to monitoring mode to monitor the CAN bus and wait for the response of the target node;

[0015] Parse the response information of the target node in the received CAN frame and extract the service ID.

[0016] In one embodiment, the step of obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer further includes:

[0017] Verify whether the service ID complies with the specification of the CAN protocol. If the service ID does not comply with the specification of the CAN protocol, prompt the user to re-acquire the service ID.

[0018] In one embodiment, determining the communication speed level according to the service ID includes:

[0019] Determine the execution function to which the service ID belongs;

[0020] If the service ID belongs to a basic diagnostic function, the service ID corresponds to a normal communication speed level;

[0021] If the service ID belongs to the ECU flashing function, the service ID corresponds to a high-speed communication speed level.

[0022] In one embodiment, the step of switching the corresponding diagnostic instrument communication mode according to the communication speed level includes:

[0023] Compare and query the service ID with a predefined communication speed level mapping table;

[0024] Obtaining the correct communication speed level corresponding to the service ID according to the comparison query result;

[0025] If the received communication speed level is inconsistent with the correct communication speed level, the user is prompted to re-determine the communication speed level.

[0026] In one embodiment, the step of switching the corresponding diagnostic instrument communication mode according to the communication speed level includes:

[0027] Initialize the diagnostic instrument communication mode;

[0028] Receive the communication speed level corresponding to the service ID;

[0029] When the service ID is at a normal communication speed level, the communication mode of the diagnostic instrument is switched to Bluetooth mode through the APK;

[0030] When the service ID is a high-speed communication speed level, the communication mode of the diagnostic instrument is switched to WIFI mode through APK.

[0031] In one embodiment, after the step of switching the corresponding diagnostic instrument communication mode according to the communication speed level, the step further includes:

[0032] Verify whether the diagnostic instrument communication mode is successfully switched to the target communication mode;

[0033] If the response data packet received by the diagnostic instrument from the target node to the test message conforms to the predefined response data packet, it is determined that the communication mode of the diagnostic instrument is successfully switched to the target communication mode; otherwise, it is determined that the communication mode of the diagnostic instrument is not successfully switched.

[0034] In addition, to achieve the above-mentioned purpose, the present application also proposes a diagnostic instrument communication mode switching device, the diagnostic instrument communication mode switching device comprising:

[0035] The data acquisition module is used to obtain the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer;

[0036] A level determination module, used for determining the communication speed level according to the service ID;

[0037] The communication switching module is used to switch the corresponding diagnostic instrument communication mode according to the communication speed level.

[0038] In addition, to achieve the above-mentioned purpose, the present application also proposes a diagnostic instrument communication mode switching device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, and the computer program is configured to implement the steps of the diagnostic instrument communication mode switching method described above.

[0039] In addition, to achieve the above-mentioned purpose, the present application also proposes a storage medium, which is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by the processor, the steps of the diagnostic instrument communication mode switching method described above are implemented.

[0040] In addition, to achieve the above-mentioned purpose, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, it implements the steps of the diagnostic instrument communication mode switching method as described above.

[0041] One or more technical solutions proposed in this application have at least the following technical effects:

[0042] By obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer; judging the communication speed level according to the service ID; switching the corresponding diagnostic instrument communication mode according to the communication speed level; it solves the technical problems of low communication efficiency, slow data transmission speed and long flashing time in certain scenarios requiring high-speed communication, such as ECU flashing. Compared with the existing technology, it can identify whether to execute the ECU flashing function according to the specific service ID in the diagnostic communication protocol, thereby automatically switching the current Bluetooth communication mode to the faster WIFI mode, which is beneficial to improving communication efficiency and significantly reducing ECU flashing time. At the same time, it simplifies operations to reduce manual intervention, enhances communication stability and reduces maintenance costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0044] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0045] Figure 1 A flow chart of the first embodiment of the method for switching the communication mode of the diagnostic instrument provided in the present application;

[0046] Figure 2 A flow chart of the second embodiment of the method for switching the communication mode of the diagnostic instrument provided in the present application;

[0047] Figure 3 A flow chart of the third embodiment of the method for switching the communication mode of the diagnostic instrument provided in the present application;

[0048] Figure 4 A flowchart of a fourth embodiment of the method for switching the communication mode of the diagnostic instrument of the present application is provided;

[0049] Figure 5 A flowchart of a fifth embodiment of the method for switching the communication mode of the diagnostic instrument of the present application is provided;

[0050] Figure 6 This is a schematic diagram of the module structure of the communication mode switching device of the diagnostic instrument according to the embodiment of the present application;

[0051] Figure 7 Schematic diagram of the device structure of the hardware operating environment involved in the diagnostic instrument communication mode switching method in the embodiment of the present application.

[0052] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0053] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.

[0054] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.

[0055] Because the existing technology has technical problems such as low communication efficiency, slow data transmission speed and long flashing time in some scenarios that require high-speed communication, such as ECU flashing process

[0056] The present application provides a solution, which obtains the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer; determines the communication speed level according to the service ID; switches the corresponding diagnostic instrument communication mode according to the communication speed level; and can identify whether to execute the ECU flashing function according to the specific service ID in the diagnostic communication protocol, thereby automatically switching the current Bluetooth communication mode to the faster WIFI mode, which is beneficial to improving communication efficiency and significantly reducing the ECU flashing time, while simplifying operations to reduce manual intervention, enhance communication stability, and reduce maintenance costs.

[0057] Based on this, the embodiment of the present application provides a method for switching the communication mode of a diagnostic instrument, referring to Figure 1 , Figure 1 This is a flow chart of the first embodiment of the method for switching the communication mode of the diagnostic instrument of the present application.

[0058] In this embodiment, the diagnostic instrument communication mode switching method includes steps S10 to S30:

[0059] Step S10, obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer;

[0060] It should be noted that the full name of the diagnostic instrument is an automobile fault diagnostic instrument, which can be used to detect and diagnose automobile electronic control unit (ECU) faults; the diagnostic instrument receives CAN messages from a lower computer through a CAN interface; the lower computer usually refers to the vehicle's electronic control unit ECU, and each ECU communicates with each other through the vehicle's network such as the CAN bus; different diagnostic protocols will also have different service IDs.

[0061] Step S20, determining the communication speed level according to the service ID;

[0062] It should be noted that a mapping table between service IDs and communication speed levels may be predefined, and the mapping table indicates data transmission speed requirements corresponding to different service IDs; the communication speed levels may also be classified according to the urgency and data volume of data transmission.

[0063] Step S30, switching the corresponding diagnostic instrument communication mode according to the communication speed level;

[0064] It should be noted that the communication mode of the diagnostic instrument includes at least a Bluetooth mode and a WIFI mode, wherein the speed of WIFI is usually dozens or even hundreds of times that of Bluetooth communication.

[0065] This embodiment obtains the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer; determines the communication speed level according to the service ID; and switches the corresponding diagnostic instrument communication mode according to the communication speed level. According to the specific service ID in the diagnostic communication protocol, it is identified whether to execute the ECU flashing function, thereby automatically switching the current Bluetooth communication mode to a faster WIFI mode, which is conducive to improving communication efficiency, greatly reducing the ECU flashing time, simplifying operations to reduce manual intervention, enhancing communication stability, and reducing maintenance costs.

[0066] Further, refer to Figure 2 The second embodiment of the method for switching the communication mode of the diagnostic instrument of the present application provides a flow chart based on the above Figure 2 The embodiment shown further refines the "obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer" in step S10, including steps A201 to A204:

[0067] Step A201, initializing the working mode of the CAN controller to send and receive data;

[0068] It should be noted that the connection between the diagnostic instrument and the CAN bus is usually achieved through the OBD-II interface; the working modes of the CAN controller include at least working mode, monitoring mode and test mode, wherein the normal mode user sends and receives data, the monitoring mode user detects bus communication, and the test mode is used for fault diagnosis or special testing.

[0069] Step A202, constructing a request message and sending it to a target node in the network via the CAN bus;

[0070] It should be noted that the diagnostic instrument constructs a request message according to the diagnostic service to be performed, and the request message usually includes a specific service ID for identifying the type of request; the request message is encapsulated into one or more CAN frames and sent to the target node in the network via the CAN bus.

[0071] Step A203, switching the working mode to the monitoring mode to monitor the CAN bus and wait for the response of the target node;

[0072] It should be noted that after the diagnostic instrument sends a request, the working mode of the CAN controller is switched to the monitoring mode, and the diagnostic instrument starts to monitor the data transmission on the CAN bus.

[0073] Step A204, parsing the response information of the target node in the received CAN frame and extracting the service ID;

[0074] It should be noted that the service ID is a response representation to the request message sent by the diagnostic instrument; the service ID is extracted by reading and decoding specific data bits in the CAN frame.

[0075] Specifically, when the diagnostic instrument needs to execute a diagnostic service of reading the coolant temperature of the vehicle, the diagnostic instrument constructs a request message to represent the request to read the coolant temperature. The request message is encapsulated into one or more CAN frames and sent to the vehicle's ECU via the CAN bus. At this time, the diagnostic instrument switches to monitoring mode to monitor the data transmission on the CAN bus and waits for the response of the vehicle's ECU. When the diagnostic instrument receives the response CAN frame sent by the vehicle ECU, it parses the data in the response CAN frame and extracts a service ID of 0C, indicating that the response is a response to the request to read the coolant temperature.

[0076] This embodiment extracts the service ID by parsing the response information of the target node in the CAN frame received by the diagnostic instrument, thereby ensuring communication compatibility, ensuring that the diagnostic instrument can recognize and understand the response content of the ECU, enabling the diagnostic instrument to quickly obtain the required information, and improving the efficiency and accuracy of automobile fault diagnosis.

[0077] In a feasible implementation manner, after "obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer" in step S10, the following is further included:

[0078] Verify whether the service ID complies with the specification of the CAN protocol. If the service ID does not comply with the specification of the CAN protocol, prompt the user to re-acquire the service ID.

[0079] It should be noted that the verification process includes checking whether the service ID is within the valid range defined by the CAN protocol and whether it matches the requested service type; if the service ID does not comply with the provisions of the CAN protocol, it may mean that an error has occurred during the communication process, such as data corruption, interference or other technical problems; the diagnostic instrument can notify the user of the invalid service ID through the user interface, such as screen display, sound reminder, etc., and suggest that the user re-execute the steps to obtain the service ID.

[0080] This embodiment can avoid performing diagnostic operations based on erroneous or non-standard data by verifying whether the service ID complies with the specifications of the CAN protocol, ensure the accuracy and reliability of communication, and improve the efficiency and security of the entire diagnostic process.

[0081] Further, refer to Figure 3 The third embodiment of the method for switching the communication mode of the diagnostic instrument of the present application provides a flow chart based on the above Figure 3 In the embodiment shown, the step S20 of "determining the communication speed level according to the service ID" is further refined to include steps A301 to A303:

[0082] Step A301, determine the execution function to which the service ID belongs;

[0083] It should be noted that the communication speed level includes ordinary communication speed level and high-speed communication speed level; the ordinary communication level is suitable for basic diagnostic functions that do not require high transmission speed, such as reading fault codes, data flow monitoring, etc., and the high-speed communication speed level is suitable for operations that require high transmission speed, such as ECU flashing. Such operations require faster data transmission speed to reduce operation time.

[0084] Step A302, if the service ID belongs to a basic diagnostic function, the service ID corresponds to a normal communication speed level;

[0085] Step A303, if the service ID belongs to the ECU flashing function, then the service ID corresponds to the high-speed communication speed level.

[0086] It should be noted that for each service ID received, the diagnostic instrument determines whether it belongs to the category of basic diagnostic functions or the category of ECU flashing functions. For service IDs that perform basic diagnostic functions, ordinary communication speed levels can usually meet the communication requirements of these basic functions while saving system resources; for service IDs of ECU flashing functions that require higher data transmission speeds, high-speed communication speed levels can reduce the time required for ECU flashing and improve maintenance efficiency and vehicle availability.

[0087] Specifically, in the judgment of the service ID for reading fault codes, the service ID for reading fault codes defined in the CAN protocol is "01". When the diagnostic instrument recognizes that the service ID is "01", it classifies it as a normal communication speed level, which is sufficient to meet the communication request for reading fault codes.

[0088] This embodiment determines the communication speed level through the service ID, wherein the diagnostic instrument can automatically select the appropriate communication speed level according to different service IDs, thereby optimizing the communication efficiency and response speed of the entire diagnostic process.

[0089] Further, refer to Figure 4 The fourth embodiment of the method for switching the communication mode of the diagnostic instrument of the present application provides a flow chart based on the above Figure 4 The embodiment shown in the figure further includes steps A401 to A403 before "switching the corresponding diagnostic instrument communication mode according to the communication speed level" in step S30:

[0090] Step A401, comparing the service ID with a predefined communication speed level mapping table;

[0091] It should be noted that the defined communication speed level mapping table indicates the correct communication levels corresponding to different service IDs, and the communication speed level mapping table is regularly updated and maintained, and when the communication level mapping table is updated, the user is immediately notified and the local mapping table is updated.

[0092] Step A402, obtaining the correct communication speed level corresponding to the service ID according to the comparison query result;

[0093] It should be noted that the correct communication level is preset based on the CAN protocol and the requirements of the vehicle ECU.

[0094] Step A403, if the received communication speed level is inconsistent with the correct communication speed level, prompting the user to re-determine the communication speed level;

[0095] It should be noted that if the communication speed level determined by the diagnostic instrument based on the service ID is inconsistent with the correct communication speed level queried in the mapping table, it indicates that there may be an error or interference; the diagnostic instrument can prompt the user through the user interface that there may be an error in the communication speed level determination, and suggest that the user re-determine the communication speed level.

[0096] This implementation verifies the received communication speed level based on the service ID, helping to prevent communication problems or diagnostic errors caused by incorrect communication speed level.

[0097] Further, refer to Figure 5 The fifth embodiment of the method for switching the communication mode of the diagnostic instrument of the present application provides a flow chart based on the above Figure 5 The embodiment shown further refines the "switching the corresponding diagnostic instrument communication mode according to the communication speed level" in step S30, including steps A501 to A504:

[0098] Step A501, initializing the diagnostic instrument communication mode;

[0099] Step A502, receiving the communication speed level corresponding to the service ID;

[0100] It should be noted that the diagnostic instrument receives the corresponding communication speed level according to the previously verified and queried service ID, and the communication speed level is determined based on the service ID and the predefined mapping table.

[0101] Step A503, when the service ID is a normal communication speed level, switching the communication mode of the diagnostic instrument to a Bluetooth mode through the APK;

[0102] It should be noted that the APK file is a format for distributing and installing applications; switching communication modes through APK usually involves the development of APK applications, which contain code logic for switching communication modes, and interact with the operating system interface of the diagnostic instrument to configure Bluetooth, WIFI or other communication modules; the APK can be installed on the diagnostic instrument through a USB connection, network system or built-in application market; after starting the APK application on the diagnostic instrument, a user interface is provided to allow the user to select or automatically detect the required communication mode; the APK sends a message to the diagnostic instrument that the Bluetooth or WIFI module has been configured based on the user's input or the automatic detection result of the service ID. If the WIFI mode is selected, the APK will ensure that the WIFI module is turned on and connected to the correct network; the Bluetooth mode is suitable for basic diagnostic functions that do not require high transmission speeds. The maximum rate of the Bluetooth 5.2 standard is maintained at around 42Mbps, which is used for diagnostic functions such as reading fault codes and data flow monitoring.

[0103] Specifically, optimize the switching strategy of the communication mode to reduce delays and data loss during the switching process. A smooth switching strategy can be adopted. During the switching process, the data transmission of the old communication mode can be gradually reduced, and the data transmission of the new communication mode can be increased to ensure the continuity and stability of data transmission; record the switching process and results of the communication mode, such as the time, reason, result and other information of the switching, and store the switching records in a database or local file.

[0104] Step A504, when the service ID is a high-speed communication speed level, switching the diagnostic instrument communication mode to a WIFI mode through the APK;

[0105] It should be noted that under the 802.11n standard, the WIFI speed ranges from 72Mbps to 600Mbps, and under the 802.11ac standard, the speed ranges from 433Mbps to 6933Mbps. The new generation of routers and devices generally support this standard. Under the 802.11ax (WIFI6) standard, the speed ranges from 600Mbps to 9608Mbps, further improving the transmission speed and reducing latency. The WIFI mode is suitable for operations that require higher transmission speeds, such as ECU flashing. Such operations require faster data transmission speeds to reduce operation time.

[0106] Specifically, before starting the diagnostic process, the diagnostic instrument communication mode is initialized to receive a new communication mode configuration. When the service ID is "36" after verification and query, according to the predefined mapping table, the service ID corresponds to the high-speed communication speed level, and the ECU flash function is executed. The diagnostic instrument automatically switches its communication mode to WIFI mode through APL.

[0107] In this embodiment, the diagnostic instrument can automatically switch to the most suitable communication mode according to the communication speed level corresponding to the service ID, thereby accelerating the communication efficiency and response speed of the entire diagnostic process.

[0108] In a feasible implementation manner, after "switching the corresponding diagnostic instrument communication mode according to the communication speed level" in step S30, the following steps are further included:

[0109] Verify whether the diagnostic instrument communication mode is successfully switched to the target communication mode;

[0110] If the response data packet received by the diagnostic instrument from the target node to the test message conforms to the predefined response data packet, it is determined that the communication mode of the diagnostic instrument is successfully switched to the target communication mode; otherwise, it is determined that the communication mode of the diagnostic instrument is not successfully switched.

[0111] It should be noted that the working mode of the CAN controller can be switched to the test mode, and the test information can be sent to the target node through the diagnostic instrument, and the target node's response to the test message can be received. The received response data packet is compared with the expected result, and the key information and results of the verification process are recorded to generate a verification log. The verification log may include information such as the test information generation, communication status check, response data packet reception, and expected result comparison; wherein the expected result is a response data packet pre-defined according to the "normal communication speed level" or "high-speed communication speed level", and the comparison result is used to confirm whether the communication mode of the diagnostic instrument has been successfully switched; the sign of successful switching is that the response data packet contains the correct data structure and the expected response information; if it is determined that the communication mode of the diagnostic instrument has not been successfully switched, the diagnostic instrument should prompt the user or automatically retry the communication mode switching process, and the automatic retry may include automatically reinitializing the communication mode, resending the test message, etc.

[0112] This embodiment can ensure the stability of the communication link by verifying the switching of the communication mode, and can help quickly locate the problem and repair it by recording the fault diagnosis information, thereby improving the efficiency of troubleshooting.

[0113] It should be noted that the above examples are only used to understand the present application and do not constitute a limitation on the communication mode switching method of the diagnostic instrument of the present application. More simple transformations based on this technical concept are all within the protection scope of the present application.

[0114] In addition, this application also provides a diagnostic instrument communication mode switching device, please refer to Figure 6 , the diagnostic instrument communication mode switching device comprises:

[0115] The data acquisition module is used to obtain the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer;

[0116] A level determination module, used for determining the communication speed level according to the service ID;

[0117] The communication switching module is used to switch the corresponding diagnostic instrument communication mode according to the communication speed level.

[0118] The diagnostic instrument communication mode switching device provided by the present application adopts the diagnostic instrument communication mode switching method in the above-mentioned embodiment, which can solve the technical problems of low communication efficiency, slow data transmission speed and long flashing time in certain scenarios requiring high-speed communication, such as during ECU flashing. Compared with the prior art, the beneficial effects of the diagnostic instrument communication mode switching device provided by the present application are the same as the beneficial effects of the diagnostic instrument communication mode switching method provided by the above-mentioned embodiment, and the other technical features in the diagnostic instrument communication mode switching device are the same as the features disclosed in the above-mentioned embodiment method, which will not be repeated here.

[0119] In addition, the present application provides a diagnostic instrument communication mode switching device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the diagnostic instrument communication mode switching method in the above-mentioned embodiment one.

[0120] Reference below Figure 7 , which shows a schematic diagram of the structure of a diagnostic instrument communication mode switching device suitable for implementing the embodiment of the present application. The diagnostic instrument communication mode switching device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 7 The diagnostic instrument communication mode switching device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0121] like Figure 7As shown, the diagnostic instrument communication mode switching device may include a processing device 1001 (such as a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM: Read Only Memory) 1002 or a program loaded from a storage device 1003 to a random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the diagnostic instrument communication mode switching device are also stored. The processing device 1001, ROM1002 and RAM1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touchpad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the diagnostic instrument communication mode switching device to communicate wirelessly or wired with other devices to exchange data. Although the diagnostic instrument communication mode switching device with various systems is shown in the figure, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or have alternatively.

[0122] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.

[0123] The diagnostic instrument communication mode switching device provided by the present application adopts the diagnostic instrument communication mode switching method in the above embodiment, which can solve the technical problems of low communication efficiency, slow data transmission speed and long flashing time in certain scenarios requiring high-speed communication, such as during ECU flashing. Compared with the prior art, the beneficial effects of the diagnostic instrument communication mode switching device provided by the present application are the same as the beneficial effects of the diagnostic instrument communication mode switching method provided by the above embodiment, and the other technical features in the diagnostic instrument communication mode switching device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.

[0124] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.

[0125] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

[0126] In addition, the present application provides a computer-readable storage medium having computer-readable program instructions (ie, computer programs) stored thereon, and the computer-readable program instructions are used to execute the diagnostic instrument communication mode switching method in the above-mentioned embodiment.

[0127] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination of the above.

[0128] The computer-readable storage medium may be included in the diagnostic instrument communication mode switching device; or may exist independently without being assembled into the diagnostic instrument communication mode switching device.

[0129] The above-mentioned computer-readable storage medium carries one or more programs. When the above-mentioned one or more programs are executed by the diagnostic instrument communication mode switching device, the diagnostic instrument communication mode switching device: obtains the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer; determines the communication speed level according to the service ID; and switches the corresponding diagnostic instrument communication mode according to the communication speed level.

[0130] Computer program code for performing the operations of the present application may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0131] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a sequence different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0132] The modules involved in the embodiments of the present application may be implemented by software or hardware, wherein the name of the module does not limit the unit itself in some cases.

[0133] The readable storage medium provided by the present application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned diagnostic instrument communication mode switching method, and can solve the technical problems of low communication efficiency, slow data transmission speed, and long flashing time in certain scenarios requiring high-speed communication, such as the ECU flashing process. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the present application are the same as the beneficial effects of the diagnostic instrument communication mode switching method provided by the above-mentioned embodiment, and will not be repeated here.

[0134] In addition, the present application also provides a computer program product, including a computer program, which implements the steps of the above-mentioned diagnostic instrument communication mode switching method when executed by a processor.

[0135] The computer program product provided by the present application can solve the technical problems of low communication efficiency, slow data transmission speed and long flashing time in certain scenarios requiring high-speed communication, such as during ECU flashing. Compared with the prior art, the beneficial effects of the computer program product provided by the present application are the same as the beneficial effects of the diagnostic instrument communication mode switching method provided by the above embodiment, and will not be repeated here.

[0136] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.

Claims

1. A method for switching a diagnostic instrument communication mode, characterized in that: The method comprises: Get the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer; Determine the communication speed level according to the service ID; The corresponding diagnostic instrument communication mode is switched according to the communication speed level.

2. The method according to claim 1, characterized in that The step of obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer includes: Initialize the working mode of the CAN controller to send and receive data; Construct a request message and send it to the target node in the network via the CAN bus; Switch the working mode to monitoring mode to monitor the CAN bus and wait for the response of the target node; Parse the response information of the target node in the received CAN frame and extract the service ID.

3. The method according to claim 2, characterized in that The step of obtaining the service ID of the CAN protocol during the communication between the diagnostic instrument and the lower computer also includes: Verify whether the service ID complies with the specification of the CAN protocol. If the service ID does not comply with the specification of the CAN protocol, prompt the user to re-acquire the service ID.

4. The method according to claim 3, characterized in that Determining the communication speed level according to the service ID includes: Determine the execution function to which the service ID belongs; If the service ID belongs to a basic diagnostic function, the service ID corresponds to a normal communication speed level; If the service ID belongs to the ECU flashing function, the service ID corresponds to a high-speed communication speed level.

5. The method according to claim 4, characterized in that The step of switching the corresponding diagnostic instrument communication mode according to the communication speed level includes: Compare and query the service ID with a predefined communication speed level mapping table; Obtaining the correct communication speed level corresponding to the service ID according to the comparison query result; If the received communication speed level is inconsistent with the correct communication speed level, the user is prompted to re-determine the communication speed level.

6. The method according to claim 5, characterized in that The step of switching the corresponding diagnostic instrument communication mode according to the communication speed level comprises: Initialize the diagnostic instrument communication mode; Receive the communication speed level corresponding to the service ID; When the service ID is at a normal communication speed level, the communication mode of the diagnostic instrument is switched to Bluetooth mode through the APK; When the service ID is a high-speed communication speed level, the communication mode of the diagnostic instrument is switched to WIFI mode through APK.

7. The method according to claim 6, characterized in that After the step of switching the corresponding diagnostic instrument communication mode according to the communication speed level, the following step is further included: Verify whether the diagnostic instrument communication mode is successfully switched to the target communication mode; If the response data packet received by the diagnostic instrument from the target node to the test message conforms to the predefined response data packet, it is determined that the communication mode of the diagnostic instrument is successfully switched to the target communication mode; otherwise, it is determined that the communication mode of the diagnostic instrument is not successfully switched.

8. A diagnostic instrument communication mode switching device, characterized in that: The device comprises: a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the diagnostic instrument communication mode switching method as described in any one of claims 1 to 7.

9. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the diagnostic instrument communication mode switching method as described in any one of claims 1 to 7 are implemented.

10. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the diagnostic instrument communication mode switching method as claimed in any one of claims 1 to 7 are implemented.