Lamp control method, apparatus, computer device, and storage medium
Patent Information
- Application Number
- JP2025009400
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2024-04-08
- Filing Date
- 2025-01-22
- Publication Date
- 2026-09-03
- Estimated Expiration
- 2045-01-22
Smart Images

Figure 0007915308000002 
Figure 0007915308000003 
Figure 0007915308000004
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of lighting devices, and specifically to a lamp body control method, an apparatus, a computer device and a storage medium. Background Art
[0002] With the improvement of people's living standards and the development of lighting technology, the use scenarios of various lamps such as stage lamps, photography lamps and landscape lamps have become increasingly complex, and the number of lamp bodies used in each scenario has been increasing. However, in the related art, since one lamp control device controls only one lamp body, each lamp body needs to be provided with one lamp control device, which makes it difficult to realize overall control of multiple lamp bodies. Summary of the Invention Problem to be Solved by the Invention
[0003] Embodiments of the present application provide a lamp body control method, an apparatus, a computer device and a storage medium, which can realize overall control of multiple lamp bodies by one lamp control device, and can improve the control accuracy of lamp bodies. Means for Solving the Problem
[0004] In a first aspect, the present application provides a lamp body control method, which is applied to a target lamp body in a lamp body control system, the lamp body control system includes a lamp control device and a plurality of lamp bodies communicatively connected to the lamp control device, the target lamp body is one of the plurality of lamp bodies, and the lamp body control method includes: receiving lamp control data transmitted from the lamp control device, wherein the lamp control data includes first address information, response information and control data, and the response information is used to characterize whether feedback data corresponding to the control data needs to be transmitted to the lamp control device; and The first address information is matched with the second address information that has been stored in advance, and it is confirmed that the second address information corresponds to the address information of the target lamp body. This includes, when the first address information matches the second address information, executing a control operation corresponding to the control data based on the response information.
[0005] In some embodiments of the present application, the lamp control data further includes first number information, and the control operation corresponding to the control data is performed based on the response information. Based on the response information, it is determined whether it is necessary to send feedback data corresponding to the control data to the lamp control device, If it is not necessary to transmit feedback data corresponding to the control data to the lamp control device, the first number information is matched with the second number information that has been stored in advance, and it is confirmed that the second number information is the number information most recently stored on the target lamp body. This includes, if the first number information does not match the second number information, executing the control operation corresponding to the control data.
[0006] In some embodiments of the present application, after determining whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device based on the response information, When it is necessary to transmit feedback data corresponding to control data to the lamp control device, this includes performing a control operation corresponding to the control data and transmitting feedback data corresponding to the control operation to the lamp control device.
[0007] In some embodiments of the present application, the control data includes a first setting command and / or a data reading command and / or an upgrade command, and the control device performs a control operation corresponding to the control data and transmits feedback data corresponding to the control operation to the lamp control device. The first setting operation corresponding to the first setting command is executed, and the setting result corresponding to the first setting operation is transmitted to the lamp control device. and / or, Based on the data reading command, the target data is determined, the target data is packaged, and the packaged target data is transmitted to the lamp control device. and / or, This includes performing an upgrade operation based on an upgrade command and transmitting the upgrade result corresponding to the upgrade operation to the lamp control device.
[0008] In some embodiments of the present invention, the lamp control data further includes protocol header information and a first check code, and before matching the first address information with the pre-stored second address information, Check the protocol header information and obtain the first check result, If the first check result passes the check, the first check code is checked based on the control data to obtain the second check result.
[0009] In a second aspect, the present application provides a lamp control method, which is applied to a lamp control device in a lamp control system, the lamp control system comprising a lamp control device and a plurality of lamps connected to the lamp control device by communication, the lamp control method is The control data and candidate lamp bodies corresponding to the control data are obtained, and it is determined that the candidate lamp body is at least one of multiple lamp bodies. The purpose is to determine the response information corresponding to the control data and to characterize whether the response information needs to transmit feedback data corresponding to the control data to the lamp control device, Based on the response information and the first address information, control data is packaged to obtain lamp control data, and the first address information is the address information corresponding to the candidate lamp body. This includes transmitting lamp control data to multiple lamp units so that a target lamp unit among multiple lamp units can perform a control operation corresponding to the control data based on first address information and response information.
[0010] In some embodiments of the present application, determining response information corresponding to control data is The data type of the control data is obtained, and the data type includes both Type 1 and Type 2. When the data type is of type 1, it is determined that the response information corresponding to the control data is type 1, and the purpose is to characterize that there is no need to transmit feedback data corresponding to the control data to the lamp control device. This includes determining that, if the data type is of type 2, the response information corresponding to the control data is type 2 information, and that the type 2 information is required to transmit feedback data corresponding to the control data to the lamp control device.
[0011] In some embodiments of the present application, when the control data is a first setting command, the lamp control data is transmitted to multiple lamp bodies. This includes adding lamp control data to the tail node of a pre-built linking list, and transmitting node data in the linking list to multiple lamp bodies according to a predetermined first timing time and a predetermined number of times.
[0012] In some embodiments of the present application, when the control data includes multiple data sub-items and the multiple data sub-items are different first data read commands, transmitting the lamp control data to multiple lamp bodies is: Based on the second timing time for each data sub-item, the timeout time for each data sub-item is determined, This involves sorting multiple data sub-items based on their timeout duration and obtaining the timeout sort results for those sub-items. This includes sending multiple data sub-items to multiple ramp bodies based on the timeout sort result.
[0013] In a third aspect, the present application provides a lamp body control device, which is applied to a target lamp body in a lamp body control system. The lamp body control system comprises a lamp control device and a plurality of lamp bodies communicatively connected to the lamp control device, the target lamp body is one of the plurality of lamp bodies, and the lamp body control device comprises: a data receiving unit, configured to receive lamp control data transmitted from the lamp control device, wherein the lamp control data includes first address information, response information and control data, and the response information is used to characterize whether feedback data corresponding to the control data needs to be transmitted to the lamp control device; an information matching unit, configured to match the first address information with pre-stored second address information, wherein the second address information is address information corresponding to the target lamp body; an operation execution unit, configured to, when the first address information matches the second address information, execute a control operation corresponding to the control data based on the response information.
[0014] In a fourth aspect, the present application further provides a computer device, the computer device comprises: one or more processors; a memory; one or more application programs stored in the memory and configured to be executed by the processor to implement the lamp body control method according to any one of the first aspect to the third aspect.
[0015] In a fifth aspect, the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is loaded by a processor, the steps in the lamp body control method according to any one of the first aspect to the third aspect are executed. Effects of the Invention
[0016] In the present application, first address information is matched with pre-stored second address information; when the first address information matches the second address information, a control operation corresponding to control data is executed based on response information. After a lamp control device transmits lamp control data to a plurality of lamp bodies, a target lamp body among the plurality of lamp bodies can determine whether to execute the control operation corresponding to the control data based on the first address information, thereby realizing overall control of the plurality of lamp bodies by one lamp control device. After determining that it is necessary to execute the control operation corresponding to the control data, the control operation corresponding to the control data is executed based on the response information, thereby improving the control accuracy of the lamp bodies. [BRIEF DESCRIPTION OF THE DRAWINGS]
[0017] In order to more clearly explain the technical solution of the embodiments of the present application, the drawings required for the description of the embodiments are briefly described below. Obviously, the drawings described below are merely examples of the embodiments of the present application, and those skilled in the art can conceive other drawings based on these drawings without creative efforts. [Figure 1] It is a flowchart of an embodiment of a lamp body control method according to an embodiment of the present application. [Figure 2] It is a flowchart of a specific embodiment of executing a control operation based on response information according to an embodiment of the present application. [Figure 3] It is a flowchart of a specific embodiment for checking control data according to an embodiment of the present application. [Figure 4] It is a flowchart of another embodiment of a lamp body control method according to an embodiment of the present application. [Figure 5] It is a flowchart of a specific embodiment for determining response information according to an embodiment of the present application. [Figure 6] It is a structural schematic diagram of an embodiment of a lamp body control device according to an embodiment of the present application. [Figure 7] It is a structural schematic diagram of another embodiment of a lamp body control device according to an embodiment of the present application. [Figure 8]This is a schematic diagram of the structure of one embodiment of a computer device according to an embodiment of the present invention. [Modes for carrying out the invention]
[0018] The technical concept of the embodiments of this application will be described clearly and completely below with reference to the drawings of the embodiments of this application. Of course, the embodiments described are only a part of the embodiments of this application, not all of them. Any other embodiments that a person skilled in the art can obtain based on the embodiments of this application without requiring inventive work are all within the scope of protection of this application.
[0019] In the description of this application, it should be understood that the orientations or positional relationships indicated by terms such as "center," "vertical," "horizontal," "length," "width," "thickness," "top," "bottom," "front," "back," "left," "right," "vertical," "horizontal," "top," "bottom," "inside," and "outside" are the orientations or positional relationships shown in the drawings, and are merely for the purpose of making the description of this application easier to understand and simplifying the description. They do not indicate or imply that the device or element being referred to must necessarily have a specific orientation, or that it must be configured and operated in a specific orientation, and therefore should not be understood as limiting this application. Furthermore, the terms "first," "second," and "third" are merely for descriptive purposes and should not be understood as indicating or implying relative importance, or implicitly indicating the number of technical features being referred to. Thus, features limited by "first," "second," and "third" may explicitly or implicitly include one or more of the aforementioned features. In the description of this application, unless specifically and clearly limited, the meaning of "multiple" is two or more.
[0020] In this application, the term “exemplary” is used to mean “an example, illustration, or explanation.” Any embodiment described as “exemplary” in this application is not necessarily construed as being preferable or superior to other embodiments. The following descriptions are made to enable those skilled in the art to implement and use this application. Details are listed in the following descriptions for interpretation. It should be understood that the application can be implemented without using these specific details, as will be understood by those skilled in the art. In other embodiments, known structures and processes are not described in detail to avoid making the description of this application difficult to understand due to unnecessary details. Accordingly, this application is not intended to be limited to the embodiments shown, but rather to the broadest scope that fits the principles and features disclosed herein.
[0021] What needs to be explained is that the methods according to the embodiments of this application are executed in a computer device, and therefore each processing object of the computer device exists in the form of data or information. For example, time is essentially time information, and as can be understood, in order for the computer device to perform processing, if dimensions, numbers, positions, etc. are mentioned in subsequent embodiments, they exist as corresponding data, and a detailed explanation of these is omitted here.
[0022] The inventor's research revealed that various conventional lighting devices can be broadly divided into two types: (1) those with one lamp body and one control box for controlling the lamp, and (2) those in which the lamp body and the control box for controlling the lamp are integrated. Whether there is one lamp body and one control box, or whether the lamp body and the control box for controlling the lamp are integrated, in both cases one lamp control device controls one lamp body. In this way, it is necessary to place one lamp control device for each lamp body, making it difficult to achieve overall control of multiple lamp bodies.
[0023] Based on this, in the embodiment of the present application, lamp control data transmitted from the lamp control device is received, and the lamp control data includes first address information, response information, and control data. The response information is used to characterize whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device. The first address information is matched with pre-stored second address information, and the second address information is the address information corresponding to the target lamp body. If the first address information matches the second address information, a control operation corresponding to the control data is executed based on the response information. In the present application, after the lamp control device transmits lamp control data to multiple lamp bodies, it is possible to determine whether the target lamp body among the multiple lamp bodies will execute a control operation corresponding to the control data based on the first address information. This enables overall control of multiple lamp bodies by a single lamp control device. After determining that it is necessary to execute a control operation corresponding to the control data, the control operation corresponding to the control data is executed based on the response information, thereby improving the control accuracy of the lamp bodies.
[0024] The contents of this application will be further explained below with reference to the drawings and the description of the embodiments.
[0025] This embodiment provides a lamp control method, which is applied to a target lamp in a lamp control system, the lamp control system comprising a lamp control device and a plurality of lamps connected to the lamp control device by communication, the target lamp being one of the plurality of lamps, and as shown in Figure 1, the lamp control method includes the following steps S10 to S30. Step S10 involves receiving lamp control data transmitted from the lamp control device and characterizing whether the lamp control data includes first address information, response information, and control data, and whether the response information needs to transmit feedback data corresponding to the control data to the lamp control device.
[0026] Lamp control data is data transmitted by the lamp control device to the controlled lamp body. In order to achieve overall control of multiple lamp bodies, in this embodiment, one lamp control device is configured to communicate with multiple lamp bodies, and the lamp control device transmits the lamp control data to all lamp bodies. For example, if the lamp control device is communicated with lamp bodies 1, 2, 3, and 4, and it is necessary to adjust the color temperature (CCT, correlated colour temperature) parameters of lamp bodies 1 and 4, the lamp control device will simultaneously transmit CCT setting commands to lamp bodies 1, 2, 3, and 4.
[0027] The lamp control device transmits lamp control data to all lamps, meaning that even lamps that do not need to perform the control operation corresponding to the control data will receive the lamp control data. Therefore, in order to avoid lamps that do not need to perform the control operation corresponding to the control data performing the control operation, this embodiment pre-sets address information corresponding to each lamp, and the address information is a single 32-bit integer type, with each bit corresponding to one lamp. As shown in Table 1, address 0x01 corresponds to lamp 1, address 0x08 corresponds to lamp 4, and so on.
[0028] Table 1: Lamp body address information JPEG0007915308000001.jpg45158
[0029] The lamp control data includes first address information, response information, and control data. The first address information is the address information corresponding to the lamp unit that needs to perform the control operation corresponding to the control data. For example, using Table 1 as an example, if lamp unit 1 and lamp unit 4 need to perform the control operation corresponding to the control data, the first address information is 0x01 and 0x08.
[0030] The control data consists of control commands corresponding to the control operations to be performed. The control data changes according to the differences in the control operations to be performed by the lamp body. For example, the control data may include a timing CCT setting command, a timing temperature data reading command, a real-time CCT setting command, a real-time temperature data reading command, and so on.
[0031] The response information is used to characterize whether it is necessary to send feedback data corresponding to the control data to the lamp control device. The response information changes according to the differences in the control data. For example, if the control data is a timing CCT setting command, the response information is 0, indicating that it is not necessary to send feedback data corresponding to the control data to the lamp control device. If the control data is a timing temperature data reading command, the response information is 1, indicating that it is necessary to send feedback data corresponding to the control data to the lamp control device.
[0032] Step S20: The first address information is matched with the second address information that has been stored in advance, and the second address information is the address information corresponding to the target lamp body.
[0033] The second address information is the address information corresponding to the target lamp body. For example, using Table 1 as an example, if the target lamp body is lamp body 1, the second address information is 0x01, and if the target lamp body is lamp body 3, the second address information is 0x04. In this embodiment, after the target lamp body receives lamp control data transmitted from the lamp control device, it matches the first address information in the lamp control data with the second address information corresponding to itself, thereby determining whether it is necessary to execute the control operation corresponding to the control data.
[0034] Step S30: If the first address information matches the second address information, the control operation corresponding to the control data is executed based on the response information.
[0035] Matching of the first address information with the second address information means that the second address information is included in the first address information. For example, if the first address information is 0x01 and 0x08 and the second address information is 0x01, the first address information matches the second address information. If the first address information is 0x01 and 0x08 and the second address information is 0x04, the first address information does not match the second address information.
[0036] In this embodiment, the first address information is matched with the second address information. If the first address information matches the second address information, the target lamp body is required to perform a control operation corresponding to the control data. In this case, the control operation corresponding to the control data is performed based on the response information. Conversely, if the first address information does not match the second address information, the target lamp body is not required to perform a control operation corresponding to the control data. In this case, the lamp control data is ignored.
[0037] In the specific implementation method, the lamp control data further includes first number information, and as shown in Figure 2, in step S30, the control operation corresponding to the control data is performed based on the response information. Step S31 determines whether it is necessary to send feedback data corresponding to the control data to the lamp control device based on the response information, If it is not necessary to transmit feedback data corresponding to the control data to the lamp control device, step S32 is performed, matching the first number information with the second number information that has been stored in advance, and the second number information is the number information most recently stored on the target lamp body. The procedure includes step S33, which, if the first number information does not match the second number information, performs a control operation corresponding to the control data.
[0038] When the control data is a timing setting command, such as a timing CCT setting command or a timing color mode (Hue-Saturation-Intensity (Lightness), HSI, or HSL) setting command, the lamp control device will transmit the lamp control data to the multiple lamps in at least three separate packets to ensure normal communication between the lamp control device and the multiple lamps. To avoid the lamps repeatedly executing control operations, the lamp control data transmitted by the lamp control device to the lamps in this embodiment further includes a first number information, which is the packet transmission number of the lamp control data.
[0039] The lamp unit receives lamp control data and, after executing all control operations corresponding to the lamp control data, stores the number information in the lamp control data that was just received. The second number information is the number information most recently stored in the target lamp unit, and based on the first and second number information, it is possible to determine whether the target lamp unit executed the control operations corresponding to the lamp control data.
[0040] Specifically, in this embodiment, when executing a control operation corresponding to control data based on response information, first, it is determined whether it is necessary to transmit feedback information corresponding to the control data to the lamp control device based on the response information. If it is not necessary to transmit feedback information corresponding to the control data to the lamp control device, the first number information and the second number information are matched. If the first number information does not match the second number information, it is explained that the control operation corresponding to the control data has never been executed, and in that case, the control operation corresponding to the control data is executed. Conversely, if the first number information matches the second number information, it is explained that the control operation corresponding to the control data has been executed, and in that case, it is not necessary to repeatedly execute the control operation corresponding to the control data.
[0041] In the specific implementation method, in step S31, after determining whether it is necessary to send feedback data corresponding to the control data to the lamp control device based on the response information, If it is necessary to send feedback data corresponding to the control data to the lamp control device, the method further includes step S34, which involves performing a control operation corresponding to the control data and sending feedback data corresponding to the control operation to the lamp control device.
[0042] When the control data is a timing data read / write command, a real-time data read / write command, a real-time setting command, or an upgrade command, it is necessary to send feedback data corresponding to the control data to the lamp control device. At this time, the control operation corresponding to the control data is executed, and feedback data corresponding to the control operation is sent to the lamp control device.
[0043] In a specific implementation method, the control data includes a first setting command and / or a data reading command and / or an upgrade command, and in step S34, a control operation corresponding to the control data is executed, and feedback data corresponding to the control operation is transmitted to the lamp control device. Step S341, which involves executing a first setting operation corresponding to a first setting command and transmitting the setting result corresponding to the first setting operation to a lamp control device, and / or Step S342, which determines the target data based on the data reading command, packages the target data, and transmits the packaged target data to the lamp control device, and / or The procedure includes step S343, which involves performing an upgrade operation based on an upgrade command and transmitting the upgrade result corresponding to the upgrade operation to the lamp control device.
[0044] In a specific implementation, the control data includes at least one of a first setting instruction, a data reading instruction, and an upgrade instruction. The first setting instruction is a user-defined real-time setting instruction, such as a real-time CCT setting instruction or a real-time HIS setting instruction. The data reading instruction may include a first data reading instruction and / or a second data reading instruction. The first data reading instruction is a timing data reading instruction, for example, reading the temperature data of the lamp body every two seconds. The second data reading instruction is a user-defined real-time data reading instruction, for example, a temperature data reading instruction issued by the user to read the temperature data of the lamp body via the lamp control device. The upgrade instruction is an instruction to upgrade the lamp body and is generally a user-defined real-time instruction.
[0045] In a specific implementation method, if the control data includes a first setting command, the step of executing a control operation corresponding to the control data and transmitting feedback data corresponding to the control operation to the lamp control device specifically includes executing a first setting operation corresponding to the first setting command and transmitting the setting result corresponding to the first setting operation to the lamp control device. For example, if the first setting command is a real-time HSI setting command, the target lamp unit adjusts its own color mode based on the control data and transmits the color mode adjustment result to the lamp control device, thereby achieving overall adjustment of the color modes of multiple lamp units.
[0046] In another specific implementation, if the control data includes a data read command, the steps of executing a control operation corresponding to the control data and transmitting feedback data corresponding to the control operation to the lamp control device specifically include determining target data based on the data read command, packaging the target data, and transmitting the packaged target data to the lamp control device. For example, if the control data is a temperature data read command, the system determines that the target data is temperature data, packages the temperature data, and transmits the packaged temperature data to the lamp control device, thereby enabling simultaneous data read operations on multiple lamps.
[0047] In another specific implementation, if the control data includes an upgrade command, the step of executing a control operation corresponding to the control data and transmitting feedback data corresponding to the control operation to the lamp control device specifically includes executing an upgrade operation based on the upgrade command and transmitting the upgrade result corresponding to the upgrade operation to the lamp control device, thereby enabling the control of multiple lamps to be upgraded simultaneously by a single lamp control device, and improving the upgrade efficiency of the lamps.
[0048] In the specific implementation method, the lamp control data further includes protocol header information and a first check code, and as shown in Figure 3, in step S20, before matching the first address information with the pre-stored second address information, Step S40 involves checking the protocol header information and obtaining the first check result, The procedure includes step S50, which, if the first check result passes the check, checks the first check code based on the control data and obtains the second check result.
[0049] To improve the control accuracy of the lamp body, the lamp control data further includes protocol header information and a first check code. Before matching the first address information with the second address information, the protocol header information can be checked to obtain the first check result. If the first check result passes, the first check code is checked based on the control data to obtain the second check result. If the second check result passes, it is explained that the control data received by the target lamp body is complete and accurate, and the first address information is then matched with the second address information. Conversely, if the first check result fails or the second check result fails, it is explained that the control data received by the target lamp body is inaccurate, and in that case, no operation is performed.
[0050] Specifically, the step of checking protocol header information may include calculating the sum of the binary inverted codes for the protocol header information, determining that the protocol header information has passed the check if the result of the obtained sum is a predetermined result, and conversely, determining that the protocol header information has not passed the check if the result of the obtained sum is not a predetermined result. For example, calculating the sum of the binary inverted codes for each 16 bits in the protocol header information, determining that the protocol header information has passed the check if the result of the obtained sum is all 1, and determining that the protocol header information has not passed the check if the result of the sum is not all 1.
[0051] Furthermore, the step of checking the first check code based on control data may specifically include generating a second check code based on the control data and a predetermined check polynomial, matching the second check code with the first check code, determining that the first check code has passed the check if the second check code matches the first check code, and conversely, determining that the first check code has failed the check if the second check code does not match the first check code.
[0052] This embodiment provides a lamp control method, which is applied to a lamp control device in a lamp control system, and the lamp control system comprises a lamp control device and a plurality of lamps that are communicated to the lamp control device, and as shown in Figure 4, the lamp control method includes the following steps M10 to M40. Step M10: The control data and candidate lamp bodies corresponding to the control data are obtained, and the candidate lamp body is at least one of the multiple lamp bodies.
[0053] The control data consists of control commands corresponding to the control operations that the lamp unit should perform. The control data changes according to the differences in the control operations that the lamp unit should perform. For example, the control data may include a timing CCT setting command, a timing temperature data reading command, a real-time CCT setting command, a real-time temperature data reading command, and so on.
[0054] Candidate lamp bodies are those lamp bodies that need to perform control operations corresponding to control data among multiple lamp bodies. For example, if the multiple lamp bodies include lamp body 1, lamp body 2, lamp body 3, and lamp body 4, and lamp body 1 and lamp body 4 need to perform control operations corresponding to control data, then the candidate lamp bodies are lamp body 1 and lamp body 4.
[0055] Step M20 determines the response information corresponding to the control data and characterizes whether the response information needs to transmit feedback data corresponding to the control data to the lamp control device.
[0056] The response information is used to characterize whether it is necessary to send feedback data corresponding to the control data to the lamp control device. In this embodiment, in order to generate lamp control data based on the response information in a subsequent step, the lamp control device obtains the control data and candidate lamps corresponding to the control data, and then determines the response information corresponding to the control data. For example, if the control data is a timing setting command, the response information is determined to be 0, and if the control data is a timing data reading command, a real-time setting command, a real-time data reading command, an upgrade command, etc., the response information is determined to be 1.
[0057] Step M30: Based on the response information and the first address information, control data is packaged to obtain lamp control data, and the first address information is the address information corresponding to the candidate lamp body.
[0058] The first address information is the address information corresponding to the candidate lamp body. For example, if the candidate lamp bodies are lamp body 1 and lamp body 4, as shown in Table 1 above, the first address information is 0x01 and 0x08. In this embodiment, after the lamp control device determines the response information corresponding to the control data, it packages the control data based on the response information and the address information corresponding to the candidate lamp body to obtain lamp control data.
[0059] Step M40: Lamp control data is transmitted to multiple lamp units so that the target lamp unit among the multiple lamp units can perform a control operation corresponding to the control data based on the first address information and response information.
[0060] In this embodiment, the lamp control device acquires lamp control data and then transmits the lamp control data to multiple lamp units. Since the lamp control data includes first address information and response information, the multiple lamp units can receive the lamp control data and then perform control operations corresponding to the control data based on the first address information and response information, thereby achieving overall control of the multiple lamp units.
[0061] In a specific implementation method, as shown in Figure 5, determining the response information corresponding to the control data in step M20 is: Step M21 retrieves the data type of the control data, and if the data type includes a first type and a second type, Step M22 is for determining that the response information corresponding to the control data is first information when the data type is first type, and for characterizing that the first information does not need to transmit feedback data corresponding to the control data to the lamp control device, Step M23, which is for determining that the response information corresponding to the control data is second information, and for characterizing that the second information needs to transmit feedback data corresponding to the control data to the lamp control device, if the data type is second type.
[0062] The data types of control data include Type 1 and Type 2. Type 1 is a data type that does not require the transmission of feedback data corresponding to the control data to the lamp control device, while Type 2 is a data type that requires the transmission of feedback data corresponding to the control data to the lamp control device. The control data may also be a first setting command (real-time setting command), a second setting command (timing setting command), a first data read command (timing data read command), a second data read command (real-time data read command), an upgrade command, etc. If the control data is a first setting command, the data type of the control data is Type 1. If the control data is a second setting command, a first data read command, a second data read command, an upgrade command, etc., the data type of the control data is Type 2.
[0063] The response information includes first information and second information. The first information is used to characterize that it is not necessary to transmit feedback data corresponding to the control data to the lamp control device, while the second information is used to characterize that it is necessary to transmit feedback data corresponding to the control data to the lamp control device. For example, the first information may be 0 and the second information may be 1.
[0064] In this embodiment, when determining the response information corresponding to control data, first, the data type of the control data is obtained. If the data type is of type 1, it is determined that the response information corresponding to the control data is of type 1. If the data type is of type 2, it is determined that the response information corresponding to the control data is of type 2. For example, if the control data is a first setting instruction (real-time setting instruction), it is determined that the response information corresponding to the control data is 0. If the control data is a second setting instruction, it is determined that the response information corresponding to the control data is 1.
[0065] In a specific implementation method, if the control data is the first setting command, then in step M40, the lamp control data is transmitted to multiple lamp units. The process includes step M41, which adds lamp control data to the tail node of a pre-built linking list and transmits node data in the linking list to multiple lamp bodies according to a predetermined first timing time and a predetermined number of times.
[0066] The first setting instruction is a timing setting instruction. When lamp control data is the first setting instruction, when sending lamp control data to multiple lamp units, the lamp control data may be added to the tail node of a pre-constructed single-linked list, and node data in the linked list may be sent to multiple lamp units according to a predetermined first timing time and a predetermined number of times. This embodiment allows lamp control data to be sent via a single-linked list, requested when it needs to be used, and the memory to be released by deleting the content after use is complete, thereby enabling more efficient use of memory.
[0067] In order to ensure that the control data of each packet is sent to multiple ramps according to the principle that whichever triggers it first is sent first, when sending node data in a linked list to multiple ramps, the head node data of the linked list may be sent to multiple ramps based on a predetermined first timing time and a predetermined number of times, then the head node data of the linked list may be deleted and the data after the node moved forward as a whole to replace the head node data, and the steps of sending the head node data of the linked list to multiple ramps may be continued according to a predetermined first timing time and a predetermined number of times until all the node data in the linked list has been sent to multiple ramps. For example, the head node data of the linked list may be sent at a timing of 100 milliseconds and repeated three times, and after the three transmissions the head node data may be deleted and the data after the node moved forward as a whole to replace the head node.
[0068] In a specific implementation method, if the control data includes multiple data sub-items and the multiple data sub-items are different first data read commands, then transmitting the lamp control data to multiple lamp bodies in step M40 is: Step M42 determines the timeout period for each data subitem based on the second timing time for each data subitem, Step M43 involves sorting multiple data sub-items by timeout duration and obtaining the timeout sort result for the multiple data sub-items. The process includes step M44, which sends multiple data sub-items to multiple ramp bodies based on the timeout sort result.
[0069] The first data read command is a timing data read command. If the control data includes multiple data sub-items and these multiple data sub-items are different timing data read commands, first, the second timing time for each data sub-item is obtained, and the timeout time for each data sub-item is determined based on the second timing time. Next, the multiple data sub-items are sorted by timeout based on the timeout time to obtain the timeout sort result for the multiple data sub-items. Finally, the data sub-item with the longest timeout time is determined based on the timeout sort result, and the data sub-item with the longest timeout time is preferentially sent to multiple lamp bodies. For example, if the control data includes a timing temperature read command, a timing rotation speed read command, and a timing error read command, and the timeout sort result is a timing temperature read command, a timing error read command, and a timing rotation speed read command, the timing temperature read command is preferentially sent to multiple lamp bodies.
[0070] To better realize the lamp control method according to the embodiment of the present application, the embodiment of the present application further provides a lamp control device based on the lamp control method, the lamp control device is applied to a target lamp in a lamp control system, the lamp control system comprises a lamp control device and a plurality of lamps connected to the lamp control device by communication, the target lamp is one of the plurality of lamps, and as shown in Figure 6, the lamp control device 600 is A data receiving unit 601 is for receiving lamp control data transmitted from a lamp control device, and the lamp control data includes first address information, response information and control data, and the response information is for characterizing whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device. This is for matching the first address information with the second address information which is stored in advance, and the second address information is the address information which corresponds to the target lamp body, and the information matching unit 602 The system includes an operation execution unit 603 for executing a control operation corresponding to the control data based on the response information when the first address information matches the second address information.
[0071] In the embodiment of the present invention, first address information is matched with pre-stored second address information. If the first address information matches the second address information, a control operation corresponding to the control data is executed based on the response information. After the lamp control device transmits the lamp control data to multiple lamp bodies, it is possible to determine whether the target lamp body among the multiple lamp bodies will execute the control operation corresponding to the control data based on the first address information. This enables overall control of multiple lamp bodies by a single lamp control device. After determining that it is necessary to execute the control operation corresponding to the control data, the control operation corresponding to the control data is executed based on the response information, thereby improving the control accuracy of the lamp bodies.
[0072] In some embodiments of the present application, the lamp control data further includes first number information, and the operation execution unit 603 specifically, Based on the response information, it is determined whether it is necessary to send feedback data corresponding to the control data to the lamp control device. If it is not necessary to transmit feedback data corresponding to the control data to the lamp control device, the first number information is matched with the second number information that has been stored in advance, and the second number information is the number information most recently stored on the target lamp body. This is used to execute a control operation corresponding to the control data when the first number information does not match the second number information.
[0073] In some embodiments of the present application, the operation execution unit 603 specifically further: This system is designed to execute a control operation corresponding to the control data and to transmit feedback data corresponding to the control operation to the lamp control device when it is necessary to send feedback data corresponding to the control data to the lamp control device.
[0074] In some embodiments of the present application, the control data includes a first setting command and / or a data reading command and / or an upgrade command, and the operation execution unit 603 specifically further, The first setting operation corresponding to the first setting command is executed, and the setting result corresponding to the first setting operation is transmitted to the lamp control device. and / or, Based on the data reading command, the target data is determined, the target data is packaged, and the packaged target data is transmitted to the lamp control device. and / or, This device is used to execute an upgrade operation based on an upgrade command and to transmit the upgrade result corresponding to the upgrade operation to the lamp control device.
[0075] In some embodiments of the present application, the lamp control data further includes protocol header information and a first check code, and the lamp control device 600 A first check unit checks the protocol header information to obtain the first check result, The system further includes a second check unit for obtaining a second check result by checking the first check code based on control data if the first check result passes the check.
[0076] To better realize the lamp control method according to the embodiment of the present application, the embodiment of the present application further provides a lamp control device based on the lamp control method, the lamp control device is applied to the lamp control device in a lamp control system, the lamp control system comprises a lamp control device and a plurality of lamps connected to the lamp control device by communication, and as shown in Figure 7, the lamp control device 700 is This is for acquiring control data and candidate lamp bodies corresponding to the control data, and the data acquisition unit 701 is such that the candidate lamp body is at least one lamp body from among a plurality of lamp bodies, An information determination unit 702 is for determining response information corresponding to control data, and for characterizing whether the response information needs to transmit feedback data corresponding to the control data to the lamp control device, This system packages control data based on response information and first address information to acquire lamp control data, and includes a data packaging unit 703 in which the first address information is address information corresponding to a candidate lamp body, The system includes a data transmission unit 704 for transmitting lamp control data to multiple lamp bodies in order for a target lamp body among multiple lamp bodies to perform a control operation corresponding to the control data based on first address information and response information.
[0077] In some embodiments of the present application, the information determination unit 702 specifically, The data type of the control data is obtained, and the data type includes both Type 1 and Type 2. When the data type is of type 1, it is determined that the response information corresponding to the control data is type 1, and the purpose is to characterize that there is no need to transmit feedback data corresponding to the control data to the lamp control device. When the data type is of type 2, it is used to determine that the response information corresponding to the control data is type 2 information, and to characterize that the type 2 information needs to transmit feedback data corresponding to the control data to the lamp control device.
[0078] In some embodiments of the present application, when the control data is a first setting command, the data transmission unit 704 specifically: This system adds lamp control data to the tail node of a pre-built linking list and transmits node data from the linking list to multiple lamp units according to a predetermined first timing time and a predetermined number of times.
[0079] In some embodiments of the present application, when the control data includes a plurality of data sub-items and the plurality of data sub-items are different first data read commands, the data transmission unit 704 specifically: Based on the second timing time for each data subitem, the timeout time for each data subitem is determined. Sort multiple data subitems by timeout duration to obtain the timeout sort result for the multiple data subitems. This is for sending multiple data sub-items to multiple ramps based on the timeout sort result.
[0080] Embodiments of the present application further provide a computer device, wherein one of the lamp control devices according to embodiments of the present application is integrated into the computer device, and the computer device is One or more processors, Memory and The system includes one or more application programs stored in memory and configured by a processor to execute steps in a lamp control method according to any one embodiment of the above-described lamp control method.
[0081] The embodiments of the present application further provide a computer device in which one of the lamp control devices according to the embodiments of the present application is integrated. Figure 8 shows a schematic diagram of the structure of the computer device according to the embodiments of the present application, specifically, The computer device may include components such as one or more processors 801 as processing cores, one or more memory 802 as computer-readable storage media, a power supply 803, and an input unit 804. As those skilled in the art will understand, the structure of the computer device shown in Figure 8 is not limiting to the computer device, and may include more or fewer components than shown, or may be arranged in combination of several or different components.
[0082] Of these, The processor 801 is the control center of the computer device, connecting all parts of the computer device using various interfaces and circuits, operating or executing software programs and / or modules stored in memory 802, and retrieving data stored in memory 802, thereby executing various functions and processing data of the computer device and thus monitoring the computer device as a whole. Optionally, the processor 801 may include one or more processing cores, and preferably, an application processor and a modem processor may be integrated into the processor 801, with the application processor mainly handling the operating system, user interface, and application programs, etc., and the modem processor mainly handling wireless communication. As understood, the modem processor does not necessarily have to be integrated into the processor 801.
[0083] Memory 802 may be for storing software programs and modules, and the processor 801 executes various functional applications and data processing by operating the software programs and modules stored in memory 802. Memory 802 may mainly include a storage program area and a storage data area, the storage program area may store an operating system, application programs necessary for at least one function (e.g., audio playback function, image playback function, etc.), and the storage data area may store data created in accordance with the use of the computer device. Memory 802 may also include high-speed random access memory, and may further include non-volatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device. Correspondingly, memory 802 may further include a memory controller to provide the processor 801 with access to memory 802.
[0084] The computer device further includes a power supply 803 for supplying power to each component, and preferably the power supply 803 may be logically connected to the processor 801 by a power management system, thereby enabling functions such as charging, discharging, and power consumption management by the power management system. The power supply 803 may further include any components such as one or more DC or AC power supplies, a recharging system, a power fault detection circuit, a power strip or inverter, and a power status indicator.
[0085] The computer device may further include an input unit 804, which may receive input numerical or character information and generate signal inputs for a keyboard, mouse, lever, optical or trackball related to user settings and function control.
[0086] Although not shown in the diagram, the computer device may include a display unit and the like, but a detailed explanation is omitted here. Specifically, in this embodiment, the processor 801 in the computer device is An instruction that receives lamp control data transmitted from a lamp control device and characterizes whether the lamp control data includes first address information, response information, and control data, and whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device. A command that matches the first address information with the second address information stored in advance, and where the second address information is the address information corresponding to the target lamp body, and When the first address information matches the second address information, various functions are realized by loading executable files corresponding to the processes of one or more application programs into memory 802 according to an instruction that executes a control operation corresponding to the control data based on the response information, and by having the processor 801 operate the application programs stored in memory 802.
[0087] As those skilled in the art will understand, all or some of the steps in the various methods of the above embodiments may be completed by instructions or by hardware related to instruction control, the instructions may be stored in a computer-readable storage medium and loaded and executed by a processor.
[0088] To this end, embodiments of the present application provide a computer-readable storage medium, which may include read-only memory (ROM), random access memory (RAM), a magnetic disk, or an optical disk. A computer program is stored in the computer-readable storage medium, and the computer program is loaded by a processor to perform a step in any one of the lamp control methods according to embodiments of the present application. For example, when the computer program is loaded by the processor, The step involves receiving lamp control data transmitted from a lamp control device, and characterizing whether the lamp control data includes first address information, response information, and control data, and whether the response information needs to transmit feedback data corresponding to the control data to the lamp control device. The first address information is matched with a pre-stored second address information, and the second address information is the address information corresponding to the target lamp body. If the first address information matches the second address information, the following steps can be performed: execute a control operation corresponding to the control data based on the response information.
[0089] In the embodiments described above, each embodiment focuses on different aspects. Therefore, for parts that are not explained in detail in one embodiment, you may refer to the detailed descriptions of the other embodiments above, and a detailed explanation will be omitted here.
[0090] When implemented in practice, each of the above units or structures may be realized as an independent entity, or they may be arbitrarily combined to be realized as the same or several entities, and specific implementations of each of the above units or structures may be shown by referring to the above-described embodiment of the method, and a detailed explanation is omitted here.
[0091] The specific implementation of each of the above operations may be shown in the above examples, and a detailed explanation is omitted here.
[0092] The above describes in detail the lamp control method, apparatus, computer apparatus, and storage medium according to the embodiments of the present application. While the principles and embodiments of the present application have been explained in this specification using specific individual examples, the above descriptions of embodiments are merely intended to facilitate understanding of the method and its core concept. At the same time, those skilled in the art will recognize that there have been changes in terms of specific embodiments and scope of application based on the concept of the present application. In short, the contents of this specification should not be understood as limiting the present application.
Claims
1. A lamp control method applicable to a target lamp in a lamp control system, wherein the lamp control system comprises a lamp control device and a plurality of lamps connected to the lamp control device by communication, and the target lamp is one of the plurality of lamps, The lamp control data transmitted from the lamp control device is received, and the lamp control data includes first address information, response information, and control data, and the response information is for characterizing whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device, wherein the control data includes one or more of the following: timing CCT setting command, timing temperature data reading command, real-time CCT setting command, and real-time temperature data reading command, and the response information changes according to the differences in the control data. The first address information is matched with the second address information stored in advance, and it is determined that the second address information corresponds to the address information of the target lamp body. A lamp control method characterized by including the following: when the first address information matches the second address information, a control operation corresponding to the control data is executed based on the response information, and the first address information matching the second address information means that the first address information includes the second address information.
2. The lamp control data further includes first number information, and the control operation corresponding to the control data is performed based on the response information. Based on the response information, it is determined whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device. If it is not necessary to transmit feedback data corresponding to the control data to the lamp control device, the first number information is matched with the second number information stored in advance, and it is determined that the second number information is the number information most recently stored in the target lamp body. The lamp control method according to claim 1, further comprising: if the first number information does not match the second number information, executing a control operation corresponding to the control data.
3. After determining whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device based on the response information, The lamp control method according to claim 2, characterized in that, when it is necessary to transmit feedback data corresponding to the control data to the lamp control device, the method includes executing a control operation corresponding to the control data and transmitting feedback data corresponding to the control operation to the lamp control device.
4. The control data includes a first setting command and / or a data reading command and / or an upgrade command, and the control device executes a control operation corresponding to the control data and transmits feedback data corresponding to the control operation to the lamp control device. The lamp control device executes a first setting operation corresponding to the first setting command and transmits the setting result corresponding to the first setting operation. and / or, Based on the data reading command, the target data is determined, the target data is packaged, and the packaged target data is transmitted to the lamp control device. and / or, The lamp control method according to claim 3, characterized in that it includes performing an upgrade operation based on the upgrade command and transmitting the upgrade result corresponding to the upgrade operation to the lamp control device.
5. The lamp control data further includes protocol header information and a first check code, and before matching the first address information with the second address information stored in advance, The protocol header information is checked to obtain the first check result, The lamp control method according to claim 1, characterized in that, if the first check result passes the check, the first check code is checked based on the control data to obtain a second check result.
6. A lamp control method, The lamp control device in a lamp control system comprises the lamp control device and a plurality of lamps connected to the lamp control device via communication, and the lamp control method is The control data and candidate lamp bodies corresponding to the control data are acquired, the candidate lamp body is at least one of the plurality of lamp bodies, and the control data includes one or more of the following: timing CCT setting command, timing temperature data reading command, real-time CCT setting command, and real-time temperature data reading command. This is for determining response information corresponding to the control data and characterizing whether the response information needs to transmit feedback data corresponding to the control data to the lamp control device, wherein the response information changes according to the differences in the control data, Based on the response information and the first address information, the control data is packaged to obtain lamp control data, and the first address information is the address information corresponding to the candidate lamp body. A lamp control method characterized by including transmitting the lamp control data to the plurality of lamps so that a target lamp among the plurality of lamps can perform a control operation corresponding to the control data based on the first address information and the response information.
7. Determining the response information corresponding to the aforementioned control data is: The data type of the control data is obtained, and the data type includes a first type and a second type. When the data type is of the first type, it is determined that the response information corresponding to the control data is first information, and the first information is characterized in that it is not necessary to transmit feedback data corresponding to the control data to the lamp control device. The lamp control method according to claim 6, further comprising: determining that the response information corresponding to the control data is second information when the data type is second type; and characterizing that the second information needs to transmit feedback data corresponding to the control data to the lamp control device.
8. If the control data is a first setting command, transmitting the lamp control data to the plurality of lamp bodies means that This includes adding the lamp control data to the tail node of a pre-constructed linking list, and transmitting the node data in the linking list to the plurality of lamp bodies according to a predetermined first timing time and a predetermined number of times. If the control data includes multiple data sub-items and the multiple data sub-items are different first data read commands, then transmitting the lamp control data to the multiple lamp bodies is: The timeout period for each data sub-item is determined based on the second timing time of each data sub-item, The process involves sorting the multiple data sub-items by timeout based on the aforementioned timeout period, and obtaining the timeout sort result of the multiple data sub-items. The lamp control method according to claim 6, characterized in that it includes transmitting the plurality of data sub-items to the plurality of lamp bodies based on the timeout sort result.
9. A lamp control device, Applicable to a target lamp in a lamp control system, the lamp control system comprises a lamp control device and a plurality of lamps connected to the lamp control device via communication, the target lamp is one of the plurality of lamps, and the lamp control device is This is for receiving lamp control data transmitted from the lamp control device, wherein the lamp control data includes first address information, response information, and control data, and the response information is used to characterize whether it is necessary to transmit feedback data corresponding to the control data to the lamp control device, wherein the control data includes one or more of the following: timing CCT setting command, timing temperature data reading command, real-time CCT setting command, and real-time temperature data reading command, and the response information changes according to the differences in the control data, and This is for matching the first address information with a second address information that has been stored in advance, and the second address information is the address information corresponding to the target lamp body, A lamp control device comprising: an operation execution unit that, when the first address information matches the second address information, executes a control operation corresponding to the control data based on the response information, wherein the matching of the first address information with the second address information means that the first address information includes the second address information.
10. A computer device, the computer device, One or more processors, Memory and A computer device comprising one or more application programs stored in the memory and configured to be executed by the processor in order to implement the lamp control method described in any one of claims 1 to 8.
11. A computer-readable storage medium, A computer-readable storage medium characterized in that it stores a computer program, and the computer program is loaded by a processor to perform the steps in the lamp control method described in any one of claims 1 to 8.
Citation Information
Patent Citations
Programmable system for controlling a plurality of distributed electrical loads
EP0038852B1