CN113382512A - Real-time control method and device for lamp strip and storage medium - Google Patents

Real-time control method and device for lamp strip and storage medium Download PDF

Info

Publication number
CN113382512A
CN113382512A CN202110677340.8A CN202110677340A CN113382512A CN 113382512 A CN113382512 A CN 113382512A CN 202110677340 A CN202110677340 A CN 202110677340A CN 113382512 A CN113382512 A CN 113382512A
Authority
CN
China
Prior art keywords
color
contact
real
contact path
time control
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110677340.8A
Other languages
Chinese (zh)
Other versions
CN113382512B (en
Inventor
王妙玉
周亮
王庆进
吴宁泉
郭媛媛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Hotata Smart Home Co Ltd
Original Assignee
Guangdong Hotata Smart Home Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Hotata Smart Home Co Ltd filed Critical Guangdong Hotata Smart Home Co Ltd
Priority to CN202110677340.8A priority Critical patent/CN113382512B/en
Publication of CN113382512A publication Critical patent/CN113382512A/en
Application granted granted Critical
Publication of CN113382512B publication Critical patent/CN113382512B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H05ELECTRIC TECHNIQUES NOT OTHERWISE PROVIDED FOR
    • H05BELECTRIC HEATING; ELECTRIC LIGHT SOURCES NOT OTHERWISE PROVIDED FOR; CIRCUIT ARRANGEMENTS FOR ELECTRIC LIGHT SOURCES, IN GENERAL
    • H05B47/00Circuit arrangements for operating light sources in general, i.e. where the type of light source is not relevant
    • H05B47/10Controlling the light source
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02BCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO BUILDINGS, e.g. HOUSING, HOUSE APPLIANCES OR RELATED END-USER APPLICATIONS
    • Y02B20/00Energy efficient lighting technologies, e.g. halogen lamps or gas discharge lamps
    • Y02B20/40Control techniques providing energy savings, e.g. smart controller or presence detection

Landscapes

  • Circuit Arrangement For Electric Light Sources In General (AREA)

Abstract

The invention discloses a real-time control method, equipment and a storage medium of a lamp belt, wherein the control method comprises the steps of receiving a touch instruction, determining a contact path generated by a contact moving on a color disc according to the touch instruction, and judging whether the contact moving on the color disc meets a trigger condition or not according to the contact path; and if the movement of the contact meets the trigger condition, generating a corresponding color switching instruction according to the contact path, and sending the color switching instruction to the specified lamp band equipment so that the lamp band equipment is switched to the corresponding color according to the color switching instruction. According to the invention, a user can adjust the color of the lamp strip in real time through the color disc, meanwhile, the user needs to judge whether the generated contact path meets the triggering condition when the color disc touches and slides, and the color of the lamp strip can be updated under the condition that the triggering condition is met, so that the problem of equipment loss caused by too fast color change of lamp strip equipment is avoided.

Description

Real-time control method and device for lamp strip and storage medium
Technical Field
The invention relates to the field of intelligent household appliance control, in particular to a real-time control method, real-time control equipment and a real-time control storage medium for a lamp strip.
Background
For the traditional household lamp strip, only three colors of white light, warm light and warm white are provided, the switch of the three colors is controlled through the switch, for the new generation lamp strip, the lamp strip not only has the white light, the warm light and the warm white, but also has the color light and can control the brightness of the lamp strip, the color of the lamp strip is changed by setting different brightness values, color temperature values and HSV values, and the desired effect is displayed.
The lamp area control that has now generally is that the user touches lamp area adjusting device gently, even the user touches lamp area adjusting device carelessly, and the colour will be switched immediately in the lamp area, and this can lead to lamp area colour change too fast, causes the equipment loss.
Disclosure of Invention
In order to overcome the defects of the prior art, one of the objectives of the present invention is to provide a real-time control method for a light strip, which solves the problem of excessive device loss caused by too fast color change of the light strip.
Another object of the present invention is to provide an electronic device.
It is a further object of the present invention to provide a storage medium.
One of the purposes of the invention is realized by adopting the following technical scheme:
a real-time control method of a lamp strip comprises the following steps:
receiving a touch instruction, determining a contact path generated by the movement of a contact on the color disc according to the touch instruction, and judging whether the movement of the contact on the color disc meets a trigger condition or not according to the contact path;
and if the movement of the contact meets the trigger condition, generating a corresponding color switching instruction according to the contact path, and sending the color switching instruction to the specified lamp band equipment so that the lamp band equipment is switched to the corresponding color according to the color switching instruction.
Furthermore, a plurality of color area blocks are uniformly distributed on the color disc, and transition is performed between the different color area blocks in a color gradient mode to enable the color disc to be in a color changing ring state.
Further, the method for judging whether the contact path meets the trigger condition includes:
identifying initial coordinates and end coordinates in the contact path;
and calculating the moving amplitude of the contact in the longitudinal axis direction of the color disc according to the initial coordinate and the end point coordinate of the contact, judging whether the moving amplitude is larger than a preset ratio or not, and if so, meeting the triggering condition.
Further, the method for judging whether the contact path meets the trigger condition includes:
and judging whether the residence time of the contact in any coordinate in the contact path exceeds the preset time, if so, meeting the triggering condition.
Further, the method for generating the corresponding color switching instruction according to the touch point path comprises the following steps:
acquiring RGB color values of colors corresponding to terminal coordinates of contacts in a contact path;
and converting the RGB color value into a corresponding HSV value, generating a switching instruction according to the HSV value, and sending the switching instruction to the specified lamp band equipment to directly switch the lamp band equipment to the color corresponding to the terminal coordinate.
Further, the method for generating the corresponding color switching instruction according to the touch point path comprises the following steps:
and recording and storing RGB color values corresponding to all coordinates in the contact path, calling and storing the RGB values of all coordinates after meeting a triggering condition, converting the RGB values into HSV values, generating a corresponding switching instruction according to the HSV values, and sending the switching instruction to the specified lamp strip equipment, so that the lamp strip equipment executes corresponding color continuous switching operation according to the contact path to realize a color gradient effect.
Further, the method for generating the corresponding color switching instruction according to the touch point path comprises the following steps:
before receiving the end point coordinates of the contact path, identifying the current coordinates of the contact on the color disc, and acquiring RGB color values corresponding to real-time coordinates;
and converting the RGB color value corresponding to the real-time coordinate into a corresponding HSV value, encrypting the HSV value to form a switching instruction, and sending the switching instruction to the specified lamp band equipment.
Further, before receiving the touch instruction, the method further includes:
receiving a setting instruction, and carrying out user-defined setting on the triggering condition and the color switching mode of the lamp strip equipment after the triggering condition is met according to the setting instruction.
The second purpose of the invention is realized by adopting the following technical scheme:
an electronic device comprises a processor, a memory and a computer program which is stored on the memory and can run on the processor, wherein the processor realizes the real-time control method of the light strip when executing the computer program.
The third purpose of the invention is realized by adopting the following technical scheme:
a storage medium having stored thereon a computer program which, when executed, implements the method of real-time control of a light strip as described above.
Compared with the prior art, the invention has the beneficial effects that:
the user accessible color wheel adjusts the colour in lamp area in real time, and the user need judge whether the contact route that generates satisfies the trigger condition when the color wheel touches, slides simultaneously, just can update lamp area colour under the condition that satisfies the trigger condition, avoids because lamp area equipment colour changes the problem that causes the equipment loss too fast.
Drawings
Fig. 1 is a schematic flow chart of a real-time control method of a light band according to the present invention;
fig. 2 is a schematic diagram illustrating an example of a control method according to an embodiment of the invention.
Detailed Description
The present invention will be further described with reference to the accompanying drawings and the detailed description, and it should be noted that any combination of the embodiments or technical features described below can be used to form a new embodiment without conflict.
Example one
The embodiment provides a real-time control method of a lamp band, which is applied to a server and lamp band devices, wherein a plurality of lamp band devices can be connected with the server through a wireless or wired network, and a user can be connected with the server through a client on a terminal device, so that the purpose of adjusting the color of the lamp band devices in real time by the user is achieved.
As shown in fig. 1, the real-time control method for a light strip in this embodiment specifically includes the following steps:
step S1: receiving a touch instruction, determining a contact path generated by the movement of a contact on the color disc according to the touch instruction, and judging whether the movement of the contact on the color disc meets a trigger condition or not according to the contact path;
step S2: and if the movement of the contact meets the trigger condition, generating a corresponding color switching instruction according to the contact path, and sending the color switching instruction to the specified lamp band equipment so that the lamp band equipment is switched to the corresponding color according to the color switching instruction.
The client of the embodiment presents the color wheel for adjusting the color of the lamp strip, the color wheel is evenly provided with a plurality of color zone blocks, different color zone blocks correspond to different colors, and the color wheel presents a color-changing ring state by transition in a color gradient mode between the different color zone blocks. In this embodiment, the color wheel is shown in RGB, where RGB is composed of seven colors, that is, R, RG, G, GB, B, BR, and R, and their corresponding binary color values are 0xfffff 0000, 0xfffff 00FF, 0xFF0000FF, 0xFF00FFFF, 0xFF00FF00, 0 xfffffff 00, and 0xfffff 0000, and the gradient color ring on the color wheel is a result of comprehensively drawing the seven colors and black and white gradients.
After the user binds the corresponding lamp area equipment through the client, the color of the lamp area equipment can be adjusted in real time through the color disc. The user can click or slide touch on the color wheel, and this embodiment can judge the contact route that user operation produced, and whether decide to send switching instruction to lamp area equipment according to the judged result again.
In this embodiment, a touch point path is generated when a user operates on the color wheel, and a complete touch point path is a position through which the finger moves from the time when the user finger starts touching the color wheel to the time when the user finger leaves the color wheel, where the touch point path includes an initial coordinate, an end point coordinate, and a coordinate through which the finger moves, and the end point coordinate is fixed. The incomplete touch point path is that the user finger stays on the color disc all the time and does not leave the color disc, and in this case, the position where the finger stays last is the end point coordinate of the touch point path, and only the end point coordinate can be updated at any time according to the movement of the user finger.
In this embodiment, the method for determining whether the contact path meets the trigger condition may be:
after receiving a touch point path generated by operation of a user on a color disc, identifying initial coordinates and end coordinates in the touch point path;
and calculating the moving amplitude of the contact in the longitudinal axis direction of the color wheel according to the initial coordinate and the end point coordinate of the contact, judging whether the moving amplitude is larger than a preset ratio, if so, meeting a triggering condition, otherwise, not meeting the triggering condition, and not executing subsequent lamp strip color switching operation.
In addition, the method for judging whether the contact path meets the trigger condition may further include:
and judging whether the residence time of the contact in any coordinate in the contact path exceeds the preset time, if so, meeting the triggering condition, and if not, not meeting the triggering condition.
The trigger condition of this embodiment can be set up in the client in advance, and in addition, the user can set up trigger condition in the client, still can carry out the custom setting to the colour switching mode of lamp area.
The color switching mode of the light strip in this embodiment includes the following situations:
acquiring RGB color values of colors corresponding to terminal coordinates of contacts in a contact path;
the RGB color values are converted into corresponding HSV values, a switching instruction is generated according to the HSV values and is sent to the specified lamp band device, so that the lamp band device is directly switched to the color corresponding to the destination coordinate, and the lamp band device is directly switched to the color corresponding to the destination coordinate.
In addition, the method for switching the lamp strip color switching mode can also be used for acquiring the color corresponding to the initial position of the contact by acquiring the initial coordinate of the contact in the contact path and calculating the HSV value of the current color; and then calculating the color corresponding to the current position of the contact after the contact moves by the corresponding amplitude according to the moving amplitude of the contact, converting the RGB color value of the current color into a corresponding HSV value after confirming the RGB color value, generating a switching instruction according to the HSV value, sending the switching instruction to the specified lamp band device, directly switching the lamp band device to the color corresponding to the terminal coordinate, and switching the color of the lamp band device according to the moving amplitude.
The method for switching the color switching mode of the lamp strip may further include: and recording and storing RGB color values corresponding to all coordinates in the contact path, calling and storing the RGB values of all coordinates after meeting a triggering condition, converting the RGB values into HSV values, generating a corresponding switching instruction according to the HSV values, and sending the switching instruction to the specified lamp strip equipment, so that the lamp strip equipment executes corresponding color continuous switching operation according to the contact path to realize a color gradient effect, and the lamp strip can sequentially switch colors according to the colors passed by the contact path.
When the touch point path is incomplete, that is, a user finger always stays on the color wheel and does not leave the color wheel, the method for switching the color of the lamp strip may be that if the triggering condition is met before the end point coordinate of the touch point path is received, the current coordinate of the touch point on the color wheel is identified, and the RGB color value corresponding to the real-time coordinate is obtained; the RGB color values corresponding to the real-time coordinates are converted into corresponding HSV values, and the HSV values are encrypted to form a switching instruction to be sent to the specified lamp strip equipment, so that the colors of the lamp strip can be changed in real time along with the positions of the contacts.
For example: as shown in fig. 2, a user slides a color palette in the color palette of the client, a corresponding contact path is generated through sliding operation, whether the sliding amplitude of the contact path is greater than 5% of a preset value is judged according to the contact path, if yes, the RGB color value corresponding to the current position of the finger of the user is converted into an HSV value which can be identified by the light strip, the HSV value is reported to the server as a switching instruction, the HSV value is stored by the server after being received by the server and is sent to the light strip device connected with the server, the light strip device updates the color of the light after searching for the HSV value, so that the color switching effect of the light strip device is realized, and whether a trigger condition is met is judged according to the sliding amplitude, so that the problem that the device is lost due to color switching when the light strip touches the color palette carelessly by the user is solved.
Example two
The embodiment provides an electronic device, which includes a processor, a memory, and a computer program stored in the memory and capable of running on the processor, wherein the processor implements the real-time control method of the light strip in the first embodiment when executing the computer program; in addition, the present embodiment also provides a storage medium, on which a computer program is stored, and when the computer program is executed, the method for controlling the light strip in real time is implemented.
The apparatus and the storage medium in this embodiment are based on two aspects of the same inventive concept, and the method implementation process has been described in detail in the foregoing, so that those skilled in the art can clearly understand the structure and implementation process of the system in this embodiment according to the foregoing description, and for the sake of brevity of the description, details are not repeated here.
The above embodiments are only preferred embodiments of the present invention, and the protection scope of the present invention is not limited thereby, and any insubstantial changes and substitutions made by those skilled in the art based on the present invention are within the protection scope of the present invention.

Claims (10)

1. A real-time control method of a lamp strip is characterized by comprising the following steps:
receiving a touch instruction, determining a contact path generated by the movement of a contact on the color disc according to the touch instruction, and judging whether the movement of the contact on the color disc meets a trigger condition or not according to the contact path;
and if the movement of the contact meets the trigger condition, generating a corresponding color switching instruction according to the contact path, and sending the color switching instruction to the specified lamp band equipment so that the lamp band equipment is switched to the corresponding color according to the color switching instruction.
2. The real-time control method for the light strip according to claim 1, wherein the color wheel is divided into a plurality of color area blocks, and the color area blocks of different colors are transited in a color gradient manner to make the color wheel in a color-changing ring state.
3. The real-time control method for the light strip according to claim 1, wherein the method for judging whether the contact path meets the trigger condition is as follows:
identifying initial coordinates and end coordinates in the contact path;
and calculating the moving amplitude of the contact in the longitudinal axis direction of the color disc according to the initial coordinate and the end point coordinate of the contact, judging whether the moving amplitude is larger than a preset ratio or not, and if so, meeting the triggering condition.
4. The real-time control method for the light strip according to claim 1, wherein the method for judging whether the contact path meets the trigger condition is as follows:
and judging whether the residence time of the contact in any coordinate in the contact path exceeds the preset time, if so, meeting the triggering condition.
5. A method for real-time control of a light strip according to claim 1, wherein the method for generating a corresponding color switching command according to the contact path comprises:
acquiring RGB color values of colors corresponding to terminal coordinates of contacts in a contact path;
and converting the RGB color value into a corresponding HSV value, generating a switching instruction according to the HSV value, and sending the switching instruction to the specified lamp band equipment to directly switch the lamp band equipment to the color corresponding to the terminal coordinate.
6. A method for real-time control of a light strip according to claim 1, wherein the method for generating a corresponding color switching command according to the contact path comprises:
and recording and storing RGB color values corresponding to all coordinates in the contact path, calling and storing the RGB values of all coordinates after meeting a triggering condition, converting the RGB values into HSV values, generating a corresponding switching instruction according to the HSV values, and sending the switching instruction to the specified lamp strip equipment, so that the lamp strip equipment executes corresponding color continuous switching operation according to the contact path to realize a color gradient effect.
7. A method for real-time control of a light strip according to claim 1, wherein the method for generating a corresponding color switching command according to the contact path comprises:
before receiving the end point coordinates of the contact path, identifying the current coordinates of the contact on the color disc, and acquiring RGB color values corresponding to real-time coordinates;
and converting the RGB color value corresponding to the real-time coordinate into a corresponding HSV value, encrypting the HSV value to form a switching instruction, and sending the switching instruction to the specified lamp band equipment.
8. The real-time control method for the light strip according to claim 1, before receiving the touch instruction, further comprising:
receiving a setting instruction, and carrying out user-defined setting on the triggering condition and the color switching mode of the lamp strip equipment after the triggering condition is met according to the setting instruction.
9. An electronic device, comprising a processor, a memory, and a computer program stored in the memory and operable on the processor, wherein the processor implements the real-time control method of the light strip according to any one of claims 1 to 8 when executing the computer program.
10. A storage medium having stored thereon a computer program which, when executed, implements a method of real-time control of a light strip according to any of claims 1 to 8.
CN202110677340.8A 2021-06-18 2021-06-18 Real-time control method and device for lamp strip and storage medium Active CN113382512B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110677340.8A CN113382512B (en) 2021-06-18 2021-06-18 Real-time control method and device for lamp strip and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110677340.8A CN113382512B (en) 2021-06-18 2021-06-18 Real-time control method and device for lamp strip and storage medium

Publications (2)

Publication Number Publication Date
CN113382512A true CN113382512A (en) 2021-09-10
CN113382512B CN113382512B (en) 2023-01-06

Family

ID=77577537

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110677340.8A Active CN113382512B (en) 2021-06-18 2021-06-18 Real-time control method and device for lamp strip and storage medium

Country Status (1)

Country Link
CN (1) CN113382512B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116321610A (en) * 2023-05-19 2023-06-23 宏泰智能科技(东莞)有限公司 Intelligent light control method and control system

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103133916A (en) * 2011-11-24 2013-06-05 隆达电子股份有限公司 Light source adjusting device and light source system thereof
CN103152942A (en) * 2013-02-27 2013-06-12 上舜照明(中国)有限公司 Intelligently controlled LED (light-emitting diode) desk lamp and control method thereof
KR20160016116A (en) * 2014-08-04 2016-02-15 현대중공업 주식회사 Lighting control system based on touch screen
US20160088708A1 (en) * 2014-09-18 2016-03-24 Osram Sylvania Inc. Wireless control of lighting systems
CN108901107A (en) * 2018-06-25 2018-11-27 常州星宇车灯股份有限公司 A kind of car atmosphere lamp control system and its control method
CN111935885A (en) * 2020-07-16 2020-11-13 广东科徕尼智能科技有限公司 Linkage control method, equipment and storage medium for terminal and equipment light color
CN213040520U (en) * 2020-09-16 2021-04-23 佛山市毅丰电器实业有限公司 Multifunctional color disc and lamp

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103133916A (en) * 2011-11-24 2013-06-05 隆达电子股份有限公司 Light source adjusting device and light source system thereof
CN103152942A (en) * 2013-02-27 2013-06-12 上舜照明(中国)有限公司 Intelligently controlled LED (light-emitting diode) desk lamp and control method thereof
KR20160016116A (en) * 2014-08-04 2016-02-15 현대중공업 주식회사 Lighting control system based on touch screen
US20160088708A1 (en) * 2014-09-18 2016-03-24 Osram Sylvania Inc. Wireless control of lighting systems
CN108901107A (en) * 2018-06-25 2018-11-27 常州星宇车灯股份有限公司 A kind of car atmosphere lamp control system and its control method
CN111935885A (en) * 2020-07-16 2020-11-13 广东科徕尼智能科技有限公司 Linkage control method, equipment and storage medium for terminal and equipment light color
CN213040520U (en) * 2020-09-16 2021-04-23 佛山市毅丰电器实业有限公司 Multifunctional color disc and lamp

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116321610A (en) * 2023-05-19 2023-06-23 宏泰智能科技(东莞)有限公司 Intelligent light control method and control system
CN116321610B (en) * 2023-05-19 2023-08-29 东莞市爱多照明有限公司 Intelligent light control method and control system

Also Published As

Publication number Publication date
CN113382512B (en) 2023-01-06

Similar Documents

Publication Publication Date Title
CN108713350B (en) Techniques for gesture-based control of color-tunable lighting
CN109901478A (en) Networking control method, module, controlling terminal, terminal and the medium of household appliance
CN105376905A (en) Smart lighting equipment control method and device
CN113382512B (en) Real-time control method and device for lamp strip and storage medium
JP6430662B2 (en) Control of networked lighting devices
EP1820373A2 (en) Method and system for adjusting the light setting for a multi-color light source
CN109857438A (en) Liquid crystal touch control switch, configuration system and configuration method
US9839097B2 (en) Method and apparatus for controlling lamp based on switching action
CN115119365A (en) Light modulation method, light modulation device and computer storage medium
WO2018182856A1 (en) Image-based lighting controller
CN110611978A (en) Street lamp dynamic dimming method, street lamp management platform, mobile terminal and system
CN104240676A (en) Method for adjusting electronic device and electronic device
CN114347061A (en) Atmosphere lamp setting method and setting device for robot and robot
CN112534967B (en) Method, electronic equipment and storage medium related to light command emission
CN112261768A (en) Lamp strip color control method and system, intelligent terminal and storage device
WO2016112815A1 (en) Method for brightness level adjustment, led lighting device, and lighting system
CN115720727A (en) Control design for perceptually uniform color adjustment
CN114449704A (en) Light control method, system, electronic equipment and computer readable storage device
CN105429828B (en) A kind of method, apparatus and system that smart machine system is added
CN204465945U (en) Intelligent lightening device, control terminal and illuminator
JP6478156B2 (en) Schedule controller, lighting system, and lighting control method
KR101676431B1 (en) System of providing color-contents using circular HSV color-palette of modified-HSV distribution for digital lighting, and method for the same
WO2024060254A1 (en) System and method for controlling lamp device, lamp device, and storage medium
CN107807850A (en) A kind of and the implementation method and device of time point intelligent Matching setting option
CN111312178A (en) Backlight adjusting method and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant