Fault Diagnosis Method, Electronic Device, and Storage Medium
20230228818 · 2023-07-20
Inventors
- Pinhui Chen (Dongguan, CN)
- Weicai Zeng (Dongguan, CN)
- Yuanji He (Dongguan, CN)
- Bo Xie (Dongguan, CN)
- Xiujiang Ma (Dongguan, CN)
Cpc classification
G01R19/165
PHYSICS
International classification
Abstract
A fault diagnosis method includes detecting a state of a relay device, sending a fault diagnosis trigger signal to the relay device based on the stateto enable the relay device to enter a fault diagnosis mode, where the fault diagnosis trigger signal includes one or more of a variable supply voltage value, a transmit/receive control signal, and a diagnosis control signal, detecting a state of the relay device in the fault diagnosis mode, determining a fault code based on the state, and determining a fault based on the fault code.
Claims
1-13. (canceled)
14. A method comprising: detecting a first state of a relay device; sending a fault diagnosis trigger signal to the relay device based on the first state to enable the relay device to enter a fault diagnosis mode, wherein the fault diagnosis trigger signal comprises one or more of a variable supply voltage value, a transmit/receive control signal, or a diagnosis control signal; detecting a second state of the relay device in the fault diagnosis mode; determining a fault code based on the second state; and determining a fault based on the fault code.
15. The method of claim 14, wherein detecting the first state comprises detecting a first relay power supply current (V.sub.TX) in a transmit period and a second relay power supply current (V.sub.RX) in a receive period, and wherein the method further comprises further sending the fault diagnosis trigger signal to the relay device when V.sub.TX is less than a preset first threshold, V.sub.TX is greater than a preset second threshold, V.sub.RX is less than a preset third threshold, or V.sub.RX is greater than a preset fourth threshold.
16. The method of claim 14, wherein detecting the first state comprises detecting a third state of a transmit path of the relay device in a transmit period, and wherein the method further comprises further sending the fault diagnosis trigger signal to the relay device when the transmit path is in an abnormal state.
17. The method of claim 14, further comprising adjusting the variable supply voltage value based on the first state to obtain an adjusted variable supply voltage value, wherein sending the fault diagnosis trigger signal comprises sending the adjusted variable supply voltage value to the relay device.
18. The method of claim 14, further comprising adjusting an output duty cycle of the transmit/receive control signal based on the first state to obtain an adjusted transmit/receive control signal, wherein sending the fault diagnosis trigger signal comprises sending the adjusted transmit/receive control signal to the relay device.
19. The method of claim 14, wherein detecting the second state comprises detecting a relay power supply current (V.sub.TX) of the relay device in a transmit period in the fault diagnosis mode, and wherein determining the fault code comprises: determining a first code when V.sub.TX is less than a preset threshold; determining a second code when V.sub.TX is greater than or equal to the preset threshold; obtaining a code set in M consecutive transmit periods, wherein the code set comprises at least one of the first code or the second code; and determining the fault code based on the code set.
20. The method of claim 19, wherein obtaining the code set comprises: obtaining a first code set of the relay device from a first transmit period to an N.sup.th transmit period in the fault diagnosis mode, wherein the first code set comprises at least one of the first code or the second code; and obtaining a second code set from an (N+1).sup.th transmit period to an (N+M).sup.th transmit period when the first code set matches a preset code set, wherein the second code set comprises at least one of the first code or the second code, and wherein the method further comprises further determining the fault code based on the second code set.
21. An electronic device comprising: a memory configured to store instructions; and a processor coupled to the memory and configured to execute the instructions to cause the electronic device to: detect a first state of a relay device; send a fault diagnosis trigger signal to the relay device based on the first state to enable the relay device to enter a fault diagnosis mode, wherein the fault diagnosis trigger signal comprises one or more of a variable supply voltage value, a transmit/receive control signal, or a diagnosis control signal; detect a second state of the relay device in the fault diagnosis mode; determine a fault code based on the second state; and determine a fault based on the fault code.
22. The electronic device of claim 21, wherein the processor is further configured to execute the instructions to cause the electronic device to: detect a first relay power supply current (V.sub.TX) in a transmit period and a second relay power supply current (V.sub.RX) in a receive period; and further send the fault diagnosis trigger signal to the relay device when V.sub.TX is less than a preset first threshold, V.sub.TX is greater than a preset second threshold, V.sub.RX is less than a preset third threshold, or V.sub.RX is greater than a preset fourth threshold.
23. The electronic device of claim 21, wherein the processor is further configured to execute the instructions to cause the electronic device to: detect a third state of a transmit path of the relay device in a transmit period; and further send the fault diagnosis trigger signal to the relay device when the transmit path is in an abnormal state.
24. The electronic device of claim 21, wherein the processor is further configured to execute the instructions to cause the electronic device to adjust the variable supply voltage value based on the first state to obtain an adjusted variable supply voltage value, and wherein the adjusted variable supply voltage value is the fault diagnosis trigger signal.
25. The electronic device of claim 21, wherein the processor is further configured to execute the instructions to cause the electronic device to adjust an output duty cycle of the transmit/receive control signal based on the first state to obtain an adjusted transmit/receive control signal, and wherein the adjusted transmit/receive control signal is the fault diagnosis trigger signal.
26. The electronic device of claim 21, wherein the processor is further configured to execute the instructions to cause the electronic device to: detect a relay power supply current (V.sub.TX) of the relay device in a transmit period in the fault diagnosis mode; determine a first code when V.sub.TX is less than a preset threshold; determine a second code when V.sub.TX is greater than or equal to the preset threshold; obtain a code set in M consecutive transmit periods, wherein the code set comprises at least one of the first code or the second code; and determine the fault code based on the code set.
27. The electronic device of claim 26, wherein the processor is further configured to execute the instructions to cause the electronic device to: obtain a first code set of the relay device from a first transmit period to an N.sup.th transmit period in the fault diagnosis mode, wherein the first code set comprises at least one of the first code or the second code; obtain a second code set from an (N+1).sup.th transmit period to an (N+M).sup.th transmit period when the first code set matches a preset code set, wherein the second code set comprises at least one of the first code or the second code; and further determine the fault code based on the second code set.
28. A computer program product comprising computer-executable instructions that are stored on a non-transitory computer-readable storage medium and that, when executed by a processor, cause an electronic device to: detect a first state of a relay device; send a fault diagnosis trigger signal to the relay device based on the first state to enable the relay device to enter a fault diagnosis mode, wherein the fault diagnosis trigger signal comprises one or more of a variable supply voltage value, a transmit/receive control signal, or a diagnosis control signal; detect a second state of the relay device in the fault diagnosis mode; determine a fault code based on the second state; and determine a fault based on the fault code.
29. The computer program product of claim 28, wherein the computer-executable instructions further cause the electronic device to: detect a first relay power supply current (V.sub.TX) in a transmit period and a second relay power supply current (V.sub.RX) in a receive period; and further send the fault diagnosis trigger signal to the relay device when V.sub.TX is less than a preset first threshold, V.sub.TX is greater than a preset second threshold, V.sub.RX is less than a preset third threshold, or V.sub.RX is greater than a preset fourth threshold.
30. The computer program product of claim 28, wherein the computer-executable instructions further cause the electronic device to: detect a third state of a transmit path of the relay device in a transmit period; and further send the fault diagnosis trigger signal to the relay device when the transmit path is in an abnormal state.
31. The computer program product of claim 28, wherein the computer-executable instructions further cause the electronic device to adjust the variable supply voltage value based on the first state to obtain an adjusted variable supply voltage value, and wherein the adjusted variable supply voltage value is the fault diagnosis trigger signal.
32. The computer program product of claim 28, wherein the computer-executable instructions further cause the electronic device to adjust an output duty cycle of the transmit/receive control signal based on the first state to obtain an adjusted transmit/receive control signal, and wherein the adjusted transmit/receive control signal is the fault diagnosis trigger signal.
33. The computer program product of claim 28, wherein the computer-executable instructions further cause the electronic device to: detect a relay power supply current (V.sub.TX) of the relay device in a transmit period in the fault diagnosis mode; determine a first code when V.sub.TX is less than a preset threshold; determine a second code when V.sub.TX is greater than or equal to the preset threshold; obtain a code set in M consecutive transmit periods, wherein the code set comprises at least one of the first code or the second code; and further determine the fault code based on the code set.
Description
BRIEF DESCRIPTION OF DRAWINGS
[0068]
[0069]
[0070]
[0071]
[0072]
[0073]
[0074]
[0075]
[0076]
[0077]
[0078]
[0079]
[0080]
[0081]
DESCRIPTION OF EMBODIMENTS
[0082] The following describes technical solutions in embodiments of this application with reference to the accompanying drawings in embodiments of this application. In the descriptions of embodiments of this application, “/” means “or” unless otherwise specified. For example, A/B may represent A or B. In this specification, “and/or” describes only an association relationship for describing associated objects and represents that three relationships may exist. For example. A and/or B may represent the following three cases: Only A exists, both A and B exist, and only B exists.
[0083] The terms “first” and “second” mentioned below are merely intended for a purpose of description, and shall not be understood as an indication or implication of relative importance or implicit indication of the quantity of indicated technical features. Therefore, a feature limited by “first” or “second” may explicitly indicate or implicitly include one or more such features. In the description of embodiments of this application, unless otherwise stated, “a plurality of” means two or more than two.
[0084] A conventional in-vehicle mobile communication system generally includes an in-vehicle terminal and an antenna. The in-vehicle terminal is directly connected to the external antenna, and may perform fault diagnosis on the antenna through direct current voltage division.
[0085] Currently, a relay amplifier is generally added between the in-vehicle terminal and the antenna to compensate for a loss of a line. In this scenario, the in-vehicle terminal supplies power to the relay amplifier by using a radio frequency coaxial cable. Therefore, the circuit in
[0086] Based on the foregoing problem, embodiments of this application provide a fault diagnosis method.
[0087] The technical solutions provided in embodiments of this application may be applied to an in-vehicle terminal. A specific form of the in-vehicle terminal that executes the technical solutions is not specially limited in this application.
[0088]
[0089]
[0090] The fault diagnosis method provided in embodiments of this application is described with reference to
[0091] Step 701: Detect a state of a relay device, and send a fault diagnosis trigger signal to the relay device based on the state, so that the relay device enters a fault diagnosis mode.
[0092] Specifically, an in-vehicle terminal may detect the state of the relay device. The in-vehicle terminal may be a telematics box (Telematics Box, TBOX), or may be another type of vehicle head unit. The relay device may be a relay amplifier, or may be a relay component that performs signal compensation.
[0093]
[0094] The state of the relay device may be detected by the in-vehicle terminal by performing current detection on a power supply that supplies power to the relay device . In this case, whether a connection between the in-vehicle terminal and the relay device is faulty may be determined. In specific implementation, as shown in
[0095] Further, after detecting that the relay device is faulty, the in-vehicle terminal may send the fault diagnosis trigger signal to the relay device. The fault diagnosis trigger signal may be used to trigger the relay device to enter the fault diagnosis mode. In this case, the relay device may send a fault code to the in-vehicle terminal. The fault diagnosis trigger signal may include one or more of a variable supply voltage value, a transmit/receive control signal, and a diagnosis control signal.
[0096] Optionally, the relay device may enter the fault diagnosis mode by changing an output voltage by the in-vehicle terminal. In specific implementation, as shown in
[0097] Optionally, the relay device may enter the fault diagnosis mode by changing, by the in-vehicle terminal, an output duty cycle of the transmit/receive control signal in the transmit period. In specific implementation, as shown in
[0098] Optionally, after power-on, the in-vehicle terminal may directly set a power supply voltage of the relay device to V.sub.det, so that the relay device enters the fault diagnosis mode. Alternatively, after power-on, the in-vehicle terminal may change the output duty cycle of the transmit/receive control signal, so that the relay device enters the fault diagnosis mode. For example, in a scenario such as installation self-test or power-on self-test, after powering on the relay device each time, the in-vehicle terminal directly enables the relay device to enter the fault diagnosis mode.
[0099] Optionally, the relay device may detect a fault of the relay device and a fault of the antenna. If the relay device detects at least one of the fault of the relay device and the fault of the antenna fault, the relay device may actively turn off a transmit path. This causes abnormality of the transmit period. After detecting the abnormality of the transmit period, the in-vehicle terminal may set the power supply voltage of the relay device to V.sub.det, so that the relay device enters the fault diagnosis mode. Alternatively, the in-vehicle terminal changes the output duty cycle of the transmit/receive control signal, so that the relay device enters the fault diagnosis mode. For example, in a scenario in which a radio frequency cable falls off, an antenna falls off, or a relay is damaged, the relay device may actively turn off the transmit path, to notify the in-vehicle terminal that the current relay device is faulty. In this case, the in-vehicle terminal sends a signal to the relay device, so that the relay device enters the fault diagnosis mode.
[0100] Step 702: Detect a state of the relay device in the fault diagnosis mode, determine a fault code based on the state, and determine a fault based on the fault code.
[0101] Specifically, after entering the fault diagnosis mode, the relay device may send the fault code to the in-vehicle terminal. The fault code may be implemented by detecting a power supply current of the relay device. In specific implementation, as shown in
[0102] Further, before sending the fault code, the relay device may further perform moment alignment with the in-vehicle terminal, to avoid mistakenly transmitting information. In specific implementation, after sending the fault diagnosis trigger signal to the relay device, the in-vehicle terminal may further send a signal of a transmit period to the relay device. After the relay device enters the fault diagnosis mode, if the relay device receives the signal of the transmit period from the in-vehicle terminal, the relay device may be controlled, in the transmit period, to be in a transmit state, a receive state, or a current load state, so as to send a handshake code to the in-vehicle terminal. The handshake code may be implemented in the foregoing power supply current detection manner. For example, the in-vehicle terminal may continuously send N transmit periods to the relay device, so that codes in the N consecutive transmit periods can be detected. It is assumed that N is set to 3 and the handshake code is set to 101. After three transmit periods, if the in-vehicle terminal detects a code 101, it may be considered that the handshake code is correct. In this case, the in-vehicle terminal may continue to send a signal of a transmit period to the relay amplifier, to detect the fault code of the relay device. After the relay device successfully performs a handshake with the in-vehicle terminal, the relay device may continue to send the fault code by controlling the power supply current value. For example, the in-vehicle terminal may continuously send M transmit periods to the relay device, so that codes in the M consecutive transmit periods can be detected. It is assumed that M is set to 5. In this case, after five transmit periods, if the in-vehicle terminal detects a code 10111, corresponding fault information may be queried based on the fault code 10111.
[0103] Further, if the in-vehicle terminal verifies that the handshake code of the relay device is incorrect, another handshake may be started. In specific implementation, after the in-vehicle terminal fails to perform a handshake with the relay device, the in-vehicle terminal may power off and restart the relay device, may send a fault diagnosis trigger signal to the relay device again, and send a signal of a transmit period after sending the fault diagnosis trigger signal, to perform a handshake with the relay device again. After receiving the fault diagnosis trigger signal, the relay device may adjust the power supply current again based on the signal of the transmit period of the in-vehicle terminal, so that the in-vehicle terminal can detect the handshake code. A maximum quantity of handshake times may be preset. If the quantity of handshake times exceeds a predetermined quantity of times, it may be considered that the relay is faulty and cannot communicate normally. Therefore, current diagnosis may be terminated.
[0104]
[0105] The detection module 1310 is configured to: detect a state of a relay device, and send a fault diagnosis trigger signal to the relay device based on the state, so that the relay device enters a fault diagnosis mode, where the fault diagnosis trigger signal includes one or more of a variable supply voltage value, a transmit/receive control signal, and a diagnosis control signal.
[0106] The diagnosis module 1320 is configured to: detect a state of the relay device in the fault diagnosis mode, determine a fault code based on the state, and determine a fault based on the fault code.
[0107] In a possible implementation, the detection module 1310 may include a detection unit 1311 and a sending unit 1312.
[0108] The detection unit 1311 is configured to detect a relay power supply current V.sub.TX in any transmit period and a relay power supply current V.sub.RX in any receive period.
[0109] The sending unit 1312 is configured to: if V.sub.TX is less than a preset first threshold, or V.sub.TX is greater than a preset second threshold, or V.sub.RX is less than a preset third threshold, or V.sub.RX is greater than a preset fourth threshold, send the fault diagnosis trigger signal to the relay device.
[0110] In a possible implementation, the detection module 1310 may include a detection unit 1313 and a sending unit 1314.
[0111] The detection unit 1313 is configured to detect a state of a transmit path of the relay device in any transmit period.
[0112] The sending unit 1314 is configured to: if the transmit path is in an abnormal state, send the fault diagnosis trigger signal to the relay device.
[0113] In a possible implementation, the detection module 1310 may be further configured to: adjust the variable supply voltage value based on the state, and send the variable supply voltage value to the relay device; or adjust an output duty cycle of the transmit/receive control signal based on the state, and send the transmit/receive control signal to the relay device.
[0114] In a possible implementation, the diagnosis module 1320 may include a detection unit 1321, a comparison unit 1322, and a diagnosis unit 1323.
[0115] The detection unit 1321 is configured to detect a relay power supply current V.sub.TX of the relay device in any transmit period in the fault diagnosis mode.
[0116] The comparison unit 1322 is configured to: if V.sub.TX is less than a preset fifth threshold, determine a first code; or if V.sub.TX is greater than or equal to a preset fifth threshold, determine a second code.
[0117] The diagnosis unit 1323 is configured to: obtain a code set in M consecutive transmit periods, and determine the fault code based on the code set, where the code set includes at least one of the first code and the second code.
[0118] In a possible implementation, the diagnosis unit 1323 may include an obtaining subunit 13231, a matching subunit 13232, and a diagnosis subunit 1 3233.
[0119] The obtaining subunit 13231 is configured to obtain a first code set of the relay device from the first transmit period to an N.sup.th transmit period in the fault diagnosis mode, where the first code set includes at least one of the first code and the second code.
[0120] The matching subunit 13232 is configured to: if the first code set matches a preset code set, obtain a second code set from an (N+1).sup.th transmit period to an (N+M).sup.th transmit period, where the second code set includes at least one of the first code and the second code.
[0121] The diagnosis subunit 13233 is configured to determine the fault code based on the second code set.
[0122] The fault diagnosis apparatus provided in embodiment shown in
[0123] It should be understood that division of the modules of the fault diagnosis apparatus shown in
[0124] For example, the foregoing modules may be configured as one or more integrated circuits for implementing the foregoing method, for example, one or more application-specific integrated circuits (Application-Specific Integrated Circuit, ASIC for short), or one or more microprocessors (Digital Signal Processor, DSP for short), or one or more field programmable gate arrays (Field Programmable Gate Array, FPGA for short). For another example, the modules may be integrated together, and implemented in a form of a system-on-a-chip (System-On-a-Chip, SOC for short).
[0125] It may be understood that an interface connection relationship between the modules that is shown in this embodiment of the present disclosure is merely an example for description, and does not constitute a limitation on a structure of the electronic device 200. In some other embodiments of this application, the electronic device 200 may alternatively use an interface connection manner different from that in the foregoing embodiment, or use a combination of a plurality of interface connection manners.
[0126] It may be understood that, to implement the foregoing functions, the electronic device includes a corresponding hardware structure and/or software module for performing each function. A person skilled in the art should be easily aware that, in combination with the examples described in embodiments disclosed in this specification, units, algorithms, and steps may be implemented by hardware or a combination of hardware and computer software in embodiments of this application. Whether a function is performed by hardware or hardware driven by computer software depends on a particular application and a design constraint of the technical solutions. A person skilled in the art may use different methods to implement the described functions for each particular application, but it should not be considered that the implementation goes beyond the scope of embodiments of the present invention.
[0127] In embodiments of this application, the terminal may be divided into functional modules based on the foregoing method examples. For example, each functional module may be obtained through division based on each corresponding function, or two or more functions may be integrated into one processing module. The integrated module may be implemented in a form of hardware, or may be implemented in a form of a software functional module. It should be noted that, in embodiments of this application, division into the modules is an example and is merely logical function division, and may be other division in an actual implementation.
[0128] Based on the foregoing descriptions of the implementations, a person skilled in the art may clearly understand that for the purpose of convenient and brief descriptions, division into the foregoing functional modules is merely used as an example for descriptions. During actual application, the foregoing functions can be allocated to different functional modules for implementation based on a requirement, in other words, an inner structure of an apparatus is divided into different functional modules to implement all or a part of the functions described above. For a specific working process of the foregoing system, apparatus, and unit, refer to a corresponding process in the foregoing method embodiments, and details are not described herein again.
[0129] Functional units in embodiments of this application may be integrated into one processing unit, or each of the units may exist alone physically, or two or more units are integrated into one unit. The integrated unit may be implemented in a form of hardware, or may be implemented in a form of a software functional unit.
[0130] When the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, the integrated unit may be stored in a computer-readable storage medium. Based on such an understanding, the technical solutions of embodiments of this application essentially, or the part contributing to the conventional technology, or all or some of the technical solutions may be implemented in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for instructing a computer device (which may be a personal computer, a server, or a network device) or a processor to perform all or some of the steps of the methods described in embodiments of this application. The foregoing storage medium includes any medium that can store program code, such as a flash memory, a removable hard disk, a read-only memory, a random access memory, a magnetic disk, or an optical disc.
[0131] The foregoing descriptions are only specific implementations of this application, but are not intended to limit the protection scope of this application. Any variation or replacement within the technical scope disclosed in this application shall fall within the protection scope of this application. Therefore, the protection scope of this application shall be subject to the protection scope of the claims.