WO2020038122A1 - 接近事件检测元件切换控制方法和装置 - Google Patents
接近事件检测元件切换控制方法和装置 Download PDFInfo
- Publication number
- WO2020038122A1 WO2020038122A1 PCT/CN2019/094200 CN2019094200W WO2020038122A1 WO 2020038122 A1 WO2020038122 A1 WO 2020038122A1 CN 2019094200 W CN2019094200 W CN 2019094200W WO 2020038122 A1 WO2020038122 A1 WO 2020038122A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- state
- screen
- switching
- terminal device
- current
- Prior art date
Links
- 238000001514 detection method Methods 0.000 title claims abstract description 47
- 238000000034 method Methods 0.000 title claims abstract description 45
- 238000013459 approach Methods 0.000 claims description 21
- 238000004590 computer program Methods 0.000 claims description 10
- 238000003860 storage Methods 0.000 claims description 6
- 230000000903 blocking effect Effects 0.000 abstract 1
- 230000006870 function Effects 0.000 description 9
- 238000013480 data collection Methods 0.000 description 6
- 238000010586 diagram Methods 0.000 description 6
- 230000008569 process Effects 0.000 description 6
- 238000005516 engineering process Methods 0.000 description 4
- 238000012545 processing Methods 0.000 description 4
- 238000002834 transmittance Methods 0.000 description 3
- 238000003491 array Methods 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 2
- 239000000463 material Substances 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- DWDGSKGGUZPXMQ-UHFFFAOYSA-N OPPO Chemical compound OPPO DWDGSKGGUZPXMQ-UHFFFAOYSA-N 0.000 description 1
- 230000006978 adaptation Effects 0.000 description 1
- 238000013475 authorization Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 239000000835 fiber Substances 0.000 description 1
- 239000012634 fragment Substances 0.000 description 1
- 230000014509 gene expression Effects 0.000 description 1
- 238000003475 lamination Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 239000004984 smart glass Substances 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 230000001960 triggered effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0487—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
- G06F3/0488—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/017—Gesture based interaction, e.g. based on a set of recognized hand gestures
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/03—Arrangements for converting the position or the displacement of a member into a coded form
- G06F3/041—Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means
- G06F3/0416—Control or interface arrangements specially adapted for digitisers
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
- G06F3/04847—Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0487—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/48—Program initiating; Program switching, e.g. by interrupt
- G06F9/4806—Task transfer initiation or dispatching
- G06F9/4843—Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
- G06F9/485—Task life-cycle, e.g. stopping, restarting, resuming execution
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3206—Monitoring of events, devices or parameters that trigger a change in power modality
- G06F1/3212—Monitoring battery levels, e.g. power saving mode being initiated when battery voltage goes below a certain level
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3206—Monitoring of events, devices or parameters that trigger a change in power modality
- G06F1/3231—Monitoring the presence, absence or movement of users
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2203/00—Indexing scheme relating to G06F3/00 - G06F3/048
- G06F2203/041—Indexing scheme relating to G06F3/041 - G06F3/045
- G06F2203/04101—2.5D-digitiser, i.e. digitiser detecting the X/Y position of the input means, finger or stylus, also when it does not touch, but is proximate to the digitiser's interaction surface and also measures the distance of the input means within a short range in the Z direction, possibly with a separate measurement setup
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2203/00—Indexing scheme relating to G06F3/00 - G06F3/048
- G06F2203/041—Indexing scheme relating to G06F3/041 - G06F3/045
- G06F2203/04108—Touchless 2D- digitiser, i.e. digitiser detecting the X/Y position of the input means, finger or stylus, also when it does not touch, but is proximate to the digitiser's interaction surface without distance measurement in the Z direction
-
- Y—GENERAL 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
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Definitions
- the present disclosure relates to the field of electronic technology, and in particular, to a method and device for switching control of a proximity event detection element.
- terminal devices can implement proximity sensor recognition based on proximity sensors, which can support upper-layer applications of terminal devices to provide various functional services based on proximity data, for example, support for game applications to provide proximity-based services. Gesture operation of data and motion recognition function.
- the present disclosure aims to solve at least one of the technical problems in the related art.
- An embodiment of the first aspect of the present disclosure proposes a method for controlling the switching of a proximity event detection element, which includes the following steps: obtaining a switching instruction for a screen of a terminal device to switch from a current first state to a second state; and calling a pre-established switching thread, Switching a first element corresponding to the first state to a second element corresponding to the second state, wherein the first element is used to detect a screen approach event in the first state, and the first The two elements are used to detect a screen approach event in the second state; and after receiving a notification of a switching success fed back by the switching thread, switching the screen of the terminal device from the first state to the second state .
- An embodiment of the second aspect of the present disclosure provides a proximity event detection element switching control device, including: an acquisition module for acquiring a switching instruction for a screen of a terminal device to switch from a current first state to a second state; a first switching module For invoking a pre-established switching thread to switch a first element corresponding to the first state to a second element corresponding to the second state, wherein the first element is configured to detect the first state A screen approach event in a state, the second element is configured to detect a screen approach event in the second state; a second switching module is configured to: The screen of the terminal device is switched from the first state to the second state.
- An embodiment of the third aspect of the present disclosure provides a terminal device including a memory, a processor, and a computer program stored on the memory and executable on the processor.
- the processor executes the computer program, the processor implements the first
- the method for controlling switching of a proximity event detection element according to the embodiment.
- An embodiment of the fourth aspect of the present disclosure proposes a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the proximity event detection element switching control according to the foregoing embodiment of the first aspect is implemented. method.
- the screen of the terminal device After receiving the notification of the switching success feedback from the switching thread, the screen of the terminal device is changed from the first One state is switched to the second state. Therefore, when the screen is in different states, different components are used to detect the proximity data, which improves the accuracy of the proximity data collection, and avoids the screen state switching caused by the delay of the corresponding component switching of the screen proximity event when the screen state is switched. Being blocked improves the smoothness of screen state switching and improves the user experience.
- FIG. 1 is a flowchart of a method for controlling a proximity event detection element switching according to an embodiment of the present disclosure
- FIG. 2 is a flowchart of a method for controlling a proximity event detection element switching according to another embodiment of the present disclosure
- FIG. 3 is a flowchart of a method for controlling a proximity event detection element switching according to another embodiment of the present disclosure
- FIG. 4-A is a schematic diagram of a screen state switching process according to an embodiment of the present disclosure.
- FIG. 4-B is a schematic diagram of a screen state switching process according to another embodiment of the present disclosure.
- FIG. 5 is a schematic plan view of a terminal device according to some embodiments of the present disclosure.
- FIG. 6 is a schematic cross-sectional view of a terminal device according to some embodiments of the present disclosure.
- FIG. 7 is another schematic cross-sectional view of a terminal device according to some embodiments of the present disclosure.
- FIG. 8 is a schematic structural diagram of a proximity event detection element switching control device according to an embodiment of the present disclosure.
- FIG. 9 is a schematic structural diagram of a proximity event detection element switching control device according to an embodiment of the present disclosure.
- FIG. 10 is a schematic structural diagram of a proximity event detection element switching control device according to another embodiment of the present disclosure.
- a fixed proximity sensor is always used to detect the proximity data in the terminal device, it is difficult to adapt to changing acquisition conditions.
- the fixed proximity sensor is an infrared sensor
- the proximity sensor excites electrons in the screen during the process of emitting infrared light, causing the transparent display to flicker, which interferes with the normal display of the transparent display and affects the ability of the terminal device to provide energy.
- the quality of service and the electronic and infrared light of the display affect each other, reducing the accuracy of the proximity data collection.
- the present disclosure proposes to set different elements for acquiring the proximity data according to different screen states, so that there are adaptations under each acquisition condition Components to improve the accuracy of the proximity data collection.
- an optimized method for switching the proximity event detection element is also provided to ensure the smoothness of the screen state switching.
- the application subject of the proximity event detection element switching method may be a terminal device including multiple proximity event detection element elements, and the terminal device may be a mobile phone. , Tablet computers, personal digital assistants, wearable devices and other hardware devices with a display screen, the wearable devices may be smart bracelets, smart watches, smart glasses, and the like.
- FIG. 1 is a flowchart of a method for controlling a proximity event detection element switching according to an embodiment of the present disclosure. As shown in FIG. 1, the method includes:
- Step 101 Obtain a switching instruction for switching a screen of a terminal device from a current first state to a second state.
- the first state and the second state of the screen respectively correspond to different states of the screen of the terminal device.
- the proximity data collection conditions are different.
- the first state and the The second state may be a screen-on state and a screen-off state, a screen-off state and a screen-on state, respectively.
- step 101 includes:
- Step 201 Detect a current operating state characteristic of a terminal device.
- the current state characteristics of the terminal device are used to assist in determining whether the user has the intention to switch the screen state in advance.
- the determined operating state characteristics are different under different screen states, examples are as follows:
- the corresponding operating state characteristics are used to assist in determining whether to perform the screen-off operation, and the corresponding current operating state characteristics include the duration of the terminal device's foreground without running applications, and the terminal device's screen without Operation time, whether it is detected that the user triggers the corresponding screen-off key, etc.
- the corresponding operating state is used to assist in determining whether to perform a bright screen operation.
- the corresponding current operating state characteristics include whether the start button of the terminal device is triggered, and whether a corresponding black screen is detected by the user. Gestures, etc.
- step 202 if the current operating state feature matches a preset screen state switching feature, a switch instruction for switching the screen of the terminal device from the current first state to the second state is obtained.
- the corresponding auxiliary judgment to determine whether to perform a screen switch is different from the current operation state, so that the corresponding preset screen state switch characteristics are different.
- the above embodiment is continued.
- the corresponding preset screen state switching feature is that the screen of the terminal device has no operation time to reach a preset time, such as 2 minutes.
- the current operating state feature matches a preset screen state switching feature, the current user is considered to have a need to switch the screen state, thereby switching the screen of the terminal device from the current first state to the second state.
- step 101 includes:
- Step 301 Detect power information of a terminal device.
- an IntentFilter, BroadcastReceiver can be written, and then registerReceiver (batteryReceiver, intentFilter) is registered, waiting for the onReceive callback to parse the intent to obtain the power information.
- step 302 if the power information matches the preset screen state switching power information, a switch instruction for switching the screen of the terminal device from the current first state to the second state is obtained.
- the preset screen state switching power information corresponds to the current screen state.
- the current screen state that is, the first state is a bright screen state
- the corresponding preset screen state switching power information includes lower power Threshold value, that is, when the screen state is the bright screen state, if the terminal power is less than the power threshold, the screen state can be switched from the bright screen state to the off screen state in order to improve the endurance of the terminal device, in order not to affect the user ’s
- a pop-up window prompt message can also be sent to the user to obtain the screen state switching operation confirmed by the user based on the pop-up window prompt information. The screen state switching operation rejected by the pop-up prompt message will not switch the screen state.
- the corresponding preset screen state switching power information includes a relatively high power threshold, such as 5% of the power, that is, the screen state is the off-screen state. At this time, if the terminal power is greater than the power threshold, the screen state is switched from the off-screen state to the bright screen state (second state) for the convenience of the user.
- the authorization information of the user can also be obtained in advance.
- the switching requirement of the screen state can also be actively detected in advance, so that the switching of the detection element of the detection data corresponding to the screen state can be started in advance, thereby further ensuring the smoothness of the switching of the screen state.
- step 102 a pre-established switching thread is invoked to switch the first element corresponding to the first state to the second element corresponding to the second state, wherein the first element is used to detect a screen approach event in the first state.
- the two components are used to detect a screen approach event in the second state.
- the time consuming of the first element of the screen approach event corresponding to the first state to the second element of the screen approach event corresponding to the second state may block the switching of the screen state, for example, when the screen state is changed from the first state
- the switching of the screen state to the second state will be suspended, which will affect the switching efficiency of the screen state and affect the user experience.
- network resources can also be coordinated and waited until the current switching thread to improve the processing efficiency of the switching thread, such as releasing an advertising thread.
- a switching thread is established in advance, and the switching thread is used to control the switching of the first element to the second element, that is, as shown in FIG. 4-A If only the first element to the second element is switched according to the switching of the screen state, first the screen state switching main thread needs to switch the first element to the second element in the first state. At this time, the screen It is necessary to wait for the second element to complete the switch before switching to the second state, which causes the screen state switch to be blocked. As shown in Figure 4-B, in the embodiment of the present disclosure, a switching thread is established in advance to switch the screen state.
- the main thread After the main thread obtains a switching instruction for the screen of the terminal device to switch from the current first state to the second state, it calls a pre-established switching thread to switch the first element corresponding to the first state to the first element corresponding to the second state. Two elements, thereby switching the first element to the second element through the switching thread, which improves the speed of element switching and ensures that the screen state is not switched. Obstruction.
- the proximity event detection element switching thread in order to ensure the stability of the proximity event detection element switching control, is marked as not responding to an asynchronous signal state, that is, the switching thread is controlled to be in an uninterruptible state.
- Step 103 After receiving the notification of the switching success feedback from the switching thread, switch the screen of the terminal device from the first state to the second state.
- the screen of the terminal device is switched from the first state to the second state, and therefore, when the screen of the terminal device is switched from the first state to the second state, the first The switching from the element to the second element ensures the smoothness of the screen state switching.
- the corresponding first element is a touch screen proximity sensor and the second element is an infrared proximity sensor.
- the terminal device 100 includes a touch display screen 103, an infrared proximity sensor 16, a light sensor 5, and a processor 23.
- the touch display screen 103 includes a display layer 13 and a display layer 13. Including a display area 1311, an infrared proximity sensor 16 is disposed below the display area 1311.
- the infrared proximity sensor 16 is configured to emit infrared light and receive infrared light reflected by the object to detect the distance from the object to the terminal device 100.
- the embodiment of the present disclosure is described by using the terminal device 100 as a mobile phone as an example.
- the mobile phone can prevent misuse by the user and help save the power of the mobile phone.
- the infrared proximity sensor 16 calculates the time when the transmitter emits infrared light and the receiver receives the reflected infrared light to generate detection information.
- the processor 23 turns off the display according to the detection information. Layer 13.
- the processor 23 opens the display layer 13 again according to the detection information fed back by the infrared proximity sensor 16 again.
- the display layer 13 includes an OLED display layer.
- the touch display screen 103 further includes a light-transmissive cover plate 11 and a touch layer 12.
- the transparent cover plate 11 is disposed on the touch layer 12
- the touch layer 12 is disposed on the display layer 13
- the upper surface 131 of the display layer 13 faces the touch layer 12, and the transparent cover plate 11 and the touch layer 12 are transparent to visible light. Both the light transmittance and infrared light transmittance are greater than 90%.
- the touch layer 12 is mainly used to receive the proximity signal input by the user and transmit it to the circuit board for data processing, that is, the touch layer 12 can support the touch display screen to work as a touch screen proximity sensor, so as to obtain the user's touch.
- the specific location of the layer 12. it should be noted that the disposition of the touch layer 12 on the display layer 13 may mean that the touch layer 12 is in contact with the display layer 13.
- In-Cell or On-Cell bonding technology may be used to connect the touch layer 12 to the display layer 13.
- Lamination of the display layers 13 can effectively reduce the weight of the display layers 13 and the overall thickness of the display layers 13.
- the disposition of the touch layer 12 on the display layer 13 may also mean that the touch layer 12 is disposed above the display layer 13 and is spaced from the display layer 13.
- the transparent cover 11 is disposed on the touch layer 12, which can effectively protect the touch layer 12 and its internal structure, and avoid damage to the touch layer 12 and the display layer 13 by external forces.
- the light transmittance of the transparent cover 11 and the touch layer 12 to visible light and infrared light are both greater than 90%, which is not only beneficial for the display layer 13 to better display the content effect, but also for infrared proximity provided under the display layer 13
- the sensor 16 steadily emits and receives infrared light, ensuring the normal operation of the infrared proximity sensor 16.
- the infrared proximity sensor 16 acquires the proximity data under the screen off, and the touch display screen 103 acquires the proximity data under the bright screen. Therefore, after receiving the screen state switching instruction, it will correspond to the bright screen state. Of the touch screen proximity sensor is switched to an infrared proximity sensor corresponding to the off-screen state.
- the corresponding first element is an infrared proximity sensor and the second element is a touch screen proximity sensor.
- the terminal device includes an infrared proximity sensor and a touch display screen with a proximity recognition function, and the touch display screen is used as a touch screen proximity sensor to identify a proximity event.
- the infrared proximity sensor 16 acquires the proximity data under the screen off, and the touch display screen 103 acquires the proximity data under the bright screen. Therefore, after receiving the screen state switching instruction, it will correspond to the screen off state.
- the infrared proximity sensor is switched to a touch screen proximity sensor corresponding to the bright screen state.
- the proximity event detection element switching control method in the embodiment of the present disclosure obtains a switching instruction for the screen of the terminal device to switch from the current first state to the second state, calls a pre-established switching thread, and corresponds to the first state.
- the first element is switched to a second element corresponding to the second state, wherein the first element is used to detect a screen approach event in the first state, and the second element is used to detect a screen approach event in the second state.
- the screen of the terminal device is switched from the first state to the second state.
- FIG. 8 is a schematic structural diagram of a proximity event detection element switching control device according to an embodiment of the present disclosure. As shown in FIG. 8, the device includes The obtaining module 10, the first switching module 20, and the second switching module 30.
- the obtaining module 10 is configured to obtain a switching instruction for switching a screen of a terminal device from a current first state to a second state.
- the first switching module 20 is configured to call a pre-established switching thread to switch a first element corresponding to a first state to a second element corresponding to a second state, wherein the first element is configured to detect a state in the first state.
- Screen approach event the second component is used to detect the screen approach event in the second state.
- the second switching module 30 is configured to switch the screen of the terminal device from the first state to the second state after receiving the notification of the switching success fed back by the switching thread.
- the first switching module 20 is specifically configured to: when the first state is a bright screen state and the second state is a screen off state, a touch screen corresponding to the bright screen state
- the proximity sensor switches to an infrared proximity sensor corresponding to the screen-off state; when the first state is a screen-off state and the second state is a bright-screen state, an infrared proximity sensor corresponding to the screen-off state Switching to a touch screen proximity sensor corresponding to the bright screen state.
- the device further includes a marking module 40, wherein the marking module 40 is configured to mark the proximity event detection element switching thread as Does not respond to asynchronous signal states.
- the acquisition module 10 includes a detection unit 11 and an acquisition unit 12, where:
- the detecting unit 11 is configured to detect a current operating state characteristic of the terminal device.
- the obtaining unit 12 is configured to obtain a switching instruction for switching a screen of a terminal device from a current first state to a second state when a characteristic of a current operation state matches a preset screen state switching feature.
- the detection unit 11 is configured to detect power information of the terminal device
- the obtaining unit 12 is configured to obtain a switching instruction for switching the screen of the terminal device from the current first state to the second state if the power information matches the preset screen state switching power information.
- the obtaining unit 12 is specifically configured to: when the first state is a bright screen state, if the power amount information is less than the screen state switching power amount information, obtain the switching of the screen of the terminal device from the bright screen state to the off screen state instruction.
- the obtaining unit 12 is specifically configured to: when the first state is the screen-off state, if the power amount information is greater than the screen state switching power amount information, obtain the switching of the screen of the terminal device from the screen-off state to the screen-on state instruction.
- the apparatus further includes: a coordination module, configured to coordinate a network resource to a currently called switching thread.
- the proximity event detection element switching control device obtains a switching instruction for the screen of the terminal device to switch from the current first state to the second state, calls a pre-established switching thread, and corresponds to the first state.
- the first element is switched to a second element corresponding to the second state, wherein the first element is used to detect a screen approach event in the first state, and the second element is used to detect a screen approach event in the second state.
- the screen of the terminal device is switched from the first state to the second state.
- the present disclosure also proposes a terminal device including a memory, a processor, and a computer program stored on the memory and executable on the processor.
- the processor executes the computer program, the implementation is implemented as The method for controlling the proximity event detection element switching described in the foregoing embodiment.
- the present disclosure also proposes a computer-readable storage medium having stored thereon a computer program that, when executed by a processor, implements a method for controlling a proximity event detection element switch as proposed by the foregoing embodiment of the present disclosure.
- first and second are used for descriptive purposes only, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as “first” and “second” may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "a plurality” is at least two, for example, two, three, etc., unless it is specifically and specifically defined otherwise.
- any process or method description in a flowchart or otherwise described herein can be understood as representing a module, fragment, or portion of code that includes one or more executable instructions for implementing steps of a custom logic function or process
- the scope of the preferred embodiments of the present disclosure includes additional implementations in which functions may be performed out of the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order according to the functions involved, which should It is understood by those skilled in the art to which the embodiments of the present disclosure belong.
- Logic and / or steps represented in a flowchart or otherwise described herein, for example, a sequenced list of executable instructions that may be considered to implement a logical function, may be embodied in any computer-readable medium, For use by, or in combination with, an instruction execution system, device, or device (such as a computer-based system, a system that includes a processor, or another system that can fetch and execute instructions from an instruction execution system, device, or device) Or equipment.
- a "computer-readable medium” may be any device that can contain, store, communicate, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device.
- computer-readable media include the following: electrical connections (electronic devices) with one or more wirings, portable computer disk cartridges (magnetic devices), random access memory (RAM), Read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disk read-only memory (CDROM).
- the computer-readable medium may even be paper or other suitable medium on which the program can be printed, because, for example, by optically scanning the paper or other medium, followed by editing, interpretation, or other suitable Processing to obtain the program electronically and then store it in computer memory.
- portions of the present disclosure may be implemented in hardware, software, firmware, or a combination thereof.
- multiple steps or methods may be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system.
- Discrete logic circuits with logic gates for implementing logic functions on data signals Logic circuits, ASICs with suitable combinational logic gate circuits, programmable gate arrays (PGA), field programmable gate arrays (FPGA), etc.
- a person of ordinary skill in the art can understand that all or part of the steps carried by the methods in the foregoing embodiments can be implemented by a program instructing related hardware.
- the program can be stored in a computer-readable storage medium.
- the program is When executed, one or a combination of the steps of the method embodiment is included.
- each functional unit in each embodiment of the present disclosure may be integrated into one processing module, or each unit may exist separately physically, or two or more units may be integrated into one module.
- the above integrated modules may be implemented in the form of hardware or software functional modules. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.
- the aforementioned storage medium may be a read-only memory, a magnetic disk, or an optical disk.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Software Systems (AREA)
- User Interface Of Digital Computer (AREA)
- Telephone Function (AREA)
Abstract
本公开提出一种接近事件检测元件切换控制方法和装置,其中,方法包括:获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令;调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,其中,第一元件用于检测第一状态下的屏幕接近事件,第二元件用于检测第二状态下的屏幕接近事件;当接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态。由此,在屏幕处于不同的状态时,使用不同的元件检测接近数据,提高了接近数据采集的准确度,避免了在屏幕状态切换时,检测屏幕接近事件的对应元件切换迟滞导致的屏幕状态切换被阻塞,提高了屏幕状态切换的流畅度,提升了用户体验。
Description
相关申请的交叉引用
本公开要求OPPO广东移动通信有限公司于2018年8月22日提交的、发明名称为“接近事件检测元件切换控制方法和装置”的、中国专利申请号“201810961363.X”的优先权。
本公开涉及电子技术领域,尤其涉及一种接近事件检测元件切换控制方法和装置。
随着终端设备制造技术的进步,终端设备可以实现基于接近传感器的接近事件识别功能,由此,可以支持终端设备的上层应用提供基于接近数据的各种功能服务,比如,支持游戏应用提供基于接近数据的手势操作动作识别功能。
公开内容
本公开旨在至少在一定程度上解决相关技术中的技术问题之一。
本公开第一方面实施例提出了一种接近事件检测元件切换控制方法,包括以下步骤:获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令;调用预先建立的切换线程,将与所述第一状态对应的第一元件切换为与所述第二状态对应的第二元件,其中,所述第一元件用于检测所述第一状态下的屏幕接近事件,所述第二元件用于检测所述第二状态下的屏幕接近事件;当接收到所述切换线程反馈的切换成功通知后,将所述终端设备的屏幕从所述第一状态切换为所述第二状态。
本公开第二方面实施例提出了一种接近事件检测元件切换控制装置,包括:获取模块,用于获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令;第一切换模块,用于调用预先建立的切换线程,将与所述第一状态对应的第一元件切换为与所述第二状态对应的第二元件,其中,所述第一元件用于检测所述第一状态下的屏幕接近事件,所述第二元件用于检测所述第二状态下的屏幕接近事件;第二切换模块,用于当接收到所述切换线程反馈的切换成功通知后,将所述终端设备的屏幕从所述第一状态切换为所述第二状态。
本公开第三方面实施例提出了一种终端设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时,实现如前述第一 方面实施例所述的接近事件检测元件切换控制方法。
本公开第四方面实施例提出了一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如前述第一方面实施例所述的接近事件检测元件切换控制方法。
本公开提供的技术方案,至少包括如下有益效果:
获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令,调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,其中,第一元件用于检测第一状态下的屏幕接近事件,第二元件用于检测第二状态下的屏幕接近事件,当接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态。由此,在屏幕处于不同的状态时,使用不同的元件检测接近数据,提高了接近数据采集的准确度,避免了在屏幕状态切换时,检测屏幕接近事件的对应元件切换迟滞导致的屏幕状态切换被阻塞,提高了屏幕状态切换的流畅度,提升了用户体验。
本公开附加的方面和优点将在下面的描述中部分给出,部分将从下面的描述中变得明显,或通过本公开的实践了解到。
本公开上述的和/或附加的方面和优点从下面结合附图对实施例的描述中将变得明显和容易理解,其中:
图1是根据本公开一个实施例的接近事件检测元件切换控制方法的流程图;
图2是根据本公开另一个实施例的接近事件检测元件切换控制方法的流程图;
图3是根据本公开又一个实施例的接近事件检测元件切换控制方法的流程图;
图4-A是根据本公开一个实施例的屏幕状态切换过程示意图;
图4-B是根据本公开另一个实施例的屏幕状态切换过程示意图;
图5是本公开某些实施方式的终端设备的平面示意图;
图6是本公开某些实施方式的终端设备的一个截面示意图;
图7是本公开某些实施方式的终端设备的另一个截面示意图;
图8是根据本公开一个实施例的接近事件检测元件切换控制装置的结构示意图;
图9是根据本公开一个实施例的接近事件检测元件切换控制装置的结构示意图;以及
图10是根据本公开另一个实施例的接近事件检测元件切换控制装置的结构示意图。
下面详细描述本公开的实施例,所述实施例的示例在附图中示出,其中自始至终相同 或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下面通过参考附图描述的实施例是示例性的,旨在用于解释本公开,而不能理解为对本公开的限制。
针对上述背景技术中所提到的,终端设备中由于始终采用某一个固定的接近传感器来实现接近数据的检测,导致难以适应多变的采集条件,比如,当固定设置的接近传感器为红外传感器时,在屏幕亮屏的状态下,接近传感器在发射红外光的过程中使屏幕里的电子受到激发从而引起透光显示屏闪烁,从而与透光显示屏的正常显示形成干涉,影响终端设备提供能的功能服务质量,并且显示屏的电子和红外光互相影响,降低了接近数据的采集的精确度。
为了解决上述固定的接近传感器与多变的采集条件之间的矛盾,本公开提出了一种根据屏幕状态的不同设置不同的获取接近数据的元件,从而,每一种采集条件下都有适配的元件,提高了接近数据的采集的精确度。
在实际应用中,申请人发现在根据屏幕的状态不同设置不同的接近数据采集元件时,可能在屏幕状态切换时,检测屏幕接近事件的对应元件切换迟滞导致的屏幕状态切换被阻塞,因而,在本公开实施例中,还提出了一种优化的接近事件检测元件的切换方法,以保证屏幕状态切换的流畅度。
下面参考附图描述本公开实施例的接近事件检测元件切换控制方法,其中,该接近事件检测元件切换方法的应用主体可以是包含多种接近事件检测元件元件的终端设备,该终端设备可以是手机、平板电脑、个人数字助理、穿戴式设备等具有显示的屏幕的硬件设备,该穿戴式设备可以是智能手环、智能手表、智能眼镜等。
图1是根据本公开一个实施例的接近事件检测元件切换控制方法的流程图,如图1所示,该方法包括:
步骤101,获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
其中,屏幕的第一状态和第二状态分别对应于终端设备的屏幕的不同状态,在第一状态下和在第二状态下的接近数据采集条件不同,在实际执行过程中,第一状态和第二状态可以分别为亮屏状态和灭屏状态,灭屏状态和亮屏状态等。
需要说明的是,在不同的应用场景下,获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令的方式不同,示例说明如下:
作为一种可能的实现方式,如图2所示,步骤101包括:
步骤201,检测终端设备的当前操作状态特征。
其中,终端设备的当前状态特征用以提前辅助判断用户是否具有切换屏幕状态的意图,在不同的屏幕状态下,判定的操作状态特征不同,示例如下:
在当前屏幕状态为亮屏状态时,则对应的操作状态特征用于辅助判断是否进行灭屏操 作,则对应的当前操作状态特征包括终端设备前台无运行应用程序的持续时长,终端设备的屏幕无操作时长,是否检测到用户触发对应的熄屏按键等。
在当前屏幕状态为灭屏状态时,则对应的操作状态用于辅助判断是否进行亮屏操作,则对应的当前操作状态特征包括终端设备的开启按键是否被触发,是否检测到用户实施对应的黑屏手势等。
步骤202,若当前操作状态特征与预设的屏幕状态切换特征匹配,则获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
不难理解的是,终端设备的屏幕状态不同,则对应的辅助判断是否进行屏幕切换的当前操作状态不同,从而,对应的预设的屏幕状态切换特征不同,举例而言,继续以上述实施例为例,在当前屏幕状态为亮屏状态时,则对应的预设的屏幕状态切换特征为终端设备的屏幕无操作时长达到预设时长,比如达到2分钟。
具体地,如果当前操作状态特征与预设的屏幕状态切换特征匹配,则认为当前用户具有切换屏幕状态的需求,从而将终端设备的屏幕从当前第一状态切换为第二状态。
作为另一种可能的实现方式,如图3所示,步骤101包括:
步骤301,检测终端设备的电量信息。
在本公开的一个实施例中,可以写一个IntentFilter,BroadcastReceiver,然后注册registerReceiver(batteryReceiver,intentFilter),等待onReceive回调再去解析intent来获取电量信息。
步骤302,若电量信息与预设的屏幕状态切换电量信息匹配,则获取到终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
容易理解的是,预设的屏幕状态切换电量信息与当前屏幕状态相对应,在当前屏幕状态即第一状态为亮屏状态时,则对应的预设的屏幕状态切换电量信息包括较低的电量阈值,即在屏幕状态为亮屏状态时,如果终端电量小于该电量阈值,则对为了提高终端设备的续航能力可以将屏幕状态由亮屏状态切换为灭屏状态,其中,为了不影响用户的使用,在将屏幕状态由亮屏状态切换为灭屏状态(第二状态)之前,还可以向用户发送弹窗提示信息,以获取用户根据弹窗提示信息确认的屏幕状态切换操作,如果用户根据弹窗提示信息拒绝的屏幕状态切换操作,则不进行屏幕状态的切换。
在当前屏幕状态即第一状态为灭屏状态时,则对应的预设的屏幕状态切换电量信息包括相对较高的电量阈值,比如为百分之五的电量,即在屏幕状态为灭屏状态时,如果终端电量大于该电量阈值,则对为了方便用户的使用,将屏幕状态由灭屏状态切换为亮屏状态(第二状态),当然,在本实施例中,为了便于用户的使用,在根据电量信息进行屏幕状态的切换时,还可以提前获取用户的授权信息。
由此,基于上述示例,还可以主动提前检测到屏幕状态的切换需求,从而,可以提前开始进行与屏幕状态对应的检测数据的检测元件的切换,进一步确保了屏幕状态的切换流畅度。
步骤102,调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,其中,第一元件用于检测第一状态下的屏幕接近事件,第二元件用于检测第二状态下的屏幕接近事件。
应当理解的是,第一状态对应的屏幕接近事件的第一元件到第二状态对应的屏幕接近事件的第二元件的耗时可能会阻塞屏幕状态的切换,比如,当屏幕状态由第一状态切换到第二状态时,由于第一元件没有切换到第二元件,则会暂停将屏幕状态到第二状态的切换,这将影响屏幕状态的切换效率,影响用户的体验。
在本公开中一些可能的示例中,还可以协调网络资源等至当前切换线程,以提高切换线程的处理效率,比如释放广告线程等。
为了保证屏幕状态切换的流畅,在本公开的实施例中,预先建立一个切换线程,该切换线程用于控制第一元件到第二元件的切换,也就是说,如图4-A图所示,如果仅仅实现根据屏幕状态的切换进行第一元件到第二元件的切换,则首先屏幕状态切换主线程需要在第一状态进行中的进行第一元件到第二元件的切换,此时,屏幕需要等待第二元件完成切换后,才能进行到第二状态的切换,导致屏幕状态切换被阻塞,而如图4-B所示,本公开的实施例中,预先建立切换线程,在屏幕状态切换主线程获取到终端设备的屏幕从当前的第一状态切换为第二状态的切换指令后,调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,从而,通过切换线程进行第一元件到第二元件的切换,提高了元件切换速度,保证了屏幕状态切换不被阻塞。
在本公开的一个实施例中,为了保证接近事件检测元件切换控制的稳定性,将接近事件检测元件切换线程标记为不响应异步信号状态,即控制该切换线程处于不可被中断的状态。
步骤103,当接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态。
具体地,在接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态,因此,终端设备的屏幕从第一状态切换为第二状态时已经完成第一元件到第二元件的切换,保证了屏幕状态切换的流畅度。
为了使得本领域的技术人员对本公开实施例的接近事件检测元件切换控制方法更加清楚,下面结合具体的应用场景进行举例,举例说明如下:
应用场景一:
在本示例中,第一状态为亮屏状态,第二状态为灭屏状态时,则对应的第一元件为触摸屏接近传感器,第二元件为红外接近传感器。
具体而言,参照图5-7,在本示例中,终端设备100包括触摸显示屏103,红外接近传感器16、光感应器5和处理器23,触摸显示屏103包括显示层13,显示层13包括显示区1311,红外接近传感器16设置在显示区1311下方,红外接近传感器16用于发射红外光并接收被物体反射的红外光以检测物体至终端设备100的距离。
本公开实施例以终端设备100为手机作为例子进行说明。手机通过设置红外接近传感器16以确定手机与障碍物之间的距离并做出相应的调整,能够防止用户的误操作和有利于节省手机的电量。当用户在接听或者拨打电话并将手机靠近头部时,红外接近传感器16经过计算发射器发出红外光和接收器接收反射回来的红外光的时间生成检测信息,处理器23根据该检测信息关闭显示层13。当手机远离头部时,处理器23再次根据红外接近传感器16反馈回来的检测信息重新打开显示层13。
在某些实施方式中,显示层13包括OLED显示层。
请参阅图7,在一些实施方式中,触摸显示屏103还包括透光盖板11和触控层12。透光盖板11设置在触控层12上,触控层12设置在显示层13上,显示层13的上表面131朝向触控层12,透光盖板11和触控层12对可见光透光率和红外光透光率均大于90%。
具体地,触控层12主要用于接收用户输入的接近信号并传送到电路板进行数据处理,也就是说触控层12可以支持触摸显示屏作为触摸屏接近传感器工作,从而获得用户触碰触控层12的具体位置。需要指出的是,触控层12设置在显示层13上可以指的是触控层12与显示层13接触,例如,可以采用In-Cell或者On-Cell贴合技术,将触控层12与显示层13进行贴合,能够有效地减轻显示层13的重量和减少显示层13的整体厚度。触控层12设置在显示层13上也可以指的是触控层12设置在显示层13上方,并与显示层13间隔。
另外,将透光盖板11设置在触控层12上,能够有效地保护触控层12及其内部结构,避免了外界作用力对触控层12及显示层13的损坏。透光盖板11和触控层12对可见光和红外光的透光率均大于90%,不仅有利于显示层13较好地展现内容效果,而且还有利于设置在显示层13下的红外接近传感器16稳定地发射和接收红外光,保证了红外接近传感器16的正常工作。
在本示例中,红外接近传感器16在灭屏下进行接近数据的获取,触摸显示屏103在亮屏下进行接近数据的获取,因而,在接收到屏幕状态切换指令后,将与亮屏状态对应的触摸屏接近传感器切换为与灭屏状态对应的红外接近传感器。
应用场景一:
在本示例中,第一状态为灭屏状态,第二状态为亮屏状态时,则对应的第一元件为红 外接近传感器,第二元件为触摸屏接近传感器。
具体而言,继续参照图5-7,终端设备中包括红外接近传感器,以及具有接近识别功能的触摸显示屏,该触摸显示屏作为触摸屏接近传感器识别接近事件。
在本示例中,红外接近传感器16在灭屏下进行接近数据的获取,触摸显示屏103在亮屏下进行接近数据的获取,因而,在接收到屏幕状态切换指令后,将与灭屏状态对应的红外接近传感器切换为与亮屏状态对应的触摸屏接近传感器。
综上,本公开实施例的接近事件检测元件切换控制方法,获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令,调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,其中,第一元件用于检测第一状态下的屏幕接近事件,第二元件用于检测第二状态下的屏幕接近事件,当接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态。由此,在屏幕处于不同的状态时,使用不同的元件检测接近数据,提高了接近数据采集的准确度,避免了在屏幕状态切换时,检测屏幕接近事件的对应元件切换迟滞导致的屏幕状态切换被阻塞,提高了屏幕状态切换的流畅度,提升了用户体验。
为了实现上述实施例,本公开还提出一种接近事件检测元件切换控制装置,图8是根据本公开一个实施例的接近事件检测元件切换控制装置的结构示意图,如图8所示,该装置包括获取模块10、第一切换模块20和第二切换模块30,其中,
获取模块10,用于获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
第一切换模块20,用于调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,其中,第一元件用于检测第一状态下的屏幕接近事件,第二元件用于检测第二状态下的屏幕接近事件。
第二切换模块30,用于当接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态。
在本公开的一个实施例中,第一切换模块20具体用于:当所述第一状态为亮屏状态,所述第二状态为灭屏状态时,将与所述亮屏状态对应的触摸屏接近传感器切换为与所述灭屏状态对应的红外接近传感器;当所述第一状态为灭屏状态,所述第二状态为亮屏状态时,将与所述灭屏状态对应的红外接近传感器切换为与所述亮屏状态对应的触摸屏接近传感器。
在本公开的一个实施例中,如图9所示,在如图8所示的基础上,该装置还包括标记模块40,其中,标记模块40,用于将接近事件检测元件切换线程标记为不响应异步信号状态。
在本公开的一个实施例中,如图10所示,在如图8所示的基础上,获取模块10包括检测单元11和获取单元12,其中,
检测单元11,用于检测终端设备的当前操作状态特征。
获取单元12,用于在当前操作状态特征与预设的屏幕状态切换特征匹配时,获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
在本公开的另一个实施例中,检测单元11,用于检测所述终端设备的电量信息;
获取单元12,用于若电量信息与预设的屏幕状态切换电量信息匹配,则获取到终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
可选地,获取单元12具体用于:第一状态为亮屏状态时,若所述电量信息小于屏幕状态切换电量信息,则获取到终端设备的屏幕从亮屏状态切换为灭屏状态的切换指令。
可选地,获取单元12具体用于:第一状态为灭屏状态时,若所述电量信息大于屏幕状态切换电量信息,则获取到终端设备的屏幕从灭屏状态切换为亮屏状态的切换指令。
在本公开的一个实施例中,该装置还包括:协调模块,用于将网络资源协调至当前调用的切换线程。
需要说明的是,前述对接近事件检测元件切换控制方法实施例的解释说明也适用于该实施例的接近事件检测元件切换控制装置,此处不再赘述。
综上,本公开实施例的接近事件检测元件切换控制装置,获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令,调用预先建立的切换线程,将与第一状态对应的第一元件切换为与第二状态对应的第二元件,其中,第一元件用于检测第一状态下的屏幕接近事件,第二元件用于检测第二状态下的屏幕接近事件,当接收到切换线程反馈的切换成功通知后,将终端设备的屏幕从第一状态切换为第二状态。由此,在屏幕处于不同的状态时,使用不同的元件检测接近数据,提高了接近数据采集的准确度,避免了在屏幕状态切换时,检测屏幕接近事件的对应元件切换迟滞导致的屏幕状态切换被阻塞,提高了屏幕状态切换的流畅度,提升了用户体验。
为了实现上述实施例,本公开还提出一种终端设备,包括:存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时,实现如前述实施例描述的接近事件检测元件切换控制方法。
为了实现上述实施例,本公开还提出一种计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现如本公开前述实施例提出的接近事件检测元件切换控制方法。
在本说明书的描述中,参考术语“一个实施例”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本公开的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不必须针对的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任一个或多个实施例或示例中以合适的方式结合。此外,在不相互矛盾的情况下,本领域的技术人员可以将本说明书中描述的不同实施例或示例以及不同实施例或示例的特征进行结合和组合。
此外,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。在本公开的描述中,“多个”的含义是至少两个,例如两个,三个等,除非另有明确具体的限定。
流程图中或在此以其他方式描述的任何过程或方法描述可以被理解为,表示包括一个或更多个用于实现定制逻辑功能或过程的步骤的可执行指令的代码的模块、片段或部分,并且本公开的优选实施方式的范围包括另外的实现,其中可以不按所示出或讨论的顺序,包括根据所涉及的功能按基本同时的方式或按相反的顺序,来执行功能,这应被本公开的实施例所属技术领域的技术人员所理解。
在流程图中表示或在此以其他方式描述的逻辑和/或步骤,例如,可以被认为是用于实现逻辑功能的可执行指令的定序列表,可以具体实现在任何计算机可读介质中,以供指令执行系统、装置或设备(如基于计算机的系统、包括处理器的系统或其他可以从指令执行系统、装置或设备取指令并执行指令的系统)使用,或结合这些指令执行系统、装置或设备而使用。就本说明书而言,"计算机可读介质"可以是任何可以包含、存储、通信、传播或传输程序以供指令执行系统、装置或设备或结合这些指令执行系统、装置或设备而使用的装置。计算机可读介质的更具体的示例(非穷尽性列表)包括以下:具有一个或多个布线的电连接部(电子装置),便携式计算机盘盒(磁装置),随机存取存储器(RAM),只读存储器(ROM),可擦除可编辑只读存储器(EPROM或闪速存储器),光纤装置,以及便携式光盘只读存储器(CDROM)。另外,计算机可读介质甚至可以是可在其上打印所述程序的纸或其他合适的介质,因为可以例如通过对纸或其他介质进行光学扫描,接着进行编辑、解译或必要时以其他合适方式进行处理来以电子方式获得所述程序,然后将其存储在计算机存储器中。
应当理解,本公开的各部分可以用硬件、软件、固件或它们的组合来实现。在上述实施方式中,多个步骤或方法可以用存储在存储器中且由合适的指令执行系统执行的软件或 固件来实现。如,如果用硬件来实现和在另一实施方式中一样,可用本领域公知的下列技术中的任一项或他们的组合来实现:具有用于对数据信号实现逻辑功能的逻辑门电路的离散逻辑电路,具有合适的组合逻辑门电路的专用集成电路,可编程门阵列(PGA),现场可编程门阵列(FPGA)等。
本技术领域的普通技术人员可以理解实现上述实施例方法携带的全部或部分步骤是可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,该程序在执行时,包括方法实施例的步骤之一或其组合。
此外,在本公开各个实施例中的各功能单元可以集成在一个处理模块中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。所述集成的模块如果以软件功能模块的形式实现并作为独立的产品销售或使用时,也可以存储在一个计算机可读取存储介质中。
上述提到的存储介质可以是只读存储器,磁盘或光盘等。尽管上面已经示出和描述了本公开的实施例,可以理解的是,上述实施例是示例性的,不能理解为对本公开的限制,本领域的普通技术人员在本公开的范围内可以对上述实施例进行变化、修改、替换和变型。
Claims (20)
- 一种接近事件检测元件切换控制方法,其特征在于,包括以下步骤:获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令;调用预先建立的切换线程,将与所述第一状态对应的第一元件切换为与所述第二状态对应的第二元件,其中,所述第一元件用于检测所述第一状态下的屏幕接近事件,所述第二元件用于检测所述第二状态下的屏幕接近事件;当接收到所述切换线程反馈的切换成功通知后,将所述终端设备的屏幕从所述第一状态切换为所述第二状态。
- 如权利要求1所述的方法,其特征在于,当所述第一状态为亮屏状态,所述第二状态为灭屏状态时,所述将与所述第一状态对应的第一元件切换为与所述第二状态对应的第二元件,包括:将与所述亮屏状态对应的触摸屏接近传感器切换为与所述灭屏状态对应的红外接近传感器;当所述第一状态为灭屏状态,所述第二状态为亮屏状态时,所述将与所述第一状态对应的第一元件切换为与所述第二状态对应的第二元件,包括:将与所述灭屏状态对应的红外接近传感器切换为与所述亮屏状态对应的触摸屏接近传感器。
- 如权利要求1或2所述的方法,其特征在于,在所述调用预先建立的接近事件检测元件切换线程之前,还包括:将所述接近事件检测元件切换线程标记为不响应异步信号状态。
- 如权利要求1-3任一项所述的方法,其特征在于,所述获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令,包括:检测所述终端设备的当前操作状态特征;若所述当前操作状态特征与预设的屏幕状态切换特征匹配,则获取所述终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
- 如权利要求1-3任一项所述的方法,其特征在于,所述获取到终端设备的屏幕从当前的第一状态切换为第二状态的切换指令,包括:检测所述终端设备的电量信息;若所述电量信息与预设的屏幕状态切换电量信息匹配,则获取到所述终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
- 如权利要求5所述的方法,其特征在于,所述若所述电量信息与预设的屏幕状态 切换电量信息匹配,则获取到所述终端设备的屏幕从当前的第一状态切换为第二状态的切换指令包括:所述第一状态为亮屏状态时,若所述电量信息小于所述屏幕状态切换电量信息,则获取到所述终端设备的屏幕从所述亮屏状态切换为灭屏状态的切换指令。
- 如权利要求5所述的方法,其特征在于,所述若所述电量信息与预设的屏幕状态切换电量信息匹配,则获取到所述终端设备的屏幕从当前的第一状态切换为第二状态的切换指令包括:所述第一状态为灭屏状态时,若所述电量信息大于所述屏幕状态切换电量信息,则获取到所述终端设备的屏幕从所述灭屏状态切换为亮屏状态的切换指令。
- 如权利要求1-7任一项所述的方法,其特征在于,在调用预先建立的切换线程之后,还包括:将网络资源协调至当前调用的切换线程。
- 一种接近事件检测元件切换控制装置,其特征在于,包括:获取模块,用于获取终端设备的屏幕从当前的第一状态切换为第二状态的切换指令;第一切换模块,用于调用预先建立的切换线程,将与所述第一状态对应的第一元件切换为与所述第二状态对应的第二元件,其中,所述第一元件用于检测所述第一状态下的屏幕接近事件,所述第二元件用于检测所述第二状态下的屏幕接近事件;第二切换模块,用于当接收到所述切换线程反馈的切换成功通知后,将所述终端设备的屏幕从所述第一状态切换为所述第二状态。
- 如权利要求9所述的装置,其特征在于,所述第一切换模块具体用于:当所述第一状态为亮屏状态,所述第二状态为灭屏状态时,将与所述亮屏状态对应的触摸屏接近传感器切换为与所述灭屏状态对应的红外接近传感器;当所述第一状态为灭屏状态,所述第二状态为亮屏状态时,将与所述灭屏状态对应的红外接近传感器切换为与所述亮屏状态对应的触摸屏接近传感器。
- 如权利要求9或10所述的装置,其特征在于,还包括:标记模块,用于将所述接近事件检测元件切换线程标记为不响应异步信号状态。
- 如权利要求9-11任一项所述的装置,其特征在于,所述获取模块,包括:检测单元,用于检测所述终端设备的当前操作状态特征;获取单元,用于在所述当前操作状态特征与预设的屏幕状态切换特征匹配时,获取所述终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
- 如权利要求9-11任一项所述的装置,其特征在于,所述获取模块,包括:检测单元,用于检测所述终端设备的电量信息;获取单元,用于若所述电量信息与预设的屏幕状态切换电量信息匹配,则获取到所述终端设备的屏幕从当前的第一状态切换为第二状态的切换指令。
- 如权利要求13所述的装置,其特征在于,所述获取单元具体用于:所述第一状态为亮屏状态时,若所述电量信息小于所述屏幕状态切换电量信息,则获取到所述终端设备的屏幕从所述亮屏状态切换为灭屏状态的切换指令。
- 如权利要求13所述的装置,其特征在于,所述获取单元具体用于:所述第一状态为灭屏状态时,若所述电量信息大于所述屏幕状态切换电量信息,则获取到所述终端设备的屏幕从所述灭屏状态切换为亮屏状态的切换指令。
- 如权利要求9-15任一项所述的装置,其特征在于,还包括:协调模块,用于将网络资源协调至当前调用的切换线程。
- 一种终端设备,其特征在于,包括:存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时,实现如权利要求1-8中任一所述的接近事件检测元件切换控制方法。
- 如权利要求17所述的终端设备,其特征在于,还包括:红外接近传感器,所述红外接近传感器用于在灭屏状态下获取接近数据。
- 如权利要求17所述的终端设备,其特征在于,还包括:触摸显示屏,所述触摸显示屏用于在亮屏状态下获取接近数据。
- 一种计算机可读存储介质,其上存储有计算机程序,其特征在于,该程序被处理器执行时实现如权利要求1-8中任一所述的接近事件检测元件切换控制方法。
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
EP19851070.3A EP3828684B1 (en) | 2018-08-22 | 2019-07-01 | Method and device for controlling switching of proximity-event detection elements |
US17/175,587 US20210165479A1 (en) | 2018-08-22 | 2021-02-12 | Method for controlling switching of proximity-event detection elements, terminal device, and non-transitory computer readable storage medium |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810961363.XA CN109271019B (zh) | 2018-08-22 | 2018-08-22 | 接近事件检测元件切换控制方法和装置 |
CN201810961363.X | 2018-08-22 |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US17/175,587 Continuation US20210165479A1 (en) | 2018-08-22 | 2021-02-12 | Method for controlling switching of proximity-event detection elements, terminal device, and non-transitory computer readable storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2020038122A1 true WO2020038122A1 (zh) | 2020-02-27 |
Family
ID=65154021
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2019/094200 WO2020038122A1 (zh) | 2018-08-22 | 2019-07-01 | 接近事件检测元件切换控制方法和装置 |
Country Status (4)
Country | Link |
---|---|
US (1) | US20210165479A1 (zh) |
EP (1) | EP3828684B1 (zh) |
CN (1) | CN109271019B (zh) |
WO (1) | WO2020038122A1 (zh) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11663628B2 (en) | 2012-05-14 | 2023-05-30 | Iqzone, Inc. | Systems and methods for unobtrusively displaying media content on portable devices |
CN109271019B (zh) * | 2018-08-22 | 2020-07-10 | Oppo广东移动通信有限公司 | 接近事件检测元件切换控制方法和装置 |
CN110138974B (zh) * | 2019-05-20 | 2021-06-01 | 西安易朴通讯技术有限公司 | 屏幕控制方法、装置、设备及计算机可读存储介质 |
US11375289B2 (en) * | 2019-10-25 | 2022-06-28 | Iqzone, Inc. | Using system broadcasts to unobtrusively display media content on portable devices |
CN114285935B (zh) * | 2020-09-17 | 2023-09-15 | 南京酷派软件技术有限公司 | 终端的控制方法、装置、存储介质及电子设备 |
CN116805929A (zh) * | 2023-08-28 | 2023-09-26 | 深圳海普瑞丽科技有限公司 | 一种网络分析仪端口复用系统、方法及存储介质 |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN203311399U (zh) * | 2013-05-20 | 2013-11-27 | 北京百纳威尔科技有限公司 | 具有接近感应功能的手机触摸屏 |
CN103929538A (zh) * | 2014-04-09 | 2014-07-16 | 惠州Tcl移动通信有限公司 | 基于接近传感器的移动终端接听方法及其系统 |
CN104516474A (zh) * | 2013-10-08 | 2015-04-15 | 联想(北京)有限公司 | 一种信息处理方法及电子设备 |
CN106873879A (zh) * | 2017-01-25 | 2017-06-20 | 维沃移动通信有限公司 | 一种电子设备以及熄屏处理方法、装置 |
CN206292950U (zh) * | 2016-09-13 | 2017-06-30 | 东莞市联臣电子科技股份有限公司 | 一种智能视力保护装置 |
CN107908313A (zh) * | 2017-11-22 | 2018-04-13 | 广东欧珀移动通信有限公司 | 电子装置的控制方法及电子装置 |
CN109088961A (zh) * | 2018-06-15 | 2018-12-25 | Oppo广东移动通信有限公司 | 传感器控制电路以及电子装置 |
CN109271019A (zh) * | 2018-08-22 | 2019-01-25 | Oppo广东移动通信有限公司 | 接近事件检测元件切换控制方法和装置 |
CN109388285A (zh) * | 2018-09-25 | 2019-02-26 | Oppo广东移动通信有限公司 | 接近检测模式切换方法、装置、电子设备及存储介质 |
Family Cites Families (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20090037756A1 (en) * | 2007-07-31 | 2009-02-05 | Lundquist David T | System and Method for Suspending Operation of a Mobile Unit |
US8723811B2 (en) * | 2008-03-21 | 2014-05-13 | Lg Electronics Inc. | Mobile terminal and screen displaying method thereof |
US9030407B2 (en) * | 2011-12-21 | 2015-05-12 | Nokia Technologies Oy | User gesture recognition |
US20150330772A1 (en) * | 2014-05-15 | 2015-11-19 | Nataporn Charusabha | Proximity Sensor Having a Daughterboard-Mounted Light Detector |
CN104007878B (zh) * | 2014-05-16 | 2017-01-25 | 广东欧珀移动通信有限公司 | 防止触摸屏终端误操作的方法和装置 |
CN104750421A (zh) * | 2015-04-20 | 2015-07-01 | 深圳市欧珀通信软件有限公司 | 一种移动终端的触屏操作方法及装置 |
CN106020423A (zh) * | 2016-05-25 | 2016-10-12 | 努比亚技术有限公司 | 终端的屏幕控制装置及方法 |
CN106200989B (zh) * | 2016-09-08 | 2019-11-12 | 广东小天才科技有限公司 | 一种移动终端亮屏的方法及装置 |
CN107943345B (zh) * | 2017-11-22 | 2020-10-02 | Oppo广东移动通信有限公司 | 接近传感器的校准方法、装置、存储介质和电子设备 |
CN110581904B (zh) * | 2018-06-11 | 2021-01-15 | Oppo广东移动通信有限公司 | 控制方法、控制装置、电子装置和存储介质 |
-
2018
- 2018-08-22 CN CN201810961363.XA patent/CN109271019B/zh active Active
-
2019
- 2019-07-01 WO PCT/CN2019/094200 patent/WO2020038122A1/zh unknown
- 2019-07-01 EP EP19851070.3A patent/EP3828684B1/en active Active
-
2021
- 2021-02-12 US US17/175,587 patent/US20210165479A1/en not_active Abandoned
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN203311399U (zh) * | 2013-05-20 | 2013-11-27 | 北京百纳威尔科技有限公司 | 具有接近感应功能的手机触摸屏 |
CN104516474A (zh) * | 2013-10-08 | 2015-04-15 | 联想(北京)有限公司 | 一种信息处理方法及电子设备 |
CN103929538A (zh) * | 2014-04-09 | 2014-07-16 | 惠州Tcl移动通信有限公司 | 基于接近传感器的移动终端接听方法及其系统 |
CN206292950U (zh) * | 2016-09-13 | 2017-06-30 | 东莞市联臣电子科技股份有限公司 | 一种智能视力保护装置 |
CN106873879A (zh) * | 2017-01-25 | 2017-06-20 | 维沃移动通信有限公司 | 一种电子设备以及熄屏处理方法、装置 |
CN107908313A (zh) * | 2017-11-22 | 2018-04-13 | 广东欧珀移动通信有限公司 | 电子装置的控制方法及电子装置 |
CN109088961A (zh) * | 2018-06-15 | 2018-12-25 | Oppo广东移动通信有限公司 | 传感器控制电路以及电子装置 |
CN109271019A (zh) * | 2018-08-22 | 2019-01-25 | Oppo广东移动通信有限公司 | 接近事件检测元件切换控制方法和装置 |
CN109388285A (zh) * | 2018-09-25 | 2019-02-26 | Oppo广东移动通信有限公司 | 接近检测模式切换方法、装置、电子设备及存储介质 |
Non-Patent Citations (1)
Title |
---|
See also references of EP3828684A4 * |
Also Published As
Publication number | Publication date |
---|---|
CN109271019A (zh) | 2019-01-25 |
CN109271019B (zh) | 2020-07-10 |
US20210165479A1 (en) | 2021-06-03 |
EP3828684A4 (en) | 2021-09-22 |
EP3828684B1 (en) | 2024-04-24 |
EP3828684A1 (en) | 2021-06-02 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2020038122A1 (zh) | 接近事件检测元件切换控制方法和装置 | |
US10372326B2 (en) | Mobile terminal device, operation method, program, and storage medium | |
US9639261B2 (en) | Apparatus and method for controlling a suspended state | |
US11868604B2 (en) | Display processing method and apparatus | |
WO2015043194A1 (zh) | 虚拟键盘显示方法、装置及终端 | |
WO2014206101A1 (zh) | 一种基于手势的会话处理方法、装置及终端设备 | |
EP3663925A1 (en) | Method for processing refreshing display abnormality, and terminal | |
CN103677633B (zh) | 屏幕解锁方法、装置和终端 | |
WO2019201136A1 (zh) | 分屏显示方法、存储介质及电子设备 | |
WO2022206130A1 (zh) | 一种控制应用程序限时使用的方法及电子设备 | |
CN107197082A (zh) | 一种信息提醒方法及终端 | |
CN111767124A (zh) | 请求响应方法、装置、存储介质和电子设备 | |
CN107562356B (zh) | 指纹识别定位方法、装置、存储介质及电子设备 | |
CN110691168B (zh) | 移动终端的屏幕控制方法、装置及存储介质 | |
CN108319885B (zh) | 指纹识别方法及装置 | |
CN112199005A (zh) | 内容显示方法、装置、存储介质及移动终端 | |
CN106339268B (zh) | 应用程序控制方法和智能终端 | |
CN111026259A (zh) | 移动终端的控制方法、装置及存储介质 | |
CN109343691A (zh) | 一种移动终端的控制方法及移动终端 | |
CN106341476A (zh) | 云端设备连接方法和智能终端 | |
CN117032540A (zh) | 交互操作响应方法、装置、计算机设备和存储介质 | |
CN109445566A (zh) | Otg节电处理方法、系统、存储介质及移动终端 | |
CN107835301A (zh) | 一种添加辅助功能的方法和装置 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 19851070 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
ENP | Entry into the national phase |
Ref document number: 2019851070 Country of ref document: EP Effective date: 20210226 |