CN113137913A - Electronic equipment and included angle detection method applied to electronic equipment - Google Patents

Electronic equipment and included angle detection method applied to electronic equipment Download PDF

Info

Publication number
CN113137913A
CN113137913A CN202010053050.1A CN202010053050A CN113137913A CN 113137913 A CN113137913 A CN 113137913A CN 202010053050 A CN202010053050 A CN 202010053050A CN 113137913 A CN113137913 A CN 113137913A
Authority
CN
China
Prior art keywords
magnetic
keyboard
display screen
notebook computer
distance
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN202010053050.1A
Other languages
Chinese (zh)
Other versions
CN113137913B (en
Inventor
张浩杰
杨永祥
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN202010053050.1A priority Critical patent/CN113137913B/en
Publication of CN113137913A publication Critical patent/CN113137913A/en
Application granted granted Critical
Publication of CN113137913B publication Critical patent/CN113137913B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B7/00Measuring arrangements characterised by the use of electric or magnetic techniques
    • G01B7/30Measuring arrangements characterised by the use of electric or magnetic techniques for measuring angles or tapers; for testing the alignment of axes

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Position Input By Displaying (AREA)

Abstract

The application relates to the field of computers, and discloses electronic equipment and an included angle detection method applied to the electronic equipment, wherein the electronic equipment is provided with a display screen and a keyboard which can be oppositely opened and closed to form an angle, the electronic equipment comprises a magnetic device, a magnetic inductor and a processor, the magnetic device is used for generating a magnetic field, the magnetic inductor is used for detecting the position of the magnetic inductor relative to the magnetic induction intensity of the magnetic device, and the processor is used for determining the relative angle between the display screen and the keyboard based on the magnetic induction intensity. The electronic equipment data acquisition disclosed by the application relates to data acquired by a magnetic inductor, the data volume is small, the processing speed is high when the data is processed, and the consumed time is short; the magnetic inductor has not strict detection conditions for the magnetic induction intensity, namely whether the notebook computer is in a static state or not, only the magnetic inductor is in a magnetic field generated by a magnetic device, and the measurement precision of the included angle is improved.

Description

Electronic equipment and included angle detection method applied to electronic equipment
Technical Field
The present application relates to the field of computers, and in particular, to an electronic device and an included angle detection method applied to the electronic device.
Background
At present, when a screen and a keyboard of a notebook computer, a flip phone and an electronic device with an openable and closable function form a certain angle, different angles correspond to different use scenes, and taking the notebook computer as an example, when the screen and the keyboard of the notebook computer form a certain angle, different functions of the notebook computer, such as screen-off standby, screen-on working, screen-off unlocking, screen brightness adjustment and the like, can be realized. In order to switch different use scenes of a notebook computer, a relative angle between a display screen and a keyboard of the notebook computer needs to be measured, in a traditional method, an acceleration sensor is respectively installed at the keyboard and the display screen of the notebook computer, and an included angle between the display screen and the keyboard is calculated through relative movement of the acceleration sensor. When the display screen and the keyboard of the notebook computer are relatively opened, if the notebook computer shakes or moves, the acceleration sensor is easily affected, the measured data precision is very low, and further the measurement precision of the included angle between the display screen and the keyboard is low.
Disclosure of Invention
The application aims to provide electronic equipment and an included angle detection method applied to the electronic equipment, and measurement accuracy of a relative angle between a display screen and a keyboard of a notebook computer which is one of the electronic equipment is improved.
In a first aspect, embodiments of the present application disclose an electronic device, where the electronic device disclosed in the first aspect of the present application may be, but is not limited to, a flip-foldable phone, a notebook computer, a reader device, and a foldable device having a display screen and a keyboard, where one or more processors are embedded or coupled, and the like, where the display screen and the keyboard may be opened and closed relatively, the electronic device has a processor and includes a display screen and a keyboard, the display screen and the keyboard are connected by a rotating shaft, and the display screen and the keyboard are opened and closed relatively to form an angle between the display screen and the keyboard, and further, the electronic device further includes:
the magnetic device is arranged on the display screen and used for generating a magnetic field;
the magnetic inductor is arranged on the keyboard and connected with the processor, and when the magnetic inductor is in a magnetic field generated by the magnetic device, the magnetic induction intensity of the position where the magnetic inductor is located relative to the magnetic device is detected;
the processor is used for determining a relative angle between the display screen and the keyboard based on the magnetic induction intensity, wherein the relative angle is an included angle formed between the display screen and the keyboard.
In a possible implementation of the first aspect of the present application, the magnetic device is configured to generate a magnetic field, and the magnetic sensor is configured to detect magnetic induction intensity. The magnetic device may be, but is not limited to, a magnet, the magnetic sensor may be, but is not limited to, a magnetometer, the magnetometer detects the magnetic induction intensity of a magnetic field based on hall effect, for example, in the magnetic field generated by the magnetic device at a position corresponding to a notebook computer where the magnetometer is located, electrons passing through the magnetometer receive lorentz force to be focused, so as to generate an electric field in the direction of electron focusing, the electric field enables subsequent electrons to be subjected to electric force to balance the lorentz force caused by the magnetic field, so that the subsequent electrons can pass through without being deflected, the effect becomes hall effect, and the voltage generated inside the hall effect is hall voltage. Therefore, the magnetometer based on the Hall effect can detect the magnetic induction intensity of the electric field generated by the magnetic device at the position where the magnetometer is positioned. With the opening and closing of the display screen and the keyboard of the notebook computer, the magnetic induction intensity of the magnetic field generated by the magnetic sensor arranged at the keyboard of the notebook computer in the magnetic device is changed.
Compared with the prior art, the electronic equipment disclosed by the first aspect of the application adopts the method that the acceleration sensors are respectively arranged at the keyboard and the display screen of the notebook computer, and the included angle between the display screen and the keyboard is calculated through the relative motion of the acceleration sensors; in addition, compared with the detection condition that the notebook computer is required to be in complete standstill when data acquisition is carried out by using two acceleration sensors in the prior art, the magnetic inductor and the magnetic device of the electronic equipment disclosed by the embodiment of the application are not strict on the detection condition, namely, whether the notebook computer is in the standstill state or not, only the magnetic inductor is in a magnetic field generated by the magnetic device, so that the measurement accuracy of the included angle is improved, in addition, the magnetic inductor is arranged on the keyboard side, the magnetic inductor is convenient to connect and communicate with the processor, the manufacturing difficulty is reduced, and the communication efficiency is improved.
In a possible implementation of the first aspect of the application, where the magnetic device is a magnet, the magnetic induction of the surface of the magnet is not less than 200mT, and where the magnetic sensor is a magnetometer, the detection range of the magnetometer may be between-30 mT and 30 mT.
In a possible implementation of the first aspect of the present application, the position of the magnetic device on the display screen is opposite to the position of the magnetic sensor on the keyboard, and the opposite position includes that a first distance between the position of the magnetic device on the display screen and the rotating shaft is equal to a second distance between the position of the magnetic sensor on the keyboard and the rotating shaft.
In a possible implementation of the first aspect of the present application, the magnetic sensor is fixed inside a keyboard casing of the notebook computer by a fastener, and the magnetic device is clamped inside a casing of the display screen. In a possible implementation of the first aspect of the present application, data communication may be performed between the magnetic inductor and the processor through an inter-integrated circuit (I2C), a Serial Peripheral Interface (SPI), and the like, and in order to improve data communication efficiency and accuracy between the magnetic inductor and the processor, the magnetic inductor and the processor in this embodiment of the present application perform data communication based on an I2C bus, where the magnetic inductor is used as a transmitter in the bus and is used to transmit data related to magnetic induction intensity to the bus; the processor acts as a receiver in the bus for receiving data relating to magnetic induction on the magnetic inductor bus. For both the magnetic sensor and the processor, they have an I2C interface for an I2C bus.
In a possible implementation of the first aspect of the present application, the processor may include one or more processing units, for example, a processing module or a processing circuit that may include a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), a Digital Signal Processor (DSP), a micro-programmed control unit (MCU), an Artificial Intelligence (AI) processor or a programmable logic device (FPGA), and the like. The different processing units may be separate devices or may be integrated into one or more processors. A memory unit may be provided in the processor for storing instructions and data. In some embodiments, the storage unit in the processor is a cache memory.
In a second aspect, an embodiment of the present application discloses an included angle detection method applied to an electronic device, where the included angle detection method includes:
the magnetic inductor collects the magnetic induction intensity in a magnetic field generated by the magnetic device at the current moment;
the processor is based on magnetic induction confirms the relative angle between display screen and the keyboard with the preset, relative angle does the display screen with the contained angle that forms between the keyboard.
In a possible implementation of the second aspect of the present application, for the included angle detection method, the magnetic device may be a magnet, the electronic device may be a notebook computer, the magnetic sensor may be a magnetometer, and the included angle detection method may be:
the processor of the notebook computer drives the magnetometer to acquire the magnetic induction intensity in the magnetic field generated by the magnet at the current moment. The magnetic field intensity of the magnetic field generated by the magnet is detected, and the magnetic field intensity of the magnetic field generated by the magnet is detected.
The processor of the notebook computer executes the instructions stored in the memory unit to calculate the distance between the magnetometer and the magnet. In some embodiments of the present application,after the magnetometer collects the magnetic induction b (x), the magnetic induction b (x) is transmitted to the processor 100 through the data communication module 111 (which may be an I2C bus), and the processor 100 calculates the magnetic induction b (x) according to the calculation formula stored in the storage unit
Figure BDA0002371878830000031
Calculates the relative distance x between the magnet and the magnetometer. In some embodiments of the present application, the property parameter of the surface of the permanent magnet is a constant magnetic induction, i.e. the constant B in the above formula0(in tesla T), the equivalent height of the hall sensor inside the magnetometer is a constant L (in meters), that is, the hall sensor can be equivalent to a cylinder, the height of the cylinder is the equivalent height L, and the constant B is0And the constant L are both stored in a memory unit of the processor 100.
The processor of the notebook computer extracts the first distance and the second distance of the magnetometer and the magnet relative to the rotating shaft of the display screen and the keyboard from the storage unit. That is, the distance between the position where the magnet is installed at the display screen and the rotating shaft of the notebook computer is the second distance b, and the distance between the position where the magnetometer is installed at the keyboard and the rotating shaft of the notebook computer is the first distance a, which can be measured by the scale in advance and stored in the storage unit of the processor.
The processor of the notebook computer calculates a relative included angle between the display screen and the keyboard of the notebook computer based on the cosine theorem in combination with the relative distance, the first distance and the second distance. That is, the second distance b between the position of the magnet mounted on the display screen and the rotation axis of the notebook computer, the first distance a between the position of the magnetometer mounted on the keyboard and the rotation axis of the notebook computer are known quantities, and the processor combines the formula
Figure BDA0002371878830000032
And calculating the relative distance x between the magnetometer and the magnet, and calculating the relative included angle gamma between the display screen and the keyboard of the notebook computer based on the cosine theorem by utilizing the instruction which is stored in the storage unit and is related to the cosine theorem.
And switching and triggering the notebook computer corresponding to the relative included angle by the processor of the notebook computer based on the calculated relative included angle.
In a possible implementation of the second aspect of the present application, the functions of the notebook computer may be a heat dissipation fan function, a brightness adjustment function, a display screen lighting function, and the like, for example, when the relative angle is 30 ° to 60 °, the heat dissipation fan function of the electronic device is switched and triggered, and when the relative angle is changed between 30 ° and 60 °, the fan of the electronic device is correspondingly controlled to operate at different rotation speeds.
By adopting the technical scheme disclosed by the second aspect of the application, the test condition of the magnetometer is not strict, the detection precision of the magnetometer is not influenced no matter whether the notebook computer is in a static state or not, and the precision of the corresponding relative included angle gamma is higher.
In a possible implementation of the second aspect of the present application, for the included angle detection method, the magnetic device may be a magnet, the electronic device may be a notebook computer, the magnetic sensor may be a magnetometer, and the included angle detection method may further be:
the processor of the notebook computer drives the magnetometer to acquire the magnetic induction intensity in the magnetic field generated by the magnet at the current moment. The magnetic field intensity of the magnetic field generated by the magnet is detected, and the magnetic field intensity of the magnetic field generated by the magnet is detected.
The processor of the notebook computer searches for a relative included angle corresponding to the magnetic induction intensity from a preset table stored in the storage unit.
In a possible implementation of the second aspect of the application, the preset table may be in accordance with a formula
Figure BDA0002371878830000041
And formula
Figure BDA0002371878830000042
For preset magnetic induction B (x)1Taking values, and then corresponding to each preset magnetic induction B (x)1Combined with the property parameters of the magnet (magnetic induction constant B of the magnet surface)0) And calculating the preset relative distance x between the corresponding magnet and the magnetometer by taking the equivalent height of the Hall sensor in the magnetometer as a constant L1And filling the table with the data to record to form a preset table. Then, based on that the distance between the position of the magnet arranged at the display screen and the rotating shaft of the notebook computer is a second distance b, the distance between the position of the magnetometer arranged at the keyboard and the rotating shaft of the notebook computer is a first distance a, and a preset relative distance x1Combination formula
Figure BDA0002371878830000043
Calculating the corresponding preset relative included angle gamma1And recording the data into the table to form a preset table, and storing the preset table into a storage unit of the processor. After the notebook computer is put into use, the magnetic induction intensity B (x) detected by the magnetometer is searched from the preset table.
In a possible implementation of the second aspect of the present application, the preset table may also be used to test a notebook computer, that is, a tester adjusts an angle between the display screen and the keyboard, and the magnetometer measures the corresponding magnetic induction intensity in real time, and combines a formula
Figure BDA0002371878830000044
And formula
Figure BDA0002371878830000045
Calculating the preset relative included angle gamma between the display screen and the keyboard1And then recording the data into the table to form a preset table, and storing the preset table into a storage unit of the processor. After the notebook computer is put into use, the magnetic induction intensity B (x) detected by the magnetometer is searched from the preset table.
And triggering the notebook computer corresponding to the relative included angle by the processor of the notebook computer based on the found relative included angle.
By adopting the technical scheme disclosed by the embodiment of the application, the test condition of the magnetometer is not strict, the detection precision of the magnetometer cannot be influenced no matter whether the notebook computer is in a static state or not, in addition, the corresponding relative angle gamma is directly searched from the preset table based on the magnetic induction intensity detected by the magnetometer, a large amount of calculation is avoided, the included angle detection efficiency is higher, and the precision of the relative included angle gamma is also higher. Additional features and corresponding advantages of the present application are set forth in the description that follows, and it is to be understood that at least some of the advantages will be apparent from the description in the present application.
Drawings
Fig. 1 is a schematic structural diagram of a laptop computer in a usage scenario disclosed in an embodiment of the present application;
fig. 2 is a schematic structural diagram of an embodiment of a notebook computer implemented as an electronic device disclosed in the present application;
fig. 3 is a schematic view of an equivalent structure of a notebook computer disclosed in the embodiment of the present application;
FIG. 4 is a schematic view of a process for detecting an angle between a display screen and a keyboard of a notebook computer according to an embodiment of the present application with a magnet and a magnetometer;
FIG. 5 is a schematic flow chart illustrating a process for detecting an angle between a display and a keyboard of a notebook computer according to another embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application is provided by way of specific examples, and other advantages and effects of the present application will be readily apparent to those skilled in the art from the disclosure herein. While the description of the present application will be described in conjunction with the embodiments, this does not represent that the features of the application are limited to that embodiment. On the contrary, the application of the present disclosure with reference to the embodiments is intended to cover alternatives or modifications as may be extended based on the claims of the present disclosure. In the following description, numerous specific details are included to provide a thorough understanding of the present application. The present application may be practiced without these particulars. Moreover, some of the specific details have been omitted from the description in order to avoid obscuring or obscuring the focus of the present application. It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
It should be noted that in this specification, like reference numerals and letters refer to like items in the following drawings, and thus, once an item is defined in one drawing, it need not be further defined and explained in subsequent drawings.
The technical solutions of the present application will be described clearly and completely with reference to the accompanying drawings, and it should be understood that the described embodiments are only some embodiments of the present application, but not all embodiments. All other embodiments obtained by persons skilled in the art based on the embodiments in the present application without creative efforts belong to the protection scope of the present application, and in addition, technologies known by persons skilled in the art can also be used as a part of the embodiments in the present application, and the present application is not described in detail herein.
It is to be appreciated that as used herein, the term module may refer to or include an Application Specific Integrated Circuit (ASIC), an electronic circuit, a processor (shared, dedicated, or group) and/or memory that executes one or more software or firmware programs, a combinational logic circuit, and/or other suitable hardware components that provide the described functionality, or may be part of such hardware components.
It is to be appreciated that in various embodiments of the present application, the processor may be a microprocessor, a digital signal processor, a microcontroller, or the like, and/or any combination thereof. According to another aspect, the processor may be a single-core processor, a multi-core processor, the like, and/or any combination thereof.
At present, when a screen and a keyboard of a notebook computer, a flip phone and an electronic device with an openable and closable function form a certain angle, different angles correspond to different use scenes of the notebook computer, and taking the notebook computer as an example, when the screen and the keyboard of the notebook computer form a certain angle, different functions such as screen-off standby, screen-on working, screen-off unlocking and screen brightness adjustment can be realized. In order to realize the switching of different use scenes of the notebook computer, the relative angle between the display screen and the keyboard of the notebook computer needs to be measured, the traditional method is that an acceleration sensor is respectively installed at the keyboard and the display screen of the notebook computer, and the included angle between the display screen and the keyboard is calculated through the relative motion of the acceleration sensor, but the included angle detection condition is very strict by adopting the method, and the notebook computer needs to be in a complete static state. When the display screen and the keyboard of the notebook computer are relatively opened, if the notebook computer shakes or moves, the acceleration sensor is easily affected, the accuracy of the detected data is very low, and the accuracy of an included angle between the display screen and the keyboard is further low. In addition, because two acceleration sensors are installed, the data volume transmitted to the processor of the notebook computer is relatively large, and the time consumption is long when the data volume is used for calculating the included angle between the display screen and the keyboard.
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
According to some embodiments of the present application, the electronic device is taken as a notebook computer 10 as an example to describe the technical solution of the embodiments of the present application. It should be noted that, an electronic device provided in the present application may be, but is not limited to, a notebook computer, and may also be, but is not limited to, a foldable flip phone, a notebook computer, a reader device, and a foldable device having two bodies (a first body (a display) and a second body (a keyboard)) in which one or more processors are embedded or coupled, where the first body and the second body may be opened and closed relatively, and for the flip phone, the structure of the notebook computer in the following usage scenario may also be provided, so as to implement the function of detecting an included angle.
As shown in fig. 1, fig. 1 is a schematic structural diagram of a notebook computer in a usage scenario disclosed in the embodiment of the present application, and the notebook computer 10 may include a processor 100, a power supply 101, a memory 103, a communication module 105, a magnetic sensor 106, a keyboard 107, an audio module 108, a fan module 109, a display screen 104, a magnetic device 110, a data communication module 111, a sensor module 112, and the like.
In some embodiments of the present application, it is understood that the structure shown in fig. 1 illustrated in the embodiments of the present application does not constitute a specific limitation to the notebook computer 10. In other embodiments of the present application, the notebook computer 10 may include more or fewer components than shown in FIG. 1, or combine certain components, or split certain components, or a different arrangement of components. The components shown in fig. 1 may be in hardware, software, or a combination of software and hardware.
The power supply 101 may include a power supply, power management components, and the like. The power management component is used for managing the charging of the power supply and the power supply of the power supply to other modules.
The communication module 105 may include, but is not limited to, an antenna, a power amplifier, a filter, a Low Noise Amplifier (LNA), and the like. The communication module 105 may provide a solution for wireless communication on the notebook computer 10. In some embodiments of the present application, at least some of the functional modules of the communication module 105 may be disposed in the processor 100, and in some embodiments of the present application, at least some of the functional modules of the communication module 105 may be disposed in the same device as at least some of the functional modules of the processor 100.
In some embodiments of the present application, the communication module 105 may include an antenna, and implement transceiving of an external instruction via the antenna. The communication module 105 may provide a solution for wireless communication applied to the notebook computer 10, including Wireless Local Area Network (WLAN) (e.g., wireless fidelity (Wi-Fi) network), Bluetooth (BT), Global Navigation Satellite System (GNSS), Frequency Modulation (FM), Near Field Communication (NFC), Infrared (IR), and the like. The notebook computer 10 may communicate with a network and other devices via wireless communication techniques.
In some embodiments of the present application, the display screen 104 of the notebook computer 10 is used to display human-computer interaction interfaces, images, videos, and the like. The display screen 104 includes a display panel and a display screen housing, and the display screen housing is specifically composed of a rear case and a frame around the display panel. The display panel may be a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a miniature, a Micro-oeld, a quantum dot light-emitting diode (QLED), or the like.
In some embodiments of the present application, the audio module 108 is used to convert digital audio information into an analog audio signal output or to convert an analog audio input into a digital audio signal. The audio module 108 may also be used to encode and decode audio signals. In some embodiments of the present application, the audio module 108 may be disposed in the processor 100, or some functional modules of the audio module 108 may be disposed in the processor 100.
In some embodiments of the present application, the audio module 108 may include a speaker 1080, an earpiece 1081, a microphone 1082, and a headphone interface 1083. The speaker 1080 is used for converting an audio signal into a sound signal and outputting the sound signal. The notebook computer 10 can listen to music or the like through the speaker 1080. The receiver 1081, also called "receiver", is used for converting the audio electrical signal into an acoustic signal and outputting the acoustic signal. When the notebook computer 10 receives a video call or a voice call, performs a network voice call, or outputs voice information, it can be close to the ear of a person to receive voice through the earphone 1081. The microphone 1082 is used to convert the collected sound signals into electrical signals. In some embodiments of the present application, the microphones 1082 may include a primary microphone disposed at the bottom of the notebook computer 10 and a secondary microphone disposed at the top of the notebook computer 10. The earphone interface 1083 is used to connect a wired earphone.
In some embodiments of the present application, the magnetic device 110 is used to generate a magnetic field, as shown in fig. 2, fig. 2 is a schematic structural diagram of a notebook computer as an electronic device disclosed in the embodiments of the present application, which can be disposed at one side of the display screen of the notebook computer 10 (shown as being clamped inside the housing of the display screen, i.e., clamped between the housing surrounding the edge of the display panel of the display screen and the back cover of the notebook computer), and the magnetic device can also be disposed at other positions of the display screen of the notebook computer according to actual conditions, which is not limited herein. With the notebook computer 10 opened and closed, the magnetic induction intensity of the magnetic field generated by the magnetic sensor 106 at the keyboard of the notebook computer 10 in the magnetic device 110 also changes, and in some embodiments of the present application, the magnetic device 110 may be a magnet. The magnet can be a hard magnet or a soft magnet according to the material property, the hard magnet comprises alnico, samarium cobalt, ferrite, neodymium iron boron and the like, and the soft magnet comprises a silicon steel sheet, a soft magnet core and the like. Hard magnets may also be referred to as permanent magnets. Soft magnets may be referred to as non-permanent magnets, i.e. magnets that only produce magnetism under certain conditions. In some embodiments of the present application, the magnets may include neodymium-iron-boron magnets, samarium-cobalt magnets, alnico magnets, iron-chromium-cobalt magnets, and the like, and in some embodiments of the present application, the shape of the magnets includes: square magnets, tile-shaped magnets, cylindrical magnets, ring magnets, wafer magnets, bar magnets, magnetic frame magnets, and the like. In some embodiments of the present application, magnetism is a basic property of a substance, and the substance may be classified into diamagnetic, paramagnetic, ferromagnetic, antiferromagnetic, and ferrimagnetic substances according to its internal structure and properties in an external magnetic field, and the ferromagnetic and ferrimagnetic substances are ferromagnetic substances, and the diamagnetic and paramagnetic substances are weak magnetic substances. The magnetic materials can be divided into two types of metals and nonmetals according to properties, wherein the former mainly comprises electrical steel, nickel-based alloy, rare earth alloy and the like, and the latter mainly comprises ferrite material and is divided into soft magnetic material, permanent magnetic material, functional magnetic material and the like according to use.
In some embodiments of the present application, when the magnetic device 110 is a magnet, the magnetic induction intensity of the surface of the magnet may be selected to be not less than 200mT, so as to avoid the problem that the magnetic field generated by the magnet is weak, which results in the detection failure or the low detection accuracy of the magnetic sensor 106.
In some embodiments of the present application, as shown in fig. 2, the keyboard 107 is an input device for commands and data of the notebook computer 10, and the keyboard 107 is divided into a main keyboard and a small keyboard, and is composed of a plurality of keys, a keyboard touch pad around the keys, a keyboard housing, and the like, wherein the keys are mainly marked with letters and numbers, and the letters, numbers, punctuation marks, and the like can be input into the notebook computer 10 through the keyboard, so as to issue commands and input data and the like to the notebook computer 10. In some embodiments of the present application, the keyboard 107 is composed of a keyboard housing, indicator lights, a keyboard circuit board, etc. (which are the control core of the entire keyboard, located inside the keyboard housing, and mainly serve as key scanning identification, coding and transmission interfaces).
In some embodiments of the present application, the sensor module 112 includes, but is not limited to, a temperature sensor for collecting the temperature of the CPU of the notebook computer 10, a light sensor for collecting the light of the notebook computer, and the like; the fan module 109 includes
In some embodiments of the present application, as shown in fig. 2, in order to ensure that the magnetic sensor 106 is convenient for communication connection with the processor 100 of the notebook computer, the magnetic sensor 106 may be disposed on the keyboard 107 of the notebook computer, specifically disposed inside the keyboard casing of the notebook computer, and may be fixed inside the keyboard casing of the notebook computer by a fastening member, such as a tiny screw, a screw, or the like, for detecting the magnetic induction intensity of the current position in the magnetic field generated by the magnetic device 110, and the measurement of the magnetic induction intensity may be performed based on a hall effect method, an electromagnetic induction method, or the like, and the corresponding detecting device may be a hall element, a magnetometer, a permanent magnet gaussmeter, or the like. In some embodiments of the present application, the magnetometer detects the magnetic induction of the magnetic field based on the hall effect.
In the magnetic field generated by the magnetic device 110 at the position corresponding to the notebook computer 10 where the magnetometer is located, electrons passing through the magnetometer receive the lorentz force and are gathered, so that an electric field is generated in the direction of gathering the electrons, the electric field can make the later electrons receive the electric force to balance the lorentz force caused by the magnetic field, the later electrons can pass through without deviation, the effect is a hall effect, and the voltage generated inside the hall effect is a hall voltage. Therefore, the magnetometer based on the hall effect can detect the magnetic induction intensity of the electric field generated by the magnetic device 110 at the position where the magnetometer is located.
In some embodiments of the application, magnetometers with a detection accuracy of no more than 1.5mT and a detection range between-30 mT and 30mT may be selected when magnetometers are chosen.
In some embodiments of the present application, in order to ensure the accuracy of detecting the magnetic induction intensity of the magnetic field generated by the magnetic device 110 by the magnetic inductor 110, the magnetic device 110 disposed on the display screen 104 of the notebook computer 10 and the magnetic inductor 106 disposed on the keyboard 107 are opposite in position.
In some embodiments of the present application, for the notebook computer 10, the display screen 104 and the keyboard 107 are pivotally connected through a rotating shaft, a linear distance between a position where the magnetic device 110 is installed at the display screen 104 and the rotating shaft may be between 30mm and 50mm, and a linear distance between a position where the magnetic sensor 106 is installed at the keyboard 107 and the rotating shaft may be between 30mm and 50mm, it is understood that, according to actual conditions and detection accuracy requirements, a linear distance between an installation position of the magnetic device 110 and the magnetic sensor 106 and the rotating shaft may also be other value ranges, and the embodiments of the present application are not limited herein.
In some embodiments of the present application, the processor 100 may include one or more processing units, for example, processing modules or processing circuits that may include a CPU, GPU/DSP, MCU, AI processor, FPGA, or the like. The different processing units may be separate devices or may be integrated into one or more processors. A memory unit may be provided in the processor 100 for storing instructions and data. In some embodiments, the memory location in processor 100 is a cache memory.
In some embodiments of the present application, a storage unit may include one or more tangible, non-transitory computer-readable media for storing data and/or instructions. In some embodiments, the storage unit may include any suitable non-volatile memory such as flash memory and/or any suitable non-volatile storage device, such as at least one of a Hard Disk Drive (HDD), a Compact Disc (CD) drive, and a Digital Versatile Disc (DVD) drive.
In some embodiments of the present application, the data communication module 111 is a module for data communication between the magnetic sensor 106 and the processor 100, and may be an I2C module, an SPI module, or the like. In some embodiments of the present application, magnetic sensor 106 and processor 100 are in data communication over an I2C bus, wherein magnetic sensor 106 acts as a transmitter in the bus for transmitting data related to magnetic induction to the bus; processor 100 acts as a receiver in the bus for receiving data relating to magnetic induction on the magnetic inductor 106 bus. For both the magnetic inductor 106 and the processor 100, there is an I2C interface for an I2C bus.
The following describes the control process of the notebook computer 10 in detail, wherein the notebook computer 10 is taken as an example for illustrative purposes only, and does not limit the electronic device and the control method.
In some embodiments of the present application, a method for controlling a notebook computer 10 is disclosed, in which an opening and closing angle between a display screen 104 and a keyboard 107 of the notebook computer 10 is detected in real time, and then the notebook computer 10 is correspondingly controlled to implement different functions according to values of the opening and closing angle of the display screen 104 and the keyboard 107 of the notebook computer 10, such as a function of controlling a fan module 109 to adjust a rotation speed of the fan, a function of controlling the display screen 104 of the notebook computer 10 to adjust a display brightness of the display screen 104, a function of controlling an audio module 108 to play music and adjust a volume, a function of switching applications and a function of controlling a power supply 101 of the notebook computer 10 to start the shutdown of the notebook computer 10 and the notebook computer 10, and the like.
Referring to fig. 3, fig. 3 is an equivalent structural diagram of a notebook computer disclosed in the embodiment of the present application, in which a distance between a position where the magnetic device 110 is installed at the display screen 104 and a rotation axis of the notebook computer 10 is b, a distance between a position where the magnetic sensor 106 is installed at the keyboard 107 and the rotation axis of the notebook computer 10 is a, and an included angle between the display screen 104 and the keyboard 107 is γ.
In some embodiments of the present application, taking the magnetic device 110 as a permanent magnet for example, and the magnetic inductor 106 as a magnetometer for example, the magnetic induction intensity of the surface of the permanent magnet is a constant, and it is assumed that the constant is B0Assuming that the equivalent height of the hall sensor inside the magnetometer is a constant L (in meters), the hall sensor can be equivalent to a cylinder, the height of the cylinder is the equivalent height L, the magnetometer is located in the magnetic field generated by the permanent magnet, and the magnetic induction B (x) detected by the magnetometer at the position where the magnetometer is located and the constant B are provided0The constant L and the linear distance x (in meters) between the permanent magnet and the magnetometer satisfy the following equation:
Figure BDA0002371878830000091
where b (x) represents the magnetic induction intensity detected by the magnetometer when the magnetometer is x meters away from the magnet.
Further, the distance x between the magnetometer and the magnet is obtained by transforming the above formula (1), which is specifically represented by the following formula:
Figure BDA0002371878830000092
after the processor 100 receives the magnetic induction b (x) transmitted by the magnetometer through the data communication module 111, the distance x between the magnetometer and the magnet is calculated through the instruction related to the above equation (2) stored in the internal storage unit.
In some embodiments of the present application, the magnet is mounted at the display screen 104 at a distance b from the rotation axis of the notebook computer 10, the magnetometer is mounted at the keyboard 107 at a distance a from the rotation axis of the notebook computer 10, wherein a and b are both in meters, a and b can be measured by a graduated scale, specifically, the graduated scale is firstly adopted to measure the position of the display screen 104 with the distance a between the magnet and the position of the rotating shaft, then fixing the magnet at the position, in order to ensure the detection precision of the magnetometer, a can be between 30mm and 50mm, namely, the problem that the detection fails due to the fact that the magnetometer is arranged at a position, which is far away from the rotating shaft, of the display screen 104 and the magnetic field of the magnetometer is weak is avoided, and the problem that the difference of the detection results is too small due to the fact that the magnetometer is arranged at a position, which is far away from the rotating shaft, of the display screen 104 and the magnetic field of the magnetometer is small in change rate is also avoided.
It will be appreciated that the constant B0The constant L, the distance b between the position where the magnet is installed on the display 104 and the rotation axis of the notebook computer 10, and the distance a between the position where the magnetometer is installed on the keyboard 107 and the rotation axis of the notebook computer 10 can be stored as known constants in the memory unit of the processor 100.
In some embodiments of the present application, the distance b between the position where the magnet is mounted on the display screen 104 and the rotation axis of the notebook computer 10, and the distance a between the position where the magnetometer is mounted on the keyboard 107 and the rotation axis of the notebook computer 10 are known quantities, and the processor 100 combines the distance x between the magnetometer and the magnet calculated by the formula (2), and then calculates the included angle γ between the display screen 104 and the keyboard 107 of the notebook computer 10 based on the cosine theorem by using the instruction related to the cosine theorem stored in the storage unit, according to the following calculation formula:
Figure BDA0002371878830000101
in some embodiments of the present application, as the display screen 104 of the notebook computer 10 is opened and closed relative to the keyboard 107, the relative distance x between the magnet mounted on the display screen 104 and the magnetometer mounted on the keyboard 107 is changed, and accordingly, the included angle γ between the display screen 104 and the keyboard 107 is changed, and the notebook computer 10 is triggered to implement different functions according to different included angles γ, as illustrated in table 1 below, and as the included angle γ is different, the functions of the corresponding notebook computer are as follows:
TABLE 1
Included angle gamma Function(s)
0°-50° Extinguishing display screen
Over 55 degree Illuminating a display screen
60°-80° Regulating the speed of a fan
Over 85 DEG Adjusting display brightness of display screen
In some embodiments of the present application, the processor 100 executes the instructions stored in the storage unit corresponding to the angle γ between the display 104 and the keyboard 107 of the notebook computer 10 in the above angle sections, and correspondingly controls to switch between the functions of the notebook computer 10 corresponding to the angle sections, after the power supply supplies power to the notebook computer 10, if the processor 100 calculates that the angle γ between the display 104 and the keyboard 107 of the notebook computer 10 is 57 °, the processor 100 controls the display of the notebook computer 10 to be turned on, and as the angle γ between the display 104 and the keyboard 107 of the notebook computer 10 increases, when the angle γ between the display 104 and the keyboard 107 of the notebook computer 10 is calculated to be 75 °, the processor 100 switches the function of turning on the display to the fan function of the fan module 109, and controls the fan module 109 to execute the instruction of adjusting the rotation speed of the fan, the temperature of the CPU of the notebook computer 10 is acquired according to the received temperature sensor in the sensor module 112, and the rotation speed of the fan is adjusted according to the temperature value of the CPU, for example, when the temperature of the CPU of the notebook computer acquired by the temperature sensor in the sensor module 112 is 55 degrees celsius, the processor 100 controls the fan to operate at a rotation speed of 5000 rpm according to an instruction stored in the storage unit, and further, in order to improve user experience, a prompt box pops up on a user interface of a display screen of the notebook computer 10 to prompt a user of information such as the temperature value of the CPU of the notebook computer at the time, the rotation speed of the fan module 109, and the like, so that the user can know detailed information of the notebook computer 10 and the notebook computer 10 at the time, and the user experience is improved; with the continuous increase of the included angle between the display screen 104 and the keyboard 107 of the notebook computer 10, when the included angle between the display screen 104 and the keyboard 107 of the notebook computer 10 exceeds 85 degrees, the processor 100 switches the fan function of the notebook computer 10 to the display screen brightness adjusting function, the processor 100 correspondingly controls the display screen 104 to execute the instruction for adjusting the display brightness of the display screen 104 stored in the storage unit, after the processor 100 receives the light sensing data acquired by the light sensing sensor in the sensor module 112, the brightness of the display screen 104 is adjusted to the proper brightness by combining the light sensing data, the display brightness of the display screen 104 is automatically adjusted by combining the light sensing data acquired by the light sensing sensor, the power consumption of the notebook computer 10 can be reduced, and the service time of the power supply 101 is prolonged.
For example, when the angle between the display screen 104 and the keypad 107 varies in a range exceeding 85 degrees, the processor 100 controls the amount of current flowing through the LED lamp in the display screen 104, thereby adjusting the brightness of the display screen 104, for example, when the angle between the display screen 104 and the keyboard 107 is increased from 85 degrees to 95 degrees, the processor 100 controls the current flowing through the LED lamp in the display screen 104 to gradually increase, so as to improve the display brightness of the display screen 104 of the notebook computer 10, of course, as the angle between the display screen 104 of the notebook computer 10 and the keyboard 107 gradually increases, the processor 100 controls the current flowing through the LED lamp in the display screen 104 to gradually decrease, thereby reducing the display brightness of the display screen 104 of the notebook computer 10, and at this time, on the human-computer interaction interface of the display screen 104, it can be displayed that what the notebook computer 10 realizes at this time is the display screen brightness adjustment function, the brightness information of the display screen, the numerical value of the included angle between the display screen 104 and the keyboard 107, and the like. It should be noted that the storage unit of the processor 100 stores the corresponding relationship between the CPU temperature of the notebook computer 10 and the rotation speed of the fan module 109, and the processor 100 receives the temperature value collected by the temperature sensor in the sensor module 112 and controls the fan of the fan module 109 to operate at the corresponding rotation speed according to the corresponding relationship.
It is understood that the angle γ between the display screen 104 and the keyboard 107 of the notebook computer 10 may be set to correspond to other types of functions of the notebook computer 10, that is, the angle γ between the display screen 104 and the keyboard 107 may also have other values, and the angle γ between the display screen 104 and the keyboard 107 and the corresponding function may also be other types of functions, and the embodiment of the present invention is not limited thereto, for example, when the angle γ between the display screen 104 and the keyboard 107 of the notebook computer 10 is in a section of 60 ° to 80 °, the audio module 108 may also be simultaneously controlled to control the audio module 108 to open or adjust the playing volume of the audio module 108, and the embodiment of the present invention is not limited to the type shown in table 1.
In some embodiments of the present application, in combination with the above description of the notebook computer 10, referring to fig. 4, fig. 4 is a flowchart illustrating a control method applied to an electronic device according to some embodiments of the present application, for example, fig. 4 is a flowchart illustrating a process of detecting an angle between a display screen and a keyboard of the notebook computer according to some embodiments of the present application in combination with a magnet and a magnetometer. The details of the foregoing description are also applicable in this process, and are not repeated herein to avoid repeating the same content, specifically, as shown in fig. 4, the process includes:
step S40: the processor 100 of the notebook computer 10 drives the magnetometer to acquire the magnetic induction intensity in the magnetic field generated by the magnet at the present moment. That is, when the notebook computer is in some usage scenarios, the magnet is located on one side of the display screen of the notebook computer and generates a magnetic field, and the magnetometer is located on one side of the keyboard of the notebook computer and is located in the magnetic field generated by the magnet and is used for detecting the magnetic induction intensity at the position where the magnetometer is located.
It can be understood that, for the magnetometer, the processor 100 drives the magnetometer, after the notebook computer is started and initialized, the processor 100 sends a control command to the magnetometer to drive the magnetometer to work to acquire the magnetic induction intensity, in addition, the start time of the magnetometer may also be preset in the processor 100, and the magnetometer is driven to work after the start time is reached, for example, after the notebook computer is started, the processor 100 sends a control command to the timer, and when the timer reaches 10 seconds (or may be set to other values), the processor 100 sends a control command to the magnetometer to drive the magnetometer to work, further, for the magnetometer, the power supply supplies power to the notebook computer and the magnetometer, after the notebook computer is started, the magnetometer gets power to immediately perform data acquisition, and sends the acquired data to the processor 100, that is, the magnetometer does not need to be driven to work by the processor 100, data acquisition can be entered immediately after the magnetometer is powered on.
Step S41: the processor 100 of the notebook computer 10 executes instructions stored in the memory unit to calculate the distance between the magnetometer and the magnet.
That is, after the magnetometer collects the magnetic induction b (x), the magnetic induction b (x) is transmitted to the processor 100 through the data communication module 111 (which may be an I2C bus), and the processor 100 calculates the magnetic induction b (x) according to the calculation formula stored in the storage unit
Figure BDA0002371878830000121
Calculates the relative distance x between the magnet and the magnetometer.
In some embodiments of the present application, the property parameter of the surface of the permanent magnet is a constant magnetic induction, i.e. the constant B in the above formula0(in tesla T) the equivalent height of the hall sensor inside the magnetometer is a constant L (in meters), i.e. the hall sensor can be equivalent to a cylinderThe height of the body and the cylinder is the equivalent height L and the constant B0And the constant L are both stored in a memory unit of the processor 100.
In some embodiments of the present application, a memory unit may be integrated in the processor 100, so that no additional memory is required, which saves hardware cost and space resources of the notebook computer 10, in order to increase the data caching speed, the memory unit in the processor 100 may be a cache memory, and the processor 100 may be an FPGA chip, for example, the model of the FPGA chip may be selected from the model of EP3C25E144C 8N.
Step S42: the processor 100 of the notebook computer 10 extracts the first and second distances of the magnetometer and the magnet from the memory unit relative to the display and the axis of rotation of the keyboard. That is, the distance between the position where the magnet is installed on the display screen 104 and the rotation axis of the notebook computer 10 is the second distance b, and the distance between the position where the magnetometer is installed on the keyboard 107 and the rotation axis of the notebook computer 10 is the first distance a, which can be measured by the scale in advance and stored in the storage unit of the processor 100.
Step S43: the processor 100 of the notebook computer 10 calculates a relative angle between the display screen and the keyboard of the notebook computer 10 based on the cosine theorem in combination with the relative distance, the first distance, and the second distance. That is, the second distance b between the position where the magnet is installed on the display screen 104 and the rotation axis of the notebook computer 10, the first distance a between the position where the magnetometer is installed on the keyboard 107 and the rotation axis of the notebook computer 10 are known quantities, and the processor 100 combines the formula
Figure BDA0002371878830000122
The calculated relative distance x between the magnetometer and the magnet is used for calculating a relative included angle γ between the display screen 104 and the keyboard 107 of the notebook computer 10 based on the cosine theorem by using the instruction related to the cosine theorem stored in the storage unit.
It can be understood that, by adopting the technical solution disclosed in the embodiment of the present application, the test condition of the magnetometer is not severe, and the detection precision of the magnetometer is not affected no matter whether the notebook computer 10 is in a static state, and the measurement precision of the corresponding relative included angle γ is also high.
Step S44: the processor 100 of the notebook computer 10 switches and triggers the function of implementing the notebook computer corresponding to the relative angle based on the calculated relative angle. It can be understood that, the functions of the notebook computer implemented according to different relative angles may refer to the descriptions in table 1, and the distinction of the usage scenarios may be set according to specific situations, and is not limited to the manner mentioned in the embodiments of the present application.
In other embodiments of the present application, in combination with the above description of the notebook computer 10, referring to fig. 5, fig. 5 is a flowchart illustrating a control method applied to an electronic device according to another embodiment of the present application, for example, fig. 5 is a flowchart illustrating a process of detecting an angle between a display screen and a keyboard of the notebook computer according to another embodiment of the present application in combination with a magnet and a magnetometer. The details of the foregoing description are also applicable in this process, and are not described herein again in order to avoid repeating the same contents, and the method includes:
step S50: the processor 100 of the notebook computer 10 drives the magnetometer to acquire the magnetic induction intensity in the magnetic field generated by the magnet at the present moment. That is, when the notebook computer is in some usage scenarios, the magnet is located on one side of the display screen of the notebook computer and generates a magnetic field, and the magnetometer is located on one side of the keyboard of the notebook computer and is located in the magnetic field generated by the magnet and is used for detecting the magnetic induction intensity at the position where the magnetometer is located.
It can be understood that, for the processor 100 to drive the magnetometer, after the notebook computer is started and initialized, the processor 100 sends a control command to the magnetometer to drive the magnetometer to work so as to collect the magnetic induction intensity, in addition, the start time of the magnetometer may also be preset in the processor 100, and the magnetometer is driven to work after the start time is reached, for example, after the notebook computer is started, the processor 100 sends a control command to the timer, and when the timer counts for 10 seconds, the processor 100 sends a control command to the magnetometer to drive the magnetometer to work, further, for the magnetometer, the power supply supplies power to the notebook computer and the magnetometer, after the notebook computer is started, the magnetometer can immediately collect data and send the collected data to the processor 100, that is, the magnetometer does not need to be driven to work at the processor 100, data acquisition can be entered immediately after the magnetometer is powered on.
Step S51: the processor 100 of the notebook computer 10 searches for the relative angle corresponding to the magnetic induction intensity from the preset table stored in the storage unit.
In some embodiments of the present application, the predetermined table may be a predetermined magnetic induction b (x) according to the formula (2) and the formula (3)1Taking values, and then corresponding to each preset magnetic induction B (x)1Combined with the property parameters of the magnet (magnetic induction constant B of the magnet surface)0) And calculating the preset relative distance x between the corresponding magnet and the magnetometer by taking the equivalent height of the Hall sensor in the magnetometer as a constant L1And recorded as filled in table 2 below. Then, based on the fact that the distance between the position where the magnet is installed at the display screen 104 and the rotating shaft of the notebook computer 10 is the second distance b, the distance between the position where the magnetometer is installed at the keyboard 107 and the rotating shaft of the notebook computer 10 is the first distance a, and the preset relative distance x1Calculating a corresponding preset relative included angle gamma by combining the formula (3)1And recorded in table 2 below. That is, each preset magnetic induction intensity corresponds to a preset relative distance x and a preset relative included angle gamma1
In some embodiments of the present application, the preset table may also be used to test the notebook computer 10, that is, the tester adjusts the angle between the display screen 104 and the keyboard 109, measures the corresponding magnetic induction intensity in real time by the magnetometer, and calculates the preset relative included angle γ between the display screen 104 and the keyboard 109 by combining the formula (2) and the formula (3)1And then recorded in table 2, and preset table 2 is stored in the memory unit of processor 100. After the notebook computer 10 is put into use, the magnetic induction B (x) detected by the magnetometer is usedThe table 2 of the preset table is searched.
TABLE 2
Figure BDA0002371878830000141
It can be understood that, for the preset table, the magnetometer may be calibrated in a production line to avoid a large measurement error caused by the magnetometer, and in addition, the preset table may be perfected by measuring multiple sets of data and averaging to reduce a calculation error.
Therefore, after the magnetometer collects the magnetic induction B (x) in the magnetic field generated by the magnet at the current moment, the preset magnetic induction B (x) consistent with the magnetic induction B (x) is correspondingly searched from the preset table1Based on the preset magnetic induction B (x) in the preset table1And a predetermined relative distance x1And a predetermined relative angle gamma1The corresponding relation of (a) and (b) is that the relative included angle gamma corresponding to the magnetic induction intensity B (x) is determined, so that a large amount of calculation is avoided, the determination speed of the relative included angle gamma is improved, and the efficiency is high.
Step S52: the processor 100 of the notebook computer 10 triggers switching based on the found relative angle and triggers the function of the notebook computer corresponding to the relative angle. It can be understood that, the functions of the notebook computer implemented according to different relative angles may refer to the descriptions in table 1, and the distinction of the usage scenarios may be set according to specific situations, and is not limited to the manner mentioned in the embodiments of the present application.
It can be understood that, by adopting the technical scheme disclosed in the embodiment of the present application, the test condition of the magnetometer is not severe, and the detection precision of the magnetometer is not affected no matter whether the notebook computer 10 is in a static state or not, and in addition, the corresponding relative angle γ is directly searched from the preset table based on the magnetic induction intensity detected by the magnetometer, so that a large amount of operations are avoided, the included angle detection efficiency is improved, and the measurement precision of the relative included angle γ is improved.
Embodiments of the mechanisms disclosed herein may be implemented in hardware, software, firmware, or a combination of these implementations. Embodiments of the application may be implemented as computer programs or program code executing on programmable systems comprising at least one processor, a storage system (including volatile and non-volatile memory and/or storage elements), at least one input device, and at least one output device. Program code may be applied to input instructions to perform the functions described herein and generate output information. The output information may be applied to one or more output devices in a known manner. For purposes of this application, a processing system includes any system having a processor such as, for example, a Digital Signal Processor (DSP), a microcontroller, an Application Specific Integrated Circuit (ASIC), or a microprocessor.
The program code may be implemented in a high level procedural or object oriented programming language to communicate with a processing system. The program code can also be implemented in assembly or machine language, if desired. Indeed, the mechanisms described in this application are not limited in scope to any particular programming language. In any case, the language may be a compiled or interpreted language.
In some cases, the disclosed embodiments may be implemented in hardware, firmware, software, or any combination thereof. The disclosed embodiments may also be implemented as instructions carried by or stored on one or more transitory or non-transitory machine-readable (e.g., computer-readable) storage media, which may be read and executed by one or more processors. For example, the instructions may be distributed via a network or via other computer readable media. Thus, a machine-readable medium may include any mechanism for storing or transmitting information in a form readable by a machine (e.g., a computer), including, but not limited to, floppy diskettes, optical disks, read-only memories (CD-ROMs), magneto-optical disks, read-only memories (ROMs), Random Access Memories (RAMs), erasable programmable read-only memories (EPROMs), electrically erasable programmable read-only memories (EEPROMs), magnetic or optical cards, flash memory, or a tangible machine-readable memory for transmitting information (e.g., carrier waves, infrared digital signals, etc.) using the internet in an electrical, optical, acoustical or other form of propagated signal. Thus, a machine-readable medium includes any type of machine-readable medium suitable for storing or transmitting electronic instructions or information in a form readable by a machine (e.g., a computer).
It should be noted that, in the embodiments of the apparatuses in the present application, each unit/module is a logical unit/module, and physically, one logical unit/module may be one physical unit/module, or may be a part of one physical unit/module, and may also be implemented by a combination of multiple physical units/modules, where the physical implementation manner of the logical unit/module itself is not the most important, and the combination of the functions implemented by the logical unit/module is the key to solve the technical problem provided by the present application. Furthermore, in order to highlight the innovative part of the present application, the above-mentioned device embodiments of the present application do not introduce units/modules which are not so closely related to solve the technical problems presented in the present application, which does not indicate that no other units/modules exist in the above-mentioned device embodiments.
It is noted that, in the examples and descriptions of this patent, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, the use of the verb "comprise a" to define an element does not exclude the presence of another, same element in a process, method, article, or apparatus that comprises the element. While the present application has been shown and described with reference to certain preferred embodiments thereof, it will be understood by those of ordinary skill in the art that various changes in form and details may be made therein without departing from the spirit and scope of the present application.

Claims (19)

1. An electronic equipment, the electronic equipment has the treater and includes display screen and keyboard, the display screen with the keyboard is connected through the pivot, the display screen with the keyboard opens and shuts relatively so that form the angle between the display screen with the keyboard, its characterized in that, electronic equipment still includes:
the magnetic device is arranged on the display screen and used for generating a magnetic field;
the magnetic inductor is arranged on the keyboard and connected with the processor, and when the magnetic inductor is in a magnetic field generated by the magnetic device, the magnetic inductor detects the magnetic induction intensity of the position where the magnetic inductor is located relative to the magnetic device;
the processor is used for determining a relative angle between the display screen and the keyboard based on the magnetic induction intensity, and the relative angle is an included angle formed between the display screen and the keyboard.
2. The electronic device of claim 1, wherein the magnetic inductor comprises a magnetometer and the magnetic device comprises a magnet.
3. The electronic device of claim 2, wherein the magnetometer has a detection accuracy of no more than 1.5mT, and the magnetometer has a detection range between-30 mT to 30 mT.
4. The electronic device of claim 1, wherein the magnetic device is disposed on a side of a display surface of the display screen, and the magnetic sensor is disposed on a side of a key surface of the keyboard.
5. The electronic device of claim 4, wherein the position of the magnetic device on the display screen and the position of the magnetic sensor on the keyboard are opposite, the opposite positions comprising a first distance between the position of the magnetic device on the display screen and the rotational axis being equal to a second distance between the position of the magnetic sensor on the keyboard and the rotational axis.
6. The electronic device of claim 5, wherein the magnetic sensor is fixed inside a keyboard housing of the notebook computer by a fastener, and the magnetic device is clamped inside a housing of the display screen.
7. The electronic device according to claim 2 or 3, wherein the magnetic induction of the surface of the magnet is not less than 200 mT.
8. The electronic device of any of claims 1-6, wherein a first distance from the magnetic device to the axis of rotation and a second distance from the magnetic sensor to the axis of rotation are each between 30mm and 50 mm.
9. The electronic device of any of claims 1-6, wherein the processor and the magnetic sensor communicate via an I2C bus.
10. An included angle detection method applied to an electronic device, based on the electronic device of any one of claims 1 to 9, the included angle detection method comprising:
the magnetic inductor collects the magnetic induction intensity in a magnetic field generated by the magnetic device at the current moment;
the processor is based on magnetic induction confirms the relative angle between display screen and the keyboard with the preset, relative angle does the display screen with the contained angle that forms between the keyboard.
11. The angle detection method applied to an electronic device according to claim 10, wherein the magnetic device includes a magnet, and the presetting includes:
the processor obtains a relative distance between the magnet and the magnetic inductor based on the attribute parameters of the magnet and the magnetic induction;
the processor extracting a first distance and a second distance of the magnetic inductor and the magnet relative to an axis of rotation of the display screen and the keyboard;
the processor calculates a relative angle between the display screen and the keyboard based on a cosine theorem in combination with the relative distance, the first distance, and the second distance.
12. The method according to claim 11, wherein the property parameter includes a magnetic induction intensity of the surface of the magnet, and the magnetic induction intensity of the surface of the magnet is constant.
13. The angle detection method applied to an electronic device according to claim 11 or 12, wherein the relative distance is calculated by using the following formula:
Figure FDA0002371878820000021
wherein, B isoIs the magnetic induction of the surface of the magnet, L is the equivalent height of the magnetic inductor, BxThe a is the relative distance.
14. The method of claim 13, wherein the relative angle is calculated using the following equation:
Figure FDA0002371878820000022
wherein γ is the relative angle, b is a first distance between the magnet and the joint of the rotating shaft, and c is a second distance between the magnetic inductor and the joint of the rotating shaft.
15. The angle detection method applied to an electronic device according to claim 10, wherein the presetting includes: based on the magnetic induction intensity, searching a relative angle corresponding to the magnetic induction intensity from a preset table and a preset table which contain the corresponding relation between the preset magnetic induction intensity and the preset relative angle.
16. The method as claimed in claim 15, wherein the predetermined table further includes a predetermined relative distance between the magnetic device and the magnetic sensor, and wherein one of the predetermined relative distances corresponds to one of the predetermined relative angle and the predetermined magnetic induction intensity.
17. The angle detection method applied to electronic equipment according to claim 16, wherein the presetting further comprises:
and determining the relative distance between the magnetic device and the magnetic inductor based on the magnetic induction intensity, and searching a preset relative angle corresponding to the relative distance from the preset table according to the relative distance.
18. An angle detection method applied to electronic equipment according to any one of claims 10 to 12 or 15 to 17, wherein after the relative angle is obtained, a function of the electronic equipment corresponding to the relative angle is switched and triggered.
19. The method as claimed in claim 18, wherein the fan heat dissipation function of the electronic device is switched and triggered when the relative angle is 30 ° to 60 °, and the fan of the electronic device is controlled to operate at different speeds when the relative angle is changed between 30 ° and 60 °.
CN202010053050.1A 2020-01-17 2020-01-17 Electronic equipment and included angle detection method applied to electronic equipment Active CN113137913B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010053050.1A CN113137913B (en) 2020-01-17 2020-01-17 Electronic equipment and included angle detection method applied to electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010053050.1A CN113137913B (en) 2020-01-17 2020-01-17 Electronic equipment and included angle detection method applied to electronic equipment

