False touch prevention method and device, folding equipment and computer program product
By combining proximity sensors, ambient light sensors, and pose sensors, the system accurately determines whether the folding device is in pocket mode, solving the problem of insufficient accuracy in preventing accidental touches in existing technologies and achieving a precise anti-accidental touch effect.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHENGDU OPPO TELECOMM TECH CORP LTD
- Filing Date
- 2024-11-19
- Publication Date
- 2026-05-19
AI Technical Summary
Existing technologies have difficulty accurately identifying whether a foldable device is in pocket mode, resulting in insufficient accuracy in preventing accidental touches and potentially leading to misjudgments or failure to execute the anti-accidental touch operation in a timely manner.
By combining proximity detection sensors, ambient light sensors, and pose sensors, the system determines whether the folding device is in pocket mode by acquiring proximity detection results, ambient light data, and pose data, and then performs an anti-accidental touch operation after confirming that the device is in pocket mode.
It improves the accuracy of detecting when a foldable device is in pocket mode, achieves precise anti-accidental touch effect, and reduces the occurrence of mis-control and functional abnormalities.
Smart Images

Figure CN122064239A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of terminal equipment technology, and in particular to a method and device for preventing accidental touches, a folding device, and a computer program product. Background Technology
[0002] With the development of science and technology, and the innovation of electronic device forms and functions, electronic devices have become more diverse and feature-rich. For example, touchscreen electronic devices currently account for a very high percentage of the market and are increasingly favored by users.
[0003] When using touchscreen electronic devices, the device can perform anti-accidental touch operations in pocket mode. Therefore, how to accurately identify when an electronic device is in pocket mode and thus accurately prevent accidental touches has become a pressing problem to be solved. Summary of the Invention
[0004] This application provides a method and device for preventing accidental touches, a folding device, and a computer program product, which can more accurately identify whether the folding device is in pocket mode, effectively improving the accuracy of preventing accidental touches on the folding device.
[0005] Firstly, a method for preventing accidental touches is provided, applied to a folding device. The folding device includes a proximity detection sensor, an ambient light sensor, and a pose sensor. The method includes: determining a folding state of the folding device, which includes an unfolded state or a closed state; acquiring a proximity detection result determined by the proximity detection sensor, acquiring ambient light data collected by the ambient light sensor, and acquiring pose data collected by the pose sensor; if the folding state is a target folding state, determining whether the folding device is in pocket mode based on at least two of the proximity detection result, ambient light data, and pose data; and if the folding device is in pocket mode, performing an anti-accidental touch operation in pocket mode.
[0006] In this application, the folding state of a folding device can be determined, including an unfolded state or a closed state. When the folding state is the target folding state, it is determined whether the folding device is in pocket mode based on at least two of the following: proximity detection results, ambient light data, and pose data. If the folding device is in pocket mode, an anti-mistouch operation in pocket mode is performed. The proximity detection results are determined by a proximity detection sensor, the ambient light data is collected by an ambient light sensor, and the pose data is collected by a pose sensor. This allows the folding device to more accurately determine whether it is in pocket mode by combining the proximity detection results from the proximity sensor, the ambient light data from the ambient light sensor, and the pose data collected by the pose sensor, thus improving the accuracy of pocket mode determination and enabling timely and precise anti-mistouch operation of the folding device.
[0007] Secondly, an anti-accidental touch device is provided, applied to a folding device. The folding device includes a proximity detection sensor, an ambient light sensor, and a pose sensor. The anti-accidental touch device includes a processing module and an acquisition module. The processing module is used to determine the corresponding folding state of the folding device, which includes an unfolded state or a closed state. The acquisition module is used to acquire the proximity detection result determined by the proximity detection sensor, acquire ambient light data collected by the ambient light sensor, and acquire pose data collected by the pose sensor. The processing module is used, when the folding state is the target folding state, to determine whether the folding device is in pocket mode based on at least two of the proximity detection result, ambient light data, and pose data; and, when the folding device is in pocket mode, to perform an anti-accidental touch operation in pocket mode.
[0008] Thirdly, a folding device is provided, including a processor coupled to a memory for executing instructions in the memory to implement the methods in any of the possible implementations of the first aspect described above. Optionally, the folding device further includes a memory. Optionally, the folding device also includes a communication interface, to which the processor is coupled.
[0009] Fourthly, a processor is provided, comprising: an input circuit, an output circuit, and a processing circuit. The processing circuit is used to receive signals through the input circuit and transmit signals through the output circuit, causing the processor to execute the method in any possible implementation of the first aspect described above.
[0010] In specific implementation, the processor can be a chip, the input circuit can be an input pin, the output circuit can be an output pin, and the processing circuit can be a transistor, gate circuit, flip-flop, and various logic circuits. The input signal received by the input circuit can be received and input by, for example, but not limited to, a receiver, and the signal output by the output circuit can be output to, for example, but not limited to, a transmitter and transmitted by the transmitter. Furthermore, the input circuit and the output circuit can be the same circuit, which is used as the input circuit and the output circuit at different times. This application does not limit the specific implementation of the processor and various circuits.
[0011] Fifthly, a processing apparatus is provided, including a processor and a memory. The processor is used to read instructions stored in the memory and to receive signals via a receiver and transmit signals via a transmitter to execute the method in any of the possible implementations of the first aspect described above.
[0012] Optionally, there may be one or more processors and one or more memories.
[0013] Alternatively, the memory can be integrated with the processor, or the memory can be set up separately from the processor.
[0014] In specific implementation, the memory can be a non-transitory memory, such as read-only memory (ROM), which can be integrated with the processor on the same chip or set on different chips. The embodiments of this application do not limit the type of memory or the way the memory and processor are set.
[0015] The processing device in the fifth aspect above can be a chip. The processor can be implemented in hardware or software. When implemented in hardware, the processor can be a logic circuit, integrated circuit, etc. When implemented in software, the processor can be a general-purpose processor that reads software code stored in memory. The memory can be integrated into the processor or located outside the processor and exist independently.
[0016] In a sixth aspect, a computer program product is provided, the computer program product comprising: a computer program (also referred to as code or instructions), which, when run, causes a computer to perform the method in any possible implementation of the first aspect described above.
[0017] In a seventh aspect, a computer-readable storage medium is provided that stores a computer program (also referred to as code or instructions) that, when executed on a computer, causes the computer to perform the methods in any of the possible implementations of the first aspect described above. Attached Figure Description
[0018] Figure 1 This is a schematic diagram of the system architecture of the folding device provided in the embodiments of this application;
[0019] Figure 2A This is a schematic diagram of a folding device provided in an embodiment of this application;
[0020] Figure 2B This is a schematic diagram of a folding device provided in an embodiment of this application;
[0021] Figure 2C This is a schematic diagram of a folding device provided in an embodiment of this application;
[0022] Figure 3 This is a schematic flowchart of a method for preventing accidental touches provided in an embodiment of this application;
[0023] Figure 4 This is a schematic diagram of an infrared proximity detection method provided in an embodiment of this application;
[0024] Figure 5 This is a schematic flowchart illustrating a first specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0025] Figure 6 This is a schematic flowchart illustrating a second specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0026] Figure 7 This is a schematic flowchart illustrating a third specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0027] Figure 8 This is a schematic flowchart illustrating the fourth specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0028] Figure 9 This is a schematic flowchart illustrating the fifth specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0029] Figure 10 This is a schematic diagram of a folding device provided in an embodiment of this application;
[0030] Figure 11 This is a schematic flowchart illustrating the sixth specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0031] Figure 12 This is a schematic diagram of the software architecture of the folding device provided in the embodiments of this application;
[0032] Figure 13 This is a schematic flowchart illustrating the seventh specific example of the method for preventing accidental touches provided in the embodiments of this application;
[0033] Figure 14 This is a schematic block diagram of an anti-accidental touch device provided in an embodiment of this application;
[0034] Figure 15 This is a schematic block diagram of a folding device provided in an embodiment of this application. Detailed Implementation
[0035] The technical solutions in this application will now be described with reference to the accompanying drawings.
[0036] To facilitate a clear description of the technical solutions in the embodiments of this application, the terms "first" and "second" are used in the embodiments of this application to distinguish identical or similar items with essentially the same function and effect. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and the terms "first" and "second" are not necessarily different.
[0037] It should be noted that in this application, the words "exemplarily" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplarily" or "for example" in this application should not be construed as being more preferred or advantageous than other embodiments or designs. Specifically, the use of words such as "exemplarily" or "for example" is intended to present the relevant concepts in a specific manner. Furthermore, "at least one" means one or more, and "more than" means two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, and c can represent: a, or b, or c, or a and b, or a and c, or b and c, or a, b, and c, where a, b, and c can be single or multiple. To make the objectives and technical solutions of this application clearer and more intuitive, the anti-accidental touch method and apparatus, folding device, and computer program product provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are merely for explaining this application and are not intended to limit this application.
[0038] Currently, electronic devices can prevent accidental touches when in pocket mode. Therefore, accurately identifying when an electronic device is in pocket mode and thus effectively preventing accidental touches has become a pressing issue that needs to be addressed.
[0039] For example, when an infrared proximity sensor detects an external object approaching or moving away from an electronic device and determines it is in pocket mode based on the proximity detection result, an error in the proximity detection result may lead to misoperation of the electronic device, affecting user experience. For instance, if no external object is approaching or obstructing the electronic device, but the infrared proximity sensor misdetects an object approaching, it may mistakenly determine the device is in pocket mode and execute anti-mistouch operations, severely impacting normal user operation. Alternatively, when a black / dark object approaches or obstructs the electronic device, such as when the device is in a dark pocket, the proximity detection result should indicate an external object is approaching. However, due to the "black card effect," the infrared proximity sensor may fail to detect the object approaching or misdetect it moving away, leading to a misjudgment that the device is not in pocket mode and failing to execute the corresponding anti-mistouch operations in time. This can result in a chain of abnormal behaviors such as functional abnormalities and accidental screen touches. The "black card effect" refers to the absorption of infrared light emitted by the infrared proximity sensor by a black / dark object, preventing it from returning to the sensor and thus hindering proximity detection.
[0040] This application provides a method and apparatus for preventing accidental touches, a folding device, and a computer program product. It can determine the folding state of the folding device, including an unfolded state or a closed state. When the folding state is the target folding state, it determines whether the folding device is in pocket mode based on at least two of the following: proximity detection results, ambient light data, and pose data. If the folding device is in pocket mode, it performs an anti-accidental touch operation in pocket mode. The proximity detection results are determined by a proximity detection sensor, the ambient light data is collected by an ambient light sensor, and the pose data is collected by a pose sensor. This allows the folding device to more accurately determine whether it is in pocket mode by combining the proximity detection results from the proximity sensor, the ambient light data from the ambient light sensor, and the pose data collected by the pose sensor, thus improving the accuracy of pocket mode determination and enabling timely and precise anti-accidental touch measures for the folding device.
[0041] For example, Figure 1 This is a schematic diagram of the system architecture of a folding device provided in an embodiment of this application.
[0042] like Figure 1 As shown, the folding device includes a processor 110 and a display unit 170. The display unit 170 may include a display screen.
[0043] Optionally, the folding device may also include a memory 130. The processor 110 and the memory 130 can communicate with each other via an internal connection to transfer data. The memory 130 stores computer programs, and the processor 110 retrieves and runs the computer programs from the memory 130. The processor 110 and the memory 130 can be combined into a single processing device, but more commonly they are independent components. The processor 110 executes the program code stored in the memory 130 to achieve the aforementioned functions. In specific implementations, the memory 130 can be integrated into the processor 110, or it can be independent of the processor 110.
[0044] In addition, to further enhance the functionality of the folding device, it may also include one or more of an input unit 160, an audio circuit 180, and a sensor 101.
[0045] Optionally, the folding device may also include a power supply 150 for providing power to various devices or circuits in the folding device.
[0046] Understandable, Figure 1 The operation and / or function of each module in the folding device shown are respectively for implementing the corresponding processes in the following method embodiments. For details, please refer to the description in the following method embodiments; detailed descriptions are omitted here to avoid repetition.
[0047] Understandable, Figure 1 The processor 110 in the illustrated folding device may include one or more processing units, such as an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural network processing unit (NPU). These different processing units may be independent devices or integrated into one or more processors.
[0048] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0049] Understandable, Figure 1 The power supply 150 shown provides power to the processor 110, memory 130, display unit 170, input unit 160, etc. The display unit 170 displays images, videos, etc. The display unit 170 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a mini-LED, a micro-LED, a quantum dot light-emitting diode (QLED), etc. The memory 130 can be used to store computer executable program code, which includes instructions. The memory 130 can include a program storage area and a data storage area. The program storage area can store the operating system, applications required for at least one function, etc. The data storage area can store data created during the use of the folding device, etc. Furthermore, memory 130 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc. Processor 110 executes various functional applications and data processing of the foldable device by running instructions stored in memory 130 and / or instructions stored in memory configured within the processor. The foldable device can implement audio functions, such as music playback and recording, through audio circuitry 180 and an application processor.
[0050] Figure 2A This is a schematic diagram of a folding device provided in an embodiment of this application. Figure 2A As shown, the folding device may include a first hinge assembly 21, which is vertically disposed in the folding device. Figure 2AThe figure 'a' shows the unfolded state of the folding device. In this unfolded state, a first display screen 22 can be provided on the front of the folding device. The first display screen 22 can be bent by the first hinge assembly 21 to achieve the lateral folding effect of the device. Specifically, as shown... Figure 2A As shown in b, during the bending process of the first display screen 22 via the first hinge assembly 21, the first display screen 22 can be divided into two parts. When the two parts (left and right parts) are fully fitted together, the folding device can be in a folding position. Figure 2A The closed state is shown by c in the figure. Figure 2A As shown in b, a second display screen 23 can also be provided on the back of the folding device when the folding device is in the position of... Figure 2A In the closed state shown by c, the folding device can display content through the second display screen 23 for user use.
[0051] Figure 2B This is a schematic diagram of a folding device provided in an embodiment of this application. Figure 2B As shown, the folding device may include a second hinge assembly 24, which is laterally disposed in the folding device. Figure 2B Figure 'a' shows the unfolded state of the folding device. In this unfolded state, a third display screen 25 can be provided on the front of the folding device. This third display screen 25 can be bent by the second hinge assembly 24 to achieve a vertical folding effect for the device. Specifically, as shown... Figure 2B As shown in b, during the bending process of the third display screen 25 via the second hinge assembly 24, the third display screen 25 can be divided into two parts. When the two parts (upper and lower parts) are fully fitted together, the folding device can be in a folding position. Figure 2B The closed state is shown by c in the figure. Figure 2B As shown in b, a fourth display screen 26 can also be provided on the back of the folding device when the folding device is in the position of... Figure 2B In the closed state shown by c, the folding device can display content through the fourth display screen 26 for user use.
[0052] It should be understood that the folding device shown in the above embodiments is merely exemplary. In addition, the folding device may also include multiple hinge components to achieve other folding effects, and this application does not limit this.
[0053] It should also be understood that the above Figure 2A The folding device shown can also be called a lateral folding device or a large folding device. Figure 2B The folding device shown can also be called a vertical folding device or a small folding device. Typically, in its unfolded state, the display screen area of this horizontal folding device is larger than that of the vertical folding device.
[0054] Figure 2C This is a schematic diagram of a folding device 200 provided in an embodiment of this application. Figure 2C As shown, the folding device 200 includes multiple sensors, such as a proximity detection sensor 201, an ambient light sensor 202, and a pose sensor 203. The proximity detection sensor 201 is a sensor capable of detecting the presence of nearby objects without any physical contact; the ambient light sensor 202 is a sensor capable of measuring the intensity of ambient light; and the pose sensor 203 is a device capable of measuring the posture and motion of an object in space.
[0055] The following combines 2A, 2B, 2C with... Figure 3 The method for preventing accidental touches provided in this application is described.
[0056] Figure 3 This is a schematic flowchart of an anti-accidental touch method 300 provided in an embodiment of this application. Figure 3 As shown, the method 300 may include the following steps:
[0057] S301, determine the folding state corresponding to the folding device, which includes an unfolded state or a closed state.
[0058] In some embodiments, the folding device further includes an opening / closing sensor, which can be used to detect the opening / closing status of the folding device. Optionally, the opening / closing sensor may include, but is not limited to, one or more of a light sensor, a distance sensor, a Hall sensor, a strain sensor, etc.
[0059] The folding device can acquire the opening and closing detection result determined by the opening and closing sensor. The opening and closing detection result is used to indicate the opening and closing status of the foldable screen of the folding device, and the corresponding folding state of the folding device is determined based on the opening and closing detection result.
[0060] In one possible scenario, the opening / closing sensor may include a connection component and a detection component, so that the folding device can acquire the opening / closing detection results determined by the connection component and the detection component, such as different electrical signals, and determine the aforementioned folding state.
[0061] In another embodiment, the opening / closing sensor may include a mechanical switch and a detection circuit, so that the folding device can acquire the opening / closing detection result determined by the mechanical switch and the detection circuit, and determine the folding state.
[0062] For example, when the hinge in the folding device is opened or closed, it squeezes or releases a mechanical switch, generating different electrical signals to determine whether the folding device is in a folded or unfolded state.
[0063] Alternatively, the folding device can also determine the folding state through software, and this application does not limit this.
[0064] S302, acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor.
[0065] In some embodiments, the folding device may, in response to a trigger operation, acquire proximity detection results determined by a proximity detection sensor, acquire ambient light data collected by an ambient light sensor, and acquire pose data collected by a pose sensor.
[0066] In one possible scenario, the triggering operation could be an operation to turn on the foldable device. For example, a user could touch the power-on function component of the foldable device, so that the foldable device can respond to the touch operation of the power-on function button, obtain the aforementioned proximity detection results, ambient light data, and pose data, and realize the detection that the foldable device is in pocket mode, so as to perform timely and accurate anti-accidental touch operation on the foldable device.
[0067] In another possible scenario, the trigger operation could also be the activation of the proximity detection function of the foldable device. For example, the user can touch the proximity detection function component of the foldable device, so that the foldable device can respond to the touch operation of the proximity detection function component, obtain the proximity detection results, ambient light data and pose data, and realize the detection of being in pocket mode, so as to perform timely and accurate anti-mistouch operation on the foldable device and improve the user experience.
[0068] In other embodiments, the folding device may also acquire proximity detection results determined by a proximity detection sensor, ambient light data collected by an ambient light sensor, and pose data collected by a pose sensor when it is determined to be in a preset mode.
[0069] In one possible scenario, the foldable device includes a sleep mode and a non-sleep mode. In sleep mode, the probability of user use is low; for example, users rarely use the foldable device during nighttime sleep, and the probability of placing it in a pocket and / or bag is also low. In non-sleep mode, the probability of user use is high; for example, during non-nighttime sleep, users can carry the foldable device in a pocket or other means and use it for work or entertainment.
[0070] For example, if it is determined that the foldable device is in sleep mode, it can be inferred that the probability of the user using the foldable device is low, and the probability of accidental touch on the foldable device's screen is also correspondingly low. Therefore, in the current mode where the need for preventing accidental touches is not high, the operation of obtaining the aforementioned proximity detection results, ambient light data, and pose data can be omitted to reduce additional power consumption. Alternatively, if it is determined that the foldable device is in non-sleep mode, it can be inferred that the user is using the foldable device and carrying it in a pocket or other means, and the probability of accidental touch on the foldable device's screen is high. Therefore, in the current mode where the need for preventing accidental touches is high, the foldable device can be triggered to obtain the aforementioned proximity detection results, ambient light data, and pose data to detect that the foldable device is in pocket mode, and to perform anti-accidental touch operations on the foldable device in a timely manner, reducing the probability of accidental touch on the foldable device's display screen and improving the user experience.
[0071] In some embodiments, the foldable device may further include a call mode and a non-call mode. In call mode, the user typically uses the foldable device close to their head or ear. Conversely, in non-call mode, the user uses the foldable device away from their head or ear.
[0072] For example, when it is determined that the foldable device is in call mode, since the user's head or ear is usually close to the foldable device, the probability of the foldable device being in a pocket and / or bag is low. Therefore, in the current mode, the foldable device can be prevented from acquiring the aforementioned proximity detection results, ambient light data, and pose data to avoid performing pocket mode detection and reduce additional power consumption. Alternatively, when it is determined that the foldable device is in non-call mode, since the probability of the user's head or ear touching the foldable device is low, the probability of placing the foldable device in a pocket and / or bag is high. Therefore, in the current mode, the foldable device can be triggered to perform the aforementioned operation of acquiring the aforementioned proximity detection results, ambient light data, and pose data to detect that the foldable device is in pocket mode and to perform anti-mistouch operations on the foldable device in a timely and accurate manner to reduce the probability of accidental touches on the foldable device's display screen and improve the user experience.
[0073] It should be understood that the preset modes shown above are merely exemplary. In addition, other specific modes may be used to trigger the above operations in different modes and achieve anti-accidental touch in different modes. This application does not limit this.
[0074] In other embodiments, the folding device may also acquire proximity detection results determined by a proximity detection sensor, ambient light data collected by an ambient light sensor, and pose data collected by a pose sensor, when it is determined to be in a target folding state.
[0075] It should be understood that the display screen that functions correctly differs depending on the folding state of the folding device. In other words, different folding states correspond to different working screens, enabling the folding device to prevent accidental touches on the working screen corresponding to the specific folding state even when in pocket mode.
[0076] For example, in conjunction with the above Figure 2A When the target is in a folded state Figure 2A The 'c' in the figure indicates the closed state of the folding device, which can detect the state described above. Figure 2A In the closed state shown by c, the aforementioned proximity detection results and data are acquired to perform an anti-accidental touch operation when the folding device is detected to be in pocket mode, thereby reducing the probability of accidental touches on the second display screen 23 corresponding to the closed state of the folding device. Alternatively, in combination with the above... Figure 2B When the target is in a folded state Figure 2B The 'a' in the diagram shows the unfolded state of the folding device, which can be activated when the aforementioned state is detected. Figure 2B In the unfolded state shown in Figure 'a', proximity detection results, ambient light data, and pose data collected by the pose sensor are acquired. When the folding device is detected to be in pocket mode, an anti-mistouch operation is performed to reduce the probability of accidental touches on the third display screen 25 corresponding to the unfolded state of the folding device. Alternatively, when the target folded state is... Figure 2B The 'c' in the figure indicates the closed state of the folding device, which can detect the state described above. Figure 2B In the case of the 'c' indicating the closed state, the above proximity detection results and data are obtained to perform an anti-accidental touch operation when the folding device is detected to be in pocket mode, thereby reducing the probability of accidental touch on the fourth display screen 26 corresponding to the closed state of the folding device.
[0077] In some embodiments, the target folding state may be a factory preset, or it may be manually set by the user based on their own usage needs. This application does not limit this.
[0078] Optionally, the folding device can also acquire the aforementioned proximity detection results, ambient light data, and pose data upon receiving a preset command, and detect whether the folding device is in pocket mode, so as to perform timely and accurate anti-mistouch operations on the folding device. This application does not limit the scope of the preset command to something such as a voice command to prevent accidental touches.
[0079] In some embodiments, the folding device can acquire in real time the proximity detection result determined by the proximity detection sensor, the ambient light data collected by the ambient light sensor, and the pose data collected by the pose sensor.
[0080] In other embodiments, the folding device may also periodically acquire proximity detection results determined by the proximity detection sensor, acquire ambient light data collected by the ambient light sensor, and acquire pose data collected by the pose sensor.
[0081] In some embodiments, the proximity detection sensor 201 described above may include an ultrasonic sensor that achieves proximity detection based on ultrasound. That is, the ultrasonic sensor can detect the distance between an external object and the folding device by emitting ultrasonic signals and listening to their echoes.
[0082] For example, an ultrasonic sensor includes an ultrasonic transmitter and an ultrasonic receiver. The ultrasonic transmitter can be used to transmit ultrasonic signals, and the ultrasonic receiver can be used to receive reflected signals of the ultrasonic signals, so that the ultrasonic sensor can determine proximity detection results based on the transmission time between the ultrasonic signals and the reflected signals, for acquisition and application by folding devices.
[0083] In one possible scenario, the proximity detection result includes distance information, which characterizes the distance between the external object and the folding device. The smaller the distance information, the closer the external object is to the folding device.
[0084] For example, different signal intensities of ultrasonic signals can correspond to different distances (such as a second correspondence). Therefore, the ultrasonic sensor can determine a proximity detection result including distance information based on the signal intensity of the ultrasonic signal received by the ultrasonic receiver and the aforementioned second correspondence, for the folding device to acquire and apply. For instance, if the distance information is less than a first distance threshold, the proximity detection result indicates that an external object is approaching the folding device; or, if the distance information is greater than or equal to a second distance threshold, the proximity detection result indicates that an external object is moving away from the folding device, where the second distance threshold is greater than or equal to the first distance threshold.
[0085] In one possible scenario, the proximity detection result includes ultrasonic signal strength information, which characterizes the distance between the external object and the folding device. The higher the ultrasonic signal strength, the closer the external object is to the folding device.
[0086] For example, if the signal strength information of the ultrasonic signal is greater than the first ultrasonic signal threshold, the proximity detection result indicates that an external object is approaching the folding device; or, if the signal strength information of the ultrasonic signal is less than or equal to the second ultrasonic signal threshold, the proximity detection result indicates that an external object is moving away from the folding device, wherein the first ultrasonic signal threshold is greater than or equal to the second ultrasonic signal threshold.
[0087] Optionally, the proximity detection result may also include information about the distance between the external object and the folding device. Such as "far away" or "near", or "1" (indicating far away) or "0" (indicating near), which can characterize information about the external object moving away from or near the folding device, so that the folding device can know the distance between the external object and the folding device without any data processing when it obtains the proximity detection result.
[0088] In some embodiments, the proximity detection sensor 201 described above may include a photoelectric proximity sensor that detects proximity based on a light beam. When an external object blocks the light beam, the photosensitive element in the photoelectric proximity sensor detects the change in light intensity to detect the approach of the external object to the folding device.
[0089] For example, the photoelectric proximity sensor can be an infrared proximity sensor, which may include an infrared emitter and an infrared receiver. The infrared emitter can emit infrared light signals, and when the infrared light signals encounter an external object, part of the infrared light signals are reflected and received by the infrared receiver. The proximity detection sensor can determine the proximity detection result by the received infrared light signals, so that the folding device can acquire and apply it.
[0090] Figure 4 This is a schematic diagram illustrating the proximity detection of an infrared proximity sensor provided in an embodiment of this application. Figure 4 As shown, the horizontal axis represents distance, which is the distance measured when the infrared proximity sensor detects an approaching external object. The vertical axis represents the infrared light intensity value (PS value), which characterizes the signal strength of the infrared light signal detected by the infrared proximity sensor after being reflected back from an external object. When there is no external object in front of the infrared proximity sensor, the PS value is low (e.g., close to 0), while when an external object approaches and blocks the infrared proximity sensor, the PS value is high (e.g., close to 2047).
[0091] In one possible scenario, the proximity detection result may include infrared light signal strength information, which characterizes the distance between the external object and the folding device. Specifically, the higher the infrared light signal strength, the closer the external object is to the folding device. Figure 4As shown, a proximity threshold (such as a first infrared light signal threshold) and a distance threshold (such as a second infrared light signal threshold) are set. When the signal strength information of the infrared light signal is greater than the first infrared light signal threshold, the signal strength information of the infrared light signal can indicate that an external object is approaching the folding device; or, when the signal strength information of the infrared light signal is less than or equal to the second infrared light signal threshold, the signal strength information of the infrared light signal can also indicate that an external object is moving away from the folding device, wherein the first infrared light signal threshold is greater than or equal to the second infrared light signal threshold.
[0092] In another possible scenario, the proximity detection result includes distance information, which characterizes the distance between the external object and the folding device. The smaller the distance, the closer the external object is to the folding device. For example... Figure 4 As shown, different signal intensities of infrared light signals can correspond to different distances (such as the first correspondence). Therefore, the infrared proximity sensor can determine the proximity detection result, including distance, based on the signal intensity of the infrared light signal received by the infrared light receiver and the aforementioned first correspondence, for the folding device to acquire and apply. For example, if the distance information is less than a third distance threshold, the proximity detection result indicates that an external object is approaching the folding device; or, if the distance information is greater than or equal to a fourth distance threshold, the proximity detection result indicates that an external object is moving away from the folding device, where the fourth distance threshold is greater than or equal to the third distance threshold.
[0093] It should be understood that during the actual proximity detection process of infrared proximity sensors, environmental factors in the actual application can also be considered, and adjustments can be made through corresponding design and algorithms to improve the performance and reliability of the infrared proximity sensors. For example, such as... Figure 4 The terms "gray card," "black card," and "oil stain" shown refer to environmental factors encountered by infrared proximity sensors in practical applications. A gray card typically refers to an object with moderate reflectivity. Its role in infrared proximity sensors is to provide a baseline reflectivity for calibration. In other words, because the reflectivity of a gray card is neither particularly high nor particularly low, it serves as a reference point, helping the infrared proximity sensor maintain consistent performance in different environments. A black card refers to an object with very low reflectivity, such as black hair or a black surface. Since black objects absorb infrared light rather than reflect it, this can reduce the signal received by the infrared receiver of the proximity sensor, thus affecting its performance. Oil stains typically refer to grease accumulated on or near the surface of the infrared proximity sensor. This grease can interfere with the infrared light emitted by the sensor, leading to false alarms. For example, grease may absorb or scatter infrared light, causing the proximity sensor to perceive an approaching object, even when no object is actually present.
[0094] Optionally, the proximity detection result may also include information about the distance between the external object and the folding device. For example, "far away" or "near," "1" (indicating far away) or "0" (indicating near) can indicate whether the external object is far away from or near the folding device, so that the folding device can know the distance between the external object and the folding device without any data processing upon obtaining the proximity detection result.
[0095] It should be understood that the proximity detection sensor 201 shown in the above embodiments is merely exemplary. In addition, the proximity detection sensor 201 may also be used in various other proximity detection sensors, such as inductive proximity sensors, capacitive proximity sensors, magnetic proximity sensors, and thermoelectric proximity sensors, depending on the specific application scenario. This application does not limit the types of proximity sensors used.
[0096] In some embodiments, the ambient light sensor 202 may include a photoresistor. This photoresistor is a resistor made of semiconductor material whose resistance changes with light intensity. When light intensity increases, the resistance decreases; conversely, when light intensity decreases, the resistance increases. Therefore, by measuring the change in the resistance of the resistor, ambient light data can be indirectly detected or acquired.
[0097] In some embodiments, the ambient light sensor 202 may include a photodiode. The photodiode is a semiconductor device that generates a photocurrent when light shines on its photosensitive area. The greater the light intensity, the greater the current generated; therefore, ambient light data can be detected or acquired by measuring the current across the photodiode.
[0098] It should be understood that the ambient light sensor 202 shown in the above embodiments is merely exemplary. In addition, the ambient light sensor 202 can also be used in various other ambient light sensors depending on the specific application scenario, and this application does not limit it.
[0099] In some embodiments, the pose sensor 203 may include an attitude sensor for acquiring attitude data of the folding device, the pose data including attitude data, so that the folding device can determine the device attitude.
[0100] In one possible scenario, the attitude sensor may include an accelerometer and / or an angular velocity sensor, and the attitude data may include acceleration data and / or angular velocity data. The accelerometer can determine the degree of tilt of an object by utilizing the inertial force generated when a point mass is affected by gravitational acceleration. The angular velocity sensor can be designed based on the law of conservation of angular momentum, determining its rotational state by detecting the angular velocities generated when the object rotates around three axes.
[0101] In some embodiments, the pose sensor 203 may include a motion sensor for acquiring motion data of the folding device, the pose data including motion data, to enable the folding device to determine a motion state, the motion state including a moving state or a non-moving state.
[0102] S303, if the above-mentioned folding state is the target folding state, determine whether the above-mentioned folding device is in pocket mode based on at least two of the proximity detection result, ambient light data and pose data.
[0103] In some embodiments, the target folding state here can be the target folding state shown in S302 above. That is, the folding device corresponds to different working screens in different folding states, so that the folding device can achieve the anti-mistouch effect on the working screen corresponding to the target folding state when it is in pocket mode.
[0104] The target folding state refers to a state in which the folding device is more likely to be in pocket mode. Pocket mode refers to a state in which the folding device is placed in a relatively small space such as a pocket or bag, which is prone to accidental touch.
[0105] For example, in combination with the above Figure 2A The folding device shown indicates that, when the folding device is in the above-mentioned position... Figure 2A In the closed state indicated by 'c', the folding device is small in size, so it is highly likely to be in pocket mode, and the target folding state can be the closed state. Therefore, when the target folding state is the closed state of the folding device, if the folding device detects that it is in the closed state, it can determine whether the folding device is in pocket mode based on at least two of the proximity detection results, ambient light data, and pose data, and perform anti-mistouch operation when the folding device is detected to be in pocket mode. In other words, when the folding device is in the closed state (i.e., small in size) and has a high probability of being in pocket mode, the proximity detection results and data can be used for verification to accurately determine the pocket mode, thereby reducing the probability of accidental touch on the display screen corresponding to the closed state of the folding device. Correspondingly, when the folding device is in the above-mentioned closed state... Figure 2A In the unfolded state shown in 'a', the folding device is large and difficult to store in a user's pocket, so there is a high probability that it is not in pocket mode. Therefore, the target folded state may not include the unfolded state, so that in the unfolded state, the acquisition of the above proximity detection results and data and the execution of anti-accidental touch operation are not triggered, thereby reducing power consumption.
[0106] For example, in combination with the above Figure 2B The folding device shown indicates that, when the folding device is in the above-mentioned position... Figure 2B The expansion state shown by 'a' in the figure is the same as... Figure 2B In the closed state shown by 'c', the folding device is relatively small, so it is highly likely to be in pocket mode. Therefore, the target folding state can be closed and / or unfolded. Thus, when the target folding state is the closed or unfolded state of the folding device, if the folding device is detected to be in either a closed or unfolded state, it can be determined whether the folding device is in pocket mode based on at least two of the proximity detection results, ambient light data, and pose data. In this case, if the folding device is detected to be in pocket mode, an anti-accidental touch operation can be performed. In other words, when the folding device is small and has a high probability of being in pocket mode, the proximity detection results and data can be used for verification to accurately determine the pocket mode, thereby reducing the probability of accidental touches on the display screen corresponding to the closed state of the folding device.
[0107] It should be understood that the target state shown herein is merely exemplary and is not intended to limit the scope of this application.
[0108] Ambient light data is used to indicate or characterize the brightness information of the environment in which the folding device is located; pose data is used to indicate or characterize the device posture and motion state of the folding device; and proximity detection results are used to indicate or characterize the approach or departure of external objects from the folding device.
[0109] In some embodiments, the external object may include at least one object other than the folding device that can function as a touch device.
[0110] For example, the external object may include a part of the user's body, such as a hand. The external object may also include non-body parts, such as the inner wall of a user's pocket or bag, or other objects stored in the pocket or bag, such as keys, clothing, or other electronic devices that can be touched.
[0111] It should be understood that the external objects shown above are merely exemplary and are not intended to limit the scope of this application.
[0112] In some embodiments, the folding device can determine whether it is in pocket mode based on proximity detection results, ambient light data, and pose data.
[0113] For example, when a foldable device is stored in a pocket or bag, the brightness inside is usually low because pockets or bags are typically small, fully or partially enclosed spaces. Furthermore, the probability of external objects approaching or obstructing the view is high, such as the inner wall of the pocket or bag being close to the foldable device, or other objects placed in the pocket or bag being close to or touching the foldable device. In addition, when a foldable device is stored in a pocket or bag, its stored posture often differs from the posture corresponding to normal user use. For example, after holding the foldable device, the user may store it in an inverted position in the pocket, resulting in the foldable device typically remaining in an abnormal usage posture. Even when a foldable device is stored in a pocket or bag, the probability of the foldable device moving due to user displacement is relatively high. Therefore, when the folding device is in a state where it is highly likely to be in pocket mode (target folding state), if the proximity detection result indicates that an external object is approaching the folding device, and the ambient light data identifies that the folding device is in a dark environment (e.g., the ambient light data is less than or equal to the first ambient light threshold), and the pose data identifies that the folding device is in an inverted posture and / or is in motion, then it can be verified that the folding device is in pocket mode.
[0114] In some embodiments, the folding device can also determine whether it is in pocket mode based on two of the following: proximity detection result, ambient light data, and pose data (such as the results). That is, the folding device is determined to be in pocket mode by cross-validating any two of the proximity detection result, ambient light data, and pose data.
[0115] For example, when a foldable device is in a state where it is highly likely to be in pocket mode (target folded state), the proximity detection result and ambient light data can be used to verify whether the foldable device is truly in pocket mode. Specifically, if the proximity detection result indicates an external object is approaching the foldable device, and the ambient light data identifies the foldable device as being in a dark environment, both are consistent with the proximity detection result and ambient brightness conditions in a scenario where the foldable device is stored in a pocket or bag. Therefore, it can be deduced that the probability of the proximity detection result and / or ambient light data being incorrect is low. In other words, in addition to verifying whether the foldable device is in pocket mode using the proximity detection result and ambient light data, the proximity detection result and ambient light data can also be mutually verified to achieve efficient and accurate judgment of the foldable device's pocket mode and promptly perform anti-mistouch operations on the foldable device, such as not responding to touch operations detected in pocket mode, thus reducing the probability of accidental touches on the foldable device's display screen.
[0116] Similarly, when the foldable device is in a state where it is highly likely to be in pocket mode (target folded state), if proximity detection indicates that an external object is approaching the foldable device, or if the foldable device is identified as being in an inverted position and / or in motion based on pose data, it can also be determined that the foldable device is in pocket mode, and anti-mistouch operations can be performed on the foldable device in a timely manner. Alternatively, when the foldable device is in a state where it is highly likely to be in pocket mode (target folded state), if the foldable device is identified as being in a dark environment based on ambient light data, or if the foldable device is identified as being in an inverted position and / or in motion based on pose data, it can also be determined that the foldable device is in pocket mode, and anti-mistouch operations can be performed in a timely manner to reduce the probability of accidental touches on the foldable device's display screen.
[0117] S304, when the folding device is in pocket mode, perform the anti-accidental touch operation in pocket mode.
[0118] In some embodiments, when the folding device is in pocket mode, touch operations detected in pocket mode may not be responded to, thereby reducing the probability of accidental touches on the display screen of the folding device.
[0119] For example, when the folding device is in pocket mode, it can be inferred that there is a high probability that an external object (such as the inner wall of the pocket or other objects in the pocket) is close to the folding device. Therefore, the screen state of the folding device can be controlled to not respond to the touch operation detected in pocket mode, so as to avoid accidental touches on the display screen of the folding device by the inner wall of the pocket or other objects in the pocket.
[0120] In some embodiments, when the folding device is in pocket mode, the display screen of the folding device can be controlled to be in an off state to reduce the probability of accidental touch on the display screen of the folding device.
[0121] For example, when the folding device is in pocket mode, it can be inferred that there is a high probability that an external object (such as the inner wall of the pocket or other objects in the pocket) will approach the folding device. Therefore, the screen state of the folding device can be controlled to be off to avoid accidental touches on the display screen of the folding device in the on state caused by the inner wall of the pocket or other objects in the pocket.
[0122] Optionally, when the folding device is in pocket mode, it can also output a prompt message to prevent accidental touches, such as through vibration, to inform the user of the current accidental touch prevention status.
[0123] In this application, the folding state of a folding device can be determined, including an unfolded state or a closed state. When the folding state is the target folding state, it is determined whether the folding device is in pocket mode based on at least two of the following: proximity detection results, ambient light data, and pose data. If the folding device is in pocket mode, an anti-mistouch operation in pocket mode is performed. The proximity detection results are determined by a proximity detection sensor, the ambient light data is collected by an ambient light sensor, and the pose data is collected by a pose sensor. This allows the folding device to more accurately determine whether it is in pocket mode in the target folding state by combining the proximity detection results from the proximity sensor, the ambient light data from the ambient light sensor, and the pose data collected by the pose sensor. This improves the accuracy of pocket mode determination and also enables timely and precise anti-mistouch operation of the folding device.
[0124] In some embodiments, the pose sensor includes an attitude sensor, and correspondingly, the pose data includes attitude data. The folding device can identify the device attitude based on the pose data, and determine whether the folding device is in pocket mode by using at least two of the above-mentioned proximity detection results, ambient light data, and pose data (attitude data), so as to perform the corresponding anti-accidental touch operation in a timely manner when it is in pocket mode.
[0125] Figure 5 This is a schematic flowchart of an anti-accidental touch method 500 provided in an embodiment of this application. Figure 5 As shown, the method 500 may include the following steps:
[0126] S501, determine the folding state corresponding to the folding device, which includes an unfolded state or a closed state.
[0127] S502, acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor.
[0128] S503, when the above-mentioned folding state is the target folding state, the device posture of the folding device is determined based on the pose data.
[0129] S504, determine whether the proximity detection result, ambient light data and device posture meet the first condition; the first condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture.
[0130] The inverted state can be the posture resulting from the user holding and using the foldable device.
[0131] For example, the folding device includes a first edge and a second edge that are parallel to each other, and a third edge and a fourth edge that are parallel to each other. When a user holds and uses the folding device, the first edge is higher than the second edge in the vertical space, and the third and fourth edges are in contact with the user's hand. Correspondingly, when the folding device is in an inverted position, the first edge may be lower than or equal to the second edge in the vertical space.
[0132] S505, if the proximity detection result, ambient light data and device posture meet the first condition, then the folding device is determined to be in pocket mode.
[0133] S506 performs anti-accidental touch operation in pocket mode.
[0134] Optionally, following the above S504, if the proximity detection result, ambient light data and device attitude do not meet the first condition, then S507 can also be executed.
[0135] S507, if the proximity detection result, ambient light data and device posture determine that the third condition is met, then the folding device is determined to be in non-pocket mode; the third condition includes the proximity detection result indicating that the external object is away from the folding device, the ambient light data being greater than the second ambient light threshold (such as a bright environment), and / or the device posture being a non-inverted posture.
[0136] In this embodiment, the folding device can determine whether it is in pocket mode based on at least two of the proximity detection results, ambient light data, and device posture. That is, the folding device can flexibly identify its posture based on this pose data, achieving highly flexible determination of the pocket mode and promptly executing corresponding anti-mistouch operations by using at least two of the proximity detection results, ambient light data, and device posture.
[0137] In some embodiments, the pose sensor includes a motion sensor, and correspondingly, the pose data includes motion data. The folding device can identify the motion state of the folding device based on the pose data, and determine whether the folding device is in pocket mode by using at least two of the above-mentioned proximity detection results, ambient light data, and pose data (motion data), so as to perform the corresponding anti-accidental touch operation in a timely manner when it is in pocket mode.
[0138] Figure 6 This is a schematic flowchart of an anti-accidental touch method 600 provided in an embodiment of this application. Figure 6 As shown, the method 600 may include the following steps:
[0139] S601, determine the folding state corresponding to the folding device, which includes an unfolded state or a closed state.
[0140] S602, acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor.
[0141] S603, when the folding state is the target folding state, the motion state of the folding device is determined based on the pose data, and the motion state includes a moving state or a non-moving state.
[0142] S604, determine whether the proximity detection result, ambient light data and motion state meet the second condition; the second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to the first ambient light threshold, and the motion state being in motion.
[0143] S605, if the proximity detection result, ambient light data and motion state meet the second condition, then the folding device is determined to be in pocket mode.
[0144] S606 performs anti-mistouch operation in pocket mode.
[0145] Optionally, following S604 above, if the proximity detection result, ambient light data and motion state do not meet the second condition, S607 can also be executed.
[0146] S607, if the proximity detection result indicates that an external object is moving away from the folding device, then the folding device is determined to be in non-pocket mode.
[0147] In this embodiment, the folding device can also determine whether it is in pocket mode based on at least two of the proximity detection results, ambient light data, and motion state. That is, the folding device can flexibly identify its motion state based on this pose data, achieving highly flexible judgment of the pocket mode and timely execution of corresponding anti-mistouch operations by using at least two of the proximity detection results, ambient light data, and motion state.
[0148] In some embodiments, the pose sensor may further include an attitude sensor and a motion sensor, and correspondingly, the pose data includes motion data and attitude data. The folding device can identify the motion state and device attitude of the folding device based on the pose data, and determine whether the folding device is in pocket mode by using at least two of the above-mentioned proximity detection results, ambient light data and pose data (motion data and attitude data), so as to perform the corresponding anti-accidental touch operation in a timely manner when it is in pocket mode.
[0149] Figure 7 This is a schematic flowchart of an anti-accidental touch method 700 provided in an embodiment of this application. Figure 7As shown, the method 700 may include the following steps:
[0150] S701, determine the folding state corresponding to the folding device, which includes an unfolded state or a closed state.
[0151] S702, acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor.
[0152] S703, when the above-mentioned folding state is the target folding state, the device posture of the folding device is determined based on the pose data.
[0153] S704, determine whether the proximity detection result, ambient light data and device posture meet the first condition; the first condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture.
[0154] S705, if the proximity detection result, ambient light data and device posture meet the first condition, then the folding device is determined to be in pocket mode, and the anti-accidental touch operation in pocket mode is performed.
[0155] Optionally, following step S704 above, if the proximity detection result, ambient light data, and device posture do not meet the first condition, the following steps may also be performed:
[0156] S706, determine the motion state of the folding device based on the pose data, the motion state including a moving state or a non-moving state.
[0157] S707, determine whether the proximity detection result, ambient light data and motion state meet the second condition; the second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being in motion.
[0158] If the proximity detection results, ambient light data, and motion state meet the second condition, then the folding device is determined to be in pocket mode, i.e., S705 shown in the figure.
[0159] Optionally, following the above S707, if the proximity detection result, ambient light data and the device attitude do not meet the second condition, then S708 can also be executed.
[0160] S708, if the proximity detection result, ambient light data and device posture determine that the third condition is met, then the folding device is determined to be in non-pocket mode; the third condition includes the proximity detection result indicating that the external object is away from the folding device, the ambient light data being greater than the second ambient light threshold, and / or the device posture being a non-inverted posture.
[0161] In this embodiment, the folding device can determine whether it is in pocket mode based on at least two of the proximity detection results, ambient light data, and pose data recognition results (device posture and motion state). That is, the folding device can flexibly recognize its posture and motion state based on this pose data, achieving highly flexible and accurate determination of the folding device's pocket mode through at least two of the proximity detection results, ambient light data, and pose data recognition results (device posture and motion state), and promptly executing corresponding anti-accidental touch operations.
[0162] In some embodiments, different types of folding devices correspond to different target folding states.
[0163] In some embodiments, the folding device includes a lateral folding device (see, for example) Figure 2A The lateral folding device includes a first hinge assembly arranged vertically, and the target folding state includes the closed state of the lateral folding device.
[0164] In a first possible implementation, if the folding device is determined to be a horizontally folding device and is in a closed state, it can be determined whether the horizontally folding device is in pocket mode based on the first condition mentioned above. That is, if the folding device is a horizontally folding device and is in a closed state, it can be determined that the device posture is identified based on the aforementioned posture data, and whether it is in pocket mode is determined based on at least two of the aforementioned proximity detection results, ambient light data, and the device posture.
[0165] In the second possible implementation, if it is determined that the folding device is a horizontally folding device and is in a closed state, it can also be determined whether the horizontally folding device is in pocket mode based on the second condition mentioned above. That is, if the folding device is a horizontally folding device and is in a closed state, it can be determined that the motion state is identified based on the above-mentioned posture data, and whether it is in pocket mode is determined based on at least two of the above-mentioned proximity detection results, ambient light data, and the motion state.
[0166] In a third possible implementation, if the folding device is determined to be a horizontally folding device and is in a closed state, it can also be determined whether the horizontally folding device is in pocket mode based on the first and second conditions mentioned above. That is, if the folding device is a horizontally folding device and is in a closed state, it can be determined whether it is in pocket mode based on at least two of the motion state and device posture recognition results (motion state and device posture) based on the aforementioned posture data, proximity detection results, ambient light data, and pose data recognition results.
[0167] Figure 8 This is a schematic flowchart of an anti-accidental touch method 800 for a horizontally folding device provided in an embodiment of this application. Figure 8 As shown, the method 800 may include the following steps:
[0168] S801, determine the folding state corresponding to the lateral folding device, which includes an unfolded state or a closed state.
[0169] S802, acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor.
[0170] S803 determines whether the horizontal folding device is in a closed state.
[0171] S804 determines the device posture of the folding device based on the pose data when the folding device is in a closed state.
[0172] S805, determine whether the proximity detection result, ambient light data and device posture meet the first condition; the first condition includes the proximity detection result indicating that an external object is approaching the horizontally folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture.
[0173] S806, if the proximity detection result, ambient light data and device posture meet the first condition, then determine that the horizontally folding device is in pocket mode and perform the anti-accidental touch operation in pocket mode.
[0174] Optionally, following step S805 above, if the proximity detection result, ambient light data, and device attitude do not meet the first condition, the following steps may also be performed:
[0175] S807, determine the motion state of the lateral folding device based on the pose data, the motion state including a moving state or a non-moving state.
[0176] S808, determine whether the proximity detection result, ambient light data and motion state meet the second condition; the second condition includes the proximity detection result indicating that an external object is approaching the horizontally folding device, the ambient light data being less than or equal to the first ambient light threshold, and the motion state being in motion.
[0177] If the proximity detection results, ambient light data and motion state meet the second condition, then the horizontally folding device is determined to be in pocket mode, and the anti-accidental touch operation in pocket mode is executed, i.e., S806.
[0178] Optionally, following the above S808, if the proximity detection result, ambient light data and device posture do not meet the second condition, then S809 can also be executed.
[0179] S809, if the proximity detection result, ambient light data and device posture determine that the third condition is met, then the horizontally folding device is determined to be in non-pocket mode; the third condition includes the proximity detection result indicating that the external object is away from the horizontally folding device, the ambient light data being greater than the second ambient light threshold, and / or the device posture being a non-inverted posture.
[0180] Optionally, following the above S803, if the lateral folding device is not in the closed state (i.e., in the unfolded state), S810 can also be executed.
[0181] S810, if the lateral folding device is not in a closed state, determine that the lateral folding device is in a non-pocket mode.
[0182] Optionally, following the above-described S810, when the folding state of the horizontal folding device switches from the closed state to the unfolded state, S811 can also be executed to turn off at least one of the ambient light sensor and the pose sensor to reduce power consumption.
[0183] In this embodiment, the horizontally folding device can determine the pocket pattern of the vertically folding device based on proximity detection results, ambient light data, and pose data recognition results when it is in a closed state. The pose data recognition results can include the device's posture and / or motion state. Therefore, while flexibly determining the pocket pattern of the vertically folding device, it also improves the accuracy of pocket pattern determination, thereby enhancing the timeliness and accuracy of performing anti-accidental touch operations on the horizontally folding device.
[0184] In another possible scenario, the folding device includes a longitudinal folding device (see [reference needed]). Figure 2B The longitudinal folding device includes a second hinge assembly arranged laterally, and the target folding state is the unfolded state or the closed state of the longitudinal folding device.
[0185] In one possible implementation, when it is determined that the folding device is a vertically folding device and is in an unfolded state, the vertically folding device can also determine whether it is in pocket mode based on the first condition and / or the second condition mentioned above. That is, when the folding device is a vertically folding device and is in an unfolded state, it can be determined whether it is in pocket mode based on at least two of the motion state and / or device posture recognition results (motion state and / or device posture) based on the proximity detection result, ambient light data, and pose data recognition results.
[0186] In another possible implementation, if the folding device is determined to be a longitudinally folding device and is in a closed state, it can also be determined whether the longitudinally folding device is in pocket mode based on the second condition mentioned above. That is, if the folding device is a longitudinally folding device and is in a closed state, it can be determined that the motion state is identified based on the above-mentioned posture data, and whether it is in pocket mode is determined based on at least two of the above-mentioned proximity detection results, ambient light data, and motion state.
[0187] Figure 9 This is a schematic flowchart of a method 900 for preventing accidental touches on a longitudinally folding device provided in an embodiment of this application. Figure 9 As shown, the method 900 may include the following steps:
[0188] S901, determine the folding state corresponding to the longitudinal folding device, which includes an unfolded state or a closed state.
[0189] S902, acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor.
[0190] S903, determine whether the longitudinal folding device is in a closed state.
[0191] S904, when the longitudinal folding device is in a closed state, the motion state of the folding device is determined based on the pose data, and the motion state includes a moving state or a non-moving state.
[0192] S905, determine whether the proximity detection result, ambient light data and motion state meet the second condition; the second condition includes the proximity detection result indicating that an external object is approaching the longitudinal folding device, the ambient light data being less than or equal to the first ambient light threshold, and the motion state being in motion.
[0193] S906, if the proximity detection result, ambient light data and motion state meet the second condition, then the longitudinally folding device is determined to be in pocket mode, and the anti-accidental touch operation in pocket mode is performed.
[0194] Optionally, following the above S905, if the proximity detection result, ambient light data and motion state do not meet the second condition, then S907 can also be executed.
[0195] S907, if the aforementioned proximity detection result indicates that an external object is moving away from the longitudinal folding device, then it is determined that the longitudinal folding device is in non-pocket mode.
[0196] Optionally, following the above S903, if the longitudinal folding device is not in the closed state (i.e., in the unfolded state), S908 can also be executed.
[0197] S908, when the longitudinally folding device is in the unfolded state, the device posture of the longitudinally folding device is determined based on the pose data.
[0198] S909, determine whether the proximity detection result, ambient light data and device posture meet the first condition; the first condition includes the proximity detection result indicating that an external object is approaching the longitudinally folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture.
[0199] If the proximity detection results, ambient light data and device posture meet the first condition, then the longitudinally folding device is determined to be in pocket mode, and the anti-accidental touch operation in pocket mode is performed, i.e., the above-mentioned S906.
[0200] Optionally, following S908 above, if the proximity detection result, ambient light data, and device posture do not meet the first condition, the system can also determine whether the vertically folding device is in pocket mode based on the second condition. The specific steps are similar to those of S904 to S907 above. For example, the system determines the motion state of the vertically folding device based on the pose data, and determines whether the proximity detection result, ambient light data, and motion state meet the second condition. If the proximity detection result, ambient light data, and motion state meet the second condition, the system determines that the vertically folding device is in pocket mode and performs the anti-mistouch operation in pocket mode. Alternatively, if the system determines that the third condition is met based on the proximity detection result, ambient light data, and device posture, the system determines that the vertically folding device is in non-pocket mode. To avoid repetition, these steps will not be elaborated here.
[0201] In this embodiment, the longitudinally folding device can flexibly determine its pocket mode based on proximity detection results, ambient light data, and pose data recognition results (device posture and / or motion state) when in the unfolded state. The longitudinally folding device can also determine whether it is in pocket mode based on proximity detection results, ambient light data, and motion state, avoiding the problem of difficulty or inability to recognize inverted postures when the longitudinally folding device is in the closed state, further improving the flexibility of pocket mode determination.
[0202] Figure 10 This is a schematic diagram of the folding device 1000 provided in this application. Figure 10 The folding device 1000 includes a proximity detection sensor 1001, a pose sensor 1002, an ambient light sensor 1003, an opening / closing sensor 1004, and an anti-accidental touch virtual sensor 1005 (also known as a pocket anti-accidental touch virtual sensor).
[0203] In some embodiments, such as Figure 10 As shown, the proximity detection sensor 1001 may include an ultrasonic sensor 1011 and / or an infrared proximity sensor 1012 to determine the proximity detection result. The ultrasonic sensor 1011 may include an ultrasonic transmitting unit and an ultrasonic receiving unit. The ultrasonic transmitting unit includes an earpiece 1111, and the ultrasonic receiving unit includes a microphone 1112, enabling the transmission and reception of ultrasonic signals based solely on the existing audio hardware and software algorithms within the folding device, without requiring additional hardware sensors. For example, the ultrasonic sensor 1011 can transmit ultrasonic signals through the earpiece 1111, receive the reflected signal of the ultrasonic signal through the microphone 1112, and determine the proximity detection result based on the transmission time between the ultrasonic signal and the reflected signal, for acquisition and application by the folding device. Figure 10 As shown, the pose sensor 1002 includes a posture sensor 1021 and / or a motion sensor 1022. The posture sensor 1021 includes an accelerometer sensor 1211 and a gyroscope sensor 1212. The folding device can acquire acceleration and angular velocity data collected by the accelerometer sensor 1211 and the gyroscope sensor 1212 via the anti-mistouch virtual sensor 1005, acquire motion data collected by the motion sensor 1022, acquire ambient light data collected by the ambient light sensor 1003, acquire the opening / closing detection result determined by the opening / closing sensor 1004, and, if the opening / closing detection result indicates that the folding device is in a target folded state, determine whether the folding device is in pocket mode based on at least two of the proximity detection result, ambient light data, and pose data, thereby achieving anti-mistouch protection for the folding device's form factor screen. See details below. Figure 11 .
[0204] Figure 11 This is a schematic diagram of the method for preventing accidental touches provided in this application. Figure 11As shown, the earpiece 1111 in the ultrasonic sensor 1011 can emit ultrasonic signals, and the microphone 1112 can receive the ultrasonic signals, i.e., the reflected signals of the ultrasonic signals. Based on the transmission time between the ultrasonic signals and the reflected signals, the proximity detection result, such as distance information, is obtained. Alternatively, the proximity detection result can also be determined by the infrared proximity sensor 1012 (not shown in the figure). For details, please refer to the above embodiments; to avoid repetition, they will not be repeated here. Figure 11 The accelerometer 1211 can collect acceleration data, the gyroscope 1212 can collect angular velocity data, the motion sensor 1022 can collect motion data, the ambient light sensor 1003 can collect ambient light data, and the opening / closing sensor 1004 can determine the opening / closing detection result. The anti-mistouch virtual sensor 1005 can acquire proximity detection results, ambient light data, and pose data (attitude data and / or motion data), and if the opening / closing detection result indicates that the folding device is in a target folded state, based on at least two of the proximity detection result, ambient light data, and pose data, it determines that the folding device is in pocket mode and performs an anti-mistouch operation on the screen state of the folding device.
[0205] Figure 12 This is a schematic diagram of the software architecture of a folding device 1200 provided in an embodiment of this application. The layered architecture divides the software system of the folding device 1200 into several layers, each with a clear role and division of labor. Layers communicate with each other through software interfaces. In this embodiment, the system can be divided into four layers: the application layer, the application framework layer (framework layer), the algorithm layer, the device driver layer, and the device layer.
[0206] like Figure 12 As shown, the application layer includes system applications, and the application framework layer includes a service module for preventing accidental touches and detecting virtual sensors. When the foldable device registers to monitor the anti-accidental touch virtual sensor through the system application, the anti-accidental touch virtual sensor service module can activate the anti-accidental touch virtual sensor after receiving the registration and monitoring instruction, and activate the ultrasonic algorithm detection function when the proximity detection sensor includes an ultrasonic sensor.
[0207] like Figure 12 As shown, the algorithm layer includes a virtual sensor to prevent accidental touches, and in the case where the proximity detection sensor includes an ultrasonic sensor, the algorithm layer also includes an ultrasonic detection algorithm engine.
[0208] like Figure 12As shown, the device layer includes an ambient light sensor, an opening / closing sensor, and a pose sensor, such as a motion sensor and / or an attitude sensor including an accelerometer and a gyroscope. In the case where the proximity detection sensor includes an ultrasonic sensor, the device layer also includes a microphone and an earpiece. In the case where the proximity detection sensor includes an infrared proximity sensor, the device layer may also include an infrared proximity sensor.
[0209] like Figure 12 As shown, the device driving layer includes an ambient light sensor driver, a pose sensor driver, an opening / closing sensor driver, and, where the proximity detection sensor includes an ultrasonic sensor, an ultrasonic driver; and where the proximity detection sensor includes an infrared proximity sensor, an infrared proximity sensor driver. The ultrasonic driver is used to turn the microphone and earpiece on or off. Specifically, the ultrasonic driver may include a microphone driver and an earpiece driver, with the microphone driver turning the microphone on or off and the earpiece driver turning the earpiece on or off. The infrared proximity sensor driver turns the infrared proximity sensor on or off, the pose sensor driver turns the pose sensor and / or motion sensor on or off, and the opening / closing sensor driver turns the opening / closing sensor on or off. See details below. Figure 13 .
[0210] Figure 13 This is a schematic flowchart illustrating a method 1300 for preventing accidental touches in call mode, provided as an embodiment of this application. Figure 13 As shown, the method 1300 may include the following steps:
[0211] S1301, the system application in the application layer sends a registration and listening instruction to the anti-mistouch dummy detection sensor service module in the framework layer. Correspondingly, the anti-mistouch dummy detection sensor service module in the framework layer receives the registration and listening instruction.
[0212] S1302, the anti-mistouch virtual detection sensor service module in the framework layer sends an activation command to the anti-mistouch virtual sensor in the algorithm layer based on the registration listening command. Correspondingly, the anti-mistouch virtual sensor in the algorithm layer receives the activation command.
[0213] S1303, the anti-mistouch virtual sensor in the algorithm layer sends an activation command to the infrared proximity sensor driver, pose sensor, ambient light sensor, and opening / closing sensor in the device driver layer, respectively, based on the activation command. Correspondingly, the infrared proximity sensor driver, pose sensor, ambient light sensor, and opening / closing sensor in the device driver layer receive the activation command.
[0214] S1304, the infrared proximity sensor driver in the device driving layer sends an enable command to the infrared proximity sensor in the device layer based on the proximity enable command. Correspondingly, the infrared proximity sensor in the device layer receives the enable command.
[0215] S1305, the pose sensor driver in the device driver layer sends an enable command to the pose sensor in the device layer based on the enable command. Correspondingly, the pose sensor in the device layer receives the enable command.
[0216] S1306, the ambient light sensor driver in the device driver layer sends an enable command to the ambient light sensor in the device layer based on the enable command. Correspondingly, the ambient light sensor in the device layer receives the enable command.
[0217] S1307, the opening / closing sensor driver in the device driving layer sends an opening command to the opening / closing sensor in the device layer based on the opening command. Correspondingly, the opening / closing sensor in the device layer receives the opening command.
[0218] S1308, the infrared proximity sensor in the device layer determines the proximity detection result, the pose sensor collects pose data, the ambient light sensor collects ambient light data, and the opening / closing sensor determines the opening / closing detection result.
[0219] S1309, the infrared proximity sensor in the device layer sends the proximity detection result to the infrared proximity sensor driver, the pose sensor sends the pose data to the pose sensor driver, the ambient light sensor sends the ambient light data to the ambient light driver, and the opening / closing sensor sends the opening / closing detection result to the opening / closing sensor driver. Correspondingly, the infrared light receiving sensor driver in the device driving layer receives the proximity detection result, the pose sensor driver receives the pose data, the ambient light sensor driver receives the ambient light data, and the opening / closing sensor determines that it receives the opening / closing detection result.
[0220] In step S1310, the infrared proximity sensor driver in the device driving layer sends the proximity detection result to the anti-mistouch virtual sensor in the algorithm layer; the pose sensor driver sends the pose data to the anti-mistouch virtual sensor in the algorithm layer; the ambient light sensor driver sends the ambient light data to the anti-mistouch virtual sensor in the algorithm layer; and the opening / closing sensor driver sends the opening / closing detection result to the anti-mistouch virtual sensor in the algorithm layer. Correspondingly, the anti-mistouch virtual sensor in the algorithm layer receives the proximity detection result, pose data, ambient light data, and opening / closing detection result.
[0221] Optionally, such as Figure 13 As shown, when the proximity detection sensor is an ultrasonic sensor, the anti-mis-touch virtual sensor in the algorithm layer can also obtain the proximity detection result from the ultrasonic detection algorithm module.
[0222] For example, the anti-mistouch false detection sensor service module in the framework layer can send a command to the ultrasonic driver in the device driver layer to enable the ultrasonic algorithm detection function based on the registration monitoring command. Correspondingly, the ultrasonic driver can send a command to the earpiece in the device layer to emit an ultrasonic signal and a command to the microphone in the device layer to receive an ultrasonic signal based on the command to enable the ultrasonic algorithm detection function, so that the earpiece in the device layer emits an ultrasonic signal and the microphone receives the reflected ultrasonic signal. The microphone in the device layer can send the reflected ultrasonic signal to the ultrasonic driver in the device driver layer, so that the ultrasonic driver sends the reflected ultrasonic signal to the ultrasonic detection algorithm module in the algorithm layer, and the ultrasonic detection algorithm module determines the proximity detection result based on the reflected ultrasonic signal.
[0223] S1311, when the opening and closing detection result indicates that the folding device is in the target folding state, the anti-mistouch virtual sensor in the algorithm layer determines that the folding device is in pocket mode based on at least two of the pose data, ambient light data and proximity detection results.
[0224] Optionally, the opening and closing detection results can be obtained first, and when the opening and closing detection results indicate that the folding device is in the target folding state, the aforementioned proximity detection results, ambient light data, and pose data can be obtained. Based on at least two of the pose data, ambient light data, and proximity detection results, it can be determined that the folding device is in pocket mode.
[0225] S1312, the anti-mistouch virtual sensor in the algorithm layer sends the judgment result of being in pocket mode to the anti-mistouch virtual detection sensor service module in the framework layer. Correspondingly, the anti-mistouch virtual detection sensor service module in the framework layer receives the judgment result.
[0226] S1313, the anti-misclick detection sensor service module in the framework layer reports the judgment result to the system application in the application layer. Correspondingly, the system application in the application layer receives the judgment result.
[0227] S1314, The system application in the application layer executes the anti-mistouch operation in this pocket mode based on the judgment result.
[0228] It should be understood that the various embodiments described above can also be coupled to each other, and this application does not limit this. Furthermore, the sequence number of each process does not imply the order of execution; the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0229] The above text combines Figures 1 to 13 The method for preventing accidental touches according to embodiments of this application is described in detail below. Figure 14 and Figure 15 This application describes in detail the anti-accidental touch device according to the embodiments of this application.
[0230] Figure 14 An anti-accidental touch device 1400 according to an embodiment of this application is shown, applied to a folding device, which includes a proximity detection sensor, an ambient light sensor, and a pose sensor. The anti-accidental touch device 1400 includes a processing module 1401 and an acquisition module 1402. The processing module 1401 is used to: determine the folding state of the folding device, which includes an unfolded state or a closed state; the acquisition module 1402 is used to: acquire the proximity detection result determined by the proximity detection sensor, acquire ambient light data collected by the ambient light sensor, and acquire pose data collected by the pose sensor; the processing module 1401 is further used to: when the folding state is the target folding state, determine whether the folding device is in pocket mode based on at least two of the proximity detection result, ambient light data, and pose data; and, when the folding device is in pocket mode, perform an anti-accidental touch operation in pocket mode.
[0231] Optionally, the processing module 1401 is configured to: determine the device posture of the folding device based on the pose data; if the proximity detection result, the ambient light data and the device posture meet a first condition, then determine that the folding device is in the pocket mode; the first condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture.
[0232] Optionally, the processing module 1401 is configured to: determine the motion state of the folding device based on the pose data, the motion state including a moving state or a non-moving state; if the second condition is satisfied based on the proximity detection result, the ambient light data, and the motion state, then determine that the folding device is in the pocket mode; the second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being the moving state.
[0233] Optionally, the processing module 1401 is configured to: determine the device posture of the folding device based on the pose data; if the proximity detection result, the ambient light data and the device posture determine that a third condition is met, then determine that the folding device is in a non-pocket mode; the third condition includes the proximity detection result indicating that an external object is moving away from the folding device, the ambient light data being greater than a second ambient light threshold, and / or the device posture being a non-inverted posture.
[0234] Optionally, the processing module 1401 is configured to: if the proximity detection result indicates that an external object is moving away from the folding device, then determine that the folding device is in non-pocket mode.
[0235] Optionally, the folding device includes a lateral folding device, which includes a vertically arranged first hinge assembly, and the target folding state includes the closed state of the lateral folding device; or, the folding device includes a longitudinal folding device, which includes a laterally arranged second hinge assembly, and the target folding state is the unfolded state or the closed state of the longitudinal folding device.
[0236] Optionally, the processing module 1401 is configured to: determine the device posture and motion state of the folding device based on the pose data when the folding device is a horizontally folding device and the horizontally folding device is in the closed state, or when the folding device is a vertically folding device and the vertically folding device is in the unfolded state; if the proximity detection result, the ambient light data, and the device posture determine that a first condition is met, then the folding device is determined to be in pocket mode; the first condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture; if the first condition is not met, if the proximity detection result, the ambient light data, and the motion state determine that a second condition is met, then the folding device is determined to be in pocket mode; the second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being the currently moving state.
[0237] Optionally, the processing module 1401 is configured to: determine that the lateral folding device is in a non-pocket mode when the lateral folding device is in the unfolded state.
[0238] Optionally, the processing module 1401 is configured to: turn off at least one of the ambient light sensor and the pose sensor when the folding state of the lateral folding device switches from the closed state to the unfolded state.
[0239] Optionally, the folding device includes a longitudinal folding device, and the processing module 1401 is configured to: determine the motion state of the folding device based on the pose data when the longitudinal folding device is in the closed state; the motion state includes a moving state or a non-moving state; if a second condition is determined to be met based on the proximity detection result, the ambient light data, and the motion data, then determine that the folding device is in pocket mode; the second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being the moving state.
[0240] Optionally, the folding device further includes an opening / closing sensor. The acquisition module 1402 is used to: acquire the opening / closing detection result determined by the opening / closing sensor; the opening / closing detection result is used to indicate the opening / closing status of the foldable screen of the folding device; and the processing module 1401 is used to: determine the folding state of the folding device based on the opening / closing detection result.
[0241] Optionally, the proximity detection sensor mentioned above includes an infrared proximity sensor and / or an ultrasonic sensor.
[0242] Optionally, the ultrasonic sensor includes an ultrasonic transmitting unit and an ultrasonic receiving unit. The ultrasonic transmitting unit includes an earpiece, and the ultrasonic receiving unit includes a microphone. The proximity detection result includes distance information. The acquisition module 1402 is used to: transmit an ultrasonic signal through the earpiece; receive the reflected signal of the ultrasonic signal through the microphone; and acquire the distance information based on the transmission time between the ultrasonic signal and the reflected signal.
[0243] Optionally, the acquisition module 1402 is used to: acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor through the anti-accidental touch virtual sensor; the processing module 1401 is used to: determine whether the folding device is in pocket mode based on at least two of the proximity detection result, the ambient light data, and the pose data through the anti-accidental touch virtual sensor.
[0244] It should be understood that the accidental touch prevention device 1400 here is embodied in the form of a functional module. The term "module" here can refer to application-specific integrated circuits (ASICs), electronic circuits, processors (e.g., shared processors, proprietary processors, or group processors, etc.) and memory for executing one or more software or firmware programs, integrated logic circuits, and / or other suitable components supporting the described functions. In an alternative example, those skilled in the art will understand that the accidental touch prevention device 1400 can be specifically the folding device in the above embodiments, or the functions of the folding device in the above embodiments can be integrated into the accidental touch prevention device 1400. The accidental touch prevention device 1400 can be used to execute the various processes and / or steps corresponding to the folding device in the above method embodiments; to avoid repetition, these will not be described again here. The above-mentioned accidental touch prevention device 1400 has the function of implementing the corresponding steps performed by the folding device in the above method; the above functions can be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions. In the embodiments of this application, Figure 14 The anti-accidental touch device 1400 can also be a chip or a chip system, such as a system on chip (SoC).
[0245] Figure 15 A folding device 1500 according to an embodiment of this application is shown. The folding device 1500 includes a processor 1501, a memory 1502, a communication interface 1503, and a bus 1504. The memory 1502 stores instructions, and the processor 1501 executes the instructions stored in the memory 1502. The processor 1501, memory 1502, and communication interface 1503 are interconnected via the bus 1504.
[0246] The processor 1501 is configured to: determine the folding state of the folding device, including an unfolded state or a closed state; acquire a proximity detection result determined by a proximity detection sensor, acquire ambient light data collected by an ambient light sensor, and acquire pose data collected by a pose sensor; if the folding state is the target folding state, determine whether the folding device is in pocket mode based on at least two of the proximity detection result, ambient light data, and pose data; and if the folding device is in pocket mode, perform anti-mistouch operation in pocket mode.
[0247] It should be understood that the folding device 1500 may specifically be the folding device in the above embodiments, or the functions of the folding device in the above embodiments may be integrated into the folding device 1500. The folding device 1500 may be used to execute the various steps and / or processes corresponding to the folding device in the above method embodiments. Optionally, the memory 1502 may include read-only memory and random access memory, and provide instructions and data to the processor 1501. A portion of the memory 1502 may also include non-volatile random access memory. For example, the memory 1502 may also store device type information. The processor 1501 may be used to execute instructions stored in the memory, and when the processor executes the instructions, the processor 1501 may execute the various steps and / or processes corresponding to the folding device in the above method embodiments. It should be understood that in the embodiments of this application, the processor may be a central processing unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor. In implementation, the steps of the above methods can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The steps of the methods disclosed in the embodiments of this application can be directly implemented by a hardware processor, or by a combination of hardware and software modules in the processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The storage medium is located in memory, and the processor executes the instructions in the memory, combining with its hardware to complete the steps of the above methods. To avoid repetition, detailed descriptions are not provided here. Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application. Those skilled in the art will readily understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood from the several embodiments provided in this application that the disclosed systems, devices, and methods can be implemented in other ways.For example, the device embodiments described above are merely illustrative. For instance, the division of units is only a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual couplings, direct couplings, or communication connections may be through some interfaces, indirect couplings, or communication connections between devices or units, and may be electrical, mechanical, or other forms. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs. Additionally, the functional units in the various embodiments of this application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. If the function is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk. The above descriptions are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for preventing accidental touches, characterized in that, Applied to a folding device, the folding device including a proximity detection sensor, an ambient light sensor, and a pose sensor, the method includes: Determine the folding state corresponding to the folding device, wherein the folding state includes an unfolded state or a closed state; The proximity detection result determined by the proximity detection sensor is obtained, the ambient light data collected by the ambient light sensor is obtained, and the pose data collected by the pose sensor is obtained. When the folded state is the target folded state, it is determined whether the folding device is in pocket mode based on at least two of the proximity detection results, the ambient light data, and the pose data. When the folding device is in pocket mode, perform the anti-accidental touch operation in pocket mode.
2. The method according to claim 1, characterized in that, The step of determining whether the folding device is in pocket mode based on at least two of the proximity detection result, the ambient light data, and the pose data includes: The device orientation of the folding device is determined based on the pose data; If the proximity detection result, the ambient light data, and the device posture meet the first condition, then the folding device is determined to be in the pocket mode; The first condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device being in an inverted posture.
3. The method according to claim 1 or 2, characterized in that, The method further includes: The motion state of the folding device is determined based on the pose data, and the motion state includes a moving state or a non-moving state. If the proximity detection result, the ambient light data, and the motion state determine that the second condition is met, then the folding device is determined to be in the pocket mode. The second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being the in motion state.
4. The method according to claim 1, characterized in that, The method further includes: The device orientation of the folding device is determined based on the pose data; If the proximity detection result, the ambient light data, and the device posture determine that the third condition is met, then the folding device is determined to be in non-pocket mode. The third condition includes the proximity detection result indicating that an external object is moving away from the folding device, the ambient light data being greater than a second ambient light threshold, and / or the device being in a non-inverted posture.
5. The method according to claim 1, characterized in that, The method further includes: If the proximity detection result indicates that an external object is moving away from the folding device, then the folding device is determined to be in non-pocket mode.
6. The method according to claim 1, characterized in that, The folding device includes a lateral folding device, which includes a vertically arranged first hinge assembly; the target folding state includes the closed state of the lateral folding device; or... The folding device includes a longitudinal folding device, which includes a second hinge assembly arranged laterally, and the target folding state is the unfolded state or the closed state of the longitudinal folding device.
7. The method according to claim 6, characterized in that, The step of determining whether the folding device is in pocket mode based on at least two of the proximity detection result, the ambient light data, and the pose data includes: When the folding device is a horizontal folding device and the horizontal folding device is in the closed state, or when the folding device is a vertical folding device and the vertical folding device is in the unfolded state, the device posture and motion state of the folding device are determined according to the pose data. If the proximity detection result, the ambient light data, and the device posture determine that the first condition is met, then the folding device is determined to be in pocket mode; the first condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the device posture being an inverted posture. If the first condition is not met, and the second condition is determined to be met based on the proximity detection result, the ambient light data, and the motion state, then the folding device is determined to be in pocket mode. The second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being the "currently in motion" state.
8. The method according to claim 6, characterized in that, The method further includes: When the lateral folding device is in the unfolded state, it is determined that the lateral folding device is in a non-pocket mode.
9. The method according to claim 8, characterized in that, The method further includes: When the folding state of the lateral folding device switches from the closed state to the unfolded state, at least one of the ambient light sensor and the pose sensor is turned off.
10. The method according to claim 6, characterized in that, The folding device includes a longitudinally folding device. The step of determining whether the folding device is in pocket mode based on at least two of the proximity detection result, the ambient light data, and the pose data includes: When the longitudinal folding device is in the closed state, the motion state of the folding device is determined based on the pose data; the motion state includes a moving state or a non-moving state. If the proximity detection result, the ambient light data, and the motion data determine that the second condition is met, then the folding device is determined to be in pocket mode; the second condition includes the proximity detection result indicating that an external object is approaching the folding device, the ambient light data being less than or equal to a first ambient light threshold, and the motion state being the in motion state.
11. The method according to claim 1, characterized in that, The folding device further includes an opening / closing sensor, and determining the folding state of the folding device includes: The opening and closing detection result determined by the opening and closing sensor is obtained; the opening and closing detection result is used to indicate the opening and closing status of the foldable screen of the foldable device. The folding state of the folding device is determined based on the opening and closing detection results.
12. The method according to claim 1, characterized in that, The steps of acquiring the proximity detection result determined by the proximity detection sensor, acquiring the ambient light data collected by the ambient light sensor, and acquiring the pose data collected by the pose sensor include: The proximity detection result determined by the proximity detection sensor is obtained through the anti-accidental touch virtual sensor, the ambient light data collected by the ambient light sensor is obtained, and the pose data collected by the pose sensor is obtained. Based on at least two of the proximity detection results, the ambient light data, and the pose data, determining whether the folding device is in pocket mode includes: Using the anti-accidental touch virtual sensor, based on at least two of the proximity detection results, ambient light data, and pose data, it is determined whether the folding device is in pocket mode.
13. A device for preventing accidental touch, characterized in that, Applied to a folding device, the folding device includes a proximity detection sensor, an ambient light sensor, and a pose sensor, and the anti-accidental touch device includes: The processing module is used to determine the folding state of the folding device, the folding state including an unfolded state or a closed state; The acquisition module is used to acquire the proximity detection result determined by the proximity detection sensor, acquire the ambient light data collected by the ambient light sensor, and acquire the pose data collected by the pose sensor. The processing module is further configured to, when the folded state is the target folded state, determine whether the folding device is in pocket mode based on at least two of the proximity detection result, the ambient light data, and the pose data; and, when the folding device is in pocket mode, perform anti-mistouch operation in pocket mode.
14. A folding device, characterized in that, It includes a processor and a memory, the memory being used to store code instructions; the processor being used to execute the code instructions to perform the method as described in any one of claims 1 to 14.
15. A computer program product, said computer program product comprising computer program code, characterized in that, When the computer program code is run on a computer, it causes the computer to implement the method as described in any one of claims 1 to 12.