Scene identification generation method, electronic device, and readable storage medium
Patent Information
- Application Number
- CN202610968688.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-30
- Publication Date
- 2026-09-29
AI Technical Summary
然而,目前主流智能家居平台在场景的复用与分享方面存在较多不方便,尤其是智能家居设备的场景分享方式十分繁琐,例如,用户若想将自创的优质场景配置参数推荐给好友,只能通过文字描述、截图或录屏的方式告知对方,而接收方需手动逐条添加条件与动作,操作繁琐且容易遗漏,导致智能家居设备场景配置数据的分享效率较为低下
[0022]本申请提供了一种场景标识生成方法,所述场景标识生成方法包括:响应于触发标识生成条件,基于所述标识生成条件对应的场景ID,生成第一配置参数对应的第一场景标识,其中,所述第一配置参数至少包括一种家居设备对应的场景条件和场景动作;建立所述第一配置参数与所述第一场景标识之间的映射关系,并存储所述映射关系,其中,所述映射关系用于供用户根据分享的所述第一场景标识应用所述第一配置参数至家居设备管理应用。如此,本申请技术方案实现了将场景配置参数转换成简短易分享的场景标识,用户可以口头告知、短信发送或社交软件传播,显著降低场景配置分享门槛,被分享者可以根据场景标识和家居设备管理应用确定对应的配置参数,实现高效的场景配置参数复用,从而有效提高了场景配置的分享效率。
Smart Images

