Automobile steering wheel button automatic recognition method, device, equipment and medium
By automatically identifying the steering wheel key type and configuring the target key parameter set, the problem of inefficient manual configuration of steering wheel key type in the prior art is solved, automatic identification and configuration are realized, and production efficiency is improved.
Patent Information
- Application Number
- CN202211111389.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-13
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2042-09-13
AI Technical Summary
In the prior art, when the same car machine needs to be compatible with different configurations of steering wheels, it is necessary to manually configure the steering wheel button type, resulting in inefficiency and consuming a lot of manpower and time.
By obtaining the voltage value of the steering wheel key access port and matching it with the preset normal state value set, the steering wheel key type is automatically identified. Then configure the target key parameter set according to the type, and determine the current target key through voltage signal matching to perform its functions.
It realizes automatic identification and configuration of steering wheel buttons, reduces the need for manual configuration, improves efficiency, convenience and speed, especially during large-scale mass production, greatly reduces labor and time costs.
Smart Images

Figure CN115303210B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of vehicle-mounted technology, and in particular to a method, a device, a computer device and a storage medium for automatically identifying vehicle steering wheel buttons. Background Art
[0002] The car steering wheel buttons are usually connected to the in-vehicle infotainment host (referred to as the car computer) to control the host. The wire-controlled steering wheel buttons are connected to the car computer through two positive and negative wires. By pressing different buttons, different voltages are generated, so that the car computer can identify which button is pressed. The same car computer may need to be compatible with steering wheels of different configurations at the same time. The current practice is generally to manually configure the steering wheel button type in the car computer factory setting interface, but this practice is not convenient and flexible enough, and is not conducive to the early stage of project testing and debugging, especially the later large-scale mass production. It requires a lot of manpower and time to manually configure, which greatly affects efficiency. Summary of the invention
[0003] The embodiments of the present invention provide a method, device, computer equipment and storage medium for automatically identifying automobile steering wheel buttons, aiming to solve the problem in the prior art that when the same vehicle computer needs to be compatible with steering wheels of different configurations at the same time, a large amount of manpower and time are required to manually configure, which greatly affects efficiency.
[0004] In a first aspect, an embodiment of the present invention provides a method for automatically identifying a car steering wheel button, which is applied to a car system, wherein the car system can be electrically connected to at least one car steering wheel button, and the method includes: powering on the system; obtaining a current access point voltage value corresponding to the current steering wheel button connected to the car system; determining the current steering wheel button type according to a matching result between the current access point voltage value and a preset normal state value set; wherein the normal state value set includes multiple normal state values, each normal state value corresponds to a voltage value generated when a parameter type steering wheel button is connected to the car system and no button is pressed; configuring a corresponding target button parameter set according to the current steering wheel button type; wherein the target button parameter set includes voltage values generated when multiple buttons are pressed respectively; when a voltage signal is detected, determining the current target button according to the matching result between the voltage value corresponding to the voltage signal and the target button parameter set, and executing the function corresponding to the current target button; wherein the voltage signal is generated when a button on the current steering wheel button is pressed.
[0005] In a second aspect, an embodiment of the present invention provides an automatic identification device for a car steering wheel button, which includes: a starting unit for powering on the system; an access point voltage acquisition unit for acquiring a current access point voltage value corresponding to the current steering wheel button connected to the vehicle system; a type determination unit for determining the current steering wheel button type according to a matching result between the current access point voltage value and a preset normal state value set; wherein the normal state value set includes a plurality of normal state values, each normal state value corresponding to a voltage value generated when a parameter type steering wheel button is connected to the vehicle system and no button is pressed; a button parameter configuration unit for configuring a corresponding target button parameter set according to the current steering wheel button type; wherein the target button parameter set includes voltage values generated when a plurality of buttons are pressed respectively; a button determination unit for determining the current target button according to a matching result between the voltage value corresponding to the voltage signal and the target button parameter set when a voltage signal is detected, and executing the function corresponding to the current target button; wherein the voltage signal is generated when a button on the current steering wheel button is pressed.
[0006] In a third aspect, an embodiment of the present invention further provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method for automatic recognition of car steering wheel buttons as described in the first aspect when executing the computer program.
[0007] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor executes the method for automatic recognition of car steering wheel buttons described in the first aspect above.
[0008] The embodiment of the present invention provides a method, device, computer equipment and storage medium for automatically identifying a car steering wheel button. The method is applied to a car system, and the car system can be electrically connected to at least one car steering wheel button. First, the current access point voltage value corresponding to the current steering wheel button connected to the car system is obtained; and the current steering wheel button type is determined according to the matching result of the current access point voltage value and a preset normal state value set; then the corresponding target button parameter set is configured according to the current steering wheel button type, and the target button parameter set includes the voltage values generated when multiple buttons are pressed respectively; finally, the current target button is determined according to the matching result of the voltage value generated when the button is pressed and the target button parameter set, and the function corresponding to the current target button is executed. The system automatically identifies the steering wheel button type and enables the steering wheel button to work normally without manual configuration, which is convenient and quick. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying any creative work.
[0010] Figure 1 A schematic diagram of a flow chart of a method for automatically identifying car steering wheel buttons provided by an embodiment of the present invention;
[0011] Figure 2 A schematic block diagram of a device for automatically identifying car steering wheel buttons provided by an embodiment of the present invention;
[0012] Figure 3 A schematic block diagram of a computer device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0013] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0014] It should be understood that when used in this specification and the appended claims, the terms "include" and "comprises" indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.
[0015] It should also be understood that the terms used in this specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.
[0016] It should be further understood that the term "and / or" used in the present description and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0017] See also Figure 1 , Figure 1A flow chart of a method for automatic identification of car steering wheel buttons provided in an embodiment of the present invention is provided. The method for automatic identification of car steering wheel buttons is applied in a vehicle system, and the vehicle system can be electrically connected to at least one car steering wheel button. The method is executed by application software installed in the vehicle system.
[0018] like Figure 1 As shown, the method includes steps S101 to S105.
[0019] S101, the system is powered on and started.
[0020] In this embodiment, a plurality of operation buttons are integrated on the car steering wheel, and each button has different functions, such as adjusting the volume, switching the audio source, or answering a Bluetooth call, so that the driver can control the electronic equipment in the car. However, the button settings on different types of steering wheel buttons may be different. When the same car computer needs to be compatible with steering wheels of different configurations at the same time, it is necessary to configure the corresponding steering wheel button type so that the system can correctly identify and implement the corresponding function of the button. The car steering wheel button is connected to the car computer through two positive and negative wires. After the car computer system is powered on and started, the different voltages generated when different types of steering wheel buttons are connected to the car computer are used to automatically identify the steering wheel button type. There is no need to manually configure the steering wheel button type, which is convenient, fast, accurate and reliable.
[0021] S102: Obtain a current input voltage value corresponding to a current steering wheel button connected to the vehicle system.
[0022] In this embodiment, the car steering wheel button is connected to the car computer through two positive and negative wires, wherein the negative pole of the car steering wheel button is connected to the car computer ground wire, and the positive pole is connected to the AD converter pin of the car computer chip, and the pull-up resistor is connected to the chip power supply. Assuming that the chip power supply voltage is U1, the voltage of the AD converter pin is U2, the pull-up resistor is R1, and the steering wheel button resistance is R2, wherein U1 and R1 are fixed values, then according to the formula U2=R2*U1 / (R1+R2), it can be concluded that when the steering wheel button resistance is different, the voltage on the AD converter pin of the car computer chip will also be different, thereby distinguishing the steering wheel button type. During the power-on startup process of the car computer system, the voltage value of the steering wheel button access port can be read through the AD converter, thereby obtaining the current access port voltage value corresponding to the current steering wheel button connected to the car computer system, so as to determine the current steering wheel button type based on the current access port voltage value.
[0023] S103. Determine the current steering wheel button type based on the matching result between the current access input voltage value and a preset normal state value set; wherein the normal state value set includes multiple normal state values, each normal state value corresponds to a voltage value generated when a parameter type steering wheel button is connected to the vehicle computer and no button is pressed.
[0024] In this embodiment, the voltage value of the current steering wheel button access port is read by an AD converter to obtain the current access port voltage value, which is the voltage value of the current steering wheel button in a normal state (i.e., no button is pressed). Then, the current access port voltage value is compared with the normal state value in a preset normal state value set, wherein the normal state value set includes multiple normal state values, and each normal state value corresponds to a voltage value generated when a parameter type steering wheel button is connected to the vehicle computer and no button is pressed. It is determined which normal state value the current access port voltage value matches, wherein it is also possible to set a preset interval range as a certain deviation range to determine which steering wheel button type's normal state value is within a certain deviation range, thereby determining the normal state value that matches the current access port voltage value, and then determining the current steering wheel button type.
[0025] In one embodiment, step S103 includes:
[0026] Calculate the difference between the current access voltage value and each normal state value in the normal state value set one by one, and obtain the difference calculation results corresponding to the current access voltage value and each normal state value respectively;
[0027] When it is determined that a difference calculation result is within a preset interval, a target normal state value corresponding to the difference calculation result is obtained, and a current steering wheel button type corresponding to the target normal state value is obtained;
[0028] When it is determined that all value calculation results are not within the preset interval, the current steering wheel button type determination fails, and the number of failures is recorded;
[0029] When the number of failures does not exceed the preset number, returning to the step of obtaining the current input voltage value corresponding to the current steering wheel button connected to the vehicle system;
[0030] When the number of failures exceeds the preset number of times, the current steering wheel button type is set to a preset default steering wheel button type.
[0031] In this embodiment, in order to determine the normal state value that matches the current access point voltage value, the difference between the current access point voltage value and each normal state value in the normal state value set is calculated one by one, so as to obtain the difference calculation results corresponding to the current access point voltage value and each normal state value. In addition, by setting a preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc. When it is determined that there is a difference calculation result within the preset interval range, that is, there is a normal state value that matches the current access point voltage value, the normal state value corresponding to the difference calculation result within the preset interval range is used as the target normal state value, and the steering wheel button type corresponding to the target normal state value is set as the current steering wheel button type. When it is determined that all value calculation results are not within the preset interval range, that is, the current access point voltage value read this time has no normal state value that matches it, so that the current steering wheel button type determination fails. In order to prevent the current access point voltage value from being inaccurately read due to special circumstances such as instantaneous voltage instability, and thus the steering wheel button type cannot be determined, this embodiment also takes certain avoidance measures. When the steering wheel button type cannot be determined by reading the current access point voltage value, a method of multiple cyclic reading and confirmation is adopted, that is, the number of failures in determining the current steering wheel button type is recorded. When the number of failures does not exceed the preset number, where the preset number can be set to 3 times, the process returns to step S102. If there are several consecutive failures, that is, when the number of failures exceeds the preset number, in order to avoid affecting the normal operation of the system, the current steering wheel button type will be set to the preset default steering wheel button type.
[0032] S104. Configure a corresponding target button parameter set according to the current steering wheel button type; wherein the target button parameter set includes voltage values generated when multiple buttons are pressed respectively.
[0033] In this embodiment, when the current steering wheel button type is determined, the target button parameter set corresponding to the determined steering wheel button type can be matched, wherein the target button parameter set includes the voltage values generated when the buttons on the same type of steering wheel buttons are pressed respectively, so that the vehicle system can identify which button is pressed by generating different voltages when different buttons are pressed.
[0034] In one embodiment, step S104 includes:
[0035] Acquire the actual voltage value generated when each button on the current steering wheel button is pressed to form an actual voltage value set;
[0036] Compare each actual voltage value in the actual voltage value set with the voltage value corresponding to the target key parameter set to obtain a first comparison result set;
[0037] When all comparison results included in the first comparison result set are within a preset interval, the current steering wheel button type is maintained.
[0038] In this embodiment, in order to further ensure that the determined current steering wheel button type is correct, after configuring the corresponding target button parameter set according to the current steering wheel button type, by obtaining the actual voltage value generated when each button on the current steering wheel button is pressed, each actual voltage value is compared with the corresponding voltage value in the target button parameter set to obtain a first comparison result set to determine whether each actual voltage value matches the corresponding voltage value in the target button parameter set. In addition, by setting a preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc., when the comparison results included in the first comparison result set are all within the preset interval range, it means that the determined current steering wheel button type is correct, and the vehicle system maintains the current steering wheel button type. When there is a comparison result included in the first comparison result set that is not within the preset interval range, it means that the determined current steering wheel button type may be wrong, and a corresponding reminder message can be generated by the vehicle system to prompt the user to check in time. By further detecting whether the determined current steering wheel button type is correct, the accuracy of automatic recognition of the vehicle steering wheel button is improved.
[0039] In one embodiment, after step S104, the method further includes:
[0040] Generate a prompt text, wherein the prompt text is used to prompt the user to press the buttons on the current steering wheel button in a preset order;
[0041] Acquire voltage values generated when the buttons of the current steering wheel are pressed in the preset order, and obtain a corresponding detection voltage value set;
[0042] Compare each detection voltage value in the detection voltage value set with the voltage value corresponding to the target key parameter set to obtain a second comparison result set;
[0043] When all comparison results included in the second comparison result set are within a preset interval, the current steering wheel button type is maintained.
[0044] In this embodiment, in order to further detect whether the determined current steering wheel button type is correct, after configuring the corresponding target button parameter set according to the current steering wheel button type, a prompt text can be generated by the vehicle system, so that the user presses the buttons on the current steering wheel button in a preset order according to the prompt text, and then obtains the corresponding detection voltage value set. By setting the preset order, all or part of the buttons on the current steering wheel button can be pressed in a certain order to improve the detection efficiency. Then each detection voltage value is compared with the voltage value corresponding to the target button parameter set to obtain a second comparison result set to determine whether each detection voltage value matches the corresponding voltage value in the target button parameter set. In addition, by setting a preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc., when the comparison results included in the second comparison result set are all within the preset interval range, it means that the determined current steering wheel button type is correct, and the vehicle system maintains the current steering wheel button type. When any comparison result included in the second comparison result set is not within the preset interval, it indicates that the current steering wheel button type determined may be wrong, and a corresponding reminder message can be generated through the vehicle system to prompt the user to check in time, thereby improving the accuracy of automatic recognition of the vehicle steering wheel buttons.
[0045] S105. When a voltage signal is detected, the current target button is determined according to the matching result between the voltage value corresponding to the voltage signal and the target button parameter set, and the function corresponding to the current target button is executed; wherein the voltage signal is generated when a button on the current steering wheel button is pressed.
[0046] In this embodiment, when a voltage signal is detected, where the voltage signal is generated when a button on the current steering wheel button is pressed, it means that a button on the current steering wheel button is pressed, and then the current target button is determined based on the matching result of the voltage value corresponding to the voltage signal and the target button parameter set, that is, the vehicle system correctly identifies which button on the current steering wheel button is pressed, and then executes the function corresponding to the current target button.
[0047] In one embodiment, step S105 includes:
[0048] When receiving a voltage signal generated when a button on the current steering wheel button is pressed, obtaining a voltage value generated when the current button is pressed;
[0049] Compare the voltage value generated when the current key is pressed with the voltage value corresponding to the target key parameter set one by one, and obtain a current target voltage value whose difference with the voltage value generated when the current key is pressed is within a preset interval;
[0050] A current target button is determined according to the current target voltage value, and a function corresponding to the current target button is executed.
[0051] In this embodiment, when a button on the current steering wheel button is pressed, the vehicle system detects the corresponding voltage signal and reads the voltage value generated when the current button is pressed through the AD converter. Then, the voltage value generated when the current button is pressed is compared one by one with the voltage value corresponding to the target button parameter set to determine which voltage value in the target button parameter set the voltage value generated when the current button is pressed is within the preset interval range, thereby obtaining the current target voltage value. Among them, the difference between the voltage value generated when the current button is pressed and the voltage value corresponding to the target button parameter set is calculated one by one, and by setting the preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc., it is determined which difference is within the preset interval range, and then the voltage value corresponding to the difference in the target button parameter set is used as the current target voltage value. Finally, the current target button is determined according to the current target voltage value, that is, the vehicle system correctly identifies which button on the current steering wheel button is pressed, and then executes the function corresponding to the current target button.
[0052] In one embodiment, before step S101, the process includes:
[0053] Obtain multiple types of steering wheel buttons, and a normal state value and button parameter set corresponding to each type of steering wheel button;
[0054] The normal state value and key parameter set corresponding to each type of steering wheel key are stored in a steering wheel key data structure;
[0055] The steering wheel button data structure corresponding to each type of steering wheel button is stored in the structure array to update the structure array.
[0056] In this embodiment, different voltages generated when different types of steering wheel buttons are connected to the vehicle computer are used to automatically identify the type of steering wheel buttons. The implementation of this method includes two parts: data acquisition and software design. Among them, data acquisition is to collect voltage values generated when different types of steering wheel buttons are connected to the vehicle computer in a normal state (i.e., no button is pressed) and when each button is pressed. The voltage value generated when the steering wheel button is connected to the vehicle computer in a normal state (i.e., no button is pressed) is recorded as the normal state value of the steering wheel button of this type, and the voltage values generated when the buttons on the steering wheel button are pressed respectively constitute a key parameter set of the steering wheel button of this type, and are written as preset parameter data in the code for use in subsequent software design. The data acquisition step does not require complicated calculations based on the circuit schematic diagram. It only requires connecting different types of steering wheel buttons to the vehicle computer and directly measuring the voltage values generated in the normal state and when each button is pressed after power-on. It is convenient, fast, accurate and reliable, and multiple measurements can be taken to obtain an average value to reduce errors. In this way, complicated formula calculations can be avoided and the error between the actual value and the theoretical value caused by the voltage resistance deviation of the actual circuit can be reduced.
[0057] The collected data is sorted and written into the code. The data structure of each type of steering wheel button is the same, that is, they all contain arrays of normal state voltage values and voltage values when the button is pressed. You can first declare a steering wheel button data structure that contains an array of normal state values and voltage values when the button is pressed. The array of voltage values when the button is pressed is arranged in a fixed order and includes the voltage values generated when multiple buttons in the corresponding button parameter set are pressed respectively. Then, the different types of steering wheel button data structures are combined into a structure array, and the data of each type of steering wheel buttons obtained previously are filled into it. Among them, by obtaining multiple types of steering wheel buttons collected previously, and the normal state value and button parameter set corresponding to each type of steering wheel button, and storing the normal state value and button parameter set corresponding to each type of steering wheel button in a steering wheel button data structure, the voltage values generated when multiple buttons in the button parameter set are pressed are stored in a button pressed voltage value array, and then the steering wheel button data structure corresponding to each type of steering wheel button is stored in a structure array to update the structure array, so that the vehicle system can automatically identify the current steering wheel button type and the current target button by comparing the data in the structure array, so that the steering wheel button only needs to be connected to the vehicle computer and can be used normally after power-on.
[0058] In one embodiment, it further includes:
[0059] If it is detected that the current system time meets the preset update condition, update data is obtained to update the steering wheel button data structure and the structure array.
[0060] In this embodiment, in order to update data in a timely manner so as to correctly identify the car steering wheel buttons, when it is detected that the current system time meets the preset update conditions, the steering wheel button data structure and structure array can be updated by obtaining update data, so that the data in the steering wheel button data structure and structure array can be updated in a timely manner.
[0061] The method utilizes the different voltage values generated when different types of steering wheel buttons are connected to the vehicle computer in a normal state (i.e., no button is pressed) and when each button is pressed to automatically identify the type of steering wheel buttons and buttons, and set the corresponding data parameters. As long as the vehicle computer system is connected to the steering wheel buttons and powered on, the vehicle computer system will automatically identify the type of steering wheel buttons and enable the steering wheel buttons to work normally without manual configuration. This is convenient and quick, especially when the product is mass-produced, which greatly reduces labor and time costs and improves production efficiency.
[0062] The embodiment of the present invention also provides a device for automatically identifying car steering wheel buttons, which is used to execute any embodiment of the aforementioned method for automatically identifying car steering wheel buttons. Figure 2 , Figure 2 A schematic block diagram of an automatic identification device 100 for automobile steering wheel buttons provided in an embodiment of the present invention.
[0063] Among them, Figure 2 As shown, the vehicle steering wheel button automatic recognition device 100 includes a starting unit 101, an input voltage acquisition unit 102, a type determination unit 103, a button parameter configuration unit 104 and a button determination unit 105. The vehicle steering wheel button automatic recognition device 100 is applied to a vehicle system, and the vehicle system can be electrically connected to at least one vehicle steering wheel button.
[0064] The startup unit 101 is used for powering on and starting the system.
[0065] In this embodiment, a plurality of operation buttons are integrated on the car steering wheel, and each button has different functions, such as adjusting the volume, switching the audio source, or answering a Bluetooth call, so that the driver can control the electronic equipment in the car. However, the button settings on different types of steering wheel buttons may be different. When the same car computer needs to be compatible with steering wheels of different configurations at the same time, it is necessary to configure the corresponding steering wheel button type so that the system can correctly identify and implement the corresponding function of the button. The car steering wheel button is connected to the car computer through two positive and negative wires. After the car computer system is powered on and started, the different voltages generated when different types of steering wheel buttons are connected to the car computer are used to automatically identify the steering wheel button type. There is no need to manually configure the steering wheel button type, which is convenient, fast, accurate and reliable.
[0066] The inlet voltage acquisition unit 102 is used to acquire the current inlet voltage value corresponding to the current steering wheel button connected to the vehicle system.
[0067] In this embodiment, the car steering wheel button is connected to the car computer through two positive and negative wires, wherein the negative pole of the car steering wheel button is connected to the car computer ground wire, and the positive pole is connected to the AD converter pin of the car computer chip, and the pull-up resistor is connected to the chip power supply. Assuming that the chip power supply voltage is U1, the voltage of the AD converter pin is U2, the pull-up resistor is R1, and the steering wheel button resistance is R2, wherein U1 and R1 are fixed values, then according to the formula U2=R2*U1 / (R1+R2), it can be concluded that when the steering wheel button resistance is different, the voltage on the AD converter pin of the car computer chip will also be different, thereby distinguishing the steering wheel button type. During the power-on startup process of the car computer system, the voltage value of the steering wheel button access port can be read through the AD converter, thereby obtaining the current access port voltage value corresponding to the current steering wheel button connected to the car computer system, so as to determine the current steering wheel button type based on the current access port voltage value.
[0068] The type determination unit 103 is used to determine the current steering wheel button type based on the matching result between the current access input voltage value and a preset normal state value set; wherein the normal state value set includes multiple normal state values, each normal state value corresponds to a voltage value generated when a parameter type steering wheel button is connected to the vehicle computer and no button is pressed.
[0069] In this embodiment, the voltage value of the current steering wheel button access port is read by an AD converter to obtain the current access port voltage value, which is the voltage value of the current steering wheel button in a normal state (i.e., no button is pressed). Then, the current access port voltage value is compared with the normal state value in a preset normal state value set, wherein the normal state value set includes multiple normal state values, and each normal state value corresponds to a voltage value generated when a parameter type steering wheel button is connected to the vehicle computer and no button is pressed. It is determined which normal state value the current access port voltage value matches, wherein it is also possible to set a preset interval range as a certain deviation range to determine which steering wheel button type's normal state value is within a certain deviation range, thereby determining the normal state value that matches the current access port voltage value, and then determining the current steering wheel button type.
[0070] In one embodiment, the type determination unit 103 is specifically configured to:
[0071] Calculate the difference between the current access voltage value and each normal state value in the normal state value set one by one, and obtain the difference calculation results corresponding to the current access voltage value and each normal state value respectively;
[0072] When it is determined that a difference calculation result is within a preset interval, a target normal state value corresponding to the difference calculation result is obtained, and a current steering wheel button type corresponding to the target normal state value is obtained;
[0073] When it is determined that all value calculation results are not within the preset interval, the current steering wheel button type determination fails, and the number of failures is recorded;
[0074] When the number of failures does not exceed the preset number, returning to the step of obtaining the current input voltage value corresponding to the current steering wheel button connected to the vehicle system;
[0075] When the number of failures exceeds the preset number of times, the current steering wheel button type is set to a preset default steering wheel button type.
[0076] In this embodiment, in order to determine the normal state value that matches the current access point voltage value, the difference between the current access point voltage value and each normal state value in the normal state value set is calculated one by one, so as to obtain the difference calculation results corresponding to the current access point voltage value and each normal state value. In addition, by setting a preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc. When it is determined that there is a difference calculation result within the preset interval range, that is, there is a normal state value that matches the current access point voltage value, the normal state value corresponding to the difference calculation result within the preset interval range is used as the target normal state value, and the steering wheel button type corresponding to the target normal state value is set as the current steering wheel button type. When it is determined that all value calculation results are not within the preset interval range, that is, the current access point voltage value read this time has no normal state value that matches it, so that the current steering wheel button type determination fails. In order to prevent the current access point voltage value from being inaccurately read due to special circumstances such as instantaneous voltage instability, and thus the steering wheel button type cannot be determined, this embodiment also takes certain avoidance measures. When the current access point voltage value cannot determine the steering wheel button type, a method of multiple cyclic reading and confirmation is adopted, that is, the number of failures in determining the current steering wheel button type is recorded. When the number of failures does not exceed the preset number, where the preset number can be set to 3 times, the step of obtaining the current access point voltage value corresponding to the current steering wheel button connected to the vehicle system is returned. If there are several consecutive failures, that is, when the number of failures exceeds the preset number, in order to avoid affecting the normal operation of the system, the current steering wheel button type will be set to the preset default steering wheel button type.
[0077] The button parameter configuration unit 104 is used to configure a corresponding target button parameter set according to the current steering wheel button type; wherein the target button parameter set includes voltage values generated when multiple buttons are pressed respectively.
[0078] In this embodiment, when the current steering wheel button type is determined, the target button parameter set corresponding to the determined steering wheel button type can be matched, wherein the target button parameter set includes the voltage values generated when the buttons on the same type of steering wheel buttons are pressed respectively, so that the vehicle system can identify which button is pressed by generating different voltages when different buttons are pressed.
[0079] In one embodiment, the vehicle steering wheel button automatic recognition device 100 further includes:
[0080] an actual voltage value acquisition unit, used to acquire the actual voltage value generated when each button on the current steering wheel button is pressed, so as to form an actual voltage value set;
[0081] A first comparison result set unit, configured to compare each actual voltage value in the actual voltage value set with a voltage value corresponding to the target key parameter set to obtain a first comparison result set;
[0082] The type detection unit maintains the current steering wheel button type when all comparison results included in the first comparison result set are within a preset interval.
[0083] In this embodiment, in order to further ensure that the determined current steering wheel button type is correct, after configuring the corresponding target button parameter set according to the current steering wheel button type, by obtaining the actual voltage value generated when each button on the current steering wheel button is pressed, each actual voltage value is compared with the corresponding voltage value in the target button parameter set to obtain a first comparison result set to determine whether each actual voltage value matches the corresponding voltage value in the target button parameter set. In addition, by setting a preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc., when the comparison results included in the first comparison result set are all within the preset interval range, it means that the determined current steering wheel button type is correct, and the vehicle system maintains the current steering wheel button type. When there is a comparison result included in the first comparison result set that is not within the preset interval range, it means that the determined current steering wheel button type may be wrong, and a corresponding reminder message can be generated by the vehicle system to prompt the user to check in time. By further detecting whether the determined current steering wheel button type is correct, the accuracy of automatic recognition of the vehicle steering wheel button is improved.
[0084] In one embodiment, the vehicle steering wheel button automatic recognition device 100 further includes:
[0085] A prompt text generating unit, used to generate a prompt text, wherein the prompt text is used to prompt the user to press the buttons on the current steering wheel button in a preset order;
[0086] A detection voltage value acquisition unit, used to acquire voltage values generated when the buttons of the current steering wheel buttons are pressed in the preset order, and obtain a corresponding detection voltage value set;
[0087] A second comparison result set unit, configured to compare each detection voltage value in the detection voltage value set with a voltage value corresponding to the target key parameter set to obtain a second comparison result set;
[0088] A type checking unit is used to maintain the current steering wheel button type when all comparison results included in the second comparison result set are within a preset interval.
[0089] In this embodiment, in order to further detect whether the determined current steering wheel button type is correct, after configuring the corresponding target button parameter set according to the current steering wheel button type, a prompt text can be generated by the vehicle system, so that the user presses the buttons on the current steering wheel button in a preset order according to the prompt text, and then obtains the corresponding detection voltage value set. By setting the preset order, all or part of the buttons on the current steering wheel button can be pressed in a certain order to improve the detection efficiency. Then each detection voltage value is compared with the voltage value corresponding to the target button parameter set to obtain a second comparison result set to determine whether each detection voltage value matches the corresponding voltage value in the target button parameter set. In addition, by setting a preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc., when the comparison results included in the second comparison result set are all within the preset interval range, it means that the determined current steering wheel button type is correct, and the vehicle system maintains the current steering wheel button type. When any comparison result included in the second comparison result set is not within the preset interval, it indicates that the current steering wheel button type determined may be wrong, and a corresponding reminder message can be generated through the vehicle system to prompt the user to check in time, thereby improving the accuracy of automatic recognition of the vehicle steering wheel buttons.
[0090] The key determination unit 105 is used to determine the current target key according to the matching result between the voltage value corresponding to the voltage signal and the target key parameter set when a voltage signal is detected, and execute the function corresponding to the current target key; wherein the voltage signal is generated when the key on the current steering wheel button is pressed.
[0091] In this embodiment, when a voltage signal is detected, where the voltage signal is generated when a button on the current steering wheel button is pressed, it means that a button on the current steering wheel button is pressed, and then the current target button is determined based on the matching result of the voltage value corresponding to the voltage signal and the target button parameter set, that is, the vehicle system correctly identifies which button on the current steering wheel button is pressed, and then executes the function corresponding to the current target button.
[0092] In one embodiment, the key determination unit 105 is specifically used for:
[0093] When receiving a voltage signal generated when a button on the current steering wheel button is pressed, obtaining a voltage value generated when the current button is pressed;
[0094] Compare the voltage value generated when the current key is pressed with the voltage value corresponding to the target key parameter set one by one, and obtain a current target voltage value whose difference with the voltage value generated when the current key is pressed is within a preset interval;
[0095] A current target button is determined according to the current target voltage value, and a function corresponding to the current target button is executed.
[0096] In this embodiment, when a button on the current steering wheel button is pressed, the vehicle system detects the corresponding voltage signal and reads the voltage value generated when the current button is pressed through the AD converter. Then, the voltage value generated when the current button is pressed is compared one by one with the voltage value corresponding to the target button parameter set to determine which voltage value in the target button parameter set the voltage value generated when the current button is pressed is within the preset interval range, thereby obtaining the current target voltage value. Among them, the difference between the voltage value generated when the current button is pressed and the voltage value corresponding to the target button parameter set is calculated one by one, and by setting the preset interval range as a certain deviation range, for example, the preset interval range can be [-0.25, 0.25], [-0.5, 0.5], etc., it is determined which difference is within the preset interval range, and then the voltage value corresponding to the difference in the target button parameter set is used as the current target voltage value. Finally, the current target button is determined according to the current target voltage value, that is, the vehicle system correctly identifies which button on the current steering wheel button is pressed, and then executes the function corresponding to the current target button.
[0097] In one embodiment, the vehicle steering wheel button automatic recognition device 100 further includes:
[0098] A data acquisition unit, used to acquire multiple types of steering wheel buttons, and a normal state value and a button parameter set corresponding to each type of steering wheel button;
[0099] A data storage unit, used for storing a normal state value and a key parameter set corresponding to each type of steering wheel key in a steering wheel key data structure;
[0100] The structure array updating unit is used to store the steering wheel button data structure corresponding to each type of steering wheel button in the structure array to update the structure array.
[0101] In this embodiment, different voltages generated when different types of steering wheel buttons are connected to the vehicle computer are used to automatically identify the type of steering wheel buttons. The implementation of this method includes two parts: data acquisition and software design. Among them, data acquisition is to collect voltage values generated when different types of steering wheel buttons are connected to the vehicle computer in a normal state (i.e., no button is pressed) and when each button is pressed. The voltage value generated when the steering wheel button is connected to the vehicle computer in a normal state (i.e., no button is pressed) is recorded as the normal state value of the steering wheel button of this type, and the voltage values generated when the buttons on the steering wheel button are pressed respectively constitute a key parameter set of the steering wheel button of this type, and are written as preset parameter data in the code for use in subsequent software design. The data acquisition step does not require complicated calculations based on the circuit schematic diagram. It only requires connecting different types of steering wheel buttons to the vehicle computer and directly measuring the voltage values generated in the normal state and when each button is pressed after power-on. It is convenient, fast, accurate and reliable, and multiple measurements can be taken to obtain an average value to reduce errors. In this way, complicated formula calculations can be avoided and the error between the actual value and the theoretical value caused by the voltage resistance deviation of the actual circuit can be reduced.
[0102] The collected data is sorted and written into the code. The data structure of each type of steering wheel button is the same, that is, they all contain arrays of normal state voltage values and voltage values when the button is pressed. You can first declare a steering wheel button data structure that contains an array of normal state values and voltage values when the button is pressed. The array of voltage values when the button is pressed is arranged in a fixed order and includes the voltage values generated when multiple buttons in the corresponding button parameter set are pressed respectively. Then, the different types of steering wheel button data structures are combined into a structure array, and the data of each type of steering wheel buttons obtained previously are filled into it. Among them, by obtaining multiple types of steering wheel buttons collected previously, and the normal state value and button parameter set corresponding to each type of steering wheel button, and storing the normal state value and button parameter set corresponding to each type of steering wheel button in a steering wheel button data structure, the voltage values generated when multiple buttons in the button parameter set are pressed are stored in a button pressed voltage value array, and then the steering wheel button data structure corresponding to each type of steering wheel button is stored in a structure array to update the structure array, so that the vehicle system can automatically identify the current steering wheel button type and the current target button by comparing the data in the structure array, so that the steering wheel button only needs to be connected to the vehicle computer and can be used normally after power-on.
[0103] In one embodiment, the vehicle steering wheel button automatic recognition device 100 further includes:
[0104] The data updating unit is used to obtain update data to update the steering wheel button data structure and the structure array if it is detected that the current system time meets the preset update condition.
[0105] In this embodiment, in order to update data in a timely manner so as to correctly identify the car steering wheel buttons, when it is detected that the current system time meets the preset update conditions, the steering wheel button data structure and structure array can be updated by obtaining update data, so that the data in the steering wheel button data structure and structure array can be updated in a timely manner.
[0106] The device uses the different voltage values generated when different types of steering wheel buttons are connected to the vehicle computer in the normal state (i.e. no button is pressed) and when each button is pressed to automatically identify the type of steering wheel buttons and buttons, and set the corresponding data parameters. As long as the vehicle computer system is connected to the steering wheel buttons and powered on, the vehicle computer system will automatically identify the type of steering wheel buttons and enable the steering wheel buttons to work normally. No manual configuration is required, which is convenient and fast. Especially when the product is mass-produced, it greatly reduces labor and time costs and improves production efficiency.
[0107] The above-mentioned vehicle steering wheel button automatic recognition device can be implemented in the form of a computer program, and the computer program can be used in Figure 3Runs on the computer device shown.
[0108] See also Figure 3 , Figure 3 The computer device 500 is a vehicle computer, which is an abbreviation of an in-vehicle infotainment product installed in a car. The vehicle computer can realize information communication between people and cars, and between cars and the outside world (cars).
[0109] See also Figure 3 The computer device 500 includes a processor 502 , a memory and a network interface 505 connected via a device bus 501 , wherein the memory may include a storage medium 503 and an internal memory 504 .
[0110] The storage medium 503 can store an operating device 5031 and a computer program 5032. When the computer program 5032 is executed, the processor 502 can execute the method for automatically identifying the buttons on the steering wheel of a car.
[0111] The processor 502 is used to provide computing and control capabilities to support the operation of the entire computer device 500 .
[0112] The internal memory 504 provides an environment for the operation of the computer program 5032 in the storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute the method for automatically identifying the car steering wheel buttons.
[0113] The network interface 505 is used for network communication, such as providing data information transmission, etc. Those skilled in the art will understand that Figure 3 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present invention, and does not constitute a limitation on the computer device 500 to which the solution of the present invention is applied. The specific computer device 500 may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0114] The processor 502 is used to run the computer program 5032 stored in the memory to implement the method for automatically identifying the car steering wheel buttons disclosed in the embodiment of the present invention.
[0115] Those skilled in the art will understand that Figure 3 The embodiments of the computer device shown in the figure do not constitute a limitation on the specific composition of the computer device. In other embodiments, the computer device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently. For example, in some embodiments, the computer device may only include a memory and a processor. In such embodiments, the structure and function of the memory and the processor are the same as those of the embodiment of the present invention. Figure 3The embodiments shown are consistent and will not be described again here.
[0116] It should be understood that in the embodiment of the present invention, the processor 502 may be a central processing unit (CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0117] In another embodiment of the present invention, a computer-readable storage medium is provided. The computer-readable storage medium may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium. The computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the method for automatically identifying a car steering wheel button disclosed in an embodiment of the present invention is implemented.
[0118] Those skilled in the art can clearly understand that, for the convenience and simplicity of description, the specific working process of the above-described equipment, devices and units can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here. Those of ordinary skill in the art can appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented with electronic hardware, computer software or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to the function. Whether these functions are executed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.
[0119] In the several embodiments provided by the present invention, it should be understood that the disclosed equipment, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. Units with the same function may also be combined into one unit. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interfaces, devices or units, or may be electrical, mechanical or other forms of connection.
[0120] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiments of the present invention.
[0121] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0122] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a background server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), disk or CD-ROM and other media that can store program codes.
[0123] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.
Claims
1. A method for automatically identifying car steering wheel buttons, applied to a car computer system, characterized in that: The vehicle system may be electrically connected to at least one vehicle steering wheel button, and the method includes: The system is powered on and started; Obtaining a current input voltage value corresponding to a current steering wheel button connected to the vehicle system; Determine the current steering wheel button type according to the matching result of the current access voltage value and the preset normal state value set; wherein the normal state value set includes multiple normal state values, each normal state value corresponds to a voltage value generated when a parameter type steering wheel button is connected to the vehicle computer and no button is pressed; configuring a corresponding target button parameter set according to the current steering wheel button type; wherein the target button parameter set includes voltage values generated when a plurality of buttons are pressed respectively; When a voltage signal is detected, the current target key is determined according to the matching result between the voltage value corresponding to the voltage signal and the target key parameter set, and the function corresponding to the current target key is executed; wherein the voltage signal is generated when a key on the current steering wheel key is pressed; After configuring the corresponding target button parameter set according to the current steering wheel button type, the method further includes: Generate a prompt text, wherein the prompt text is used to prompt the user to press the buttons on the current steering wheel button in a preset order; Acquire voltage values generated when the buttons of the current steering wheel are pressed in the preset order, and obtain a corresponding detection voltage value set; Compare each detection voltage value in the detection voltage value set with the voltage value corresponding to the target key parameter set to obtain a second comparison result set; When all comparison results included in the second comparison result set are within a preset interval, the current steering wheel button type is maintained.
2. The method for automatically identifying car steering wheel buttons according to claim 1, characterized in that: The determining the current steering wheel button type according to the matching result of the current input voltage value and the preset normal state value set includes: Calculate the difference between the current access voltage value and each normal state value in the normal state value set one by one, and obtain the difference calculation results corresponding to the current access voltage value and each normal state value respectively; When it is determined that a difference calculation result is within a preset interval, a target normal state value corresponding to the difference calculation result is obtained, and a current steering wheel button type corresponding to the target normal state value is obtained; When it is determined that all value calculation results are not within the preset interval, the current steering wheel button type determination fails, and the number of failures is recorded; When the number of failures does not exceed the preset number, returning to the step of obtaining the current input voltage value corresponding to the current steering wheel button connected to the vehicle system; When the number of failures exceeds the preset number of times, the current steering wheel button type is set to a preset default steering wheel button type.
3. The method for automatically identifying car steering wheel buttons according to claim 1, characterized in that: After configuring the corresponding target button parameter set according to the current steering wheel button type, the method further includes: Acquire the actual voltage value generated when each button on the current steering wheel is pressed to form an actual voltage value set; Compare each actual voltage value in the actual voltage value set with the voltage value corresponding to the target key parameter set to obtain a first comparison result set; When all comparison results included in the first comparison result set are within a preset interval, the current steering wheel button type is maintained.
4. The method for automatically identifying car steering wheel buttons according to claim 1, characterized in that: When a voltage signal is detected, determining a current target key according to a matching result between a voltage value corresponding to the voltage signal and the target key parameter set, and executing a function corresponding to the current target key, includes: When receiving a voltage signal generated when a button on the current steering wheel button is pressed, obtaining a voltage value generated when the current button is pressed; Compare the voltage value generated when the current key is pressed with the voltage value corresponding to the target key parameter set one by one, and obtain a current target voltage value whose difference with the voltage value generated when the current key is pressed is within a preset interval; A current target button is determined according to the current target voltage value, and a function corresponding to the current target button is executed.
5. The method for automatically identifying car steering wheel buttons according to claim 1, characterized in that: Before the system is powered on and started, the system also includes: Obtain multiple types of steering wheel buttons, and a normal state value and button parameter set corresponding to each type of steering wheel button; The normal state value and key parameter set corresponding to each type of steering wheel key are stored in a steering wheel key data structure; The steering wheel button data structure corresponding to each type of steering wheel button is stored in the structure array to update the structure array.
6. The method for automatically identifying car steering wheel buttons according to claim 5, characterized in that: include: If it is detected that the current system time meets the preset update condition, update data is obtained to update the steering wheel button data structure and the structure array.
7. An automatic identification device for car steering wheel buttons, applied to a car computer system, characterized in that: The vehicle system can be electrically connected to at least one vehicle steering wheel button, and the vehicle steering wheel button automatic recognition device includes a unit for executing the vehicle steering wheel button automatic recognition method as described in any one of claims 1-6.
8. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the method for automatically identifying automobile steering wheel buttons according to any one of claims 1 to 6 is implemented.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, which, when executed by a processor, enables the processor to execute the method for automatic recognition of automobile steering wheel buttons as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Steering wheel key function learning method and system as well as corresponding vehicular information system
CN102145657A
Steering wheel key function learning system
CN103738271A