Combined control method of intelligent key and intelligent key
By adding a judgment and update mechanism for the combined key port value in the smart key, the problem of the combined key function not being triggered under short-interval key presses is solved, improving user experience and system reliability.
Patent Information
- Application Number
- CN202410839096.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-26
- Publication Date
- 2024-10-15
AI Technical Summary
Existing smart keys cannot correctly send out the key port value corresponding to the key combination when the user presses two keys consecutively for a short time, resulting in the key combination function not being triggered, affecting the user experience.
By adding a judgment and update mechanism for the combination key port value in the smart key, it is ensured that the key port value corresponding to the combination key value can be correctly issued regardless of whether the key trigger sequence is reversed, including updating when the MCU reads the combination key port value. The key port value ensures the normal triggering of the combined key function.
It solves the problem of the combination key function not being triggered, improves the user experience, avoids misjudgment of smart key failures, and ensures that the smart key can still work normally under short-interval key operations.
Smart Images

Figure CN118781684A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of vehicle control technology, and in particular to a combination control method of a smart key and a smart key. Background Art
[0002] Users can interact with the vehicle through the smart key to achieve control of the vehicle, such as unlocking and locking the doors, finding the vehicle, keyless start, opening the back door, etc. In the daily use of the vehicle, the smart key has become an indispensable part.
[0003] At present, the body of the smart key is generally designed with four function buttons: unlock button, lock button, remote control back door opening button and car search button. When the user wants to realize the above single-key functions, after the user presses the corresponding button of the smart key, the smart key will generate the corresponding button port value according to the button situation, and send a control signal carrying the button port value to the vehicle. The vehicle parses the button port value in the control signal and realizes the corresponding function. For other functions, multiple buttons can be pressed continuously in the form of combination buttons, so that the smart key generates a combination button port value different from the button port value of each single button, and sends the control signal carrying the combination button port value to the vehicle, which can realize the function of the combination button after recognition by the vehicle.
[0004] However, in actual operation, when the time interval between the user pressing two buttons continuously is less than the minimum button detection cycle of the microcontroller unit (MCU) of the smart key, the smart key may only be able to send the button port value corresponding to a single button, and cannot send the button port value corresponding to the combination button, which may cause the function of the combination button not to be triggered, affecting the user experience. Summary of the invention
[0005] In order to solve the above-mentioned technical problems existing in the prior art, the present application provides a combination control method and a smart key for a smart key, which can correctly send the key port value corresponding to the combination key when the user presses two buttons continuously at a short time interval, so that the function of the combination key can be triggered normally, thereby ensuring the user's usage experience and avoiding the user from misjudging the smart key failure because the function of the combination key is not triggered.
[0006] In the first aspect, the present application provides a combination control method for a smart key, wherein the smart key includes multiple buttons, and the smart key supports triggering a combination button function through a combination button, the method comprising: reading a newly added button port value, the button port value is generated when one or more buttons are pressed; when the newly added button port value is a port value corresponding to a single button, updating the button port value according to the newly added button port value and the previous button port value; when the newly added button port value is a port value corresponding to multiple buttons, updating the button port value according to the newly added button port value; when the updated button port value is the port value corresponding to the combination button, using the port value corresponding to the combination button to generate a vehicle control signal.
[0007] The method provided by the present application not only determines whether the newly added key port value is the key port value corresponding to a single key, but also adds the judgment of the combined key port value, that is, it adds the determination of whether the newly added key port value is the port value corresponding to multiple keys. When the time interval between the user pressing two keys is long, resulting in the detection of two key port value changes, the key port value corresponding to the combined key value can be obtained by combining the second newly added key port value with the first key port value. When the user presses two keys almost at the same time, resulting in the newly added key port value being the key port value corresponding to the combined key, the key port value can be updated according to the key port value of the newly added combined key, to ensure that the updated key port value corresponds to the combined key, so that the function of the combined key can be triggered normally, thereby ensuring the user's experience and avoiding the user's misjudgment of the smart key failure because the function of the combined key is not triggered.
[0008] In a possible implementation, the keys corresponding to the first port value and the second port value respectively are the first combination keys, the key port value corresponding to the first combination key is the third port value, the first combination key is used to implement the first combination key function, and when the newly added key port value is the port value corresponding to a single key, the key port value is updated according to the newly added key port value and the previous key port value, specifically including: when the newly added key port value is the first port value, determining the previous key port value; when the previous key port value is the second port value, updating the key port value to the third port value; when the newly added key port value is the second port value, determining the previous key port value; when the previous key port value is the first port value, updating the key port value to the third port value.
[0009] That is, no matter whether the key triggering sequence of the combination key is reversed, the technical solution of the present application can correctly send out the key port value corresponding to the combination key value.
[0010] In one possible implementation, when no key is pressed, the key port value is zero, and the method further includes: when the newly added key port value is the first port value and the previous key port value is zero, updating the key port value to the first port value; when the newly added key port value is the second port value and the previous key port value is zero, updating the key port value to the second port value.
[0011] At this time, the user only presses a single key, and the port value is updated to the function corresponding to the single key.
[0012] In a possible implementation, the method also includes: when the newly added key port value is the first port value and the previous key port value is the fourth port value, the key port value is updated to the first port value, and there is no combination key function between the keys corresponding to the fourth port value and the first port value; when the newly added key port value is the second port value and the previous key port value is the fourth port value, the key port value is updated to the second port value.
[0013] At this time, although the user presses two buttons successively, resulting in two updates of the port value, there is no combination button function between the two buttons, that is, the two buttons are used to realize independent functions respectively, and the updated button port value remains unchanged at this time.
[0014] In one possible implementation, the method also includes: when the newly added key port value is the first port value and the previous key port value is the third port value, updating the key port value to the third port value; when the newly added key port value is the second port value and the previous key port value is the third port value, updating the key port value to the third port value.
[0015] In this implementation, when the previous key port value is a combination key value, if the next key port value is the port value of a single key, the port value can still be updated to the port value of the combination key, so that when the user triggers the combination key multiple times, if only one button in the combination key is pressed due to an error operation, the key port value can also be updated to the port value of the combination key.
[0016] In a possible implementation, the key port value corresponding to the first combination key is the third port value, the first combination key is used to implement the first combination key function, and when the newly added key port value is the port value corresponding to multiple keys, the key port value is updated according to the newly added key port value, including: when the newly added key port value is the third port value, the key port value is updated to the third port value. In a possible implementation, the first combination key includes an unlocking key and a locking key, and the function of the first combination key is to lower the vehicle suspension.
[0017] In a second aspect, the present application also provides a smart key, which includes a processor and at least two buttons. One or more buttons are used to generate a newly added button port value when pressed. The processor is used to read the newly added button port value; when the newly added button port value is the port value corresponding to a single button, the button port value is updated according to the newly added button port value and the previous button port value; when the newly added button port value is the port value corresponding to multiple buttons, the button port value is updated according to the newly added button port value; when the updated button port value is the port value corresponding to a combination button, the control signal of the vehicle is generated using the port value corresponding to the combination button.
[0018] In a possible implementation, the keys corresponding to the first port value and the second port value are respectively a first combination key, the key port value corresponding to the first combination key is a third port value, the first combination key is used to implement the function of the first combination key, and the processor is specifically used to: when the newly added key port value is the first port value, determine the previous key port value; when the current key port value is the second port value, update the key port value to the third port value; when the newly added key port value is the second port value, determine the previous key port value; when the current key port value is the first port value, update the key port value to the third port value.
[0019] In one possible implementation, the key port value corresponding to the first combination key is the third port value, the first combination key is used to implement the first combination key function, and the processor is specifically used to update the key port value to the third port value when the newly added key port value is the third port value.
[0020] In a possible implementation, the smart key includes at least the following four buttons: an unlock button, a lock button, a remote control back door opening button, and a vehicle search button. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 A schematic diagram of a smart key provided in an embodiment of the present application;
[0022] Figure 2 A schematic diagram of the structure of the smart key provided for this application;
[0023] Figure 3 A flowchart of a combination control method of an existing smart key is provided for an embodiment of the present application;
[0024] Figure 4 A flowchart of a combination control method of a smart key provided in an embodiment of the present application;
[0025] Figure 5 A flowchart of another combination control method of a smart key provided in an embodiment of the present application;
[0026] Figure 6 A schematic diagram of a smart key provided in an embodiment of the present application. DETAILED DESCRIPTION
[0027] In order to enable those skilled in the art to more clearly understand the present application scheme, the application scenario of the present application technical scheme is first described below.
[0028] See also Figure 1 and Figure 2 .in, Figure 1 A schematic diagram of a smart key provided in an embodiment of the present application; Figure 2 This is a schematic diagram of the structure of the smart key provided in this application.
[0029] The smart key 10 is generally designed with four function buttons: an unlock button 11 , a lock button 12 , a remote control back door opening button 13 and a vehicle search button 14 .
[0030] In the existing solution, when the key of the key port 110 of the smart key is pressed, a corresponding port key value can be generated. The MCU 120 processes the new port key value read this time, and combines the port key value read last time to obtain the key value to be sent, and then sends a control signal carrying the key value to the vehicle through the signal sending module 130.
[0031] See also Figure 3 , which is a flow chart of a combination control method of an existing smart key provided in an embodiment of the present application.
[0032] When a key is pressed, the key port becomes valid, the MCU is awakened and starts to read the newly added key port value, that is, S11 is executed.
[0033] It takes about 3ms from the time the key port becomes effective to the time the MCU wakes up and starts detecting keys.
[0034] In the following description, it is taken as an example that the key port value generated after pressing the lock key is 01, the key port value generated after pressing the unlock key is 02, and the key port value generated after pressing the unlock key and the lock key at the same time is 03.
[0035] In the prior art solution, the recognition logic for the combination key is to recognize the two changes of the key port caused by two keys being pressed twice in succession, and then determine the key value to be sent corresponding to the combination key.
[0036] For example, when the user wants to realize the vehicle suspension lowering function, the user needs to use the unlock key and the lock key to issue the combination key value 03.
[0037] In a possible implementation, the user presses the lock key first and then presses the unlock key.
[0038] In the prior art, when making an AND gate judgment, the two key port values used in the judgment need to be converted into binary numbers.
[0039] When the user presses the lock key, the newly added key port value is 01. When the MCU detects that the newly added key port value is 01, it converts it into a binary number of 01. (01&01) is not equal to 0, so S13 is executed. The key port value was 0 before, so S17 is executed to assign the port value to 01.
[0040] When the user presses the unlock key, the newly added key port value is 02. When the MCU detects that the newly added key port value is 02, it is converted to a binary number of 10, and (10&01) is equal to 0, so S18 is executed. In S18, 02 is converted to a binary number of 10, so (new port value & 02) is (10&10) = 1 in actual calculation, which is not equal to 0, so S19 is executed. Since the previous port value is 01, S20 is executed to assign the port value to 03, and then the MCU determines that the current port value is the composite key value, and then executes S24 to determine the current port value as the key value to be sent.
[0041] In another possible implementation, the user presses the unlock key first and then presses the lock key.
[0042] When the user presses the unlock key, the newly added key port value is 02. When the MCU detects that the newly added key port value is 02, it is converted to a binary number of 10, and (10&01) is equal to 0, so S18 is executed. (Newly added port value & 02) is (10&10) = 1, which is not equal to 0 in actual calculation, so S19 is executed. The previous key port value is 0, so S23 is executed to assign the port value to 02.
[0043] When the user presses the lock key, the newly added key port value is 01. When the MCU detects that the newly added key port value is 01, (01&01) is not equal to 0, so S13 is executed. Since the previous port value is 02, S14 is executed to assign the port value to 03, and then the MCU determines that the current port value is the combined key value, and then executes S24 to determine the current port value as the key value to be sent.
[0044] In the above manner, the user can use different key sequences to make the smart key generate the correct key value to be sent. However, in actual applications, if two keys are pressed almost at the same time, the time limit of the combined key function often occurs.
[0045] The inventor simulated the user pressing the lock key and the unlock key successively through the bench, and the time interval between pressing is T. The value range of T is 0-1000ms, and the value of T is gradually increased at intervals of 1ms. Through cyclic testing, it is found that when the time interval between the two keys is pressed is less than or equal to 3ms, the function of the combination key fails. Through research, it is found that the time of 3ms matches the minimum time interval from the key port being effective to waking up the MCU and starting to detect the key. In other words, the reason for the timeliness of the combination key function is: because the two keys are pressed almost at the same time, when the MCU is awakened for the first time to read the newly added port value, the newly added port value read is not 01 or 02, but the port value 03 of the combination key. 03 is converted to a binary number of 11. In S12, since (11&01) is equal to 01, not equal to 0, S13 is executed. Since this is the first awakening of the MCU, the previous port value is 00, so S17 is executed, and the port value is assigned to 01, resulting in the realization of the single key function and the inability to realize the combination key function.
[0046] The key values 04, 06, 08, 09, etc. in the above examples can realize other functions, and this application does not make specific limitations.
[0047] In summary, in the existing solution, the MCU can only process a single newly added port value at a time, and in steps S12, S18, etc., it first identifies which single key the newly added port value corresponds to, and then combines the previous port value to obtain the port value corresponding to the combination key. However, this method, when the newly added port value is the port value of the combination key, because the previous port value is 00, only the single key function can be realized.
[0048] In order to solve the above problems, the embodiments of the present application provide a combination control method and a smart key for a smart key, which can correctly send a correct combination key value when the user presses two buttons continuously at a short time interval, so that the function of the combination key can be triggered normally, thereby ensuring the user's usage experience and avoiding the user from misjudging the smart key failure because the function of the combination key is not triggered.
[0049] In order to enable persons skilled in the art to more clearly understand the solution of the present application, the technical solution in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application.
[0050] The terms "first", "second", etc. in this application description are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated.
[0051] In the present application, unless otherwise clearly specified and limited, the term "connection" should be understood in a broad sense. For example, "connection" can be a fixed connection, a detachable connection, or an integral connection; it can be a direct connection or an indirect connection through an intermediate medium.
[0052] An embodiment of the present application provides a combination control method for a smart key, which is described in detail below with reference to the accompanying drawings.
[0053] See also Figure 4 , which is a flow chart of a combination control method of a smart key provided in an embodiment of the present application.
[0054] The method comprises the following steps:
[0055] S31: Read the newly added button port value, which is generated when one or more buttons are pressed.
[0056] The solution of the embodiment of the present application can be implemented by a processor on the smart key, and the processor can be an MCU.
[0057] When the user presses one or more buttons, the corresponding button port values are generated.
[0058] When the user presses a button, the generated button port value is the button port value corresponding to the single key. For example, when the user presses the lock button, the generated button port value is 01. When the user presses the unlock button, the generated button port value is 02.
[0059] When the user presses multiple buttons, the generated button port value is the button port value corresponding to the combination button, that is, the button port value is the port value corresponding to multiple buttons. For example, after the user presses the lock key and the unlock key, the generated button port value is 03, and the function of the corresponding combination button is suspension lifting.
[0060] S32: When the newly added button port value is a port value corresponding to a single button, the button port value is updated according to the newly added button port value and the previous button port value.
[0061] The solution of the embodiment of the present application first identifies whether the newly added key port value read after the current MCU is awakened is a port value corresponding to a single key or a port value corresponding to multiple keys.
[0062] When it is identified that the newly added key port value is the port value corresponding to a single key, for example, when the key port value corresponding to the lock key is 01, the previous key port value is further determined.
[0063] The MCU can update the key port value according to the newly added key port value and the previous key port value.
[0064] For example, when the current key port value is the port value of a single key, and the key corresponding to the previous key port value and the newly added key port value has a combination key function, the key port value is updated to the key port value corresponding to the combination key to realize the function of the combination key.
[0065] For another example, when the current key port value is zero, that is, the MCU did not detect that the key was pressed last time, but this time the MCU detects that the newly added key port value is the port value corresponding to a single key, it indicates that the user did not press two keys at this time, but only pressed one key, and the user wants to trigger the function of a single key. At this time, the key port value is updated to the key port value corresponding to the single key.
[0066] In the present application scheme, by combining the newly added button port value with the previous port value, when the user presses different buttons in the combination button twice in succession and the MCU detects the corresponding port value changes twice, the button port value corresponding to the correct combination button can be determined based on the port values detected twice before and after, so that the function of the combination button can be triggered normally, ensuring the user experience.
[0067] S33: When the newly added button port value is a port value corresponding to multiple buttons, the button port value is updated according to the newly added button port value.
[0068] The method of the embodiment of the present application not only determines whether the newly added port value is the button port value corresponding to a single button, but also adds the judgment of the combined button port value, that is, determines whether the newly added button port value is the port value corresponding to a certain combined button.
[0069] For example, the smart key may support one or more combination key functions, such as vehicle suspension lifting, trailer hook control, etc. These combination key functions have corresponding key port values, for example, the key port value corresponding to the vehicle suspension lifting function is 03, and the key port value corresponding to the trailer hook control function is 0X. The embodiment of the present application does not specifically limit the value of X.
[0070] At this time, it is necessary to determine whether the newly added key port value is 03, and whether it is 0X. That is, when the newly added key port value is not the port value corresponding to a single key, it is necessary to determine whether the newly added key port is the same as the key port value corresponding to each combination key function, and then determine whether the newly added key port value is the port value corresponding to multiple keys.
[0071] When the newly added key port value is the port value corresponding to multiple keys, the key port value can be updated only according to the newly added key port value, and there is no need to combine it with the previous key port value. This is because when it is determined that the newly added port value is already the port value corresponding to multiple keys, it indicates that the user has pressed the combination key at the same time, that is, the MCU directly reads the port value of the combination key at one time. Regardless of whether the key value read by the MCU last time is zero or a single key value, it has no effect on the combination key function that the user wants to achieve this time.
[0072] Therefore, in the present application scheme, the key port value is updated directly according to the newly added key port value, and the updated key port value is kept unchanged, thereby obtaining the key port value corresponding to the correct combination key.
[0073] For example, when the newly added button port value is 03, the port value is still updated to 03, so that the updated port value is the same as the newly added button port value.
[0074] S34: When the updated button port value is the port value corresponding to the combination button, a vehicle control signal is generated using the port value corresponding to the combination button.
[0075] At this time, the smart key uses the port value corresponding to the combination key as the key value to be sent, generates a control signal and sends it to the vehicle. The control signal carries the key value to be sent. After the vehicle receives the control signal, it parses the control signal and obtains the key value, and then the vehicle controller controls the vehicle to implement the corresponding combination key function.
[0076] In summary, by using the technical solution provided by the embodiment of the present application, for the newly added key port value, it is not only necessary to judge whether it is the key port value corresponding to a single key, but also a judgment of the combined key port value is added, that is, it is added to determine whether the newly added key port value is the port value corresponding to multiple keys. When the time interval between the user pressing two keys is relatively long, causing the MCU to detect two key port value changes, the key port value corresponding to the combined key value can be obtained according to the combination of the second newly added key port value and the first key port value. When the user presses two keys almost at the same time, causing the newly added key port value to be the key port value corresponding to the combined key, the key port value can be updated according to the key port value of the newly added combined key, to ensure that the updated key port value corresponds to the combined key, so that the function of the combined key can be triggered normally, thereby ensuring the user's experience and avoiding the user from misjudging the smart key failure because the function of the combination key is not triggered.
[0077] The following is an explanation in conjunction with a specific implementation method.
[0078] See also Figure 5, which is a flow chart of another smart key combination control method provided in an embodiment of the present application.
[0079] In the following description of the embodiments of the present application, some functions of the smart key are as follows:
[0080] The unlock key is pressed to generate a port value of 01;
[0081] When the lock key is pressed, the port value is 02;
[0082] The key port value of the combination key corresponding to the first combination key function is 03, and the key port values corresponding to each single key in the combination key are 01 and 02 respectively;
[0083] The key port value of the combination key corresponding to the second combination key function is 09, and the key port values corresponding to each single key in the combination key are 01 and 08 respectively;
[0084] The key port value of the combination key corresponding to the third combination key function is 06, and the key port values corresponding to each single key in the combination key are 02 and 04 respectively.
[0085] The embodiment of the present application does not specifically limit the first combination button function, the second combination button function and the third combination button function. Those skilled in the art may configure them according to the actual vehicle conditions, for example, configuring the first combination button function as a vehicle suspension lifting function, configuring the second combination button function as a trailer hook control function, etc.
[0086] The key port values corresponding to the individual keys in the above combination keys are for illustrative purposes only and do not constitute a limitation on the technical solution of the present application. In actual applications, they can be configured to other values, which will not be described in detail here.
[0087] In the following embodiments, the first port value is 01, the second port value is 02, the third port value is 03, the key port value corresponding to the first combination key is the third port value, and when no key is pressed, the key port value is zero.
[0088] The method comprises the following steps:
[0089] S41: Read the newly added port value.
[0090] S42: Whether the newly added port value is 01.
[0091] If so, execute S43, otherwise execute S48.
[0092] Specifically, the code for making the judgment is implemented as "new port value == 01?". The judgment condition of the port value is replaced by "==" from the AND logic "&" in the prior art, avoiding the key port value corresponding to the combination key, and the key port value corresponding to the single key value is processed by the processing logic.
[0093] contrast Figure 5 and Figure 1 When the new port value is 03, 03 is converted to a binary number of 11. In S12, since (11&01) is equal to 01, the existing solution uses the processing logic "S13-S17" of the key port value of the single key value to process the key port value of the combined key value.
[0094] The solution of the present application modifies the judgment logic of the port value so that when the newly added port value is 03, the key port value of the combination key value will not be processed through the processing logic "S43-S47" of the key port value of the single key value. Therefore, the subsequent processing process of the combination key value will not be interrupted, avoiding the timeliness of the combination key function.
[0095] S43: Whether the previous port value is 02 or 03.
[0096] If so, execute S44; otherwise, execute S45.
[0097] That is, when the newly added key port value is the first port value 01, the previous key port value is determined.
[0098] When the previous key port value is the second port value 02, the key port value is updated to the third port value 03.
[0099] When the current key port value is the third port value, that is, when the previous key port value corresponds to the first combination key function, the solution of the present application will update the key port value to the third port value 03. This is because the solution of the present application takes into account that in actual applications, the user may trigger the combination key multiple times, for example, the user may trigger the locking key and the unlocking key multiple times to control the vehicle suspension to rise and fall multiple times. When the user triggers the combination key function multiple times, it is possible that only one key in the combination key is pressed due to misoperation, such as only pressing the locking key to cause the newly added port value to be 01. At this time, the solution of the present application can still update the key port value to the port value of the combination key to overcome the user's misoperation.
[0100] For example, the user triggers the combination key function multiple times, and the newly added port values corresponding to each triggering of the combination key function are: the first time (01, 02), the second time (02, 01), the third time (3), and the fourth time (01). It can be found that the user's fourth key operation missed an unlock key. At this time, the solution of this application is in S43. Since the previous port value is 03, S44 will still be executed to assign the port value to the correct 03.
[0101] S44: Assign the port value to 03.
[0102] By assigning a value to the port value, the port value is updated so that the port value is the port value corresponding to the combination key.
[0103] S45: Whether the previous port value is 08 or 09.
[0104] If so, execute S46; otherwise, execute S47.
[0105] At this time, the previous port value is not 08 or 09. In a possible implementation, the previous key port value is zero, that is, the MCU did not detect the port value because the user did not press the key last time. At this time, S47 is executed to assign the port value to the newly added port value 01. In another possible implementation, the previous key port value is the fourth port value, for example, 05, which is used to implement other single-key functions, and there is no combination key function between the keys corresponding to the fourth port value and the first port value, so the newly added port value and the fourth port value are respectively used to implement different single-key functions. At this time, S53 is executed to assign the port value to the newly added port value 02.
[0106] S46: Assign the port value to 09.
[0107] By assigning a value to the port value, the port value is updated so that the port value is the port value corresponding to the combination key.
[0108] S47: Assign the port value to 01.
[0109] S48: Whether the newly added port value is 02.
[0110] If so, execute S49; otherwise, execute S54.
[0111] The code for making the judgment is implemented as "Newly added port value == 02?"
[0112] When the newly added key port value is the second port value 02, the single key processing logic is executed.
[0113] S49: Whether the previous port value is 01 or 03.
[0114] If so, execute S50; otherwise, execute S51.
[0115] At this time, the previous key port value is determined, and when the previous key port value is the first port value 01, the key port value is updated to the third port value 03.
[0116] When the previous key port value is the third port value, that is, when the previous key port value corresponds to the first combination key function, the solution of the present application will update the key port value to the third port value 03.
[0117] S50: Assign the port value to 03.
[0118] S51: Whether the previous port value is 04 or 06.
[0119] If not, execute S53; if so, execute S52.
[0120] At this time, the previous port value is not 04 or 06. In a possible implementation, the previous key port value is zero, that is, the MCU did not detect the port value because the user did not press the key last time. At this time, S53 is executed, and the port value is assigned to the newly added port value 02. In another possible implementation, the previous key port value is the fourth port value, for example, 05, which is used to implement other single-key functions, and there is no combination key function between the keys corresponding to the fourth port value and the second port value, so the newly added port value and the fourth port value are respectively used to implement different single-key functions. At this time, S53 is executed, and the port value is assigned to the newly added port value 02.
[0121] S52: Assign the port value to 06.
[0122] S53: Assign the port value to 02.
[0123] S54: Is the newly added port value 03?
[0124] The code implementation when making the judgment is "newly added port value == 03?".
[0125] S55: Assign the port value to 03.
[0126] When the newly added key port value is the third port value 03, the key port value is updated to the third port value 03.
[0127] S56: Determine the current port value as the key value to be sent.
[0128] The smart key uses the port value corresponding to the combination key as the key value to be sent, generates a control signal and sends it to the vehicle. The control signal carries the key value to be sent. After the vehicle receives the control signal, it parses the control signal and obtains the key value, and then the vehicle controller controls the vehicle to implement the corresponding combination key function. The vehicle controller has the processing capability to identify the combination key function. For example, when implementing the first combination key function, the port value of the smart key may be 01+03, or 02+03, or 03. At this time, the vehicle controller can control the vehicle to implement the corresponding first combination key function when parsing the above port values.
[0129] Understandably, Figure 5 The division of the above steps is only for the convenience of explanation, and only for the key port values corresponding to some single keys and some combination keys of the smart key. In actual applications, the smart key may include more single keys and more combination keys. For example, if the key port value of the single key corresponding to the remote control back door opening key is 05, then at this time, between S42 and S48, or between S48 and S54, a judgment of "whether the newly added port value is 05" can be added. For another example, if the key port value of the single key corresponding to the back door opening key is 05, and it can form a combination key function with another single key, then a step similar to "S43-S47" or "S49-S53" can be further added to determine the port value corresponding to the combination key according to the two port values, and a step of determining the port value corresponding to the combination key according to the port values corresponding to multiple keys as shown in "S55" can be added.
[0130] The following examples illustrate the technical effects of the method of the present application.
[0131] When the time interval between the user pressing the unlock key and the lock key is less than or equal to 3ms, the newly added port value read in S41 is 03. At this time, by executing S54 and S55, the final key value to be sent is 03, and the smart key can correctly send the key port value corresponding to the combination key.
[0132] When the time interval between the user pressing the unlock key and the lock key is greater than 3ms, and the user presses the unlock key first and then the lock key, the newly added port value read by the MCU for the first time is 02, and the previous port value is 00. Therefore, after passing through S42, S48, S49, S51, and S53, the port value is assigned to 02. The newly added port value read by the MCU for the second time is 01, and the previous port value is 02. Therefore, after passing through S42, S43, and S44, the port value is assigned to 03, and the key port value corresponding to the combination key can be correctly issued.
[0133] When the time interval between the user pressing the unlock key and the lock key is greater than 3ms, and the lock key is pressed first and then the unlock key, the newly added port value read by the MCU for the first time is 01, and the previous port value is 00. Therefore, after passing through S42, S43, S45 and S47, the port value is assigned to 01. The newly added port value read by the MCU for the second time is 02, and the previous port value is 01. Therefore, after passing through S48, S49, S50, the port value is assigned to 03, and the key port value corresponding to the combination key can be correctly issued.
[0134] In summary, the solution provided by the embodiment of the present application changes the judgment condition of the port value from the AND logic "&" to "==", and adds the judgment of the combination key port value, which solves the problem that when the interval is less than 3ms, the subsequent judgment and processing process of the combination key value will be interrupted due to the use of AND logic during the software operation, resulting in functional failure. Even if the user presses two keys in succession at a short time interval, the key port value corresponding to the combination key can still be correctly issued, so that the function of the combination key can be triggered normally, ensuring the user's experience and avoiding the user's misjudgment of the smart key failure because the function of the combination key is not triggered.
[0135] Based on the combined control method of the smart key provided in the above embodiments, the embodiment of the present application further provides a smart key, which is described in detail below with reference to the accompanying drawings.
[0136] See also Figure 6 , which is a schematic diagram of a smart key provided in an embodiment of the present application.
[0137] The smart key 10 may include: an MCU 120 , a signal transmission module 130 , a battery 140 , a speaker 150 , an indicator 160 , a key module 170 , and the like.
[0138] The button module 170 at least includes an unlock button 11 , a lock button 12 , a remote control back door opening button 13 and a vehicle search button 14 .
[0139] It is understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the smart key 10. In other embodiments of the present application, the smart key 10 may include more or fewer components than shown in the figure, or combine some components, or separate some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
[0140] MCU120, also known as a processor, may include one or more processing units, such as a controller and a digital signal processor (DSP), etc. Different processing units may be independent devices or integrated into one or more processors.
[0141] MCU120 can be an application specific integrated circuit (ASIC), a programmable logic device (PLD), a digital signal processor (DSP) or a combination thereof. The above-mentioned PLD can be a complex programmable logic device (CPLD), a field programmable gate array (FPGA), a generic array logic (GAL) or any combination thereof, which is not specifically limited in the embodiments of the present application.
[0142] The battery 140 may be a removable battery or a non-removable battery, the battery 140 may be a rechargeable battery, or the battery 140 may support wireless charging.
[0143] The speaker 150 may also be called a "speaker" and is used to convert an audio electrical signal into a sound signal. The speaker 150 may indicate a key function or indicate corresponding information by emitting an indication sound.
[0144] The indicator 160 may be an indicator light, which may be used to indicate the power status, or may be used to indicate whether a key is valid, and whether the smart key sends a control signal.
[0145] The signal sending module 130 is used to send a control signal carrying a key value to the vehicle, where the key value is the port value corresponding to the combination key or the port value corresponding to a single key.
[0146] When one or more buttons are pressed, new button port values are generated.
[0147] MCU120 is used to read the newly added button port value; when the newly added button port value is the port value corresponding to a single button, the button port value is updated according to the newly added button port value and the previous button port value; when the newly added button port value is the port value corresponding to multiple buttons, the button port value is updated according to the newly added button port value; when the updated button port value is the port value corresponding to a combination button, the vehicle control signal is generated using the port value corresponding to the combination button.
[0148] In a possible implementation, the keys corresponding to the first port value and the second port value are the first combination keys, the key port value corresponding to the first combination key is the third port value, and the first combination key is used to implement the first combination key function. MCU120 is specifically used to: when the newly added key port value is the first port value, determine the previous key port value; when the current key port value is the second port value, update the key port value to the third port value; when the newly added key port value is the second port value, determine the previous key port value; when the current key port value is the first port value, update the key port value to the third port value.
[0149] In a possible implementation, the key port value corresponding to the first key combination is the third port value, and the first key combination is used to implement the first key combination function. MCU120 is specifically configured to update the key port value to the third port value when the newly added key port value is the third port value.
[0150] In a possible implementation, when no key is pressed, the key port value is zero. MCU120 is further configured to update the key port value to the first port value when the newly added key port value is the first port value and the previous key port value is zero; and to update the key port value to the second port value when the newly added key port value is the second port value and the previous key port value is zero.
[0151] In a possible implementation, MCU120 is also used to update the key port value to the first port value when the newly added key port value is the first port value and the previous key port value is the fourth port value, and there is no combination key function between the keys corresponding to the fourth port value and the first port value; when the newly added key port value is the second port value and the previous key port value is the fourth port value, the key port value is updated to the second port value.
[0152] In one possible implementation, MCU120 is also used to update the key port value to the third port value when the newly added key port value is the first port value and the previous key port value is the third port value; and to update the key port value to the third port value when the newly added key port value is the second port value and the previous key port value is the third port value.
[0153] In a possible implementation, the key port value corresponding to the first key combination is the third port value, and the first key combination is used to implement the first key combination function. MCU120 is also used to update the key port value to the third port value when the newly added key port value is the third port value.
[0154] By using the smart key provided by the embodiment of the present application, when the user presses two buttons successively with a long time interval so that the MCU can detect two changes in button port values, the MCU can obtain the button port value corresponding to the combination key value based on the combination of the button port value newly added for the second time and the button port value added for the first time. When the user presses two buttons almost at the same time so that the newly added button port value is the button port value corresponding to the combination key, the MCU can update the button port value based on the newly added button port value of the combination key to ensure that the updated button port value corresponds to the combination key, so that the function of the combination key can be triggered normally, thereby ensuring the user's experience and avoiding the user from misjudging the smart key failure because the function of the combination key is not triggered.
[0155] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0156] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. The device embodiments described above are merely schematic, wherein the units and modules described as separate components may or may not be physically separated. In addition, some or all of the units and modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art can understand and implement it without paying creative work.
[0157] The above is only a specific implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A combination control method of a smart key, characterized in that: The smart key includes a plurality of buttons, and the method includes: Reading a newly added key port value, wherein the key port value is generated when one or more keys are pressed; When the newly added button port value is a port value corresponding to a single button, updating the button port value according to the newly added button port value and the previous button port value; When the newly added button port value is a port value corresponding to a plurality of buttons, updating the button port value according to the newly added button port value; When the updated button port value is the port value corresponding to the combination button, the control signal of the vehicle is generated by using the port value corresponding to the combination button.
2. The method according to claim 1, characterized in that The keys corresponding to the first port value and the second port value are the first combination keys, the key port value corresponding to the first combination key is the third port value, the first combination key is used to implement the first combination key function, and when the newly added key port value is the port value corresponding to a single key, updating the key port value according to the newly added key port value and the previous key port value specifically includes: When the newly added key port value is the first port value, determining the previous key port value; When the previous key port value is the second port value, updating the key port value to the third port value; When the newly added key port value is the second port value, determining the previous key port value; When the previous key port value is the first port value, the key port value is updated to the third port value.
3. The method according to claim 2, characterized in that When no key is pressed, the key port value is zero, and the method further comprises: When the newly added key port value is the first port value and the previous key port value is zero, updating the key port value to the first port value; When the newly added key port value is the second port value and the previous key port value is zero, the key port value is updated to the second port value.
4. The method according to claim 2, characterized in that: The method further comprises: When the newly added key port value is the first port value, and the previous key port value is the fourth port value, the key port value is updated to the first port value, and there is no combination key function between the keys corresponding to the fourth port value and the first port value respectively; When the newly added key port value is the second port value, and the previous key port value is the fourth port value, the key port value is updated to the second port value.
5. The method according to claim 2, characterized in that: The method further comprises: When the newly added key port value is the first port value, and the previous key port value is the third port value, updating the key port value to the third port value; When the newly added key port value is the second port value, and the previous key port value is the third port value, the key port value is updated to the third port value.
6. The method according to claim 1, characterized in that The key port value corresponding to the first combination key is a third port value, the first combination key is used to implement a first combination key function, and when the newly added key port value is a port value corresponding to a plurality of the keys, updating the key port value according to the newly added key port value includes: When the newly added button port value is the third port value, the button port value is updated to the third port value.
7. The method according to claim 2 or 6, characterized in that: The first combination button includes an unlocking button and a locking button, and the function of the first combination button is to lower the vehicle suspension.
8. A smart key, characterized in that: The smart key includes a processor and at least two buttons; One or more of the buttons are used to generate a newly added button port value when pressed; The processor is used to read a newly added button port value; when the newly added button port value is a port value corresponding to a single button, the button port value is updated according to the newly added button port value and the previous button port value; when the newly added button port value is a port value corresponding to multiple buttons, the button port value is updated according to the newly added button port value; when the updated button port value is a port value corresponding to a combination button, a vehicle control signal is generated using the port value corresponding to the combination button.
9. The smart key according to claim 8, characterized in that: The keys corresponding to the first port value and the second port value are respectively a first combination key, the key port value corresponding to the first combination key is a third port value, the first combination key is used to implement a first combination key function, and the processor is specifically used to: When the newly added key port value is the first port value, determining the previous key port value; When the previous key port value is the second port value, updating the key port value to the third port value; When the newly added key port value is the second port value, determining the previous key port value; When the previous key port value is the first port value, the key port value is updated to the third port value.
10. The smart key according to claim 8, characterized in that: The button port value corresponding to the first combination button is a third port value, the first combination button is used to implement a first combination button function, and the processor is specifically used to update the button port value to the third port value when the newly added button port value is the third port value.
Citation Information
Patent Citations
Scan locating method for independent keyboard
CN103226391A
Operation method and device for remote control for set top box
CN104703013A
Key value self-defined keyboard configuration system and method
CN108089722A
Combined key recognition method, device and equipment and readable access medium
CN111984182A
Key function integration system and method
CN116743185A