Publications (2)

Publication Number Publication Date
CN113137913A true CN113137913A (en) 2021-07-20
CN113137913B CN113137913B (en) 2022-10-11

Family

ID=76808446

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010053050.1A Active CN113137913B (en) 2020-01-17 2020-01-17 Electronic equipment and included angle detection method applied to electronic equipment

Country Status (1)

Country Link
CN (1) CN113137913B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113793766A (en) * 2021-09-30 2021-12-14 维沃移动通信有限公司 Electronic device
CN116048246A (en) * 2022-08-25 2023-05-02 荣耀终端有限公司 Display assembly and control method of display device
CN117707321A (en) * 2023-06-30 2024-03-15 荣耀终端有限公司 False touch prevention identification method and related equipment
WO2024098889A1 (en) * 2022-11-08 2024-05-16 荣耀终端有限公司 Electronic device and method for controlling working state of electronic device

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090052123A1 (en) * 2007-01-11 2009-02-26 Alps Electric Co., Ltd. Electronic device including a rotation unit
US20130018628A1 (en) * 2011-07-11 2013-01-17 Parco Adam Louis Methods and devices to determine a mobile device housing position
US20130328825A1 (en) * 2012-06-08 2013-12-12 Apple Inc. Detection system and method between accessory and electronic device
US20170082461A1 (en) * 2015-09-22 2017-03-23 Apple Inc. Portable computer sleep mode system with angle sensor
CN206891452U (en) * 2017-06-15 2018-01-16 广西三创科技有限公司 Screen rotation angle induction device
CN207207878U (en) * 2017-05-16 2018-04-10 深圳市保千里电子有限公司 A kind of steering indicating light detection means and vehicular traffic
CN207601693U (en) * 2018-01-02 2018-07-10 合肥联宝信息技术有限公司 A kind of turnover type notebook
CN110398197A (en) * 2019-07-31 2019-11-01 联想(北京)有限公司 A kind of electronic equipment and information processing method

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090052123A1 (en) * 2007-01-11 2009-02-26 Alps Electric Co., Ltd. Electronic device including a rotation unit
US20130018628A1 (en) * 2011-07-11 2013-01-17 Parco Adam Louis Methods and devices to determine a mobile device housing position
US20130328825A1 (en) * 2012-06-08 2013-12-12 Apple Inc. Detection system and method between accessory and electronic device
US20170082461A1 (en) * 2015-09-22 2017-03-23 Apple Inc. Portable computer sleep mode system with angle sensor
CN207207878U (en) * 2017-05-16 2018-04-10 深圳市保千里电子有限公司 A kind of steering indicating light detection means and vehicular traffic
CN206891452U (en) * 2017-06-15 2018-01-16 广西三创科技有限公司 Screen rotation angle induction device
CN207601693U (en) * 2018-01-02 2018-07-10 合肥联宝信息技术有限公司 A kind of turnover type notebook
CN110398197A (en) * 2019-07-31 2019-11-01 联想(北京)有限公司 A kind of electronic equipment and information processing method

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113793766A (en) * 2021-09-30 2021-12-14 维沃移动通信有限公司 Electronic device
CN116048246A (en) * 2022-08-25 2023-05-02 荣耀终端有限公司 Display assembly and control method of display device
CN116048246B (en) * 2022-08-25 2023-11-10 荣耀终端有限公司 Display assembly and control method of display device
WO2024098889A1 (en) * 2022-11-08 2024-05-16 荣耀终端有限公司 Electronic device and method for controlling working state of electronic device
CN117707321A (en) * 2023-06-30 2024-03-15 荣耀终端有限公司 False touch prevention identification method and related equipment