Figure CN122840089A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of smart home, and in particular, to a scenario identifier generation method, an electronic device and a computer-readable storage medium. Background Art
[0002] With the rapid development of the Internet of Things technology, smart home devices have been widely used in families. Scenario-based configuration applications are also becoming more and more extensive. Users can customise corresponding scenario modes (such as away mode, home mode, viewing mode, etc.) through mobile phone applications, and realize linkage control of multiple devices. However, current mainstream smart home platforms have many inconveniences in scenario reuse and sharing, especially the scenario sharing method for smart home devices is very cumbersome. For example, if a user wants to recommend self-created high-quality scenario configuration parameters to friends, the user can only inform the other party by means of text description, screenshot or screen recording, and the receiver needs to manually add conditions and actions one by one, which is cumbersome and easy to miss, resulting in relatively low sharing efficiency of scenario configuration data of smart home devices.
[0003] The above information disclosed in this Background section is only for understanding the background of the inventive concept of the present application, and therefore, it may contain information that does not constitute prior art. Summary of the Invention
[0004] The main purpose of the present application is to provide a scenario identifier generation method, an electronic device and a computer-readable storage medium, aiming to improve the sharing efficiency of scenario configuration data of smart home devices.
[0005] To achieve the above objective, the present application provides a scenario identifier generation method applied to a server, the scenario identifier generation method comprising: In response to triggering an identifier generation condition, generate a first scenario identifier corresponding to first configuration parameters based on a scenario ID corresponding to the identifier generation condition, wherein the first configuration parameters include at least scenario conditions and scenario actions corresponding to one home device; Establishing a mapping relationship between the first configuration parameters and the first scenario identifier, and storing the mapping relationship, wherein the mapping relationship is for a user to apply the first configuration parameters to a home device management application according to the shared first scenario identifier.
[0006] In an embodiment, the first scenario identifier includes a first scenario password, the identifier generation condition includes receiving a password generation request, and the step of generating a first scenario identifier corresponding to first configuration parameters based on a scenario ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to receiving a password generation request, the password generation request carries a scenario ID corresponding to the first configuration parameters; A string of a preset length is generated based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID.
[0007] In one embodiment, after the step of generating a string of a preset length based on a preset combination of numbers and letters to obtain a first scene password corresponding to the scene ID, the method further includes: In response to receiving a link generation request, the link generation request carries the scene ID corresponding to the first configuration parameter; The first scene password is embedded into a preset link template to generate the first scene link corresponding to the scene ID.
[0008] In one embodiment, after the step of embedding the first scene password into a preset link template to generate the first scene link corresponding to the scene ID, the method further includes: In response to receiving a QR code generation request, the QR code generation request carries the scene ID corresponding to the first configuration parameter; Encode the first scene password and / or the first scene link to generate a first scene QR code corresponding to the scene ID.
[0009] In one embodiment, the first scene identifier includes a first scene password, the identifier generation condition includes a first configuration parameter pre-generated to the scene recommendation page, and the step of generating a first scene identifier corresponding to the first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to the first configuration parameter being pre-generated on the scene recommendation page, a string of a preset length is generated based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID of the first configuration parameter.
[0010] In one embodiment, prior to the step of generating a string of a preset length based on a preset combination of numbers and letters, the method further includes: Check if the scene ID corresponding to the first configuration parameter exists in the stored mapping relationship; If it exists, the second configuration parameter corresponding to the scene ID in the mapping relationship is updated to the first configuration parameter.
[0011] After the step of querying whether the scene ID corresponding to the first configuration parameter exists in the stored mapping relationship, the method further includes: If the scene ID corresponding to the first configuration parameter does not exist in the stored mapping relationship, then return to the step of generating a string of a preset length based on a preset combination of numbers and letters.
[0012] In one embodiment, after the step of generating a string of a preset length based on a preset combination of numbers and letters to obtain a first scene password corresponding to the scene ID, the method further includes: In response to the scenario recommendation page receiving a save instruction for the first configuration parameter, the first user scenario corresponding to the first configuration parameter is obtained; In response to the user scenario page receiving a password generation instruction for the first user scenario, a string of a preset length is generated based on a preset combination of numbers and letters to obtain a second scenario password corresponding to the first configuration parameter, wherein the second scenario password is different from the first scenario password.
[0013] In one embodiment, after the step of establishing the mapping relationship between the first configuration parameter and the first scene identifier, and storing the mapping relationship, the method further includes: In response to an update to the first configuration parameter, the first configuration parameter is updated to the third configuration parameter in the mapping relationship; Upon receiving the first scene identifier, the third configuration parameter is returned; In response to receiving a cancellation command for the first scene identifier, the first scene identifier and the configuration parameters corresponding to the first scene identifier are deleted from the mapping relationship, and the first scene identifier is released.
[0014] In one embodiment, the first scene identifier includes a first scene link, and the identifier generation condition includes receiving a link generation request. The step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to receiving a link generation request sent by a mobile terminal, the link generation request carries a scenario ID corresponding to the first configuration parameter; The scene ID is embedded into a preset link template to generate the first scene link corresponding to the scene ID.
[0015] In one embodiment, after the step of embedding the scene ID into a preset link template and generating a first scene link corresponding to the scene ID, the method further includes: In response to receiving a QR code generation request, the QR code generation request carries the scene ID corresponding to the first configuration parameter; The first scene link is encoded to generate a first scene QR code corresponding to the scene ID.
[0016] In one embodiment, the first scene identifier includes a first scene QR code, and the identifier generation condition includes receiving a QR code generation request. The step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to receiving a QR code generation request sent by a mobile terminal, the QR code generation request carries a scene ID corresponding to the first configuration parameter; The scene ID is encoded to generate a first scene QR code corresponding to the scene ID.
[0017] In one embodiment, the identifier generation condition includes receiving an identifier generation request, and the scene identifier generation method includes: In response to the home management application on the mobile terminal receiving the identifier generation instruction, the scene ID corresponding to the first configuration parameter pointed to by the identifier generation instruction is obtained; The scene ID is embedded in a preset identifier generation request, and the identifier generation request is sent to the server through the mobile terminal so that the server can trigger the identifier generation conditions to generate the corresponding first scene identifier and establish a mapping relationship between the first configuration parameter and the first scene identifier.
[0018] In one embodiment, the identifier generation condition includes receiving an identifier generation request, and the scene identifier generation method includes: In response to the server receiving an identifier generation request sent by the mobile terminal, the server generates a first scene identifier corresponding to the scene ID based on the scene ID corresponding to the identifier generation request. The server returns the first scene identifier to the mobile device so that the mobile device can share the first scene identifier with the target user.
[0019] In addition, to achieve the above objectives, this application also provides an electronic device, which includes at least: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the scene identifier generation method applied to the electronic device as described above.
[0020] In addition, to achieve the above objectives, this application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the scene identifier generation method described above.
[0021] In addition, to achieve the above objectives, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the scene identifier generation method described above.
[0022] This application provides a method for generating scene identifiers. The method includes: responding to a triggered identifier generation condition, generating a first scene identifier corresponding to a first configuration parameter based on a scene ID corresponding to the identifier generation condition, wherein the first configuration parameter includes at least a scene condition and a scene action corresponding to a home appliance; establishing a mapping relationship between the first configuration parameter and the first scene identifier, and storing the mapping relationship, wherein the mapping relationship is used for users to apply the first configuration parameter to a home appliance management application based on the shared first scene identifier. Thus, this application's technical solution converts scene configuration parameters into concise and easily shareable scene identifiers. Users can verbally inform, send text messages, or spread them through social media, significantly reducing the barrier to sharing scene configurations. The recipient can determine the corresponding configuration parameters based on the scene identifier and the home appliance management application, achieving efficient reuse of scene configuration parameters and effectively improving the sharing efficiency of scene configurations. Attached Figure Description
[0023] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0024] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0025] Figure 1 This is a flowchart illustrating the scene identifier generation method applied to the server in this application embodiment; Figure 2 A sequence diagram of a feasible scenario for generating a password based on a user's identifier in an embodiment of this application; Figure 3 This is a timing diagram of a feasible pre-generated scenario password in an embodiment of this application; Figure 4 This is a flowchart illustrating a feasible scenario identifier generation and management process in this application embodiment; Figure 5 This is a schematic diagram illustrating the interaction process between the mobile terminal and the server during the scene identifier generation process in this application embodiment; Figure 6 This is a schematic diagram of a feasible mobile terminal and server-side business process in the scenario configuration sharing process in this application embodiment; Figure 7 This is a schematic diagram of a feasible mobile and server-side business process in the process of adding scene identifiers in the embodiments of this application; Figure 8 This is a schematic diagram of the device structure of the hardware operating environment involved in the scene identifier generation method in this application embodiment.
[0026] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0027] To make the above-mentioned objectives, features, and advantages of this application more apparent and understandable, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of this application, and not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.
[0028] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.
[0029] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.
[0030] To improve the efficiency of sharing scene configuration data of smart home devices, this application provides a method for generating scene identifiers, referring to... Figure 1 , Figure 1 This is a flowchart illustrating an embodiment of the scene identifier generation method of this application. The scene identifier generation method includes: Step S10: In response to triggering the identifier generation condition, generate a first scene identifier corresponding to the first configuration parameter based on the scene ID corresponding to the identifier generation condition. The first configuration parameter includes at least one scene condition and scene action corresponding to a home device. The conditions for generating scene identifiers (passwords, links, or QR codes) are pre-set and can include two methods: pre-generation and real-time generation. Pre-generation means that operators pre-set multiple applicable family scenes and configure corresponding scene configuration parameters through statistics and organization, allowing users to choose or share them. In this case, after the scene is established and recommendations begin, a scene identifier is generated for each scene. Each scene corresponds to a scene ID (identity), so there is a fixed binding relationship between the scene ID and the scene identifier, which remains unchanged during the scene's validity period until the scene expires. Real-time generation refers to generating corresponding scene identifiers in response to user needs for sharing scenes. When a user needs to share a scene they have set or saved with friends, the server generates a corresponding unique scene identifier for that scene, facilitating convenient and quick sharing of scene configurations through various methods and achieving efficient scene configuration reuse.
[0031] Taking scene passwords as an example, in the process of generating the first scene password corresponding to the first configuration parameter based on preset numbers and letters, a random generation method can be adopted, that is, letters and numbers are randomly combined to form a string of fixed length as the first scene password, and the uniqueness of the scene password corresponding to each set of first configuration parameters is guaranteed, that is, each scene password corresponds to only one set of scene configuration parameters, and each set of scene configuration parameters also has only one corresponding scene password.
[0032] Home appliances can include various smart home devices, such as air conditioners, televisions, lights, robot vacuums, curtains, and water heaters. Scene conditions refer to the conditions that trigger scene actions, such as a person leaving, a person approaching, a preset time point, or receiving a scene switching command. Scene actions refer to actions that control home appliances, such as turning them on or off, adjusting settings, and adjusting power.
[0033] Step S20: Establish a mapping relationship between the first configuration parameter and the first scene identifier, and store the mapping relationship. The mapping relationship is used for users to apply the first configuration parameter to the home device management application based on the shared first scene identifier.
[0034] In order to associate and bind the first configuration parameter and the first scene identifier, it is necessary to establish and store the mapping relationship between the first configuration parameter and the first scene identifier so that the first scene identifier (the sharing scene corresponding to the scene identifier) can be quickly determined according to the first configuration parameter in subsequent applications, or the first configuration parameter (the adding scene corresponding to the scene identifier) can be determined according to the first scene identifier.
[0035] It should be noted that in the actual storage of mapping relationships, the scene ID is usually associated with the first scene identifier and the first configuration parameter. If the first configuration parameter changes, the scene ID is associated with the updated first configuration parameter, but the scene ID itself remains unchanged.
[0036] Further, in a feasible embodiment, the first scene identifier includes a first scene password, and the identifier generation condition includes receiving an identifier generation request. The step S10, in response to triggering the identifier generation condition, generating the first scene identifier corresponding to the first configuration parameter based on the scene ID corresponding to the identifier generation condition, may include: Step S11: In response to receiving an identifier generation request sent by the mobile terminal, the identifier generation request carries the scene ID corresponding to the first configuration parameter; Step S12: Generate a string of a preset length based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID.
[0037] This application provides a method for generating a first scene password in real time. The identifier generation request sent by the mobile terminal is an identifier generation request input by the user through a home device management application on the mobile terminal, and is for sharing scenes set or saved by the user. For example, when a user clicks the share button for a scene (corresponding to a scene ID) on the user scene page of the home device management application, the mobile terminal will generate a corresponding identifier generation request based on the scene ID and send it to the server. The server will then generate a string of a preset length (e.g., 6 characters) based on a preset combination of numbers and letters to obtain the first scene password corresponding to the first configuration parameters.
[0038] For example, the scene password consists of 6 characters, each character is selected from numbers (0-9) and uppercase English letters (AZ), for a total of 36 possibilities, and the total number of combinations is 36. 6 ≈ 2.17 billion, which is enough to guarantee the global uniqueness of the password (password examples: A3B9K7, 8X2P0L).
[0039] In one feasible embodiment, an available string can be randomly selected from a pre-established string library and bound to the scene ID. Here, "available" means that it has not been bound to any other scene ID. Alternatively, a pre-defined string corresponding to preset numbers and letters can be randomly combined in real time, but it is necessary to ensure that the string is in an available state.
[0040] In another feasible embodiment, if the user has already pre-generated a first scene password corresponding to the scene ID of the first configuration parameter, then after the user enters the scene sharing command on the mobile terminal, the server directly queries the first scene password corresponding to the scene ID from the stored mapping relationship and returns it to the mobile terminal.
[0041] For ease of understanding, please refer to Figure 2 The diagram illustrates a sequence of events for generating a scene password based on a user's identifier. When user A (the sharer) clicks the "Share Scene" button on App A (the mobile device), they request a password (carrying the scene ID) from the scene management server (the server). The scene management server first checks its database to see if a password already exists for the scene. If a password already exists, it returns the existing password; otherwise, it generates a unique 6-digit password (numbers + uppercase letters) and stores the password mapping (including scene ID, password, status + valid). After successful storage, it returns the password (e.g., "X9Y8Z7") to App A, which then displays the password for the user to copy and share.
[0042] In this embodiment, the password is generated only when the mobile user actively initiates the sharing of the scene, so as to achieve on-demand generation and avoid the use of password resources for unshared scenes.
[0043] In one feasible embodiment, after the step of generating a string of a preset length based on a preset combination of numbers and letters to obtain a first scene password corresponding to the scene ID, the method may further include: Step A10: In response to receiving a link generation request, the link generation request carries the scene ID corresponding to the first configuration parameter; Step A20: Embed the first scene password into the preset link template to generate the first scene link corresponding to the scene ID.
[0044] Building upon the generated initial scene password, to enrich the display format of scene identifiers, a corresponding initial scene link can be generated based on the initial scene password, enabling sharing via a link. Specifically, the scene password for the current scene can be embedded into a pre-configured link template to obtain the initial scene link corresponding to the scene ID.
[0045] Furthermore, in a feasible embodiment, after the step of embedding the first scene password into a preset link template and generating the first scene link corresponding to the scene ID, the method may further include: Step A30: In response to receiving a QR code generation request, the QR code generation request carries the scene ID corresponding to the first configuration parameter; Step A40: Encode the first scene password and / or the first scene link to generate the first scene QR code corresponding to the scene ID.
[0046] Based on the already generated first scene password and first scene link, in order to further enrich the display form of scene identifiers, the first scene password and / or first scene link can be further encoded to generate a first scene QR code. The first scene QR code can be easily shared by users with others online or offline. Users who receive the shared first scene QR code can obtain the corresponding first scene password, first scene link and / or first configuration parameters by scanning it.
[0047] In another feasible embodiment, the first scene identifier includes a first scene password, and the identifier generation condition includes a first configuration parameter pre-generated to the scene recommendation page. The step of generating the first scene identifier corresponding to the first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition may further include: Step S13: In response to the first configuration parameter being pre-generated to the scene recommendation page, a string of a preset length is generated based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID of the first configuration parameter.
[0048] The password pre-generation method in this application embodiment is applicable to recommended scenarios. The first configuration parameters and the corresponding scenario ID set by the operators will be listed on the scenario recommendation page for users to choose from. In this case, when the first configuration parameters and their scenario ID are listed, the identifier generation condition is triggered, and the corresponding first scenario password is generated for the scenario ID.
[0049] In another feasible embodiment, when the user generates the first configuration parameters with the help of an AI (Artificial Intelligence) assistant or agent, the first configuration parameters and their scene ID are published to the scene recommendation page to be pushed to the user, and the corresponding first scene password is generated simultaneously. The functions of the AI assistant include responding to the user's scene creation needs and automatically generating configuration parameters and scenes that are adapted to the user's habits based on the user's historical control logs of home devices, which is equivalent to automatically generating recommended scenes.
[0050] Before the step of generating a string of a preset length based on a preset combination of numbers and letters, the method further includes: Step A10: Query whether the scene ID corresponding to the first configuration parameter exists in the stored mapping relationship; Step A20: If it exists, update the second configuration parameter corresponding to the scene ID in the mapping relationship to the first configuration parameter; If step A30 does not exist, then execute the step of generating a string of a preset length based on a preset combination of numbers and letters; Step A40: If the scene ID corresponding to the first configuration parameter does not exist in the stored mapping relationship, return to step S12: Generate a string of a preset length based on the preset combination of numbers and letters.
[0051] The second configuration parameter is the original configuration parameter corresponding to the scene ID, and the first configuration parameter is the latest configuration parameter corresponding to the scene ID, which is used to replace the position of the second configuration parameter in the mapping relationship.
[0052] Specifically, if the scenario ID corresponding to the currently released configuration parameters has already generated a first scenario password, then the first scenario password corresponding to the scenario ID can be directly retrieved from the mapping relationship. In this case, the scenario is where the first configuration parameter is the updated configuration parameter. This is suitable for continuously upgrading and updating the configuration parameters of the scenario ID after the initial generation of the scenario ID, thereby improving the user experience and the personalization of the scenario.
[0053] For ease of understanding, please refer to Figure 3 This diagram illustrates a sequence diagram for generating scene passwords based on user identifiers. After the operations / backend uploads / publishes scene configurations (recommendation / AI / Agent) on the scene management server, the scene management server verifies the scene content and queries the database to see if a password for that scene already exists. If not, it generates a unique 6-digit password (numbers + uppercase letters) and stores the password mapping (scene ID, password, status + valid). Upon successful storage, it returns the password (e.g., "A3B9K7"). In this way, the combination of six numbers and uppercase letters can form 2.17 billion different strings. Combined with server-side uniqueness verification, this effectively prevents malicious enumeration.
[0054] Furthermore, in a feasible embodiment, after the step of generating a string of a preset length based on a preset combination of numbers and letters to obtain a first scene password corresponding to the scene ID, the method may further include: Step S30: In response to the scene recommendation page receiving a save instruction for the first configuration parameter, the first user scene corresponding to the first configuration parameter is obtained; Step S40: In response to the user scenario page receiving a password generation instruction for the first user scenario, a string of a preset length is generated based on a preset combination of numbers and letters to obtain a second scenario password corresponding to the first configuration parameter, wherein the second scenario password is different from the first scenario password.
[0055] Understandably, the scenario recommendation page of the mobile home device management application displays information such as the first configuration parameter, scenario ID, and scenario name. After browsing the scenario, the user clicks the save command, and the first configuration parameter is saved as the first user scenario corresponding to that user. The first user scenario is a scenario exclusive to that user, and the user can modify it according to the actual situation.
[0056] Furthermore, users can browse their saved scenarios on the user scenario page and choose to share the first user scenario. Regardless of whether the configuration parameters corresponding to the first user scenario have been modified from the first configuration parameters, a new second scenario password will be generated, which is different from the original first scenario password. This distinguishes between application-recommended scenarios and user-personalized scenarios, making scenario sharing traceable. In this way, users can also cancel the second scenario password according to the actual situation (it will be displayed as invalid when other users use the second scenario password), but the first scenario password can still be used, maintaining the independence of scenario password sharing.
[0057] For example, user D sees the recommended scenario "Energy Saving Mode" (password A1B2C3) and saves it to their scenario library. This scenario copy then becomes user D's personal scenario. User D clicks share, and the server generates a new user scenario password X9Y8Z7 (different from the original recommended scenario password). Friend E accesses the scenario copy saved by user D via X9Y8Z7 (which may differ slightly from the original recommended scenario, for example, D may have adjusted the parameters). Other users can still access the official version using the original recommended password A1B2C3.
[0058] Furthermore, in a feasible embodiment, after the step of establishing the mapping relationship between the first configuration parameter and the first scene identifier, and storing the mapping relationship, the method may further include: Step S50: In response to the existence of an update to the first configuration parameter, the first configuration parameter is updated to the third configuration parameter in the mapping relationship; Step S60: In response to receiving the first scene identifier sent by the mobile terminal, the third configuration parameter is returned to the mobile terminal; This application provides a scenario identifier generation strategy when updating the first configuration parameter. Specifically, after the first configuration parameter is determined, the first configuration parameter, the first scenario identifier, the scenario ID, the scenario name, and other information are all associated and stored in a mapping relationship. Subsequently, operators or users can update, modify, or optimize the first configuration parameter of the scenario. After the first configuration parameter is updated to the third configuration parameter, the first configuration parameter is synchronously updated to the third configuration parameter in the mapping relationship stored on the server. This is equivalent to changing the scenario ID from pointing to the first configuration parameter to pointing to the third configuration parameter, while keeping the scenario identifier unchanged.
[0059] When a user adds a scene using the first scene identifier, the server responds to the first scene identifier by returning the updated third configuration parameters to the mobile device. This ensures that the scene identifier always points to the scene ID, and the original scene identifier automatically points to the latest content after the scene configuration parameters are updated, without the need to regenerate the scene identifier. This avoids the scene identifier becoming invalid and thus affecting the scene sharing efficiency.
[0060] For example, taking a scene password as an example, in a scenario where a password is pre-generated, a feasible scene password generation and application process may include: A home appliance management application launches a "Home Mode" recommended scene; operators set the scene's configuration parameters in the backend (conditions: door lock open; actions: turn on lights, turn on air conditioning). The server assigns a unique 6-digit password B8X2P0 to this scene and stores it in a database mapping table. User A sees this scene in the app's recommended list and can directly jump to the scene details page and activate it by entering B8X2P0. Two months later, the operators optimize the scene content (adding the action of opening curtains). User A accesses it again using the original password B8X2P0, applying the latest configuration, without needing to re-share.
[0061] For example, in a scenario where a password is generated in response to a user request, a feasible scenario identifier generation and application process may include: User B creates a custom scenario "Goodnight Mode," clicks "Share to Generate Password," and if the server detects that the scenario has not yet been assigned a password, it randomly selects an unused 6-character string K9M3N1 from the available character combinations, binds it to the scenario ID, and returns it. User B sends the password to friend C, who can then preview and enable it after entering it. If User B subsequently modifies the scenario's configuration parameters (e.g., adds a "turn off TV" action), the original password K9M3N1 remains valid, and C's next access will apply the latest configuration parameters.
[0062] Step S70: In response to receiving a cancellation instruction for the first scene identifier, delete the first scene identifier and the configuration parameters corresponding to the first scene identifier from the mapping relationship, and release the first scene identifier.
[0063] On the other hand, after sharing a scene through the first scene identifier, users can choose to cancel the sharing of the first scene identifier according to their actual situation (specifically, this is done in the home device management application). After receiving the cancellation instruction for the first scene identifier, the server deletes the first scene identifier, the configuration parameters corresponding to the first scene identifier, the scene ID, the scene name, and other related information from the mapping relationship stored in the database. Finally, the first scene identifier is released, which means that the first scene identifier is restored to a usable state (for example, the scene password can be bound to other configuration parameters), and can be bound or associated with other configuration parameters in the future.
[0064] In another feasible embodiment, when the scene ID in the scene recommendation page is removed by the operator, the same operations are performed, such as deleting the first scene identifier, the configuration parameters corresponding to the first scene identifier, the scene ID, the scene name and other relevant information in the mapping relationship stored in the database, and releasing the first scene identifier.
[0065] It should be noted that if the first scene identifier has been canceled and is not bound to any other scene ID or configuration parameters, and a user attempts to add a scene using the first scene identifier, a message will appear indicating that the identifier is invalid. This allows the user to understand that the scene has been canceled from sharing or removed from the platform. The logic is simple, clear, and easy to understand. The feature ensures that the scene becomes inaccessible immediately after the scene identifier expires, guaranteeing control and security over scene configuration parameters.
[0066] For ease of understanding, the approach to scene identifier generation in the aforementioned application embodiments can be based on... Figure 4 To understand this, taking a 6-digit password as an example, first determine the scenario type. If the scenario is pre-generated or generated in real time, directly generate a 6-digit password. If the scenario content is updated or the scenario becomes invalid, then execute the steps of updating the scenario content or marking it as invalid.
[0067] For example, a recommended scenario called "Good Morning Mode" was removed from the platform due to a data error, and the system marked its password F4G5H6 as invalid. Afterwards, any user accessing this scenario with the password will receive the message "Scenario removed." User B deleted their own created "Good Night Mode" scenario, and their password K9M3N1 became invalid. If friend C had previously saved the password shared by user B, accessing it again will result in the message "Scenario deleted by the author."
[0068] In another feasible embodiment, the first scene identifier includes a first scene link, the identifier generation condition includes receiving a link generation request, and the step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition may include: Step B10: In response to receiving a link generation request sent by the mobile terminal, the link generation request carries the scene ID corresponding to the first configuration parameter; Step B20: Embed the scene ID into the preset link template to generate the first scene link corresponding to the scene ID.
[0069] This application also provides a scheme for directly generating scene links based on scene IDs for scene sharing. Specifically, the scene ID is embedded into a preset URL (uniform resource locator) to generate a corresponding first scene link. When a user enters a scene sharing command in a mobile home appliance management application, the user can copy the first scene link for quick and convenient sharing. Specifically, the server concatenates the scene ID of the current scene into a URL format, which the user can copy to the clipboard on their mobile device. The user can then send the link to friends via any text channel such as third-party communication applications, SMS, email, or social media platforms. If the recipient does not have the home appliance management application installed, clicking the link will redirect to the official download page or an H5 preview page (displaying basic scene information and guiding the user to download the home appliance management application).
[0070] In another feasible embodiment, the first scene identifier includes a first scene QR code, and the identifier generation condition includes receiving a QR code generation request. The step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition may include: Step C10: In response to receiving a QR code generation request sent by the mobile terminal, the QR code generation request carries the scene ID corresponding to the first configuration parameter; Step C20: Encode the scene ID to generate the first scene QR code corresponding to the scene ID.
[0071] This application also provides a scheme for directly generating scene QR codes based on scene IDs for scene sharing. The first scene QR code is obtained by encoding the scene ID, with a one-to-one correspondence between the two. For example, when a user clicks "Share Scene" and selects "Generate QR Code" on a mobile device, the server generates the corresponding QR code image. The application displays the QR code image in a pop-up or full-screen mode, and outputs the prompt message "Friends can scan the code to obtain the scene." A "Save QR Code to Album" function is also provided for offline distribution (such as printing on instruction manuals or posters). The recipient can obtain corresponding configuration parameters and other information after scanning. If a third-party communication application scans the QR code, it opens the link in the system browser and then guides the user to download the home device management application or launches the home device management application via a URL Scheme (an in-page redirection protocol). If the QR code is scanned within the home device management application, the configuration parameters are directly parsed and the user is redirected to the corresponding scene information page, displaying the scene ID, configuration parameters, scene name, and other scene information.
[0072] In one feasible embodiment, such as Figure 5As shown, the conditions for generating the identifier include receiving an identifier generation request, and the scene identifier generation method may further include: Step D10: In response to the home management application on the mobile terminal receiving the identifier generation instruction, the scene ID corresponding to the first configuration parameter pointed to by the identifier generation instruction is obtained; Step D20: Embed the scene ID into the preset identifier generation request, and send the identifier generation request to the server through the mobile terminal so that the server can trigger the identifier generation conditions to generate the corresponding first scene identifier and establish a mapping relationship between the first configuration parameter and the first scene identifier.
[0073] Taking the first scene identifier as the scene password as an example, a home device management application is installed on the mobile terminal (such as a mobile phone). When the home device management application displays the user scene page, it can be used to receive the password generation instruction input by the user for the first configuration parameter (bound scene ID). The mobile terminal then embeds the scene ID into the preset identifier generation request and sends it to the server. After receiving it, the server will respond to the identifier generation request, generate the corresponding first scene identifier, and save the mapping relationship.
[0074] For example, after receiving a scene password shared by a friend via a mobile device, a user can choose to copy the scene password. After switching to the home device management application on the mobile device, the application automatically reads the scene password already copied from the clipboard or the scene password manually entered by the user, and then the mobile device sends the scene password to the server. The server queries the scene password in the mapping relationship of the database. If it is not found, it means that the scene password has expired, and the mobile device outputs the corresponding prompt information. If the scene ID and configuration parameters corresponding to the scene password are found, the server returns the scene ID, configuration parameters, scene name, and other information to the mobile device. Since the configuration parameters corresponding to the scene ID in the mapping relationship can be optimized and upgraded based on operational or user needs, the configuration parameters returned to the user at this time are the latest version, ensuring the timeliness of the scene configuration.
[0075] In another feasible embodiment, the identifier generation condition includes receiving an identifier generation request, and the scene identifier generation method may further include: Step E10: In response to the server receiving an identifier generation request sent by the mobile terminal, the server generates a first scene identifier corresponding to the scene ID based on the scene ID corresponding to the identifier generation request. Step E20: The server returns the first scene identifier to the mobile device so that the mobile device can share the first scene identifier with the target user.
[0076] This application provides a scenario identifier generation scheme after the server receives an identifier generation request sent by the mobile terminal. Taking the first scenario identifier as the scenario password as an example, after receiving the identifier generation request, the server will first determine whether the scenario ID already has a corresponding first scenario password. If it exists, the server will directly query the first scenario password corresponding to the scenario ID in the mapping relationship. If it does not exist, the server will generate the first scenario password corresponding to the scenario ID based on the preset password generation rules (allocated from optional strings or generated in real time) and return it to the mobile terminal so that the user can share the scenario based on the first scenario password.
[0077] In another feasible embodiment, for mobile devices, the scheme for sharing scene identifiers may include: In response to receiving a scene sharing instruction, the first scene information corresponding to the scene sharing instruction is sent to the server so that the server can return the first scene identifier corresponding to the scene information; A first scene identifier is received, wherein the first scene identifier is mapped to the configuration parameters of at least one home device, and the first scene identifier is used to share with the target user so that the target user can configure scene information according to the first scene identifier.
[0078] The scene sharing command is received by the home device management application (APP), which is software installed on a mobile device to manage smart home devices such as air conditioners, televisions, lights, curtains, and air purifiers. The scene sharing command is the control command entered by the user during interaction while using the mobile APP. It is used to convert the first scene information (including scene name, scene conditions, scene actions, etc.) corresponding to the current scene on the APP page into the form of a first scene identifier for easy and quick sharing.
[0079] It should be noted that the generation and acquisition of the first scene identifier requires the cooperation of the mobile terminal and the server. After the mobile terminal sends the first scene information to the server, the server determines whether the first scene information has already generated a first scene identifier. If so, the server directly returns the first scene identifier; otherwise, the server generates the first scene identifier first and then returns it, and stores the mapping relationship between the first scene identifier and the first scene information for subsequent calls.
[0080] The mobile device receives a first scene identifier sent from the server through the communication interface of the home device management APP. The first scene identifier can be a string password or a QR code, and the first scene identifier has a mapping relationship with the configuration parameters of at least one home device. This allows the user who shares the first scene identifier to determine the configuration parameters of the corresponding smart home device based on the first scene identifier, thereby realizing automated scene control of the smart home device.
[0081] Understandably, sharing a scene identifier is more convenient and simpler than sharing all scene configuration data. The first scene identifier (such as a scene password) can be sent to the target user's mobile device via various third-party communication applications, or it can be displayed to the target user as a QR code. Because the first scene identifier has a small data size and is easy to transmit, after being shared with the first scene identifier, the target user can use it to parse configuration parameters (including trigger conditions, control actions, etc.) for one or more home devices from the server. This effectively reuses the scene directly in the target user's home, lowering the barrier to understanding and operating scene configuration, enabling rapid sharing and one-click reuse of scene configurations, and improving deployment efficiency and user experience.
[0082] In one feasible embodiment, the method for adding scene configuration parameters on a mobile device may include: In response to the home device management application receiving the second scene identifier, the second scene identifier is sent to the server so that the server can return the second scene information corresponding to the second scene identifier; This application also provides a method for saving corresponding scene information by adding a scene identifier when a scene identifier is received.
[0083] Among them, the home device management application can receive the second scene identifier through a window in the APP page installed on the mobile terminal. Taking the scene password as an example, after the user receives the scene password shared by a friend, he or she enters it into the APP, and the APP sends it to the server. The server processes the scene password to determine the second scene information and returns the second scene information to the mobile terminal.
[0084] For example, taking scene passwords as an example, when receiving scene identifiers, the APP's homepage, scene homepage, and my scene page all have password addition function entry points. After the user clicks, a scene password input pop-up window is displayed. The user can enter the scene password to query the corresponding scene. If the corresponding scene is found, the user will be redirected to the corresponding scene information window. If the corresponding scene is not found, the user will be prompted that the scene password is incorrect or invalid.
[0085] Furthermore, if the home device model associated with the home device management application supports the configuration requirements corresponding to the second scene information, the scene information window corresponding to the second scene information is output. The scene information window includes at least the scene name, scene conditions, and scene actions.
[0086] To further improve the compatibility of sharing smart home scene configuration data across devices and address situations where different families have different smart home device models and brands, and the recipient cannot directly apply the scene configuration data to their own devices even if they obtain it, the server can determine whether the home device model associated with the home device management application installed on this mobile device supports the configuration requirements corresponding to the second scene information. If the configuration requirements are supported, the server can directly output the scene information window corresponding to the second scene information. The scene information window includes at least the scene name, scene conditions, and scene actions, allowing users to browse and understand the specific information of the current scene configuration. The server can also respond to user interactions to save and share the scene configuration data.
[0087] For example, the scene name is information that summarizes the scene function or application scenario, such as home scene, away scene, lights turn on when someone enters, movie viewing mode, etc.; the scene condition is the preset condition that triggers the scene, such as when a person is detected entering the door, when a person is detected leaving, when a person is detected approaching, etc.; the scene action is the control action for smart home devices that meets the scene condition, such as turning on the lights, turning off the lights, opening the curtains, turning on the air conditioner, etc.
[0088] In another feasible embodiment, if the home device model associated with the home device management application does not support the configuration requirements corresponding to the second scenario information, the first home device model that is not covered by the home device model associated with the home device management application is obtained from the home device models included in the second scenario information. If there is a second home device model with the same function as the first home device model among the home device models associated with the home device management application, the second home device model will be pushed to the user for selection, so as to update the second home device model to the second scene information; If there is no second home device model with the same function as the first home device model among the home device models associated with the home device management application, a prompt message will be output to indicate that the home device corresponding to the first home device model is missing, and a purchase link corresponding to the first home device model will be pushed.
[0089] Specifically, if the home device models associated with the home device management application do not cover all the home device models in the configuration requirements, it means that one or more home device models in the configuration requirements of the second scenario information are not available in the household. In order to further enhance the adaptability and versatility of scenario configuration, when the home device models associated with the home device management application do not cover all the home device models in the configuration requirements, a process is added to further query a second home device model (equivalent to a similar type of device) with the same function.
[0090] Specifically, first identify one or more first home appliance models that are not covered by the existing home appliances in the household. Then, find the second home appliance models that have the same functions. Home appliance models with the same functions refer to those that are not the same model but have basically the same functions. For example, although the household appliances do not include air conditioner model A, they do include air conditioner model C. Air conditioner model C has all the functions of air conditioner model A (cooling mode, dehumidification mode, energy saving mode, gentle wind mode, etc.) and can replace air conditioner model A in the scene configuration process. Therefore, air conditioner model C can be used as the second home appliance model.
[0091] Furthermore, if all first-home appliance models have corresponding second-home appliance models, it means that all first-home appliance models have alternatives, and users can be prompted to select the corresponding alternative to update the existing second-scene information. Conversely, if one or more first-home appliance models do not have corresponding second-home appliance models, this configuration requirement cannot be supported.
[0092] In another feasible embodiment, if it is determined that the configuration requirement is not supported, the home device management application outputs a corresponding prompt message, indicating to the user that the first home device model is missing, and pushes a home device model that can support the configuration requirement, and pushes a purchase link, prompting the purchase process, so that the user can purchase the required smart home devices more conveniently and quickly.
[0093] In another feasible embodiment, after the step of outputting the scene information window corresponding to the second scene information, the method may further include: In response to the scene information window receiving a save command, the second scene information is saved, and the third scene information is obtained; Understandably, after confirming the supported configuration requirements, users can save the scene information displayed in the scene information window by entering a save command on the interface, generating their own third scene information. There are two scenarios: First, if the home device models associated with the home device management application cover all the home device models in the configuration requirements, all parameters in the second scene information can be saved directly. In this case, all home device models match, and no modification is needed. The second scenario is if the home device models associated with the home device management application do not cover all the home device models in the configuration requirements, but a corresponding second home device model is found. In this case, the unmatched first home device model needs to be changed to the second home device model to obtain the corresponding third scene information.
[0094] When the page corresponding to the third scene information receives the scene sharing instruction, a third scene identifier is generated based on the third scene information.
[0095] Understandably, after saving the scene configuration shared by a friend to the mobile device, if the scene information needs to be shared again, a third scene identifier, different from the second scene identifier, will be generated. In this way, the scene identifier not only corresponds to the configuration parameters of the home device but also represents the identity of the sharer. Each sharer has a different scene identifier when sharing scene configurations, improving the traceability efficiency of scene identifiers.
[0096] In another feasible embodiment, after the step of saving the second scene information and obtaining the third scene information, the method may further include: When the scene corresponding to the third scene information is in an active state, in response to the satisfaction of the scene conditions, at least one home device is controlled based on the scene action.
[0097] After the scene information window is pushed to the mobile app, the user can enter the save command through the save button set on the scene information window. At this time, the scene name, scene conditions and scene actions will be saved locally.
[0098] The fact that the scene corresponding to the third scene information is in an active state means that the user has set the scene to an available state. Subsequently, as long as the scene conditions are met, the scene action will be automatically triggered to control the corresponding home devices, thereby realizing automated scene control of home devices.
[0099] For example, the scene name is "Lights on when people approach", and the scene condition is "people are detected approaching". When this mode is active, if people are detected approaching, the scene action "lights on" will be automatically triggered, thereby controlling the lights to turn on automatically.
[0100] In another feasible embodiment, the method for sharing and adding scene configurations on a mobile device may further include: In response to the home appliance management application receiving scene query information, determine the scene name corresponding to the scene query information; Send the scene name to the server so that the server can return the scene identifier corresponding to the scene name.
[0101] In another feasible embodiment, the home device management application can also be pre-installed with an AI (Artificial Intelligence) assistant. Users can send scene query information through keyboard input or voice interaction. The scene query information is used to express the intent to query the scene password. The scene identifier (such as scene password) of the scene name reflected in the scene query information can be queried through the server. Users can also long press to copy the scene password text and share the scene password with friends, or apply the scene information corresponding to the scene password in their own home.
[0102] In another feasible embodiment, after receiving the scene identifier, in response to the home device management application receiving the scene addition intent information, the scene identifier is sent to the server so that the server can return the scene information corresponding to the scene identifier; Receive scene information, and if the home appliance model associated with the home appliance management application supports the configuration requirements corresponding to the scene information, output the scene information window corresponding to the scene information; or, Receive scene information, and if the home device model associated with the home device management application supports the configuration requirements corresponding to the scene information, save the scene information to obtain the scene information.
[0103] It should be noted that after obtaining the scene identifier, users can also activate the AI assistant built into the application and send scene addition intent information through keyboard input or voice interaction. The server can then query the scene information corresponding to the scene identifier. If the home device model associated with the home device management application supports the configuration requirements corresponding to the scene information, a scene information window representing the scene details will be output, or the scene information can be directly added and saved as personalized exclusive scene information.
[0104] In another feasible embodiment, for the mobile terminal, in response to the detection of a scene password in the clipboard, the scene password is sent to the server so that the server can return the scene information corresponding to the scene password; If the home appliance model associated with the home appliance management application supports the configuration requirements corresponding to the scene information, output the scene information window corresponding to the scene information.
[0105] This application embodiment also supports clipboard copying of scene passwords to query corresponding scenes. For example, after a user copies a scene password and enters the APP, the APP can extract the scene password by recognizing and parsing the clipboard content, query the scene information corresponding to the scene password using the server, and directly jump to the corresponding scene information window if the home device model associated with the home device management application supports the configuration requirements corresponding to the scene information.
[0106] In another feasible embodiment, the control method for the server during the sharing and adding of scene configuration parameters may include: In response to receiving the first scene information sent by the mobile terminal; In the preset mapping relationship between scene information and scene identifier, query whether the first scene information already has a corresponding first scene identifier; If a first scene identifier exists, then the first scene identifier is sent to the mobile device; If no first scene identifier exists, a first scene identifier corresponding to the first scene information is generated, the first scene identifier is sent to the mobile terminal, and the first scene information and the first scene identifier are associated and stored in the mapping relationship.
[0107] This application provides a scenario configuration method applied on the server side. The first scenario information sent by the mobile terminal is the scenario information that the user of the mobile terminal needs to share. At this time, the server needs to determine whether the first scenario information already has a corresponding first scenario identifier. It should be noted that if the user of the mobile terminal has previously shared the first scenario information with friends, that is, the first scenario identifier has been pre-generated, it is stored on the server in the form of a mapping relationship. The server directly queries the corresponding first scenario identifier and sends it to the mobile terminal. If the mapping relationship stored locally on the server does not include the first scenario information, a unique first scenario identifier is generated in real time (the first scenario identifier and the first scenario information correspond one-to-one), the first scenario identifier is returned to the mobile terminal, and the first scenario information and the first scenario identifier are associated and stored in the mapping relationship for future use.
[0108] To facilitate understanding, a feasible mobile (corresponding APP) and server-side business process during scenario configuration sharing is as follows: Figure 6 As shown, firstly, after the user enters the scene details in the mobile app, the user clicks to share, which queries the server for the scene password. The server determines whether a scene password has been generated for the scene. If not, it generates the scene and sends the scene password to the mobile app. If so, it sends the scene password to the mobile app. The mobile app displays the scene password, and the user can then copy the scene password and send it to a friend in a third-party communication application.
[0109] In another feasible embodiment, for the server, in response to receiving the second scene identifier sent by the mobile terminal, it queries the mapping relationship to see if the second scene identifier exists; If a second scene identifier exists and the second scene identifier is enabled, the second scene information corresponding to the second scene identifier will be sent to the mobile device. If the second scene identifier does not exist or is not enabled, a prompt message indicating that the second scene identifier is invalid will be sent to the mobile device.
[0110] After receiving the second scene identifier sent by the user, the server needs to determine whether the second scene identifier is enabled and whether it is a real and valid scene identifier. Being enabled means that the sharer of the second scene identifier has not disabled the second scene identifier. Being a real and valid scene identifier means that the second scene identifier is generated based on the server and the second scene information, and is not other randomly generated or meaningless identifiers. This can be determined by querying the mapping relationship stored on the server.
[0111] The step of sending the second scene information corresponding to the second scene identifier to the mobile terminal will only be executed if the second scene identifier is genuine, valid and enabled. Otherwise, a prompt message indicating that the second scene identifier is invalid will be sent to the mobile terminal.
[0112] To facilitate understanding, a feasible mobile and server-side business process for adding scene identifiers is as follows: Figure 7 As shown, after the mobile device enters the password addition page and inputs the scene password through the APP, it queries the server for the scene. The server determines whether the scene password is valid. If the scene password is valid, it queries the corresponding scene information and returns the scene information to the mobile device. The server then determines whether the home device meets the configuration requirements of the scene. If it does, the user can directly save the scene. If it does not, it outputs a message indicating that it is not supported.
[0113] Furthermore, after the step of sending the second scene information corresponding to the second scene identifier to the mobile terminal, If the home device models associated with the home device management application cover all the home device models in the second scenario information, it is determined that the home device models associated with the home device management application support the configuration requirements corresponding to the second scenario information. If the home device models associated with the home device management application do not cover all the home device models in the second scenario information, it is determined that the home device models associated with the home device management application do not support the configuration requirements corresponding to the second scenario information.
[0114] It should be noted that the second scenario information in this application embodiment includes various home appliance models. Based on preset scenario conditions, the scene can be automatically controlled by adaptively setting the devices of these home appliance models. Therefore, in order to meet the scenario configuration requirements, the smart home appliance models in the home where the mobile terminal is located must at least include these home appliance models. The specific smart home appliance models in the home are represented by the home appliance models associated with the home appliance management application. The APP includes the associated home appliance models. By comparing these home appliance models with the home appliance models or brands in the configuration requirements, it can be determined whether all home appliance models in the configuration requirements are fully covered.
[0115] For example, if the configuration requirements include air conditioner model A, curtain model B, and lighting model C, and the home device models associated with the home device management application include: air conditioner model A, air conditioner model D, curtain model B, lighting model C, and table lamp model E, then the configuration requirements are considered supported. If the home device models associated with the home device management application only include: air conditioner model A and curtain model B, and lighting model C is missing, then the configuration requirements are considered not supported.
[0116] It should be noted that this example is only for the purpose of assisting in understanding this application and does not constitute a limitation on the scenario identifier generation method of this application. Any simple transformations based on this technical concept are all within the protection scope of this application.
[0117] This application also provides an electronic device, which includes at least: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, which are executed by the at least one processor to enable the at least one processor to perform the scene identifier generation method in the above embodiments.
[0118] The following is for reference. Figure 8 It shows a schematic diagram of the structure of an electronic device suitable for implementing the embodiments of this application. Figure 8 The electronic device shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of this application.
[0119] like Figure 8 As shown, the electronic device may include a processing unit 101 (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 102 or a program loaded from a storage device 103 into a random access memory (RAM) 104. The RAM 104 also stores various programs and data required for the operation of the electronic device. The processing unit 101, ROM 102, and RAM 104 are interconnected via a bus 105. An input / output (I / O) interface 106 is also connected to the bus. Typically, the following systems can be connected to the I / O interface 106: input devices 107 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 108 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 103 including, for example, magnetic tapes, hard disks, etc.; and communication devices 109. The communication device 109 allows the electronic device to communicate wirelessly or wiredly with other devices to exchange data. Although the diagrams show electronic devices with various systems, it should be understood that it is not required to implement or have all of the systems shown. More or fewer systems may be implemented alternatively.
[0120] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 103, or installed from ROM 102. When the computer program is executed by processing device 101, it performs the functions defined in the methods of the embodiments of this application.
[0121] The electronic device provided in this application, employing the scene identifier generation method described in the above embodiments, can improve the sharing efficiency of scene configuration data for smart home devices. Compared with the prior art, the beneficial effects of the electronic device provided in this application are the same as those of the scene identifier generation method provided in the above embodiments, and other technical features in the electronic device are the same as those disclosed in the methods of the above embodiments, and will not be repeated here.
[0122] It should be understood that various parts of the embodiments of this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.
[0123] The above description is merely a specific implementation of the embodiments of this application, but the protection scope of the embodiments of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the protection scope of the embodiments of this application. Therefore, the protection scope of the embodiments of this application should be determined by the protection scope of the above claims.
[0124] This application also provides a computer-readable storage medium storing a computer program that can run on a processor. The computer program is used to execute the scene identifier generation method in the above embodiments.
[0125] The computer-readable storage medium provided in this application embodiment may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems or devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections with one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.
[0126] The aforementioned computer-readable storage medium may be included in an electronic device or may exist independently without being assembled into an electronic device.
[0127] The aforementioned computer-readable storage medium carries one or more programs that, when executed by an electronic device, cause the electronic device to: in response to triggering an identifier generation condition, generate a first scene identifier corresponding to a first configuration parameter based on a scene ID corresponding to the identifier generation condition, wherein the first configuration parameter includes at least a scene condition and scene action corresponding to a home device; establish a mapping relationship between the first configuration parameter and the first scene identifier, and store the mapping relationship, wherein the mapping relationship is used for users to apply the first configuration parameter to a home device management application based on the shared first scene identifier.
[0128] Computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0129] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0130] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.
[0131] The computer-readable storage medium provided in this application embodiment stores computer-readable program instructions for executing the above-described scene identifier generation method, which can improve the sharing efficiency of scene configuration data of smart home devices. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application embodiment are the same as the beneficial effects of the scene identifier generation method provided in the above embodiments, and will not be repeated here.
[0132] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the scene identifier generation method described above.
[0133] The computer program product provided in this application can improve the sharing efficiency of scene configuration data of smart home devices. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as the beneficial effects of the scene identifier generation method provided in the above embodiments, and will not be repeated here.
[0134] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent scope of this application.
Claims
1. A method for generating scene identifiers, characterized in that, The method includes: In response to triggering the identifier generation condition, a first scene identifier corresponding to the first configuration parameter is generated based on the scene ID corresponding to the identifier generation condition, wherein the first configuration parameter includes at least a scene condition and scene action corresponding to a home device; Establish a mapping relationship between the first configuration parameter and the first scene identifier, and store the mapping relationship, wherein the mapping relationship is used for users to apply the first configuration parameter to the home device management application based on the shared first scene identifier.
2. The scene identifier generation method as described in claim 1, characterized in that, The first scene identifier includes a first scene password, and the identifier generation condition includes receiving a password generation request. The step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to receiving a password generation request, the password generation request carries the scenario ID corresponding to the first configuration parameter; A string of a preset length is generated based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID.
3. The scene identifier generation method as described in claim 2, characterized in that, After the step of generating a string of a preset length based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID, the method further includes: In response to receiving a link generation request, the link generation request carries the scene ID corresponding to the first configuration parameter; The first scene password is embedded into a preset link template to generate the first scene link corresponding to the scene ID.
4. The scene identifier generation method as described in claim 3, characterized in that, After the step of embedding the first scene password into a preset link template to generate the first scene link corresponding to the scene ID, the method further includes: In response to receiving a QR code generation request, the QR code generation request carries the scene ID corresponding to the first configuration parameter; Encode the first scene password and / or the first scene link to generate a first scene QR code corresponding to the scene ID.
5. The scene identifier generation method as described in claim 1, characterized in that, The first scene identifier includes a first scene password, the identifier generation condition includes a first configuration parameter pre-generated to the scene recommendation page, and the step of generating the first scene identifier corresponding to the first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to the first configuration parameter being pre-generated on the scene recommendation page, a string of a preset length is generated based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID of the first configuration parameter.
6. The scene identifier generation method as described in claim 5, characterized in that, Before the step of generating a string of a preset length based on a preset combination of numbers and letters, the method further includes: Check if the scene ID corresponding to the first configuration parameter exists in the stored mapping relationship; If it exists, the second configuration parameter corresponding to the scene ID in the mapping relationship is updated to the first configuration parameter.
7. The scene identifier generation method as described in claim 6, characterized in that, After the step of querying whether the scene ID corresponding to the first configuration parameter exists in the stored mapping relationship, the method further includes: If the scene ID corresponding to the first configuration parameter does not exist in the stored mapping relationship, then return to the step of generating a string of a preset length based on a preset combination of numbers and letters.
8. The scene identifier generation method as described in claim 5, characterized in that, After the step of generating a string of a preset length based on a preset combination of numbers and letters to obtain the first scene password corresponding to the scene ID, the method further includes: In response to the scenario recommendation page receiving a save instruction for the first configuration parameter, the first user scenario corresponding to the first configuration parameter is obtained; In response to the user scenario page receiving a password generation instruction for the first user scenario, a string of a preset length is generated based on a preset combination of numbers and letters to obtain a second scenario password corresponding to the first configuration parameter, wherein the second scenario password is different from the first scenario password.
9. The scene identifier generation method as described in claim 1, characterized in that, After the step of establishing the mapping relationship between the first configuration parameter and the first scene identifier, and storing the mapping relationship, the method further includes: In response to an update to the first configuration parameter, the first configuration parameter is updated to the third configuration parameter in the mapping relationship; Upon receiving the first scene identifier, the third configuration parameter is returned; In response to receiving a cancellation command for the first scene identifier, the first scene identifier and the configuration parameters corresponding to the first scene identifier are deleted from the mapping relationship, and the first scene identifier is released.
10. The scene identifier generation method as described in claim 1, characterized in that, The first scene identifier includes a first scene link, and the identifier generation condition includes receiving a link generation request. The step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition, in response to triggering the identifier generation condition, includes: In response to receiving a link generation request sent by a mobile terminal, the link generation request carries a scenario ID corresponding to the first configuration parameter; The scene ID is embedded into a preset link template to generate the first scene link corresponding to the scene ID.
11. The scene identifier generation method as described in claim 10, characterized in that, After the step of embedding the scene ID into a preset link template and generating a first scene link corresponding to the scene ID, the method further includes: In response to receiving a QR code generation request, the QR code generation request carries the scene ID corresponding to the first configuration parameter; The first scene link is encoded to generate a first scene QR code corresponding to the scene ID.
12. The scene identifier generation method as described in claim 1, characterized in that, The first scene identifier includes a first scene QR code. The identifier generation condition includes receiving a QR code generation request. The step of generating a first scene identifier corresponding to a first configuration parameter based on the scene ID corresponding to the identifier generation condition in response to triggering the identifier generation condition includes: In response to receiving a QR code generation request sent by a mobile terminal, the QR code generation request carries a scene ID corresponding to the first configuration parameter; The scene ID is encoded to generate a first scene QR code corresponding to the scene ID.
13. The scene identifier generation method as described in claim 1, characterized in that, The identifier generation conditions include receiving an identifier generation request, and the scene identifier generation method includes: In response to the home management application on the mobile terminal receiving the identifier generation instruction, the scene ID corresponding to the first configuration parameter pointed to by the identifier generation instruction is obtained; The scene ID is embedded in a preset identifier generation request, and the identifier generation request is sent to the server through the mobile terminal so that the server can trigger the identifier generation conditions to generate the corresponding first scene identifier and establish a mapping relationship between the first configuration parameter and the first scene identifier.
14. The scene identifier generation method as described in claim 1, characterized in that, The identifier generation conditions include receiving an identifier generation request, and the scene identifier generation method includes: In response to the server receiving an identifier generation request sent by the mobile terminal, the server generates a first scene identifier corresponding to the scene ID based on the scene ID corresponding to the identifier generation request. The server returns the first scene identifier to the mobile device so that the mobile device can share the first scene identifier with the target user.
15. An electronic device, characterized in that, The electronic device includes at least: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the scene identifier generation method as described in any one of claims 1 to 14.
16. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a program implementing the scene identifier generation method, which is executed by a processor to implement the steps of the scene identifier generation method as described in any one of claims 1 to 14.