WO2022247424A1 - 数据处理方法、装置、电子设备及计算机可读介质 - Google Patents
数据处理方法、装置、电子设备及计算机可读介质 Download PDFInfo
- Publication number
- WO2022247424A1 WO2022247424A1 PCT/CN2022/082658 CN2022082658W WO2022247424A1 WO 2022247424 A1 WO2022247424 A1 WO 2022247424A1 CN 2022082658 W CN2022082658 W CN 2022082658W WO 2022247424 A1 WO2022247424 A1 WO 2022247424A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- strength
- threshold
- timer
- received signal
- timing
- Prior art date
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 15
- 238000000034 method Methods 0.000 claims abstract description 45
- 230000000875 corresponding effect Effects 0.000 claims description 24
- 230000008859 change Effects 0.000 claims description 15
- 238000012545 processing Methods 0.000 claims description 13
- 230000002596 correlated effect Effects 0.000 claims description 8
- 230000004913 activation Effects 0.000 claims description 6
- 238000001994 activation Methods 0.000 claims description 6
- 238000010586 diagram Methods 0.000 description 15
- 238000004891 communication Methods 0.000 description 8
- 238000001514 detection method Methods 0.000 description 6
- 230000006870 function Effects 0.000 description 6
- 230000008569 process Effects 0.000 description 3
- 230000001960 triggered effect Effects 0.000 description 3
- 238000013459 approach Methods 0.000 description 2
- 230000008878 coupling Effects 0.000 description 2
- 238000010168 coupling process Methods 0.000 description 2
- 238000005859 coupling reaction Methods 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 230000003247 decreasing effect Effects 0.000 description 2
- 230000007547 defect Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000009471 action Effects 0.000 description 1
- 230000000903 blocking effect Effects 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000004590 computer program Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000001914 filtration Methods 0.000 description 1
- 230000002452 interceptive effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/12—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
- H04L67/125—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks involving control of end-device applications over a network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/2803—Home automation networks
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04R—LOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
- H04R1/00—Details of transducers, loudspeakers or microphones
- H04R1/10—Earpieces; Attachments therefor ; Earphones; Monophonic headphones
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/06—Selective distribution of broadcast services, e.g. multimedia broadcast multicast service [MBMS]; Services to user groups; One-way selective calling services
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W8/00—Network data management
- H04W8/005—Discovery of network devices, e.g. terminals
-
- 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
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
Definitions
- the present application relates to the technical field of the Internet of Things, and more specifically, to a data processing method, device, electronic device, and computer-readable medium.
- At least one of the user's devices performs the targeted action when the signal strength between one of the user's devices and another is less than a threshold, however, if other devices not associated with the user (for example, other devices in public places) communicate with the user If the signal strength between the devices is close to the threshold, it may cause the user device to perform the targeted operation by mistake.
- the present application proposes a data processing method, device, electronic equipment, and computer-readable medium to improve the above defects.
- an embodiment of the present application provides a data processing method applied to a first device, the method comprising: when the first device detects a broadcast signal sent by a second device, starting a first timer; Based on the broadcast signal sent by the second device received by the first device, determine the target received signal strength; when the first timer expires, if within the duration of the first timer, no detection If the target received signal strength is greater than the strength threshold, increase the strength threshold; if it is detected that the received signal strength is greater than the strength threshold, perform a specified operation.
- the embodiment of the present application further provides a data processing apparatus, which is applied to the first device, and the apparatus includes: a timing unit, a determination unit, an adjustment unit, and an execution unit.
- a timing unit configured to start a first timer when the first device detects the broadcast signal sent by the second device.
- a determining unit configured to determine a target received signal strength based on the broadcast signal received by the first device and sent by the second device.
- the adjusting unit is configured to increase the strength threshold if it is not detected that the target received signal strength is greater than the strength threshold within the timing duration of the first timer after the first timer expires.
- An execution unit configured to execute a specified operation if it is detected that the strength of the received signal is greater than the strength threshold.
- the embodiment of the present application also provides an electronic device, including: one or more processors; memory; one or more application programs, wherein the one or more application programs are stored in the memory And configured to be executed by the one or more processors, the one or more application programs are configured to execute the above method.
- the embodiment of the present application further provides a computer-readable medium, the readable storage medium stores program code executable by a processor, and when the program code is executed by the processor, the processor Execute the method above.
- FIG. 1 shows a schematic diagram of an application scenario provided by an embodiment of the present application
- Fig. 2 shows a schematic diagram of an application scenario provided by another embodiment of the present application
- Fig. 3 shows a schematic diagram of an application scenario provided by another embodiment of the present application.
- FIG. 4 shows a schematic diagram of an earphone provided by an embodiment of the present application
- FIG. 5 shows a method flowchart of a data processing method provided by an embodiment of the present application
- FIG. 6 shows a method flowchart of a data processing method provided by another embodiment of the present application.
- FIG. 7 shows a schematic diagram of a threshold setting interface provided by an embodiment of the present application.
- FIG. 8 shows a schematic diagram of a threshold setting interface provided by another embodiment of the present application.
- Fig. 9 shows a schematic diagram of a timing setting interface provided by an embodiment of the present application.
- Fig. 10 shows a schematic diagram of intensity thresholds changing with time provided by an embodiment of the present application
- Fig. 11 shows a schematic diagram of a timing setting interface provided by another embodiment of the present application.
- Fig. 12 shows a schematic diagram of a timing setting interface provided by another embodiment of the present application.
- FIG. 13 shows a block diagram of a data processing device provided by an embodiment of the present application.
- FIG. 14 shows a schematic diagram of an electronic device provided by an embodiment of the present application.
- Fig. 15 is a storage unit for storing or carrying program codes for realizing the data processing method according to the embodiment of the present application according to the embodiment of the present application.
- the Internet of Things is a network concept based on the "Internet concept" that extends and expands its client terminal to any item and item for information exchange and communication.
- IOT Internet of Things
- the configuration scenario multiple smart devices may be involved, and the multiple smart devices have a certain linkage relationship and can work together.
- the configured scenario may include that when one device is close to another device, at least one of the two devices will perform a specified operation.
- the first device may be a user terminal 100 (for example, may be a smart phone), the second device may be a smart home device 200, and the smart home device 200 may include smart devices such as smart TVs, air conditioners, and curtains,
- the control interface of the second device is displayed on the first device, and the user can control the second device to perform corresponding actions through the control interface of the second device displayed on the first device.
- the first device may be a user terminal 100 (for example, may be a smart phone), and the second device may be a wireless earphone system 300.
- the first device displays a bullet box Information 110
- the power of the wireless earphone system can be displayed in the bullet box information 110
- the wireless earphone system 300 can include an earphone 320 and an earphone box 310
- the earphone box 310 can accommodate the earphone 320, specifically, the earphone box 310
- the inner wall of the casing forms an accommodating cavity, and the earphone 320 can be accommodated in the accommodating cavity of the earphone box 310 .
- the earphone box 310 can not only provide a cavity for accommodating the earphone 320, but also can communicate with the earphone 320, so as to obtain information such as the power and name of the earphone 320, or the network parameters of the earphone 320, so that the user terminal can pass through the earphone box 310.
- the pairing with the earphone 320 is successful and the communication connection is realized.
- the earphone box 310 is also used for charging the earphone 320 .
- the power of the earphone 320 and the power of the earphone box 310 may be simultaneously displayed in the pop-up information.
- the distance between two devices can be determined by the Received Signal Strength Indication (RSSI) of another device received by one device.
- RSSI Received Signal Strength Indication
- the ranging formula is as follows:
- d represents the distance between two devices
- RSSI represents the received signal strength of another device received by one device
- A is a reference distance, usually a constant
- B is a path loss factor.
- the second device when the second device activates the wireless communication module, the second device transmits a broadcast signal to the surroundings.
- the second device is a wireless earphone system
- the cover of the earphone box 310 when the second device is close to the first device, the cover of the earphone box 310 is in a closed state, then at this time, the earphone box 310 does not transmit broadcasts to the surroundings.
- signal that is, as shown in FIG. 3, the user terminal 100 has not received the broadcast signal transmitted by the earphone box 310, and the pop-up message 110 has not been displayed.
- the box cover of the user terminal 100 is open, as shown in FIG. 2, the earphone box 310 Transmit a broadcast signal, the broadcast signal can be received by the user terminal 100 , and when the received signal strength of the received broadcast signal is greater than a threshold, display pop-up information 110 .
- the wireless communication module may be a wireless fidelity (Wireless Fidelity, Wi-Fi) module, or a Bluetooth module.
- the wireless communication module may be a Bluetooth module.
- the first electronic The device and the second electronic device may be connected via Bluetooth, and the broadcast message may be a Bluetooth broadcast message, for example, a Bluetooth Low Energy (Bluetooh Low Energy, BLE) broadcast.
- BLE Bluetooth Low Energy
- the first device can detect the broadcast signal of the second device, and then can determine the signal strength of the broadcast signal received by the second device, that is, the received signal strength, As the distance between the first device and the second device gets closer, the received signal strength of the first device gradually increases.
- the first device displays the bullet box information, and then the first device A device and a second device may establish a wireless connection (eg, a Bluetooth connection).
- a connection button is displayed in the bullet box information displayed by the first device, such as the connection control 111 shown in FIG. 2 , and the user clicks the connection control 111 to realize the connection between the first device and the second device.
- the first device is a user terminal
- the second device is an earphone
- the earphone housing is provided with a wearing detection device.
- the earphone housing is provided with a wearing detector 130.
- the designated surface of the earphone shell the designated surface is the surface where the headphone head is in contact with the concha cavity of the human ear when the earphone is worn, specifically, a black round hole may be opened on the designated surface, and inside the round hole What is assembled is a wearing detector 130.
- the wearing detector 130 can be a photosensitive sensor, which includes a light emitting unit and a photosensitive unit. If there is an opaque object in front of the headset, most of the light will be reflected back. The photosensitive unit judges whether there is an object blocking it according to the intensity of the reflected light, and infers whether it is in the wearing state. Then after the user terminal displays the pop-up information, the user wears the earphone, and the wearing detection device of the earphone can detect that the earphone is in the wearing state, and then initiates a connection request to the user terminal, and the user terminal completes the communication connection with the earphone.
- the devices around the user terminal of the user include not only the devices related to the user, but specifically, the current login account of the device and the login account of the user terminal are the same user, or the user terminal and the device have successfully Establish connections, also including devices not associated with the user.
- a device that is not related to the user is named an unrelated device
- the unrelated device since the unrelated device may also transmit broadcast signals and be received by the user terminal, the received signal of the broadcast signal sent by the unrelated device received by the user terminal
- the intensity may also trigger the user terminal to perform a specified operation, where the specified operation may include displaying pop-up information and may also include other specified operations.
- the irrelevant device is not the device that the user cares about, the specified operation triggered by the irrelevant device will cause interference to the user of the user terminal, so the irrelevant device will cause the user terminal to perform the specified operation by mistake.
- the inventor analyzed the reasons why the current user terminal mis-executed the specified operation and found that when the user terminal receives the broadcast signal of an unrelated device, the unrelated device will not intentionally approach the user terminal, so , the unrelated device will not deliberately shorten the distance from the mobile phone quickly, so the received signal strength of the broadcast signal sent by the unrelated device detected by the user terminal may fluctuate around the aforementioned specified threshold, so the pop-up will be triggered continuously. Due to the frame condition, false pop-ups continue to appear on the user terminal, which seriously affects the user experience.
- the embodiments of the present application provide a data processing method, device, electronic equipment and computer-readable medium, which can detect that the received signal strength is greater than the strength threshold within a certain period of time , it can make it more difficult for the received signal strength of the broadcast signal sent by the second device to be greater than the strength threshold, so as to prevent the first device from performing a specified operation by mistake.
- FIG. 5 shows a data processing method provided by an embodiment of the present application, which is applied to a first device. Specifically, the method includes: S501 to S504.
- the second device when the second device starts the wireless module, it can transmit a broadcast signal to the surroundings, and the broadcast signal carries the network parameters of the second device, and the network parameters may include the network address of the second device or other information used to establish Parameters for the network connection.
- the wireless module of the first device when the wireless module of the first device is started, it can scan the surrounding connectable wireless connection points, specifically, it can receive the surrounding broadcast signal, and analyze the broadcast signal to obtain the data carried in the broadcast signal.
- the first device starts the first timer when scanning the broadcast signal of the second device.
- the first timer may be an application program or program module in the first device, or electronic hardware of the first device.
- the maximum timing length of a timer. Specifically, the timing period can be set by the user according to the needs, or can be set based on historical data, the historical data includes when the first device detects the broadcast signal of other devices, until it detects that other devices enter the second.
- the time length of the specified range of a device wherein the detection of the other device entering the specified range of the first device may be based on the relationship between the received signal strength of the broadcast signal received by the other device and the strength threshold
- the detection of the other device entering the specified range of the first device may be based on the relationship between the received signal strength of the broadcast signal received by the other device and the strength threshold
- the first device may start the first timer when it detects the broadcast signal sent by the second device for the first time this time.
- the first device may perform a timing operation; judge whether the timing duration of the timing operation satisfies a specified condition; if so, start the first timer device.
- the specified condition may be an interval of a preset time length, specifically, after the first device detects the broadcast signal sent by the second device for the first time this time, it restarts the first timer at an interval of a preset time length, wherein the preset The length of time can be set based on demand.
- the first device after the first device detects the broadcast signal sent by the second device for the first time this time, it can determine whether the first device can continue to detect the broadcast signal sent by the second device within a preset period of time. If yes, start a first timer.
- S502 Based on the broadcast signal received by the first device and sent by the second device, determine a target received signal strength.
- the first device may calculate the received signal strength according to the received broadcast messages, that is, obtain the received signal strength corresponding to each broadcast message.
- received signal strength RxPower-SystemGain, wherein, RxPower is to carry out analog/digital conversion to the received wireless signal, after performing the filtering etc. processing of digital front end (digital front end, DFE), calculate and obtain The in-band received power of the signal; SystemGain indicates the system gain, which can be estimated according to the RF front-end.
- the timeout of the first timer can be understood as the completion of the timing of the first timer.
- the completion of the timing can refer to the completion of the maximum timing length of the first timer, for example, the maximum timing of the first timer If the timing length is 3 seconds, from the start of the first timer to the completion of the timing of 3 seconds, it is defined as the timeout of the first timer.
- the first timer if the first timer is terminated, it may also be completed as timing. For example, the maximum timing length of the first timer is 3 seconds.
- increasing the strength threshold may increase the difference between the target received signal strength and the strength threshold, so that the received signal strength is determined when the first device receives the broadcast signal of the second device Then, since the difference between the target received signal strength and the strength threshold is deliberately increased, it is more difficult for the received signal strength to be greater than the strength threshold.
- the strength threshold is increased, assuming that the transmit power of the second device has not changed and the position of the second device has not changed, it is more difficult for the first device to receive the received signal strength of the broadcast signal of the second device to be greater than the strength threshold, thereby enabling It increases the difficulty of judging that the second device enters the preset range of the first device.
- reducing the target received signal strength and increasing the strength threshold may also be performed at the same time. For details, please refer to subsequent embodiments.
- the designated operation may include displaying the above-mentioned control interface or pop-up information on the first device, etc., and may also be other preset operations. If the strength of the received signal is greater than the strength threshold, it may indicate that the second device enters the preset range of the first device, so that the first device performs a specified operation, thereby realizing the interactive operation between the second device and the first device.
- the second device may not correspond to the same user as the first device, and the second device is only temporarily discovered by the first device and has not quickly contacted the first device.
- the proximity therefore, is not detected by the first device within the timing period of time with a received signal strength greater than the strength threshold.
- the strength threshold may be directly increased.
- the first device may not be able to receive the broadcast signal sent by the second device during the timing period, that is, the second device If the device is far away from the signal receiving range of the first device, before increasing the strength threshold, determine whether the first device can still receive the broadcast signal sent by the second device, and then determine whether to increase the Intensity Threshold.
- FIG. 6 shows a data processing method provided by an embodiment of the present application, which is applied to a first device. Specifically, the method includes: S601 to S607.
- the user may pre-configure the intensity threshold on the first device.
- a threshold setting interface is displayed on the first device, and a threshold setting component 701 is included in the threshold device interface.
- the threshold setting component 701 can be an input component, and the input component can be a selection menu or a An input box, the user triggers the threshold setting component 701 to input a specified value, and the specified value is used as the current intensity threshold.
- the intensity threshold at this time may be used as the initial threshold.
- the threshold setting interface may also include reference information 702, the reference information is used to indicate the setting rules of the intensity threshold, for example, may include a minimum threshold, then when the user equipment has an intensity threshold, the intensity threshold may be set based on the minimum threshold, To prevent the set intensity threshold from being too small, for example, the set intensity threshold is not less than the minimum threshold.
- the change rule for increasing the intensity threshold can be set in the threshold setting interface, as shown in Figure 8, a rule setting component 703 is displayed on the threshold setting interface, The change rule is used to indicate the increase rule when the intensity threshold is increased.
- the change rule may include linear increase, exponential increase, steep first and then steady, or other increasing methods, then the increase of the intensity threshold time, it can be set with reference to the change rule.
- the user can select a change rule by operating the rule setting component 703 for subsequent increase of the intensity threshold.
- the maximum timing length is used as the timing duration of the first timer. Then the maximum timing length can be set based on the aforementioned historical data. Specifically, the maximum timing length corresponding to the first timer can be set based on the designated time length corresponding to the designated device, wherein the designated device is a device related to the first device, specifically, a device related to the first device.
- the designated device is a device related to the first device, specifically, a device related to the first device
- the device may be that the login account of the first device and the login account of the designated device correspond to the same user, or that the first device has previously connected or transmitted data with the designated device, or that the first device and the designated device have been successfully paired.
- the designated time length is the time length between when the first device detects the broadcast signal of the designated device and executes the designated operation, specifically, when the first device detects the broadcast signal of the designated device, Denote it as the first moment, and determine the received signal strength of the designated device received by the first device based on the broadcast signal of the designated device, denote it as the designated received signal strength, and detect within the time length threshold after the first moment
- the time length threshold can be a preset empirical value, if the specified received signal strength is not detected to be greater than the strength threshold beyond the time length threshold, then the first moment of this time is abandoned, that is, the specified time length is invalid this time .
- the time length from when the device related to the first device is discovered by the first device to when the first device performs the specified operation can be counted, and the maximum timing length of the first timer is set based on the time length, then if It is not detected that the target received signal strength is greater than the strength threshold during the maximum timing length, and it may be considered that the current second device is not related to the user.
- the maximum timing length may be determined based on the multiple specified time lengths. Specifically, all specified time lengths corresponding to the specified device are used as candidate time lengths, and then a target time length is determined from the candidate time lengths, and a maximum timing length is determined based on the target time length. In some embodiments, all specified time lengths are averaged to obtain an averaged specified time length, and the maximum timing length is set as the averaged specified time length. In some other embodiments, the designated time length within the latest first time period among the candidate time lengths is used as the designated time length to be selected, and then the maximum timing length is determined based on the designated time length to be selected. For example, the average value of the specified time lengths to be selected is used as the maximum timing length.
- the target device may be determined from multiple specified devices, and the maximum timing length is determined based on the specified time length of the target device, specifically, the target device is determined from multiple specified devices
- An embodiment of the method may be to search for a device connected to the first device within the latest second time period from a plurality of specified devices, and then search for the specified time length of each target device, and determine based on the specified time length of each target device
- the implementation manner of determining the maximum timing length can refer to the foregoing embodiments, and details are not repeated here.
- the maximum timing length corresponding to the first timer may be set by the user based on the first device.
- the first device may display a timing setting interface, and the timing setting interface includes an input component of a maximum timing length. Please refer to FIG. 9 , a timing input component 901 is displayed in the timing setting interface shown in FIG. 9 , and the user inputs a duration through the timing input component 901 .
- the timing input assembly 901 includes a slider (circle shown in Figure 9) and a designated straight line, the slider can slide on the designated straight line, when the slider is at different positions on the straight line, the slider corresponds to The value is different, the value is used as the user's input duration, the rightmost endpoint of the straight line is used as the maximum duration that can be input, and the leftmost endpoint of the straight line is used as the minimum duration that can be input.
- the maximum duration and the minimum duration may be set according to actual needs.
- FIG. 9 also includes a switch component 902.
- the switch component 902 When the switch component 902 is in the on state, the first timer is allowed to be turned on, that is, the first device is allowed to start the first timer.
- the switch component 902 When the switch component 902 is in the off state, it is not allowed to The timer is turned on, that is, the first device is not allowed to start the first timer, then when the switch component 902 is in the open state, the timing input component 901 is in an operable state, and the user can input the maximum timing by operating the timing input component 901 length, the maximum timing length is used as the timing duration of the first timer.
- S602 Determine a target received signal strength based on the broadcast signal received by the first device and sent by the second device.
- S603 Determine whether the target received signal strength is greater than a strength threshold.
- the broadcast signal sent by the second device is sent according to the first specified interval, and the broadcast signal received by the first device is received based on the second specified interval, so the target reception is also counted according to the second specified interval signal strength. Then, each time the first device obtains the target received signal strength, S603 is executed. If the target received signal strength is greater than the strength threshold, perform S604, and if the target received signal strength is not greater than the strength threshold, perform S605. It should be noted that, when S603 is executed, the timer is still counting.
- S604 Display preset prompt information on the first device, and terminate the first timer.
- the preset prompt information may be the above-mentioned pop-up information, or may be the above-mentioned control interface, and of course, may also be other information, which is not limited here.
- the preset prompt information may be information related to the second device, for example, the preset prompt information includes the target parameters of the second device, and the target parameters may include the power and status information of the second device etc., so that the user can learn about the second device through the first device, and the target parameter can also be used as a reference for the connection between the first device and the second device.
- a connection button is displayed in the preset prompt information, and the user establishes a connection between the first device and the second device by operating the preset prompt information, so the preset corresponding to the second device is pushed accurately.
- Setting prompt information can greatly improve user experience.
- the first timer may be terminated. That is to say, if the second device has already triggered the first device to display the preset prompt information at this time, the second device can be considered as a related device of the first device with a high probability. Assuming that the prompt information is also irrelevant, the execution of the method ends after the first timer expires. That is, after S604, the method can be ended directly.
- the timeout of the first timer can be completed as timing. Specifically, when the timing of the first timer is completed, the system of the first device will generate a specified parameter, and the first device can determine the current first timing by detecting the specified parameter. Whether the device times out.
- the specified parameter may be generated when the timing duration of the first timer reaches the maximum timing duration, or may be generated when the first timer is terminated, so that when the timing operation is terminated, it can also be determined as The first timer expires.
- S606 Determine whether the broadcast signal sent by the second device can be detected.
- the broadcast signal sent by the second device can be detected, that is, the first device can still detect the broadcast signal of the second device when the timing is completed, it means that the second device is still within the signal receivable range of the first device. Therefore, in order to avoid subsequent fluctuations in the broadcast signal of the second device received by the first device within the range of the strength threshold, resulting in misoperation of the first device, S607 may be performed to increase the target received signal strength and the The difference between the intensity thresholds, ie to reduce the possibility of false triggering of the first device performing the specified operation.
- the first timer is terminated, and it is also determined that the timing is completed. Then, when S606 is executed, if the first device can detect the broadcast signal sent by the second device, then Execute S607, that is, increase the intensity threshold. Therefore, before the first timer expires, the first device detects that the target received signal strength is greater than the strength threshold, and executes the specified operation, then after that, the strength threshold is increased, and the second device can also trigger the signal multiple times easily The first device executes the specified operation, so that multiple triggers of the specified operation of the first device by the second device can be better avoided.
- the first device cannot detect the broadcast signal sent by the second device, it indicates that the second device is no longer within the signal receiving range of the first device, and the possibility of the second device triggering the first device to perform a specified operation is very low. It may not be necessary to execute S607, and this method may end, or return to S601, and the first device continues to detect broadcast signals sent by surrounding devices.
- the first device After the first device cannot detect the broadcast signal sent by the second device, it is determined whether it is still unable to detect the broadcast signal sent by the second device within a preset detection time length, and if so, then end This method, or return to execute S601. If the broadcast signal sent by the second device is detected within the preset detection time length, S607 is executed.
- the target received signal strength is less than or equal to the strength threshold. Therefore, by increasing the strength threshold, the distance between the target received signal strength and the strength threshold can be increased. , reducing the possibility that the received signal strength of the target is greater than the strength threshold.
- the strength threshold used by the first device is recorded as the initial threshold, and the setting of the initial threshold Reference may be made to the foregoing embodiments, and details are not repeated here.
- an implementation manner of increasing the intensity threshold may be to set a target amplitude value, and use the sum of the initial threshold and the target amplitude value as the intensity threshold.
- the target amplitude value is 0, and the intensity threshold is equal to the initial threshold.
- the target amplitude value can be set to be non-zero, for example, a positive number, so that the intensity threshold can be increased.
- the first device can still detect the broadcast signal sent by the second device, and within the timing duration corresponding to the first timer, no When the received signal strength of the target is greater than the strength threshold, increase the strength threshold, then start the first timer again, and perform subsequent operations until it is detected that the received signal strength of the target is greater than the strength threshold or the first The device cannot detect broadcast signals sent by the second device.
- the first device After starting the first timer again, based on the increased intensity threshold, it is judged again whether the first device satisfies a specified operating condition, wherein the specified operating condition is that this timing ends, if the first The device can still detect the broadcast signal sent by the second device, and within the timing period corresponding to the first timer, it is not detected that the target received signal strength is greater than the strength threshold.
- the intensity threshold is the initial threshold, then after the first timer ends for the first time, if the first device meets the specified operating conditions, the intensity threshold will be increased, specifically, the intensity threshold and The sum of the target amplitude values is used as a new intensity threshold, and then the first timer is started again, and based on the new intensity threshold, it is determined again whether the first device meets the specified operating conditions, and if the first device still meets the specified operating conditions, increase The target amplitude value, so that the sum of the intensity threshold and the new target amplitude value is used as the new intensity threshold again, and the first timer is started again until it is detected that the target received signal strength is greater than the intensity threshold or the first device cannot detect To the broadcast signal sent by the second device.
- the operation of reducing the target received signal strength or increasing the strength threshold may be set to be related to the number of times.
- the current start times of the first timer are obtained, and the intensity threshold is increased based on the start times. Specifically, each time it is determined that the first device satisfies the specified operating condition and the intensity threshold is increased, the number of times the first timer is started is counted, for example, the first timer is started for the first time, and after the intensity threshold is increased, the first timer is started The number of times is set to 1.
- an implementation manner of increasing the intensity threshold based on the number of activations is to increase the intensity threshold based on the number of activations, wherein the number of activations is positively correlated with an increase range of the intensity threshold.
- the above process of increasing the intensity threshold based on the number of activations is described. Specifically, different times correspond to different target amplitude values, and the greater the number of times, the larger the target amplitude value, that is, the number of times is positively correlated with the target amplitude value.
- the formula of the intensity threshold is as follows:
- RSSI min RSSI 0 + a*c (2)
- RSSI min is the strength threshold
- RSSI 0 is the initial threshold, for example, it can be -60dB
- a is the weight, which is a constant, for example, it can be 0.5
- c is the number of starts
- a*c is the target amplitude value, which can be It can be seen that the target amplitude value is positively correlated with the number of starts.
- the total time length can also be counted, wherein the total time length is the sum of the time length between each start of the first timer and the end, for example, the first timer is currently started three times in total, three times
- the timing lengths of the timing are t1, t2 and t3 respectively, then the total timing length is t1+t2+t3, and then the intensity threshold is increased based on the total timing length, wherein the increase of the intensity threshold is positively correlated with the total timing length .
- the formula of the intensity threshold is as follows:
- RSSI min RSSI 0 +a*T (3)
- a*c is the target amplitude value
- T is the total time length. It can be seen that the target amplitude value is positively correlated with the total time length.
- the formula of the intensity threshold can also be as follows:
- RSSI min RSSI 0 +a*(T/t) (4)
- a*(T/t) is the target amplitude value
- T is the total timing length
- t is the timing interval, that is, the maximum timing length. It can be seen that the target amplitude value is positively correlated with the total timing length. If the first timer ends after counting the maximum timing length each time, and the maximum timing length remains unchanged, then T/t can be used as the number of starts.
- Figure 10 shows two curves, respectively the first curve L1 and the second curve L2, and also shows the threshold line L3 of the initial intensity threshold, that is, the horizontal dotted line in Figure 10, wherein , the first curve and the second curve are the received signal strength curves when the broadcast signals sent by different devices are received by the first device.
- the received signal strength value corresponding to the second curve L2 fluctuates around the threshold line L3 , especially after 3s, the received signal strength of the second curve L2 appears for the first time greater than the strength threshold, and the received signal strength fluctuates back and forth between less than and greater than the strength threshold.
- the timing length of the first timer is 3s, and as the number of starts of the first timer increases, the intensity threshold gradually increases, as shown in L4 in Figure 10, the multiple black horizontal lines are execution The threshold line after the strength threshold is increased, it can be seen that the difference between the received signal strength and the strength threshold is getting larger and larger. As time increases, the possibility that the received signal strength is greater than the strength threshold is getting lower and lower, and the difficulty getting bigger.
- the maximum timing length corresponding to the first timer may be fixed, for example, timing is 3 seconds each time.
- the maximum timing length corresponding to the first timer can be changed.
- the timing setting interface also includes a The time length change setting component 903 of the change rule, through which the time length change setting component 903 can set the change rule of the maximum timing length corresponding to the first timer, the change rule can include gradually increasing, gradually decreasing, first increasing and then decreasing Small or decrease first and then increase, etc., each time the timing is started again, the maximum timing length corresponding to the first timer is set based on the change rule of the maximum timing length.
- the timing setting interface also displays an interval setting component 904, through which the user sets the variation range corresponding to the variation rule of the maximum timing length, for example, the variation range is 0.3s, and the variation rule is gradually increasing, Then the timing duration of starting the first timer for the first time is 3s, then the timing duration of starting the first timer for the second time is 3.3, the timing duration of starting the first timer for the third time is 3.6, and so on.
- the number of timing cycles can also be set.
- the first device can still detect the broadcast signal sent by the second device, and within the timing duration corresponding to the first timer, no If it is detected that the received signal strength of the target is greater than the strength threshold, then keep the strength threshold as the last set strength threshold unchanged, that is, the strength threshold will not be updated until it is detected that the received signal strength of the target is greater than the strength threshold or the first A device cannot detect a broadcast signal sent by a second device.
- the intensity threshold is -58dB, and although the timing can continue afterwards, the intensity threshold remains at -58dB and will not be updated.
- the timing setting interface also displays a cycle number setting component 905, through which the cycle number setting component 905 can set the timing cycle number, after the timing cycle number ends, keep the intensity threshold as the last set intensity threshold Change, that is, no longer update the intensity threshold.
- FIG. 13 shows a structural block diagram of a data processing device 1300 provided by an embodiment of the present application.
- the device may include: a timing unit 1301 , a determining unit 1302 , an adjusting unit 1303 and an executing unit 1304 .
- the timing unit 1301 is configured to start a first timer when the first device detects the broadcast signal sent by the second device.
- the determining unit 1302 is configured to determine a target received signal strength based on the broadcast signal received by the first device and sent by the second device.
- the adjusting unit 1303 is configured to increase the strength threshold if it is not detected that the target received signal strength is greater than the strength threshold within the timing duration of the first timer after the first timer expires.
- the adjustment unit 1303 is further configured to: when the first timer expires, if the first device can still detect the broadcast signal sent by the second device, and the timing duration of the first timer If it is not detected that the received signal strength of the target is greater than the strength threshold, the strength threshold is increased.
- the adjustment unit 1303 is further configured to start the first timer again after performing the preset operation, and perform subsequent operations until it is detected that the target received signal strength is greater than a strength threshold or the first device cannot A broadcast signal sent by the second device is detected.
- the adjustment unit 1303 is further configured to acquire the current number of starts of the first timer; increase the intensity threshold based on the number of starts, wherein the number of starts is positively proportional to the increase range of the intensity threshold relevant.
- the execution unit 1304 is configured to execute a specified operation if it is detected that the received signal strength is greater than the strength threshold.
- execution unit 1304 is further configured to, if it is detected that the strength of the received signal is greater than the strength threshold, terminate the first timer after performing a specified operation.
- execution unit 1304 is further configured to display preset prompt information on the first device if it is detected that the received signal strength is greater than the strength threshold.
- the coupling between the modules may be electrical, mechanical or other forms of coupling.
- each functional module in each embodiment of the present application may be integrated into one processing module, each module may exist separately physically, or two or more modules may be integrated into one module.
- the above-mentioned integrated modules can be implemented in the form of hardware or in the form of software function modules.
- the electronic device 10 may be an electronic device capable of running application programs, such as a smart phone, a tablet computer, and an e-book. Specifically, the electronic device 10 may be the aforementioned user device 100 .
- the electronic device 10 in the present application may include one or more of the following components: a processor 101, a memory 102, and one or more application programs, wherein one or more application programs may be stored in the memory 102 and configured to be used by One or more processors 101 are executed, and one or more programs are configured to execute the methods described in the foregoing method embodiments.
- Processor 101 may include one or more processing cores.
- the processor 101 uses various interfaces and lines to connect various parts of the entire electronic device 10, and executes by running or executing instructions, programs, code sets or instruction sets stored in the memory 102, and calling data stored in the memory 102.
- Various functions and processing data of the electronic device 10 may adopt at least one of Digital Signal Processing (Digital Signal Processing, DSP), Field-Programmable Gate Array (Field-Programmable Gate Array, FPGA), and Programmable Logic Array (Programmable Logic Array, PLA).
- DSP Digital Signal Processing
- FPGA Field-Programmable Gate Array
- PLA Programmable Logic Array
- the processor 101 may integrate one or a combination of a central processing unit (Central Processing Unit, CPU), an image processor (Graphics Processing Unit, GPU), a modem, and the like.
- the CPU mainly handles the operating system, user interface and application programs, etc.; the GPU is used to render and draw the displayed content; the modem is used to handle wireless communication. It can be understood that the above modem may also not be integrated into the processor 101, but implemented by a communication chip alone.
- the memory 102 may include random access memory (Random Access Memory, RAM), and may also include read-only memory (Read-Only Memory). Memory 102 may be used to store instructions, programs, codes, sets of codes, or sets of instructions.
- the memory 102 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system and instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.) , instructions for implementing the following method embodiments, and the like.
- the data storage area can also store data created during use of the electronic device 10 (such as phonebook, audio and video data, chat record data) and the like.
- FIG. 15 shows a structural block diagram of a computer-readable storage medium provided by an embodiment of the present application.
- Program codes are stored in the computer-readable medium 1500, and the program codes can be invoked by a processor to execute the methods described in the foregoing method embodiments.
- the computer readable storage medium 1500 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read Only Memory), EPROM, hard disk, or ROM.
- the computer-readable storage medium 1500 includes a non-transitory computer-readable storage medium (non-transitory computer-readable storage medium).
- the computer-readable storage medium 1500 has a storage space for program code 1510 for executing any method steps in the above methods. These program codes can be read from or written into one or more computer program products.
- Program code 1510 may, for example, be compressed in a suitable form.
- the data processing method, device, electronic device, and computer-readable medium provided by the embodiments of the present application indicate that the first device can scan the broadcast signal sent by the second device when the first device detects the broadcast signal sent by the second device.
- the second device then starts a first timer, and determines a target received signal strength based on the broadcast signal received by the first device and sent by the second device.
- the first device When the first timer expires, if it detects that the received signal strength is greater than the strength threshold within the timing duration corresponding to the first timer, the first device performs a specified operation, and if the received signal is not detected If the signal strength is greater than the strength threshold, it indicates that within the timing period, the signal strength of the second device received by the first device does not increase significantly, and the second device may not be related to the first device. Therefore, the strength threshold is increased, thereby increasing the difference between the target received signal strength and the strength threshold, thereby making it more difficult for the received signal strength of the broadcast signal sent by the second device to be greater than the strength threshold, so that the Prevent the first device from performing a specified operation by mistake.
- the processing method of dynamically adjusting the RSSI threshold with the time of discovering the IOT device is adopted, so that the RSSI threshold increases in stages with time, ensuring the accuracy of the IOT device outside the set bullet box distance.
- the RSSI value is always smaller than the set RSSI threshold, thereby preventing the IOT device from being falsely popped up on the user terminal and improving the reliability of the RSSI ranging solution.
Landscapes
- Engineering & Computer Science (AREA)
- Signal Processing (AREA)
- Computer Networks & Wireless Communication (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- Databases & Information Systems (AREA)
- Automation & Control Theory (AREA)
- Physics & Mathematics (AREA)
- Acoustics & Sound (AREA)
- Multimedia (AREA)
- Telephone Function (AREA)
Abstract
本申请公开了一种数据处理方法、装置、电子设备及计算机可读介质,涉及物联网技术领域,方法包括:在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器;基于第一设备接收到的第二设备发送的广播信号,确定目标接收信号强度;当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值;若检测到接收信号强度大于强度阈值,则执行指定操作。因此,通过增大强度阈值,使得第二设备发送的广播信号的接收信号强度更加难以大于强度阈值,以便能够避免第一设备误执行指定操作。
Description
相关申请的交叉引用
本申请要求于2021年05月26日提交中国专利局的申请号为202110579097.6、名称为“数据处理方法、装置、电子设备及计算机可读介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请涉及物联网技术领域,更具体地,涉及一种数据处理方法、装置、电子设备及计算机可读介质。
目前,在用户的一个设备与另一个设备之间的信号强度小于阈值时,至少其中一个设备会执行目标操作,然而,如果与用户不相关的其他设备(例如,公共场合的其他设备)与用户的设备之间的信号强度接近阈值,则可能会导致用户设备误执行目标操作。
发明内容
本申请提出了一种数据处理方法、装置、电子设备及计算机可读介质,以改善上述缺陷。
第一方面,本申请实施例提供了一种数据处理方法,应用于第一设备,所述方法包括:在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器;基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度;当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值;若检测到所述接收信号强度大于所述强度阈值,则执行指定操作。
第二方面,本申请实施例还提供了一种数据处理装置,应用于第一设备,所述装置包括:计时单元、确定单元、调整单元和执行单元。计时单元,用于在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器。确定单元,用于基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度。调整单元,用于当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值。执行单元,用于若检测到所述接收信号强度大于所述强度阈值,则执行指定操作。
第三方面,本申请实施例还提供了一种电子设备,包括:一个或多个处理器;存储器;一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个应用程序配置用于执行上述 方法。
第四方面,本申请实施例还提供了一种计算机可读介质,所述可读存储介质存储有处理器可执行的程序代码,所述程序代码被所述处理器执行时使所述处理器执行上述方法。
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1示出了本申请一实施例提供的应用场景的示意图;
图2示出了本申请另一实施例提供的应用场景的示意图;
图3示出了本申请又一实施例提供的应用场景的示意图;
图4示出了本申请实施例提供的耳机的示意图;
图5示出了本申请一实施例提供的数据处理方法的方法流程图;
图6示出了本申请另一实施例提供的数据处理方法的方法流程图;
图7示出了本申请一实施例提供的阈值设置界面的示意图;
图8示出了本申请另一实施例提供的阈值设置界面的示意图;
图9示出了本申请一实施例提供的计时设置界面的示意图;
图10示出了本申请一实施例提供的强度阈值随时间变化的示意图;
图11示出了本申请另一实施例提供的计时设置界面的示意图;
图12示出了本申请又一实施例提供的计时设置界面的示意图;
图13示出了本申请一实施例提供的数据处理装置的模块框图;
图14示出了本申请实施例提供的电子设备的示意图;
图15是本申请实施例的用于保存或者携带实现根据本申请实施例的数据处理方法的程序代码的存储单元。
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述。
物联网(Internet Of Things,IOT)是在“互联网概念”的基础上,将其用户端延伸和扩展到任何物品与物品之间,进行信息交换和通信的一种网络概念。随着物联网技术的发展,在物联网系统中可以配置一些场景。对于配置的场景,可以涉及到多个智能设备,而且多个智能设备之间具有一定的联动关系,能够协同工作。例如,所配置的场景可以包括,当一个设备靠近另一个设备的时候,两个设备中的至少一个会执行指定操作。
如图1所示,第一设备可以是用户终端100(例如,可以是智能手机),第二设备可以是智能家居设备200,该智能家居设备200可以包括智能电视、空调、窗帘等智能设备,在第一设备靠近第二设备的时候,在第一设备上显示第二设备的控制界面,用户可以通过第一设备显示的第二设备的控制界面控制所述第二设备执行对应的动作。
如图2所示,第一设备可以是用户终端100(例如,可以是智能手机),第二设备可以是无线耳机系统300,在第二设备靠近第一设备的时候,第一设备显示弹框信息110, 在该弹框信息110内可以显示无线耳机系统的电量,具体地,该无线耳机系统300可以包括耳机320和耳机盒310,耳机盒310可以容纳耳机320,具体地,耳机盒310的壳体内壁形成容纳腔,耳机320可以容纳在该耳机盒310的容纳腔内。另外,耳机盒310不仅可以提供用于容纳耳机320的容纳腔,还可以与耳机320通信,从而能获取耳机320的电量、名称或者耳机320的网络参数等信息,以便用户终端能通过耳机盒310与耳机320配对成功并实现通信连接。作为一种实施方式,该耳机盒310还用于为耳机320充电。具体地,可以在该弹框信息内同时显示耳机320的电量和耳机盒310的电量。
目前,两个设备之间可以通过一个设备接收的另一个设备的接收信号强度(Received Signal Strength Indication,RSSI)来确定两个设备之间的距离,具体地,测距公式如下:
公式(1)中,d表示两个设备之间的距离,RSSI表示一个设备接收的另一个设备的接收信号强度,A为参考距离,通常是常量,B为路径损耗因子。由公式(1)可以看出,距离d与RSSI是一一对应的关系。因此,通常判断一个设备与另一设备之间的距离是否小于预设距离,或者一个设备是否进入另一个设备的预设范围内,通常可以通过获取一个设备接收的另一个设备的接收信号强度,然后,通过判断该接收信号强度是否大于指定阈值的方式,判断一个设备是否进入另一个设备的预设范围内。
具体地,假设两个设备分别为第一设备和第二设备,在第二设备启动无线通信模块的时候,第二设备向周围发射广播信号。如图3所示,假设第二设备是无线耳机系统,在第二设备靠近第一设备的时候,耳机盒310的盒盖处于闭合状态,则此时,耳机盒310并不会向周围发射广播信号,即图3所示,用户终端100并未接收到耳机盒310发射的广播信号,也未显示弹框信息110,当用户终端100的盒盖处于打开状态,如图2所示,耳机盒310发射广播信号,能够被用户终端100接收到该广播信号,并且在接收的广播信号的接收信号强度大于阈值的时候,显示弹框信息110。
在一些实施例中,该无线通信模块可以是无线保真(wireless fidelity,Wi-Fi)模块,也可以是蓝牙模块,于本申请实施例中,该无线通信模块可以是蓝牙模块,第一电子设备和第二电子设备之间可以通过蓝牙连接,则该广播消息可以是蓝牙广播消息,例如,低功耗蓝牙(Bluetooh Low Energy,BLE)广播。随着第二设备与第一设备之间的距离的靠近,第一设备能够检测到第二设备的广播信号,进而能够确定该第二设备接收到的广播信号的信号强度,即接收信号强度,随着第一设备和第二设备之间的距离的靠近,第一设备的接收信号强度逐渐增大,当检测到的接收信号强度大于指定阈值时,第一设备显示弹框信息,然后,第一设备和第二设备可以建立无线连接(例如,蓝牙连接)。
例如,第一设备显示的弹框信息内显示有连接按钮,如图2所示的连接控件111,用户点击该连接控件111,能够实现第一设备和第二设备之间的连接。再例如,第一设备是用户终端,第二设备为耳机,耳机的壳体上设置有佩戴检测装置,如图4所示,耳机的壳体上设置有佩戴检测器130,该佩戴检测器130设置在耳机壳体的指定表面,该指定表面为该耳机被佩戴时,耳机头与人耳耳甲腔接触的表面,具体地,可以是在该指定表面开设一个黑色圆孔,这个圆孔内装配的便是一个佩戴检测器130,该佩戴检测器130可以是光感传感器,其包括发光单元和感光单元,该发光单元可以是LED灯,LED灯发出红外光线,透过圆孔上的棱镜片,辐射向耳机外,如果前方有不透明物体阻挡的话,大部分光线会反射回来,感光单元根据反射回来的光线强度来判断是否有物体阻挡,来推断是否处于佩戴状态。则在用户终端显示弹框信息之后,所用户佩戴该耳机,则耳机的佩戴检测装置能够检测到该耳机处于佩戴状态,则发起连接请求至用户终端,用户 终端完成与耳机之间的通信连接。
然后,在用户的用户终端周围的设备中,不仅包括与用户相关的设备,具体,可以是该设备当前的登陆帐号与用户终端的登陆帐号为同一个用户,或者,用户终端与该设备之前成功建立连接,还包括与用户不相关的设备。假设,将与用户不相关的设备命名为不相关设备,则由于不相关设备也可能向外发射广播信号,并且被用户终端接收,则用户终端接收到的不相关设备发送的广播信号的接收信号强度也可能会触发用户终端执行指定操作,其中,该指定操作可以包括显示弹框信息还可以包括其他的指定操作。然后,由于不相关设备并非是用户关心的设备,则不相关设备所触发的指定操作,会给用户终端的用户造成干扰,所以,不相关设备会造成用户终端误执行指定操作。
发明人在付出创造性劳动的情况下,分析目前用户终端误执行指定操作的原因之后发现,当用户终端接收到不相关设备的广播信号的时候,由于不相关设备不会刻意向用户终端靠近,所以,该不相关设备不会刻意的快速拉近与手机的距离,因此,用户终端所检测到的不相关设备发送的广播信号的接收信号强度可能在前述指定阈值附近波动,所以,会不断触发弹框条件,导致用户终端上不断出现误弹框的情形,严重影响用户体验。
因此,为了克服上述缺陷,本申请实施例提供了一种数据处理方法、装置、电子设备及计算机可读介质,能够在一定时间内未检测到所述接收信号强度大于所述强度阈值的情况下,能够使得第二设备发送的广播信号的接收信号强度更加难以大于强度阈值,以便能够避免第一设备误执行指定操作。
请参阅图5,图5示出了本申请实施例提供的一种数据处理方法,应用于第一设备,具体地,该方法包括:S501至S504。
S501:在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器。
具体地,第二设备在启动无线模块的时候,能够向周围发射广播信号,该广播信号内携带有第二设备的网络参数,该网络参数可以包括第二设备的网络地址或者其他的用于建立网络连接的参数。第一设备的无线模块在启动的时候,能够扫描周围的可连接的无线连接点,具体地,能够接收到周围的广播信号,解析该广播信号能够得到该广播信号内携带的数据。
则第一设备在扫描到第二设备的广播信号时,启动第一定时器。作为一种实施方式,该第一定时器可以是第一设备内的应用程序或者程序模块,也可以是第一设备的电子硬件,该第一定时器对应有计时时长,该计时时长作为该第一定时器的最大计时长度。具体地,该计时时长可以是用户根据需求而设定的,也可以是基于历史数据而设定,该历史数据包括第一设备在检测到其他设备的广播信号,至检测到其他设备进入到第一设备的指定范围的时间长度,其中,该其他设备进入到第一设备的指定范围的检测,可以基于第一设备接收到的其他设备的广播信号的接收信号强度与强度阈值之间的关系来确定,具体地,请参考后续实施例。
作为一种实施方式,第一设备可以在本次首次检测到第二设备发送的广播信号的时候,就启动第一定时器。作为另一种实施方式,还可以当所述第一设备检测到第二设备发送的广播信号时,执行计时操作;判断所述计时操作的计时时长是否满足指定条件;若满足,启动第一定时器。。其中,指定条件可以是间隔预设时间长度,具体地,第一设备在本次首次检测到第二设备发送的广播信号后,间隔预设时间长度再启动第一定时器,其中,该预设时间长度可以基于需求而设定。作为一种实施方式,第一设备在本次首次检测到第二设备发送的广播信号后,可以判断在预设时间长度内,第一设备是否持续能够检测到第二设备发送的广播信号后,如果是,则启动第一定时器。
S502:基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信 号强度。
在一些实施方式中,第一设备可以根据接收到的广播消息计算接收信号强度,即得到每条广播消息对应的接收信号强度。在一种实施方式中,接收信号强度=RxPower-SystemGain,其中,RxPower为对接收到的无线信号进行模/数转换,再进行数字前端(digital front end,DFE)的滤波等处理后,计算获得的信号带内接收功率;SystemGain表示系统增益,可以根据射频前端预估得到。
S503:当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值。
作为一种实施方式,该第一定时器超时可以理解为第一定时器计时完成,具体地,该计时完成可以是指第一定时器的最大计时长度完成,例如,该第一定时器的最大计时长度为3秒,则从第一定时器启动,至完成3秒的计时,定义为第一定时器超时。作为另一种实施方式,该第一定时器若被终止,也可以作为计时完成,例如,该第一定时器的最大计时长度为3秒。
作为一种实施方式,增大所述强度阈值可以增大所述目标接收信号强度与所述强度阈值之间的差值,从而在第一设备接收到第二设备的广播信号确定了接收信号强度之后,由于目标接收信号强度与所述强度阈值之间的差值被特意增大,使得接收信号强度更加难以大于强度阈值。
因此,如果将强度阈值增加,假设第二设备的发射功率未变,且第二设备的位置没有变,第一设备接收到第二设备的广播信号的接收信号强度更加难以大于强度阈值,从而能够增加判定第二设备进入到第一设备的预设范围内的难度。另外,还可以同时执行降低所述目标接收信号强度和增大所述强度阈值,具体地,请参考后续实施例。
S504:若检测到所述接收信号强度大于所述强度阈值,则执行指定操作。
其中,指定操作可以包括上述的在第一设备上显示控制界面或弹框信息等,还可以是其他的预先设定的操作。若接收信号强度大于所述强度阈值,则可以表示第二设备进入第一设备的预设范围内,从而第一设备执行指定操作,进而能够实现第二设备与第一设备之间的互动操作。
因此,若在所述第一定时器的计时时长内,未检测到所述接收信号强度大于所述强度阈值,则表明在该计时时长内,第一设备所接收的第二设备的信号强度未明显增大,则极有可能第二设备与第一设备不相关,第二设备可能与第一设备对应的并非同一个用户,第二设备只是暂时被第一设备发现而未快速向第一设备靠近,因此,并未在计时时间长度内,被第一设备检测到接收信号强度大于所述强度阈值。则此时增大强度阈值,从而增大所述目标接收信号强度与所述强度阈值之间的差值,进而使得第二设备发送的广播信号的接收信号强度更加难以大于强度阈值,以便能够避免第一设备误执行指定操作。
另外,作为一种实施方式,在第一定时器对应的计时时长内,未检测到所述目标接收信号强度大于强度阈值,有可能是第二设备的广播信号依然能够被第一设备接收到,只是接收信号强度比较小而无法大于强度阈值,则在计时完成时,可以直接增大所述强度阈值。作为另一种实施方式,还可以是在第二设备只是短暂出现在第一设备的信号接收范围内,可能在计时期间,第一设备已经无法接收到第二设备发送的广播信号,即第二设备已经远离第一设备的信号接收范围内,则可以在增大所述强度阈值之前,确定第一设备是否仍然能够接收到第二设备发送的广播信号,然后,再确定是否要增大所述强度阈值。
具体地,请参阅图6,图6示出了本申请实施例提供的一种数据处理方法,应用于第一设备,具体地,该方法包括:S601至S607。
S601:在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器。
作为一种实施方式,用户可以预先在第一设备上配置强度阈值。如图7所示,在第一设备上显示有阈值设置界面,在阈值设备界面内包括阈值设置组件701,该阈值设置组件701可以是一个输入组件,该输入组件可以是一个选择菜单也可以是一个输入框,用户触发该阈值设置组件701可以输入指定数值,该指定数值作为本次的强度阈值。作为一种实施方式,可以将此时的强度阈值作为初始阈值。另外,该阈值设置界面还可以包括参考信息702,该参考信息用于表明强度阈值的设置规则,例如,可以包括最小阈值,则用户设备强度阈值的时候,可以基于该最小阈值设置该强度阈值,以避免所设置的强度阈值过小,例如,所设置的强度阈值不小于最小阈值。
作为一种实施方式,考虑到后续强度阈值可能会被增大,则可以在阈值设置界面内设置强度阈值增大的变化规则,如图8所示,阈值设置界面上显示有规则设置组件703,该变化规则用于指示强度阈值被增大的时候的增大规律,具体地,该变化规则可以包括线性递增、指数递增、先陡再平稳或者其他的增大方式,则强度阈值被增大的时候,可以参考该变化规则而设定。如图8所示,用户可以通过操作该规则设置组件703选中一个变化规则,用于后续增大强度阈值。
作为一种实施方式,该最大计时长度作为该第一定时器的计时时长。则该最大计时长度可以基于前述历史数据而设置。具体地,第一定时器对应的最大计时长度可以基于指定设备对应的指定时间长度而设定,其中,所述指定设备为与所述第一设备相关的设备,具体地,与第一设备相关的设备可以是第一设备的登录账号与指定设备的登录账号对应同一个用户,还可以是第一设备曾与指定设备连接或传输过数据,还可以是第一设备与指定设备成功配对。另外,还可以是统计与第一设备连接过的设备,将指定时间段内连接次数超过指定次数的设备作为第一设备的相关设备。
其中,所述指定时间长度为所述第一设备在检测到所述指定设备的广播信号至执行指定操作之间的时间长度,具体地,在第一设备检测到指定设备的广播信号的时候,记为第一时刻,并且基于指定设备的广播信号确定所述第一设备接收到的所述指定设备的接收信号强度,记为指定接收信号强度,在该第一时刻之后的时间长度阈值内检测到指定接收信号强度大于强度阈值时,记为第二时刻,将第一时刻和第二时刻之间的时间长度记为指定时间长度。其中,时间长度阈值可以是预先设定的经验值,如果超过该时间长度阈值还未检测到指定接收信号强度大于强度阈值时,则放弃本次的第一时刻,即本次的指定时间长度无效。
通过统计指定设备的指定时间长度能够统计到与第一设备相关的设备被第一设备发现至第一设备执行指定操作的时间长度,基于该时间长度设置第一定时器的最大计时长度,则如果在该最大计时长度未检测到目标接收信号强度大于强度阈值,可以认为当前的第二设备为与用户不相关的设备。
作为一种实施方式,指定设备对应的指定时间长度为多个,则可以通过该多个指定时间长度确定最大计时长度。具体地,将所述指定设备对应的所有指定时间长度作为备选时间长度,然后,从备选时间长度确定目标时间长度,基于目标时间长度确定最大计时长度。在一些实施例中,将所有的指定时间长度求平均值得到平均后的指定时间长度,将最大计时长度设置为平均后的指定时间长度。在另一些实施例中,将备选时间长度中最近的第一时间段内的指定时间长度作为待选指定时间长度,然后,基于待选指定时间长度确定最大计时长度。例如,将待选指定时间长度的平均值作为最大计时长度。
作为另一种实施方式,指定设备可以为多个,则可以从多个指定设备中确定目标设备,基于目标设备的指定时间长度确定最大计时长度,具体地,从多个指定设备中确定目标设备的实施方式可以是,从多个指定设备中查找最近的第二时间段内与第一设备连 接的设备,然后,查找每个目标设备的指定时间长度,基于每个目标设备的指定时间长度确定最大计时长度,该确定最大计时长度的实施方式可以参考前述实施例,在此不再赘述。
作为另一种实施方式,该第一定时器对应的最大计时长度可以是用户基于第一设备而设置的。在一些实施例中,第一设备可以显示计时设置界面,在该计时设置界面包括最大计时长度的输入组件。请参阅图9,图9所示的计时设置界面内显示有计时输入组件901,用户通过该计时输入组件901输入时长,在确定应用该时长之后,该时长作为最大计时长度。如图9所示,该计时输入组件901包括滑动件(图9所示的圆圈)和指定直线,该滑动件可以在该指定直线上滑动,滑动件在直线上的不同位置时,滑动件对应的数值不同,该数值作为用户的输入时长,直线的最右侧的端点作为所能输入的最大时长,直线的最左侧的端点作为所能输入的最小时长。其中,最大时长和最小时长可以根据实际需要而设定。
另外,图9还包括开关组件902,该开关组件902处于开启状态时,允许第一计时器被打开,即允许第一设备启动第一定时器,而该开关组件902处于关闭状态时,不允许计时器被打开,即不允许第一设备启动第一定时器,则在开关组件902处于开启状态时,该计时输入组件901处于可被操作状态,用户能够通过操作该计时输入组件901输入最大计时长度,该最大计时长度作为第一定时器的计时时长。
S602:基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度。
S603:判断所述目标接收信号强度是否大于强度阈值。
作为一种实施方式,第二设备发送的广播信号是按照第一指定间隔发送的,第一设备接收该广播信号是基于第二指定间隔接收的,所以,也是按照第二指定间隔来统计目标接收信号强度。则在第一设备每次获取到目标接收信号强度,就执行S603。如果目标接收信号强度大于强度阈值,则执行S604,如果目标接收信号强度不大于强度阈值,则执行S605。需要说明的是,执行S603的时候,计时器还在计时。
S604:在所述第一设备上显示预设提示信息,并将所述第一定时器终止。
作为一种实施方式,该预设提示信息可以是上述的弹框信息,也可以是上述的控制界面,当然,也可以是其他的信息,在此不做限定。于本申请实施例中,该预设提示信息可以是与第二设备相关的信息,例如,该预设提示信息包括第二设备的目标参数,该目标参数可以包括第二设备的电量、状态信息等,以便用户通过第一设备了解第二设备,则该目标参数还可以作为第一设备和第二设备之间的连接的参考依据。如图2所示,该预设提示信息内显示有连接按钮,用户通过操作该预设提示信息,建立第一设备和第二设备之间的连接,因此,准确的推送第二设备对应的预设提示信息,能够极大提高用户使用体验度。
在第一设备显示预设提示信息之后,可以将第一定时器终止。也就是说,此时第二设备已经触发第一设备显示预设提示信息,则可以大概率认为该第二设备为第一设备的相关设备,则即使后期的多次触发该第一设备显示预设提示信息也可以无关紧要,则在第一定时器终止之后,结束本方法的执行。即在S604之后,可以直接结束本方法。
S605:判断计时是否完成。
其中,第一定时器超时可以作为计时完成具体地,在第一定时器计时完成的时候,第一设备的系统会生成一个指定参数,第一设备通过检测该指定参数能够确定当前的第一定时器是否超时。其中,该指定参数可以是在第一定时器的计时时长为最大计时长度的时候产生,也可以是在第一定时器被终止的时候产生,从而在计时操作被终止的时候,也能够判定为第一定时器超时。
则如果第一定时器超时,则执行S606,如果第一定时器未超时,则执行S602,即再次获取目标接收信号强度,并执行后续操作。
S606:判断是否能够检测到第二设备发送的广播信号。
如果能够检测到第二设备发送的广播信号,即在计时完成的时候,第一设备依然能够检测到第二设备的广播信号,则说明第二设备依然在第一设备的信号可接收范围内。因此,为了避免后续第一设备所接收的第二设备的广播信号在强度阈值的范围内波动,而导致第一设备的误操作,可以执行S607,以增大所述目标接收信号强度与所述强度阈值之间的差值,即降低第一设备执行指定操作的误触发的可能性。
作为一种实施方式,在执行S604的时候,第一定时器被终止,也被判定为计时完成,然后,在执行S606的时候,如果第一设备能够检测到第二设备发送的广播信号,则执行S607,即增大强度阈值。从而,在第一定时器超时之前,第一设备检测到目标接收信号强度大于强度阈值,并执行指定操作,则在之后,将强度阈值增大,也可以后续第二设备多次较轻易地触发第一设备执行指定操作,从而能够较好地避免第二设备对第一设备的指定操作的多次触发。
如果第一设备不能够检测到第二设备发送的广播信号,则表明第二设备已经不在第一设备的信号可接收范围内,则第二设备触发第一设备执行指定操作的可能性非常低,可以不必执行S607,则可以结束本次方法,也可以返回执行S601,第一设备继续检测周围的设备发送的广播信号。
作为一种实施方式,在第一设备不能够检测到第二设备发送的广播信号之后,确定在预设检测时间长度内是否依然不能够检测到第二设备发送的广播信号,如果是,则结束本次方法,或返回执行S601。如果在该预设检测时间长度内,检测到第二设备发送的广播信号,则执行S607。
S607:增大所述强度阈值。
由于未检测到目标接收信号强度大于强度阈值,所以,目标接收信号强度小于或等于强度阈值,因此,通过增大所述强度阈值的方式,能够增大目标接收信号强度与所述强度阈值之间的差值,降低目标接收信号强度大于强度阈值的可能性。
作为一种实施方式,在第一设备本次检测到第二设备的广播信号之后,首次启动第一定时器的时候,第一设备所使用的强度阈值记为初始阈值,该初始阈值的设定可以参考前述实施例,在此不再赘述。则增大所述强度阈值的实施方式可以是,设置目标幅度值,将初始阈值与目标幅度值之和作为强度阈值。则在首次启动第一定时器的时候,该目标幅度值为0,强度阈值等于初始阈值。然后,在执行S607的时候,可以设置该目标幅度值非0,例如,为正数,从而可以将强度阈值增大。
作为一种实施方式,在第一定时器本次超时后,若所述第一设备仍然能够检测到所述第二设备发送的广播信号,且在第一定时器对应的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大强度阈值,然后,再次启动所述第一定时器,并执行后续操作,直至检测到所述目标接收信号强度大于强度阈值或所述第一设备无法检测到第二设备发送的广播信号。具体地,在再次启动所述第一定时器之后,基于增大后的强度阈值,再次判断第一设备是否满足指定操作条件,其中,指定操作条件为在本次计时结束,若所述第一设备仍然能够检测到所述第二设备发送的广播信号,且在第一定时器对应的计时时长内,未检测到所述目标接收信号强度大于强度阈值。
具体地,首次启动计时的时候,强度阈值为初始阈值,则在首次第一定时器结束之后,若第一设备满足指定操作条件,则将强度阈值增大,具体地,可以是将强度阈值和目标幅度值之和作为新的强度阈值,然后,再次启动第一定时器,并基于新的强度阈值再次确定第一设备是否满足指定操作条件,如果第一设备依然满足指定操作条件,则增 大目标幅度值,从而再次将强度阈值和新的目标幅度值之和作为新的强度阈值,再次启动第一定时器,直至检测到所述目标接收信号强度大于强度阈值或所述第一设备无法检测到第二设备发送的广播信号。
因此,由于启动第一定时器的次数可以是多次,即增大强度阈值的次数为多次,则可以设置降低所述目标接收信号强度或增大所述强度阈值的操作与次数相关。
作为一种实施方式,获取所述第一定时器的当前的启动次数,基于所述启动次数增大强度阈值。具体地,在每次确定第一设备满足指定操作条件,并且,增大强度阈值之后,统计第一定时器的启动次数,例如,首次启动第一定时器,并且在增大强度阈值之后,启动次数设置为1。
具体地,基于所述启动次数增大强度阈值的实施方式为,基于所述启动次数增大所述强度阈值,其中,所述启动次数与所述强度阈值的增大幅度正相关。
以增大强度阈值为增大所述强度阈值为例,说明上述的基于所述启动次数增大强度阈值的过程。具体地,不同的次数对应的目标幅度值不同,次数越多,则目标幅度值越大,即次数与目标幅度值正相关。具体地,强度阈值的公式如下:
RSSI
min=RSSI
0+a*c (2)
其中,RSSI
min为强度阈值,RSSI
0为初始阈值,例如,可以是-60dB,a为权重,为常数,例如,可以是0.5,c为启动次数,其中,a*c为目标幅度值,可以看出,目标幅度值与启动次数正相关。
作为另一种实施方式,还可以统计总计时长度,其中,该总计时长度为每次第一定时器的启动至结束之间的时间长度总和,例如,当前一共启动三次第一定时器,三次计时的计时长度分别为t1、t2和t3,则总计时长度为t1+t2+t3,然后,基于总计时长度增大所述强度阈值,其中,强度阈值的增大幅度与总计时长度正相关。具体地,强度阈值的公式如下:
RSSI
min=RSSI
0+a*T (3)
其中,a*c为目标幅度值,T为总计时长度,可以看出,目标幅度值与总计时长度正相关。
进一步地,强度阈值的公式还可以如下:
RSSI
min=RSSI
0+a*(T/t) (4)
其中,a*(T/t)为目标幅度值,T为总计时长度,t为计时间隔,即最大计时长度,可以看出,目标幅度值与总计时长度正相关。若每次第一定时器都在计时了最大计时长度之后计时结束,并且,最大计时长度不变,则T/t可以作为启动次数。
如图10所示,图10示出了两个曲线,分别为第一曲线L1和第二曲线L2,还示出了初始的强度阈值的阈值线L3,即图10中的横点线,其中,第一曲线和第二曲线分别为不同的设备发送的广播信号为第一设备接收时的接收信号强度曲线,可以看出,第二曲线L2对应的接收信号强度值在阈值线L3附近上下波动,尤其是在3s之后,首次出现第二曲线L2的接收信号强度大于强度阈值,并且接收信号强度在小于和大于强度阈值之间来回波动。如图10所示,第一定时器的计时长度为3s,则随着第一定时器的启动次数的增加,强度阈值逐渐增大,如图10的L4所示,多条黑色横线为执行强度阈值增大后的阈值线,可以看出,接收信号强度与强度阈值之间的差值越来越大,随着时间的增加,接收信号强度大于强度阈值的可能性越来越低,难度越来越大。
另外,合理设置最大计时长度,使得在第一设备在首次检测到第二设备的广播信号之后的首次开启第一定时器的计时长度内,不相关设备的接收信号强度不会大于强度阈值,具体地,可以参考前述关于最大计时长度的设置的实施方式。
作为一种实施方式,每次启动第一定时器的时候,该第一定时器对应的最大计时长 度可以是固定不变的,例如,每次都计时3秒。作为另一种实施方式,每次启动第一定时器的时候,该第一定时器对应的最大计时长度可以是改变的,如图11所示,计时设置界面内还包括用于设置计时时长的变化规律的时长变化设置组件903,通过该时长变化设置组件903可以设定第一定时器对应的最大计时长度的变化规律,该变化规律可以包括逐渐增大、逐渐减小、先增大后减小或先减小后增大等,每次再次启动计时的时候,基于该最大计时长度的变化规律设置本次第一定时器对应的最大计时长度。另外,该计时设置界面还显示有间隔设置组件904,用户通过该间隔设置组件904设置该最大计时长度的变化规律对应的变化幅度,例如,该变化幅度为0.3s,变化规律为逐渐增大,则首次启动第一定时器的计时时长为3s,则第二次启动第一定时器的计时时长为3.3,第三次启动第一定时器的计时时长为3.6,依次类推。
再者,还可以设置计时循环次数,在计时循环次数结束的时候,所述第一设备仍然能够检测到所述第二设备发送的广播信号,且在第一定时器对应的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则保持强度阈值为最近一次设置的强度阈值不变,即不再更新该强度阈值,直至检测到所述目标接收信号强度大于强度阈值或所述第一设备无法检测到第二设备发送的广播信号。如图10所示,第4次计时结束的时候,强度阈值为-58dB,则在之后虽然可以继续计时,但是,强度阈值保持为-58dB,不再更新。如图12所示,计时设置界面还显示有循环次数设置组件905,通过该循环次数设置组件905能够设置计时循环次数,在该计时循环次数结束之后,保持强度阈值为最近一次设置的强度阈值不变,即不再更新该强度阈值。
请参阅图13,其示出了本申请实施例提供的一种数据处理装置1300的结构框图该装置可以包括:计时单元1301、确定单元1302、调整单元1303和执行单元1304。
计时单元1301,用于在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器。
确定单元1302,用于基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度。
调整单元1303,用于当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值。
进一步的,调整单元1303还用于当所述第一定时器超时后,若所述第一设备仍然能够检测到所述第二设备发送的广播信号,且在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值。
进一步的,调整单元1303还用于所述执行预设操作之后,再次启动所述第一定时器,并执行后续操作,直至检测到所述目标接收信号强度大于强度阈值或所述第一设备无法检测到第二设备发送的广播信号。
进一步的,调整单元1303还用于获取所述第一定时器的当前的启动次数;基于所述启动次数增大所述强度阈值,其中,所述启动次数与所述强度阈值的增大幅度正相关。
执行单元1304,用于若检测到所述接收信号强度大于所述强度阈值,则执行指定操作。
进一步的,执行单元1304还用于若检测到所述接收信号强度大于所述强度阈值,则执行指定操作之后,将所述第一定时器终止。
进一步的,执行单元1304还用于若检测到所述接收信号强度大于所述强度阈值,在所述第一设备上显示预设提示信息。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述装置和模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。在本申请 所提供的几个实施例中,模块相互之间的耦合可以是电性,机械或其它形式的耦合。
另外,在本申请各个实施例中的各功能模块可以集成在一个处理模块中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。
请参考图14,其示出了本申请实施例提供的一种电子设备的结构框图。该电子设备10可以是智能手机、平板电脑、电子书等能够运行应用程序的电子设备,具体地,该电子设备10可以是前述的用户设备100。本申请中的电子设备10可以包括一个或多个如下部件:处理器101、存储器102、以及一个或多个应用程序,其中一个或多个应用程序可以被存储在存储器102中并被配置为由一个或多个处理器101执行,一个或多个程序配置用于执行如前述方法实施例所描述的方法。
处理器101可以包括一个或者多个处理核。处理器101利用各种接口和线路连接整个电子设备10内的各个部分,通过运行或执行存储在存储器102内的指令、程序、代码集或指令集,以及调用存储在存储器102内的数据,执行电子设备10的各种功能和处理数据。可选地,处理器101可以采用数字信号处理(Digital Signal Processing,DSP)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)、可编程逻辑阵列(Programmable Logic Array,PLA)中的至少一种硬件形式来实现。处理器101可集成中央处理器(Central Processing Unit,CPU)、图像处理器(Graphics Processing Unit,GPU)和调制解调器等中的一种或几种的组合。其中,CPU主要处理操作系统、用户界面和应用程序等;GPU用于负责显示内容的渲染和绘制;调制解调器用于处理无线通信。可以理解的是,上述调制解调器也可以不集成到处理器101中,单独通过一块通信芯片进行实现。
存储器102可以包括随机存储器(Random Access Memory,RAM),也可以包括只读存储器(Read-Only Memory)。存储器102可用于存储指令、程序、代码、代码集或指令集。存储器102可包括存储程序区和存储数据区,其中,存储程序区可存储用于实现操作系统的指令、用于实现至少一个功能的指令(比如触控功能、声音播放功能、图像播放功能等)、用于实现下述各个方法实施例的指令等。存储数据区还可以存储电子设备10在使用中所创建的数据(比如电话本、音视频数据、聊天记录数据)等。
请参考图15,其示出了本申请实施例提供的一种计算机可读存储介质的结构框图。该计算机可读介质1500中存储有程序代码,所述程序代码可被处理器调用执行上述方法实施例中所描述的方法。
计算机可读存储介质1500可以是诸如闪存、EEPROM(电可擦除可编程只读存储器)、EPROM、硬盘或者ROM之类的电子存储器。可选地,计算机可读存储介质1500包括非易失性计算机可读介质(non-transitory computer-readable storage medium)。计算机可读存储介质1500具有执行上述方法中的任何方法步骤的程序代码1510的存储空间。这些程序代码可以从一个或者多个计算机程序产品中读出或者写入到这一个或者多个计算机程序产品中。程序代码1510可以例如以适当形式进行压缩。
综上所述,本申请实施例提供的数据处理方法、装置、电子设备及计算机可读介质,在所述第一设备检测到第二设备发送的广播信号时,表明第一设备能够扫描到第二设备,然后,启动第一定时器,并且基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度。当所述第一定时器超时后,若在第一定时器对应的计时时长内,检测到所述接收信号强度大于所述强度阈值,则第一设备执行指定操作,若未检测到所述接收信号强度大于所述强度阈值,则表明在该计时时长内,第一设备所接收的第二设备的信号强度未明显增大,则第二设备可能与第一设备不相关。因此,增大所述强度阈值,从而增大所述目标接收信号强度与所述强度阈值之间的差值,进而使得第 二设备发送的广播信号的接收信号强度更加难以大于强度阈值,以便能够避免第一设备误执行指定操作。
因此,在用户终端发现IOT设备的应用中,采用随发现IOT设备的时间动态调整RSSI阈值的处理方法,使RSSI阈值随时间阶段性地增大,保证处于设置的弹框距离外的IOT设备的RSSI值始终小于设定的RSSI阈值,从而阻止该IOT设备在用户终端上的误弹框,提高RSSI测距方案的可靠性。
最后应说明的是:以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不驱使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。
Claims (20)
- 一种数据处理方法,其特征在于,应用于第一设备,所述方法包括:在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器;基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度;当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值;若检测到所述接收信号强度大于所述强度阈值,则执行指定操作。
- 根据权利要求1所述的方法,其特征在于,所述当所述第一定时器超时后若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值,包括:当所述第一定时器超时后,若所述第一设备仍然能够检测到所述第二设备发送的广播信号,且在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值。
- 根据权利要求1所述的方法,其特征在于,所述增大所述强度阈值之后,还包括:再次启动所述第一定时器,并执行后续操作,直至检测到所述目标接收信号强度大于强度阈值或所述第一设备无法检测到第二设备发送的广播信号。
- 根据权利要求3所述的方法,其特征在于,所述增大所述强度阈值,包括:获取所述第一定时器的当前的启动次数;基于所述启动次数增大所述强度阈值,其中,所述启动次数与所述强度阈值的增大幅度正相关。
- 根据权利要求3所述的方法,其特征在于,所述增大所述强度阈值,包括:获取多次启动所述第一定时器对应的总计时长度;基于所述总计时长度增大所述强度阈值,其中,所述总计时长度与所述强度阈值的增大幅度正相关。
- 根据权利要求1-5任一所述的方法,其特征在于,所述若检测到所述接收信号强度大于所述强度阈值,则执行指定操作之后,还包括:将所述第一定时器终止。
- 根据权利要求1-5任一所述的方法,其特征在于,所述若检测到所述接收信号强度大于所述强度阈值,则执行指定操作,包括:若检测到所述接收信号强度大于所述强度阈值,在所述第一设备上显示预设提示信息。
- 根据权利要求1-7任一项所述的方法,其特征在于,所述在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器,包括:当所述第一设备检测到第二设备发送的广播信号时,执行计时操作;判断所述计时操作的计时时长是否满足指定条件;若满足,启动第一定时器。
- 根据权利要求1-8任一项所述的方法,其特征在于,所述基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度,包括:获取所述广播信号的无线功率;获取系统增益;基于所述无线功率以及所述系统增益确定所述目标接收信号强度。
- 根据权利要求1-9任一项所述的方法,其特征在于,所述当所述第一定时器超 时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值之前,还包括:获取所述强度阈值,所述强度阈值通过所述第一设备的阈值设置界面输入。
- 根据权利要求1-9任一项所述的方法,其特征在于,所述当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值之前,还包括:确定与所述第一设备相关的指定设备;获取所述指定设备对应的指定时间长度,所述指定时间长度为所述第一设备在检测到所述指定设备的广播信号至执行指定操作之间的时间长度;基于所述指定时间长度确定所述计时时长。
- 根据权利要求11所述的方法,其特征在于,所述第一设备的登录账号与指定设备的登录账号对应同一个用户。
- 根据权利要求11所述的方法,其特征在于,所述获取所述指定设备对应的指定时间长度,包括:将所述第一设备检测到所述指定设备的广播信号的时刻,记为第一时刻,并且基于所述指定设备的广播信号确定所述第一设备接收到的所述指定设备的接收信号强度,记为指定接收信号强度;在所述第一时刻之后的时间长度阈值内检测到所述指定接收信号强度大于所述强度阈值的时刻,记为第二时刻;将所述第一时刻和所述第二时刻之间的时间长度记为指定时间长度。
- 根据权利要求1-9任一项所述的方法,其特征在于,所述当所述第一定时器超时后,若在所述第一定时器的计时时长内,未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值之前,还包括:获取所述计时时长,所述计时时长通过所述第一设备的计时设置界面输入。
- 根据权利要求14所述的方法,其特征在于,所述计时设置界面包括开关组件,所述开关组件包括开启状态,所述开启状态用于指示允许通过所述第一设备的计时设置界面输入,所述获取所述计时时长,包括:若所述开关组件处于开启状态,获取所述计时时长。
- 根据权利要求15所述的方法,其特征在于,所述计时设置界面还包括时长变化设置组件,所述时长变化设置组件用于设置计时时长的变化规律,所述若所述开关组件处于开启状态,获取所述计时时长,包括:在所述开关组件处于开启状态的情况下,基于所述时长变化设置组件获取所述计时时长的变化规律;基于所述计时时长的变化规律,获取所述计时时长。
- 根据权利要求1-16任一项所述的方法,其特征在于,所述若检测到所述接收信号强度大于所述强度阈值,则执行指定操作,包括:若检测到所述接收信号强度大于所述强度阈值,显示提示信息,所述提示信息用于提示连接所述第一设备和所述第二设备。
- 一种数据处理装置,其特征在于,应用于第一设备,所述装置包括:计时单元,用于在所述第一设备检测到第二设备发送的广播信号时,启动第一定时器;确定单元,用于基于所述第一设备接收到的所述第二设备发送的广播信号,确定目标接收信号强度;调整单元,用于当所述第一定时器超时后,若在所述第一定时器的计时时长内, 未检测到所述目标接收信号强度大于强度阈值,则增大所述强度阈值;执行单元,用于若检测到所述接收信号强度大于所述强度阈值,则执行指定操作。
- 一种电子设备,其特征在于,包括:一个或多个处理器;存储器;一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个应用程序配置用于执行如权利要求1-17任一项所述的方法。
- 一种计算机可读介质,其特征在于,所述计算机可读介质存储有处理器可执行的程序代码,所述程序代码被所述处理器执行时使所述处理器执行权利要求1-17任一项所述方法。
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110579097.6 | 2021-05-26 | ||
CN202110579097.6A CN113329072B (zh) | 2021-05-26 | 2021-05-26 | 数据处理方法、装置、电子设备及计算机可读介质 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2022247424A1 true WO2022247424A1 (zh) | 2022-12-01 |
Family
ID=77416921
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2022/082658 WO2022247424A1 (zh) | 2021-05-26 | 2022-03-24 | 数据处理方法、装置、电子设备及计算机可读介质 |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN113329072B (zh) |
WO (1) | WO2022247424A1 (zh) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113329072B (zh) * | 2021-05-26 | 2022-08-30 | Oppo广东移动通信有限公司 | 数据处理方法、装置、电子设备及计算机可读介质 |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20170332190A1 (en) * | 2016-05-16 | 2017-11-16 | Google Inc. | Adaptive threshold for proximity based wireless communications features |
CN109348431A (zh) * | 2018-11-14 | 2019-02-15 | Oppo广东移动通信有限公司 | 蓝牙扫描方法、装置、设备及存储介质 |
CN112040461A (zh) * | 2019-06-03 | 2020-12-04 | 华为技术有限公司 | 一种靠近发现的方法及设备 |
CN113329072A (zh) * | 2021-05-26 | 2021-08-31 | Oppo广东移动通信有限公司 | 数据处理方法、装置、电子设备及计算机可读介质 |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
GB2489951A (en) * | 2011-04-12 | 2012-10-17 | Nokia Corp | Scanning receiver |
US9520045B2 (en) * | 2014-09-02 | 2016-12-13 | Apple Inc. | Establishment and detection of breakage of wireless leash between devices |
WO2017068230A1 (en) * | 2015-10-21 | 2017-04-27 | Nokia Technologies Oy | Positioning method |
CN112333332B (zh) * | 2020-10-27 | 2021-05-28 | 维沃移动通信有限公司 | 提示信息显示方法、装置及电子设备 |
-
2021
- 2021-05-26 CN CN202110579097.6A patent/CN113329072B/zh active Active
-
2022
- 2022-03-24 WO PCT/CN2022/082658 patent/WO2022247424A1/zh active Application Filing
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20170332190A1 (en) * | 2016-05-16 | 2017-11-16 | Google Inc. | Adaptive threshold for proximity based wireless communications features |
CN109348431A (zh) * | 2018-11-14 | 2019-02-15 | Oppo广东移动通信有限公司 | 蓝牙扫描方法、装置、设备及存储介质 |
CN112040461A (zh) * | 2019-06-03 | 2020-12-04 | 华为技术有限公司 | 一种靠近发现的方法及设备 |
CN113329072A (zh) * | 2021-05-26 | 2021-08-31 | Oppo广东移动通信有限公司 | 数据处理方法、装置、电子设备及计算机可读介质 |
Also Published As
Publication number | Publication date |
---|---|
CN113329072B (zh) | 2022-08-30 |
CN113329072A (zh) | 2021-08-31 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110139262B (zh) | 蓝牙通信控制方法及相关产品 | |
US10205817B2 (en) | Method, device and storage medium for controlling screen state | |
US10511931B1 (en) | Detecting movement of a computing device based on wireless access point signal strength data and adaptive thresholds | |
EP3176984B1 (en) | Method and device for processing information | |
EP3196751A1 (en) | Gesture identification method and device | |
WO2020119230A1 (zh) | 电磁干扰控制方法及相关产品 | |
CN109788423B (zh) | 语音接收方法、装置及计算机可读存储介质 | |
EP3917116A1 (en) | Detecting maximum transmission unit value | |
US20230319615A1 (en) | Communication method, communication apparatus, and storage medium | |
WO2022247424A1 (zh) | 数据处理方法、装置、电子设备及计算机可读介质 | |
WO2023030531A1 (zh) | 提示信息的显示方法、装置、电子设备以及存储介质 | |
US11304141B2 (en) | Controlling device modem scan duty cycle based on device sensor or wireless data | |
CN113329391B (zh) | 提示信息的显示方法、装置、电子设备以及存储介质 | |
CN105704174B (zh) | 信息提示方法及装置 | |
CN107622234B (zh) | 一种显示萌脸礼物的方法和装置 | |
KR102686229B1 (ko) | 랜덤 접속 방법 및 단말 | |
WO2022247468A1 (zh) | 数据处理方法、装置、电子设备及存储介质 | |
CN113395745A (zh) | 接入Mesh网络的方法、装置、终端及存储介质 | |
CN106454078B (zh) | 一种对焦模式控制方法及终端设备 | |
JP7561868B2 (ja) | リソース選択方法及び機器 | |
EP3934293A1 (en) | Communication method and apparatus, and storage medium | |
EP3820127A1 (en) | Microphone hole blockage detecting method and related product | |
CN105635379A (zh) | 噪声抑制方法及装置 | |
WO2023030071A1 (zh) | 广播消息的发射方法、装置、电子设备以及存储介质 | |
WO2023030529A1 (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: 22810158 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 22810158 Country of ref document: EP Kind code of ref document: A1 |