Also Published As

Publication number Publication date
CN113137913B (en) 2022-10-11

Similar Documents

Publication Publication Date Title
CN113137913B (en) Electronic equipment and included angle detection method applied to electronic equipment
CN108370084B (en) Dynamic antenna power control for multi-context devices
AU2016204111B2 (en) Sensor fusion
TWI544713B (en) Wireless charging device and method thereof
KR102049075B1 (en) Method and apparatus for displaying information on wireless charging pad in electronic device
WO2020103548A1 (en) Video synthesis method and device, and terminal and storage medium
KR102656655B1 (en) Electronic device for performing operation based on a moving direction of an external electronic device and method for the same
US20180364811A1 (en) Wearable sensor system for providing a personal magnetic field and techniques for horizontal localization utilizing the same
CN107202572B (en) Electronic compass calibration method, electronic compass and electronic equipment
US11448527B2 (en) Magnetic encoder, method, system for detecting absolute electrical angle, and readable storage medium
CN109003621B (en) Audio processing method and device and storage medium
CN103902002A (en) Power supply managing method and device
CN111060000A (en) Rotation angle detection device and method and electronic equipment
US10024689B2 (en) Using magnets to detect a state of a cover
EP1988690B1 (en) Acoustic device
US8965731B2 (en) Methods and devices to determine a mobile device housing position
EP4120242A1 (en) Method for in-chorus mixing, apparatus, electronic device and storage medium
CN114448015B (en) Temperature compensation method and device, terminal equipment and readable storage medium
US8249674B2 (en) Portable electronic device
CN111488895B (en) Countermeasure data generation method, device, equipment and storage medium
CN103210277B (en) Electronic equipment
CN104951203A (en) Device control method and device and electronic device
CN111638564B (en) Rainfall forecasting method, device, equipment and storage medium
US20110210754A1 (en) Capacitance sensing module and electronic apparatus
JP2004020289A (en) Foldable personal terminal, and magnetic sensor

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant