Identification code display method, electronic device, storage medium, and program product
By acquiring the behavioral intent parameters of the terminal device in the target scenario and multi-source radio frequency signals, and combining multi-dimensional judgment, the problem of high false trigger rate of identification codes in the existing technology is solved, and the accuracy and timeliness of identification code display are achieved, thus improving the user experience.
Patent Information
- Application Number
- CN202611293119.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-24
- Publication Date
- 2026-11-20
AI Technical Summary
In existing technologies, terminal devices rely solely on geolocation to determine the display of identification codes, which cannot effectively distinguish between the valid scenario of a user entering the store for consumption and the scenario of passing through the store, resulting in a high rate of false triggers and affecting the user experience.
By acquiring the behavioral intent parameters of the terminal device in the target scenario, including the target's moving speed, dwell time, and signal strength, and combining multi-source radio frequency signals, the terminal device's tendency to display the identification code is judged. The behavioral intent dimension is introduced for secondary screening, and the display operation is only performed when there is indeed an intent to display the identification code.
It significantly reduced the false trigger rate of identification code display, improved the timeliness and accuracy of display, and enhanced the user experience.
Smart Images

Figure CN123140949A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of mobile payment and smart terminal interaction technology, and in particular to a method for displaying identification codes, an electronic device, a storage medium, and a program product. Background Technology
[0002] In offline stores and other target scenarios, terminal devices can complete business interactions such as consumption verification and rights redemption by displaying identification codes. The logic for triggering the display of identification codes directly affects the user experience. To facilitate users in quickly completing business operations, terminal devices can trigger the display of identification codes based on location information, thereby reducing the cumbersome manual operation for users.
[0003] Existing technologies mostly rely on single location information to trigger identification code judgment. When the terminal device enters the geographical area covered by the store, the identification code will pop up and be displayed directly, relying solely on geographical location to complete scene judgment and identification code display.
[0004] However, this method cannot effectively distinguish between the valid scenario of a user entering the store to make a purchase and the scenario of passing by the store. As long as the terminal device falls within the geographical range of the target scenario, the identification code will be displayed, which is prone to false triggering. Summary of the Invention
[0005] This application provides a method for displaying identification codes, an electronic device, a storage medium, and a program product, which can at least reduce the false trigger rate of identification code display.
[0006] A first aspect of this application provides a method for displaying an identification code, comprising: in response to a terminal device being located in a target scene where there is a need to display an identification code, obtaining behavioral intent parameters of the terminal device in the target scene; the behavioral intent parameters being used to characterize the tendency of the terminal device to display an identification code in the target scene; and in response to determining, based on the behavioral intent parameters, that the terminal device has the intention to display an identification code, displaying an identification code corresponding to the target scene.
[0007] A second aspect of this application provides an electronic device, comprising: at least one processor; at least one memory for storing at least one program; and, when the at least one program is executed by the at least one processor, implementing the identification code display method provided in any of the above aspects.
[0008] A third aspect of the embodiments of this application provides a computer-readable storage medium storing computer-executable instructions for performing the identification code display method provided in any of the above aspects.
[0009] A fourth aspect of this application provides a computer program product, including a computer program or computer instructions, which are stored in a computer-readable storage medium. A processor of a communication device reads the computer program or computer instructions from the computer-readable storage medium and executes the computer program or computer instructions, causing the communication device to perform the identification code display method provided in any of the above aspects.
[0010] In the identification code display method provided in this application embodiment, after determining that the terminal device is located in a target scene where there is a need to display identification codes, a behavioral intent parameter that can characterize the terminal device's tendency to display identification codes is further obtained. Geographical location is no longer used as the sole criterion for judgment. A behavioral intent dimension that can reflect the user's true intention to use the device is introduced for secondary screening. Only when it is determined based on the behavioral intent parameter that the terminal device does indeed have the intention to display identification codes will the corresponding identification code display operation be executed. This can filter out invalid scenarios such as the terminal device merely entering the target scene geographically, but the user has no intention of performing business operations such as consumption verification or rights verification, thereby effectively reducing the false trigger rate of identification code display. Attached Figure Description
[0011] The accompanying drawings are used to provide a further understanding of the technical solutions of this application and constitute a part of the specification. They are used together with the embodiments of this application to explain the technical solutions of this application and do not constitute a limitation on the technical solutions of this application.
[0012] Figure 1 This is a flowchart illustrating the identification code display method provided in the embodiments of this application; Figure 2 This is a schematic diagram of a scene-aware intelligent QR code display process provided in an embodiment of this application; Figure 3 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Detailed Implementation
[0013] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0014] It should be understood that in the description of the embodiments of this application, the use of terms such as "first" and "second" is only for the purpose of distinguishing technical features and should not be construed as indicating or implying relative importance, or implicitly indicating the number of technical features indicated, or implicitly indicating the order of the technical features indicated. "At least one" refers to one or more, and "more" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent the existence of A alone, the simultaneous existence of A and B, or the existence of B alone. A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one of the following" and similar expressions refer to any group of these items, including any group of singular or plural items. For example, at least one of a, b, and c can represent: a, b, c, a and b, a and c, b and c, or a and b and c, where a, b, and c can be single or multiple.
[0015] To facilitate understanding of the solutions in the embodiments of this application, some contents involved in the embodiments of this application are described below: Traditional methods of displaying identification codes rely on a single location to directly pop up and display the code when a terminal device enters the geographical area covered by a store. This method cannot effectively distinguish between a user's valid interaction scenario of entering the store for consumption and a passing scenario of simply passing by the store, which can easily lead to false triggers and affect the user experience.
[0016] Based on this, this application provides a method for displaying identification codes, an electronic device, a storage medium, and a program product, which can at least reduce the false trigger rate of identification code display.
[0017] like Figure 1 The diagram illustrates a method for displaying identification codes, which can be applied to terminal devices and includes the following steps S110 to S120: S110, in response to the terminal device being located in a target scenario where there is a need to display an identification code, obtain the behavioral intent parameters of the terminal device in the target scenario; the behavioral intent parameters are used to characterize the terminal device's tendency to display the identification code in the target scenario; S120, in response to determining that the terminal device has the intention to display an identification code based on the behavioral intent parameters, displays an identification code corresponding to the target scenario.
[0018] For ease of understanding, the following explains some key terms in this embodiment: A terminal device can refer to any electronic device with computing and communication capabilities, such as smartphones, tablets, smartwatches, and in-vehicle terminals. This terminal device is capable of performing the various operations described in this method, including acquiring parameters, making judgments, and displaying identification codes.
[0019] An identification code is a graphic or digital code used for purposes such as identity verification, transaction payment, and information verification, such as a QR code, barcode, or number string. This identification code is typically associated with a specific business or service and is displayed for scanning or input in specific scenarios, such as payment and transportation scenarios.
[0020] The target scenario refers to the specific physical environment or location where there is a need to display the identification code, such as offline stores, public transportation stations, and event venues. In this target scenario, users may need to display the identification code to complete some kind of interactive behavior.
[0021] Behavioral intent parameters refer to various data used to quantify or characterize the tendency of a terminal device to display an identification code in a target scenario. Acquiring and analyzing these parameters helps the system determine whether a user truly needs to display an identification code, thereby avoiding unnecessary code displays.
[0022] Based on the explanation of the above key terms, the specific implementation process of the identification code display method provided in the embodiments of this application will be described in detail below.
[0023] Specifically, this method acquires the behavioral intent parameters of the terminal device in a target scenario where an identification code needs to be displayed. As one implementation, the terminal device is configured to initiate the acquisition process of behavioral intent parameters upon confirming that the user has entered the target scenario. For example, once the terminal device detects that it is in the target scenario, it begins collecting parameters related to user behavior.
[0024] These behavioral intent parameters can be obtained based on sensor data inside the terminal device. For example, the device's motion sensor data can be analyzed to obtain its movement status information, or a timer can be used to record the time the terminal device stays in the current scene.
[0025] The acquired behavioral intent parameters were used to assess the likelihood of the terminal device displaying the identification code in the target scenario. These parameters reflect the user's activity level, dwell time, or intensity of interaction with the scenario. For example, if the terminal device moves at a low speed or stays in the target scenario for a long time, the user is considered more likely to display the identification code. Conversely, if the terminal device moves quickly through the target scenario at a high speed, the user is less likely to display the identification code.
[0026] Furthermore, after acquiring the behavioral intent parameters, the system analyzes these parameters according to preset judgment logic to determine whether the terminal device intends to display the identification code. For example, a preset intent threshold can be set; when the behavioral intent parameters reach or exceed this preset threshold, it is determined that there is an intent to display the identification code.
[0027] Once the intent is confirmed, the terminal device will automatically display an identification code that matches the current target scenario. The identification code can be displayed directly on the terminal device's screen to allow the user to perform subsequent scanning or operations.
[0028] In one possible implementation, before displaying the identification code, the terminal device reads the scene information pre-stored in the local database to determine at least one of the identification code corresponding to the target scene and the user's preferred payment method.
[0029] In one possible implementation, the terminal device can display an identification code or scanning interface corresponding to the target scenario, and support one-click switching between the identification code and the scanning interface.
[0030] In one possible implementation, after the user leaves the target scene, the terminal device saves information such as the payment method used to the local database, and further returns a low-power scan status to determine whether the user is in the target scene where an identification code display is required, thus forming a closed loop in the process.
[0031] In this embodiment, after determining that the terminal device is located in a target scenario where there is a need to display an identification code, a behavioral intent parameter that can characterize the terminal device's tendency to display the identification code is further obtained. Geographical location is no longer used as the sole criterion for judgment. A behavioral intent dimension that can reflect the user's true intention to use the device is introduced for secondary screening. Only when it is determined based on the behavioral intent parameter that the terminal device does indeed have the intention to display the identification code will the corresponding identification code display operation be executed. This can filter out invalid scenarios where the terminal device is merely geographically entering the target scenario but the user has no intention of performing business operations such as consumption verification or rights verification, thereby effectively reducing the false trigger rate of identification code display.
[0032] In some embodiments, this application further proposes that the behavioral intent parameter includes at least one of the following: Target movement speed; Target dwell time; Target signal strength; target signal strength is used to characterize the strength of the wireless signal received by the terminal device that reflects the target scene.
[0033] In this embodiment, the target moving speed refers to the movement rate of the terminal device in the target scene. This parameter can be acquired and calculated using data from various sensors built into the terminal device.
[0034] Target dwell time refers to the length of time a terminal device remains continuously within a target scene. Obtaining this parameter depends on the terminal device's positioning capabilities.
[0035] Target signal strength refers to the strength of the wireless signal received by the terminal device that reflects the characteristics of the target scene. Obtaining this parameter involves the terminal device's monitoring of specific wireless signals.
[0036] Specifically, the terminal device can use its integrated Global Positioning System (GPS) module to calculate the displacement per unit time using continuous positioning data points, thereby determining the moving speed. Alternatively, it can combine accelerometer and gyroscope data from the Inertial Measurement Unit (IMU) to estimate the terminal device's real-time moving speed using dead reckoning algorithms.
[0037] The system starts timing when the terminal device is first detected entering the geographical area or signal coverage area of the target scene. Thereafter, the system continuously monitors the terminal device's location information or signal characteristics, and the timer continues to accumulate as long as the terminal device remains within the target scene. Once the terminal device leaves the target scene, the timer stops, and the total duration of the stay is recorded.
[0038] In one possible implementation, if the terminal device loses signal or the target moves faster than the preset interruption time (e.g., 3 seconds) during the timing process, the target dwell time is reset to zero.
[0039] Specific Wi-Fi hotspots, Bluetooth beacons, or Near Field Communication (NFC) tags can be deployed in the target scenario. The terminal device, through its wireless communication module, periodically scans and measures the Received Signal Strength Indicator (RSSI) values of these signals. A higher RSSI value generally indicates that the terminal device is closer to the signal source or is in the core area of signal coverage, thus indirectly reflecting the physical proximity of the terminal device to the target scenario and the signal characteristics of the surrounding environment.
[0040] By introducing target movement speed, target dwell time, and target signal strength as specific behavioral intent parameters, this application enables a more refined and quantitative assessment of the terminal device's tendency to display identification codes in target scenarios. The introduction of these specific parameters allows the system to more accurately and reliably determine the terminal device's intent to display identification codes, thereby avoiding misjudgments or omissions caused by ambiguous parameters and significantly improving the timeliness, accuracy, and user experience of identification code display.
[0041] In some embodiments, this application further proposes that for a terminal device to have the intention to display an identification code, at least one of the following must be met: The target's movement speed is less than or equal to a preset speed threshold; The target dwell time is greater than or equal to a preset duration threshold; The target signal strength meets the signal strength condition; the signal strength condition is used to determine whether the terminal device is within the effective signal coverage range of the target scene.
[0042] In this embodiment, the condition that the target moving speed is less than or equal to a preset speed threshold is used to determine the movement state of the terminal device in the target scene. The target moving speed can be obtained in real time through sensors built into the terminal device, such as accelerometers, gyroscopes, or GPS modules.
[0043] The preset speed threshold is a configurable value, and its setting should be adjusted according to the specific application scenario and user behavior patterns. For example, in scenarios where the user needs to be stationary or move slowly to perform the operation, the threshold can be set to a low value, such as 0.5 m / s or 1 m / s, to ensure that the user is only considered to have the intention to display the identification code when they are relatively stationary or walking.
[0044] In one possible implementation, the condition is determined to be met when the target's moving speed is less than or equal to a preset speed threshold, such as 2.0 m / s, for a continuous preset duration, such as 6 seconds. If the target's moving speed is greater than a preset upper limit threshold, such as 4.0 m / s, the terminal device is directly determined to be in a passing state, and the display of the identification code is suppressed.
[0045] The condition that the target dwell time is greater than or equal to a preset duration threshold is used to evaluate the length of time the terminal device stays in the target scene. The target dwell time can be calculated by continuously monitoring the presence of the terminal device in the target scene.
[0046] The preset duration threshold is also a configurable parameter, and its setting should reflect the minimum dwell time required for a user to interact in a specific scenario. For example, if a user typically needs to stay for 5 or 10 seconds or more to complete an operation, the threshold can be set to the corresponding time to avoid misinterpreting the user's intentions when the user is only briefly passing by.
[0047] In one possible implementation, the preset duration threshold can be configured according to the target scenario type. For example, the preset duration threshold for a convenience store scenario can be configured to 10 seconds, and the preset duration threshold for a subway scenario can be configured to 15 seconds.
[0048] The requirement that the target signal strength meets the signal strength condition is used to ensure that the terminal device is within the effective signal coverage range of the target scene, thereby guaranteeing the reliability of subsequent interactions. Target signal strength refers to the strength of the wireless signal received by the terminal device that reflects the target scene, such as Wi-Fi, Bluetooth, or near-field communication signals.
[0049] Signal strength conditions can be defined as a specific signal strength range, for example, the Received Signal Strength Indicator (RSSI) being between -70dBm and -40dBm. By meeting this condition, situations where the terminal device is geographically close to the target scene but cannot interact effectively due to a weak signal can be effectively ruled out.
[0050] In one possible implementation, the signal strength condition can be determined as shown in Table 1 below: Table 1. Schematic diagram of signal strength conditions
[0051] If any one of the above three signal conditions is met, the target signal strength is determined to meet the signal strength condition.
[0052] It is understandable that by jointly determining the target's movement speed, dwell time, and signal strength, the criteria for scene determination can be upgraded from single-location judgment to multi-dimensional behavioral understanding: the target movement speed dimension is used to determine whether the user has slowed down to the walking level corresponding to the scene, the target dwell time dimension is used to determine whether the user stays in the scene continuously, and the target signal strength dimension is used to determine whether the user is within the effective coverage area of the scene.
[0053] In one possible implementation, the three dimensions are independent of each other and mutually verify each other. When the terminal device simultaneously meets the conditions of the above three dimensions, it is confirmed that the terminal device has the intention to display the identification code, thereby triggering the display of the identification code.
[0054] Through the above technical solution, this application can more accurately and reliably determine the intention of a terminal device to display an identification code in a target scenario. When the terminal device meets these conditions, such as the user being relatively stationary or moving slowly in the target scenario for a sufficiently long time, and the terminal device being within the effective signal coverage range of the target scenario, this comprehensively indicates that the user has a clear interaction intention. This quantitative judgment mechanism based on multi-dimensional behavioral parameters effectively avoids the inaccuracy caused by judging based on a single or fuzzy parameter, significantly reduces the false judgment rate, and ensures that the identification code is only displayed when the user truly needs it.
[0055] In some embodiments, this application further proposes that, prior to S110, the following steps are included: Based on the multi-source radio frequency signals collected by the terminal device, determine whether the terminal device is located in the target scene; Among them, multi-source radio frequency signals are signals originating from different radio frequency emission sources, used to sense the scene environment in which the terminal device is located.
[0056] In this embodiment, "multi-source radio frequency signals" refers to a collection of signals emitted by various types of radio transmitters, such as, but not limited to, Wi-Fi signals, Bluetooth signals, and Near Field Communication (NFC) signals. These different radio frequency transmitters typically have different coverage areas, signal characteristics, and recognition accuracies. The purpose of using multi-source radio frequency signals is to improve the accuracy and robustness of scene perception. A single type of radio frequency signal may be affected by environmental interference, signal obstruction, or coverage limitations, leading to deviations in scene judgment. By comprehensively utilizing signals from different radio frequency transmitters, they can complement and verify each other, thereby obtaining more comprehensive and reliable scene environment information.
[0057] Specifically, this step of determining whether a terminal device is located in a target scene based on multi-source radio frequency signals collected by the terminal device aims to accurately determine whether its current physical environment is a preset target scene by analyzing the wireless signals received by the terminal device. Its purpose is to provide accurate scene triggering conditions for subsequent acquisition of behavioral intent parameters and display of identification codes.
[0058] In one possible implementation, the terminal device can continuously or periodically scan and collect various radio frequency (RF) signals in its surrounding environment. These signals carry scene-related characteristic information, such as signal strength, signal source identification, and signal type. The system processes and analyzes these collected RF signals, for example, by comparing them with pre-stored RF feature fingerprints of the target scene, or by using machine learning models to classify the signal features, thereby determining whether the terminal device is within the target scene.
[0059] As an example, terminal devices can encapsulate hardware drivers such as Wi-Fi modules, Bluetooth modules, near-field communication modules, satellite positioning modules, motion sensors, and display modules through a hardware abstraction layer, providing a unified application programming interface (API) to the upper layer to achieve output control for the acquisition of multi-source radio frequency signals and the display of identification codes.
[0060] Furthermore, when determining whether a terminal device is located in a target scene based on multi-source radio frequency signals, a hierarchical confidence strategy can be adopted: For contactless far-field signals such as Wi-Fi signals and long-range Bluetooth signals, a weighted summation can be used to calculate the total scene confidence score, thereby determining whether the terminal device is located in the target scene based on the total scene confidence score. For near-field triggering signals such as near-field communication signals and near-field Bluetooth signals, a hard threshold saturation mechanism can be enabled, and the relationship between the signal and the hard threshold can be used to directly determine whether the terminal device is located in the target scene. The specific implementation process of this hierarchical confidence strategy can be found in subsequent embodiments.
[0061] By employing the aforementioned technical solution, this application introduces a step of determining whether the terminal device is located in a target scene based on multi-source radio frequency signals before obtaining the behavioral intent parameters of the terminal device. This improvement enables the system to more accurately perceive the actual environment in which the terminal device is located. Given that multi-source radio frequency signals can provide rich and complementary scene information, for example, by combining the characteristics of different signals such as Wi-Fi, Bluetooth, and NFC, the system can overcome the limitations of a single signal source and effectively improve the accuracy and reliability of scene recognition.
[0062] In some embodiments, this application further proposes that the multi-source radio frequency signals include near-field communication signals; Based on multi-source radio frequency signals collected by the terminal device, determine whether the terminal device is located in the target scene, including: In response to reading a valid scene identifier from the near-field communication signal, the terminal device is determined to be located in the target scene; the valid scene identifier is identity information that matches the target scene; In response to the failure to read a valid scene identifier from the near-field communication signal, the system determines whether the terminal device is located in the target scene based on the scene confidence scores corresponding to the multi-source radio frequency signals. The scene confidence score is used to characterize the probability that the terminal device indicated by the radio frequency signal is located in the target scene.
[0063] In this embodiment, Near Field Communication (NFC) is a short-range, high-frequency wireless communication technology that allows for contactless point-to-point data transmission. Its characteristics include short communication distance (typically within a few centimeters), high security, low power consumption, and the ability to quickly establish a connection.
[0064] A valid scene identifier is data pre-configured in a near-field communication (NFC) tag. Its content can include a unique identifier for the target scene, scene type, geographic location information, service provider information, or any other identity data that clearly indicates a specific scene. For example, at a subway turnstile, the NFC tag might store a unique identifier for "subway turnstile entrance." The terminal device determines whether a match is found by comparing the read identifier with its own stored or cloud-based scene identifier database.
[0065] Scene confidence is a quantitative metric used to assess the likelihood that a terminal device is in a target scene for a specific radio frequency signal, such as a Wi-Fi signal or Bluetooth signal. For example, if the strength and Basic Service Set Identifier (BSSID) of a Wi-Fi signal highly match the preset characteristics of the target scene, the scene confidence corresponding to that Wi-Fi signal will be high. By combining the scene confidence of multiple radio frequency signals, a more comprehensive and accurate scene determination result can be obtained.
[0066] Specifically, this application uses near-field communication signals as a type of multi-source radio frequency signal. Their unique short-range characteristics enable them to provide highly accurate scene recognition capabilities in specific scenarios, such as payment terminals, access control systems, or information query points where close-range interaction is required. When a terminal device approaches or comes into contact with a device containing a near-field communication tag, the terminal device can read the information stored in the tag through its built-in near-field communication module. If the read information contains identity information matching a preset target scene—that is, a valid scene identifier—then it can be immediately and with high confidence determined that the terminal device is located in that target scene.
[0067] In one possible implementation, the effective scenario identifier can be deployed at key physical locations within the target scenario. For example, passive near-field communication tags can be deployed near the barcode scanner at a convenience store checkout or on the checkout sign. These tags typically operate at a frequency of 13.56MHz and comply with the ISO / IEC 14443 standard. The effective scenario identifier is pre-written with information such as scenario type, store number, checkout number, trigger action, identification code type, and preferred payment application.
[0068] The terminal device enables near-field communication (NFC) functionality, which requires prior user authorization. When the terminal device approaches a valid scene identifier (typically less than 5 centimeters away), the NFC controller detects the valid scene identifier and triggers the system's NFC service. A dedicated application registered on the terminal device receives NFC Data Exchange Format (NDEF) messages, parses the data payload, and extracts fields such as scene type and identification code type as current scene feature information.
[0069] When a terminal device fails to read a valid scene identifier from the near-field communication signal—for example, if the terminal device is not near any near-field communication tag, or the tag is damaged or the information is mismatched—the system will not immediately abandon scene determination. Instead, it will activate a backup mechanism. At this time, the system will comprehensively analyze other types of multi-source radio frequency signals, such as Wi-Fi signals and Bluetooth signals, and further determine whether the terminal device is located in the target scene based on the probability indicated by each of these signals, i.e., the scene confidence level. This ensures the robustness and coverage of scene determination.
[0070] As an example, let the target scene type be S, and the feature set collected within a preset time window, such as 10 seconds, be F = {f_GPS, f_Wi-Fi, f_BT, f_NFC}. Then the total scene confidence can be: C_total(S) = α·C_GPS(S) + β·C_Wi-Fi(S) + γ·C_BT(S) + δ·C_NFC(S) Where α+β+γ+δ=1 are all weighting coefficients, and these weighting coefficients can be dynamically adjusted according to the target scenario type. For example, in indoor scenarios, the weight α corresponding to satellite positioning is reduced, while the weights β and γ corresponding to Wi-Fi and Bluetooth are increased.
[0071] The confidence scores for each scenario are explained below: C_GPS(S): The value is 1 if the satellite positioning coordinates fall within the preset geofence of the target scene, and 0 otherwise; C_Wi-Fi(S): Obtained by the weighted voting result of multiple Wi-Fi hotspots, with a value range of 0 to 1; the specific implementation process of the weighted voting of multiple Wi-Fi hotspots can be found in the following embodiments. C_BT(S): 0.8 when Bluetooth beacon pairing is successful and the distance between them is less than 5 meters, 1 when the distance between them is less than 2 meters, and 0 otherwise; C_NFC(S): 1 when a matching valid scene identifier is read, otherwise 0.
[0072] In one possible implementation, a scene trigger threshold Th_on and a scene exit threshold Th_off are preset, for example, Th_on=0.7 and Th_off=0.3. When the total scene confidence is greater than or equal to the scene trigger threshold, it can be determined that the terminal device has entered the target scene; when the total scene confidence is less than or equal to the scene exit threshold, it can be determined that the terminal device has left the target scene.
[0073] Furthermore, the terminal device can be determined to be in the target scene and the preparation for displaying the identification code can be triggered only when the total scene confidence C_total(S) is greater than or equal to the scene trigger threshold Th_on for a consecutive preset number of sampling periods (e.g., 3, each sampling period is 2 seconds).
[0074] Furthermore, when the total scene confidence C_total(S) is less than or equal to the scene exit threshold Th_off for a consecutive preset number of sampling periods, it can be determined that the terminal device has left the target scene. As an example, the number of sampling periods can be 5. This is only an example and does not constitute a limitation on the present invention.
[0075] By setting the difference between the scene trigger threshold and the scene exit threshold, anti-shake function can be achieved, avoiding frequent switching of scene judgment near the boundary.
[0076] Through the above technical solution, this application provides a layered and efficient scene recognition mechanism. First, by utilizing the short-range and high-precision characteristics of near-field communication signals, when the terminal device can read a valid scene identifier, it can quickly and accurately determine that the terminal device is located in the target scene. This avoids complex and time-consuming comprehensive analysis of other radio frequency signals, significantly improving the real-time performance and efficiency of scene recognition. Second, when the near-field communication signal cannot provide a valid scene identifier, the system can seamlessly switch to a backup mechanism based on the scene confidence levels corresponding to each of the multi-source radio frequency signals. This mechanism fully utilizes the coverage and diversity of other radio frequency signals, ensuring the robustness and accuracy of scene judgment by comprehensively evaluating the probability of different signals indicating a scene, and avoiding judgment failure due to the failure of a single signal.
[0077] In some embodiments, this application further proposes that the multi-source radio frequency signal also includes a Wi-Fi signal; Determining whether a terminal device is located in the target scene based on the scene confidence levels corresponding to each of the multi-source radio frequency signals also includes: The target basic service set identifier in the Wi-Fi signal is matched with the standard basic service set identifier of the target scenario to obtain the first matching result; In response to the first matching result indicating a successful match, the scene confidence level corresponding to the Wi-Fi signal is determined based on the first received signal strength of the Wi-Fi signal and the standard Wi-Fi signal strength range of the target scene.
[0078] In this embodiment, Wi-Fi signal is a wireless local area network signal, widely used in indoor positioning and scene perception. Terminal devices can obtain broadcast signal information, including the Basic Service Set Identifier (BSSID) and Received Signal Strength Indicator (RSSI), by scanning surrounding Wi-Fi access points. As a type of multi-source radio frequency signal, Wi-Fi signal can provide rich environmental information, helping to determine the scene in which the terminal device is located.
[0079] The target basic service set identifier refers to the MAC address of the access point carried by the Wi-Fi signal currently scanned by the terminal device. The standard basic service set identifier is a pre-configured Wi-Fi access point MAC address associated with a specific target scenario.
[0080] The first matching result is the output of the basic service set identifier matching process described above. It is usually a Boolean value indicating whether the match was successful or failed. When the match is successful, it indicates that the terminal device may be located within the target scene, providing a basis for subsequent scene confidence calculation.
[0081] The first received Wi-Fi signal strength refers to the strength value of the Wi-Fi signal received by the terminal device, usually measured in dBm. This strength value reflects the distance between the terminal device and the Wi-Fi access point and the signal attenuation. The terminal device measures and acquires this first received signal strength in real time through its built-in wireless communication module. The standard Wi-Fi signal strength range for a specific target scenario is a pre-defined and reasonable range of Wi-Fi signal strength for that scenario.
[0082] Specifically, the matching process for target basic service set identifiers typically involves comparing one or more target basic service set identifiers scanned by the terminal device with standard basic service set identifiers stored in the target scenario database. If one or more target basic service set identifiers are completely identical to the standard basic service set identifiers, the match is considered successful.
[0083] Furthermore, once the basic service set identifier is successfully matched, the confidence level of the Wi-Fi signal in determining the scene can be further quantified by comparing the first received signal strength measured by the terminal device with the standard Wi-Fi signal strength range of the target scene. If the first received signal strength falls within the standard Wi-Fi signal strength range, the scene confidence level is high; if it falls at the edge of the range or outside the range, the scene confidence level is correspondingly lower.
[0084] For example, the scene confidence can be calculated by using linear interpolation or piecewise functions based on the position of the first received signal strength within the standard Wi-Fi signal strength range, so that the closer the signal strength is to the center of the range, the higher the scene confidence.
[0085] By employing the above technical solution, when determining whether a terminal device is located in a target scene using multi-source radio frequency signals, the judgment can be made more accurately using Wi-Fi signals. First, by matching the target basic service set identifier in the Wi-Fi signal with the standard basic service set identifier of the target scene, it is possible to quickly and preliminarily confirm whether the terminal device is within the coverage area of the Wi-Fi network associated with the target scene, effectively eliminating interference from Wi-Fi signals unrelated to the target scene. Based on this, in response to a successful match, further comparison is made between the first received signal strength of the Wi-Fi signal and the standard Wi-Fi signal strength range of the target scene. This allows for the quantification of the specific location or distance of the terminal device within the target scene, thereby enabling a more refined assessment of the confidence level of the scene indicated by the Wi-Fi signal.
[0086] In some embodiments, this application further proposes that, after matching the target basic service set identifier in the Wi-Fi signal with the standard basic service set identifier of the target scenario to obtain a first matching result, the method further includes: In response to the first matching result indicating a matching failure, the target service set identifier in the Wi-Fi signal is matched with the standard service set identifier of the target scenario to obtain a second matching result; In response to the second matching result indicating a successful match, the scene confidence level corresponding to the Wi-Fi signal is determined based on the first received signal strength of the Wi-Fi signal and the standard Wi-Fi signal strength range of the target scene.
[0087] In this embodiment, when a terminal device attempts to match the Basic Service Set Identifier (SSID) in the Wi-Fi signal with the Standard Basic Service Set Identifier (SSI) of the target scene, but the first matching result indicates a failure, the system does not immediately abandon the Wi-Fi signal as a basis for scene determination. Instead, it further attempts to match using the Service Set Identifier (SSID). This step aims to provide a backup or supplementary Wi-Fi scene identification mechanism to address the situation where BSSID matching fails, thereby improving the robustness of scene identification.
[0088] Once an SSID match is successful (i.e., the second matching result indicates a successful match), the system further utilizes the first received Wi-Fi signal strength to assess the confidence level that the terminal device is located in the target scene. The first received signal strength is an indicator of the strength of the Wi-Fi signal received by the terminal device, and is typically related to the distance between the terminal device and the Wi-Fi access point. By comparing the current first received Wi-Fi signal strength with a preset standard Wi-Fi signal strength range for the target scene, the system can determine whether the terminal device is within the effective coverage area of the target scene and the reasonableness of its location.
[0089] In a possible implementation, the terminal device actively scans surrounding Wi-Fi access points through the Wi-Fi management module, and collects auxiliary information such as a Service Set Identifier (SSID), a Basic Service Set Identifier (BSSID), a Received Signal Strength Indicator (RSSI, in dBm), as well as channels and encryption types.
[0090] The terminal device may adopt a low-power periodic scanning manner, for example, scanning once every 5 seconds, and the scanning result includes a list of all detectable Wi-Fi access points in the current environment. For example, the mobile terminal actively scans surrounding Wi-Fi hotspots through the Wi-Fi management module, and collects the following key characteristic parameters: 1) SSID: Wi-Fi network name, for example, "Meiyijia".
[0091] 2) BSSID: the MAC address of the Wi-Fi access point, which is unique and used to accurately identify a specific router or AP.
[0092] 3) RSSI: signal strength (in dBm), which reflects the distance between the mobile terminal and an Access Point (AP).
[0093] 4) Auxiliary information such as channels and encryption types.
[0094] In the offline phase, Wi-Fi fingerprint collection may be performed on site in each target scenario to construct a scenario fingerprint database. Each fingerprint record includes a scenario identifier, a Wi-Fi fingerprint list, and a scenario type. The Wi-Fi fingerprint herein includes a feature set of a service set identifier, a basic service set identifier, a received signal strength interval, a weight, and the like. For example, example data of one fingerprint record is as follows: the scenario IDs are convenience store A and convenience store B; the Wi-Fi fingerprint list includes two Wi-Fi fingerprints, the first fingerprint: SSID is "ShopA_AP", BSSID is "AA:BB:CC:DD:EE:01", the RSSI interval is [-65dBm, -40dBm], and the weight is 0.6; the second fingerprint: SSID is "ShopB_AP", BSSID is "AA:BB:CC:DD:EE:03", the RSSI interval is [-75dBm, -50dBm], and the weight is 0.1; the scenario type is a convenience store.
[0095] The scenario fingerprint database may be stored locally on the terminal device, and also supports on-demand downloading and updating from the cloud.
[0096] During real-time matching, the following steps can be performed in sequence: Basic Service Set Identifier Precise Matching: The basic service set identifier of each scanned Wi-Fi access point is compared with the records in the scene fingerprint database. If the basic service set identifiers match perfectly, one or more candidate target scenes associated with that access point in the fingerprint database are matched.
[0097] Fuzzy matching of service set identifiers: If the basic service set identifier cannot be matched precisely (e.g., access point equipment is changed), service set identifier matching is performed. For example, if a service set identifier starting with a specific brand name pre-stored in the fingerprint database is detected, it is determined to be a store scenario of the corresponding brand.
[0098] Received signal strength threshold verification: For a matched Wi-Fi access point, check whether the real-time received signal strength of the access point obtained by the terminal scan falls within the standard Wi-Fi signal strength range recorded in the scene fingerprint database. If the real-time received signal strength is too weak (e.g., below -80dBm), it indicates that the terminal device is too far from the access point, reducing the scene confidence corresponding to the access point.
[0099] Multi-hotspot weighted voting: For multiple Wi-Fi access points that are matched at the same time, a weighted voting mechanism is used to calculate the scene confidence C_Wi-Fi(S) corresponding to the Wi-Fi signal. When C_Wi-Fi(S) exceeds a preset threshold (e.g., 0.65), it is determined that the Wi-Fi signal features support the target scene S.
[0100] Through the above technical solution, when the terminal device fails to match the Basic Service Set Identifier (SSID) in the Wi-Fi signal with the Standard Service Set Identifier (SSI) of the target scene, the system can further match the target service set identifier in the Wi-Fi signal with the SSI of the target scene. This introduction of SSID as a backup identification mechanism after BSSID matching failure effectively solves the problem of scene identification omissions that may occur if only BSSID is relied upon, especially when BSSID is unstable or unavailable.
[0101] In some embodiments, this application further proposes that the multi-source radio frequency signal also includes a Bluetooth signal; Determining whether a terminal device is located in the target scene based on the scene confidence levels corresponding to each of the multi-source radio frequency signals also includes: In response to the matching of the first Bluetooth beacon corresponding to the Bluetooth signal and the second Bluetooth beacon corresponding to the target scene, the distance between the terminal device and the second Bluetooth beacon is determined based on the second received signal strength of the Bluetooth signal and the standard Bluetooth signal strength of the target scene. Based on the interval distance, the scene confidence level corresponding to the Bluetooth signal is determined.
[0102] In this embodiment, Bluetooth signal is a short-range wireless communication technology widely used for device connection and positioning. It can be transmitted by devices such as Bluetooth beacons, which are usually deployed in specific areas and can periodically broadcast data packets containing their own identity information and / or service information.
[0103] The second received signal strength is the actual Bluetooth signal strength received by the terminal device. Standard Bluetooth signal strength usually refers to the Bluetooth signal strength measured at a specific distance (e.g., 1 meter).
[0104] Specifically, by scanning and receiving these Bluetooth signals, the terminal device can obtain data such as the identification information and signal strength of the Bluetooth beacon. When the terminal device receives a Bluetooth signal, it parses the identification information of the corresponding Bluetooth beacon, which is the first Bluetooth beacon. Simultaneously, the system pre-stores Bluetooth beacon identification information associated with a specific target scene, i.e., the second Bluetooth beacon. By comparing the first Bluetooth beacon received by the terminal device with the pre-set second Bluetooth beacon for the target scene, it can preliminarily determine whether the terminal device is within the coverage area of that target scene.
[0105] Based on this, this application determines the distance between the terminal device and the second Bluetooth beacon based on the second received signal strength of the Bluetooth signal and the standard Bluetooth signal strength of the target scenario. The Received Signal Strength Indication (RSSI) of the Bluetooth signal is inversely proportional to the distance between the transmitting and receiving devices. By comparing the actual received second received signal strength with the preset standard Bluetooth signal strength, and combining this with a signal attenuation model, the physical distance between the terminal device and the second Bluetooth beacon emitting the Bluetooth signal can be estimated.
[0106] Ultimately, this application determines the scene confidence level corresponding to the Bluetooth signal based on the interval distance. Once the interval distance between the terminal device and the second Bluetooth beacon is obtained, the scene confidence level of the terminal device being located in the target scene can be evaluated based on this distance. For example, the smaller the interval distance, the closer the terminal device is to the core area of the target scene, and the higher its scene confidence level; conversely, the larger the interval distance, the lower the scene confidence level.
[0107] In one possible implementation, low-power Bluetooth beacons (such as iBeacon or Eddystone) are deployed at key locations in the target scenario.
[0108] For example, in a convenience store scenario, Bluetooth beacons are deployed inside the store entrance and near the checkout counter. The data packets broadcast by the Bluetooth beacons contain information such as the chain brand's universally unique identifier (UUID), store number, and area identifier (entrance / checkout counter).
[0109] The terminal device enables Bluetooth Low Energy (BLE) scanning to obtain information about Bluetooth beacons (i.e., the first Bluetooth beacon), including a universally unique identifier / primary number / secondary number (used to identify the specific scene and location) and received signal strength (used to estimate the distance).
[0110] The interval distance can be estimated using the logarithmic distance path loss model: d = 10^((RSSI_ref - RSSI_meas) / (10·n)); Where d is the interval distance to be estimated; RSSI_ref is the reference signal strength (i.e., standard Bluetooth signal strength) measured at a known distance (usually 1 meter); RSSI_meas is the currently measured signal strength (i.e., the second received signal strength); and n is the environmental attenuation factor, used to reflect the attenuation rate of the signal in different environments (such as indoors and outdoors).
[0111] When the estimated distance d is less than 5 meters, it can be determined that the terminal device is close to the target scene; when d is less than 1 meter, it can be determined that the terminal device is at a very close distance; thus, the scene confidence level corresponding to the Bluetooth signal can be determined based on the inverse proportional relationship of the interval distance.
[0112] Furthermore, in terms of scene matching logic, the entry detection method is as follows: when a Bluetooth beacon signal (i.e., the second Bluetooth beacon) of the same target scene is received in a series of preset number of scans (e.g., 3 times, with an interval of about 2 seconds between each scan), and the estimated interval distance d is less than a preset distance threshold (e.g., 8 meters), it is determined that the terminal device has entered the target scene range.
[0113] The dwell detection method is as follows: if the Bluetooth beacon signal of the target scene is continuously received for a period of time exceeding a preset duration (e.g., 10 seconds), it is determined that the terminal device is inside the scene.
[0114] The exit detection method is as follows: if no Bluetooth beacon signal is received for a preset duration (e.g., 15 seconds), or if the received signal strength of all Bluetooth beacons is lower than a preset strength threshold (e.g., -90dBm, corresponding to a distance of more than 15 meters), it is determined that the terminal device has left the target scene.
[0115] By introducing Bluetooth signals into multi-source radio frequency signals and utilizing Bluetooth beacon matching and the relationship between signal strength and distance, this application can more accurately determine the actual distance between the terminal device and the target scene. This distance-based judgment method overcomes the potential accuracy problems of relying solely on signal matching or generalized signal strength judgment, and is particularly suitable for scenarios requiring fine positioning or close-range perception.
[0116] In some embodiments, this application further proposes determining whether the terminal device is located in a target scene based on multi-source radio frequency signals collected by the terminal device, including: Based on the satellite positioning information and / or base station positioning information of the terminal device, determine whether the terminal device is located in the preset geofence corresponding to the target scene; In response to the terminal device being located in a preset geofence, the system determines whether the terminal device is located in the target scene based on the multi-source radio frequency signals collected by the terminal device.
[0117] In this embodiment, the preset geofence is a virtual geographical boundary set around the target scene, which can be a polygonal area, a circular area, or a complex shape defined by a series of geographical coordinate points.
[0118] Specifically, when determining whether a terminal device is located in a target scenario, a preliminary geographical location assessment can be made using the terminal device's satellite positioning information and / or base station positioning information. Satellite positioning information is typically obtained through the terminal device's built-in Global Positioning System (GPS) module; base station positioning information is estimated by measuring parameters such as signal strength, time difference of arrival, or angle between the terminal device and nearby cellular base stations, combined with base station location information.
[0119] After obtaining its current location coordinates through its positioning module, the terminal device compares them with the boundaries of a preset geofence to determine whether it is inside that geofence. This preliminary judgment can quickly filter whether the terminal device is within the approximate geographical range of the target scene.
[0120] Only when a terminal device is initially determined to be within a preset geofence does the system further initiate a more refined judgment process based on multi-source radio frequency signals collected by the terminal device to determine whether the device is located within the target scene. Multi-source radio frequency signals can include Wi-Fi signals, Bluetooth signals, near-field communication (NFC) signals, etc. These signals can provide more detailed local environmental information than satellite / base station positioning, thereby achieving accurate identification of the target scene. For example, only after a terminal device enters the geofence of a large shopping mall will the system begin analyzing the Wi-Fi hotspot information and Bluetooth beacon signals it receives to determine whether it is located in a specific store or area within the mall.
[0121] In one possible implementation, regarding satellite positioning, the terminal device obtains its current location coordinates through the Global Positioning System (GPS) or the BeiDou Navigation Satellite System to determine whether the terminal device is located within a preset geofence corresponding to the target scene.
[0122] In terms of base station positioning, in indoor environments where satellite positioning signals are weak, the terminal device automatically switches to base station positioning (Cell ID positioning) as a supplement. By obtaining the number (Cell ID) and signal strength of the currently connected mobile communication base station, and combining it with the base station deployment location database, the area where the terminal device is located is roughly estimated, which is used to trigger or suppress subsequent fine sensing processes.
[0123] The positioning and screening in this application adopts a progressively refined strategy: Level 1 (coarse screening): Based on satellite positioning information and / or base station positioning information, determine whether the terminal device is located within the preset geofence of any preset scene; if not, end the scene determination process; if yes, proceed to Level 2.
[0124] Level 2 (Preliminary Scene Type Judgment): Based on the specific preset geofence type where the satellite positioning coordinates fall (e.g., convenience store point of interest (POI) fence), the target scene type is initially determined, and the corresponding Wi-Fi / Bluetooth / Near Field Communication scanning module is notified to start fine sensing.
[0125] By using the above-mentioned initial location screening, we can avoid terminal devices from performing Wi-Fi / Bluetooth / Near Field Communication scans at all times and in all locations, thereby reducing device power consumption.
[0126] The above technical solution determines whether a terminal device is located within a target scene by first using satellite positioning information and / or base station positioning information for preliminary geographical location assessment. This method can quickly and efficiently filter whether the terminal device is within a preset geofence of the target scene, avoiding unnecessary and continuous high-precision multi-source radio frequency signal acquisition and analysis when the terminal device is far from the target scene, thus significantly reducing the terminal device's computing resource consumption and power consumption. Only when the terminal device is initially determined to be within the geofence of the target scene is a more refined scene assessment based on multi-source radio frequency signals initiated, ensuring the accuracy and real-time nature of the scene assessment. This hierarchical assessment mechanism effectively solves the problem of balancing efficiency and accuracy in scene recognition over a wide geographical area.
[0127] In some embodiments, this application further proposes that S120 includes: In response to the terminal device's screen being on, an identification code corresponding to the target scene is displayed.
[0128] In this embodiment, the screen-on state of the terminal device refers to the terminal device's display screen being active and displaying content. This typically means that the user is using the device, or that the device has just been woken up.
[0129] Specifically, when a user wakes up the screen by touching the screen, pressing a physical button, or performing a raise-to-wake action, the device will enter a screen-on state.
[0130] Under this premise, the terminal device will display a pre-configured or real-time generated identification code associated with the current target scene on the screen. This identification code can be in various forms such as QR code, barcode, number string, and graphic code, and is used for user authentication, payment, information retrieval, and other operations.
[0131] The display method can be a pop-up window on the screen, full-screen display, or display in a specific area of the screen.
[0132] Through the above technical solution, after determining the intent to display the identification code, the terminal device further determines whether the screen is on. The identification code is only displayed when the screen is on. This conditional display mechanism ensures that the identification code is displayed only when the user can effectively receive the information, avoiding invalid display when the screen is off, thus significantly improving the effectiveness of the identification code display and the user experience. Simultaneously, using "screen on" as the sole trigger condition eliminates the need for clicking or swiping, achieving a zero-operation interaction experience of "pay upon screen on," greatly enhancing convenience.
[0133] It should be noted that the various embodiments described in this application can be combined with each other or implemented individually without conflict, and this application does not limit this.
[0134] For ease of understanding, a specific embodiment will be used as an example: like Figure 2 The diagram illustrates a process flow for displaying a scene-aware intelligent identification code. The complete implementation process of this scene-aware intelligent identification code display can be divided into three stages: scene perception determination, intent determination and display, and scene departure closure.
[0135] The first stage is scene perception and determination (S201 to S205): After the process starts, step S201 is executed first to determine whether the terminal device is located within the preset geofence corresponding to the target scene; if not, the determination is repeated through S201; if yes, the process proceeds to step S202 to perform multi-source radio frequency signal acquisition. After acquisition, the process proceeds to step S203 to determine whether a valid scene identifier is read from the near-field communication signal; if a valid scene identifier is read, the confidence calculation is skipped and the process proceeds to step S206; if not, the process proceeds to step S204 to perform total scene confidence calculation. After calculation, the process proceeds to step S205 to determine whether the total scene confidence is greater than the scene trigger threshold and less than the scene exit threshold: if it is greater than the scene trigger threshold, the process proceeds to step S206; if it is less than the scene exit threshold, the process returns to step S201 to re-perform the preset geofence determination; if it is between the two, the process returns to step S204 to continue calculating the total scene confidence.
[0136] The second stage is intent determination and identification code display (S206 to S210): After confirming that the terminal device is located in the target scene, step S206 is entered to collect behavioral intent parameters, followed by step S207 to determine whether the terminal device has the intent to display the identification code; if not, the behavioral intent parameters are collected again in step S206; if so, the identification code is read in step S208. After reading, step S209 is entered to determine whether the terminal device is in a screen-on state; if the screen is not on, step S209 continues to determine whether it is in a screen-on state; if the screen is on, the identification code is displayed in step S210.
[0137] The third stage is the scenario departure and process closure (S211 to S212): After the identification code is displayed, step S211 is entered to determine whether the terminal device has left the target scenario; if it has not left, step S211 is continued to determine whether the terminal device has left the target scenario; if it has left, step S212 is entered to store the payment method and information source information in the local database, and then step S201 is returned to restart the next round of scenario perception and judgment process, thus forming a complete closed loop.
[0138] This application also provides an electronic device, such as... Figure 3 As shown, the electronic device 300 includes: One or more processors 310; The memory 320 stores one or more programs that, when executed by one or more processors 310, enable the one or more processors 310 to implement the identification code display method described in any of the above embodiments.
[0139] Memory 320, as a non-transitory network system, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory 320 may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory 320 may optionally include remotely located memories 320 relative to processor 310, which can be connected to processor 310 via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
[0140] The memory 320 can be implemented as a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 320 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 320 and is called and executed by the processor 310.
[0141] The processor 310 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this application.
[0142] In some embodiments, the electronic device further includes: Input / output interfaces are used to implement information input and output; The communication interface is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, Wi-Fi, Bluetooth, etc.). A bus transmits information between various components of a device, such as processor 310, memory 320, input / output interfaces, and communication interfaces. The processor 310, memory 320, input / output interface, and communication interface can communicate with each other within the device via a bus.
[0143] One embodiment of this application also provides a computer-readable storage medium storing computer-executable instructions for performing the identification code display method as provided in any embodiment of this application.
[0144] An embodiment of this application also provides a computer program product, including a computer program or computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer program or computer instructions from the computer-readable storage medium and executes the computer program or computer instructions, causing the computer device to perform the identification code display method provided in any embodiment of this application.
[0145] The system architecture and application scenarios described in this application are intended to more clearly illustrate the technical solutions of this application and do not constitute a limitation on the technical solutions provided in this application. Those skilled in the art will understand that as system architectures evolve and new application scenarios emerge, the technical solutions provided in this application are also applicable to similar technical problems.
[0146] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.
[0147] In hardware implementations, the division between functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed collaboratively by several physical components. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include computer storage media (or non-transitory media) and communication media (or transient media). As is known to those skilled in the art, the term computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disc (DVD) or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and is accessible to a computer. Furthermore, as is known to those skilled in the art, communication media typically contain computer-readable instructions, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and may include any information delivery medium.
[0148] As used in this specification, the terms "component," "module," "system," etc., are used to refer to computer-related entities, hardware, firmware, combinations of hardware and software, software, or software in execution. For example, a component can be, but is not limited to, a process running on a processor, a processor, an object, an executable file, an execution thread, a program, or a computer. As illustrated, applications running on computing devices and computing devices can both be components. One or more components may reside in a process or execution thread, and components may be located on a single computer or distributed among two or more computers. Furthermore, these components can be executed from various computer-readable media on which various data structures are stored. Components can communicate, for example, via local or remote processes based on signals having one or more data packets (e.g., data from two components interacting with another component between a local system, a distributed system, or a network, such as the Internet interacting with other systems via signals).
[0149] The above description, with reference to the accompanying drawings, illustrates some embodiments of this application, but does not limit the scope of this application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and spirit of this application shall be within the scope of this application.
Claims
1. A method for displaying an identification code, comprising: In response to the terminal device being located in a target scenario where there is a need to display an identification code, the behavioral intent parameters of the terminal device in the target scenario are obtained; The behavioral intent parameter is used to characterize the tendency of the terminal device to display the identification code in the target scenario; In response to determining, based on the behavioral intent parameters, that the terminal device has the intent to display the identification code, the identification code corresponding to the target scenario is displayed.
2. The method according to claim 1, characterized in that, The behavioral intent parameter includes at least one of the following: Target movement speed; Target dwell time; Target signal strength; the target signal strength is used to characterize the strength of the wireless signal received by the terminal device that reflects the target scene.
3. The method according to claim 2, characterized in that, The terminal device must satisfy at least one of the following conditions to have the intention to display the identification code: The target's moving speed is less than or equal to a preset speed threshold; The target dwell time is greater than or equal to a preset duration threshold; The target signal strength meets the signal strength condition; the signal strength condition is used to determine whether the terminal device is within the effective signal coverage range of the target scene.
4. The method according to claim 1, characterized in that, Before obtaining the behavioral intent parameters of the terminal device in the target scenario in response to the terminal device being located in a target scenario where there is a need to display an identification code, the method further includes: Based on the multi-source radio frequency signals collected by the terminal device, it is determined whether the terminal device is located in the target scene; The multi-source radio frequency signal is a signal originating from different radio frequency emission sources, used to sense the scene environment in which the terminal device is located.
5. The method according to claim 4, characterized in that, The multi-source radio frequency signals include near-field communication signals; The step of determining whether the terminal device is located in the target scene based on the multi-source radio frequency signals collected by the terminal device includes: In response to reading a valid scene identifier from the near-field communication signal, it is determined that the terminal device is located in the target scene; the valid scene identifier is identity information that matches the target scene; In response to the failure to read a valid scene identifier from the near-field communication signal, the system determines whether the terminal device is located in the target scene based on the scene confidence scores corresponding to each of the multi-source radio frequency signals; the scene confidence scores are used to characterize the probability that the terminal device indicated by the radio frequency signals is located in the target scene.
6. The method according to claim 5, characterized in that, The multi-source radio frequency signal also includes a Wi-Fi signal; The step of determining whether the terminal device is located in front of the target scene based on the scene confidence scores corresponding to the multi-source radio frequency signals further includes: The target basic service set identifier in the Wi-Fi signal is matched with the standard basic service set identifier of the target scenario to obtain a first matching result; In response to the first matching result indicating a successful match, the scene confidence level corresponding to the Wi-Fi signal is determined based on the first received signal strength of the Wi-Fi signal and the standard Wi-Fi signal strength range of the target scene.
7. The method according to claim 6, characterized in that, After matching the target basic service set identifier in the Wi-Fi signal with the standard basic service set identifier of the target scenario to obtain a first matching result, the method further includes: In response to the first matching result indicating a matching failure, the target service set identifier in the Wi-Fi signal is matched with the standard service set identifier of the target scenario to obtain a second matching result; In response to the second matching result indicating a successful match, the scene confidence level corresponding to the Wi-Fi signal is determined based on the first received signal strength of the Wi-Fi signal and the standard Wi-Fi signal strength range of the target scene.
8. The method according to claim 5, characterized in that, The multi-source radio frequency signal also includes a Bluetooth signal; The step of determining whether the terminal device is located in front of the target scene based on the scene confidence scores corresponding to the multi-source radio frequency signals further includes: In response to the first Bluetooth beacon corresponding to the Bluetooth signal matching with the second Bluetooth beacon corresponding to the target scene, the distance between the terminal device and the second Bluetooth beacon is determined based on the second received signal strength of the Bluetooth signal and the standard Bluetooth signal strength of the target scene; Based on the interval distance, the scene confidence level corresponding to the Bluetooth signal is determined.
9. The method according to claim 4, characterized in that, The step of determining whether the terminal device is located in the target scene based on the multi-source radio frequency signals collected by the terminal device includes: Based on the satellite positioning information and / or base station positioning information of the terminal device, determine whether the terminal device is located in the preset geofence corresponding to the target scene; In response to the terminal device being located within the preset geofence, the system determines whether the terminal device is located within the target scene based on the multi-source radio frequency signals collected by the terminal device.
10. The method according to claim 1, characterized in that, The displayed identification code corresponding to the target scene includes: In response to the terminal device's screen being on, an identification code corresponding to the target scene is displayed.
11. An electronic device, comprising: At least one processor; At least one memory for storing at least one program; The identification code display method according to any one of claims 1 to 10 is implemented when at least one of the programs is executed by at least one of the processors.
12. A computer-readable storage medium storing computer-executable instructions for performing the identification code display method according to any one of claims 1 to 10.
13. A computer program product comprising a computer program, which, when executed by a processor, implements, as follows: The identification code display method according to any one of claims 1 to 10.
