Folding angle detection method and device, equipment and storage medium

By identifying the axis direction in the terminal device and dynamically switching the detection strategy, the problem of inaccurate angle calculation in the vertical direction of the folding screen mobile phone is solved, the accuracy and stability of angle detection are improved, and the performance of the terminal device is improved.

CN119996557APending Publication Date: 2025-05-13GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311512359.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-11-13
Publication Date
2025-05-13

AI Technical Summary

Technical Problem

When the rotation axis is parallel to gravity, there is a problem of inaccurate angle calculations in existing folding screen mobile phones.

Method used

By identifying in the terminal device whether the rotation axis direction meets the preset vertical direction range, the detection strategy is dynamically switched, and the detection strategy is switched from the first detection strategy to the second detection strategy to determine the target angle between the first screen and the second screen.

Benefits of technology

It improves the accuracy and stability of the angle detection of the folding screen, and accurately identify the application mode of the terminal device according to the target angle, improving the performance of the terminal device.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119996557A_ABST
    Figure CN119996557A_ABST
Patent Text Reader

Abstract

The invention discloses a folding angle detection method and device, equipment and a storage medium, which are applied to foldable terminal equipment, and screens of the foldable terminal equipment comprise a first screen and a second screen. The method comprises the following steps: determining a rotating shaft direction of the terminal equipment under the condition that the terminal equipment performs angle detection by using a first detection strategy; when the rotating shaft direction of the terminal equipment accords with a preset vertical direction range, controlling a detection strategy of the terminal equipment to be switched from a first detection strategy to a second detection strategy, and determining a target angle between the first screen and the second screen based on the second detection strategy; wherein the first detection strategy is different from the second detection strategy. Therefore, the problem that the angle detection of the folding screen is inaccurate in the vertical direction in the prior art can be solved, the angle detection accuracy of the folding screen is improved, and the performance of the terminal equipment is further improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of terminal technology, and in particular to a folding angle detection method, device, equipment and storage medium. Background Art

[0002] With the development of screen technology, more and more manufacturers are launching foldable screen mobile phones. In the application process of foldable screen mobile phones, it is usually necessary to control the display state and operation mode of the foldable screen mobile phone according to the folding angle to match the user's usage habits, which requires real-time detection of the folding angle of the foldable screen.

[0003] In the related technology, folding angle detection solutions such as dual accelerometers, dual inertial measurement units, and magnetic sensors with magnets are usually used. However, when using these existing detection solutions to realize angle detection, if the rotation axis is parallel to gravity, there is a problem of inaccurate angle calculation. Summary of the invention

[0004] The present application proposes a folding angle detection method, device, equipment and storage medium, which can improve the accuracy of angle detection of the folding screen, thereby improving the performance of the terminal device.

[0005] The technical solution of this application is implemented as follows:

[0006] In a first aspect, an embodiment of the present application provides a folding angle detection method, which is applied to a foldable terminal device, and the screen of the foldable terminal device includes a first screen and a second screen; the method includes:

[0007] When the terminal device uses the first detection strategy to perform angle detection, determine the rotation axis direction of the terminal device;

[0008] When the rotation axis direction of the terminal device meets the preset vertical direction range, the detection strategy of the terminal device is controlled to switch from the first detection strategy to the second detection strategy, and based on the second detection strategy, a target angle between the first screen and the second screen is determined;

[0009] Among them, the first detection strategy is different from the second detection strategy.

[0010] In a second aspect, an embodiment of the present application provides an angle detection device, which is applied to a foldable terminal device, and the screen of the foldable terminal device includes a first screen and a second screen; the folding angle detection device includes a determination unit, a switching unit and a detection unit, wherein:

[0011] a determination unit, configured to determine the rotation axis direction of the terminal device when the terminal device uses the first detection strategy to perform angle detection;

[0012] A switching unit, configured to control the detection strategy of the terminal device to switch from the first detection strategy to the second detection strategy when the rotation axis direction of the terminal device meets the preset vertical direction range;

[0013] The detection unit is configured to determine a target angle between the first screen and the second screen based on a second detection strategy; wherein the first detection strategy is different from the second detection strategy.

[0014] In a third aspect, an embodiment of the present application provides a terminal device, including a memory and a processor, wherein:

[0015] A memory for storing computer programs that can be run on the processor;

[0016] A processor is used to execute the method described in the first aspect when running the computer program.

[0017] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by at least one processor, it implements the method described in the first aspect.

[0018] A folding angle detection method, device, equipment and storage medium provided in the embodiments of the present application are applied to a foldable terminal device, and the screen of the foldable terminal device includes a first screen and a second screen. When the terminal device uses the first detection strategy for angle detection, the rotation axis direction of the terminal device is determined; when the rotation axis direction of the terminal device meets the preset vertical direction range, the detection strategy of the terminal device is controlled to switch from the first detection strategy to the second detection strategy, and based on the second detection strategy, the target angle between the first screen and the second screen is determined; wherein the first detection strategy is different from the second detection strategy. In this way, by identifying whether the rotation axis direction of the terminal device meets the preset vertical direction range, it is determined whether to control the folding screen angle detection of the terminal device to switch to the second detection strategy; in this way, according to the target angle obtained by the second detection strategy, the problem of inaccurate folding screen angle detection in the vertical direction in the related technology is solved, and the accuracy and stability of the folding screen angle detection can be improved. Moreover, according to the target angle, the application mode corresponding to the terminal device can also be accurately identified, thereby improving the performance of the terminal device. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 A schematic diagram of the internal structure of a folding screen Figure 1 ;

[0020] Figure 2 A schematic diagram of the internal structure of a folding screen Figure 2 ;

[0021] Figure 3A A schematic diagram of a scenario in which a user's finger is away from the folding screen;

[0022] Figure 3B A schematic diagram of a scenario in which a user's finger approaches a folding screen;

[0023] Figure 3C A schematic diagram of a scenario in which a user touches a folding screen with a finger;

[0024] Figure 4 A schematic diagram of a coupling circuit between a user's finger and a folding screen surface;

[0025] Figure 5 It is a schematic diagram of the working principle of an acceleration sensor;

[0026] Figure 6 A schematic diagram of the change in capacitance when an object slides;

[0027] Figure 7 It is a schematic diagram of the working principle of an IMU sensor;

[0028] Figure 8 is a schematic diagram of a folding screen when the folding angle is 0 degrees;

[0029] Fig. 9 A schematic diagram of a folding screen when the folding angle is 180 degrees;

[0030] Fig.10 A schematic diagram of the folding angle calculation principle of a folding screen;

[0031] Fig.11 A schematic diagram of the structure of a terminal device with the x-axis perpendicular to the ground;

[0032] Fig.12 A schematic diagram of a structure of a terminal device with the y-axis perpendicular to the ground;

[0033] Fig.13 A schematic diagram of a flow chart of a folding angle detection method provided in an embodiment of the present application;

[0034] Fig.14 A schematic flow chart of another folding angle detection method provided in an embodiment of the present application;

[0035] Fig.15 A detailed flow chart of a folding angle detection method provided in an embodiment of the present application;

[0036] Fig.16 A detailed flowchart of another folding angle detection method provided in an embodiment of the present application;

[0037] Fig.17 A schematic diagram of the structure of a folding angle detection device provided in an embodiment of the present application;

[0038] Fig.18 A schematic diagram of the structure of a terminal device provided in an embodiment of the present application;

[0039] Fig.19 A schematic diagram of the composition structure of another terminal device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0040] In order to enable a more detailed understanding of the features and technical contents of the embodiments of the present application, the implementation of the embodiments of the present application is described in detail below in conjunction with the accompanying drawings. The attached drawings are for reference only and are not used to limit the embodiments of the present application.

[0041] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0042] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0043] It should also be pointed out that the terms "first\second\third" involved in the embodiments of the present application are only used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged in a specific order or sequence where permitted, so that the embodiments of the present application described here can be implemented in an order other than that illustrated or described here.

[0044] With the development of screen technology, more and more manufacturers are launching foldable screen mobile phones. These foldable screen mobile phones can be unfolded into one fold, two folds or even multiple folds, thus bringing users a wider and more shocking screen visual experience.

[0045] In the embodiments of the present application, the folding screens mostly use mutual capacitance and have the following characteristics:

[0046] (1) Using a driving method that transfers from one electrode group (e.g., row) to another electrode group (e.g., column). For example, the horizontal electrode (TX electrode) can send a touch excitation signal, and the vertical electrode (RX electrode) can receive the touch excitation signal.

[0047] (2) Figure 1 As shown, the folding screen has M*N touch blocks. Figure 2 As shown, two diagonally adjacent blocks need to be connected by a line ( Figure 2For M*N touch control blocks, the number of connection lines required is M+N.

[0048] (3) When the user's finger touches the folding screen, the coupling capacitance between the TX electrode and the RX electrode decreases, and the signal change is small. For example, when the user's finger touches the folding screen, the coupling capacitance between the TX electrode and the RX electrode is less than 0.1 pF.

[0049] For example, Figure 3A As shown in , when the user's finger is away from the folding screen, the mutual capacitance between the TX electrode and the RX electrode is constant; Figure 3B As shown in , when the user's finger approaches the folding screen, the mutual capacitance between the TX electrode and the RX electrode gradually decreases; Figure 3C As shown in FIG. 1 , when the user's finger touches the folding screen, the mutual capacitance between the TX electrode and the RX electrode is further reduced. By touching the folding screen with the user's finger, multi-touch can be achieved, but at this time the folding screen has a complex structure and requires multiple layers of film to achieve.

[0050] In the embodiment of the present application, when the user touches the folding screen with his finger, a coupling capacitor is formed between the user and the surface of the folding screen due to the human body electric field. For high-frequency current, the capacitor is a direct conductor and will affect the overall capacitance characteristics of the circuit. In addition, the touch integrated circuit (IC) can determine the user's touch position by identifying the capacitance change on the electrode, thereby making a response action.

[0051] For example, Figure 4 As shown, capacitor C1 generates current I1, and capacitor C3 generates current I3. When the user's finger is away from the folding screen, current I1 is equal to current I3; when the user's finger touches the folding screen, the user and the surface of the folding screen form a coupling capacitor C2, and the coupling capacitor C2 generates current I2, and I1 = I2 + I3. Therefore, the touch IC can determine the user's touch position by identifying the capacitance change of the coupling capacitor C2, and respond accordingly.

[0052] (4) The coupling capacitance between the TX electrode and the RX electrode is easily affected by other parameters, resulting in a small signal to noise ratio (SNR).

[0053] In the application process of foldable screen mobile phones, it is usually necessary to control the display status, operation method, etc. of the foldable screen mobile phone according to the folding angle to match the user's usage habits. This requires real-time detection of the folding angle of the foldable screen.

[0054] Taking the Android system as an example, in the Android system, the events after an object (such as a finger) contacts the touch screen are mainly divided into three states: pressing, lifting and moving.

[0055] Regarding the principle of capacitive touch screen recognition of objects, the capacitive sensing function of the touch screen can use the capacitive sensing principle of the touch screen to determine whether the object touches the touch screen and then report the state of the object, mainly referring to the state of objects such as fingers and styluses, which is mainly divided into pressing, lifting, and moving after pressing. Among them, the reported data may include coordinate data and event status.

[0056] Capacitive touch screens are mainly composed of transmitting channels and receiving channels. The capacitance data collected from the transmitting channel and the receiving channel to the ground is self-capacitance data, and the data collected from the transmitting channel and the receiving channel is mutual capacitance data. Currently, mutual capacitance data is used to determine whether the finger is in a pressed, moving, or lifted state. Self-capacitance data is used to determine other auxiliary functions, such as proximity sensing functions. In the touch screen area, the area where the touch reports coordinates is divided into an XY two-dimensional coordinate system.

[0057] As for the touch screen reporting principle, the touch screen uses the capacitive sensing principle of the touch screen. The touch screen recognizes the coordinates of the object by calculating the capacitance difference between the current object touching the touch screen and not touching the touch screen. By calculating the area of ​​the capacitance difference, the peak difference value of the area is found to determine whether it is within a certain preset reporting threshold, and then the reporting coordinates are sent from the terminal system.

[0058] For an accelerometer (G-sensor), an accelerometer is an object that measures the acceleration of a device, which is the rate of change of velocity. They are expressed in meters per second squared (m / s 2 ) or G force (g). On Earth, one G force here is equivalent to 9.8m / s 2 , but this does vary somewhat with altitude (and will have different values ​​on different planets due to changes in gravity). Accelerometers can be used to sense vibrations in a system or for directional applications.

[0059] Figure 5 Figure 1 is a schematic diagram of the working principle of an acceleration sensor. Figure 5 As shown, the acceleration sensor is a three-axis accelerometer, and X, Y, and Z correspond to the three measurement axes of the three-axis accelerometer. Here, we can first determine the three direction axes measured by the acceleration sensor: X, Y, and Z. These three direction axes are determined relative to the posture of the terminal device and are not absolute.

[0060] Figure 6 Figure 1 is a schematic diagram of the capacitance change when a mass block slides. Figure 6As shown, 11 represents a proofmass, 12 represents a spring, 13 represents a first fixed finger 1, and 14 represents a second fixed finger 2. Specifically, the first fixed finger 13 and the second fixed finger 14 are fixed on the base, and the proofmass 11 is movable. When the acceleration sensor senses an external force, the proofmass 11 moves in the corresponding direction, causing the capacitance c1 and the capacitance c2 to change. The acceleration can be determined by measuring the capacitance c1 and the capacitance c2.

[0061] That is to say, there is a corresponding mass block for each measuring axis inside the terminal device. It can be seen that when the acceleration changes, the mass block will slide in the corresponding direction, thereby causing the change of the two capacitance values. The calculation formula is: a=(c1-c2) / (c1+c2).

[0062] For the dual inertial measurement unit (IMU), IMU is the full name of inertial measurement unit, which is mainly used to detect and measure acceleration and rotational motion. Its principle is to use the law of inertia. These sensors range from ultra-small MEMS sensors to laser gyroscopes with very high measurement accuracy. Whether the size of MEMS sensors is only a few millimeters or the diameter of optical fiber devices is nearly half a meter, they all use this principle. The working principle of IMU is as follows Figure 7 As shown in the figure, in the Cartesian coordinate system, the z-axis represents the up and down direction, the y-axis represents the left and right direction, and the x-axis represents the front and back direction. This is true for both movement and rotation. The rotation of the z-axis represents rotation around the z-axis, which is called yaw. The rotation of the x-axis represents rotation around the x-axis, which is called roll. The rotation of the y-axis represents rotation around the y-axis, which is called pitch. The rotation values ​​around the three axes (pitch, yaw, roll) can be called pitch angle, yaw angle, and roll angle respectively.

[0063] For the angle detection of the folding screen touch screen, the main screen of the folding screen uses the touch screen as a sensor to collect capacitance data changes, and then calculates the angle between the first screen and the second screen according to the capacitance change. Figure 8 As shown; when the folding angle of the folding screen is 180 degrees, the folding screen at this time is as follows Fig. 9 As shown; In addition, the calculation principle of the folding angle of the folding screen is as follows Fig.10 As shown, the folding angle between the first screen and the second screen can be calculated according to the capacitance change of the preset channel between the first screen and the second screen.

[0064] In related technologies, the folding angle detection of folding screens mainly realizes multi-mode switching. Different angles of mobile phone screens correspond to different application modes, which are commonly as follows:

[0065] 0°: "Cover screen" mode;

[0066] 90-179°: The lower half of the screen acts as a tripod for multi-angle selfies or laptop-like operation;

[0067] 180°: Fully unfolded, like a normal phone or tablet.

[0068] In actual applications, more advanced functions can also be supported here, including smooth switching of applications, large and small screen interface layout, etc. Looking at mobile phone manufacturers, the folding angle detection solutions currently used can be roughly divided into the following three types: dual accelerometers (Acc), dual inertial measurement units (IMUs), and magnetic sensors with magnets. When using these existing solutions to achieve angle detection, acceleration and gyroscope sensors can be used to calculate gravity, and then gravity is used to calculate the angle. However, if the axis of rotation is parallel to gravity, a plane cannot be formed, resulting in inaccurate angle calculation. For example, if Fig.11 As shown in the figure, when the X-axis of the terminal device is perpendicular to the ground, the angle calculation may be inaccurate if the IMU solution is used for angle detection. Fig.12 As shown in the figure, when the Y-axis of the terminal device is perpendicular to the ground, the angle calculation may be inaccurate when the IMU solution is used for angle detection.

[0069] Based on this, an embodiment of the present application provides a folding angle detection method, which determines the rotation axis direction of the terminal device when the terminal device uses the first detection strategy for angle detection; when the rotation axis direction of the terminal device meets the preset vertical direction range, the detection strategy of the terminal device is controlled to switch from the first detection strategy to the second detection strategy, and based on the second detection strategy, the target angle between the first screen and the second screen is determined; wherein the first detection strategy is different from the second detection strategy. In this way, by identifying whether the rotation axis direction of the terminal device meets the preset vertical direction range, it is determined whether to control the folding screen angle detection of the terminal device to switch to the second detection strategy; in this way, the target angle obtained according to the second detection strategy solves the problem of inaccurate folding screen angle detection in the vertical direction in the related art, which can improve the accuracy and stability of folding screen angle detection, and according to the target angle, it can also accurately identify the application mode corresponding to the terminal device, thereby improving the performance of the terminal device.

[0070] The embodiments of the present application will be described in detail below with reference to the accompanying drawings.

[0071] In one embodiment of the present application, Fig.13A schematic diagram of a folding angle detection method provided in an embodiment of the present application. Fig.13 As shown, the method may include:

[0072] S1301: When the terminal device uses a first detection strategy to perform angle detection, determine the rotation axis direction of the terminal device.

[0073] S1302, when the axis direction of the terminal device meets the preset vertical direction range, control the detection strategy of the terminal device to switch from the first detection strategy to the second detection strategy, and determine the target angle between the first screen and the second screen based on the second detection strategy.

[0074] It should be noted that, in the embodiments of the present application, the folding angle detection method can be applied to a folding angle detection device, or a terminal device integrated with the device. The terminal device can be implemented in various forms, for example, the terminal device can include such as a smart phone, a tablet computer, a laptop computer, a PDA, a portable media player (PMP), a navigation device, a wearable device, etc., which are not limited here.

[0075] It should also be noted that in the embodiment of the present application, the folding angle detection method is specifically applied to a foldable terminal device, and the screen of the foldable terminal device may include a first screen and a second screen. The folding angle here refers to the angle between the first screen and the second screen, so the folding angle can also be called the "opening and closing angle". In addition, for a foldable terminal device, its screen can also be called a "folding screen".

[0076] In a possible application scenario, when a user uses a terminal device with a foldable screen, in order to enable the terminal device to realize different functions, the foldable screen is usually folded. In this process, the terminal device performs different operations according to the change of the folding angle. For example, the terminal device can be a mobile phone with a foldable screen. When the foldable screen of the mobile phone is in a closed state, that is, when the folding angle is 0 degrees (such as Figure 8 As shown in the figure, if the user wants to watch a video on the large screen, the user can unfold the folding screen. When the folding screen is unfolded by the user, the mobile phone can detect the folding angle of the folding screen, and light up the folding screen when it is detected that the folding angle of the folding screen is greater than or equal to the first preset angle; when it is detected that the folding screen is fully unfolded, that is, when the folding angle is detected to be 180 degrees, the desktop of the mobile phone is displayed in full screen on the folding screen, as shown in the figure. Fig. 9As shown in the figure, the user can trigger the video application on the desktop of the mobile phone, so that the mobile phone can play the video through the folding screen. If the user closes the folding screen, then during the closing process of the folding screen, if the mobile phone detects that the folding angle of the folding screen is less than or equal to the second preset angle, the folding screen can be turned off.

[0077] It is understandable that in the embodiment of the present application, the first detection strategy is different from the second detection strategy. The first detection strategy is the detection strategy enabled by default in the terminal device, but the folding angle detection is inaccurate in some scenarios, and it is necessary to switch from the first detection strategy to the second detection strategy.

[0078] Exemplarily, the first detection strategy may be a first type of sensor angle detection strategy, such as performing angle detection based on a sensor such as an inertial measurement sensor (ie, IMU) or an acceleration sensor (Acc).

[0079] Exemplarily, the second detection strategy may be a second type of sensor angle detection strategy, such as performing angle detection using a touch sensor, a magnetic sensor, a Hall sensor, or the like.

[0080] Here, if the terminal device is in a vertical state, that is, the rotation axis direction of the terminal device meets the preset vertical direction range, the angle detection accuracy corresponding to the second type of sensor angle detection strategy is higher than the angle detection accuracy corresponding to the first type of sensor angle detection strategy.

[0081] That is to say, in the embodiment of the present application, the first type of sensor may include any one of an inertial measurement sensor, an acceleration sensor, etc., and the second type of sensor may include any one of a touch sensor, a magnetic sensor, a Hall sensor, etc. In addition, for the touch sensor, the touch screen is mainly regarded as a sensor, and then the angle detection is performed based on the capacitance change of the touch screen, so the touch sensor may also be called a "touch screen sensor", "touch control sensor", etc.

[0082] In a specific embodiment, the first detection strategy can be an angle detection strategy based on an inertial measurement sensor (referred to as "IMU sensor angle detection strategy"). At this time, the angle detection is stable, but the cost is high and it is not accurate in the vertical direction of the terminal device; the second detection strategy can be an angle detection strategy based on a touch sensor (referred to as "touch sensor angle detection strategy"). At this time, the angle detection consumes power, but can save costs, but the disadvantage is that the detection accuracy is limited. However, it should be noted that the first detection strategy and the second detection strategy can also be two other different detection strategies, which are not limited here.

[0083] In some embodiments, see Fig.14After step S1301, the method may further include:

[0084] S1303: When the rotation axis direction of the terminal device does not conform to the preset vertical direction range, close the second detection strategy, and determine the target angle between the first screen and the second screen based on the first detection strategy.

[0085] It should be noted that in the embodiment of the present application, when the first detection strategy is the first type of sensor angle detection strategy, if the axis of the terminal device is perpendicular to the ground, if the first type of sensor angle detection strategy is used at this time, there may be a problem of inaccurate angle detection. Therefore, when the terminal device uses the first type of sensor angle detection strategy for angle detection, it is first identified whether the axis direction of the terminal device is within the preset vertical direction range.

[0086] It should also be noted that in the embodiment of the present application, a preset sensor is provided on each screen of the terminal device. When the terminal device uses the first type of sensor angle detection strategy for angle detection, data is collected based on the preset sensors provided on each screen to obtain respective posture data.

[0087] It should also be noted that, in the embodiments of the present application, a first posture sensor is provided on the first screen, and a second posture sensor is provided on the second screen. Accordingly, in some embodiments, it may include: collecting data through the first posture sensor to obtain first posture data of the first screen; and collecting data through the second posture sensor to obtain second posture data of the second screen.

[0088] Exemplarily, taking the IMU sensor as an example, according to the IMU sensor set on the first screen, first posture data can be collected, which may include first acceleration data and first gyroscope data; according to the IMU sensor set on the second screen, second posture data can be collected, which may include second acceleration data and second gyroscope data.

[0089] That is to say, when the terminal device uses the first type of sensor angle detection strategy to perform angle detection, the terminal device can periodically collect posture data of the first type of sensor to obtain first collected data based on the first detection strategy.

[0090] In some embodiments, the preset sensor includes: a first posture sensor set on the first screen, and / or a second posture sensor set on the second screen. The method may include: obtaining acceleration data collected by the preset sensor, and determining the rotation axis direction data corresponding to the acceleration data in the device coordinates; wherein, according to the rotation axis direction data corresponding to the acceleration data in the device coordinates, identifying whether the rotation axis direction of the terminal device meets the preset vertical direction range.

[0091] In a specific implementation, the method may include: obtaining first acceleration data collected by a first posture sensor on the first screen, and determining the axis direction data corresponding to the first acceleration data in the device coordinates; based on the axis direction data corresponding to the first acceleration data in the device coordinates, identifying whether the axis direction of the terminal device is within a preset vertical direction range.

[0092] In another specific implementation, the method may include: obtaining second acceleration data collected by a second posture sensor on the second screen, and determining the axis direction data corresponding to the second acceleration data in the device coordinates; based on the axis direction data corresponding to the second acceleration data in the device coordinates, identifying whether the axis direction of the terminal device is within a preset vertical direction range.

[0093] In another specific implementation, the method may include: obtaining first acceleration data collected by a first posture sensor on a first screen, and determining the rotation axis direction data corresponding to the first acceleration data in device coordinates; and obtaining second acceleration data collected by a second posture sensor on a second screen, and determining the rotation axis direction data corresponding to the second acceleration data in device coordinates; based on the rotation axis direction data corresponding to the first acceleration data in device coordinates and the rotation axis direction data corresponding to the second acceleration data in device coordinates, identifying whether the rotation axis direction of the terminal device meets a preset vertical direction range.

[0094] It should be noted that in the embodiment of the present application, no matter what posture the terminal device is in, the direction of the earth's gravitational acceleration will not change. For the first acceleration data or the second acceleration data, it can be decomposed into x, y, and z three-axis components in the device coordinate system. In this way, according to the x, y, and z three-axis components of the first acceleration data or the second acceleration data, it can be identified whether the rotation axis direction of the terminal device meets the preset vertical direction range.

[0095] It should also be noted that, in the embodiment of the present application, the rotation axis of the terminal device is the central bearing of the folding screen. Fig.11 As shown, the terminal device has a structure in which the rotation axis direction is the y-axis. Fig.12 shown.

[0096] In some embodiments, identifying whether the rotation axis direction of the terminal device meets a preset vertical direction range according to the rotation axis direction data corresponding to the acceleration data in the device coordinates may include:

[0097] If the rotation axis direction data corresponding to the acceleration data in the device coordinates meets the preset conditions, it is determined that the rotation axis direction of the terminal device meets the preset vertical direction range;

[0098] If the rotation axis direction data corresponding to the acceleration data in the device coordinates does not meet the preset conditions, it is determined that the rotation axis direction of the terminal device does not meet the preset vertical direction range.

[0099] It should be noted that in the embodiment of the present application, the preset condition is a judgment condition for measuring whether the terminal device is in a vertical state, or in other words, the preset condition is a judgment condition for measuring whether the rotation axis direction of the terminal device meets the preset vertical direction range. Exemplarily, the preset condition can be set to around ±1G, but is not specifically limited.

[0100] In a possible implementation, when the rotation axis direction of the terminal device is the y-axis, if the y-axis direction data corresponding to the acceleration data in the device coordinates meets the preset conditions, it is determined that the rotation axis direction of the terminal device meets the preset vertical direction range, indicating that the terminal device is in a vertical state. Exemplarily, if the rotation axis of the terminal device is the y-axis, and the y-axis direction data corresponding to the acceleration data in the device coordinates is near ±1G, it is determined that the rotation axis direction of the terminal device meets the preset vertical direction range.

[0101] It should also be noted that when the rotation axis direction of the terminal device is the y-axis, if the y-axis direction data corresponding to the acceleration data in the device coordinates does not meet the preset conditions, it is determined that the rotation axis direction of the terminal device does not meet the preset vertical direction range, that is, it indicates that the terminal device is not in a vertical state. Exemplarily, if the rotation axis of the terminal device is the y-axis, but the y-axis direction data corresponding to the acceleration data in the device coordinates is not near ±1G, then it is determined that the rotation axis direction of the terminal device does not meet the preset vertical direction range.

[0102] In another possible implementation, when the rotation axis direction of the terminal device is the x-axis, if the x-axis direction data corresponding to the acceleration data in the device coordinates meets the preset conditions, it is determined that the rotation axis direction of the terminal device meets the preset vertical direction range, indicating that the terminal device is in a vertical state. Exemplarily, if the rotation axis of the terminal device is the x-axis, and the x-axis direction data corresponding to the acceleration data in the device coordinates is near ±1G, it is determined that the rotation axis direction of the terminal device meets the preset vertical direction range.

[0103] It should also be noted that when the rotation axis direction of the terminal device is the x-axis, if the x-axis direction data corresponding to the acceleration data in the device coordinates does not meet the preset conditions, it is determined that the rotation axis direction of the terminal device does not meet the preset vertical direction range, that is, it indicates that the terminal device is not in a vertical state. Exemplarily, if the rotation axis of the terminal device is the x-axis, but the x-axis direction data corresponding to the acceleration data in the device coordinates is not near ±1G, it is determined that the rotation axis direction of the terminal device does not meet the preset vertical direction range.

[0104] In an embodiment of the present application, the above-mentioned acceleration data may be collected only through the first posture sensor on the first screen, or may be collected only through the second posture sensor on the second screen, or may be collected jointly by the first posture sensor on the first screen and the second posture sensor on the second screen, and no specific limitation is made here.

[0105] In some embodiments, when the first detection strategy is a first type of sensor angle detection strategy, determining the target angle between the first screen and the second screen based on the first detection strategy may include: acquiring first acquisition data obtained based on the first detection strategy; performing angle detection based on the first acquisition data to determine the target angle.

[0106] It should be noted that, in an embodiment of the present application, when performing angle detection based on the first collected data to determine the target angle, it can include: determining a first gravitational acceleration based on first posture data collected by a first posture sensor arranged on the first screen, and determining a first angle between the first screen and a preset gravity plane based on the first gravitational acceleration; determining a second gravitational acceleration based on second posture data collected by a second posture sensor arranged on the second screen, and determining a second angle between the second screen and the preset gravity plane based on the second gravitational acceleration; and then determining the target angle between the first screen and the second screen based on the first angle and the second angle.

[0107] Thus, in the embodiment of the present application, the first gravity acceleration is determined according to the first posture data, and the first gravity acceleration can be determined by fusing the first acceleration data in the first posture data with the first gyroscope data. Similarly, the second gravity acceleration is determined according to the second posture data, and the second gravity acceleration can be determined by fusing the second acceleration data in the second posture data with the second gyroscope data.

[0108] It should also be noted that, in the embodiment of the present application, determining the first angle between the first screen and the preset gravity plane based on the first gravity acceleration may include: determining the three-axis components of the first gravity acceleration in the device coordinates, and calculating the angle based on the three-axis components corresponding to the first gravity acceleration, to determine the first angle between the first screen and the preset gravity plane. Similarly, determining the second angle between the second screen and the preset gravity plane based on the second gravity acceleration may include: determining the three-axis components of the second gravity acceleration in the device coordinates, and calculating the angle based on the three-axis components corresponding to the second gravity acceleration, to determine the second angle between the second screen and the preset gravity plane. Then, by adding the first angle and the second angle, the target angle between the first screen and the second screen can be obtained.

[0109] In some embodiments, when the second detection strategy is a second type of sensor angle detection strategy, determining the target angle between the first screen and the second screen based on the second detection strategy may include: acquiring second acquisition data obtained based on the second detection strategy; performing angle detection based on the second acquisition data to determine the target angle.

[0110] In a possible implementation, taking the second type of sensor as a touch sensor as an example, the screen of the terminal device mainly uses the touch screen as a sensor to collect changes in capacitance, which can specifically include: obtaining the capacitance change of the current touch screen; performing angle detection based on the capacitance change to determine the target angle between the first screen and the second screen.

[0111] It should also be noted that, in the embodiment of the present application, for the touch screen, a first channel is set on the first screen, and a second channel is set on the second screen. Accordingly, in some embodiments, obtaining the capacitance change of the currently acquired touch screen may include: detecting the capacitance parameter values ​​of the first channel and the second channel; and determining the capacitance change according to the difference between the capacitance parameter value and the reference parameter value.

[0112] Here, the first channel may be a transmitting channel, and the second channel may be a receiving channel; or, the first channel may be a receiving channel, and the second channel may be a transmitting channel.

[0113] Here, the capacitance parameter value may include a self-capacitance parameter value and / or a mutual capacitance parameter value, wherein the self-capacitance parameter value may be the capacitance data of the collected transmitting channel and the receiving channel to the ground, and the mutual capacitance parameter value may be the capacitance data between the collected transmitting channel and the receiving channel.

[0114] In another possible implementation, taking the second type of sensor as a Hall sensor as an example, in this case, a first Hall sensor is provided on the first screen of the terminal device, and a second Hall sensor is provided on the second screen of the terminal device. When performing angle detection according to the second collected data and determining the target angle, it can specifically include: determining a first magnetic induction intensity value according to the first Hall sensor data, and determining a first angle between the first screen and a preset gravity plane according to the first magnetic induction intensity value and the mapping relationship between the magnetic induction intensity and the angle; determining a second magnetic induction intensity value according to the second Hall sensor data, and determining a second angle between the second screen and a preset gravity plane according to the second magnetic induction intensity value and the mapping relationship between the magnetic induction intensity and the angle; determining a target angle between the first screen and the second screen according to the first angle and the second angle.

[0115] It should be noted that in the embodiment of the present application, according to the first Hall sensor set on the first screen, the first Hall sensor data can be collected, and the first magnetic induction intensity value can be further determined based on the first Hall sensor data; according to the second Hall sensor set on the second screen, the second Hall sensor data can be collected, and the second magnetic induction intensity value can be further determined based on the second Hall sensor data.

[0116] It should also be noted that, in the embodiments of the present application, the mapping relationship between the magnetic induction intensity and the angle can be a linear mapping relationship or a nonlinear mapping relationship, which is not specifically limited here.

[0117] In this way, based on the first magnetic induction intensity value and the mapping relationship, the first angle between the first screen and the preset gravity plane can be determined; based on the second magnetic induction intensity value and the mapping relationship, the second angle between the second screen and the preset gravity plane can be determined; and then the first angle and the second angle are added to determine the target angle between the first screen and the second screen.

[0118] It should also be noted that in the embodiments of the present application, whether based on the first type of sensor angle detection strategy or the second type of sensor angle detection strategy, after obtaining a more accurate target angle, the corresponding application mode can be determined according to the target angle. For example, when the target angle is 0°, the application mode can be the cover screen mode; when the target angle is 180°, the application mode can be the fully expanded mode; when the target angle is 90-179°, the application mode can be the tripod mode (specifically, the lower half of the screen acts as a tripod for multi-angle selfies or laptop-like operations), etc.; even according to the target angle, more advanced functions can be supported, such as smooth switching of applications, large and small screen interface arrangement, etc., thereby realizing multi-mode switching of terminal devices.

[0119] An embodiment of the present application provides a folding angle detection method. When a terminal device uses a first detection strategy for angle detection, by identifying whether the rotation axis direction of the terminal device meets the preset vertical direction range, when the rotation axis direction of the terminal device meets the preset vertical direction range, the folding screen angle detection of the terminal device is controlled to switch to a second detection strategy to obtain a target angle; thereby solving the problem of inaccurate folding screen angle detection in the vertical direction in related technologies, and being able to improve the accuracy and stability of folding screen angle detection, and based on the target angle, it is also possible to accurately identify the application mode corresponding to the terminal device, thereby improving the performance of the terminal device.

[0120] In another embodiment of the present application, based on the folding angle detection method described in the above embodiment, Fig.15A detailed flow chart of a folding angle detection method provided in an embodiment of the present application. Fig.15 As shown, the detailed process may include:

[0121] S1501, identifying whether the rotation axis direction of the terminal device meets a preset vertical direction range.

[0122] In the embodiment of the present application, how to identify whether the axis direction of the terminal device is within the preset vertical direction range, the specific identification method is similar to the steps of the aforementioned embodiment, and will not be described in detail here.

[0123] In the embodiment of the present application, the terminal device has a foldable function, and the screen of the foldable terminal device may include a first screen and a second screen. In addition, assuming that the second detection strategy is an angle detection strategy based on a touch sensor, the terminal device may also include a touch service module, a touch bottom layer module, and a touch angle detection module, which are used to determine whether the second detection strategy is turned on according to the instruction generated by the recognition result, and whether to execute the second detection strategy to determine the target angle between the first screen and the second screen.

[0124] S1502: When the recognition result indicates that the direction of the rotation axis is within a preset vertical direction range, a first instruction is sent to the touch service module.

[0125] S1503, based on the first instruction, controlling the touch control bottom layer module to execute and start the second detection strategy, and switching from the first detection strategy to the second detection strategy.

[0126] In an embodiment of the present application, if the axis direction of the terminal device is within the preset vertical direction range, a first instruction can be sent to the touch service module; based on the first instruction, the touch underlying module is controlled to execute the steps of starting the second detection strategy and switching from the first detection strategy to the second detection strategy.

[0127] That is to say, when the axis direction of the terminal device meets the preset vertical direction range, the first instruction is sent to notify the touch service module; then the touch service module notifies the touch underlying module to perform corresponding actions according to the first instruction, specifically, the touch underlying module turns on the second detection strategy, and switches from the first detection strategy to the second detection strategy to determine the target angle between the first screen and the second screen. It should be noted that after switching from the first detection strategy to the second detection strategy, the first detection strategy can also be turned off at this time.

[0128] In some embodiments, the method may further include: after the touch bottom layer module starts the second detection strategy, controlling the touch angle detection module to obtain the collected capacitance change, and determining the target angle between the first screen and the second screen according to the capacitance change.

[0129] That is to say, when the axis direction of the terminal device is within the preset vertical range, the touch underlying module starts the second detection strategy according to the first instruction. At this time, the touch angle detection function can be executed to determine the target angle through the collected capacitance change, and then the touch angle detection module reports the target angle to the system service module of the terminal device.

[0130] S1504: When the recognition result indicates that the rotation axis direction does not conform to the preset vertical direction range, send a second instruction to the touch service module.

[0131] S1505: Based on the second instruction, control the touch control underlying module to execute the second detection strategy.

[0132] In an embodiment of the present application, if the axis direction of the terminal device does not conform to the preset vertical direction range, a second instruction can be sent to the touch service module; based on the second instruction, the touch underlying module is controlled to execute the step of closing the second detection strategy.

[0133] That is to say, when the axis direction of the terminal device does not conform to the preset vertical direction range, a second instruction is sent to notify the touch service module; then the touch service module notifies the touch underlying module to perform corresponding actions according to the second instruction, specifically, the touch underlying module turns off the second detection strategy, and is still based on the first detection strategy to determine the target angle between the first screen and the second screen.

[0134] In some embodiments, the method may further include: after the touch bottom layer module turns off the second detection strategy, controlling the touch angle detection module to stop the angle detection signal.

[0135] That is to say, when the axis direction of the terminal device does not meet the preset vertical direction range, the touch bottom layer module turns off the second detection strategy according to the second instruction, and the touch angle detection function can be turned off at this time, and the angle detection signal is stopped by the touch angle detection module. It should be noted that only the second detection strategy is stopped here, and the target angle between the first screen and the second screen can still be determined based on the first detection strategy.

[0136] The embodiments of the present application provide a folding angle detection method. The specific implementation of the aforementioned embodiments is elaborated in detail through the aforementioned embodiments. It can be seen that through the technical scheme of the aforementioned embodiments, it is dynamically identified whether the rotation axis direction of the terminal device is within the preset vertical direction range, thereby solving the problem of inaccurate vertical angle detection of the folding screen in the related technology, and can improve the accuracy and stability of the folding screen angle detection, and according to the target angle, it can also accurately identify the application mode corresponding to the terminal device, thereby improving the performance of the terminal device.

[0137] In another embodiment of the present application, based on the folding angle detection method of the aforementioned embodiment, taking the first detection strategy as the IMU sensor angle detection strategy and the second detection strategy as the touch sensor angle detection strategy as an example, Fig.16 A detailed flow chart of another folding angle detection method provided in an embodiment of the present application. Fig.16 As shown, the detailed process may include:

[0138] S1601, the terminal device collects IMU sensor data regularly.

[0139] S1602, identifying whether the rotation axis direction of the terminal device is within a preset vertical direction range.

[0140] S1603: If the rotation axis direction is within a preset vertical direction range, a first instruction is sent to notify the touch service module.

[0141] S1604: If the axis direction does not conform to the preset vertical direction range, a second instruction is sent to notify the touch service module.

[0142] S1605: The touch service module dynamically notifies the touch underlying module whether to switch the touch angle detection function according to the first instruction / the second instruction.

[0143] S1606: If the touch bottom layer module determines that the instruction is the first instruction, the touch angle detection function is started.

[0144] S1607: Based on the touch angle detection function, the touch angle detection module collects the capacitance change required for angle detection and calculates the target angle.

[0145] S1608: Report the target angle to the system service module through the touch angle detection module.

[0146] S1609: If the touch bottom layer module determines that the instruction is the second instruction, the touch angle detection function is disabled.

[0147] S1610, based on the touch angle detection function, stop the angle detection signal.

[0148] It should be noted that in an embodiment of the present application, an optimization method and system for the fusion of IMU sensor angle detection and touch sensor angle detection based on a folding screen of a terminal device is proposed. Among them, the system at least includes a folding screen, a touch service module, a touch underlying module, a touch angle detection module and a system service module. Here, the folding screen may include a first screen and a second screen, and the touch service module, the touch underlying module and the touch angle detection module may be used to determine whether the touch sensor angle detection strategy is turned on according to the instructions generated by the recognition result, and whether to execute the touch sensor angle detection strategy to determine the target angle. In addition, the system is set in the terminal device, so it can also be called a "terminal system."

[0149] It should also be noted that in the embodiment of the present application, when the terminal device performs IMU sensor angle detection, if the axis direction of the terminal device is within the preset vertical direction range, the touch sensor angle detection strategy is switched. If the axis direction of the terminal device does not meet the preset vertical direction range, the touch sensor angle detection strategy is turned off.

[0150] In a specific implementation, the process may specifically include:

[0151] Step 1: The terminal device collects IMU sensor data regularly.

[0152] Among them, the IMU sensor is a dual inertial measurement unit, which is mainly used to detect and measure acceleration and rotational motion. Its principle is realized by the law of inertia. These sensors range from ultra-small MEMS sensors to laser gyroscopes with very high measurement accuracy. Whether the size of MEMS sensors is only a few millimeters or the diameter of optical fiber devices is nearly half a meter, they all use this principle.

[0153] Step 2: The terminal device obtains the current IMU sensor data to identify whether the rotation axis direction of the terminal device is within a preset vertical direction range.

[0154] The rotating shaft of the terminal device is the central bearing of the folding screen. Exemplarily, the preset vertical direction range may include:

[0155] When the rotation axis is the y-axis, if the acceleration y-axis (that is, the aforementioned "acceleration data in the y-axis direction data in the device coordinates") is around ±1G, it means that the terminal device is in a vertical state, that is, the rotation axis direction of the terminal device is in line with the preset vertical direction range.

[0156] In the case where the rotation axis is the x-axis, if the acceleration x-axis (i.e. the aforementioned "x-axis direction data of acceleration data in device coordinates") is ±If it is around 1G, it means that the terminal device is in a vertical state, that is, the rotation axis direction of the terminal device is within the preset vertical direction range.

[0157] Step 3: If the axis direction of the terminal device meets the preset vertical direction range, a first instruction is sent to notify the touch service module. And / or if the axis direction of the terminal device does not meet the first preset vertical direction range, a second instruction is sent to notify the touch service module.

[0158] Step 4: The touch service module dynamically notifies the touch underlying module whether to switch the touch angle detection function according to the first / second instruction.

[0159] Step 5: If the touch bottom layer module determines that it is the first instruction, the touch angle detection function is started. Here, "start" can also be called "open" or "turn on", that is, turn on the touch angle detection function, or turn on the touch angle detection function.

[0160] For the touch angle detection function, the capacitance signal required for angle detection can be collected, and the target angle between the first screen and the second screen can be calculated. The capacitance signal can represent the capacitance change between the first screen and the second screen. The touch angle detection module then reports the target angle to the terminal system.

[0161] Step 6: If the touch bottom layer module determines that the instruction is the second instruction, the touch angle detection function is disabled.

[0162] Among them, for the touch angle detection function, the angle detection signal is stopped at this time. It should be noted that here only the touch sensor angle detection strategy is stopped, and the target angle between the first screen and the second screen is still determined based on the IMU sensor angle detection strategy.

[0163] In the embodiments of the present application, the specific implementation of the aforementioned embodiments is elaborated in detail through the above embodiments. It can be seen that according to the technical scheme of the aforementioned embodiments, it is dynamically identified whether the rotation axis direction of the terminal device is in the vertical direction of the folding screen, thereby solving the problem of inaccurate vertical angle calculation of the folding screen in the related technology. By dynamically switching the angle detection strategy of the terminal device, the accuracy and stability of the folding screen angle detection can be improved, thereby improving the performance of the terminal device.

[0164] In another embodiment of the present application, Fig.17 This is a schematic diagram of the structure of a folding angle detection device provided in an embodiment of the present application. Fig.17 As shown, the folding angle detection device 170 is applied to a foldable terminal device, and the screen of the foldable terminal device includes a first screen and a second screen. The folding angle detection device 170 may include a determination unit 1701, a switching unit 1702 and a detection unit 1703, wherein:

[0165] The determining unit 1701 is configured to determine the rotation axis direction of the terminal device when the terminal device uses the first detection strategy to perform angle detection;

[0166] The switching unit 1702 is configured to control the detection strategy of the terminal device to switch from the first detection strategy to the second detection strategy when the rotation axis direction of the terminal device meets the preset vertical direction range;

[0167] The detection unit 1703 is configured to determine a target angle between the first screen and the second screen based on a second detection strategy; wherein the first detection strategy is different from the second detection strategy.

[0168] In some embodiments, the detection unit 1703 is further configured to turn off the second detection strategy when the axis direction of the terminal device does not conform to a preset vertical direction range, and determine the target angle between the first screen and the second screen based on the first detection strategy.

[0169] In some embodiments, the detection unit 1703 is further configured to obtain first collected data based on the first detection strategy; and perform angle detection according to the first collected data to determine the target angle.

[0170] In some embodiments, see Fig.17 The folding angle detection device 170 may also include an identification unit 1704, which is configured to obtain acceleration data collected by a preset sensor and determine the rotation axis direction data corresponding to the acceleration data in the device coordinates when the terminal device uses the first detection strategy for angle detection; wherein the preset sensor includes: a first posture sensor set on the first screen, and / or, a second posture sensor set on the second screen; and according to the rotation axis direction data corresponding to the acceleration data in the device coordinates, identify whether the rotation axis direction of the terminal device meets the preset vertical direction range.

[0171] In some embodiments, the identification unit 1704 is further configured to determine that the axis direction of the terminal device is within a preset vertical direction range when the axis direction data meets the preset conditions; when the axis direction data does not meet the preset conditions, determine that the axis direction of the terminal device does not meet the preset vertical direction range.

[0172] In some embodiments, the detection unit 1703 is further configured to obtain second collected data based on a second detection strategy; and perform angle detection according to the second collected data to determine the target angle.

[0173] In some embodiments, the terminal device also includes a touch service module and a touch underlying module; the detection unit 1703 is also configured to send a first instruction to the touch service module when the axis direction of the terminal device is within a preset vertical direction range; and based on the first instruction, control the touch underlying module to execute the steps of starting the second detection strategy and switching from the first detection strategy to the second detection strategy.

[0174] In some embodiments, the detection unit 1703 is further configured to send a second instruction to the touch service module when the axis direction of the terminal device does not conform to a preset vertical direction range; and based on the second instruction, control the touch underlying module to execute the step of closing the second detection strategy.

[0175] Those skilled in the art should understand that the relevant description of the above-mentioned folding angle detection device in the embodiment of the present application can be understood by referring to the relevant description of the folding angle detection method in the embodiment of the present application.

[0176] In yet another embodiment of the present application, Fig.18 A schematic diagram of the structure of a terminal device provided in an embodiment of the present application. Fig.18 As shown, the terminal device 180 may include: a communication interface 1801, a memory 1802 and a processor 1803; each component is coupled together via a bus system 1804. It is understood that the bus system 1804 is used to realize the connection and communication between these components. In addition to the data bus, the bus system 1804 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, Fig.18 Various buses are labeled as bus system 1804. Among them, the communication interface 1801 is used for receiving and sending signals in the process of sending and receiving information between other external network elements;

[0177] A memory 1802, used for storing a computer program that can be run on the processor 1803;

[0178] The processor 1803 is configured to execute, when running the computer program:

[0179] When the terminal device uses the first detection strategy for angle detection, the rotation axis direction of the terminal device is determined; when the rotation axis direction of the terminal device is within a preset vertical direction range, the detection strategy of the terminal device is controlled to switch from the first detection strategy to the second detection strategy, and based on the second detection strategy, the target angle between the first screen and the second screen is determined; wherein the first detection strategy is different from the second detection strategy.

[0180] It can be understood that the memory 1802 in the embodiment of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus random access memory (DRRAM). The memory 1802 of the systems and methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.

[0181] The processor 1803 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the processor 1803. The above-mentioned processor 1803 can be a general-purpose processor, a digital signal processor (Digital Signal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor to execute, or the hardware and software modules in the decoding processor are combined and executed. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 1802, and the processor 1803 reads the information in the memory 1802 and completes the steps of the above method in combination with its hardware.

[0182] It is understood that the embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or a combination thereof. For hardware implementation, the processing unit may be implemented in one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), general purpose processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in the present application, or a combination thereof.

[0183] For software implementation, the techniques described herein can be implemented by modules (e.g., procedures, functions, etc.) that perform the functions described herein. The software code can be stored in a memory and executed by a processor. The memory can be implemented in the processor or outside the processor.

[0184] In some embodiments, the processor 1803 is further configured to execute the steps of the method described in any one of the aforementioned embodiments when running the computer program.

[0185] In some embodiments, the present application also provides another terminal device composition, such as Fig.19 As shown, the terminal device 180 may include a folding screen 1901 and a folding angle detection device 170 according to any one of the aforementioned embodiments. The folding screen 1901 may include a first screen and a second screen. The folding angle detection device 170 may be used to determine a target angle between the first screen and the second screen.

[0186] An embodiment of the present application provides a terminal device, which, for the scenario of folding screen angle detection, identifies whether the rotation axis direction of the terminal device is within a preset vertical direction range. If the rotation axis direction of the terminal device is within the preset vertical direction range, the folding screen angle detection of the terminal device is controlled to switch to a second detection strategy to obtain a target angle. This solves the problem of inaccurate vertical angle detection of the folding screen in the related art, can improve the accuracy and stability of the folding screen angle detection, and can also accurately identify the application mode corresponding to the terminal device according to the target angle, thereby improving the performance of the terminal device.

[0187] An embodiment of the present application also provides a computer-readable storage medium for storing a computer program.

[0188] In some embodiments, the computer-readable storage medium can be applied to the terminal device in the embodiments of the present application, and when the computer program is executed by at least one processor, it implements the corresponding processes implemented by the terminal device in the various methods of the embodiments of the present application. For the sake of brevity, they will not be repeated here.

[0189] An embodiment of the present application also provides a computer program product, including computer program instructions.

[0190] In some embodiments, the computer program product can be applied to the terminal device in the embodiments of the present application, and the computer program instructions enable the computer to execute the corresponding processes implemented by the terminal device in the various methods of the embodiments of the present application. For the sake of brevity, they will not be repeated here.

[0191] The embodiment of the present application also provides a computer program.

[0192] In some embodiments, the computer program can be applied to the terminal device in the embodiments of the present application. When the computer program runs on the computer, the computer executes the corresponding processes implemented by the terminal device in the various methods of the embodiments of the present application. For the sake of brevity, they will not be repeated here.

[0193] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed in this application can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0194] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and units can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0195] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms. The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the scheme of this embodiment.

[0196] In addition, each functional unit in each embodiment of the present 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.

[0197] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory, a random access memory, a magnetic disk, or an optical disk.

[0198] It should be noted that, in this application, the terms "include", "comprises" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "includes a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0199] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0200] The methods disclosed in several method embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments.

[0201] The features disclosed in several product embodiments provided in this application can be arbitrarily combined without conflict to obtain new product embodiments.

[0202] The features disclosed in several method or device embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments or device embodiments.

[0203] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A folding angle detection method, characterized in that: The method is applied to a foldable terminal device, wherein the screen of the foldable terminal device includes a first screen and a second screen; the method includes: When the terminal device uses a first detection strategy to perform angle detection, determining a rotation axis direction of the terminal device; When the rotation axis direction of the terminal device meets the preset vertical direction range, control the detection strategy of the terminal device to switch from the first detection strategy to the second detection strategy, and determine the target angle between the first screen and the second screen based on the second detection strategy; The first detection strategy is different from the second detection strategy.

2. The method according to claim 1, characterized in that The method further comprises: When the rotation axis direction of the terminal device does not conform to a preset vertical direction range, the second detection strategy is turned off, and based on the first detection strategy, a target angle between the first screen and the second screen is determined.

3. The method according to claim 2, characterized in that The determining a target angle between the first screen and the second screen based on the first detection strategy includes: Acquire first collected data obtained based on the first detection strategy; Angle detection is performed according to the first collected data to determine the target angle.

