P-gear key state identification method and device, medium and vehicle
By acquiring and analyzing the multi-channel button signal circuit voltages of the P gear button, the target circuit state with the highest correlation with the P gear button state is determined, solving the problem of inaccurate P gear button state recognition and improving the reliability of the P gear button and driving safety.
Patent Information
- Application Number
- CN202410445991.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-12
- Publication Date
- 2025-10-21
AI Technical Summary
In the existing technology, the judgment strategy for the P gear button status is chaotic, resulting in low reliability of the P gear button and affecting driving and personal safety.
By acquiring the loop voltage of the multi-channel key signal loop of the P-mode button, and comparing the loop voltage with the voltage threshold range, the loop state of each key signal loop is determined. Based on the correlation between the loop state and the P-mode button state, the target loop state is determined, thereby accurately identifying the P-mode button state.
This improves the reliability of the P gear button, ensures driving and personal safety, avoids logical confusion in the P gear button status recognition, and ensures the accuracy of fault identification.
Smart Images

Figure CN120819630A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of vehicle control technology, and in particular to a method, device, medium, and vehicle for identifying the state of a P-shift button. Background Art
[0002] With the advancement of automobile manufacturing technology and customer demand, the application of automation in automobiles has become increasingly popular. Among them, the automatic control type gear shift has also evolved into several types: gear lever type, knob type, paddle type, and hand-shift type. Among them, the hand-shift type gear shift solution is becoming more and more widely used with the popularity of new energy vehicles. Automobile manufacturers that adopt the hand-shift solution often integrate the electronic parking brake switch into the P gear button to simultaneously control the vehicle's transmission system and braking system, making the reliability of the P gear button particularly important. The P gear button of the existing technical solution has already used a dual-circuit P gear button signal, but the P gear button status judgment strategy is confusing and rough, and the P gear button status cannot be accurately identified, resulting in low reliability of the P gear button, affecting driving and personal safety. Summary of the Invention
[0003] In order to solve the above technical problems, the present disclosure provides a P-gear button status recognition method, device, medium and vehicle to accurately identify the P-gear button status, improve the reliability of the P-gear button, and ensure driving and personal safety.
[0004] The present disclosure provides a method for identifying the state of a P-shift button, comprising:
[0005] Obtaining a circuit voltage of each key signal circuit in multiple key signal circuits of the P gear key;
[0006] Determining the loop state of each key signal loop based on a comparison between the loop voltage and a voltage threshold range; wherein the voltage threshold range is used to classify the loop state, and the loop state is used to indicate whether the key signal loop is on or off or in an abnormal state;
[0007] determining a target circuit state based on the circuit states and the correlation between the circuit states and the P gear button state, wherein the target circuit state is the circuit state with the greatest correlation with the P gear button state among the circuit states, the correlation reflecting a criterion for determining the P gear button state;
[0008] The P gear button state that matches the target circuit state is set as the current P gear button state.
[0009] In the present disclosure, determining the loop state of each key signal loop based on the comparison between the loop voltage and the voltage threshold range includes:
[0010] Comparing the loop voltage with a voltage threshold range under a corresponding key signal loop, and determining a target voltage threshold range within which the loop voltage lies from the voltage threshold range;
[0011] The circuit state of the corresponding key signal circuit is determined based on the target voltage threshold range and the corresponding relationship between the voltage threshold range and the circuit state of the corresponding key signal circuit.
[0012] In the present disclosure, the multiple key signal circuits include a first key signal circuit and a second key signal circuit; and determining the circuit state of each key signal circuit based on a comparison between the circuit voltage and a voltage threshold range includes:
[0013] If the first loop voltage of the first key signal loop is within a first voltage threshold range, determining that the first key signal loop is turned on;
[0014] If the voltage of the first circuit is within a second voltage threshold range, determining that the first key signal circuit is disconnected;
[0015] If the voltage of the first circuit is within a third voltage threshold range, determining that the first key signal circuit is short-circuited;
[0016] If the first loop voltage is not within the first voltage threshold range, the second voltage threshold range, and the third voltage threshold range, determining that the first key signal loop is faulty;
[0017] And / or, determining the loop state of each key signal loop based on a comparison between the loop voltage and a voltage threshold range, including:
[0018] If the second loop voltage of the second key signal loop is within a fourth voltage threshold range, determining that the second key signal loop is turned on;
[0019] If the second circuit voltage is within a fifth voltage threshold range, determining that the second key signal circuit is disconnected;
[0020] If the second circuit voltage is within a sixth voltage threshold range, determining that the second key signal circuit is short-circuited;
[0021] If the second loop voltage is not within the fourth voltage threshold range, the fifth voltage threshold range, and the sixth voltage threshold range, it is determined that the second key signal loop is faulty.
[0022] In the present disclosure, the first voltage threshold range is different from the fourth voltage threshold range, the second voltage threshold range is different from the fifth voltage threshold range, and the third voltage threshold range is the same as the sixth voltage threshold range.
[0023] In the present disclosure, the circuit status includes circuit short circuit, circuit disconnection, circuit conduction and circuit error, and the correlation degree between the circuit short circuit, circuit disconnection, circuit conduction and circuit error and the P gear button status decreases in sequence.
[0024] In the present disclosure, the multi-channel key signal circuit is a two-channel key signal circuit; based on the circuit state and the degree of correlation between the circuit state and the P gear key state, determining the target circuit state includes:
[0025] If the circuit state of one of the key signal circuits is the circuit short circuit, determining the circuit short circuit as the target circuit state;
[0026] If the circuit states of both key signal circuits are not the circuit short circuit, and the circuit state of one key signal circuit is the circuit disconnection, determining the circuit disconnection as the target circuit state;
[0027] If the loop states of the two key signal loops are neither the loop short circuit nor the loop disconnection, and the loop state of one key signal loop is the loop conduction, determining the loop conduction as the target loop state;
[0028] If the loop states of the two key signal loops are both the loop error, the loop error is determined as the target loop state.
[0029] In the present disclosure, determining the P gear button state matched by the target circuit state as the current P gear button state includes:
[0030] If the target circuit status is circuit short circuit or circuit error, it is determined that the P gear button is faulty;
[0031] If the target circuit status is circuit disconnected, make sure the P gear button is not pressed;
[0032] If the target circuit state is circuit conduction, confirm that the P gear button is pressed.
[0033] The present disclosure provides a device for identifying the state of a P-shift button, comprising:
[0034] A circuit voltage acquisition module, used to obtain the circuit voltage of each of the multiple key signal circuits of the P gear key;
[0035] a circuit state determination module, configured to determine the circuit state of each key signal circuit based on a comparison between the circuit voltage and a voltage threshold range; wherein the voltage threshold range is used to classify the circuit state, and the circuit state is used to indicate whether the key signal circuit is on, off, or abnormal;
[0036] a target circuit state determining module, configured to determine a target circuit state based on the circuit states and a correlation between the circuit states and the P gear button state, wherein the target circuit state is the circuit state having the greatest correlation with the P gear button state among the circuit states, the correlation reflecting a criterion for determining the P gear button state;
[0037] The button state determination module is used to set the P gear button state matched by the target circuit state as the current P gear button state.
[0038] The present disclosure also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a program or instruction, wherein the program or instruction enables a computer to execute the steps of any one of the above methods.
[0039] The present disclosure also provides a vehicle, comprising:
[0040] one or more processors;
[0041] a memory for storing one or more programs or instructions;
[0042] The processor is configured to execute the steps of any of the above methods by calling the program or instructions stored in the memory.
[0043] The technical solution provided by the embodiments of the present disclosure has the following advantages over the prior art:
[0044] The technical solution provided by the embodiments of the present disclosure, for a P-shift button with multiple button signal circuits, obtains the circuit voltage of each button signal circuit, determines the circuit state of each button signal circuit based on the circuit voltage, and then determines the target circuit state with the greatest correlation with the P-shift button state from the circuit states. The correlation reflects the determination criterion for the P-shift button state, thereby using the circuit state with the greatest correlation with the P-shift button state to determine the current P-shift button state. In this way, the technical solution of the present disclosure can accurately identify the P-shift button state, thereby improving the reliability of the P-shift button and ensuring driving and personal safety. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0046] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0047] Figure 1 A flowchart of a method for identifying the state of a P-shift button provided in an embodiment of the present disclosure;
[0048] Figure 2 A schematic diagram of the structure of a two-way key signal circuit provided by an embodiment of the present disclosure;
[0049] Figure 3 A structural block diagram of a device for identifying the state of a P-shift button provided in an embodiment of the present disclosure;
[0050] Figure 4 A schematic structural diagram of a vehicle provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0051] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features therein can be combined with each other in the absence of conflict.
[0052] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.
[0053] Figure 1 This is a flow chart of a method for identifying the state of a P-gear button provided by an embodiment of the present disclosure. This method is applicable to various driving conditions and can accurately identify the state of the P-gear button. It can be applied to a P-gear button integrated with an electronic parking brake switch. This method can be executed by a P-gear button state identification device, which can be implemented in software and / or hardware. Figure 1 As shown, the method includes the following steps:
[0054] S110 , obtaining a circuit voltage of each key signal circuit in multiple key signal circuits of the P gear key.
[0055] In the technical solution disclosed in the present invention, the multi-channel key signal circuit may include two-channel key signal circuits or three-channel key signal circuits. The embodiment of the present invention takes two-channel key signal circuits as an example to explain the technical solution disclosed in the present invention. Figure 2 The two key signal circuits include a first key signal circuit CH1 and a second key signal circuit CH2. The microcontroller unit MCU monitors the circuit voltages of the first key signal circuit CH1 and the second key signal circuit CH2 in real time via two ports. The port voltages obtained by the microcontroller unit MCU are the circuit voltages. In the disclosed embodiment, both key signal circuits are analog circuits, and accordingly, the circuit voltages are analog voltages.
[0056] S120 : Determine the loop state of each key signal loop based on a comparison between the loop voltage and the voltage threshold range.
[0057] The voltage threshold range is used to divide the circuit state, and the circuit state is used to indicate the on / off condition or abnormal condition of the key signal circuit.
[0058] Figure 2 This is just a simple schematic diagram. In the actual key signal loop, resistors are also provided in series and / or in parallel. By setting the resistors, the loop voltage of the key signal loop can be different in different loop states. Therefore, different loop states can be represented by calibrating different voltage threshold ranges, and then the loop state of the corresponding key signal loop can be determined by comparing the loop voltage with the voltage threshold range. In addition, the loop state is used to represent the on-off condition or abnormal condition of the key signal loop, wherein the on-off condition includes conduction (i.e., the loop switch is pressed) or disconnection (i.e., the loop switch is not pressed), and the abnormal condition includes short circuit or error. Accordingly, in the optional example, the loop state may include loop short circuit, loop disconnection, loop conduction and loop error.
[0059] In some embodiments, based on the comparison of the loop voltage and the voltage threshold range, the loop state of each key signal loop is determined, including: comparing the loop voltage with the voltage threshold range under the corresponding key signal loop, and determining the target voltage threshold range of the loop voltage from the voltage threshold range; based on the target voltage threshold range and the correspondence between the voltage threshold range under the corresponding key signal loop and the loop state, determining the loop state of the corresponding key signal loop.
[0060] In this solution, the voltage threshold range corresponding to each loop state can be set specifically according to the loop resistance of the key signal loop. For example, if the loop resistances of the two key signal loops are the same, then for any identical loop state, the voltage threshold range under each key signal loop is the same. If the loop resistances of the two key signal loops are different, then for some identical loop states (except for loop short circuit, because the short-circuit voltage is the same), the voltage threshold range under each key signal loop is different. Based on this, the corresponding relationship between the voltage threshold range and the loop state can be associated with each key signal loop respectively. After obtaining the loop voltage of each key signal loop, the loop voltage is compared with the voltage threshold range under the corresponding key signal loop to determine the voltage threshold range to which the loop voltage belongs. The voltage threshold range is used as the target voltage threshold range. Then, based on the corresponding relationship between the voltage threshold range and the loop state, the loop state corresponding to the target voltage threshold range is determined, and the loop state is determined as the loop state of the corresponding key signal loop.
[0061] Specifically, in some embodiments, the multiple key signal circuits include a first key signal circuit and a second key signal circuit; based on a comparison of the circuit voltage and the voltage threshold range, determining the circuit state of each key signal circuit includes: if the first circuit voltage of the first key signal circuit is within the first voltage threshold range, determining that the first key signal circuit is connected; if the first circuit voltage is within the second voltage threshold range, determining that the first key signal circuit is disconnected; if the first circuit voltage is within the third voltage threshold range, determining that the first key signal circuit is short-circuited; if the first circuit voltage is not within the first voltage threshold range, the second voltage threshold range, and the third voltage threshold range, determining that the first key signal circuit is faulty;
[0062] And / or, based on the comparison of the loop voltage and the voltage threshold range, determining the loop status of each key signal loop, including: if the second loop voltage of the second key signal loop is within the fourth voltage threshold range, determining that the second key signal loop is turned on; if the second loop voltage is within the fifth voltage threshold range, determining that the second key signal loop is disconnected; if the second loop voltage is within the sixth voltage threshold range, determining that the second key signal loop is short-circuited; if the second loop voltage is not within the fourth voltage threshold range, the fifth voltage threshold range, and the sixth voltage threshold range, determining that the second key signal loop is faulty.
[0063] In this embodiment, the first voltage threshold range, the second voltage threshold range, and the third voltage threshold range do not intersect, and the first voltage threshold range, the second voltage threshold range, and the third voltage threshold range are mutually different; the fourth voltage threshold range, the fifth voltage threshold range, and the sixth voltage threshold range do not intersect, and the fourth voltage threshold range, the fifth voltage threshold range, and the sixth voltage threshold range are mutually different. In this way, different voltage threshold ranges are calibrated for the loop status of each key signal loop, and the loop status of the corresponding key signal loop can be quickly and accurately determined based on the loop voltage.
[0064] In some embodiments, the first voltage threshold range is different from the fourth voltage threshold range, the second voltage threshold range is different from the fifth voltage threshold range, and the third voltage threshold range is the same as the sixth voltage threshold range. That is, for the first key signal circuit and the second key signal circuit, the voltage threshold ranges for determining circuit conduction are different, the voltage threshold ranges for determining circuit disconnection are different, and the voltage threshold ranges for determining circuit short circuit are the same. Accordingly, the voltage threshold ranges for determining circuit error are different. Thus, by setting different voltage threshold ranges for the same circuit state in different key signal circuits, functional safety requirements are met and common cause failures are prevented.
[0065] Exemplarily, the first voltage threshold range is 1-1.4V, the second voltage threshold range is 3.6-3.9V, and the third voltage threshold range is 4.9-5.1V or 0-0.2V. Specifically, if the first circuit voltage is between 1-1.4V, it is determined that the first key signal circuit is connected; if the first circuit voltage is between 3.6-3.9V, it is determined that the first key signal circuit is disconnected; if the first circuit voltage is between 4.9-5.1V or 0-0.2V, it is determined that the first key signal circuit is short-circuited; if the first circuit voltage does not meet any of the above conditions, it is determined that the first key signal circuit is faulty.
[0066] The fourth voltage threshold range is 3.3 to 3.7 V, the fifth voltage threshold range is 0.83 to 0.97 V, and the sixth voltage threshold range is 4.9 to 5.1 V or 0 to 0.2 V. Specifically, if the second circuit voltage is between 3.3 and 3.7 V, the second key signal circuit is determined to be connected; if the second circuit voltage is between 0.83 and 0.97 V, the second key signal circuit is determined to be disconnected; if the second circuit voltage is between 4.9 and 5.1 V or 0 to 0.2 V, the second key signal circuit is determined to be short-circuited; if the second circuit voltage does not meet any of the above conditions, the second key signal circuit is determined to be faulty.
[0067] S130 : Determine a target circuit state based on the circuit state and the degree of correlation between the circuit state and the P gear button state.
[0068] The target circuit state is the circuit state with the highest correlation with the P-shift button state among all circuit states. This correlation reflects the criterion for determining the P-shift button state. In this embodiment, the circuit state with the highest correlation with the P-shift button state among the two key signal circuit states serves as the criterion for determining the P-shift button state. This avoids confusion in the P-shift button state determination logic and improves the accuracy of P-shift button state recognition. In particular, if the circuit states of the two key signal circuits are the same, either circuit state is designated as the target circuit state.
[0069] In some embodiments, the degree of correlation between the circuit state and the P-gear button state is set based on the requirements of functional safety. Based on this, in some specific embodiments, the circuit state includes circuit short circuit, circuit disconnection, circuit conduction and circuit error, and the degree of correlation between circuit short circuit, circuit disconnection, circuit conduction and circuit error and the P-gear button state decreases in sequence. Specifically, if the circuit state of one key signal circuit is circuit short circuit, the circuit short circuit is determined as the target circuit state; if the circuit states of both key signal circuits are not circuit short circuit, and the circuit state of one key signal circuit is circuit disconnection, the circuit disconnection is determined as the target circuit state; if the circuit states of both key signal circuits are not circuit short circuit and circuit disconnection, and the circuit state of one key signal circuit is circuit conduction, the circuit conduction is determined as the target circuit state; if the circuit states of both key signal circuits are circuit errors, the circuit error is determined as the target circuit state.
[0070] S140: Set the P gear button state that matches the target circuit state as the current P gear button state.
[0071] This solution associates the circuit state with the P-shift button state, establishing a corresponding relationship between the circuit state and the P-shift button state. After determining the target circuit state, combining this relationship with the P-shift button state directly determines the P-shift button state corresponding to the target circuit state, i.e., the current P-shift button state.
[0072] In some embodiments, the P-gear button state matched by the target circuit state is set as the current P-gear button state, including: if the target circuit state is circuit short circuit or circuit error, it is determined that the P-gear button is faulty; if the target circuit state is circuit disconnection, it is determined that the P-gear button is not pressed; if the target circuit state is circuit conduction, it is determined that the P-gear button is pressed.
[0073] Based on the above solution, the correspondence between the circuit states of the two key signal circuits and the P-position button status can be found in Table 1: "No Press" indicates a circuit disconnect, "Press" indicates a circuit continuity, "Fault" indicates a circuit error, "SC" indicates a circuit short circuit, "0x0" indicates the P-position button is not pressed, "0x1" indicates the P-position button is pressed, and "0x2" indicates a P-position button fault. As shown in Table 1, if the circuit state of one of the first key signal circuit CH1 and the second key signal circuit CH2 is a circuit short circuit, the P-position button is faulty. If the circuit states of neither the first key signal circuit CH1 nor the second key signal circuit CH2 are short circuited, and one of the key signal circuits is disconnected, the P-position button is not pressed. If the circuit states of neither the first key signal circuit CH1 nor the second key signal circuit CH2 are short circuited or disconnected, and one of the key signal circuits is continuous, the P-position button is pressed. If the circuit states of both the first key signal circuit CH1 and the second key signal circuit CH2 are circuit errors, the P-position button is faulty.
[0074] Table 1 Correspondence between the circuit status of the two-way key signal circuit and the P gear key status
[0075]
[0076] In addition, in some embodiments, when a P-shift button fault is determined, the P-shift button fault information is reported. This allows after-sales maintenance personnel to be notified promptly, allowing them to accurately determine the fault point and repair it in a timely manner, reducing driving risks.
[0077] The P-shift button state identification method provided by the disclosed embodiment is designed for a P-shift button with multiple button signal circuits. By obtaining the circuit voltage of each button signal circuit, the circuit state of each button signal circuit is determined based on the circuit voltage. The target circuit state with the highest correlation with the P-shift button state is then determined from the circuit states. The correlation reflects the criterion for determining the P-shift button state. Thus, the circuit state with the highest correlation with the P-shift button state can be used to determine the current P-shift button state. In this way, the disclosed technical solution can accurately identify the P-shift button state, thereby improving the reliability of the P-shift button and ensuring driving and personal safety.
[0078] The multi-channel key signal circuit may also include a three-channel key signal circuit. The working logic of the three-channel key signal circuit is similar to that of the two-channel key signal circuit, and those skilled in the art may perform adaptive design.
[0079] Corresponding to the P-gear button state recognition method provided in the embodiment of the present disclosure, the embodiment of the present disclosure also provides a P-gear button state recognition device. Figure 3This is a structural block diagram of the P gear button state recognition device provided by the embodiment of the present disclosure, such as Figure 3 As shown, the P gear button state recognition device includes:
[0080] The circuit voltage acquisition module 21 is used to obtain the circuit voltage of each key signal circuit in the multiple key signal circuits of the P gear key;
[0081] A circuit state determination module 22 is configured to determine the circuit state of each key signal circuit based on a comparison between the circuit voltage and a voltage threshold range; wherein the voltage threshold range is used to classify the circuit state, and the circuit state is used to indicate whether the key signal circuit is on, off, or abnormal;
[0082] a target circuit state determination module 23 for determining a target circuit state based on the circuit state and the degree of correlation between the circuit state and the P gear button state, wherein the target circuit state is the circuit state with the greatest correlation with the P gear button state among the circuit states, and the degree of correlation reflects a criterion for determining the P gear button state;
[0083] The button state determination module 24 is configured to set the P gear button state that matches the target circuit state as the current P gear button state.
[0084] In some embodiments, the loop state determination module 22 is specifically configured to:
[0085] Compare the loop voltage with the voltage threshold range under the corresponding key signal loop, and determine the target voltage threshold range within which the loop voltage lies from the voltage threshold range;
[0086] Based on the target voltage threshold range and the corresponding relationship between the voltage threshold range and the circuit state of the corresponding key signal circuit, the circuit state of the corresponding key signal circuit is determined.
[0087] In some embodiments, the loop state determination module 22 is specifically configured to:
[0088] If the first loop voltage of the first key signal loop is within the first voltage threshold range, determining that the first key signal loop is turned on;
[0089] If the voltage of the first circuit is within the second voltage threshold range, it is determined that the first key signal circuit is disconnected;
[0090] If the first circuit voltage is within the third voltage threshold range, it is determined that the first key signal circuit is short-circuited;
[0091] If the first loop voltage is not within the first voltage threshold range, the second voltage threshold range, and the third voltage threshold range, it is determined that the first key signal loop is faulty;
[0092] and / or determining a loop state of each key signal loop based on a comparison of the loop voltage with a voltage threshold range, including:
[0093] If the second loop voltage of the second key signal loop is within a fourth voltage threshold range, determining that the second key signal loop is turned on;
[0094] If the second circuit voltage is within the fifth voltage threshold range, it is determined that the second key signal circuit is disconnected;
[0095] If the second circuit voltage is within the sixth voltage threshold range, it is determined that the second key signal circuit is short-circuited;
[0096] If the second loop voltage is not within the fourth voltage threshold range, the fifth voltage threshold range, and the sixth voltage threshold range, it is determined that the second key signal loop is faulty.
[0097] In some embodiments, the first voltage threshold range is different from the fourth voltage threshold range, the second voltage threshold range is different from the fifth voltage threshold range, and the third voltage threshold range is the same as the sixth voltage threshold range.
[0098] In some embodiments, the loop status includes loop short circuit, loop disconnection, loop conduction and loop error, and the correlation between loop short circuit, loop disconnection, loop conduction and loop error and the P gear button status decreases in sequence.
[0099] In some embodiments, the multi-channel key signal circuit is a two-channel key signal circuit; the target circuit state determination module 23 is specifically used to:
[0100] If the circuit state of a key signal circuit is a circuit short circuit, the circuit short circuit is determined as the target circuit state;
[0101] If the circuit states of both key signal circuits are not short circuit, and the circuit state of one key signal circuit is disconnected, then the disconnected circuit is determined as the target circuit state;
[0102] If the circuit states of the two key signal circuits are neither short-circuited nor disconnected, and the circuit state of one key signal circuit is connected, the circuit connected state is determined as the target circuit state;
[0103] If the loop states of the two key signal loops are both loop errors, the loop error is determined as the target loop state.
[0104] In some embodiments, the button state determination module 24 is specifically configured to:
[0105] If the target circuit status is circuit short circuit or circuit error, it is determined that the P gear button is faulty;
[0106] If the target circuit status is circuit disconnected, make sure the P gear button is not pressed;
[0107] If the target circuit state is circuit conduction, confirm that the P gear button is pressed.
[0108] In some embodiments, a fault reporting module is further included, configured to:
[0109] When it is determined that the P gear button is faulty, the P gear button fault information is reported.
[0110] The P-gear button state recognition device disclosed in the above embodiments can execute the P-gear button state recognition method disclosed in the above embodiments, and has the same or corresponding beneficial effects. To avoid repetition, it will not be described here.
[0111] The embodiments of the present disclosure further provide a computer-readable storage medium, which stores a program or instruction, and the program or instruction enables a computer to execute the steps of any of the above methods.
[0112] Exemplarily, the program or instruction causes the computer to execute a method for identifying the state of a P gear button, the method comprising:
[0113] Obtain the circuit voltage of each key signal circuit in the multiple key signal circuits of the P gear key;
[0114] Determine the loop status of each key signal loop based on a comparison between the loop voltage and the voltage threshold range; wherein the voltage threshold range is used to classify the loop status, and the loop status is used to indicate whether the key signal loop is on or off or in an abnormal state;
[0115] Determining a target circuit state based on the circuit state and the degree of correlation between the circuit state and the P gear button state, wherein the target circuit state is the circuit state with the greatest correlation with the P gear button state among the circuit states, and the degree of correlation reflects the criterion for determining the P gear button state;
[0116] Set the P gear button state that matches the target circuit state as the current P gear button state.
[0117] Optionally, when executed by a computer processor, the computer executable instruction can also be used to execute the technical solution of any of the above-mentioned P-gear button state recognition methods provided in the embodiments of the present disclosure, thereby achieving corresponding beneficial effects.
[0118] Through the above description of the implementation methods, those skilled in the art can clearly understand that the embodiments of the present disclosure can be implemented with the help of software and necessary general-purpose hardware, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the embodiments of the present disclosure is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as a computer floppy disk, read-only memory (ROM), random access memory (RAM), flash memory (FLASH), hard disk or optical disk, etc., including a number of instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute the methods described in each embodiment of the present disclosure.
[0119] An embodiment of the present disclosure also provides a vehicle, comprising: one or more processors; a memory for storing one or more programs or instructions; the processor calls the programs or instructions stored in the memory to execute the steps of any of the above methods to achieve corresponding beneficial effects.
[0120] Figure 4 Schematic diagram of the hardware structure of the vehicle provided in the embodiment of the present disclosure. Figure 4 As shown, the vehicle includes one or more processors 301 and memory 302 .
[0121] The processor 301 may be a central processing unit (CPU) or other forms of processing units having data processing capabilities and / or instruction execution capabilities, and may control other components in the vehicle to perform desired functions.
[0122] The memory 302 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, random access memory (RAM) and / or cache memory. The non-volatile memory may include, for example, read-only memory (ROM), a hard disk, a flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 301 may execute the program instructions to implement the P-gear button state recognition method of the embodiment of the present disclosure described above, and / or other desired functions. Various contents such as input signals, signal components, noise components, etc. may also be stored in the computer-readable storage medium.
[0123] In one example, the vehicle may further include an input device 303 and an output device 304 , and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown).
[0124] In addition, the input device 303 may also include, for example, a keyboard, a mouse, and the like.
[0125] The output device 304 can output various information to the outside, including determined distance information, direction information, etc. The output device 304 can include, for example, a display, a speaker, a printer, a communication network and its connected remote output device, etc.
[0126] Of course, to simplify, Figure 4 Only some of the components in the vehicle related to the present disclosure are shown, and components such as buses, input / output interfaces, etc. are omitted. In addition, the vehicle may further include any other appropriate components according to specific application scenarios.
[0127] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or device comprising the element.
[0128] The foregoing description is intended only to provide specific embodiments of the present disclosure, intended to enable those skilled in the art to understand and implement the present disclosure. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure is not intended to be limited to the embodiments described herein, but rather to be construed in the broadest manner consistent with the principles and novel features disclosed herein.
Claims
1. A method for identifying the state of a P gear button, characterized in that: include: Obtaining a circuit voltage of each key signal circuit in multiple key signal circuits of the P gear key; Determining the loop state of each key signal loop based on a comparison between the loop voltage and a voltage threshold range; wherein the voltage threshold range is used to classify the loop state, and the loop state is used to indicate whether the key signal loop is on or off or in an abnormal state; determining a target circuit state based on the circuit states and the correlation between the circuit states and the P gear button state, wherein the target circuit state is the circuit state with the greatest correlation with the P gear button state among the circuit states, the correlation reflecting a criterion for determining the P gear button state; The P gear button state that matches the target circuit state is set as the current P gear button state.
2. The method according to claim 1, characterized in that Determining a loop state of each key signal loop based on a comparison between the loop voltage and a voltage threshold range includes: Comparing the loop voltage with a voltage threshold range under a corresponding key signal loop, and determining a target voltage threshold range within which the loop voltage lies from the voltage threshold range; The circuit state of the corresponding key signal circuit is determined based on the target voltage threshold range and the corresponding relationship between the voltage threshold range and the circuit state of the corresponding key signal circuit.
3. The method according to claim 1, characterized in that The multiple key signal circuits include a first key signal circuit and a second key signal circuit; and determining a circuit state of each key signal circuit based on a comparison between the circuit voltage and a voltage threshold range includes: If the first loop voltage of the first key signal loop is within a first voltage threshold range, determining that the first key signal loop is turned on; If the voltage of the first circuit is within a second voltage threshold range, determining that the first key signal circuit is disconnected; If the voltage of the first circuit is within a third voltage threshold range, determining that the first key signal circuit is short-circuited; If the first loop voltage is not within the first voltage threshold range, the second voltage threshold range, and the third voltage threshold range, determining that the first key signal loop is faulty; And / or, determining the loop state of each key signal loop based on a comparison between the loop voltage and a voltage threshold range, including: If the second loop voltage of the second key signal loop is within a fourth voltage threshold range, determining that the second key signal loop is turned on; If the second circuit voltage is within a fifth voltage threshold range, determining that the second key signal circuit is disconnected; If the second circuit voltage is within a sixth voltage threshold range, determining that the second key signal circuit is short-circuited; If the second loop voltage is not within the fourth voltage threshold range, the fifth voltage threshold range, and the sixth voltage threshold range, it is determined that the second key signal loop is faulty.
4. The method according to claim 3, characterized in that The first voltage threshold range is different from the fourth voltage threshold range, the second voltage threshold range is different from the fifth voltage threshold range, and the third voltage threshold range is the same as the sixth voltage threshold range.
5. The method according to claim 1, characterized in that The circuit status includes circuit short circuit, circuit disconnection, circuit conduction and circuit error, and the correlation degree between the circuit short circuit, circuit disconnection, circuit conduction and circuit error and the P gear button status decreases in sequence.
6. The method according to claim 5, characterized in that The multi-channel key signal circuit is a two-channel key signal circuit; based on the circuit state and the degree of correlation between the circuit state and the P gear key state, determining the target circuit state includes: If the circuit state of one of the key signal circuits is the circuit short circuit, determining the circuit short circuit as the target circuit state; If the circuit states of both key signal circuits are not the circuit short circuit, and the circuit state of one key signal circuit is the circuit disconnection, determining the circuit disconnection as the target circuit state; If the loop states of the two key signal loops are neither the loop short circuit nor the loop disconnection, and the loop state of one key signal loop is the loop conduction, determining the loop conduction as the target loop state; If the loop states of the two key signal loops are both the loop error, the loop error is determined as the target loop state.
7. The method according to claim 5, characterized in that Setting the P gear button state matched by the target circuit state as the current P gear button state includes: If the target circuit status is circuit short circuit or circuit error, it is determined that the P gear button is faulty; If the target circuit status is circuit disconnected, make sure the P gear button is not pressed; If the target circuit state is circuit conduction, confirm that the P gear button is pressed.
8. A device for identifying the state of a P gear button, characterized in that: include: A circuit voltage acquisition module, used to obtain the circuit voltage of each of the multiple key signal circuits of the P gear key; a circuit state determination module, configured to determine the circuit state of each key signal circuit based on a comparison between the circuit voltage and a voltage threshold range; wherein the voltage threshold range is used to classify the circuit state, and the circuit state is used to indicate whether the key signal circuit is on, off, or abnormal; a target circuit state determining module, configured to determine a target circuit state based on the circuit states and a correlation between the circuit states and the P gear button state, wherein the target circuit state is the circuit state having the greatest correlation with the P gear button state among the circuit states, the correlation reflecting a criterion for determining the P gear button state; The button state determination module is used to set the P gear button state matched by the target circuit state as the current P gear button state.
9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a program or instruction, and the program or instruction enables a computer to execute the steps of the method according to any one of claims 1 to 7.
10. A vehicle, characterized in that: include: one or more processors; a memory for storing one or more programs or instructions; The processor is configured to execute the steps of the method according to any one of claims 1 to 7 by calling the program or instructions stored in the memory.