Unlocking control method and related device
By determining whether face recognition is successfully performed after the number of fingerprint recognition errors reaches the threshold in the electronic device, and deciding whether to disable the face unlocking function, the problem of low unlocking rate of electronic devices is solved and the user experience is improved.
Patent Information
- Application Number
- CN202410345602.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-10-27
- Publication Date
- 2025-05-06
AI Technical Summary
There may be a problem with low unlocking success rate in some electronic devices, especially when the number of consecutive fingerprint recognition errors reaches a certain threshold.
When the number of consecutive fingerprint recognition errors in the electronic device reaches the error threshold m, it is determined whether the electronic device has successfully recognized the face. If so, the face unlocking function will not be disabled, thereby increasing the unlocking success rate.
By not disabling the face unlocking function, users can still unlock electronic devices through face unlocking, which improves the unlocking success rate of electronic devices and improves the user experience.
Smart Images

Figure CN119939555A_ABST
Abstract
Description
[0001] This application is a divisional application. The application number of the original application is 202311402287.6, and the original application date is October 27, 2023. The entire contents of the original application are incorporated into this application by reference. Technical Field
[0002] The present application relates to the field of terminal technology, and in particular to an unlocking control method and related devices. Background Art
[0003] Some electronic devices have a lock screen function. When using the electronic device, you need to unlock it first. After successfully unlocking, you can use the electronic device normally. Among them, the authentication methods that can be used when unlocking the electronic device may include: password authentication, face authentication and / or fingerprint authentication, etc.
[0004] However, some electronic devices may have a low unlocking success rate. Summary of the invention
[0005] The embodiment of the present application provides an unlocking control method and related devices, which are applied to the field of terminal technology. When the number of consecutive fingerprint recognition errors of the electronic device reaches the error number threshold m for disabling fingerprints of the electronic device, it is determined whether the face recognition of the electronic device is successful. If so, the electronic device does not disable the face unlocking function. In this way, after the unlocked electronic device enters the lock screen state, the face unlocking function is still normal, and the user can still unlock the electronic device through the face unlocking function, so that the success rate of unlocking the electronic device is high, which can improve the user experience.
[0006] In the first aspect, the embodiment of the present application proposes an unlocking control method. The method includes: at a first time point, the fingerprint area of the electronic device is pressed by the m-1th wrong fingerprint, and the electronic device lights up. Wherein, the electronic device is in a locked screen state, and before the first time point, the electronic device has been pressed by the m-2th wrong fingerprint in the locked screen state, and the electronic device has not been unlocked between the m-2th wrong fingerprint and the m-1th wrong fingerprint. m is the threshold of the number of errors for the electronic device to disable fingerprints. At a second time point, the electronic device turns off the screen, and between the first time point and the second time point, the electronic device does not achieve unlocking. At a third time point, the electronic device realizes the screen lighting based on the mth wrong fingerprint pressing the fingerprint area, and the electronic device realizes unlocking through the face, and between the second time point and the third time point, the electronic device does not achieve unlocking. At a fourth time point, the electronic device turns off the screen, and between the third time point and the fourth time point, the electronic device is in a light screen and unlocked state. At a fifth time point, the electronic device lights up the screen and realizes unlocking based on the correct face, or the electronic device realizes unlocking based on the correct fingerprint, and between the fourth time point and the fifth time point, the electronic device does not achieve unlocking. Among them, in electronic devices, the security authentication level of face unlocking is lower than that of fingerprint unlocking.
[0007] For example, m may be 5. Figure 3 and Figure 4 , at the first point in time, the electronic device can display Figure 3 The interface shown in b in the figure, on which the fingerprint area of the electronic device is pressed by the fourth wrong fingerprint. At the second time point, the electronic device responds to the user pressing the power button 309, and the screen of the electronic device turns off. At the third time point, the electronic device turns on the screen based on the fifth wrong fingerprint pressing the fingerprint area, and the electronic device is unlocked by face recognition, and the electronic device displays Figure 3 At the fourth time point, in response to the user pressing the power button 309, the electronic device turns off the screen, and the electronic device can display Figure 4 At the fifth time point, the electronic device lights up and unlocks based on the correct face, or the electronic device unlocks based on the correct fingerprint, and the electronic device displays Figure 4 The interface shown in d.
[0008] In this way, if the electronic device fails to recognize fingerprints m times in a row, in response to the mth operation of pressing the fingerprint area, the electronic device lights up the screen and successfully recognizes the face, and the electronic device is unlocked without disabling the fingerprint unlocking function and the face unlocking function. After the electronic device enters the lock screen state again, the user can still unlock the electronic device by face unlocking, and the user can also unlock the electronic device by fingerprint unlocking, which can increase the success rate of unlocking the electronic device and reduce the probability of the electronic device being unlocked after successful face recognition and then entering the lock screen state from the unlock state with a low unlocking success rate.
[0009] In one possible implementation, between the third time point and the fourth time point, the method also includes: when the electronic device determines that the electronic device face recognition is successful and the fingerprint area obtains m consecutive erroneous fingerprints, the electronic device does not disable the face unlocking function and the fingerprint unlocking function.
[0010] It should be understood that the fingerprint area of the electronic device has a fingerprint collection device. The fingerprint area obtains m consecutive wrong fingerprints, which means that the number of consecutive fingerprint recognition errors of the electronic device reaches m. When the electronic device determines that the face recognition of the electronic device is successful, and the fingerprint area obtains m consecutive wrong fingerprints, the electronic device does not disable the face unlocking function and the fingerprint unlocking function. In this way, after the electronic device successfully enters the unlocked state through face recognition, and then enters the locked screen state from the unlocked state, the user can still unlock the electronic device by face unlocking, and the user can also unlock the electronic device by fingerprint unlocking, which can make the success rate of unlocking the electronic device high.
[0011] In a possible implementation, a first flag bit and a second flag bit are maintained in the electronic device, wherein, when the electronic device realizes unlocking based on face, the first flag bit is set to a first value, and when the fingerprint area obtains m consecutive wrong fingerprints, the second flag bit is set to a second value. When the electronic device determines that the electronic device face recognition is successful and the fingerprint area obtains m consecutive wrong fingerprints, the electronic device does not disable the face unlocking function and the fingerprint unlocking function, including: when the first flag bit is the first value and the second flag bit is the second value, the electronic device does not disable the face unlocking function and the fingerprint unlocking function.
[0012] In this way, by judging that the value of the first flag bit is the first value and the value of the second flag bit is the second value, it can be determined that the face recognition of the electronic device is successful, and if the number of consecutive fingerprint recognition errors of the electronic device reaches m, the electronic device does not disable the face unlocking function and the fingerprint unlocking function, so that after the electronic device enters the lock screen state from the unlocked state, the unlocking success rate of the electronic device is low.
[0013] In a possible implementation, when the first flag bit is the first value and the second flag bit is the second value, the electronic device further sets the second flag bit to a third value, where the third value is used to indicate that the fingerprint disabling condition is not met.
[0014] In this way, when the first flag bit is the first value and the second flag bit is the second value, the electronic device does not disable the face unlocking function and the fingerprint unlocking function, and the electronic device can set the second flag bit to the third value. In this way, the electronic device can, based on the third value, restart the accumulation of the number of consecutive fingerprint recognition errors when receiving information indicating a fingerprint recognition error again, so as to control whether the fingerprint unlocking function and the face unlocking function are disabled based on the number of consecutive fingerprint recognition errors after the electronic device is unlocked. It can also reduce the probability of the electronic device disabling the fingerprint unlocking function and the face unlocking function when the next face recognition error occurs but the number of consecutive fingerprint recognition errors does not reach m, thereby improving the user experience. It can also reduce the probability of the electronic device performing subsequent repeated updates of the values of the third flag bit and the fourth flag bit based on the second value of the second flag bit, thereby saving computing resources of the electronic device.
[0015] In a possible implementation, it also includes: at the sixth time point, the electronic device turns off the screen. Among them, the sixth time point is later than the fifth time point, and the face unlocking function and fingerprint unlocking function of the electronic device are not disabled. At the seventh time point, starting from the sixth time point, the fingerprint area of the electronic device is pressed by the m-1th wrong fingerprint, and the electronic device keeps the screen on and does not achieve unlocking. Between the sixth time point and the seventh time point, the electronic device is pressed by the m-2th wrong fingerprint in a row, and the electronic device is not unlocked. Starting from the sixth time point, when the fingerprint area of the electronic device is pressed by the m-2th wrong fingerprint, the electronic device turns on the screen and does not achieve unlocking. At the eighth time point, the electronic device turns off the screen, and between the seventh time point and the eighth time point, the electronic device is not unlocked. At the ninth time point, starting from the sixth time point, the electronic device turns on the screen based on the mth wrong fingerprint pressing the fingerprint area, and the electronic device is not unlocked by the face, and between the eighth time point and the ninth time point, the electronic device is not unlocked. At the tenth time point, the electronic device turns off the screen, and between the tenth time point and the tenth time point, the electronic device is in a state of turning on the screen and unlocking. At the eleventh time point, the screen of the electronic device turned on, but unlocking was not achieved based on the correct face or the correct fingerprint. Between the tenth time point and the eleventh time point, the electronic device was not unlocked.
[0016] For example, see Figure 5 and Figure 6 At the sixth time point, the electronic device turns off the screen, and the electronic device can display Figure 6At the seventh time point, the fingerprint area of the electronic device is pressed by the fourth wrong fingerprint from the sixth time point, the electronic device keeps the screen on and is not unlocked, and the electronic device can display Figure 6 The interface shown in c in the figure. Between the sixth time point and the seventh time point, the electronic device is pressed on the fingerprint area by three consecutive wrong fingerprints, and the electronic device is not unlocked. From the sixth time point onwards, when the fingerprint area of the electronic device is pressed by the third wrong fingerprint, the electronic device turns on the screen but is not unlocked. The electronic device can display Figure 6 At the eighth time point, the electronic device displays Figure 6 In the case of the interface shown in c in the figure, the electronic device turns off the screen, and the electronic device can display Figure 5 In the interface shown in a, between the seventh time point and the eighth time point, the electronic device is not unlocked. At the ninth time point, starting from the sixth time point, the electronic device lights up the screen based on the fifth incorrect fingerprint pressing the fingerprint area, and the electronic device is not unlocked by the face, the electronic device can display Figure 5 In the interfaces shown in b, c and d, between the eighth time point and the ninth time point, the electronic device is not unlocked. At the tenth time point, the screen of the electronic device is off. At the eleventh time point, the screen of the electronic device is on, and the unlocking is not achieved based on the correct face or the correct fingerprint.
[0017] In this way, if the number of consecutive fingerprint recognition errors reaches m, it means that the electronic device may be used by a user who has not obtained the permission of the user of the electronic device, or the user's operation of pressing the fingerprint area with the fingerprint is not standardized. When the number of consecutive fingerprint recognition errors reaches m and the face recognition of the electronic device is unsuccessful, the security management of the electronic device can be achieved by disabling the fingerprint unlocking function and the face unlocking function.
[0018] In one possible implementation, between the ninth time point and the tenth time point, the method also includes: when the electronic device determines that face recognition of the electronic device is unsuccessful and the fingerprint area obtains m consecutive erroneous fingerprints, the electronic device disables the face unlocking function and the fingerprint unlocking function.
[0019] In this way, by disabling the fingerprint unlocking function and the face unlocking function, the security management of the electronic device can be achieved.
[0020] In a possible implementation, a first flag bit and a second flag bit are maintained in the electronic device, wherein, when the electronic device fails to unlock based on the face, the first flag bit is set to a fourth value, and when the fingerprint area obtains m consecutive wrong fingerprints, the second flag bit is set to a second value. When the electronic device determines that the electronic device face recognition is unsuccessful and the fingerprint area obtains m consecutive wrong fingerprints, the electronic device disables the face unlocking function and the fingerprint unlocking function, including: when the first flag bit is the fourth value and the second flag bit is the second value, the electronic device disables the face unlocking function and the fingerprint unlocking function.
[0021] In this way, by judging that the value of the first flag bit is the fourth value and the value of the second flag bit is the second value, it can be determined that the face recognition of the electronic device is unsuccessful, and if the number of consecutive fingerprint recognition errors of the electronic device reaches m, the electronic device disables the face unlocking function and the fingerprint unlocking function to achieve security management of the electronic device.
[0022] In a possible implementation, it also includes: at the twelfth time point, the electronic device turns off the screen. The twelfth time point is later than the fifth time point, and the face unlocking function and the fingerprint unlocking function of the electronic device are not disabled. At the thirteenth time point, the fingerprint area of the electronic device is pressed by the mth wrong fingerprint from the twelfth time point, and the electronic device keeps the screen on and does not achieve unlocking. Between the twelfth time point and the thirteenth time point, the fingerprint area of the electronic device is pressed by the m-1th wrong fingerprint continuously, and the electronic device is not unlocked. When the fingerprint area of the electronic device is pressed by the m-2th wrong fingerprint from the twelfth time point, the electronic device turns on the screen and does not achieve unlocking. At the fourteenth time point, the electronic device turns off the screen, and between the thirteenth time point and the fourteenth time point, the electronic device keeps the screen on and does not achieve unlocking. At the fifteenth time point, the electronic device turns on the screen and does not achieve unlocking based on the correct face, or the electronic device does not achieve unlocking based on the correct fingerprint, and between the fourteenth time point and the fifteenth time point, the electronic device keeps the screen off and does not achieve unlocking.
[0023] For example, see Figure 6 At the twelfth time point, the electronic device turns off the screen, and the electronic device can display Figure 6 At the thirteenth time point, the fingerprint area of the electronic device is pressed by the fifth wrong fingerprint starting from the twelfth time point, the electronic device keeps the screen on and is not unlocked, and the electronic device can display Figure 6 The interface shown in d in the figure. Between the twelfth time point and the thirteenth time point, the electronic device is pressed on the fingerprint area by four consecutive incorrect fingerprints, and the electronic device is not unlocked. Starting from the twelfth time point, when the fingerprint area of the electronic device is pressed by the third incorrect fingerprint, the electronic device turns on the screen but is not unlocked. The electronic device can display Figure 6At the fourteenth time point, the electronic device displays Figure 6 In the case of the interface shown in d in the figure, the electronic device turns off the screen, and between the thirteenth time point and the fourteenth time point, the electronic device keeps the screen on and does not achieve unlocking. Because the electronic device responds to the operation of pressing the fingerprint area with the wrong fingerprint for the fifth time, the electronic device makes a fingerprint recognition error for the fifth time, and the electronic device determines that face recognition is not performed or face recognition is unsuccessful, and the electronic device disables the fingerprint unlocking function and the face unlocking function. When the duration from the twelfth time point to the fifteenth time point is less than the timing duration, the fingerprint unlocking function and the face unlocking function have been disabled, so at the fifteenth time point, the electronic device turns on the screen and cannot achieve unlocking based on the correct face, and the electronic device cannot achieve unlocking based on the correct fingerprint. It should be understood that when the fingerprint area of the electronic device is pressed by the wrong fingerprint for the third time from the twelfth time point, the electronic device turns on the screen and does not achieve unlocking, indicating that face recognition is unsuccessful or the electronic device does not capture the face and does not perform face recognition.
[0024] In this way, if the number of consecutive fingerprint recognition errors reaches m, it means that the electronic device may be used by a user who has not obtained the permission of the user of the electronic device, or the user's operation of pressing the fingerprint area with the fingerprint is not standardized. In order to achieve safe management of the electronic device, when the number of consecutive fingerprint recognition errors reaches m and the face recognition of the electronic device is unsuccessful (or face recognition is not performed), the fingerprint unlocking function and the face unlocking function are disabled, so that safe management of the electronic device can be achieved.
[0025] In one possible implementation, between the thirteenth time point and the fourteenth time point, the method also includes: when the electronic device determines that face recognition is not started and the fingerprint area obtains m consecutive erroneous fingerprints, the electronic device disables the face unlocking function and the fingerprint unlocking function.
[0026] The electronic device not starting face recognition may include the electronic device not capturing a face and not performing face recognition. In this way, when the electronic device determines that the electronic device does not start face recognition and the fingerprint area obtains m consecutive wrong fingerprints, the face unlocking function and the fingerprint unlocking function are disabled, thereby achieving security management of the electronic device.
[0027] In a possible implementation, a first flag bit and a second flag bit are maintained in the electronic device, wherein the first flag bit is set to a fourth value when the electronic device does not start face recognition based on the electronic device, and the second flag bit is set to a second value when the fingerprint area obtains m consecutive wrong fingerprints. When the electronic device determines that the electronic device does not start face recognition and the fingerprint area obtains m consecutive wrong fingerprints, the electronic device disables the face unlocking function and the fingerprint unlocking function, including: when the first flag bit is the fourth value and the second flag bit is the second value, the electronic device disables the face unlocking function and the fingerprint unlocking function.
[0028] In this way, by judging that the value of the first flag bit is the fourth value and the value of the second flag bit is the second value, it can be determined that the electronic device has not successfully recognized the face, and if the number of consecutive fingerprint recognition errors of the electronic device reaches m, the electronic device disables the face unlocking function and the fingerprint unlocking function to achieve security management of the electronic device.
[0029] In a possible implementation, the method further includes: at the sixteenth time point, the screen of the electronic device is turned off. Wherein, the face unlocking function and the fingerprint unlocking function of the electronic device are both disabled, and the sixteenth time point is later than the fifteenth time point. At the seventeenth time point, the screen of the electronic device is turned on, and unlocking is not achieved based on the correct face or the correct fingerprint, and between the sixteenth time point and the seventeenth time point, the electronic device is not unlocked. At the eighteenth time point, the electronic device receives the correct password, and the electronic device is unlocked. Between the seventeenth time point and the eighteenth time point, the electronic device keeps the screen on and does not unlock. At the nineteenth time point, the screen of the electronic device is turned off, and between the eighteenth time point and the nineteenth time point, the electronic device keeps the screen on and unlocked. At the twentieth time point, the screen of the electronic device is turned on, and unlocking is not achieved based on the correct face or the correct fingerprint, and between the nineteenth time point and the twentieth time point, the electronic device is not unlocked.
[0030] For example, see Figure 5 and Figure 7 At the 16th time point, the electronic device screen turns off, and the electronic device can display Figure 5 The interface shown in a of FIG. Among them, the face unlocking function and fingerprint unlocking function of the electronic device are both disabled, and the sixteenth time point is later than the fifteenth time point. At the seventeenth time point, the electronic device can display Figure 5 In the case of the interface shown in a in FIG. 1 , the user can press the power button 309 to light up the screen of the electronic device, and if the unlocking is not achieved based on the correct face, the electronic device can display Figure 5 In the interface shown in b, between the 18th time point and the 17th time point, the electronic device is not unlocked. Figure 5In the case of the interface shown in e, at the eighteenth time point, the electronic device receives the correct password, the electronic device is unlocked, and the electronic device can display Figure 7 In the interface shown in b, between the seventeenth time point and the eighteenth time point, the electronic device may display Figure 5 The interface shown in d in FIG. 1 can be displayed on an electronic device Figure 5 In the case of the interface shown in d in FIG. 1 , the user can slide up the display screen, and the electronic device can display Figure 5 The interface shown in e.
[0031] In this way, since the security authentication level of the fingerprint unlocking function is lower than that of the password unlocking function, when the fingerprint unlocking function and the face unlocking function are disabled in the electronic device, the password unlocking function is in a normal state, and the user can use the password authentication method to unlock the electronic device, thereby achieving security management of the electronic device and improving the flexibility of the user in performing unlocking operations to unlock the electronic device, thereby improving the user experience.
[0032] In a possible implementation, a third flag bit and a fourth flag bit are maintained in the electronic device. When the face unlocking function is disabled in the electronic device, the third flag bit is set to a fifth value, and when the fingerprint unlocking function is disabled in the electronic device, the fourth flag bit is set to a sixth value.
[0033] In this way, by maintaining the third flag bit as the fifth value and maintaining the fourth flag bit as the sixth value, the fingerprint unlocking function and the face unlocking function can be disabled at the same time.
[0034] In a second aspect, an embodiment of the present application provides an electronic device, which includes: a processor and a memory; the memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory, so that the electronic device performs the method of the first aspect.
[0035] In a third aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program. When the computer program is executed by a processor, the method of the first aspect is implemented.
[0036] In a fourth aspect, an embodiment of the present application provides a computer program product, which includes a computer program. When the computer program is executed, the computer executes the method of the first aspect.
[0037] In a fifth aspect, an embodiment of the present application provides a chip, the chip including a processor, the processor being used to call a computer program in a memory to execute the method described in the first aspect.
[0038] It should be understood that the second to fifth aspects of the present application correspond to the technical solutions of the first aspect of the present application, and the beneficial effects achieved by each aspect and the corresponding feasible implementation methods are similar and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] Figure 1 A schematic diagram of the structure of an electronic device 100 provided in an embodiment of the present application;
[0040] Figure 2 A software structure block diagram of the electronic device 100 according to an embodiment of the present application;
[0041] Figure 3 A scene diagram for unlocking an electronic device provided in an embodiment of the present application;
[0042] Figure 4 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application;
[0043] Figure 5 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application;
[0044] Figure 6 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application;
[0045] Figure 7 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application;
[0046] Figure 8 A flowchart of the unlocking control method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0047] In order to clearly describe the technical solutions of the embodiments of the present application, some terms and technologies involved in the embodiments of the present application are briefly introduced below:
[0048] 1. Electronic equipment
[0049] The electronic device of the embodiment of the present application may include a handheld device, a vehicle-mounted device, etc. with an image processing function. For example, some electronic devices are: mobile phones, tablet computers, PDAs, laptop computers, mobile internet devices (MIDs), wearable devices, virtual reality (VR) devices, augmented reality (AR) devices, wireless terminals in industrial control, wireless terminals in self driving, wireless terminals in remote medical surgery, wireless terminals in smart grids, wireless terminals in transportation safety, wireless terminals in smart cities, wireless terminals in smart homes, cellular phones, cordless phones, session initiation protocol (SIP) phones, wireless local loop (WLL) stations, personal digital assistants (PDAs), handheld devices with wireless communication capabilities, computing devices or other processing devices connected to wireless modems, vehicle-mounted devices (such as vehicle computers), wearable devices, terminal devices in 5G networks or future evolved public land mobile communication networks (public land mobile The embodiments of the present application do not limit this.
[0050] In an embodiment of the present application, the electronic device or each network device includes a hardware layer, an operating system layer running on the hardware layer, and an application layer running on the operating system layer. The hardware layer includes hardware such as a central processing unit (CPU), a memory management unit (MMU), and a memory (also called main memory). The operating system can be any one or more computer operating systems that implement business processing through processes, such as Linux operating systems, Unix operating systems, Android operating systems, iOS operating systems, or Windows operating systems. The application layer includes applications such as cameras, browsers, address books, word processing software, and instant messaging software.
[0051] 2. Lock screen status
[0052] The lock screen state can be understood as the state in which the display screen of the electronic device is locked. For example, when the display screen is in a locked state, the display screen can be black and not display, or the display screen can display an always on display (AOD) interface or a bright lock screen interface.
[0053] Among them, the display screen showing the screen-off interface can be understood as a part of the display screen area showing information such as time and power. The display screen showing the screen-on lock screen interface can be understood as the display screen is lit up, the screen can display content but it is not unlocked, and the functions of the electronic device when unlocked cannot be realized.
[0054] When the display screen displays the screen-off interface, it can be referred to as the electronic device screen-off. When the display screen displays the screen-on lock screen interface, it can be referred to as the electronic device screen-on. When the electronic device screen is off or the display screen is black, it can be referred to as the electronic device screen is off.
[0055] 3. Unlocked status
[0056] The unlocked state can be understood as the state in which the display screen of the electronic device is unlocked. For example, when the display screen is in the unlocked state, the display screen can display the interface of the application program and receive user triggers to implement various functions of the electronic device.
[0057] 4. Other terms
[0058] In the embodiments of the present application, the words "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
[0059] In the embodiments of the present application, "at least one" refers to one or more, and "plurality" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects 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 represent: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple.
[0060] In the embodiment of the present application, "at..." may be the instant when a certain situation occurs, or may be a period of time after a certain situation occurs, and the embodiment of the present application does not specifically limit this. In addition, the display interface provided in the embodiment of the present application is only an example, and the display interface may also include more or less content.
[0061] Figure 1 A schematic structural diagram of an electronic device 100 is shown.
[0062] The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.
[0063] It is to be understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 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.
[0064] The software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. In the embodiment of the present invention, the Android system of the layered architecture is taken as an example to exemplify the software structure of the electronic device 100.
[0065] Figure 2 It is a software structure block diagram of the electronic device 100 according to an embodiment of the present application.
[0066] The layered architecture divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the Android runtime and system library, and the kernel layer.
[0067] The application layer can include a series of application packages.
[0068] like Figure 2 As shown, the application package may include camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, lock screen and other applications.
[0069] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer includes some predefined functions.
[0070] like Figure 2 As shown, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, and the like.
[0071] The Android runtime includes the core library and the virtual machine. The Android runtime is responsible for the scheduling and management of the Android system.
[0072] The core library consists of two parts: one part is the function that needs to be called by the Java language, and the other part is the Android core library.
[0073] The application layer and the application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.
[0074] The system library may include multiple functional modules, such as surface manager, media library, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), etc.
[0075] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.
[0076] Some electronic devices have password unlocking function, fingerprint unlocking function and 2D face unlocking function. In terms of the reliability of identity authentication, the reliability of password unlocking is higher than that of fingerprint unlocking, and the reliability of fingerprint unlocking is higher than that of 2D face unlocking. Therefore, for the electronic device provided in the embodiment of the present application, the security authentication level of password unlocking is level 1, the security authentication level of fingerprint unlocking is level 2, and the security authentication level of 2D face unlocking is level 3, where level 1 is higher than level 2, and level 2 is higher than level 3.
[0077] When the number of consecutive fingerprint recognition errors of the electronic device reaches the error number threshold m for the electronic device to disable fingerprints, the electronic device can disable the fingerprint unlocking function. For the sake of electronic device security management, when the electronic device disables the fingerprint unlocking function, the electronic device can disable the 2D face unlocking function. Since the security authentication level of password unlocking is higher than that of fingerprint unlocking, the password unlocking function is not disabled when the electronic device disables the fingerprint unlocking function.
[0078] In the embodiment of the present application, the identity authentication involved in fingerprint unlocking can be referred to as fingerprint authentication or fingerprint recognition, and the 2D face unlocking function can be referred to as face unlocking function in the future. The identity authentication involved in 2D face unlocking can be referred to as face authentication or face recognition.
[0079] When the user presses the fingerprint area of the electronic device with a fingerprint, the electronic device can obtain the fingerprint collected in the fingerprint area. The electronic device can use the obtained fingerprint to match the preset fingerprint to complete fingerprint recognition. If the obtained fingerprint matches the preset fingerprint successfully, it means that the fingerprint recognition is correct, and if the obtained fingerprint does not match the preset fingerprint successfully, it means that the fingerprint recognition is wrong. If the fingerprint recognition is successful, the electronic device is unlocked. If the fingerprint recognition is wrong, the electronic device remains in the locked screen state.
[0080] When the screen of an electronic device is black or off, turning on the screen of the electronic device will trigger face recognition, and the camera of the electronic device can capture a face image. The electronic device can use the face image captured by the camera to match the preset image to complete face recognition. If the captured face image matches the preset image successfully, it means that the face recognition is successful, and if the captured face image does not match the preset image successfully, it means that the face recognition is unsuccessful (or the face recognition is wrong). If the face recognition is successful, the electronic device is unlocked. If the face recognition is wrong, the electronic device remains in the locked screen state.
[0081] It should be understood that the methods of realizing lighting up the screen of an electronic device may include: triggering the screen to light up by a posture change of the electronic device, triggering the screen to light up by the user pressing the power button of the electronic device, or triggering the screen to light up by the user pressing the fingerprint area of the electronic device with a fingerprint.
[0082] If the electronic device has made fingerprint recognition errors for m-1 consecutive times and the screen is off, the user may press the fingerprint area with the wrong fingerprint once more. When the electronic device receives the user's m-th operation of pressing the fingerprint area with a fingerprint, the electronic device turns on the screen, which triggers face recognition. When the electronic device performs face recognition and the face recognition is successful, the electronic device is unlocked. After the electronic device enters the locked screen state from the unlocked state, the electronic device may fail to unlock based on the correct face image.
[0083] In a possible implementation, when the number of consecutive fingerprint recognition errors of the electronic device reaches m times, the electronic device disables the fingerprint unlocking function. Since the security authentication level of the face unlocking function is lower than the security authentication level of the fingerprint unlocking function, when the fingerprint unlocking function is disabled, the face unlocking function is also disabled. Since the action of the electronic device to perform face unlocking is faster than the action of the electronic device to disable the fingerprint unlocking function based on the mth fingerprint recognition error, when the electronic device receives the user's mth operation of pressing the fingerprint area with a fingerprint, the electronic device first realizes unlocking based on the correct face image, and then disables the fingerprint unlocking function based on the mth fingerprint recognition error. As a result, after the electronic device is unlocked through face recognition and then enters the lock screen state from the unlocked state, the fingerprint unlocking function and the face unlocking function of the electronic device are both disabled, and the electronic device cannot be unlocked based on the correct face image, which causes the electronic device to have a low unlocking success rate and a poor user experience.
[0084] In view of this, an embodiment of the present application provides an unlocking control method, which determines whether the electronic device has successfully recognized the face when the number of consecutive fingerprint recognition errors of the electronic device reaches m times. If so, the electronic device does not disable the face unlocking function. In this way, after the unlocked electronic device enters the lock screen state, since the face unlocking function is still normal, the user can still unlock the electronic device through the face unlocking function, so that the success rate of unlocking the electronic device is high, which can improve the user experience.
[0085] An unlocking control method provided by an embodiment of the present application is described below in conjunction with some embodiments.
[0086] Combination Figure 2 The software architecture shown is used to explain the unlocking control method provided in the embodiment of the present application as follows.
[0087] The electronic device may maintain a first flag bit, a second flag bit, a third flag bit, and a fourth flag bit. The electronic device may maintain the first flag bit as the fourth value when the face recognition is wrong or the face recognition is not started, and may maintain the first flag bit as the first value when the face recognition is successful. The electronic device may maintain the second flag bit as the third value when the number of consecutive fingerprint recognition errors does not reach m, and may maintain the second flag bit as the second value when the number of consecutive fingerprint recognition errors reaches m. The electronic device may maintain the third flag bit as the fifth value when the face unlocking function is disabled, and may maintain the third flag bit as the seventh value when the face unlocking function is not disabled. The electronic device may maintain the fourth flag bit as the sixth value when the fingerprint unlocking function is disabled, and may maintain the fourth flag bit as the eighth value when the fingerprint unlocking function is not disabled.
[0088] Exemplarily, when the electronic device performs face recognition, the application framework layer can obtain the face image captured by the camera through the camera driver. The application framework layer can use the obtained face image to match the preset image to complete face recognition. Each time the application framework layer completes face recognition, the application framework layer can transmit information indicating successful face recognition or information indicating face recognition error to the lock screen application in the application layer. The lock screen application can maintain the first flag bit as the fourth value when receiving information indicating a face recognition error or not receiving face recognition information, and can maintain the first flag bit as the first value when receiving information indicating successful face recognition.
[0089] When the user presses the fingerprint area with a fingerprint, in response to the operation of pressing the fingerprint area, the application framework layer can obtain the fingerprint collected in the fingerprint area. The application framework layer can use the obtained fingerprint to match the preset fingerprint to complete fingerprint recognition. Each time the application framework layer completes fingerprint recognition, the application framework layer can transmit information indicating successful fingerprint recognition or information indicating fingerprint recognition error to the lock screen application. The lock screen application can accumulate the number of consecutive receipts of information indicating fingerprint recognition errors, and when the accumulated number of times does not reach m, the second flag bit can be maintained as the third value, and when the accumulated number of times reaches m, the second flag bit can be maintained as the second value.
[0090] The lock screen application can maintain the third flag bit as the fifth value when the face unlock function is disabled, and can maintain the third flag bit as the seventh value when the face unlock function is not disabled.
[0091] The lock screen application can maintain the fourth flag bit as the sixth value when the fingerprint unlocking function is disabled, and can maintain the fourth flag bit as the eighth value when the fingerprint unlocking function is not disabled.
[0092] In some implementations, the following scenario may exist.
[0093] Scenario 1: After the user presses the fingerprint area with the wrong fingerprint for m-1 consecutive times, the screen of the electronic device goes black or turns off. When the user presses the fingerprint area with the wrong fingerprint for the mth time, the screen of the electronic device turns on, triggering face recognition, and face recognition is successful.
[0094] Second scenario: After the user presses the fingerprint area with the wrong fingerprint for m-1 consecutive times, the electronic device screen goes black or turns off. When the user presses the fingerprint area with the wrong fingerprint for the mth time, the electronic device screen turns on, triggering face recognition, and the face recognition is incorrect.
[0095] Scenario 3: After the user presses the fingerprint area with an incorrect fingerprint for m-1 consecutive times, the screen of the electronic device remains on. When the user presses the fingerprint area with an incorrect fingerprint for the mth time, the electronic device does not perform face recognition.
[0096] Scenario 4: The user presses the fingerprint area with the wrong fingerprint for n consecutive times. n is the fingerprint recognition error threshold for permanently disabling the fingerprint unlocking function and face unlocking function of the electronic device.
[0097] For the first scenario, in response to the user's operation of pressing the fingerprint area with an incorrect fingerprint for the mth time, the electronic device lights up the screen, which triggers face recognition and the face recognition is successful. The application framework layer transmits information indicating successful face recognition to the lock screen application. The lock screen application can control the display screen to display the system application desktop or the application interface of the application that was interrupted by the last black screen or screen off of the electronic device, and maintain the first flag bit as the first value. The application framework layer also transmits information indicating a fingerprint recognition error to the lock screen application. The lock screen application determines that the cumulative number of times reaches m, and the lock screen application maintains the second flag bit as the second value. It should be understood that the display screen displays the system application desktop or application interface, indicating that the electronic device is in an unlocked state. Among them, the system application desktop can be found in the subsequent Figure 3 The interface shown in f.
[0098] When the lock screen application maintains the second flag as the second value, the lock screen application can read the value of the first flag and the value of the second flag. When the lock screen application reads the first value and the second value, the lock screen application can maintain the third flag as the seventh value and maintain the fourth flag as the eighth value. When the third flag is the seventh value and the fourth flag is the eighth value, the fingerprint unlocking function and the face unlocking function of the electronic device are not disabled, and the electronic device can unlock the electronic device based on the correct fingerprint or the correct face. In this way, the success rate of unlocking the electronic device can be high, and the probability of the electronic device being unlocked based on the correct face and then entering the lock screen state, failing to unlock based on the correct face and having a low success rate of unlocking can be reduced.
[0099] Optionally, when the lock screen application reads the first value and the second value, the lock screen application can also maintain the second flag as a third value. In this way, the lock screen application can, based on the third value, restart the accumulation of the number of consecutive received information indicating fingerprint recognition errors when receiving information indicating a fingerprint recognition error again, so as to control whether the fingerprint unlocking function and the face unlocking function are disabled based on the number of consecutive fingerprint recognition errors after the electronic device is unlocked. It can also reduce the probability of the electronic device disabling the fingerprint unlocking function and the face unlocking function when the next face recognition error occurs but the number of consecutive fingerprint recognition errors does not reach m, thereby improving the user experience. It can also reduce the probability of the electronic device repeatedly updating the values of the third flag and the fourth flag based on the second value of the second flag, thereby saving computing resources of the electronic device.
[0100] For the second scenario, in response to the user's operation of pressing the fingerprint area with an incorrect fingerprint for the mth time, the electronic device turns on the screen, which triggers face recognition and the face recognition is wrong. The application framework layer transmits information indicating the face recognition error to the lock screen application, and the lock screen application can control the display screen to display the lock screen interface and maintain the first flag bit as the fourth value. The application framework layer also transmits information indicating the fingerprint recognition error to the lock screen application, and the lock screen application determines that the cumulative number of times reaches m, and the lock screen application maintains the second flag bit as the second value.
[0101] When the lock screen application maintains the second flag bit as the second value, the lock screen application can read the value of the first flag bit and the value of the second flag bit. When the lock screen application reads the fourth value and the second value, the lock screen application can maintain the third flag bit as the fifth value and maintain the fourth flag bit as the sixth value.
[0102] In this way, if the number of consecutive fingerprint recognition errors reaches m, it means that the electronic device may be used by a user who has not obtained the permission of the user of the electronic device, or the user's operation of pressing the fingerprint area with the fingerprint is not standardized. In order to achieve safe management of the electronic device, when the number of consecutive fingerprint recognition errors reaches m and the face recognition of the electronic device is unsuccessful, the fingerprint unlocking function and the face unlocking function are disabled by maintaining the third flag bit as the fifth value and maintaining the fourth flag bit as the sixth value, so as to achieve safe management of the electronic device.
[0103] Optionally, the lock screen application can start the timer while maintaining the third flag bit as the fifth value and maintaining the fourth flag bit as the sixth value. The timing duration indicates the duration for which the lock screen application disables the fingerprint unlocking function and the face unlocking function. The timing duration of the timer can be 30 seconds. When the timer reaches the timing duration, the lock screen application can maintain the third flag bit as the seventh value and maintain the fourth flag bit as the eighth value. The lock screen application can also maintain the first flag bit as the fourth value and the second flag bit as the third value.
[0104] In this way, when the user does not press the fingerprint area properly with the fingerprint, the fingerprint unlocking function and the face unlocking function can be temporarily disabled to achieve the security management of the electronic device. After the timer reaches the timer length, the disablement is released to restore the flexibility of the electronic device unlocking method, which can improve the user experience.
[0105] From the moment the lock screen application starts the timer to the timer reaching the timing duration, if the lock screen application receives information indicating successful fingerprint recognition or information indicating successful face recognition transmitted by the application framework layer, the lock screen application can control the electronic device to remain in the locked screen state.
[0106] Since the third flag bit is the fifth value and the fourth flag bit is the sixth value from the time when the lock screen application starts the timer to the timer reaching the timing duration, the fingerprint unlocking function and the face unlocking function of the electronic device are both disabled, and the electronic device cannot be unlocked based on the correct fingerprint, and the electronic device cannot be unlocked based on the correct face.
[0107] Optionally, from the moment the lock screen application starts the timer to the timer reaching the timing duration, if the application framework layer obtains the password input by the user, the application framework layer uses the obtained password to match the preset password to complete the password authentication. If the obtained password successfully matches the preset password, the application framework layer can transmit information indicating that the password authentication is successful to the lock screen application. Based on the information indicating that the password authentication is successful, the lock screen application can control the display screen to display the system application desktop or application interface, so that the electronic device is in an unlocked state, realizing the flexibility of unlocking the electronic device, and can improve the user experience.
[0108] For the third scenario, in response to the user's operation of pressing the fingerprint area with an incorrect fingerprint for the mth time, the electronic device keeps the screen on and performs fingerprint recognition. The electronic device performs fingerprint recognition error for the mth time. The application framework layer transmits information indicating fingerprint recognition error to the lock screen application. The lock screen application determines that the cumulative number of times reaches m, and the lock screen application maintains the second flag bit as the second value. When the lock screen application maintains the second flag bit as the second value, if the lock screen application reads the fourth value and the second value, the lock screen application can maintain the third flag bit as the fifth value and the fourth flag bit as the sixth value, and start the timer.
[0109] In this way, if the number of consecutive fingerprint recognition errors reaches m, it means that the electronic device may be used by a user who has not obtained the permission of the user of the electronic device, or the user's operation of pressing the fingerprint area with the fingerprint is not standardized. In order to achieve safe management of the electronic device, when the number of consecutive fingerprint recognition errors reaches m and the face recognition of the electronic device is unsuccessful (or face recognition is not performed), the fingerprint unlocking function and the face unlocking function are disabled by maintaining the third flag bit as the fifth value and maintaining the fourth flag bit as the sixth value, so that safe management of the electronic device can be achieved.
[0110] For the fourth scenario, in response to the user's operation of pressing the fingerprint area with an incorrect fingerprint for the nth time, the electronic device performs the nth fingerprint recognition, and the nth fingerprint recognition is incorrect. The application framework layer transmits information indicating a fingerprint recognition error to the lock screen application. The lock screen application determines that the cumulative number of times reaches n, and the lock screen application maintains the second flag bit as the second value. When the lock screen application maintains the second flag bit as the second value, the value of the first flag bit and the value of the second flag bit can be read. When the fourth value and the second value are read, the lock screen application can maintain the third flag bit as the fifth value and the fourth flag bit as the sixth value, and does not start the timer to achieve permanent disabling of the fingerprint unlocking function and the face unlocking function. n>m. n can be 20.
[0111] In this way, if the number of consecutive fingerprint recognition errors reaches n, it means that the electronic device may be used by a user who has not obtained the permission of the user of the electronic device. In order to achieve safe management of the electronic device, when the number of consecutive fingerprint recognition errors reaches n, the fingerprint unlocking function and the face unlocking function are permanently disabled. This can reduce the probability of a user who has not obtained the permission of the user of the electronic device using the functions of the electronic device, so as to achieve safe management of the electronic device.
[0112] Optionally, if the number of times the lock screen application continuously receives information indicating face recognition errors reaches k, the lock screen application can maintain the third flag bit as the fifth value and not start the timer, so as to permanently disable the face unlocking function, thereby achieving security management of the electronic device. k can be 5. Since the security authentication level of the face unlocking function is lower than that of the fingerprint unlocking function, when the number of face recognition errors of the face unlocking function reaches k, only the face unlocking function is disabled, but the fingerprint unlocking function is not disabled, which can reduce the probability of reduced flexibility of the unlocking method of the electronic device.
[0113] Exemplarily, the specific implementation of the electronic device maintaining the value of the second flag bit and maintaining the value of the third flag bit may be shown in the following pseudo code:
[0114]
[0115] Among them, public static void set fingerprint disabled face {If (main user && 2D face) {set mark}} can indicate that the lock screen application maintains the value of the second flag bit based on the judgment result of whether the cumulative number of times reaches m, or it can indicate that the lock screen application maintains the value of the second flag bit based on the judgment result of whether the cumulative number of times reaches n. public static boolean get fingerprint disabled face status {return fingerprint disabled face mark;} can indicate that the lock screen application reads the value of the second flag bit. Current face status! = authentication success can indicate that face authentication is unsuccessful (or face recognition error). Setting the face status to disabled can indicate that the state representing the face unlocking function is set to disabled, for example, setting the value of the third flag bit to the fifth value. public void update face status {if (current face status! = authentication success && fingerprint disabled face status is true) {set face status to disabled;} can indicate that if the lock screen application determines whether the value of the first flag bit and the value of the second flag bit read meet the following conditions: face recognition is successful and the number of fingerprint errors reaches m, then the lock screen application sets the value of the third flag bit to the fifth value.
[0116] The unlocking control method in each of the various scenarios is described above. The following takes m=5 as an example and describes the relevant scenarios in combination with some embodiments.
[0117] For the first scenario, Figure 3 A scenario diagram for unlocking an electronic device provided in an embodiment of the present application is shown.
[0118] When the electronic device's screen is on and in the locked state, the electronic device may display the following Figure 3 The lock screen interface shown in a. Figure 3 The interface shown in a in FIG. 1 includes an identifier 301 indicating a fingerprint area, a camera control 302, a time “16:43”, an identifier 303 indicating a lock screen state, and a status bar.
[0119] exist Figure 3 In the interface shown in a of FIG. 1 , the user can press the fingerprint area with the fingerprint, for example, the user presses the mark 301 with the fingerprint. In the case where the user presses the fingerprint area with the wrong fingerprint three times in a row, the electronic device receives the wrong fingerprint three times in a row and the fingerprint recognition error occurs three times in a row, and the electronic device can display Figure 3 The interface shown in b in the figure. Figure 3 The interface shown in b in the figure includes a logo 301, a numeric keyboard 304, a logo 305 indicating the password input status, a prompt message "Unrecognized, click here to try again" and a status bar.
[0120] exist Figure 3In the interface shown in b in FIG. 1 , the user can press the fingerprint area with the fingerprint. When the user presses the fingerprint area with the wrong fingerprint again, the fingerprint area of the electronic device receives the wrong fingerprint again and the fingerprint recognition error occurs again, and the electronic device can display Figure 3 The interface shown in c in FIG. 1 is used to prompt the user to use the password unlocking function to unlock the electronic device. Figure 3 The contents of the interface shown in c can be found in Figure 3 The contents of the interface shown in b will not be repeated here.
[0121] like Figure 3 As shown in b, the electronic device also includes a power button 309, and the user can press the power button 309 to turn off the screen of the electronic device or make the screen black. Figure 3 In the case of the interface shown in c in FIG. 1 , the user presses the power button 309, and the electronic device can display Figure 3 The screen off interface shown in d in the figure. Figure 3 The screen-off interface shown in d in FIG. 1 includes a logo 301, a logo 306 indicating the system, a logo 307 indicating the power level, a time "16:43" and a date "July 8, Saturday, XX year, month 21".
[0122] exist Figure 3 On the screen-off interface shown in d in FIG. 1 , the user can press the fingerprint area with a fingerprint. When the user presses the fingerprint area with an incorrect fingerprint again, the electronic device turns on the screen and performs face recognition. For example, Figure 3 As shown in d in FIG. 1 , the electronic device further includes a front camera 300. When the electronic device turns on the screen and performs face recognition, the front camera 300 can capture the face, and the electronic device can obtain a face image. The electronic device matches the obtained face image with a preset image to complete face recognition.
[0123] If face recognition is successful, the electronic device is unlocked and can display Figure 3 The interface shown in e. Figure 3 The interface shown in e in FIG. 1 includes a logo 301, a camera control 302, a time “16:43”, a prompt message “Face recognition successful”, a logo 308 indicating an unlocked state, and a status bar.
[0124] If the face recognition is wrong, the electronic device can disable the fingerprint unlocking function. In order to achieve the security management of electronic devices, when the electronic device disables the fingerprint unlocking function, the electronic device can also disable the face unlocking function. For scenarios where the electronic device disables the fingerprint unlocking function and the face unlocking function due to face recognition errors, please refer to the following Figure 5 The embodiment shown.
[0125] Display on electronic devices Figure 3In the case of the interface shown in e in the figure, the interface displayed by the electronic device will automatically jump, and the electronic device can display the following Figure 3 The interface shown in f in FIG. 1 indicates that the electronic device is in an unlocked state. Figure 3 The interface shown in f in FIG. 1 includes a phone application icon 310, a camera application icon 311, a text message application icon 312, a WeChat application icon 313, a note application icon 314, a Toutiao application icon 315, a setting application icon 316, a calendar application icon 317, a Youdao Dictionary application icon 318 and a status bar.
[0126] In this embodiment, the electronic device has five consecutive fingerprint recognition errors. In response to the fifth operation of pressing the fingerprint area, the electronic device lights up the screen and successfully recognizes the face. The electronic device is unlocked without disabling the fingerprint unlocking function and the face unlocking function. After the electronic device enters the lock screen state again, the user can still unlock the electronic device by face unlocking, and the user can also unlock the electronic device by fingerprint unlocking. For details, please refer to the subsequent Figure 4 In this way, the probability of low unlocking success rate after the electronic device is unlocked after successful face recognition and then entering the lock screen state from the unlocked state can be reduced, so that the unlocking success rate of the electronic device is high and the user experience is improved.
[0127] Figure 4 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application is shown.
[0128] When the electronic device is unlocked, the electronic device may display Figure 4 The interface shown in a.
[0129] Figure 4 The interface shown in a in the figure can be an electronic device in Figure 3 In the scene shown, press Figure 3 The interface displayed after unlocking using the unlocking method shown in the embodiment. Figure 4 The contents of the interface shown in a can be found in Figure 3 The contents of the interface shown in f will not be repeated here.
[0130] Display on electronic devices Figure 4 In the case of the interface shown in a, the user can press the power button 309, and the electronic device can display Figure 4 The interface shown in b. Figure 4 The contents of the interface shown in b can be found in Figure 3 The contents of the interface shown in d will not be repeated here.
[0131] Display on electronic devices Figure 4In the case of the interface shown in b in FIG. 1 , the user can press the power button 309, the electronic device lights up the screen and starts the face recognition function. If the face recognition is successful, the electronic device is unlocked and the electronic device can display Figure 4 The interface shown in c. Figure 4 The contents of the interface shown in c can be found in Figure 3 The contents of the interface shown in e in the figure are not described here. Figure 4 In the case of the interface shown in c in the figure, the interface displayed by the electronic device will automatically jump, and the electronic device can display the following Figure 4 The interface shown in d. Figure 4 The contents of the interface shown in d can be found in Figure 3 The contents of the interface shown in f will not be repeated here.
[0132] Optionally, the electronic device displays Figure 4 In the interface shown in b, the user can press the fingerprint area with the fingerprint to unlock the electronic device, and the electronic device can display Figure 4 The interface shown in d.
[0133] from Figure 3 and Figure 4 It can be seen that when the screen goes off after the electronic device is unlocked, the fingerprint unlocking function and face unlocking function of the electronic device are both normal.
[0134] For the second scenario, Figure 5 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application is shown.
[0135] If the electronic device fails to recognize fingerprints four times in a row and the screen of the electronic device is turned off, the electronic device can display Figure 5 The interface shown in a. Figure 5 The contents of the interface shown in a can be found in Figure 3 The contents of the interface shown in d will not be repeated here.
[0136] exist Figure 5 In the interface shown in a, if the user presses the fingerprint area with the wrong fingerprint again, the electronic device lights up and performs face recognition. If the face recognition is wrong, the electronic device is still in the locked screen state, and the electronic device can display Figure 5 The interface shown in b in the figure. Figure 5 The interface shown in b in FIG. 1 includes a logo 301, a camera control 302, a time “16:43”, a prompt message “face recognition error”, a logo 303 and a status bar.
[0137] Display on electronic devices Figure 5 After the prompt message "Face recognition error" on the interface shown in b disappears, the electronic device may display the following Figure 5The prompt message on the interface shown in c in the figure is "Fingerprint is disabled, please try again after 30 seconds". Figure 5 After the prompt message "Fingerprint disabled, please try again after 30 seconds" on the interface shown in c disappears, the electronic device can display Figure 5 The prompt message on the interface shown in d in Figure 1 is “Swipe up to unlock”. Figure 5 The difference between the interfaces shown in b, c and d is that the prompt information is different.
[0138] exist Figure 5 On the interface shown in d, the user can slide up, and the electronic device can display Figure 5 The password interface shown in e. Figure 5 The interface shown in e is the same as Figure 3 The difference between the interface shown in b is that Figure 5 The interface shown in e includes the prompt message "Face and fingerprint are disabled, please enter the password to unlock", but does not include the prompt message "Recognition was not successful, click here to try again".
[0139] In this embodiment, the electronic device has five consecutive fingerprint recognition errors. In response to the fifth operation of pressing the fingerprint area, the electronic device lights up the screen and makes a face recognition error. Since the number of consecutive fingerprint recognition errors of the electronic device reaches five, the electronic device remains in a locked screen state and disables the fingerprint unlocking function and the face unlocking function. The electronic device can display Figure 5 The interface shown in c, d or e can reduce the probability of abnormal use of the functions of the electronic device when identity authentication is unsuccessful, so as to achieve safe management of the electronic device.
[0140] Figure 6 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application is shown.
[0141] When the fingerprint unlocking function and face unlocking function of the electronic device are not disabled and the screen of the electronic device is turned off, the electronic device can display Figure 6 The interface shown in a. Figure 6 The contents of the interface shown in a can be found in Figure 4 The contents of the interface shown in b will not be repeated here.
[0142] exist Figure 6 If the user presses the fingerprint area with the wrong fingerprint for three consecutive times, the electronic device will light up and display Figure 6 The interface shown in b. Figure 6 The contents of the interface shown in b can be found in Figure 5 The contents of the interface shown in d will not be repeated here.
[0143] Display on electronic devices Figure 6 In the case of the interface shown in b in the figure, the interface displayed by the electronic device can automatically jump, and the electronic device can display Figure 6 The interface shown in c. Figure 6 The contents of the interface shown in c can be found in Figure 3 The contents of the interface shown in b will not be repeated here.
[0144] exist Figure 6 In the interface shown in c in Figure 1, if the user presses the fingerprint area with the wrong fingerprint twice in a row, the electronic device disables the fingerprint unlocking function and the face unlocking function, and the electronic device can display Figure 6 The interface shown in d. Figure 6 The contents of the interface shown in d can be found in Figure 5 The contents of the interface shown in e will not be repeated here.
[0145] In this embodiment, the electronic device has five consecutive fingerprint recognition errors, and from the first to the fifth fingerprint recognition errors in the five consecutive times, the electronic device did not perform face recognition or the electronic device did not obtain the face image captured by the front camera. When the fifth fingerprint recognition error occurs, since the number of fingerprint recognition errors reaches five, the electronic device disables the fingerprint unlocking function and the face unlocking function, and the electronic device can display Figure 6 The interface shown in d.
[0146] When the fingerprint unlocking function and face unlocking function of the electronic device are disabled, the password unlocking function of the electronic device is not disabled. Therefore, the user can unlock the electronic device by means of password authentication. For details, please refer to Figure 7 .
[0147] Figure 7 Another scenario diagram for unlocking an electronic device provided in an embodiment of the present application is shown.
[0148] When the fingerprint unlocking function and face unlocking function are disabled in the electronic device, the electronic device may display Figure 7 The interface shown in a. Figure 7 The contents of the interface shown in a can be found in Figure 6 The contents of the interface shown in d will not be repeated here.
[0149] exist Figure 7 In the interface shown in a of FIG. 1 , the user can touch the numeric keypad 304 to enter the unlock password. In response to the user inputting the unlock password, the electronic device can obtain the password input by the user, and the electronic device uses the obtained password to match the preset password. If the match is successful, the electronic device is unlocked. The electronic device can display Figure 7 The interface shown in b. Figure 7 The contents of the interface shown in b can be found in Figure 3 The contents of the interface shown in f will not be repeated here.
[0150] Since the security authentication level of the fingerprint unlocking function is lower than that of the password unlocking function, when the fingerprint unlocking function and the face unlocking function are disabled in the electronic device, the password unlocking function is in a normal state and the user can use the password authentication method to unlock the electronic device, thereby achieving security management of the electronic device and improving the flexibility of the user in performing unlocking operations to unlock the electronic device and improving the user experience.
[0151] Figure 8 The flowchart of the unlocking control method provided by the embodiment of the present application is shown in FIG. Figure 8 , the unlocking control method provided in the embodiment of the present application is described.
[0152] like Figure 8 As shown, the method includes:
[0153] S801. In response to a user pressing a fingerprint area with a fingerprint, the electronic device obtains the pressed fingerprint.
[0154] The pressed fingerprint is a fingerprint collected by the fingerprint area of the electronic device when the user presses the fingerprint area with his fingerprint.
[0155] After the electronic device obtains the pressed fingerprint, it can perform fingerprint recognition as shown in S802 or S811.
[0156] S802: When the electronic device has a black screen or is off (on no match black), the electronic device matches the pressed fingerprint with a preset fingerprint to complete fingerprint recognition.
[0157] If the fingerprint recognition is successful, the electronic device executes step S803. It should be understood that a successful fingerprint recognition indicates a successful identity authentication. A fingerprint recognition error indicates an unsuccessful identity authentication.
[0158] If the fingerprint recognition is incorrect, the electronic device will remain black or the screen will be turned off.
[0159] If the electronic device obtains the pressed fingerprint three times in a row and the fingerprint recognition is wrong three times in a row, the electronic device executes step S804.
[0160] S803: The electronic device matches the pressed fingerprint with the preset fingerprint to complete fingerprint recognition. If the fingerprint recognition is successful, the electronic device is unlocked to enter the system application desktop. The electronic device is unlocked to enter the system application desktop, for example, the electronic device displays Figure 3 The interface shown in f.
[0161] S804. The screen of the electronic device turns on.
[0162] When the screen of the electronic device is on, if the electronic device obtains the pressed fingerprint twice in succession and the fingerprint recognition is wrong twice in succession, the electronic device executes step S805.
[0163] S805. In response to the fifth operation of pressing the fingerprint area, the electronic device determines that the number of fingerprint recognition errors reaches 5 times and no face recognition is performed. The electronic device can execute S806.
[0164] S806: The electronic device sets the second flag bit to a second value.
[0165] For example, the electronic device sets the second flag bit to true to implement setting a fingerprint forbidden face in the electronic device.
[0166] S807: When the second flag is set to the second value, the electronic device reads the value of the first flag and the value of the second flag. When the fourth value and the second value are read, the electronic device sets the third flag to the fifth value and the fourth flag to the sixth value, and starts the timer, and the timing duration is 30 seconds. The fifth value and the sixth value may also be true.
[0167] In this way, the fingerprint unlocking function and the face unlocking function can be disabled simultaneously.
[0168] S808: When the timer reaches the timing duration, the electronic device sets the third flag bit to the seventh value and the fourth flag bit to the eighth value, and may also set the second flag bit to the third value.
[0169] Optionally, when the timer reaches the timing duration, the electronic device can clear the fifth value and the sixth value, and can also set the second flag bit to the third value or clear the second value, so as to release the disabling of the fingerprint unlocking function and the face unlocking function, and restore the fingerprint unlocking function and the face unlocking function to a normal state. For example, an m state cleaner is provided in the electronic device.
[0170] S809. If the electronic device determines that the number of fingerprint recognition errors reaches 20 times, the electronic device permanently disables the fingerprint unlocking function and the face unlocking function.
[0171] When the fingerprint unlocking function and the face unlocking function are disabled on the electronic device, the user can only unlock the electronic device by entering a password. If the electronic device receives the correct password, the electronic device can execute step S810.
[0172] S810. Unlock the electronic device and enter the system application desktop.
[0173] S811. When the screen of the electronic device is on (on no match white), the electronic device matches the pressed fingerprint with the preset fingerprint to complete fingerprint recognition.
[0174] If the fingerprint recognition is successful, the electronic device executes step S803.
[0175] If the fingerprint recognition is incorrect, the screen of the electronic device remains on.
[0176] If the electronic device obtains the pressed fingerprint three times in a row and the fingerprint recognition is wrong three times in a row, the electronic device executes step S812.
[0177] S812. The electronic device displays a password interface.
[0178] Password interface example Figure 3 The interface shown in b.
[0179] When the electronic device displays the password interface, in response to the user pressing the fingerprint area once again with the wrong fingerprint, the electronic device makes another fingerprint recognition error. When the electronic device makes four consecutive fingerprint recognition errors, the user may press the power button. The electronic device may execute S813.
[0180] S813. The screen of the electronic device is turned off.
[0181] Optionally, if the electronic device fails to recognize fingerprints four times in a row, the screen may be automatically turned off without receiving any user operation.
[0182] When the screen of the electronic device is off, the user may continue to press the fingerprint area with the wrong fingerprint, and the electronic device may execute S814.
[0183] S814. In response to the user pressing the fingerprint area with the wrong fingerprint for the fifth time, the electronic device turns on the screen and performs face recognition.
[0184] If the face recognition is successful, the electronic device may execute S815.
[0185] After the face recognition is completed, in response to the user pressing the fingerprint area with the wrong fingerprint for the fifth time, the electronic device also determines that the number of consecutive fingerprint recognition errors reaches m, maintains the second flag as the second value, and the electronic device can execute S816, the second value is true, for example.
[0186] S815. Unlock the electronic device and enter the system application desktop.
[0187] S816: When the electronic device determines that face recognition is successful and the number of fingerprint recognition errors reaches m, the electronic device does not disable the fingerprint unlocking function and the face unlocking function.
[0188] For example, the electronic device determines that the face status is not sucuss and the second flag is true, and the electronic device does not disable the fingerprint unlocking function and the face unlocking function.
[0189] S817: When the electronic device does not disable the fingerprint unlocking function and the face unlocking function, the electronic device may enter the locked screen state from the unlocked state. When the electronic device is in the locked screen state, the electronic device may execute S818.
[0190] S818: The electronic device may obtain the fingerprint in response to the user pressing the fingerprint area with the fingerprint. The electronic device may also obtain the face image captured by the camera when performing face recognition.
[0191] Based on the correct fingerprint or the correct face, the electronic device may execute S810.
[0192] In this embodiment, if the electronic device has five consecutive fingerprint recognition errors, and the electronic device has not performed face recognition or the electronic device has not obtained the face image captured by the camera during the period from the first fingerprint recognition error to the fifth fingerprint recognition error of the five consecutive times, the electronic device can disable the fingerprint unlocking function and the face unlocking function based on the judgment result that the number of consecutive fingerprint recognition errors has reached five times, and the disabling time is 30 seconds. The electronic device can also permanently disable the fingerprint unlocking function and the face unlocking function based on the judgment result that the number of consecutive fingerprint recognition errors has reached 20 times. In this way, the security management of electronic devices can be achieved.
[0193] If the electronic device fails to recognize fingerprints five times in a row, and in response to the fifth operation of pressing the fingerprint area among the five consecutive times, the electronic device lights up the screen and successfully recognizes the face, the electronic device can be unlocked without disabling the fingerprint unlocking function and the face unlocking function, and when the electronic device enters the lock screen state again, the user can unlock the electronic device through face recognition, and the user can also unlock the electronic device through fingerprint authentication. In this way, the probability of the electronic device being unlocked after successful face recognition and then having a low unlocking success rate after entering the lock screen state from the unlocked state can be reduced, thereby increasing the unlocking success rate of the electronic device.
[0194] The unlocking control method of the embodiment of the present application has been described above, and the device for executing the above-mentioned list sorting method provided by the embodiment of the present application is described below. Those skilled in the art can understand that the method and the device can be combined and referenced with each other, and the relevant device provided by the embodiment of the present application can execute the steps in the above-mentioned method.
[0195] The unlocking control method provided in the embodiment of the present application can be applied to electronic devices with communication functions. The electronic devices include terminal devices, and the specific device form of the terminal devices can refer to the above related descriptions, which will not be repeated here.
[0196] An embodiment of the present application provides an electronic device, which includes: a processor and a memory; the memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory, so that the electronic device executes the above method.
[0197] The embodiment of the present application provides a chip. The chip includes a processor, and the processor is used to call a computer program in a memory to execute the technical solution in the above embodiment. Its implementation principle and technical effect are similar to those of the above related embodiments, and will not be repeated here.
[0198] The embodiments of the present application also provide a computer-readable storage medium. The computer-readable storage medium stores a computer program. The above method is implemented when the computer program is executed by the processor. The method described in the above embodiment can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. If implemented in software, the function can be stored as one or more instructions or codes on a computer-readable medium or transmitted on a computer-readable medium. Computer-readable media can include computer storage media and communication media, and can also include any medium that can transfer a computer program from one place to another. The storage medium can be any target medium that can be accessed by a computer.
[0199] In one possible implementation, a computer-readable medium may include RAM, ROM, compact disc read-only memory (CD-ROM) or other optical disk storage, disk storage or other magnetic storage devices, or any other medium that is intended to carry or store the required program code in the form of instructions or data structures and can be accessed by a computer. Moreover, any connection is appropriately referred to as a computer-readable medium. For example, if a coaxial cable, fiber optic cable, twisted pair, digital subscriber line (DSL) or wireless technology (such as infrared, radio and microwave) is used to transmit software from a website, server or other remote source, the coaxial cable, fiber optic cable, twisted pair, DSL or wireless technology such as infrared, radio and microwave are included in the definition of medium. Disks and optical disks as used herein include optical disks, laser disks, optical disks, digital versatile disks (DVD), floppy disks and Blu-ray disks, where disks usually reproduce data magnetically, while optical disks reproduce data optically using lasers. Combinations of the above should also be included in the scope of computer-readable media.
[0200] An embodiment of the present application provides a computer program product, which includes a computer program. When the computer program is executed, the computer executes the above method.
[0201] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable device to generate a machine, so that the instructions executed by the processing unit of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0202] The above specific implementation methods further illustrate the purpose, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above are only specific implementation methods of the present invention and are not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made on the basis of the technical solutions of the present invention should be included in the scope of protection of the present invention.
Claims
1. An unlocking control method, characterized in that: include: The electronic device displays a first interface; In the first time period, after the electronic device fails to be unlocked by fingerprint h times, the electronic device turns on the screen and displays the second interface, where h is an integer greater than 0; In the first time period, after the mth fingerprint unlocking is triggered on the second interface using an incorrect fingerprint, in response to the face unlocking being successful, the electronic device displays a third interface; wherein the mth fingerprint unlocking fails, m is an integer greater than h, and the third interface is the display interface after unlocking; After the first time period, in response to a screen lock operation, the electronic device displays the first interface; in response to successful fingerprint unlocking, the electronic device displays the third interface; After the first time period, the electronic device displays the first interface; In a second time period, after the electronic device fails to unlock with fingerprint m times, the electronic device displays a message that fingerprint is disabled; the duration of the second time period is the same as the duration of the first time period; After the second time period, after fingerprint unlocking or face unlocking is triggered, the electronic device displays information that the fingerprint is disabled.
2. The method according to claim 1, characterized in that The electronic device maintains a first flag bit and a second flag bit; wherein the electronic device sets the first flag bit to a first value based on successful face unlocking; and the electronic device sets the second flag bit to a second value based on m fingerprint unlocking failures; After the response to the face unlocking being successful, the method further includes: When the first flag bit is the first value and the second flag bit is the second value, the electronic device does not disable the face unlocking function and the fingerprint unlocking function.
3. The method according to claim 2, characterized in that When the first flag bit is the first value and the second flag bit is the second value, the electronic device further sets the second flag bit to a third value, where the third value is used to indicate that the fingerprint disabling condition is not met.
4. The method according to claim 1, characterized in that In the second time period, after the electronic device fails to unlock with fingerprint m times, the method further includes: If the electronic device fails to unlock the face and fails to unlock the fingerprint m times, the electronic device disables the face unlock function and the fingerprint unlock function; or The electronic device disables the face unlocking function and the fingerprint unlocking function based on the face unlocking not being started and the fingerprint unlocking failing m times.
5. The method according to claim 4, characterized in that The electronic device maintains a first flag bit and a second flag bit; wherein the electronic device sets the first flag bit to a fourth value based on a face unlock failure or a face unlock failure; and the electronic device sets the second flag bit to a second value based on m fingerprint unlock failures; The electronic device disables the face unlocking function and the fingerprint unlocking function, including: When the first flag bit is the fourth value and the second flag bit is the second value, the electronic device disables the face unlocking function and the fingerprint unlocking function.
6. The method according to any one of claims 1 to 5, characterized in that Also includes: Starting from displaying the information that fingerprint is disabled, within a preset time period, after triggering fingerprint unlocking, the electronic device displays the information that fingerprint is disabled.
7. The method according to any one of claims 1 to 6, characterized in that Also includes: Starting from displaying the information that fingerprint is disabled, after a preset time period, fingerprint unlocking is triggered based on the correct fingerprint, and the electronic device displays the third interface.
8. The method according to any one of claims 1 to 7, characterized in that The electronic device maintains a third flag bit and a fourth flag bit; wherein, when the electronic device displays information that fingerprints are disabled, the third flag bit is a fifth value, and the fourth flag bit is a sixth value.
9. The method according to any one of claims 1 to 8, characterized in that The first interface is the AOD interface.
10. An electronic device, characterized in that: include: Processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the electronic device performs the method according to any one of claims 1 to 9.
11. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 9 is implemented.