4. The method according to claim 1, characterized in that In the case where the terminal device uses the first detection strategy to perform angle detection, the method further includes: Acquire acceleration data collected by a preset sensor, and determine the rotation axis direction data corresponding to the acceleration data in the device coordinates; wherein the preset sensor includes: a first attitude sensor provided on the first screen, and / or a second attitude sensor provided on the second screen; According to the rotation axis direction data corresponding to the acceleration data in the device coordinates, it is identified whether the rotation axis direction of the terminal device meets the preset vertical direction range.

5. The method according to claim 4, characterized in that The step of identifying whether the rotation axis direction of the terminal device meets a preset vertical direction range according to the rotation axis direction data corresponding to the acceleration data in the device coordinates includes: When the rotation axis direction data meets a preset condition, determining that the rotation axis direction of the terminal device meets a preset vertical direction range; When the rotation axis direction data does not meet the preset condition, it is determined that the rotation axis direction of the terminal device does not meet the preset vertical direction range.

6. The method according to claim 1, characterized in that The determining a target angle between the first screen and the second screen based on the second detection strategy includes: Acquire second collected data obtained based on the second detection strategy; Angle detection is performed according to the second collected data to determine the target angle.

7. The method according to claim 1, characterized in that The terminal device further includes a touch service module and a touch bottom layer module; when the rotation axis direction of the terminal device meets the preset vertical direction range, the method further includes: Sending a first instruction to the touch service module; Based on the first instruction, the touch control underlying module is controlled to execute the steps of enabling the second detection strategy and switching from the first detection strategy to the second detection strategy.

8. The method according to claim 7, characterized in that When the rotation axis direction of the terminal device does not conform to a preset vertical direction range, the method further includes: Sending a second instruction to the touch service module; Based on the second instruction, the touch control underlying module is controlled to execute a step of closing the second detection strategy.

9. An angle detection device, characterized in that: Applicable to a foldable terminal device, wherein the screen of the foldable terminal device includes a first screen and a second screen; the folding angle detection device includes a determination unit, a switching unit and a detection unit, wherein: The determination unit is configured to determine the rotation axis direction of the terminal device when the terminal device uses a first detection strategy to perform angle detection; The switching unit is configured to control the detection strategy of the terminal device to switch from the first detection strategy to the second detection strategy when the rotation axis direction of the terminal device meets the preset vertical direction range; The detection unit is configured to determine a target angle between the first screen and the second screen based on the second detection strategy; wherein the first detection strategy is different from the second detection strategy.

10. A terminal device, characterized in that: comprising a memory and a processor, wherein: The memory is used to store a computer program that can be run on the processor; The processor is configured to execute the method according to any one of claims 1 to 8 when running the computer program.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by at least one processor, the method according to any one of claims 1 to 8 is implemented.