Lighting display method, device, equipment and storage medium
By using drivers in smart devices to directly read the lighting profile of the cloud server and control the lighting in real time, the problem of slow response speed of the smart device's lighting display is solved, achieving fast response and high-intelligent interactive experience.
Patent Information
- Application Number
- CN201910660068.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-07-22
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2039-07-22
AI Technical Summary
After the existing smart devices process user voice input, the light display response speed is slow and cannot achieve real-time interaction.
The driver directly reads and parses the lighting configuration files stored in the cloud server, extracts operation instructions corresponding to voice information, and controls the display effect of the lighting components in real time.
It significantly improves the response speed of the light display, and can complete the response of the light display effect within 0.1 seconds, greatly improving the intelligence and user experience of the intelligent interactive device.
Smart Images

Figure CN110569070B_ABST
Abstract
Description
[Technical field]
[0001] The present invention belongs to the technical field of intelligent devices, and in particular relates to a light display method, device, equipment and storage medium. [Background technology]
[0002] Existing smart devices such as smart speakers and smart robots can control different lighting display effects according to user operations. At present, most smart devices mainly trigger lighting control through voice input. After waiting for the network to send and receive control commands, they are processed in the upper-level application queue, and then the driver executes the command to control the display effect of the lighting device. The upper-level application often needs to handle more tasks. Without considering the network delay, the user can only see the corresponding response of the lighting display effect after 1 to 3 seconds. This control method has a slow response and cannot allow users to feel the operation of interacting with smart devices in real time.
[0003] In view of this, it is necessary to provide a light display method, device, equipment and storage medium to overcome the above-mentioned defects. [Summary of the invention]
[0004] The present invention provides a light display method, device, equipment and storage medium to improve the response speed of controlling light display and enhance the intelligence of intelligent interactive equipment.
[0005] In order to achieve the above object, the present invention provides a light display method, which is applied to a smart device and comprises the following steps:
[0006] Get voice information and connect to the cloud server;
[0007] Reading and parsing the lighting effect configuration file stored in the cloud server through a driver program, and extracting the operation instruction corresponding to the voice information;
[0008] The lighting assembly is controlled to perform corresponding operations according to the operation instructions.
[0009] In a preferred embodiment, the driver program reads and parses the lighting effect configuration file stored in the cloud server to extract the operation instruction corresponding to the voice information, including:
[0010] Parse and obtain the regular expression in the lighting effect configuration file;
[0011] Matching the voice information with the regular expression to find a matched target expression;
[0012] Output an operation instruction according to the lighting effect parameters in the target expression.
[0013] In a preferred embodiment, before the step of obtaining voice information and connecting to the cloud server, the method further includes:
[0014] Set the corresponding regular expression according to the voice content and lighting effect parameters;
[0015] A lighting effect configuration file including multiple regular expressions is created and stored in a cloud server.
[0016] In a preferred embodiment, before the step of obtaining voice information and connecting to the cloud server, the method further includes:
[0017] Connect and log in to the cloud server and search for the lighting effect configuration file stored in the cloud server through the driver;
[0018] The lighting effect parameters are modified by the driver and saved and updated in the lighting effect configuration file.
[0019] In order to achieve the above object, the present invention provides a light display device, comprising:
[0020] The acquisition module is used to obtain voice information and connect to the cloud server;
[0021] An extraction module, used to read and parse the lighting effect configuration file stored in the cloud server through a driver program, and extract an operation instruction corresponding to the voice information;
[0022] The control module is used to control the lighting assembly to perform corresponding operations according to the operation instructions.
[0023] In a preferred embodiment, the extraction module further comprises:
[0024] A parsing unit, used for parsing and obtaining a regular expression in the lighting effect configuration file;
[0025] A matching unit, used to match the voice information with the regular expression to find a matched target expression;
[0026] An output unit is used to output an operation instruction according to the lighting effect parameters in the target expression.
[0027] In a preferred embodiment, the light display device further comprises:
[0028] The setting module is used to set the corresponding regular expression according to the voice content and lighting effect parameters;
[0029] The storage module is used to establish a lighting effect configuration file including multiple regular expressions and store it in a cloud server.
[0030] In a preferred embodiment, the light display device further comprises:
[0031] A search module, used to connect to and log in to the cloud server and search for a lighting effect configuration file stored in the cloud server through the driver;
[0032] An updating module is used to modify the lighting effect parameters through the driver and save and update them in the lighting effect configuration file.
[0033] In order to achieve the above objectives, the present invention also provides an intelligent device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above method when executing the computer program.
[0034] In order to achieve the above object, the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the above method are implemented.
[0035] Compared with the prior art, the beneficial effect of the present invention is that after the user utters a voice, the file on the cloud server on the network is directly read and parsed through the driver program, and the corresponding operation instructions are obtained for the lighting component to execute, which can quickly complete the reaction of the lighting display effect and has a fast response speed, greatly improving the intelligence of the smart interactive device.
[0036] In order to make the above-mentioned objects, features and advantages of the invention more obvious and easy to understand, the preferred embodiments of the present invention are specifically cited below and described in detail with reference to the attached drawings.
Brief Description of the Drawings
[0037] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0038] Figure 1 A flowchart of a light display method provided in Embodiment 1 of the present invention;
[0039] Figure 2 for Figure 1 The sub-flow chart of step S102 in the light display method shown;
[0040] Figure 3 A flowchart of a light display method provided in Embodiment 2 of the present invention;
[0041] Figure 4 A flowchart of a light display method provided in Embodiment 3 of the present invention;
[0042] Figure 5 This is a structural block diagram of a light display device provided in an embodiment of the present invention. [Specific implementation method]
[0043] In order to make the purpose, technical solution and beneficial technical effect of the present invention clearer, the present invention is further described in detail below in conjunction with the accompanying drawings and specific implementation methods. It should be understood that the specific implementation methods described in this specification are only for explaining the present invention, not for limiting the present invention.
[0044] See also Figure 1 and Figure 2 The embodiment of the present invention provides a light display method, which is applied to a smart device and specifically includes the following steps:
[0045] Step S101, obtain voice information and connect to log in to the cloud server.
[0046] In step S101, a lighting component such as an LED lamp is provided on the smart device, and the smart device responds to the lighting effect through voice input, wherein the smart device may include, but is not limited to, a smart speaker, a smart air conditioner, a smart refrigerator, a smart voice door and window, and a smart voice interactive robot. When the user issues a corresponding voice as needed, the smart device receives the voice information and logs in to the cloud server through a wireless network. The voice information is input by the user, and the voice information may be the voice issued directly from the user's mouth, or it may be audio downloaded from the Internet or pre-recorded audio. Specifically, the smart device may obtain the voice information input by the user through a microphone.
[0047] Step S102, reading and parsing the lighting effect configuration file stored in the cloud server through the driver program, and extracting the operation instruction corresponding to the voice information.
[0048] The lighting effect configuration file stored in the cloud server is read and parsed by the driver, and the operation instructions corresponding to the voice information are extracted according to the lighting effect configuration file. In step S102, the driver is a specific program based on the Linux system to control the lighting components. By running the driver, the files on the cloud server can be directly parsed. In the prior art, it is necessary to wait for the network to send and receive the lighting control command, and then parse the lighting effect configuration file and extract the operation instructions through the application in the smart device controller. The technical solution of the present invention avoids the step of queuing the application in the controller of the smart device, thereby improving the operation efficiency. Among them, if Figure 2 As shown, step S102 further includes the following sub-steps:
[0049] Step S201, parse and obtain a regular expression in the lighting effect configuration file.
[0050] The lighting effect configuration file can be a pre-generated regular expression library. Regular expressions are also called regular expressions, which describe a string matching pattern and can be used to retrieve and / or replace text content that meets a certain rule. In actual operation, smart device manufacturers can set corresponding regular expressions in advance according to different task types, such as wake-up tasks or power-on tasks, so that users can directly obtain regular expressions to implement corresponding lighting display functions when interacting with smart devices.
[0051] For example, the pre-set wake-up task is that the default display light of the smart device named "Xiao Ai" is blue after waking up, so the regular expression related to wake-up is set to "name": "Xiao Ai", "led_color": "blue". The character rules established by the regular expression are to use commas as delimiters and the first double quotation mark as a match. The voice information it matches is the wake-up word "Xiao Ai". After the match is qualified, the second double quotation mark is matched, and the color of the light is determined to be blue based on the feature content of the second double quotation mark.
[0052] Step S202, matching the voice information with the regular expression to find the matched target expression.
[0053] The target expression is the regular expression after successful matching. For example, when the user shouts the wake-up word "Xiao Ai", there is a regular expression in the lighting effect configuration file: "name": "Xiao Ai", "led_color": "blue", and the voice information input by the user matches the regular expression, which is the target expression.
[0054] Step S203: outputting operation instructions according to the lighting effect parameters in the target expression.
[0055] Among them, the lighting effect parameters can be obtained from the target expression, for example, if it is blue, the corresponding operation instruction can be to adjust the RGB color of the light component to (0, 0, 255) to achieve the lighting effect of blue display. In this embodiment, the lighting effect parameters can include, but are not limited to, light colors such as red, yellow, and blue, light flashing states such as on and off, and the shape composed of multiple light displays can be, for example, square and circle.
[0056] Step S103, controlling the lighting assembly to perform a corresponding operation according to the operation instruction.
[0057] In step S103, the operation instruction extracted by the driver is sent to the controller in the smart device through the communication interface, and then the controller controls the lighting component to perform the corresponding operation, such as controlling the LED light to emit blue light.
[0058] In the embodiment of the present invention, after the user utters a voice, the file on the cloud server on the network is directly read and parsed through the driver program, and the corresponding operation instructions are obtained for the lighting component to execute. The reaction of the lighting display effect can be completed within 0.1s, and the response speed is fast, which greatly improves the intelligence of the smart interactive device and enhances the user experience.
[0059] In one embodiment of the present invention, see Figure 3 Step S102 specifically includes the following steps:
[0060] Step S301, setting a corresponding regular expression according to the voice content and lighting effect parameters.
[0061] The voice content is the text content in the regular expression, which is associated with the voice information input by the user. The regular expression can be set by the user or by the default setting of the smart device system.
[0062] Step S302: Create a lighting effect configuration file including a plurality of regular expressions and store it in a cloud server.
[0063] Among them, the lighting effect configuration file is stored in the cloud server, which makes it convenient for smart devices to enter the cloud server to parse the file and occupies less memory of the smart device.
[0064] Step S303, obtain voice information and connect to log in to the cloud server.
[0065] Step S304, reading and parsing the lighting effect configuration file stored in the cloud server through the driver program, and extracting the operation instruction corresponding to the voice information.
[0066] Step S305, controlling the lighting assembly to perform a corresponding operation according to the operation instruction.
[0067] In one embodiment of the present invention, see Figure 4 , the lighting display method specifically includes the following steps:
[0068] Step S401, connect to and log in to the cloud server and search for the lighting effect configuration file stored in the cloud server through the driver.
[0069] Among them, users can open the settings webpage of the smart device through a mobile phone or computer, enter their account to log in to the cloud server, and customize the lighting effect display according to their own needs or preferences, which is highly flexible.
[0070] Step S402, modifying the lighting effect parameters through the driver and saving and updating in the lighting effect configuration file.
[0071] Among them, after searching the lighting effect configuration file through the driver, it can be modified directly through the driver. The technical solution of the present invention omits the step of processing through the application, thereby improving the operating efficiency. The user can select a color value in the color comparison table or color selection item as a new lighting effect parameter. For example, the default display light blue in the regular expression related to the wake-up task is changed to RGB color (255, 0, 0). When the lighting effect configuration file is updated, the lighting effect configuration file stored in the cloud server is read and parsed by the driver when the voice wake-up is input again, and the extracted operation instruction is to display the red lighting effect.
[0072] Step S403, obtain voice information and connect to log in to the cloud server.
[0073] Step S404, reading and parsing the lighting effect configuration file stored in the cloud server through the driver, and extracting the operation instruction corresponding to the voice information.
[0074] Step S405, controlling the lighting assembly to perform a corresponding operation according to the operation instruction.
[0075] Based on the above method embodiment, the present invention also provides a light display device 100, see Figure 5 , the light display device 100 specifically comprises:
[0076] The acquisition module 10 is used to acquire voice information and connect to the cloud server.
[0077] The extraction module 20 is used to read and parse the lighting effect configuration file stored in the cloud server through the driver program, and extract the operation instructions corresponding to the voice information.
[0078] The control module 30 is used to control the lighting assembly to perform corresponding operations according to the operation instructions.
[0079] Furthermore, the extraction module 20 also includes:
[0080] The parsing unit 21 is used to parse and obtain the regular expression in the lighting effect configuration file.
[0081] The matching unit 22 is used to match the voice information with the regular expression to find the matched target expression.
[0082] The output unit 23 is used to output an operation instruction according to the lighting effect parameters in the target expression.
[0083] Preferably, the light display device 100 further includes:
[0084] The setting module 40 is used to set corresponding regular expressions according to the voice content and lighting effect parameters.
[0085] The storage module 50 is used to establish a lighting effect configuration file including a plurality of regular expressions and store it in a cloud server.
[0086] Preferably, the light display device 100 further includes:
[0087] The search module 60 is used to connect to the cloud server and search for the lighting effect configuration file stored in the cloud server through the driver.
[0088] The updating module 70 is used to modify the lighting effect parameters through the driver program and save and update them in the lighting effect configuration file.
[0089] It should be noted that the device is a device corresponding to the above-mentioned light display method, and all implementation methods in the above-mentioned method embodiment are applicable to the embodiment of the device and can achieve the same technical effect.
[0090] Furthermore, an embodiment of the present invention also provides an intelligent device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the light display method in the above embodiment when executing the computer program.
[0091] The embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the steps of the light display method in the above embodiment are implemented.
[0092] A person skilled in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.
[0093] The above are only preferred embodiments of the present invention, which are further detailed descriptions of the present invention in combination with specific preferred implementations. It cannot be determined that the specific implementation of the present invention is limited to these descriptions. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A light display method, applied to a smart device, characterized in that: The following steps are involved: Get voice information and connect to the cloud server; The lighting effect configuration file stored in the cloud server is read and parsed by the driver program, and the operation instruction corresponding to the voice information is extracted; the driver program is a specific program for controlling the lighting components based on the Linux system, and the file on the cloud server can be directly parsed by running the driver program; Control the lighting assembly to perform corresponding operations according to the operation instructions; The operation instructions extracted by the driver are sent to the controller in the smart device through the communication interface, and then the controller controls the lighting component to perform the corresponding operation; The driver program reads and parses the lighting effect configuration file stored in the cloud server, and extracts the operation instruction corresponding to the voice information, including: Parse and obtain the regular expression in the lighting effect configuration file; Matching the voice information with the regular expression to find a matched target expression; Outputting an operation instruction according to the lighting effect parameters in the target expression; Before the step of obtaining voice information and connecting to the cloud server, the method further includes: Set the corresponding regular expression according to the voice content and lighting effect parameters; Create a lighting effect configuration file including multiple regular expressions and store it in a cloud server; Before the step of obtaining voice information and connecting to the cloud server, the method further includes: Connect and log in to the cloud server and search for the lighting effect configuration file stored in the cloud server through the driver; The lighting effect parameters are modified by the driver and saved and updated in the lighting effect configuration file.
2. A lighting display device, characterized in that: include: The acquisition module is used to obtain voice information and connect to the cloud server; An extraction module, used to read and parse the lighting effect configuration file stored in the cloud server through a driver program, and extract the operation instructions corresponding to the voice information; the driver program is a specific program for controlling the lighting components based on the Linux system, and the file on the cloud server can be directly parsed by running the driver program; A control module, used to control the lighting assembly to perform corresponding operations according to the operation instructions; The operation instructions extracted by the driver are sent to the controller in the smart device through the communication interface, and then the controller controls the lighting component to perform the corresponding operation; The extraction module also includes: A parsing unit, used for parsing and obtaining a regular expression in the lighting effect configuration file; A matching unit, used to match the voice information with the regular expression to find a matched target expression; An output unit, used for outputting an operation instruction according to the lighting effect parameters in the target expression; The light display device also includes: The setting module is used to set the corresponding regular expression according to the voice content and lighting effect parameters; A storage module, used for establishing a lighting effect configuration file including a plurality of regular expressions and storing the configuration file in a cloud server; The light display device also includes: A search module, used to connect to and log in to the cloud server and search for a lighting effect configuration file stored in the cloud server through the driver; An updating module is used to modify the lighting effect parameters through the driver and save and update them in the lighting effect configuration file.
3. An intelligent device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to claim 1 are implemented.
4. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to claim 1 are implemented.
Citation Information
Patent Citations
Data analyzing method and device
CN105868311A
Lighting display effect control method
CN106332399A
Method and apparatus for presenting information
CN108804667A