WO2023087832A1 - 合页角度的检测方法及相关设备 - Google Patents

合页角度的检测方法及相关设备 Download PDF

Info

Publication number
WO2023087832A1
WO2023087832A1 PCT/CN2022/115421 CN2022115421W WO2023087832A1 WO 2023087832 A1 WO2023087832 A1 WO 2023087832A1 CN 2022115421 W CN2022115421 W CN 2022115421W WO 2023087832 A1 WO2023087832 A1 WO 2023087832A1
Authority
WO
WIPO (PCT)
Prior art keywords
algorithm
hinge angle
screen
electronic device
common axis
Prior art date
Application number
PCT/CN2022/115421
Other languages
English (en)
French (fr)
Inventor
王鹏
贾现召
Original Assignee
荣耀终端有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 荣耀终端有限公司 filed Critical 荣耀终端有限公司
Priority to EP22871048.9A priority Critical patent/EP4207722A4/en
Publication of WO2023087832A1 publication Critical patent/WO2023087832A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/0206Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings
    • H04M1/0208Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings characterized by the relative motions of the body parts
    • H04M1/0214Foldable telephones, i.e. with body parts pivoting to an open position around an axis parallel to the plane they define in closed position
    • H04M1/0216Foldable in one direction, i.e. using a one degree of freedom hinge
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/16Constructional details or arrangements
    • G06F1/1613Constructional details or arrangements for portable computers
    • G06F1/1615Constructional details or arrangements for portable computers with several enclosures having relative motions, each enclosure supporting at least one I/O or computing function
    • G06F1/1616Constructional details or arrangements for portable computers with several enclosures having relative motions, each enclosure supporting at least one I/O or computing function with folding flat displays, e.g. laptop computers or notebooks having a clamshell configuration, with body parts pivoting to an open position around an axis parallel to the plane they define in closed position
    • G06F1/1618Constructional details or arrangements for portable computers with several enclosures having relative motions, each enclosure supporting at least one I/O or computing function with folding flat displays, e.g. laptop computers or notebooks having a clamshell configuration, with body parts pivoting to an open position around an axis parallel to the plane they define in closed position the display being foldable up to the back of the other housing with a single degree of freedom, e.g. by 360° rotation over the axis defined by the rear edge of the base enclosure
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/16Constructional details or arrangements
    • G06F1/1613Constructional details or arrangements for portable computers
    • G06F1/1633Constructional details or arrangements of portable computers not specific to the type of enclosures covered by groups G06F1/1615 - G06F1/1626
    • G06F1/1637Details related to the display arrangement, including those related to the mounting of the display in the housing
    • G06F1/1652Details related to the display arrangement, including those related to the mounting of the display in the housing the display being flexible, e.g. mimicking a sheet of paper, or rollable
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/16Constructional details or arrangements
    • G06F1/1613Constructional details or arrangements for portable computers
    • G06F1/1633Constructional details or arrangements of portable computers not specific to the type of enclosures covered by groups G06F1/1615 - G06F1/1626
    • G06F1/1675Miscellaneous details related to the relative movement between the different enclosures or enclosure parts
    • G06F1/1677Miscellaneous details related to the relative movement between the different enclosures or enclosure parts for detecting open or closed state or particular intermediate positions assumed by movable parts of the enclosure, e.g. detection of display lid position with respect to main body in a laptop, detection of opening of the cover of battery compartment
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/16Constructional details or arrangements
    • G06F1/1613Constructional details or arrangements for portable computers
    • G06F1/1633Constructional details or arrangements of portable computers not specific to the type of enclosures covered by groups G06F1/1615 - G06F1/1626
    • G06F1/1684Constructional details or arrangements related to integrated I/O peripherals not covered by groups G06F1/1635 - G06F1/1675
    • G06F1/1694Constructional details or arrangements related to integrated I/O peripherals not covered by groups G06F1/1635 - G06F1/1675 the I/O peripheral being a single or a set of motion sensors for pointer control or gesture input obtained by sensing movements of the portable computer
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3206Monitoring of events, devices or parameters that trigger a change in power modality
    • G06F1/3215Monitoring of peripheral devices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3234Power saving characterised by the action undertaken
    • G06F1/325Power saving in peripheral device
    • G06F1/3265Power saving in display device
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3234Power saving characterised by the action undertaken
    • G06F1/3287Power saving characterised by the action undertaken by switching off individual functional units in the computer system
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/0206Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings
    • H04M1/0208Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings characterized by the relative motions of the body parts
    • H04M1/0214Foldable telephones, i.e. with body parts pivoting to an open position around an axis parallel to the plane they define in closed position
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/0206Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings
    • H04M1/0241Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings using relative motion of the body parts to change the operational status of the telephone set, e.g. switching on/off, answering incoming call
    • H04M1/0243Portable telephones comprising a plurality of mechanically joined movable body parts, e.g. hinged housings using relative motion of the body parts to change the operational status of the telephone set, e.g. switching on/off, answering incoming call using the relative angle between housings
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/026Details of the structure or mounting of specific components
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/026Details of the structure or mounting of specific components
    • H04M1/0266Details of the structure or mounting of specific components for a display module assembly
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M2250/00Details of telephonic subscriber devices
    • H04M2250/12Details of telephonic subscriber devices including a sensor for measuring a physical value, e.g. temperature or motion
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Definitions

  • the present application relates to the technical field of folding screens, in particular to a hinge angle detection method and related equipment.
  • folding screen mobile phones With the gradual maturity of folding screen technology, there are more and more folding screen mobile phones on the market. In order to improve the user experience when using a folding screen mobile phone, many developers have developed a series of functions associated with the folding screen technology. For example, after the folding screen mobile phone is unfolded, the function of adaptively displaying and playing videos on the large screen is designed, and so on.
  • the application provides a hinge angle detection method and related equipment, the purpose of which is to obtain an accurate hinge angle.
  • the present application discloses a hinge angle detection method, which is applied to a foldable electronic device.
  • the folding screen of the foldable electronic device includes a first screen and a second screen.
  • the hinge angle detection method includes: Determine the state of motion of the electronic device, and the relative position of the common axis to the horizontal plane. Wherein, the common axis is the axis where the folding edge of the folding screen is located.
  • determine the target algorithm includes: an acceleration sensor algorithm, a gyroscope sensor algorithm, or a fusion algorithm.
  • the fusion algorithm is an algorithm for calculating the hinge angle by fusing the data of the acceleration sensor and the data of the gyroscope sensor.
  • the determined target algorithm is used to calculate the hinge angle of the electronic device.
  • the hinge angle is the angle between the first screen and the second screen.
  • the hinge angle detection method of the present application determines the target algorithm by determining the motion state of the foldable electronic device and the relative positional relationship between the common axis and the horizontal plane, and then uses the target algorithm to calculate the hinge angle, which can Get a more accurate hinge angle.
  • the motion state and the relative positional relationship between the common axis of the folding screen and the horizontal plane are taken into account, and the influence on the accuracy of calculating the hinge angle by different algorithms is taken into account, so that a more accurate calculation can be made.
  • the hinge angle is optimized for functions that require the use of hinge angles in electronic equipment.
  • the motion state of the electronic device includes: being in a static state or not in a static state.
  • the relative position of the common axis and the horizontal plane includes: the common axis is perpendicular to the horizontal plane or the common axis is not perpendicular to the horizontal plane.
  • determining the target algorithm according to the motion state and the relative position includes: determining the acceleration sensor algorithm as the target algorithm if the electronic device is in a static state. If the electronic equipment is not in a static state and the common axis is not perpendicular to the horizontal plane, the fusion algorithm or the gyroscope sensor algorithm is determined as the target algorithm. If the electronic device is not in a static state and the common axis is perpendicular to the horizontal plane, then the gyroscope sensor algorithm is determined as the target algorithm.
  • determining the motion state of the electronic device includes: if the difference between the modulus length of the acceleration vector of the electronic device and the acceleration of gravity is less than or equal to a first preset value, then consider that the acceleration vector The modulus length is close to the value of the acceleration of gravity, and it is determined that the motion state of the electronic device is a static state. If the difference between the modulus length of the acceleration vector and the acceleration of gravity is greater than the first preset value, it is considered that the modulus length of the acceleration vector is not close to the value of the acceleration of gravity, and it is determined that the motion state of the electronic device is not in a static state.
  • determining the relative position between the common axis and the horizontal plane includes: if the difference between the component of the acceleration vector on the common axis and the acceleration of gravity is less than or equal to the first preset value, then consider the acceleration The components of the vectors on the common axis approximate the acceleration of gravity, determining that the common axis is perpendicular to the horizontal plane. If the difference between the component of the acceleration vector on the common axis and the acceleration of gravity is greater than the first preset value, it is considered that the component of the acceleration vector on the common axis is not close to the acceleration of gravity, and it is determined that the common axis is not perpendicular to the horizontal plane.
  • using the determined target algorithm to calculate the hinge angle of the electronic device includes: if it is determined that the hinge angle changes, using the determined target algorithm to calculate the hinge angle of the electronic device .
  • determining that the hinge angle changes includes: determining that the hinge angle changes if a difference between the angular velocity difference and zero is greater than a second preset value.
  • the angular velocity difference is the difference between the angular velocity of the first gyro sensor around the common axis and the angular velocity of the second gyro sensor around the common axis.
  • the first gyro sensor is arranged on the body corresponding to the first screen, and the second gyro sensor is arranged on the body corresponding to the second screen.
  • determining the motion state of the electronic device and the relative position between the common axis and the horizontal plane includes: if it is determined that the folding screen is not in the closed state, then determining the motion state of the electronic device and the relative position between the common axis and the horizontal plane. The relative position of the horizontal plane.
  • determining that the folding screen is not in the closed state includes: determining that the folding screen is not in the closed state according to the magnetic force data.
  • the magnetic force data is obtained by detecting the magnetic field intensity of the magnet by the magnetic sensor, the magnetic sensor is arranged on the body corresponding to the first screen, and the magnet is arranged on the body corresponding to the second screen.
  • determining that the folding screen is not in the closed state according to the magnetic force data includes: determining that the folding screen is not in the closed state if the magnetic force data is less than or equal to a first preset magnetic force value.
  • the target algorithm is a fusion algorithm
  • use the determined target algorithm to calculate the hinge angle of the electronic device including: according to the angular velocity around the common axis collected by the first gyroscope sensor, the second The angular velocity around the common axis collected by the two gyroscope sensors, the hinge angle calculated by using the acceleration sensor algorithm, the sampling period, the process covariance, and the measurement error of key parameters are calculated by using a fusion algorithm to obtain the hinge angle of the electronic device.
  • the fusion algorithm is constructed based on the Kalman filter algorithm
  • the first gyro sensor is set on the body corresponding to the first screen
  • the second gyro sensor is set on the body corresponding to the second screen.
  • the target algorithm is the acceleration sensor algorithm
  • use the determined target algorithm to calculate the hinge angle of the electronic device including: projection of the acceleration vector on the x1o1z1 plane of the first screen coordinate system
  • the vector, and the projection vector of the acceleration vector on the x2o2z2 plane of the second screen coordinate system are calculated using the acceleration sensor algorithm to obtain the hinge angle of the electronic device.
  • the projection vector of the acceleration vector on the x1o1z1 plane of the first screen coordinate system is collected by the first acceleration sensor
  • the projection vector of the acceleration vector on the x2o2z2 plane of the second screen coordinate system is collected by the second acceleration sensor
  • the first acceleration sensor is arranged on the body corresponding to the first screen
  • the y1 axis of the first screen coordinate system is parallel to the y2 axis of the second screen coordinate system.
  • using the determined target algorithm to calculate the hinge angle of the electronic device includes: The angular velocity of the electronic device, the angular velocity around the common axis collected by the second gyro sensor, the hinge angle calculated last time, and the sampling period are calculated using the gyro sensor algorithm to obtain the hinge angle of the electronic device.
  • the first gyro sensor is arranged on the body corresponding to the first screen
  • the second gyro sensor is arranged on the body corresponding to the second screen.
  • the present application discloses a foldable electronic device, including: a foldable screen, the foldable screen includes a first screen and a second screen, one or more processors, and a memory on which programs are stored.
  • the program is executed by one or more processors, the foldable electronic device is made to execute the hinge angle detection method described in any one of the above first aspects.
  • Fig. 1a is a schematic diagram of changes in the unfolding and folding process of the folding screen mobile phone disclosed in the embodiment of the present application;
  • Fig. 1b is a schematic diagram of the video interface changes during the unfolding and folding process of the folding screen mobile phone disclosed in the embodiment of the present application during the process of playing the video;
  • Fig. 2a is a schematic diagram of the hardware structure of the foldable electronic device disclosed in the embodiment of the present application.
  • Fig. 2b is a schematic diagram of the hardware layout of the folding screen mobile phone disclosed in the embodiment of the present application.
  • Fig. 3 is a schematic diagram of the software framework of the foldable electronic device disclosed in the embodiment of the present application.
  • Fig. 4a is a schematic diagram of the included angle between two planes disclosed in the embodiment of the present application.
  • Fig. 4b is a schematic flow chart of the method for detecting the hinge angle disclosed in the embodiment of the present application.
  • Fig. 5 is a schematic diagram of the magnetic force change detected by the magnetic sensor during the deployment disclosed in the embodiment of the present application;
  • Fig. 6 is a schematic diagram of the relationship between the mold length of the magnetic force vector and the hinge angle disclosed in the embodiment of the present application;
  • Fig. 7a is a scene diagram 1 of detecting the hinge angle of the folding screen mobile phone disclosed in the embodiment of the present application;
  • Fig. 7b is a schematic diagram of hinge angle changes under different algorithms disclosed in the embodiment of the present application.
  • Fig. 7c is the second scene diagram of detecting the hinge angle of the folding screen mobile phone disclosed in the embodiment of the present application.
  • Fig. 7d is the scene diagram 3 of detecting the hinge angle of the folding screen mobile phone disclosed in the embodiment of the present application.
  • Fig. 7e is the scene diagram 4 of detecting the hinge angle of the folding screen mobile phone disclosed in the embodiment of the present application.
  • Fig. 7f is a scene diagram five of detecting the hinge angle of the folding screen mobile phone disclosed in the embodiment of the present application.
  • Fig. 7g is a scene diagram six of detecting the hinge angle of the folding screen mobile phone disclosed in the embodiment of the present application.
  • Fig. 8a is a schematic diagram of the hinge angle change corresponding to Experiment 1 disclosed in the embodiment of the present application;
  • Fig. 8b is a schematic diagram of the hinge angle change corresponding to Experiment 2 disclosed in the embodiment of the present application.
  • Fig. 8c is a schematic diagram of hinge angle changes corresponding to Experiment 3 disclosed in the embodiment of the present application.
  • words such as “exemplary” or “for example” are used as examples, illustrations or illustrations. Any embodiment or design scheme described as “exemplary” or “for example” in the embodiments of the present application shall not be interpreted as being more preferred or more advantageous than other embodiments or design schemes. Rather, the use of words such as “exemplary” or “such as” is intended to present related concepts in a concrete manner.
  • the folding screen of the folding screen mobile phone includes: a first screen and a second screen.
  • the folding screen is folded according to the folding edge to form the first screen and the second screen.
  • the virtual axis on which the folded edges lie is the common axis.
  • the first screen may include an inner screen and an outer screen of the first screen, and the second screen may also include an inner screen and an outer screen of the second screen.
  • the inner screen refers to the screen located inside when the folding screen is in the folded state
  • the outer screen is the screen located outside when the foldable screen is closed.
  • the angle between the first screen and the second screen is the hinge angle ⁇ of the folding screen mobile phone.
  • the folding screen mobile phone includes: a body corresponding to the first screen (referred to as the first body) and a body corresponding to the second screen (the second body). The first body and the second body are connected through a connecting shaft.
  • the shape of the folding screen mobile phone can be changed according to the needs of users. For example, when the user wants to carry it easily, the folding screen mobile phone can be folded, and the folding process can follow the order of (1) unfolded state, (2) stand state, (3) folded state from the folding direction shown in Figure 1a Change the shape of the mobile phone. When users want to watch videos on a large screen, they can unfold the folding screen phone. As shown in Figure 1a, the folding screen mobile phone can be unfolded. During the unfolding process, the folding screen mobile phone can change the shape of the mobile phone in the order of (3) folded state, (2) bracket state, and (1) unfolded state shown in Figure 1a.
  • the function of adaptively zooming in on the displayed content after unfolding and adaptively reducing the displayed content after folding is designed.
  • Figure 1b when the folding screen mobile phone is unfolded from (1) in Figure 1b to (2), the interface for playing the video is adaptively enlarged, and the playback task continues.
  • the video playback interface shrinks adaptively, and the playback task continues.
  • the embodiment of the present application proposes a hinge angle detection method.
  • the hinge angle detection method proposed in the embodiment of the present application can be applied to tablet computers, notebook computers, ultra-mobile personal computers (Ultra-mobile Personal Computer, UMPC), handheld computers, and netbooks in addition to being applied to folding screen mobile phones.
  • UMPC Ultra-mobile Personal Computer
  • other foldable electronic devices that is, the hinge angle of any foldable electronic device can be calculated in this embodiment of the present application.
  • the foldable electronic device 200 may include: a processor 210, a smart sensor hub 210A, a sensor module 220, a first gyro sensor 220A, a first acceleration sensor 220B, a second gyro sensor 220C, The second acceleration sensor 220D, the magnetic sensor 220E, the folding screen 230, the audio module 240, and the magnet 240A.
  • the first gyro sensor 220A, the first acceleration sensor 220B, and the magnetic sensor 220E can be arranged in the first body as shown in FIG. It is arranged in the second body as shown in Fig. 1a.
  • the structure shown in this embodiment does not constitute a specific limitation on the foldable electronic device.
  • the foldable electronic device may include more or fewer components than shown, or combine certain components, or separate certain components, or arrange different components.
  • the illustrated components can be realized in hardware, software or a combination of software and hardware.
  • the processor 210 may include one or more processing units, for example: the processor 210 may include an application processor (application processor, AP), a modem processor, a graphics processing unit (graphics processing unit, GPU), an image signal processor ( image signal processor (ISP), controller, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural network processor (neural-network processing unit, NPU), etc. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • application processor application processor, AP
  • modem processor graphics processing unit
  • graphics processing unit graphics processing unit
  • ISP image signal processor
  • controller video codec
  • digital signal processor digital signal processor
  • baseband processor baseband processor
  • neural network processor neural-network processing unit
  • the processor 210 may also include a smart sensor hub (Sensor hub) 210A for connecting and processing data from various sensor devices.
  • the smart sensor hub 210A is connected to and processes the data of the first gyroscope sensor 220A, the first acceleration sensor 220B, the second gyroscope sensor 220C, the second acceleration sensor 220D, and the magnetic sensor 220E,
  • the hinge angle detection method shown in FIG. 4b below is executed according to the data of the sensor. For the specific execution process, refer to the description of the hinge angle detection method in FIG. 4b below, which will not be repeated here.
  • the folding screen 230 is used to display images, videos and the like.
  • the folding screen 230 can be understood as a foldable flexible screen.
  • the folding screen 230 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 or an active matrix organic light emitting diode (active-matrix organic light emitting diode, AMOLED), flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oled, quantum dot light emitting diodes (quantum dot light emitting diodes, QLED), etc.
  • LCD liquid crystal display
  • OLED organic light-emitting diode
  • AMOLED active matrix organic light emitting diode
  • FLED flexible light-emitting diode
  • Miniled MicroLed
  • Micro-oled quantum dot light emitting diodes (quantum dot light emitting di
  • the folding screen 230 includes a first screen 230A and a second screen 230B.
  • the folding screen 230 can be unfolded or folded along the folding edge to form a first screen 230A and a second screen 230B.
  • first screen 230A and the second screen 230B reference may be made to the first screen and the second screen in FIG. 1a.
  • the first gyro sensor 220A can be used to determine the motion posture of the electronic device. For example, the angular velocity of the first screen around three axes (ie, x1, y1 and z1 axes) of the first screen may be determined by the first gyro sensor 220A. In the embodiment of the present application, the first gyro sensor 220A may be used to determine the angular velocity of the first screen around the y1 axis of the first screen coordinate system (ie, the common axis of the folding screen). The first gyro sensor 220A can also be used for image stabilization.
  • the second gyro sensor 220C can also be used to determine the motion posture of the electronic device.
  • the angular velocity of the second screen around the three axes (ie, x2, y2 and z2 axes) of the second screen can be determined by the second gyro sensor 220C.
  • the second gyro sensor 220C can be used to determine the angular velocity of the second screen around the y2 axis of the second screen (that is, the common axis of the folding screen, the y1 axis and the y2 axis are the same axis).
  • the second gyro sensor 220C can also be used for image stabilization.
  • the first acceleration sensor 220B can detect the acceleration of the first screen in various directions (generally, the three axes x1, y1 and z1 determined by the first screen). When the electronic device is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the second acceleration sensor 220D can detect the acceleration of the second screen in various directions (generally the three axes x2, y2 and z2 determined by the second screen). When the electronic device is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the magnetic sensor 220E is used to detect the magnetic field strength of the magnet 240A to obtain magnetic force data, and detect the opening or closing of the folding screen through the magnetic force data.
  • the magnetic sensor 220E is disposed in a body (first body) corresponding to the first screen.
  • the smart sensor hub 210A judges whether the folding screen is in an unfolded state or a closed state according to the magnetic force data acquired by the magnetic sensor 220E under the action of the magnetic field of the magnet 240A. Then, according to the detected opening and closing state, it is decided whether to start the hinge angle detection. Specifically, reference may be made to relevant parts from step S401 to step S403 in the hinge angle detection method shown in FIG. 4b.
  • the magnet 240A is used to generate a magnetic field.
  • the magnet 240A is arranged in a body (second body) corresponding to the second screen.
  • the magnet 240A may also be a speaker due to the presence of a magnet in the speaker. Loudspeakers, also known as "horns", are used to convert audio electrical signals into sound signals. Electronic devices can listen to music through the speakers, or listen to hands-free calls.
  • the magnet 240A allows the magnetic sensor 220E to detect the magnetic force. As the opening and closing state of the folding screen changes, the distance between the magnetic sensor 220E and the magnet 240A changes accordingly, and the magnetic field strength of the magnet 240A detected by the magnetic sensor 220E also changes. , and then the magnetic data collected by the magnetic sensor 220E will also change accordingly, and then the smart sensor hub 210A can detect the opening and closing state of the folding screen through the magnetic data detected by the magnetic sensor 220E.
  • the internal hardware layout of the foldable phone may be as shown in FIG. 2b.
  • the first gyro sensor 220A, the first acceleration sensor 220B, and the magnetic sensor 220E are disposed in the first body
  • the second gyro sensor 220C, the second acceleration sensor 220D, and the magnet 240A are disposed in the second body.
  • the first gyro sensor 220A and the second gyro sensor 220C are placed in parallel, and the first acceleration sensor 220B and the second acceleration sensor 220D are placed in parallel, so that the y1 axis in the first screen coordinate system can be aligned with the y1 axis in the second screen coordinate system.
  • the y2 axis is parallel.
  • the distance between the magnet 240A and the magnetic sensor 220E can be set to 2 cm, depending on the accuracy requirements of the application scenario. Since the magnetic sensor 220E is easily disturbed by an external magnetic field, the magnetic sensor 220E may not be placed at the edge of the first screen.
  • an operating system runs on top of the above components.
  • Applications can be installed and run on this operating system.
  • the operating system of the foldable electronic device 200 may adopt a layered architecture, an event-driven architecture, a micro-kernel architecture, a micro-service architecture, or a cloud architecture.
  • an Android system with a layered architecture is taken as an example to illustrate the software structure of a foldable electronic device.
  • Fig. 3 is a block diagram of the software structure of the foldable electronic device according to the embodiment of the present application.
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate through software interfaces.
  • the Android system is divided into four layers, which are respectively the application program layer, the application program framework layer, the Android runtime (Android runtime) and the system library, and the kernel layer from top to bottom.
  • the application layer can consist of a series of application packages. As shown in FIG. 3, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and short message.
  • applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and short message.
  • the application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer.
  • the application framework layer includes some predefined functions. As shown in Figure 3, the application framework layer can include window manager, content provider, view system, phone manager, resource manager, notification manager, etc.
  • a window manager is used to manage window programs.
  • the window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, capture the screen, etc.
  • Content providers are used to store and retrieve data and make it accessible to applications.
  • Said data may include video, images, audio, calls made and received, browsing history and bookmarks, phonebook, etc.
  • the view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on.
  • the view system can be used to build applications.
  • a display interface can consist of one or more views.
  • a display interface including a text message notification icon may include a view for displaying text and a view for displaying pictures.
  • the phone manager is used to provide communication functions of electronic devices. For example, the management of call status (including connected, hung up, etc.).
  • the resource manager provides various resources for the application, such as localized strings, icons, pictures, layout files, video files, and so on.
  • the notification manager enables the application to display notification information in the status bar, which can be used to convey notification-type messages, and can automatically disappear after a short stay without user interaction.
  • the notification manager is used to notify the download completion, message reminder, etc.
  • the notification manager can also be a notification that appears on the top status bar of the system in the form of a chart or scroll bar text, such as a notification of an application running in the background, or a notification that appears on the screen in the form of a dialog window.
  • the AndroidRuntime includes core library and virtual machine.
  • the Android runtime is responsible for the scheduling and management of the Android system.
  • the core library consists of two parts: one part is the function function that the java language needs to call, and the other part is the core library of Android.
  • the application layer and the application framework layer run in virtual machines.
  • the virtual machine executes the java files of the application program layer and the application program framework layer as binary files.
  • the virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.
  • a system library can include multiple function modules. For example: surface manager (surface manager), media library (Media Libraries), 3D graphics processing library (eg: OpenGL ES), 2D graphics engine (eg: SGL), angle algorithm module and closure detection algorithm module, etc.
  • the angle algorithm module and the closure detection algorithm module are used to coordinately execute the hinge angle detection algorithm shown in FIG. 4b .
  • FIG. 4b For details, please refer to the related content of the hinge angle detection algorithm shown in FIG. 4b .
  • the surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple applications.
  • the media library supports playback and recording of various commonly used audio and video formats, as well as still image files, etc.
  • the media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
  • the 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing, etc.
  • 2D graphics engine is a drawing engine for 2D drawing.
  • the kernel layer is the layer between hardware and software.
  • the kernel layer includes at least a display driver, a camera driver, an audio driver, and a sensor driver.
  • the first screen coordinate system and the second screen coordinate system As shown in Figure 2b, the x1 axis and y1 axis in the first screen coordinate system x1y1z1 are parallel to or coincident with the length and width of the first screen, and the z1 axis is perpendicular to the plane where the first screen is located.
  • the origin o1 selected by the coordinate system of the first screen may not only be at the position shown in FIG. 2 b , but also other positions on the first screen may be selected as the origin.
  • the second screen coordinate system x2y2z2 is also established in a similar manner to the first screen coordinate system, which will not be repeated here.
  • the y1 axis and the y2 axis also coincide, which is the virtual axis where the folding edge of the foldable electronic device is located (that is, the common axis of the foldable electronic device).
  • the algorithm for calculating the hinge angle by using the acceleration sensor referred to as the acceleration sensor (Acceleration transducer, ACC) algorithm.
  • the ACC algorithm calculates the hinge angle through the acceleration data collected by the acceleration sensor.
  • the acceleration data may specifically be the coordinates of the acceleration vector.
  • calculating the hinge angle ⁇ of the foldable electronic device can be converted into calculating the normal vector of the plane where the first screen is located and the normal vector of the plane where the second screen is located The angle ⁇ between them.
  • the foldable electronic device In a static state, the foldable electronic device is only affected by gravity, and the gravity vector is equivalent to the Z axis of the earth coordinate system.
  • the coordinates of the gravity vector in the mobile phone coordinate system that is, the first screen coordinate system or the second screen coordinate system
  • the relative coordinates of the earth coordinate system relative to the mobile phone coordinate system so the problem of finding the hinge angle between the first screen and the second screen can be converted into finding the gravity vector (ie, the gravity acceleration vector) on the first screen
  • the coordinate system and the included angle of the gravity vector (ie, the gravity acceleration vector) in the second screen coordinate system The coordinate system and the included angle of the gravity vector (ie, the gravity acceleration vector) in the second screen coordinate system.
  • the acceleration vector (ie, the gravity acceleration vector) in the first screen coordinate system x1y1z1 collected by the first acceleration sensor is (A 1 , B 1 , C 1 ), and the acceleration vector collected by the second acceleration sensor
  • the acceleration vector in the two-screen coordinate system x2y2z2 is (A 2 , B 2 , C 2 ), therefore, substituting A 1 , B 1 , C 1 , A 2 , B 2 , and C 2 into Formula 1, the calculation results in The normal vector of the first screen ⁇ 1 and the normal vector of the second screen The angle ⁇ between them.
  • the working principle of the first acceleration sensor refer to the description of the first acceleration sensor 220B in FIG. 2 a
  • the working principle of the second acceleration sensor refer to the description of the first acceleration sensor 220D in FIG. 2 a.
  • Formula One is: Wherein, the hinge angle ⁇ is equal to 180- ⁇ .
  • formula 1 can be converted into formula 2, that is, the acceleration vector collected by the first acceleration sensor is in the x1o1z1 plane of the first screen coordinate system
  • the projection vector (A 1 , C 1 ) and the projection vector (A 2 , C 2 ) of the acceleration vector collected by the second acceleration sensor on the x2o2z2 plane of the second screen coordinate system are substituted into Formula 2 to calculate the hinge angle .
  • the ACC algorithm may also have other specific algorithm forms, which are not limited here.
  • the algorithm for calculating the hinge angle by using the gyro sensor referred to as the gyro sensor (Gyro) algorithm.
  • the Gyro algorithm is an algorithm for calculating the hinge angle through the angular velocity collected by the gyroscope sensor. Specifically, as shown in Figure 2b, it can be seen that the y-axis of the first screen coordinate system and the second screen coordinate system are parallel or coincident (that is, the axis where the folding edge is located), and only the rotation along the y-axis will affect the hinge angle. size. Therefore, when using the angular velocity to calculate the hinge angle, only the component of the y-axis can be integrated.
  • the angular velocity Gyroy1 of the rotation around the y1 axis collected by the first gyro sensor during the sampling period and the angular velocity Gyroy1 of the rotation around the y2 axis collected by the second gyro sensor during the sampling period
  • the angular velocity Gyroy2 and the hinge angle a calculated in the previous sampling period are substituted into Formula 3 to calculate the current hinge angle ⁇ .
  • the working principle of the first gyro sensor refer to the description of the first gyro sensor 220A in FIG. 2 a
  • the working principle of the second gyro sensor refer to the description of the second gyro sensor 220C in FIG. 2 a.
  • delatT is the value of the sampling period.
  • the Gyro algorithm can also have other specific algorithm forms, which are not limited here.
  • the fusion algorithm using the acceleration sensor and the gyroscope sensor to calculate the hinge angle may also be further referred to as the fusion algorithm in the embodiment of the present application.
  • the A+G fusion algorithm is an algorithm that fuses the angular velocity data collected by the gyroscope sensor and the acceleration data collected by the acceleration sensor to calculate the hinge angle.
  • Kalman filtering can be used to fuse acceleration and angular velocity data to calculate the hinge angle.
  • no limitation is imposed on the specific form of the algorithm for calculating the hinge angle by fusing the angular velocity and the acceleration.
  • the A+G fusion algorithm model constructed based on Kalman filter is:
  • eAngle eAngle+delatT ⁇ Gyro;
  • eAngle eAngle+K ⁇ (Angle-eAngle);
  • Gyro Gyroy2-Gyroy1.
  • Gyroy1 is the angular velocity of rotation around the y1 axis collected by the first gyro sensor in a certain sampling period
  • Gyroy2 is the angular velocity of rotation around the y2 axis collected by the second gyro sensor in the sampling period.
  • delatT is the value of the sampling period.
  • eAngle is the hinge angle estimated by the hinge angle algorithm model. The eAngle initially input into the model can be assumed arbitrarily, or the hinge angle calculated last time can be used as eAngle.
  • P is a priori estimated covariance, and the initial input of P to the model can be a number between 0 and 1 that is not 0, and can be set arbitrarily.
  • Q is the process covariance, which is equivalent to the internal system error of the A+G fusion algorithm model constructed based on Kalman filtering. It is a fixed value that has been pre-set and debugged based on experience, for example, it can be 0.000001.
  • R is the measurement error of the key parameter, which is equivalent to the error of the algorithm itself that uses the acceleration sensor to calculate the hinge angle. It is also a fixed value that has been pre-set and debugged based on experience, for example, it can be 1.5.
  • K is the covariance, which is a parameter generated during the internal operation of the model and does not require external input into the model.
  • Angle is an algorithm that uses an acceleration sensor to calculate the hinge angle, and the calculated hinge angle value.
  • the values of Q and R are set in advance, and assuming that an arbitrary eAngle and P are input into the model, the formula of the estimation process can be used to predict Estimate a new eAngle and P. Then eAngle and P can be updated by formulas in the measurement calculation process. The updated eAngle and P in the measurement calculation process are then iterated into the formula in the estimation calculation process, and after repeated iterations, a more accurate hinge angle eAngle can be output.
  • the hinge angle algorithm calculated by the gyroscope sensor is the main algorithm, and the hinge angle data calculated by the ACC algorithm is fused.
  • the hinge angle error calculated by the ACC algorithm is relatively large, but the trend of size change can make up for the error of the Gyro algorithm.
  • the A+G fusion algorithm model constructed based on Kalman filter has the advantages of simple calculation, high efficiency, and fast convergence. At the same time, it can filter out high-frequency and low-frequency interference, and it does not depend on the precise initial hinge angle.
  • Fig. 4b is a hinge angle detection method proposed in the embodiment of the present application, which is applied to the foldable electronic device proposed in the embodiment of the present application. Taking the folding screen mobile phone as an example, the following steps are described:
  • the closure detection algorithm module determines whether the folding screen is in a closed state according to the magnetic force data.
  • the magnetic force data is collected by a magnetic sensor in the electronic device, and there is a corresponding relationship between the magnetic force data and the hinge angle of the folding screen.
  • a corresponding hinge angle can be determined, and then according to the hinge angle, it can be determined whether the folding screen is in a closed state.
  • the closed state refers to the state where the hinge angle of the folding screen is close to zero
  • the non-closed state refers to the state where the hinge angle is greater than zero, which can also be considered as the state where the folding screen is opened.
  • the folding angle ⁇ of the folding screen is greater than zero, and when the folding screen is in a support state, it is also an open state of the folding screen, that is, it is not in a closed state.
  • the hinge angle ⁇ is almost zero, the first screen and the second screen overlap, and at this time they are in a closed state (or called a folded state).
  • the magnetic force data may be the modulus length of the magnetic force vector.
  • the closure detection algorithm module determines the current hinge angle through the corresponding relationship between the mold length of the magnetic vector and the hinge angle, and then can determine whether the folding screen is in a closed state according to the determined hinge angle.
  • the modulus length of the magnetic force vector has a negative correlation with the hinge angle.
  • the folding screen 230 of the electronic device in FIG. 2a is folded into a first screen 230A and a second screen 230B
  • the magnetic field lines emitted by the magnet inside the magnet 240A will pass through the magnetic sensor 220E
  • the magnetic sensor 220E collects the modulus length of the magnetic force vector.
  • the hinge angle between the first screen 230A and the second screen 230B is gradually increasing, from (1), (3) in FIG. 5 (2), (3) It can be seen that as the hinge angle increases, the magnetic field lines passing through the magnetic sensor 220E become less and less, and the modulus length of the magnetic force vector detected by the magnetic sensor 220E becomes smaller .
  • the second preset angle can be set to 10 degrees, and the corresponding second preset magnetic force value is 1930. That is, when the modulus length of the magnetic force vector is less than or equal to 1930, it means that the hinge angle is greater than or equal to 10 degrees, and it is determined that the folding screen is not in the closed state.
  • the first preset angle value can be set to 5 degrees
  • the corresponding first preset magnetic force value is 2800, that is, when the modulus of the magnetic force vector is greater than or equal to 2800, it means that the hinge angle is less than or It is equal to 5 degrees, and it is determined that the folding screen is in a closed state.
  • the first preset angle value and the second preset angle value may be equal or not.
  • the first preset magnetic force value and the second preset magnetic force value may also be equal or unequal.
  • step S401 if it is determined in step S401 that the folding screen is not in the closed state, the angle algorithm module needs to be activated to detect the hinge angle of the folding screen, so step S402 needs to be executed, and if it is determined in step S401 that the folding screen is in the closed state, then It shows that it is not necessary to detect the hinge angle of the folding screen, so step S403 needs to be performed.
  • step S401 is a step that is executed in real time or periodically. Step S401 may be executed every time after determining whether the folding screen is in the closed state, and step S402 or S403 is executed, or it may be performed only after the determined folding screen is in the closed state. When the state of the screen changes (for example, from the closed state to the non-closed state), step S402 or step S403 is executed again.
  • the closure detection algorithm module notifies the angle algorithm module to start.
  • the start of the angle algorithm module means that the start of the angle algorithm module detects the hinge angle of the folding screen.
  • the folding screen is not in the closed state (that is, in the open state), it proves that it may be necessary to open the folding screen to realize some functions (such as the functions shown in the scenes in Figure 1a and Figure 1b), and these functions need to detect the current state of the folding screen.
  • Attitude, that is, the hinge angle of the folding screen needs to be known, so the angle algorithm module needs to be activated to detect the hinge angle.
  • the closure detection algorithm module to notify the angle algorithm module to start, for example, to notify the angle algorithm module by sending a start instruction.
  • the angle algorithm module may also be notified by sending a start request. There is no limitation on the specific way of notifying the angle algorithm module.
  • the angle algorithm module responds to the start notification of the closure detection algorithm module, starts to detect the hinge angle, and starts to execute step S404.
  • starting the preparation process for detecting the hinge angle may be: creating a thread for performing the hinge angle detection, and controlling the starting work of the sensor required for starting the hinge angle detection process.
  • the first gyro sensor 220A, the first acceleration sensor 220B, the second gyro sensor 220C, and the second acceleration sensor 220D shown in FIG. 2a may be controlled to start working.
  • the closure detection algorithm notifies the angle algorithm module to close.
  • the angle algorithm module is closed, which means that the angle algorithm module stops detecting the hinge angle of the folding screen.
  • the angle algorithm module stops detecting the hinge angle of the folding screen.
  • the closure detection algorithm module to notify the angle algorithm module to be closed, for example, to notify the angle algorithm module by sending a close command.
  • the angle algorithm module may also be notified by sending a closing request. There is no limitation on the specific way of notifying the angle algorithm module.
  • the angle algorithm module responds to the closure notification of the closure detection algorithm module, and stops detecting the hinge angle.
  • disabling the hinge angle detection process may be: ending the hinge angle detection thread, and controlling the sensors used in the hinge angle detection process to stop working, that is, the sensors stop collecting data.
  • the first gyro sensor 220A, the first acceleration sensor 220B, the second gyro sensor 220C, and the second acceleration sensor 220D shown in FIG. 2a may be controlled to stop working.
  • the angle algorithm module does not work, and the sensors used in the hinge angle detection process also do not work, and the hinge angle detection is stopped, thereby reducing power consumption and improving operating efficiency.
  • the angle algorithm module judges whether it is in a static state.
  • the angle algorithm module When the angle algorithm module starts to detect the hinge angle of the folding screen mobile phone, it needs to judge the current motion state of the folding screen mobile phone to select an appropriate angle algorithm to calculate the hinge angle.
  • the static state in the embodiment of the present application can be understood as a relatively static state. In the static state, the folding screen mobile phone is equivalent to only being subjected to gravity.
  • angle algorithm module judges that it is in a static state, it means that it is suitable to use the ACC algorithm with high calculation accuracy in the static state to calculate the hinge angle.
  • angle algorithm module is not in a static state, it means that it is not suitable to use the ACC algorithm , and then need to further determine the current appropriate angle algorithm.
  • the angle algorithm module determines whether the folding screen mobile phone is in a static state (that is, determines the motion state of the folding screen mobile phone) by obtaining the modulus length of the acceleration vector of the folding screen mobile phone.
  • the modulus length of the acceleration vector is close to 9.8m/s 2 , that is, close to the value of the gravitational acceleration, it is judged to be in a static state.
  • the difference between the modulus length of the acceleration vector of the electronic device and the acceleration of gravity is less than or equal to the first preset value, it is considered that the modulus length of the acceleration vector is close to the acceleration of gravity, and the motion state of the electronic device is determined to be static state.
  • the first preset value can be set according to actual experience, and the value of the first preset value can be close to 0.
  • the modulus length of the acceleration vector of the folding screen mobile phone can be acquired through an acceleration sensor.
  • the modulus length of the acceleration vector can be acquired through the first acceleration sensor 220B or the second acceleration sensor 220D.
  • step S405 When the angle algorithm module determines that it is in a static state, step S405 is executed. And when the angle algorithm module determines that it is not in a static state, step S408 is executed.
  • the angle algorithm module judges whether the common axis is perpendicular to the horizontal plane.
  • the common axis is the axis where the folded edge is located, and can also be understood as the y1 axis in the first screen coordinate system x1y1z1 or the y2 axis in the second screen coordinate system x2y2z2.
  • the horizontal plane refers to the horizontal plane in the earth coordinate system.
  • step S404 When it is determined in step S404 that it is in a static state, it means that the current suitable algorithm for calculating the hinge angle is the ACC algorithm, but the ACC algorithm can accurately calculate the hinge angle only when the common axis is not perpendicular to the horizontal plane, so further judgment is required Whether the common axis is perpendicular to the horizontal plane.
  • step S404 When the common axis is perpendicular to the horizontal plane, and step S404 also determines that the folding screen mobile phone is in a static state, step S406 is executed. When the common axis is not perpendicular to the horizontal plane, and step S404 also judges that the folding screen mobile phone is in a static state, step S407 is executed.
  • the manner of performing step S405 may be: judging whether the common axis is perpendicular to the horizontal plane according to the component of the acceleration on the common axis.
  • the component of the acceleration vector on the common axis is obtained by an acceleration sensor, for example, the first acceleration sensor 220B or the second acceleration sensor 220D in FIG. 2 a . If the component of the acceleration vector on the common axis (that is, the component of the y1 axis in the first screen coordinate system, or the component of the y2 axis in the second screen coordinate system) is close to 9.8, it is determined that the common axis is perpendicular to the horizontal plane.
  • the common axis is perpendicular to the horizontal plane. If the difference between the component of the acceleration vector on the common axis and the acceleration of gravity is greater than a first preset value, it is determined that the common axis is not perpendicular to the horizontal plane.
  • the first preset value may be a number close to 0, and the value of the acceleration of gravity is 9.8.
  • step S404 has judged that it is in a static state and is only subjected to gravity, when all the values of the acceleration of gravity are on the common axis, it means that the direction of gravity coincides with the common axis, and the common axis is perpendicular to the horizontal plane.
  • the difference between the component of the acceleration vector on the common axis and the acceleration of gravity is greater than the first preset value, it is considered that the component of the acceleration vector on the common axis is not close to the acceleration of gravity, and the common axis is judged not perpendicular to the horizontal plane.
  • the angle algorithm module does not recalculate the hinge angle of the folding screen.
  • not recalculating the hinge angle of the folding screen can also be understood as continuing to use the hinge angle of the folding screen calculated last time as the currently detected hinge angle of the folding screen, that is, the last (or latest) ) detected hinge angle as the currently detected hinge angle.
  • step S402 since step S402 notifies the angle algorithm module to start, the angle algorithm module will calculate the hinge angle of the folding screen periodically or in real time until the angle algorithm module is notified to close.
  • the flow chart shown in FIG. 4b is an exemplary description of a certain hinge angle detection process as an example. For the current hinge angle detection process, when it is determined that the hinge angle does not need to be recalculated, the latest detected hinge angle is directly used as the currently detected hinge angle.
  • step S404 determines that the folding screen mobile phone is currently in a static state, and in a static state, calculating the hinge angle by using the ACC algorithm is more accurate than using the Gyro algorithm.
  • step S405 determines that the common axis is perpendicular to the horizontal plane, when using the ACC algorithm to calculate the hinge angle, it is through the projection of the acceleration vector on the x1o1z1 plane in the first screen coordinate system, and the acceleration vector in the second screen coordinate system.
  • the projection of the x2o2z2 plane is used to calculate the hinge angle.
  • the common axis is perpendicular to the horizontal plane and is in a static state, it means that the folding screen mobile phone is only affected by the acceleration of gravity, and the gravity acceleration vector coincides with the common axis, there is no projection on the xoz plane, and the ACC algorithm cannot be used to calculate the hinge angle. Also, since the foldable electronic device is in a static state and is not affected by other external forces, the hinge angle does not change, so the hinge angle does not need to be recalculated.
  • the ACC algorithm For the technical principle of the ACC algorithm, reference may be made to the foregoing introduction to the ACC algorithm, which will not be repeated here.
  • the hinge angle of the folding screen calculated last time can be used as the currently detected hinge angle. If the function of the current folding screen mobile phone needs to use For the hinge angle of the folding screen, the hinge angle of the folding screen calculated last time can be used.
  • the hinge angle calculated by the closure detection algorithm module latest through the modulus length of the magnetic force vector can be used as the current hinge angle. page angle.
  • the process of calculating the hinge angle by the closure detection algorithm module through the modulus length of the magnetic force vector can refer to the relevant content of step S401 , which will not be repeated here.
  • the hinge angle calculated last time by the angle algorithm module can be directly used as the currently detected hinge angle.
  • Fig. 7b shows the change diagram of the hinge angle detected by various algorithms.
  • the motion state of the folding screen mobile phone with a hinge angle of 67 degrees is changed from static to shaking, and finally returns to static.
  • the angle measured by the Gyro algorithm shown in (2) gradually deviates from the true value of 67 degrees as time increases.
  • the ACC algorithm in the static period, that is, from 0 to 73 seconds, and from 721 to 961 seconds, the value of the calculated hinge angle does not change, which is 67 degrees. It can be seen from this that in a static state, the hinge angle can be calculated more accurately using the ACC algorithm than the Gyro algorithm.
  • the angle algorithm module uses the ACC algorithm to calculate the hinge angle.
  • the ACC algorithm can be used to calculate the hinge angle. It can be seen from the related description in Figure 7b above that the accuracy of calculating the hinge angle using the ACC algorithm in the static state is relatively high, and the current common axis is not perpendicular to the horizontal plane.
  • the first acceleration sensor can collect the acceleration vector in the coordinate system of the first screen
  • the projection of the x1o1z1 plane of the second acceleration sensor can also collect the projection of the acceleration vector on the x2o2z2 plane of the second screen coordinate system, thus satisfying the conditions for using the ACC algorithm.
  • the folding screen mobile phone is placed on the desktop by the user, and the folding edge is not perpendicular to the horizontal plane.
  • the folding screen mobile phone is using the ACC algorithm to calculate the hinge angle.
  • the angle algorithm module acquires the acceleration vector (A 1 , B 1 , C 1 ) collected by the first acceleration sensor, and the acceleration vector (A 2 , B 2 , C 2 ) collected by the second acceleration sensor , substituted into the aforementioned formula 1 to calculate cos ⁇ , determine ⁇ , and then calculate the hinge angle by subtracting ⁇ from hinge angle ⁇ equal to 180.
  • the angle algorithm module can also obtain the projection of the acceleration vector collected by the first acceleration sensor on the x1o1z1 plane ( A1, C 1 ), and the projection (A 2 , C 2 ) of the acceleration vector collected by the second acceleration sensor on the x2o2z2 plane is substituted into the aforementioned formula 2 to calculate cos ⁇ , determine ⁇ , and then pass the hinge Angle ⁇ is equal to 180 minus ⁇ to calculate the hinge angle.
  • the ACC algorithm can still be used to calculate the hinge angle with high accuracy.
  • it can be calculated by using the ACC algorithm. Accurate hinge angle, correcting errors in previous calculations.
  • the angle algorithm module judges whether the common axis is perpendicular to the horizontal plane.
  • Step S404 After the angle algorithm module determines that the algorithm module is not in a static state in step S404, it means that the acceleration of the current folding screen mobile phone is not only affected by gravity acceleration, but also by other accelerations, so it is not suitable for using the ACC algorithm, and then needs to pass Step S408 further determines whether to use the Gyro algorithm or the A+G fusion algorithm to calculate the hinge angle.
  • the hinge angle calculated by the ACC algorithm cannot be used, and then the A+G fusion algorithm cannot be used. If the hinge angle needs to be calculated, the Gyro algorithm needs to be used. When it is judged that the common axis is perpendicular to the horizontal plane, it means that the hinge angle calculated by the ACC algorithm can be used, so the A+G fusion algorithm can be used to calculate the hinge angle.
  • step S408 it can be determined which algorithm is currently suitable for calculating the hinge angle. However, after the available algorithm is determined through step S408, it is still necessary to further judge whether it is necessary to use the algorithm to calculate the hinge angle at present. Therefore, when it is determined that the common axis is perpendicular to the horizontal plane and the Gyro algorithm is suitable for use, step S409 needs to be performed to further determine whether the hinge angle changes, so as to determine whether the hinge angle needs to be calculated currently. Similarly, when it is judged that the common axis is not perpendicular to the horizontal plane and it is determined that the A+G fusion algorithm is suitable, it is also necessary to perform step S410 to further judge whether the hinge angle changes, and determine whether the hinge angle needs to be calculated currently.
  • step S408 for the execution process and principle of step S408, reference may be made to step S405, which will not be repeated here.
  • the angle algorithm module judges whether the hinge angle changes.
  • step S411 is executed, that is, the hinge angle is not recalculated.
  • step S412 is performed to calculate the hinge angle using the Gyro algorithm.
  • an implementation manner of performing step S409 is: the angle algorithm module determines whether the hinge angle changes according to the angular velocity collected by the gyroscope sensor. Specifically, what can cause the hinge angle to change is the change of the angular velocity of the y-axis. Therefore, in some embodiments, the angle algorithm module can acquire the angular velocity Gyroy1 of rotating around the y1 axis collected by the first gyro sensor, and obtain the angular velocity Gyroy2 of rotating around the y2 axis collected by the second gyro sensor.
  • the second preset value may be a value close to zero.
  • the angle algorithm module judges whether the hinge angle changes.
  • step S413 is executed, that is, the hinge angle is not recalculated.
  • step S414 is performed to calculate the hinge angle using the A+G fusion algorithm.
  • step S410 For the process and principle of the angle algorithm module executing step S410, reference may be made to step S409, which will not be repeated here.
  • the angle algorithm module does not recalculate the hinge angle of the folding screen.
  • the applicable algorithm is the Gyro algorithm. However, if it is determined that the hinge angle has not changed, it is not necessary to recalculate the hinge angle of the folding screen. Directly use the hinge angle calculated last time, that is, the current hinge angle detection process no longer calculates the current hinge angle, but uses the latest (or latest) calculated hinge angle as the current detection out hinge angle.
  • the scene shown in Figure 7d the user holds a foldable phone while walking to watch, and the folding edge of the foldable phone is perpendicular to the horizontal plane.
  • the foldable phone is not in a static state, the user does not change the folding
  • the shape of the folding screen mobile phone does not change the hinge angle, so in the scenario shown in Figure 7d, the folding screen mobile phone does not recalculate the hinge angle.
  • step S411 may refer to step S406.
  • the angle algorithm module uses the Gyro algorithm to calculate the hinge angle.
  • the applicable algorithm can be the Gyro algorithm, and through the aforementioned judgment hinge Whether the angle changes determines that the current hinge angle has changed. Therefore, it is necessary to use the Gyro algorithm to calculate the hinge angle.
  • the folding screen mobile phone uses the Gyro algorithm to calculate the hinge angle.
  • the angle algorithm module acquires the angular velocity Gyroy1 of rotation around the y1 axis collected by the first gyro sensor, and the angular velocity Gyroy2 of rotation around the y2 axis collected by the second gyro sensor, and converts Gyroy1, Gyroy2, and
  • the hinge angle a calculated last time is substituted into Formula 3 to calculate the current hinge angle ⁇ .
  • the angle algorithm module does not recalculate the hinge angle of the folding screen.
  • the applicable algorithm can be the A+G fusion algorithm, but the hinge angle There is no change, therefore, there is no need to recalculate the hinge angle of the folding screen, and the hinge angle calculated last time can be used directly, that is, the current hinge angle detection process no longer calculates the current hinge angle, but Use the latest (or latest) calculated hinge angle as the currently detected hinge angle.
  • the user holds a foldable phone while walking to watch.
  • the folding edge of the foldable phone is not perpendicular to the horizontal plane.
  • the foldable phone is not in a static state, the user does not change the folding screen
  • the shape of the mobile phone does not change the hinge angle, so in the scenario shown in Figure 7f, the folding screen mobile phone does not recalculate the hinge angle.
  • the angle algorithm module uses the A+G fusion algorithm to calculate the hinge angle.
  • the applicable algorithm is the A+G fusion algorithm, and through the aforementioned Judging whether the hinge angle has changed determines that the current hinge angle has changed. Therefore, it is necessary to use the A+G fusion algorithm to calculate the hinge angle.
  • the user is opening the folding screen mobile phone while walking.
  • the folding screen mobile phone is not in a static state, and the folding edge is not perpendicular to the horizontal plane. Therefore, the folding screen mobile phone uses the A+G fusion algorithm to calculate Hinge angle.
  • the reason why the A+G fusion algorithm can be used is that the hinge angle For a folding screen mobile phone with an angle of 67 degrees, when the hinge angle does not change, the hinge angle calculated by the ACC algorithm in the shaking stage (that is, the non-stationary stage) is not correct during the process of being stationary, shaking, and then standing still.
  • the hinge angle error calculated by the Gyro algorithm will become larger and larger as time goes by, while the Kalman filter based on (3) shown
  • the A+G fusion algorithm the calculated hinge angle is stable at about 67 degrees no matter what kind of motion state. Therefore, when the folding screen mobile phone is not in a static state and the common axis is not perpendicular to the horizontal plane, the A+G fusion algorithm with high accuracy can be used.
  • the algorithm used to calculate the hinge angle in step S414 may also be the Gyro algorithm.
  • the angle algorithm module can calculate the hinge angle Angle calculated by the current ACC algorithm, the angular velocity Gyroy1 of the rotation around the y1 axis collected by the first gyro sensor, and the rotation around the y2 axis collected by the second gyro sensor
  • the angular velocity Gyroy2, the preset process covariance Q, and the preset key parameter measurement error R are input into the A+G fusion algorithm model constructed based on Kalman filtering. After repeated iterations in the model for N times, the estimated The hinge angle eAngle is the hinge angle currently detected by the angle algorithm module. Wherein, the value of N can be set according to experience.
  • N when N is determined to be 150 times according to experience, the error between the outputted eAngle and the real hinge angle is small, that is, N can be set to 150.
  • N can be set to 150.
  • steps S404 to S414 are only an exemplary process of calculating the hinge angle once, and if the hinge angle needs to be detected again, steps S404 to S414 are repeated.
  • steps S401 to S403 may not be executed, that is, the angle algorithm module may also be always in the activated state, that is, to detect the hinge angle all the time.
  • the angle algorithm module determines the current motion state (that is, whether it is in a static state) and the relative position between the common axis of the folding screen and the horizontal plane through steps S404, S405, and S408. Positional relationship (that is, whether the common axis is perpendicular to the horizontal plane), and then according to the current motion state and the relative positional relationship between the common axis and the horizontal plane, the target algorithm can be matched from the ACC algorithm, the Gyro algorithm, and the A+G fusion algorithm (that is, the current A hinge angle algorithm with higher calculation accuracy in the scene).
  • the ACC algorithm is used as the target algorithm to calculate the hinge angle.
  • the Gyro algorithm is used as the target algorithm to calculate the hinge angle.
  • the A+G fusion algorithm is used as the target algorithm to calculate the hinge angle.
  • step S409 and step S410 after it is determined that the hinge angle is not in a static state, it is also determined whether the hinge angle needs to be calculated using the determined target algorithm according to whether the hinge angle changes. If the hinge angle does not change, the hinge angle may not be calculated to save power consumption and improve operating efficiency. In some other embodiments, when it is determined in step S404 that it is in a static state, and it is determined in step S405 that the common axis is not perpendicular to the horizontal plane, it can also be determined whether to use the determined hinge angle according to whether the hinge angle changes.
  • Target algorithm ACC algorithm
  • steps S409 and S410 may not be executed, that is, after step S408 determines that the common axis is perpendicular to the horizontal plane, step S412 may be directly performed to calculate the hinge angle, and after it is determined that the common axis is not perpendicular to the horizontal plane , then step S414 can be directly executed to calculate the hinge angle.
  • steps S401 to S403 the purpose of steps S401 to S403 is: the foldable electronic device starts to detect the hinge angle only when the folding screen is not in the closed state, and when the folding screen is in the closed state, then
  • the embodiment of the present application does not make a limitation on whether the closure detection hinge angle is achieved through the cooperation of the closure detection algorithm module and the angle algorithm module, or only through one module.
  • the execution module from step S404 to step S404 can also be executed by one or more other modules.
  • the embodiment of the present application does not limit the specific execution modules of the hinge angle detection method shown in FIG. 4b.
  • the accuracy of the calculated hinge angle is different, so
  • the target algorithm is matched from multiple hinge angle algorithms, and then the target algorithm is used to calculate Hinge angle, can get more accurate hinge angle.
  • the motion state and the relative positional relationship between the common axis of the folding screen and the horizontal plane are taken into account, which will affect the accuracy of the hinge angle algorithm, and then a more accurate hinge angle can be calculated.
  • Page angle optimize the function of hinge angle in electronic equipment.
  • Experiment 1 For the folding screen mobile phone with the self-developed algorithm and the folding screen mobile phone with the X2 algorithm, collect the hinge angle of the folding screen at a frequency of 50HZ, and fold 39 times at a high frequency, with an average folding speed of 1 second each time.
  • the curve of the hinge angle detected by the X2 algorithm does not change smoothly, and there are situations where the detected hinge angle jumps, for example, at 401 seconds and 801 seconds, there are situations where the hinge angle jumps and changes .
  • the change curve of the self-developed algorithm is smoother.
  • the common axis is vertical to the desktop, and the true value of the hinge angle is about 80 degrees.
  • the folding screen mobile phone using the X2 algorithm has a screen-off phenomenon, and the detected hinge angle is 35 degrees, and there is an obvious error.
  • the self-developed algorithm accurately detects the hinge angle of about 80 degrees.
  • the self-developed algorithm is smoother than the X2 algorithm, and the X2 algorithm has an angle jump problem (for example, there is a jump around 1601 seconds, 1801 to 2001 seconds).
  • the actual hinge angle is 73 degrees, while the calculation result of X2 is 32 degrees, and the calculation result of the self-developed algorithm is 54 degrees, and the error is smaller than that of the X2 algorithm.
  • the X2 algorithm also turned off the screen during the slow folding process.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Signal Processing (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Environmental & Geological Engineering (AREA)
  • Mathematical Physics (AREA)
  • Computing Systems (AREA)
  • Telephone Function (AREA)

Abstract

本申请公开了一种合页角度的检测方法及相关设备,涉及折叠屏技术领域,目的在于准确计算出折叠屏的合页角度。具体方案应用于可折叠的电子设备,可折叠的电子设备包括第一屏和第二屏,通过确定电子设备的运动状态、以及公共轴与水平面的相对位置,然后根据运动状态和相对位置,确定出目标算法,确定出的目标算法在当前的运动状态和相对位置下,计算合页角度的准确度较高。其中,目标算法,包括:加速度传感器算法、陀螺仪传感器算法、或者融合算法。融合算法为融合加速度传感器的数据和陀螺仪传感器的数据,计算出合页角度的算法。然后使用确定出的目标算法,可准确计算电子设备的合页角度。

Description

合页角度的检测方法及相关设备
本申请要求于2021年11月19日提交中国国家知识产权局、申请号为202111398160.2、发明名称为“合页角度的检测方法及相关设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及折叠屏技术领域,尤其涉及一种合页角度的检测方法及相关设备。
背景技术
随着折叠屏技术逐渐成熟,市面上的折叠屏手机也越来越多。为了提高用户使用折叠屏手机时的体验,许多开发人员开发了与折叠屏技术相关联的一系列功能。例如,设计了折叠屏手机展开后自适应大屏显示播放视频的功能等等。
然而,在实现这一系列功能的过程中,往往需要获取到当前折叠屏手机的合页角度,以确定出当前折叠屏手机的姿态。因此,现有的折叠屏手机具有获取准确的合页角度的需求。
发明内容
本申请提供了一种合页角度的检测方法及相关设备,目的在于获取准确的合页角度。
为了实现上述目的,本申请提供了以下技术方案:
第一方面,本申请公开了一种合页角度的检测方法,应用于可折叠的电子设备,可折叠的电子设备的折叠屏包括第一屏和第二屏,合页角度的检测方法包括:确定电子设备的运动状态、以及公共轴与水平面的相对位置。其中,公共轴为折叠屏的折叠边所在的轴线。然后根据运动状态和相对位置,确定出目标算法。其中,目标算法,包括:加速度传感器算法、陀螺仪传感器算法、或者融合算法。其中融合算法为融合加速度传感器的数据和陀螺仪传感器的数据,计算出合页角度的算法。最后使用确定出的目标算法,计算电子设备的合页角度。其中,合页角度为第一屏和第二屏之间的夹角。
本申请的合页角度的检测方法,通过确定出的可折叠的电子设备的运动状态、以及公共轴与水平面的相对位置关系,确定出了目标算法,进而使用目标算法来计算合页角度,能得到更为准确的合页角度。本申请实施例在检测合页角度的过程中,考虑到了运动状态以及折叠屏的公共轴与水平面的相对位置关系,对不同算法计算合页角度的准确度的影响,进而可计算出更为准确的合页角度,优化了电子设备中需要使用到合页角度的功能。
在一种可能的实现方式中,电子设备的运动状态包括:处于静止状态或不处于静止状态。公共轴与水平面的相对位置包括:公共轴垂直于水平面或者公共轴不垂直于水平面。
在另一种可能的实现方式中,根据运动状态和相对位置,确定出目标算法,包括:若电子设备处于静止状态,则将加速度传感器算法确定为目标算法。若电子设备不处于静止状态、且公共轴不垂直于水平面,则将融合算法,或者陀螺仪传感器算法确定,确定为目 标算法。若电子设备不处于静止状态、且公共轴垂直于水平面,则将陀螺仪传感器算法确定为目标算法。
在另一种可能的实现方式中,确定电子设备的运动状态,包括:若电子设备的加速度向量的模长与重力加速度之间的差值小于或等于第一预设值,则认为加速度向量的模长与重力加速度的值接近,确定出电子设备的运动状态为静止状态。若加速度向量的模长与重力加速度之间的差值大于第一预设值,则认为加速度向量的模长与重力加速度的值不接近,确定出电子设备的运动状态为不处于静止状态。
在另一种可能的实现方式中,确定公共轴与水平面的相对位置,包括:若加速度向量在公共轴上的分量与重力加速度之间的差值小于或等于第一预设值,则认为加速度向量在公共轴上的分量接近于重力加速度,确定出公共轴垂直于水平面。若加速度向量在公共轴上的分量与重力加速度之间的差值大于第一预设值,则认为加速度向量在公共轴上的分量不接近于重力加速度,确定出公共轴不垂直于水平面。
在另一种可能的实现方式中,使用确定出的目标算法,计算电子设备的合页角度,包括:若确定出合页角度发生变化,则使用确定出的目标算法,计算电子设备的合页角度。
在另一种可能的实现方式中,确定出合页角度发生变化,包括:若角速度差与零之间的差值大于第二预设值,则确定出合页角度发生变化。其中,角速度差为第一陀螺仪传感器绕公共轴的角速度与第二陀螺仪传感器绕公共轴的角速度之间的差值。第一陀螺仪传感器设置于第一屏对应的机体,第二陀螺仪传感器设置于第二屏对应的机体。
在另一种可能的实现方式中,确定电子设备的运动状态、以及公共轴与水平面的相对位置,包括:若确定出折叠屏不处于闭合状态,则确定电子设备的运动状态、以及公共轴与水平面的相对位置。
在另一种可能的实现方式中,确定出折叠屏不处于闭合状态,包括:根据磁力数据,确定出折叠屏不处于闭合状态。其中,磁力数据由磁传感器检测磁铁的磁场强度得到,磁传感器设置于第一屏对应的机体,磁铁设置于第二屏对应的机体。
在另一种可能的实现方式中,根据磁力数据,确定出折叠屏不处于闭合状态,包括:若磁力数据小于或等于第一预设磁力值,则确定出折叠屏不处于闭合状态。
在另一种可能的实现方式中,若目标算法为融合算法,则使用确定出的目标算法,计算电子设备的合页角度,包括:根据第一陀螺仪传感器采集的绕公共轴的角速度、第二陀螺仪传感器采集的绕公共轴的角速度、使用加速度传感器算法计算出的合页角度、采样周期、过程协方差、以及关键参数测量误差,使用融合算法计算得到所述电子设备的合页角度。其中,融合算法基于卡尔曼滤波算法构造,第一陀螺仪传感器设置于第一屏对应的机体,第二陀螺仪传感器设置于第二屏对应的机体。
在另一种可能的实现方式中,若目标算法为加速度传感器算法,则使用确定出的目标算法,计算电子设备的合页角度,包括:根据加速度向量在第一屏坐标系的x1o1z1平面的投影向量,以及加速度向量在第二屏坐标系的x2o2z2平面的投影向量,使用加速度传感器算法计算得到电子设备的合页角度。其中,加速度向量在第一屏坐标系的x1o1z1平面的投影向量由第一加速度传感器采集得到,加速度向量在第二屏坐标系的x2o2z2平面的投影向量由第二加速度传感器采集得到,第一加速度传感器设置于第一屏对应的机体,第二加速 度传感器设置于第二屏对应的机体,第一屏坐标系的y1轴与第二屏坐标系的y2轴平行。
在另一种可能的实现方式中,若目标算法为陀螺仪传感器算法,则使用确定出的目标算法,计算电子设备的合页角度,包括:根据第一陀螺仪传感器采集的绕所述公共轴的角速度、第二陀螺仪传感器采集的绕所述公共轴的角速度、上一次计算出的合页角度、以及采样周期,使用陀螺仪传感器算法计算得到电子设备的合页角度。其中,第一陀螺仪传感器设置于第一屏对应的机体,第二陀螺仪传感器设置于第二屏对应的机体。
第二方面,本申请公开了一种可折叠的电子设备,包括:折叠屏,折叠屏包括第一屏和第二屏,一个或多个处理器,存储器,其上存储有程序。当程序被一个或多个处理器执行时,使得可折叠的电子设备执行如上述第一方面中任意一项所述的合页角度的检测方法。
附图说明
图1a为本申请实施例公开的折叠屏手机在展开及折叠过程中的变化示意图;
图1b为本申请实施例公开的折叠屏手机在播放视频的过程中进行展开以及折叠过程中的视频界面变化示意图;
图2a为本申请实施例公开的可折叠的电子设备的硬件结构示意图;
图2b为本申请实施例公开的折叠屏手机的硬件布局示意图;
图3为本申请实施例公开的可折叠的电子设备的软件框架示意图;
图4a为本申请实施例公开的两个平面之间的夹角示意图;
图4b为本申请实施例公开的合页角度的检测方法的流程示意图;
图5为本申请实施例公开的展开过程中磁传感器检测到的磁力变化示意图;
图6为本申请实施例公开的磁力向量的模长和合页角度之间的关系示意图;
图7a为本申请实施例公开的折叠屏手机检测合页角度的场景图一;
图7b为本申请实施例公开的不同算法下的合页角度变化示意图;
图7c为本申请实施例公开的折叠屏手机检测合页角度的场景图二;
图7d为本申请实施例公开的折叠屏手机检测合页角度的场景图三;
图7e为本申请实施例公开的折叠屏手机检测合页角度的场景图四;
图7f为本申请实施例公开的折叠屏手机检测合页角度的场景图五;
图7g为本申请实施例公开的折叠屏手机检测合页角度的场景图六;
图8a为本申请实施例公开的实验一对应的合页角度变化示意图;
图8b为本申请实施例公开的实验二对应的合页角度变化示意图;
图8c为本申请实施例公开的实验三对应的合页角度变化示意图。
具体实施方式
本申请说明书和权利要求书及附图说明中的术语“第一”、“第二”和“第三”等是用于区别不同对象,而不是用于限定特定顺序。
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如” 等词旨在以具体方式呈现相关概念。
随着折叠屏技术逐渐成熟,市面上的折叠屏手机也越来越多。如图1a所示,折叠屏手机的折叠屏包括:第一屏和第二屏。折叠屏按照折叠边折叠,形成第一屏和第二屏。折叠边所在的虚拟轴线为公共轴。第一屏可以包括第一屏的内屏和外屏,第二屏也可以包括第二屏的内屏和外屏。其中,内屏指的是折叠屏处于折叠状态时,位于内部的屏,外屏反之,是闭合状态时位于外部的屏。第一屏和第二屏之间的夹角为折叠屏手机的合页角度α。折叠屏手机包括:第一屏对应的机体(简称第一机体)和第二屏对应的机体(第二机体)。第一机体和第二机体之间通过连接轴相连。
折叠屏手机的形态可以根据用户的需要而改变。例如,当用户想要方便携带时,则可以将折叠屏手机进行折叠,折叠过程可以从图1a示出的折叠方向按照(1)展开状态、(2)支架状态、(3)折叠状态的顺序变化手机形态。当用户想要大屏观看视频时,则可以将折叠屏手机展开。如图1a所示,可以将折叠屏手机进行展开,展开过程折叠屏手机可以按照图1a示出的(3)折叠状态、(2)支架状态、(1)展开状态的顺序变化手机形态。
为了提高用户使用折叠屏手机的体验,许多开发人员开发了与折叠屏相关联的一系列功能。例如,设计了展开后自适应放大显示内容,且折叠后自适应缩小显示内容的功能。举例说明,如图1b所示,折叠屏手机由图1b的(1)展开为(2)时,播放视频的界面自适应放大,且播放任务仍然继续,当由图1b的(2)折叠为(1)时,播放视频的界面自适应缩小,且播放任务仍然继续。
具体的,与折叠屏相关联的一系列功能还有很多,本申请不再一一赘述。而在执行一系列与折叠屏相关联的功能的过程中,通常需要获取到折叠屏手机的合页角度。例如,随着折叠屏手机的展开或折叠,播放视频的界面需自适应调整显示尺寸。因此,折叠屏手机具有获取准确的合页角度的需求。
介于获取准确的合页角度的需求,本申请实施例提出的一种合页角度的检测方法。本申请实施例提出的合页角度的检测方法,除了可以应用于折叠屏手机中,还可以应用于平板电脑,笔记本电脑,超级移动个人计算机(Ultra-mobile Personal Computer,UMPC),手持计算机,上网本等可折叠的电子设备中,即本申请实施例中可以计算任意的可折叠的电子设备的合页角度。
如图2a所示,可折叠的电子设备200,可以包括:处理器210,智能传感集线器210A,传感器模块220,第一陀螺仪传感器220A,第一加速度传感器220B,第二陀螺仪传感器220C,第二加速度传感器220D,磁传感器220E,折叠屏230,音频模块240,以及磁铁240A。
其中,第一陀螺仪传感器220A、第一加速度传感器220B、以及磁传感器220E可以设置于如图1a示出的第一机体内,第二陀螺仪传感器220C、第二加速度传感器220D、以及磁铁240A可以设置于如图1a示出的第二机体内。
可以理解的是,本实施例示意的结构并不构成对可折叠的电子设备的具体限定。在另一些实施例中,可折叠的电子设备可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。
处理器210可以包括一个或多个处理单元,例如:处理器210可以包括应用处理器(applicationprocessor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processingunit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。
处理器210中还可以包括智能传感集线器(Sensor hub)210A,用于连接并处理来自各种传感器设备的数据。例如,在本申请实施例中,智能传感集线器210A连接并处理第一陀螺仪传感器220A、第一加速度传感器220B、第二陀螺仪传感器220C、第二加速度传感器220D、以及磁传感器220E的数据,根据传感器的数据执行下述图4b示出的合页角度的检测方法,具体执行过程可参见下述图4b的合页角度的检测方法的描述,此处不再赘述。
折叠屏230用于显示图像,视频等。折叠屏230可以理解为是一种可折叠的柔性屏幕。折叠屏230包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode的,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed,Micro-oled,量子点发光二极管(quantum dot light emitting diodes,QLED)等。折叠屏230,包括,第一屏230A和第二屏230B。折叠屏230可沿着折叠边进行展开或者折叠,形成第一屏230A和第二屏230B。第一屏230A和第二屏230B的相关描述可以参考图1a中的第一屏和第二屏。
第一陀螺仪传感器220A可以用于确定电子设备的运动姿态。例如,可以通过第一陀螺仪传感器220A确定第一屏围绕第一屏的三个轴(即,x1,y1和z1轴)的角速度。在本申请实施例中,第一陀螺仪传感器220A可以用于确定出第一屏围绕第一屏坐标系的y1轴(即折叠屏的公共轴)的角速度。第一陀螺仪传感器220A也可以用于拍摄防抖。
第二陀螺仪传感器220C也可以用于确定电子设备的运动姿态。在本申请实施例中,可以通过第二陀螺仪传感器220C确定第二屏围绕第二屏的三个轴(即,x2,y2和z2轴)的角速度。在本申请实施例中,第二陀螺仪传感器220C可以用于确定出第二屏围绕第二屏的y2轴(即折叠屏的公共轴,y1轴和y2轴是同一个轴)的角速度。第二陀螺仪传感器220C也可以用于拍摄防抖。
第一加速度传感器220B可检测第一屏在各个方向上(一般为第一屏所确定出的三轴x1,y1以及z1)加速度的大小。当电子设备静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。
第二加速度传感器220D可检测第二屏在各个方向上(一般为第二屏所确定出的三轴x2,y2以及z2)加速度的大小。当电子设备静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。
磁传感器220E用于检测磁铁240A的磁场强度,得到磁力数据,通过磁力数据检测折叠屏的展开或闭合。在本申请实施例中,磁传感器220E设置于第一屏对应的机体(第一机体)中。智能传感集线器210A根据磁传感器220E在磁铁240A的磁场作用下所获取到的磁力数据,判断折叠屏处于展开状态还是闭合状态。进而根据检测到的开合状态,决定是否启动合页 角度检测。具体的,可参阅图4b示出的合页角度的检测方法中的步骤S401至步骤S403的相关部分。
磁铁240A用于产生磁场,在本申请实施例中,磁铁240A设置于第二屏对应的机体(第二机体)中。在一些实施例中,由于扬声器中具有磁铁,因此磁铁240A也可以是扬声器。扬声器也称“喇叭”,用于将音频电信号转换为声音信号。电子设备可以通过扬声器收听音乐,或收听免提通话。磁铁240A可以让磁传感器220E检测到磁力,随着折叠屏开合状态的变化,磁传感器220E与磁铁240A之间的距离相应发生变化,磁传感器220E检测到的磁铁240A的磁场强度也会发生变化,进而磁传感器220E采集到的磁力数据也会随之发生变化,进而智能传感集线器210A可通过磁传感器220E检测到的磁力数据,检测出折叠屏的开合状态。
举例说明,在一些实施例中,若图2a示出的可折叠的设备为折叠屏手机时,折叠屏手机内部的硬件布局可以如图2b所示。第一陀螺仪传感器220A、第一加速度传感器220B、以及磁传感器220E设置于第一机体内,第二陀螺仪传感器220C、第二加速度传感器220D、以及磁铁240A设置于第二机体内。第一陀螺仪传感器220A和第二陀螺仪传感器220C平行放置,第一加速度传感器220B和第二加速度传感器220D平行放置,以使得第一屏坐标系下的y1轴能够与第二屏坐标系下的y2轴平行。磁铁240A和磁传感器220E之间的距离可以设定为2cm,具体根据应用场景对精度的要求而定。由于磁传感器220E容易被外界磁场干扰,可以不将磁传感器220E放到第一屏的边缘位置。
另外,在上述部件之上,运行有操作系统。例如iOS操作系统,Android开源操作系统,Windows操作系统等。在该操作系统上可以安装运行应用程序。
可折叠的电子设备200的操作系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本申请实施例以分层架构的Android系统为例,示例性说明可折叠的电子设备的软件结构。
图3是本申请实施例的可折叠的电子设备的软件结构框图。
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。
应用程序层可以包括一系列应用程序包。如图3所示,应用程序包可以包括相机,图库,日历,通话,地图,导航,WLAN,蓝牙,音乐,视频,短信息等应用程序。
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。如图3所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器等。
窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。
内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。
电话管理器用于提供电子设备的通信功能。例如通话状态的管理(包括接通,挂断等)。
资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。
通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。
AndroidRuntime包括核心库和虚拟机。Android runtime负责安卓系统的调度和管理。
核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。
应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。
系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维图形处理库(例如:OpenGL ES),2D图形引擎(例如:SGL),角度算法模块以及闭合检测算法模块等。在本申请实施例中,角度算法模块和闭合检测算法模块用于配合执行图4b示出的合页角度的检测算法,具体可参见图4b示出的合页角度的检测算法的相关内容。
表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。
媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。
三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。
2D图形引擎是2D绘图的绘图引擎。
内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动。
需要说明的是,本申请实施例虽然以Android系统为例进行说明,但是其基本原理同样适用于基于iOS、或Windows等操作系统的电子设备。
为了便于理解,这里介绍下本申请实施例涉及的相关技术原理:
(1)第一屏坐标系和第二屏坐标系。如图2b所示,第一屏坐标系x1y1z1下的x1轴和y1轴分别平行或重合于第一屏的长和宽,而z1轴则垂直于第一屏所在的平面。第一屏坐标系所选择的原点o1除了可以在如图2b所示的位置,也可以选择第一屏上的其他位置作为原点。而第二屏坐标系x2y2z2也与第一屏坐标系的建立方式类似,此处不再赘述。当第一屏坐标系和第二屏坐标系选择的原点重合时,y1轴和y2轴也重合,为可折叠电子设备的折叠边所在的虚拟轴线(即可折叠的电子设备的公共轴)。
(2)采用加速度传感器计算合页角度的算法,简称加速度传感器(Acceleration transducer,ACC)算法。ACC算法通过加速度传感器采集到的加速度数据计算出合页角度。加速度数据具体可以是加速度向量的坐标。
具体的,使用ACC算法计算合页角度的原理为:如图4a所示,求取可折叠的电子设备的合页角度α,可以转换为求取第一屏所在平面的法向量
Figure PCTCN2022115421-appb-000001
和第二屏所在平面的法向量
Figure PCTCN2022115421-appb-000002
之间的夹角θ。
静止状态下,可折叠的电子设备只受重力,而重力向量相当于地球坐标系的Z轴,重力向量在手机坐标系(即第一屏坐标系或者第二屏的坐标系)的坐标,相当于是地球坐标系相对于手机坐标系的相对坐标,因此可以将求取第一屏和第二屏之间的合页角度的问题,转换为求取重力向量(即重力加速度向量)在第一屏坐标系以及重力向量(即重力加速度向量)在第二屏坐标系下的夹角。
具体的,静止状态下,第一加速度传感器采集到的第一屏坐标系x1y1z1下的加速度向量(即重力加速度向量)为(A 1,B 1,C 1),第二加速度传感器采集到的第二屏坐标系x2y2z2下的加速度向量为(A 2,B 2,C 2),因此,将A 1,B 1,C 1,A 2,B 2,C 2代入至公式一中,计算得到取第一屏π1的法向量
Figure PCTCN2022115421-appb-000003
和第二屏的法向量
Figure PCTCN2022115421-appb-000004
之间的夹角θ。其中,第一加速度传感器的工作原理可参见图2a中的第一加速度传感器220B的描述,第二加速度传感器的工作原理可参见图2a中的第一加速度传感器220D的描述。
公式一为:
Figure PCTCN2022115421-appb-000005
其中,合页角度α等于180-θ。
又由于第一屏坐标系和第二屏坐标系的y轴是平行的,因此公式一可以转换为公式二,即把第一加速度传感器采集到的加速度向量在第一屏坐标系的x1o1z1平面的投影向量(A 1,C 1),以及第二加速度传感器采集到的加速度向量在第二屏坐标系的x2o2z2平面的投影向量(A 2,C 2)代入至公式二中,计算得到合页角度。
公式二为
Figure PCTCN2022115421-appb-000006
其中,合页角度α等于180-θ。
ACC算法除了可以是公式一、公式二这样的算法形式,还可以有其他的具体算法形式,此处不做限制。
(3)采用陀螺仪传感器计算合页角度的算法,简称陀螺仪传感器(Gyro)算法。Gyro算法即通过陀螺仪传感器采集到的角速度计算出合页角度的算法。具体的,如图2b可以看出,第一屏坐标系和第二屏坐标系的y轴平行或者重合(即折叠边所在的轴),而只有沿y轴的旋转才会影响合页角度的大小。因此在使用角速度计算合页角度时,可以只对y轴的分量进行积分。
具体的,针对每一个采样周期,将第一陀螺仪传感器在该采样周期内采集到的绕y1轴旋转的角速度Gyroy1,以及第二陀螺仪传感器在该采样周期内采集到的绕y2轴旋转的角 速度Gyroy2,以及上一个采样周期计算出的合页角度a代入至公式三中,计算得到当前的合页角度α。其中,第一陀螺仪传感器的工作原理可参见图2a中的第一陀螺仪传感器220A的描述,第二陀螺仪传感器的工作原理可参见图2a中的第二陀螺仪传感器220C的描述。
公式三为:α=a+(Gyroy2-Gyroy1)×delatT。其中,delatT为采样周期的值。
Gyro算法除了可以是公式三这样的算法形式,还可以有其他的具体算法形式,此处不做限制。
(4)采用加速度传感器和陀螺仪传感器计算合页角度的融合算法,简称加速度传感器和陀螺仪传感器的融合算法,即A+G融合算法,在本申请实施例中也可以进一步简称为融合算法。A+G融合算法为通过陀螺仪传感器采集到的角速度数据以及加速度传感器采集到的加速度数据,融合计算出合页角度的算法。其中,可以用于融合角速度和加速度数据的A+G融合算法有很多,例如可以使用卡尔曼滤波融合加速度和角速度的数据,计算出合页角度。本申请实施例中对于融合角速度和加速度计算出合页角度的算法的具体形式,不做限制。
基于卡尔曼滤波所构造的A+G融合算法模型为:
预估计算过程:
eAngle=eAngle+delatT×Gyro;
P=P+Q;
测量计算过程:
K=P/(P+R);
eAngle=eAngle+K×(Angle-eAngle);
P=(1-K)×P。
其中,Gyro=Gyroy2-Gyroy1。Gyroy1是第一陀螺仪传感器在某一个采样周期内采集到的绕y1轴旋转的角速度,Gyroy2是第二陀螺仪传感器在该采样周期内采集到的绕y2轴旋转的角速度。delatT为采样周期的值。eAngle为合页角度算法模型所估算出的合页角度,初始输入到模型中的eAngle可以随意假设,或者使用上一次计算出的合页角度作为eAngle。P为先验估计协方差,初始输入到模型中的P可以是个介于0到1之间的不为0的数,具体可任意设定。Q为过程协方差,相当于是基于卡尔曼滤波所构造的A+G融合算法模型内部的系统误差,是个预先根据经验预先调试设定好的固定值,例如可以为0.000001。R为关键参数测量误差,相当于是采用加速度传感器计算合页角度的算法本身所具有的误差,也是个根据经验预先调试设定好的固定值,例如可以为1.5。K是协方差,属于模型内部运算过程中产生的参数,不需要外部输入到模型中。Angle是采用加速度传感器计算合页角度的算法,所计算出的合页角度值。
在基于卡尔曼滤波所构造的A+G融合算法模型中,预先设定好Q和R的值,且假设 一个任意的eAngle和P输入到模型中,即可通过预估计算过程的公式,预估出一个新的eAngle和P。然后通过测量计算过程中的公式可以更新eAngle和P。再将测量计算过程中更新出的eAngle和P在迭代到预估计算过程中的公式内,反复迭代多次后,即可输出一个较为准确的合页角度eAngle。
基于卡尔曼滤波所构造的A+G融合算法模型中,以陀螺仪传感器所计算出的合页角度算法为主,融合ACC算法所计算出的合页角度的数据,虽然可折叠的电子设备在运动时,通过ACC算法计算出的合页角度误差比较大,但大小变化的趋势,可以弥补Gyro算法的误差。基于卡尔曼滤波所构造的A+G融合算法模型具有计算简单、效率高、收敛快的优点,同时可以滤掉高频、低频的干扰,还可以不依赖精确的初始合页角度。
下面将具体结合图4b,阐述本申请实施例所提出的合页角度的检测方法。
参阅图4b,图4b为本申请实施例提出的一种合页角度的检测方法,应用于本申请实施例提出的可折叠的电子设备中,以折叠屏手机为例,描述以下步骤:
S401、闭合检测算法模块根据磁力数据,确定折叠屏是否处于闭合状态。
其中,磁力数据通过电子设备中的磁传感器采集得到,磁力数据与折叠屏的合页角度之间存在对应关系。通过磁传感器采集到的磁力数据,即可确定出一个对应的合页角度,进而再根据合页角度,确定出折叠屏是否处于闭合状态。
闭合状态指的是折叠屏的合页角度接近于零的状态,非闭合状态则是合页角度大于零的状态,也可以认为是折叠屏打开的状态。如图1a所示,当如图1a中的(1)所示,折叠屏完全展开时,形成折叠屏的展开状态,即不处于闭合状态,将折叠屏按照(1)所示的折叠方向折叠之后,如图1a中的(2)所示,折叠屏的折叠角度α大于零,折叠屏形成支架状态时,同样也是一种折叠屏打开的状态,即也不处于闭合状态。而如图1a中的(3)所示,合页角度α几乎为零时,第一屏和第二屏相重合,此时则为闭合状态(或者称为折叠状态)。
在一些实施例中,磁力数据可以为磁力向量的模长。闭合检测算法模块通过磁力向量的模长与合页角度之间的对应关系,确定出当前的合页角度,进而可以根据确定出的合页角度,确定出折叠屏是否处于闭合状态。
在一些实施例中,磁力向量的模长与合页角度呈负相关关系。具体的,如图5所示,当图2a的电子设备的折叠屏230被折叠为第一屏230A和第二屏230B时,磁铁240A内部的磁铁发出的磁感线会穿过磁传感器220E,进而使得磁传感器220E采集到磁力向量的模长。当折叠屏手机按照(1)、(2)、(3)的顺序展开时,第一屏230A和第二屏230B之间的合页角度在逐渐增大,由图5中的(1)、(2)、(3)可以看出,随着合页角度的增大,穿过磁传感器220E的磁感线就越来越少,磁传感器220E检测到的磁力向量的模长就会越小。
在一些实施例中,当确定出的合页角度大于或等于第一预设角度值时,即磁力向量的模长小于或等于第一预设磁力值时,确定出折叠屏不处于闭合状态(即处于打开状态)。例如,如图6所示,第二预设角度可以设定为10度,而对应的第二预设磁力值为1930。即当磁力向量的模长小于或等于1930时,说明合页角度大于或等于10度,确定出折叠屏不处于闭合状态。
在一些实施例中,当确定出的合页角度小于或等于第二预设角度值时,即磁力向量的模长大于或等于第二预设磁力值时,确定出折叠屏为闭合状态。例如图6所示,可以将第 一预设角度值设定为5度,对应的第一预设磁力值为2800,即当磁力向量的模长大于或等于2800时,说明合页角度小于或等于5度,确定出折叠屏为闭合状态。其中,第一预设角度值和第二预设角度值可以相等,也可以不相等。进而第一预设磁力值和第二预设磁力值也可以相等,也可以不相等。
其中,若步骤S401确定出折叠屏不处于闭合状态,则需要角度算法模块启动进行折叠屏的合页角度的检测,因此需要执行步骤S402,而如果步骤S401确定出折叠屏是处于闭合状态,就说明不需要检测折叠屏的合页角度,因此需执行步骤S403。
需要说明的是,步骤S401是一个实时执行或者周期性执行的步骤,步骤S401可以是每次确定出折叠屏是否处于闭合状态后,都执行步骤S402或S403,也可以是仅在确定出的折叠屏的状态发生变更时(例如由闭合状态变为非闭合状态),再执行步骤S402或步骤S403。
S402、闭合检测算法模块通知角度算法模块启动。
角度算法模块启动,指的是角度算法模块启动检测折叠屏的合页角度。当折叠屏处于不处于闭合状态(即处于打开状态)时,证明可能需要打开折叠屏实现一些功能,(例如图1a、图1b的场景所展现的功能),而这些功能需要检测折叠屏当前的姿态,即需要知道折叠屏的合页角度,因此需要角度算法模块启动检测合页角度。
在一些实施例中,闭合检测算法模块通知角度算法模块启动的方式有很多,例如可以是通过发送启动指令的方式通知角度算法模块。又例如,也可以是发送启动请求的方式通知角度算法模块。具体通知角度算法模块的方式不做限制。
角度算法模块响应闭合检测算法模块的启动通知,启动检测合页角度,开始执行步骤步骤S404。在一些实施例中,启动检测合页角度的准备过程可以是:创建用于执行合页角度检测的线程,以及控制启动合页角度检测过程中所需要用到的传感器启动工作。例如,可以是控制图2a示出的第一陀螺仪传感器220A、第一加速度传感器220B、第二陀螺仪传感器220C、以及第二加速度传感器220D启动工作。
S403、闭合检测算法通知角度算法模块关闭。
角度算法模块关闭,指的是角度算法模块停止检测折叠屏的合页角度。当折叠屏处于闭合状态时,证明当前不需要执行任何需要用到合页角度的功能,因此可以通知角度算法模块关闭,以节省功耗,提高运行效率。
在一些实施例中,闭合检测算法模块通知角度算法模块关闭的方式有很多,例如可以是通过发送关闭指令的方式通知角度算法模块。又例如,也可以是发送关闭请求的方式通知角度算法模块。具体通知角度算法模块的方式不做限制。
角度算法模块响应闭合检测算法模块的关闭通知,停止检测合页角度。在一些实施例中,关闭检测合页角度的过程可以是:结束合页角度检测的线程,以及控制启动合页角度检测过程中所需要用到的传感器停止工作,即传感器停止采集数据。例如,可以是控制图2a示出的第一陀螺仪传感器220A、第一加速度传感器220B、第二陀螺仪传感器220C、以及第二加速度传感器220D停止工作。由于折叠屏处于闭合状态时,角度算法模块不工作,合页角度检测过程中所需要用到的传感器也不工作,停止了合页角度检测,因此降低了功耗,提高了运行效率。
S404、角度算法模块判断是否处于静止状态。
角度算法模块开始检测折叠屏手机的合页角度时,需要先判断当前折叠屏手机的运动状态,以选择出合适的角度算法来计算合页角度。其中,本申请实施例中的静止状态可以理解为是一种相对静止状态,在静止状态下,折叠屏手机相当于只受到重力。
当角度算法模块判断出处于静止状态时,则说明可以适合使用在静止状态下计算精度较高的ACC算法来计算合页角度,当角度算法模块不处于静止状态,则说明并不适合使用ACC算法,进而需要进一步确定当前合适的角度算法。
在一些实施例中,角度算法模块通过获取折叠屏手机的加速度向量的模长,来确定折叠屏手机是否处于静止状态(即确定折叠屏手机的运动状态)。当加速度向量的模长接近于9.8m/s 2,即接近于重力加速度的值的时候,就判断出处于静止状态。具体的,当电子设备的加速度向量的模长与重力加速度之间的差值小于或等于第一预设值,则认为加速度向量的模长与重力加速度接近,判断出电子设备的运动状态为静止状态。而当若加速度向量的模长与重力加速度之间的差值大于第一预设值,则认为加速度向量的模长与重力加速度不接近,判断出电子设备的运动状态为不处于静止状态。其中,第一预设值可以根据实际经验设定,第一预设值的值可以接近于0。
在一些实施例中,可以通过加速度传感器来获取折叠屏手机的加速度向量的模长。例如,若折叠屏手机如图2a所示,则可以通过第一加速度传感器220B或者第二加速度传感器220D来获取加速度向量的模长。
当角度算法模块判断出处于静止状态时,执行步骤S405。而当角度算法模块判断出不处于静止状态时,则执行步骤S408。
S405、角度算法模块判断公共轴是否垂直于水平面。
其中,公共轴如图2b所示,为折叠边所在的轴,也可以理解为是第一屏坐标系x1y1z1下的y1轴或者第二屏坐标系x2y2z2下的y2轴。水平面指的是地球坐标系下的水平面。
当步骤S404确定出处于静止状态之后,则说明当前合适的用于计算合页角度的算法为ACC算法,但ACC算法在公共轴不垂直于水平面时才可准确计算出合页角度,因此需要进一步判断公共轴是否垂直于水平面。
当公共轴垂直于水平面时,且步骤S404还判断出了折叠屏手机处于静止状态时,执行步骤S406。当公共轴不垂直于水平面,且步骤S404还判断出了折叠屏手机处于静止状态时,则执行步骤S407。
在一些实施例中,执行步骤S405的方式可以是:根据加速度在公共轴上的分量来判断公共轴是否垂直于水平面。具体的,通过加速度传感器获取加速度向量在公共轴上的分量,例如可通过图2a中的第一加速度传感器220B或者第二加速度传感器220D。若加速度向量在公共轴上的分量(即在第一屏坐标系下的y1轴的分量,或者第二屏坐标系下的y2轴的分量)接近于9.8,则判断出公共轴垂直于水平面。
在一些实施例中,如果加速度向量在公共轴上的分量与重力加速度之间的差值小于或等于第一预设值,则确定出公共轴垂直于水平面。如果加速度向量在公共轴上的分量与重力加速度之间的差值大于第一预设值,则确定出公共轴不垂直于水平面。其中,第一预设值可以是一个接近于0的数,重力加速度的值为9.8。当加速度向量在公共轴上的分量与重 力加速度之间的差值小于或等于第一预设值时,则认为加速度向量在公共轴上的分量接近于重力加速度9.8,判断出公共轴垂直于水平面。由于步骤S404已判断出处于静止状态,仅受重力,因此当重力加速度的值全部都在公共轴上时,就说明重力的方向与公共轴重合,公共轴垂直于水平面。相反的,当加速度向量在公共轴上的分量与重力加速度之间的差值大于第一预设值时,就认为加速度向量在公共轴上的分量不接近于重力加速度,就判断出了公共轴不垂直于水平面。
S406、角度算法模块不重新计算折叠屏的合页角度。
其中,不重新计算折叠屏的合页角度,也可以理解为是继续使用上一次计算出的折叠屏的合页角度作为当前检测到的折叠屏的合页角度,即最后一次(或者说最新一次)检测出的合页角度作为当前检测出的合页角度。
需要说明的是,自步骤S402通知角度算法模块启动开始,角度算法模块都会周期性的,或者实时的计算折叠屏的合页角度,直到角度算法模块被通知关闭为止。而图4b示出的流程图则是示例性的以某一次检测合页角度的过程为例进行的说明。针对当前的一次检测合页角度的过程,当确定出不需要重新计算合页角度时,则直接将最新一次检测出的合页角度,作为当前检测到的合页角度。
由于步骤S404判断出了折叠屏手机当前处于静止状态,而静止状态下,通过ACC算法计算合页角度,相较于使用Gyro算法会更为准确。但由于步骤S405判断出了公共轴垂直于水平面,而使用ACC算法计算合页角度时,是通过加速度向量在第一屏坐标系下的x1o1z1平面的投影,以及加速度向量在第二屏坐标系下的x2o2z2平面的投影来计算合页角度的。因此,当公共轴垂直于水平面,且为静止状态时,说明折叠屏手机只受重力加速度的影响,且重力加速度向量与公共轴重合,在xoz平面没有投影,无法使用ACC算法计算合页角度。又由于可折叠的电子设备处于静止状态,没有受到其他外力的影响,合页角度没有发生改变,因此可以不重新计算合页角度。而ACC算法的技术原理可参见前述对ACC算法的介绍,此处不再赘述。
举例说明,如图7a所示,当用户将折叠屏手机放置在桌子上,且折叠边与水平面垂直时,此时折叠屏手机内部不重新计算合页角度。
在一些实施例中,不重新计算折叠屏的合页角度之后,可以将上一次计算出的折叠屏的合页角度,作为当前检测出的合页角度,若当前折叠屏手机的功能需要使用到折叠屏的合页角度,则可使用上一次计算出的折叠屏的合页角度。
具体的,在一些实施例中,若当前为角度算法模块首次计算(检测)合页角度,则可以将闭合检测算法模块最新通过磁力向量的模长所计算出的合页角度,作为当前的合页角度。具体的,闭合检测算法模块通过磁力向量的模长计算出合页角度的过程可以参阅步骤S401部分的相关内容,此处不再赘述。在另一些实施例中,若当前不是角度算法模块首次计算合页角度,则直接使用角度算法模块上一次计算出的合页角度作为当前检测出的合页角度即可。
需要说明的是,静止状态下,使用加速度计算合页角度,相较于Gyro算法计算合页角度会更为准确的原因是:通过前述对Gyro算法的介绍可知,Gyro算法需要通过上一个采样周期计算出的合页角度a计算出当前的合页角度。因此,若只使用Gyro算法计算合页角 度,就需要初始的合页角度十分精确,而且随着时间的增加陀螺仪传感器所采集的角速度的误差积累下来会越来越大。因此在通常情况下,使用ACC算法计算合页角度会更为准确。尤其是在静止状态时,只受重力加速度影响,通过ACC算法所计算出的合页角度准确度是比较高的。
举例说明,参阅图7b,图7b采用多种算法检测出的合页角度的变化图。具体的,将合页角度为67度的折叠屏手机的运动状态从静止到晃动,最终回归静止。由图7b可以看出,相较于(1)示出的ACC算法所计算的合页角度,(2)示出的Gyro算法随着时间的增加,测量出的角度逐渐偏离真实值67度。而ACC算法,在静止时段内,即0至73秒,以及721至961秒阶段,所计算出的合页角度的值没有发生变化,都是67度。由此可以看出,静止状态下,使用ACC算法相较于Gyro算法,更可以准确计算出合页角度。
S407、角度算法模块使用ACC算法计算合页角度。
在一些实施例中,当确定出折叠屏手机处于静止状态,且公共轴不垂直于水平面后,说明当前可以使用ACC算法计算合页角度。由前述图7b的相关描述可知,静止状态下使用ACC算法计算合页角度的准确度较高,且当前的公共轴不垂直于水平面,第一加速度传感器可以采集到加速度向量在第一屏坐标系的x1o1z1平面的投影,第二加速度传感器也可以采集到加速度向量在第二屏坐标系的x2o2z2平面的投影,因此满足了使用ACC算法的条件。
举例说明,如图7c示出的场景中,折叠屏手机的被用户静止放置在桌面上,且折叠边与水平面不垂直,此时折叠屏手机在使用ACC算法计算合页角度。
在一些实施例中,角度算法模块获取第一加速度传感器采集到的加速度向量(A 1,B 1,C 1),以及第二加速度传感器采集到的加速度向量(A 2,B 2,C 2),代入至前述提及的公式一中,计算得到cosθ,确定出θ,进而通过合页角度α等于180减去θ,计算出合页角度。
在另一些实施例中,由于第一屏坐标系和第二屏坐标系的y轴相同,因此角度算法模块还可以是获取第一加速度传感器采集到的加速度向量在x1o1z1平面的投影(A 1,C 1),以及第二加速度传感器采集到的加速度向量在x2o2z2平面的投影(A 2,C 2),代入至前述提及到的公式二中,计算得到cosθ,确定出θ,进而通过合页角度α等于180减去θ,计算出合页角度。
具体的,ACC算法的技术原理可参考前述对ACC算法的相关介绍,此处不再赘述。且第一加速度传感器和第二加速度传感器的介绍可参考图2a示出的相关部分,此处也不再赘述。
在静止状态下,虽然合页角度没有发生改变,但仍然可以使用ACC算法计算出准确度较高的合页角度,在之前所得到的合页角度存在误差时,即可通过使用ACC算法计算出准确的合页角度,校正之前计算过程中的误差。
S408、角度算法模块判断公共轴是否垂直于水平面。
角度算法模块在步骤S404中确定出算法模块不处于静止状态后,则说明当前折叠屏手机的加速度不仅有重力加速度,还有其他加速度的影响,因此并不适用于使用ACC算法,进而还需要通过步骤S408进一步确定是需要使用Gyro算法、还是A+G融合算法计算合页角度。
当判断出公共轴垂直于水平面时,说明不能使用到ACC算法计算出的合页角度,进而说明无法使用A+G融合算法,如若需要计算合页角度,则需要使用Gyro算法。当判断出公共轴垂直于水平面时,则说明能够使用到ACC算法计算出的合页角度,因此可以使用A+G融合算法来计算合页角度。
通过步骤S408可确定出当前适合用于计算合页角度的算法是哪个。但通过步骤S408确定出了可使用的算法后,仍需做进一步的判断当前是否需要使用算法去计算合页角度。因此,当判断出公共轴垂直于水平面,确定出适合使用Gyro算法之后,则需要执行步骤S409,进一步判断合页角度是否发生变化,以确定当前是否需要计算合页角度。同样的,当判断出公共轴不垂直于水平面,确定出适合使用A+G融合算法之后,也需要执行步骤S410,进一步判断合页角度是否发生变化,已确定当前是否需要计算合页角度。
其中,步骤S408的执行过程和原理可参考步骤S405,此处不再赘述。
S409、角度算法模块判断合页角度是否发生变化。
当角度算法模块判断出合页角度没有发生变化,则执行步骤S411,即不重新计算合页角度。当角度算法模块判断出合页角度发生了变化,则执行步骤S412,使用Gyro算法来计算合页角度。
在一些实施例中,执行步骤S409的一种实施方式为:角度算法模块根据陀螺仪传感器采集的角速度确定合页角度是否发生变化。具体的,由于能够引起合页角度发生变化的,是y轴的角速度的改变。因此,在一些实施例中,角度算法模块可以获取第一陀螺仪传感器采集到的绕y1轴旋转的角速度Gyroy1,以及获取第二陀螺仪传感器采集到的绕y2轴旋转的角速度Gyroy2。当Gyroy2与Gyroy1的差值等于零(或者接近于零),即Gyroy2与Gyroy1的差值(角速度差)与零之间的差值小于或等于第二预设值时,则说明合页角度没有发生变化。其中,第二预设值可以是接近于零的值。反之,当Gyroy1与Gyroy2的差值不等于零(或者不接近于零),即Gyroy2与Gyroy1的差值(角速度差)与零之间的差值大于第二预设值时,则说明合页角度发生了变化。
S410、角度算法模块判断合页角度是否发生变化。
当角度算法模块判断出合页角度没有发生变化,则执行步骤S413,即不重新计算合页角度。当角度算法模块判断出合页角度发生了变化,则执行步骤S414,使用A+G融合算法来计算合页角度。
具体的,角度算法模块执行步骤S410的过程和原理可参考步骤S409,此处不再赘述。
S411、角度算法模块不重新计算折叠屏的合页角度。
在不处于静止状态的情况下,且公共轴垂直于水平面时,可以确定出适用的算法是Gyro算法,但若判断出合页角度没有发生变化,也可以不重新计算折叠屏的合页角度,可以直接使用上一次计算出的合页角度,即当前该次检测合页角度的过程不再计算当前的合页角度,而是使用最近一次(或者说最新一次)计算出的合页角度作为当前检测出的合页角度。
举例说明,如图7d所示的场景:用户在走路过程中拿着折叠屏手机观看,此时折叠屏手机的折叠边垂直于水平面,虽然折叠屏手机不处于静止状态,但是用户并未改变折叠屏手机的形态,即没有改变合页角度,因此图7d示出的场景下,折叠屏手机不重新计算合页角度。
其中,步骤S411的执行原理和过程可参考步骤S406。
S412、角度算法模块使用Gyro算法计算合页角度。
通过前述的判断是否处于静止状态以及判断公共轴是否垂直于水平面,可确定出当不处于静止状态,且公共轴垂直于水平面时,适用的算法可以是Gyro算法,且又通过前述的判断合页角度是否发生变化确定出当前的合页角度发生了改变,因此,需要使用Gyro算法去计算合页角度。
举例说明,如图7e所示的场景,用户在行走过程中,正在打开折叠屏手机,此时折叠边垂直于地面且不处于静止状态,因此折叠屏手机使用了Gyro算法计算合页角度。
在一些实施例中,角度算法模块获取第一陀螺仪传感器采集到的绕y1轴旋转的角速度Gyroy1,以及第二陀螺仪传感器采集到的绕y2轴旋转的角速度Gyroy2,并将Gyroy1、Gyroy2、以及上一次计算出的合页角度a代入至公式三中,计算得到当前的合页角度α。
其中,Gyro算法的原理可参考前述对Gyro算法的介绍,此处不再赘述。
S413、角度算法模块不重新计算折叠屏的合页角度。
通过前述的判断是否处于静止状态以及判断公共轴是否垂直于水平面,可确定出当不处于静止状态,且公共轴不垂直于水平面时,适用的算法可以是A+G融合算法,但合页角度没有发生变化,因此,不需要重新计算折叠屏的合页角度,可以直接使用上一次计算出的合页角度,即当前该次检测合页角度的过程不再计算当前的合页角度,而是使用最近一次(或者说最新一次)计算出的合页角度作为当前检测出的合页角度。
举例说明,如图7f所示,用户在行走过程中拿着折叠屏手机观看,此时折叠屏手机的折叠边不垂直于水平面,虽然折叠屏手机不处于静止状态,但是用户并未改变折叠屏手机的形态,即没有改变合页角度,因此图7f示出的场景下,折叠屏手机不重新计算合页角度。
S414、角度算法模块使用A+G融合算法计算合页角度。
通过前述的判断是否处于静止状态以及判断公共轴是否垂直于水平面,可确定出当前在不处于静止状态、以及公共轴不垂直与水平面时,适用的算法为A+G融合算法,且又通过前述的判断合页角度是否发生变化确定出当前的合页角度发生了改变,因此,需要使用A+G融合算法去计算合页角度。
举例说明,如图7g所示,用户在行走过程中正在打开折叠屏手机,此时折叠屏手机不处于静止状态,且折叠边也不垂直于水平面,因此折叠屏手机使用A+G融合算法计算合页角度。
需要说明的是,在确定出折叠屏手机不处于静止状态,且公共轴不垂直于水平面时,可以使用A+G融合算法的原因为:通过图7b示出的(3)可知,合页角度为67度的折叠屏手机,在合页角度未发生变化的情况下,由静止、晃动、再到静止的过程中,ACC算法在晃动阶段(即非静止阶段)计算出的合页角度是不准确的,又跟(2)示出的Gyro算法相比,Gyro算法随着时间的推移,计算出的合页角度误差是会越来越大的,而(3)示出的基于卡尔曼滤波的A+G融合算法,所计算出的合页角度不论是什么样的运动状态下,均稳定在67度左右。因此,当折叠屏手机不处于静止状态,且公共轴不垂直于水平面时,可以使用准确度较高的A+G融合算法。
在另一些实施例中,例如对合页角度的准确度要求较低的场景下,步骤S414中用于计 算合页角度的算法也可以是Gyro算法。
在一些实施例中,角度算法模块可以将当前ACC算法计算出的合页角度Angle、第一陀螺仪传感器采集到的绕y1轴旋转的角速度Gyroy1、第二陀螺仪传感器采集到的绕y2轴旋转的角速度Gyroy2、预设的过程协方差Q、预设的关键参数测量误差R输入到基于卡尔曼滤波所构造的A+G融合算法模型中,在模型中反复迭代N次后,输出预估的合页角度eAngle,作为角度算法模块当前检测到的合页角度。其中,N的值可以根据经验进行设定,例如根据经验确定出N为150次时,所输出的eAngle与真实的合页角度之间的误差较小,即可以将N设定为150。具体的,有关A+G融合算法的技术原理可以参考前述对A+G融合算法的介绍,此处不再赘述。
需要说明的是,步骤S404至步骤S414仅仅是示例性的计算一次合页角度的过程,若需要再次检测合页角度,则重复执行步骤S404至步骤S414。
还需要说明的是,在另一些实施例中,也可以不执行步骤S401至步骤S403,即角度算法模块也可以一直处于启动状态,即一直检测合页角度。
由前述步骤S404至步骤S414可知,本申请实施例中,角度算法模块通过步骤S404、步骤S405以及步骤S408来确定当前的运动状态(即是否处于静止状态)以及折叠屏的公共轴与水平面的相对位置关系(即公共轴是否垂直于水平面),进而可根据当前的运动状态以及公共轴与水平面的相对位置关系,从ACC算法、Gyro算法、以及A+G融合算法中匹配出目标算法(即当前场景下计算准确度更高的合页角度算法)。具体的,当处于静止状态、且公共轴不垂直于水平面时,使用ACC算法作为目标算法,计算合页角度。当不处于静止状态、且公共轴垂直于水平面时,使用Gyro算法作为目标算法,计算合页角度。当不处于静止状态、且公共轴不垂直于水平面时,使用A+G融合算法作为目标算法,来计算合页角度。
而步骤S409和步骤S410中,当确定出不处于静止状态之后,还根据合页角度是否发生变化,来确定需不需要使用确定出的目标算法来计算合页角度。如果合页角度没有发生变化,则可以不计算合页角度,节省功耗,提高运行效率。在另一些实施例中,在步骤S404确定出处于静止状态、且步骤S405确定出了公共轴不垂直于水平面时,同样也可以根据合页角度是否发生变化,来确定需不需要使用确定出的目标算法(ACC算法)。
而在另一些实施例中,也可以不执行步骤S409和步骤S410,即步骤S408判断出公共轴垂直于水平面后,可以直接执行步骤S412计算合页角度,而判断出公共轴不垂直于水平面后,则可以直接执行步骤S414计算合页角度。
需要说明的是,判断处于静止状态、判断公共轴是否垂直于水平面以及判断合页角度算法是否发生变化的先后顺序并不影响本申请实施例的实现。
由前述的步骤S401至步骤S403可知,步骤S401至步骤S403的目的为:可折叠的电子设备仅在折叠屏不处于闭合状态时,启动检测合页角度,而在折叠屏处于闭合状态时,则关闭检测合页角度,而具体是通过闭合检测算法模块和角度算法模块配合实现该目的,还是仅通过一个模块实现该目的,本申请实施例不作限制。同样的步骤S404至步骤S404的执行模块除了可以是角度算法模块,也可以是其他的一个或多个模块配合执行。本申请实施例对图4b示出的合页角度的检测方法的具体执行模块不作限制。
由于电子设备在不同的场景(即不同的运动状态、不同的公共轴与水平面的相对位置关系)下,使用不同的合页角度算法,所计算出的合页角度的准确度是不同的,因此本申请实施例中,通过可折叠的电子设备当前的运动状态、以及折叠屏的公共轴与水平面的相对位置关系,从多个合页角度算法中匹配出了目标算法,进而使用目标算法来计算合页角度,能得到更为准确的合页角度。本申请实施例在检测合页角度的过程中,考虑到了运动状态以及折叠屏的公共轴与水平面的相对位置关系,对合页角度算法的准确度的影响,进而可计算出更为准确的合页角度,优化了电子设备中需要使用到合页角度的功能。
以下为应用了本申请实施例的图4b所提供的自研算法的折叠屏手机,与应用了另一种合页角度算法X2的折叠屏手机之间的对比实验:
实验一:分别对自研算法的折叠屏手机和X2算法的折叠屏手机,按照50HZ的频率采集折叠屏的合页角度,且高频率折叠39次,折叠速度平均每次1秒。
如图8a所示,可以看出X2算法检测合页角度的曲线变化不平滑,存在检测到的合页角度跳跃的情况,例如401秒、801秒的时候,都存在合页角度跳跃变化的情况。而自研算法的变化曲线则更为平滑。在实验一结束时刻,公共轴垂直桌面折叠,合页角度的真实值为80度左右,应用X2算法的折叠屏手机出现了灭屏现象,检测出的合页角度为35度,出现明显误差。而自研算法则准确的检测出了80度左右的合页角度。
因此,通过实验一可知,在高频率折叠运动的场景下,本申请实施例的自研算法准确度优于X2算法。
实验二:分别对自研算法的折叠屏手机和X2算法的折叠屏手机,进行了33次慢速折叠,平均2.57秒折叠一次。
如图8b所示,慢速折叠的情况下,自研算法相较于X2算法更加平滑,X2算法有角度跳跃问题(例如1601秒左右、1801至2001秒左右出现跳跃),实验二结束时的实际合页角度为73度,而X2计算结果为32度,自研算法计算结果为54度,误差小于X2算法。且X2算法在慢速折叠的过程还出现了灭屏现象。
因此,通过实验二可知,在低频率折叠运动的场景下,本申请实施例的自研算法准确度优于X2算法。
实验三:分别对自研算法的折叠屏手机和X2算法的折叠屏手机,在用户走路状态下折叠4.7分钟,中间(约11476至12241秒)暂停折叠,检查合页角度是否可以收敛。
如图8c所示,在走路过程中,低频折叠时,自研算法和X2算法的检测精度相当,高频折叠时X2角度跳跃,不平滑,容易出现比实际角度小的计算角度。中间展开暂停时,X2算法还出现错误,之后才逐渐修复收敛。
因此,通过实验三可知,在用户走路状态下对折叠屏折叠运动的场景下,本申请实施例的自研算法准确度优于X2算法。

Claims (14)

  1. 一种合页角度的检测方法,其特征在于,应用于可折叠的电子设备,所述可折叠的电子设备的折叠屏包括第一屏和第二屏,所述合页角度的检测方法包括:
    确定所述电子设备的运动状态、以及公共轴与水平面的相对位置;其中,所述公共轴为所述折叠屏的折叠边所在的轴线;
    根据所述运动状态和所述相对位置,确定出目标算法;其中,所述目标算法,包括:加速度传感器算法、陀螺仪传感器算法、或者融合算法;其中所述融合算法为融合加速度传感器的数据和陀螺仪传感器的数据,计算出合页角度的算法;
    使用确定出的目标算法,计算所述电子设备的合页角度;其中,所述合页角度为所述第一屏和所述第二屏之间的夹角。
  2. 根据权利要求1所述的合页角度的检测方法,其特征在于,所述电子设备的运动状态包括:处于静止状态或不处于静止状态;所述公共轴与水平面的相对位置包括:公共轴垂直于水平面或者公共轴不垂直于水平面。
  3. 根据权利要求2所述的合页角度的检测方法,其特征在于,所述根据所述运动状态和所述相对位置,确定出目标算法,包括:
    若所述电子设备处于静止状态,则将加速度传感器算法确定为目标算法;
    若所述电子设备不处于静止状态、且公共轴不垂直于水平面,则将融合算法,或者陀螺仪传感器算法确定,确定为目标算法;
    若所述电子设备不处于静止状态、且公共轴垂直于水平面,则将陀螺仪传感器算法确定为目标算法。
  4. 根据权利要求1至3任一所述的合页角度的检测方法,其特征在于,所述确定所述电子设备的运动状态,包括:
    若所述电子设备的加速度向量的模长与重力加速度之间的差值小于或等于第一预设值,则确定出所述电子设备的运动状态为静止状态;
    若所述加速度向量的模长与重力加速度之间的差值大于所述第一预设值,则确定出所述电子设备的运动状态为不处于静止状态。
  5. 根据权利要求1至4任一所述的合页角度的检测方法,其特征在于,所述公共轴与水平面的相对位置的确定过程,包括:
    若加速度向量在公共轴上的分量与重力加速度之间的差值小于或等于第一预设值,则确定出所述公共轴垂直于水平面;
    若所述加速度向量在公共轴上的分量与重力加速度之间的差值大于所述第一预设值,则确定出所述公共轴不垂直于水平面。
  6. 根据权利要求1至5任一所述的合页角度的检测方法,其特征在于,所述使用确定出的目标算法,计算所述电子设备的合页角度,包括:
    若确定出合页角度发生变化,则使用确定出的目标算法,计算所述电子设备的合页角度。
  7. 根据权利要求6所述的合页角度的检测方法,其特征在于,所述确定出合页角度发生变化,包括:
    若角速度差与零之间的差值大于第二预设值,则确定出合页角度发生变化;其中,所述角速度差为第一陀螺仪传感器绕公共轴的角速度与第二陀螺仪传感器绕所述公共轴的角速度之间的差值;所述第一陀螺仪传感器设置于所述第一屏对应的机体,所述第二陀螺仪传感器设置于所述第二屏对应的机体。
  8. 根据权利要求1至7任一所述的合页角度的检测方法,其特征在于,所述确定所述电子设备的运动状态、以及公共轴与水平面的相对位置,包括:
    若确定出所述折叠屏不处于闭合状态,则确定所述电子设备的运动状态、以及公共轴与水平面的相对位置。
  9. 根据权利要求8所述的合页角度的检测方法,其特征在于,所述确定出所述折叠屏不处于闭合状态,包括:
    根据磁力数据,确定出折叠屏不处于闭合状态;其中,所述磁力数据由磁传感器检测磁铁的磁场强度得到;所述磁传感器设置于所述第一屏对应的机体;所述磁铁设置于所述第二屏对应的机体。
  10. 根据权利要求9所述的合页角度的检测方法,其特征在于,所述根据磁力数据,确定出折叠屏不处于闭合状态,包括:
    若磁力数据小于或等于第一预设磁力值,则确定出折叠屏不处于闭合状态。
  11. 根据权利要求1至10任一所述的合页角度的检测方法,其特征在于,若所述目标算法为融合算法,则使用确定出的目标算法,计算所述电子设备的合页角度,包括:
    根据第一陀螺仪传感器采集的绕所述公共轴的角速度、第二陀螺仪传感器采集的绕所述公共轴的角速度、使用所述加速度传感器算法计算出的合页角度、采样周期、过程协方差、以及关键参数测量误差,使用所述融合算法计算得到所述电子设备的合页角度;其中,所述融合算法基于卡尔曼滤波算法构造;所述第一陀螺仪传感器设置于所述第一屏对应的机体;所述第二陀螺仪传感器设置于所述第二屏对应的机体。
  12. 根据权利要求1至11任一所述的合页角度的检测方法,其特征在于,若所述目标算法为加速度传感器算法,则使用确定出的目标算法,计算所述电子设备的合页角度,包括:
    根据加速度向量在第一屏坐标系的x1o1z1平面的投影向量,以及加速度向量在第二屏坐标系的x2o2z2平面的投影向量,使用加速度传感器算法计算得到所述电子设备的合页角度;其中,所述加速度向量在第一屏坐标系的x1o1z1平面的投影向量由第一加速度传感器采集得到;所述加速度向量在第二屏坐标系的x2o2z2平面的投影向量由第二加速度传感器采集得到;所述第一加速度传感器设置于所述第一屏对应的机体,所述第二加速度传感器设置于所述第二屏对应的机体;所述第一屏坐标系的y1轴与第二屏坐标系的y2轴平行。
  13. 根据权利要求1至12任一所述的合页角度的检测方法,其特征在于,若所述目标算法为陀螺仪传感器算法,则使用确定出的目标算法,计算所述电子设备的合页角度,包括:
    根据第一陀螺仪传感器采集的绕所述公共轴的角速度、第二陀螺仪传感器采集的绕所述公共轴的角速度、上一次计算出的合页角度、以及采样周期,使用陀螺仪传感器算法,计算得到所述电子设备的合页角度;其中,所述第一陀螺仪传感器设置于所述第一屏对应 的机体,所述第二陀螺仪传感器设置于所述第二屏对应的机体。
  14. 一种可折叠的电子设备,其特征在于,包括:
    折叠屏,所述折叠屏包括第一屏和第二屏;
    一个或多个处理器;
    存储器,其上存储有程序;
    当所述程序被所述一个或多个处理器执行时,使得所述可折叠的电子设备执行如权利要求1至13中任意一项所述的合页角度的检测方法。
PCT/CN2022/115421 2021-11-19 2022-08-29 合页角度的检测方法及相关设备 WO2023087832A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP22871048.9A EP4207722A4 (en) 2021-11-19 2022-08-29 HINGE ANGLE DETECTION METHOD AND ASSOCIATED DEVICE

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111398160.2A CN115002250B (zh) 2021-11-19 2021-11-19 合页角度的检测方法及相关设备
CN202111398160.2 2021-11-19

Publications (1)

Publication Number Publication Date
WO2023087832A1 true WO2023087832A1 (zh) 2023-05-25

Family

ID=83018304

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/115421 WO2023087832A1 (zh) 2021-11-19 2022-08-29 合页角度的检测方法及相关设备

Country Status (3)

Country Link
EP (1) EP4207722A4 (zh)
CN (2) CN115002250B (zh)
WO (1) WO2023087832A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117630414B (zh) * 2024-01-25 2024-05-24 荣耀终端有限公司 加速度传感器校准方法、折叠式电子设备及存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107543546A (zh) * 2016-06-28 2018-01-05 沈阳新松机器人自动化股份有限公司 一种六轴运动传感器的姿态解算方法及装置
CN108027650A (zh) * 2015-09-11 2018-05-11 三星电子株式会社 用于测量显示器之间的角度的方法和使用该方法的电子设备
CN108958362A (zh) * 2017-05-25 2018-12-07 意法半导体股份有限公司 实现融合来自惯性传感器的数据的算法的计算系统和方法
CN110045936A (zh) * 2019-02-23 2019-07-23 华为技术有限公司 一种动态图像的显示方法及电子设备
WO2021128245A1 (en) * 2019-12-27 2021-07-01 Intel Corporation Hinge angle detection

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8854834B2 (en) * 2010-11-16 2014-10-07 Flextronics Ap, Llc Dual screen folding display hinge
CN109302508A (zh) * 2017-07-25 2019-02-01 中兴通讯股份有限公司 一种确定双屏相对位置的方法、显示控制的方法及终端
CN110035147A (zh) * 2019-03-19 2019-07-19 华为技术有限公司 一种保护电子设备可活动部分的方法及电子设备
CN110307821A (zh) * 2019-07-01 2019-10-08 三星电子(中国)研发中心 一种角度测量方法及移动终端
CN110417961B (zh) * 2019-07-17 2021-03-12 Oppo广东移动通信有限公司 折叠屏电子设备及折叠角度确定方法
CN110545354A (zh) * 2019-07-18 2019-12-06 华为技术有限公司 一种具有折叠屏的电子设备的控制方法及电子设备
CN110536004B (zh) * 2019-07-23 2021-08-31 华为技术有限公司 多传感器应用于具有柔性屏幕的电子设备的方法及电子设备
CN112860359A (zh) * 2019-11-28 2021-05-28 华为技术有限公司 一种折叠屏的显示方法及相关装置
CN114237530A (zh) * 2020-01-21 2022-03-25 华为技术有限公司 一种折叠屏的显示方法及相关装置
CN113596242B (zh) * 2020-04-17 2022-10-18 华为技术有限公司 传感器调整方法、装置、电子设备和存储介质
IT202000009937A1 (it) * 2020-05-05 2021-11-05 St Microelectronics Srl Metodo di controllo di un apparecchio elettronico eseguito tramite il calcolo di un angolo di apertura, relativo apparecchio elettronico e prodotto software
CN112099717B (zh) * 2020-09-15 2022-02-15 北京小米移动软件有限公司 折叠屏状态检测方法、装置、电子设备和显示系统
CN112991957A (zh) * 2021-03-22 2021-06-18 合肥维信诺科技有限公司 一种折叠屏及显示设备

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108027650A (zh) * 2015-09-11 2018-05-11 三星电子株式会社 用于测量显示器之间的角度的方法和使用该方法的电子设备
CN107543546A (zh) * 2016-06-28 2018-01-05 沈阳新松机器人自动化股份有限公司 一种六轴运动传感器的姿态解算方法及装置
CN108958362A (zh) * 2017-05-25 2018-12-07 意法半导体股份有限公司 实现融合来自惯性传感器的数据的算法的计算系统和方法
CN110045936A (zh) * 2019-02-23 2019-07-23 华为技术有限公司 一种动态图像的显示方法及电子设备
WO2021128245A1 (en) * 2019-12-27 2021-07-01 Intel Corporation Hinge angle detection

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4207722A4

Also Published As

Publication number Publication date
CN115002250A (zh) 2022-09-02
CN115002250B (zh) 2023-06-13
CN116781809A (zh) 2023-09-19
EP4207722A1 (en) 2023-07-05
EP4207722A4 (en) 2024-04-17

Similar Documents

Publication Publication Date Title
US9898161B2 (en) Method and apparatus for controlling multitasking in electronic device using double-sided display
CN104767915B (zh) 照相机中的磁性照相机组件安装
US8704767B2 (en) Environmental gesture recognition
KR101785598B1 (ko) 기울여서 스크롤하기
US20090276730A1 (en) Techniques for navigation of hierarchically-presented data
US20140347275A1 (en) Method and apparatus for executing applications in portable electronic devices
US20090228779A1 (en) Use of remote services by a local wireless electronic device
US20090225093A1 (en) Buffers for display acceleration
CN116399283B (zh) 合页角度的检测方法及相关设备
KR20110038646A (ko) 모바일 컴퓨팅 디바이스에서의 모션-컨트롤 뷰
WO2021169992A1 (zh) 内容呈现方法、装置、终端设备及计算机可读存储介质
WO2023087832A1 (zh) 合页角度的检测方法及相关设备
CN116033056B (zh) 折叠屏的折叠角度检测方法、装置及可读存储介质
US20120221317A1 (en) Operating system and method based on sensor data
WO2020146122A1 (en) Context-aware system menu behavior for mixed reality
WO2022089407A1 (zh) 一种显示方法及电子设备
WO2021098460A1 (zh) 截屏显示方法、装置和终端设备
US10852836B2 (en) Visual transformation using a motion profile
WO2023066165A1 (zh) 动画效果显示方法及电子设备
WO2022062949A1 (zh) 一种动态元素控制方法、电子设备和计算机可读存储介质
WO2024066976A1 (zh) 控件显示方法及电子设备
CN116033051B (zh) 折叠屏的折叠角度检测方法、装置及可读存储介质
WO2023072113A1 (zh) 显示方法及电子设备
EP4383191A1 (en) Display method and electronic device
WO2022068628A1 (zh) 一种界面的分布式显示方法、电子设备及通信系统

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 2022871048

Country of ref document: EP

Effective date: 20230328