Lamp dimmer and lamp light control method
Technical field
The application relates to technical field of lamps, is specifically related to a kind of lamp dimmer and lamp light control method of light fixture.
Background technology
At present, along with the raising of people's living standard, in lighting field, light fixture is not only for people provide lighting demand, also carry the effect that band brings visual enjoyment.
At present on the market with the music relevant device of light flash, its light flash mode is very simple, just be built in music relevant device in fixing several modes, its light flash method fixed single, different process can not be done for different music, such as along with the light on and off of the unified light controlled of rhythm of music, or flash mode or speed along with the rhythm of music is unified, thus the blink cadence not reaching music rhythm and light unified dazzle beautiful effect.
Summary of the invention
The object of the application is to provide a kind of lamp dimmer and lamp light control method, effectively cannot unify the problem of the blink cadence of music rhythm and light in order to solve existing music relevant device.
In order to solve the problem, this application provides a kind of lamp dimmer, in order to control the rhythm of light of light fixture according to the voice signal of external environment.Lamp dimmer comprises sound acquisition module, processing module and signal output module, and wherein sound acquisition module is in order to collected sound signal; Processing module is coupled to sound acquisition module, in order to receive voice signal, and identify and stored sound signal in note and beat; Signal output module is coupled to processing module, controls signal to light fixture accordingly in order to send according to note and beat.
Further, above-mentioned lamp dimmer also comprises noise reduction module, and it is coupled between sound acquisition module and processing module, carries out noise reduction process in order to the voice signal collected sound acquisition module.
Further, above-mentioned lamp dimmer also comprises display module, and it is coupled to processing module, in order to show actions menu.
Further, in above-mentioned lamp dimmer, sound acquisition module is provided with input/output port, and processing module is provided with timer, the frequency that processing module produces in input/output port according to the scheduled time detecting voice signal of timer, and the tone of note is judged according to the cycle of frequency.
Further, in above-mentioned lamp dimmer, note corresponds to frequency, and beat is the playing time of note.
Further, in above-mentioned lamp dimmer, control signal comprises the number of repetition of lights signal, the delay time of lights, light start signal and switch light.
The application provides a kind of lamp light control method simultaneously, in order to control the rhythm of light of light fixture according to the voice signal of external environment.Lamp light control method comprises: collected sound signal; Note in sound recognition signal and beat; And control signal to light fixture accordingly according to note and beat transmission.
Further, above-mentioned lamp light control method also comprises and carries out noise reduction process to the voice signal collected; And store the operation of note and beat.
Further, in above-mentioned lamp light control method, the note in sound recognition signal and the operation of beat comprise: the frequency detecting voice signal in the given time; The tone of note is judged according to the cycle of frequency; And locate beat according to the playing time of note.
Further, in above-mentioned lamp light control method, send according to note and beat the operation controlling signal to light fixture accordingly and comprise: blackout in delay time; Light is opened after delay time; Determine to repeat blackout and the number of operations opening light according to cycle and beat; And repeat blackout and the operation of opening light.
Compared with prior art, the application can obtain and comprise following technique effect:
The lamp dimmer that the application provides can control the rhythm of light of light fixture according to the voice signal of external environment.Lamp dimmer comprises sound acquisition module, processing module and signal output module, voice signal sound acquisition module collected by processing module carries out the identification of note and beat, send note and beat therewith by signal output module again and control signal to light fixture accordingly, thus allow light fixture can coordinate the music rhythm of external environment or the conversion of rhythm, allow the blink speed of light echo mutually with music rhythm instantly or rhythm, and the blink cadence reaching music rhythm and light unified dazzle beautiful effect.
Accompanying drawing explanation
Accompanying drawing described herein is used to provide further understanding of the present application, and form a application's part, the schematic description and description of the application, for explaining the application, does not form the improper restriction to the application.In the accompanying drawings:
Fig. 1 is a block schematic diagram of the lamp dimmer of the application first embodiment;
Fig. 2 is a block schematic diagram of the lamp dimmer of the application second embodiment;
Fig. 3 is the another block schematic diagram of the lamp dimmer of the application second embodiment;
Fig. 4 is a flow chart of the lamp light control method of the application the 3rd embodiment;
Fig. 5 is the another flow chart of the lamp light control method of the application the 3rd embodiment.
Embodiment
Drawings and Examples will be coordinated below to describe the execution mode of the application in detail, by this to the application how application technology means solve technical problem and the implementation procedure reaching technology effect can fully understand and implement according to this.
As employed some vocabulary to censure specific components in the middle of specification and claim.Those skilled in the art should understand, and hardware manufacturer may call same assembly with different noun.This specification and claims are not used as with the difference of title the mode distinguishing assembly, but are used as the criterion of differentiation with assembly difference functionally." comprising " as mentioned in the middle of specification and claim is in the whole text an open language, therefore should be construed to " comprise but be not limited to "." roughly " refer to that in receivable error range, those skilled in the art can solve the technical problem within the scope of certain error, reach described technique effect substantially.In addition, " couple " or " electric connection " one word comprise directly any and indirectly electric property coupling means at this.Therefore, if describe a first device in literary composition to be coupled to one second device, then represent described first device and directly can be electrically coupled to described second device, or be indirectly electrically coupled to described second device by other device or the means that couple.Specification subsequent descriptions is implement the better embodiment of the application, and right described description is for the purpose of the rule that the application is described, and is not used to the scope limiting the application.The protection range of the application is when being as the criterion depending on the claims person of defining.
Also it should be noted that, term " comprises ", " comprising " or its other variant any are intended to contain comprising of nonexcludability, thus make to comprise the process of a series of key element, method, commodity or system and not only comprise those key elements, but also comprise other key element clearly do not listed, or also comprise by the intrinsic key element of this process, method, commodity or system.When not more restrictions, the key element limited by statement " comprising ... ", and be not precluded within process, method, commodity or the system comprising described key element and also there is other identical element.
embodiment describes
The lamp dimmer that the application proposes is the rhythm of light in order to control light fixture according to the voice signal of external environment, such as allow light fixture can coordinate the music rhythm of external environment or the conversion of rhythm, allow the blink speed of light echo mutually with music rhythm instantly or rhythm, and the blink cadence reaching music rhythm and light unified dazzle beautiful effect.
Embodiment 1
As shown in Figure 1, the block diagram of the lamp dimmer disclosed by the application first embodiment.Described lamp dimmer 10 can be adopt the pattern of external power supply to operate, or adopt the mode of filling battery to provide power supply, powering mode the present embodiment concrete for it does not specifically limit, if it is conceivable that external power supply, as alternating current etc. needs to connect power supply adaptor, to carry out transformation to the voltage fallen short of specifications.
Lamp dimmer 10 comprises sound acquisition module 110, processing module 120 and signal output module 130.
Described processing module 120 is respectively coupled to sound acquisition module 110 and signal output module 130.Sound acquisition module 110 is in order to collected sound signal, and therefore, sound acquisition module 110 can be but be not limited to microphone or other forms of audio signal reception device.Processing module 120 includes main control integrated circuit chip, in order to receive voice signal from sound acquisition module 110 and to identify the note in this voice signal and beat, and the note in the voice signal after identification and beat is stored.Signal output module 130 includes communication chip, light fixture is controlled signal to accordingly in order to send according to note and beat, therefore in signal output module 130 and light fixture, corresponding signal receiving/transmission device is configured with respectively, such as be applicable to the signal receiving/transmission device of DMX512 form, allow signal output module 130 can transmit control signal to drive the light unlatching of light fixture or the frequency of closedown.Here, described control signal can comprise DMX512 signal, and it observes DMX512 agreement, the agreement that its simplicity had, reliability and flexibility are selected under making it become rapidly fund permission situation, except dimmer, a series of ever-increasing control appliance is exactly evidence.DMX512 remains a scientific frontier, has the various marvellous technology produced on rule-based approach.
Particularly, described processing module 120 is adopted progressive die block 110 from sound and is received voice signal, and the note in voice signal and beat are identified, wherein, when voice signal is by input/output port (I/O mouth) that sound acquisition module configures, frequency can be produced on input/output port, now by processing module 120, this frequency is fetched, and closed in the given time by the timer that processing module 120 configures and interruption processing module to the detecting of voice signal and fetch, namely detect the frequency of described voice signal in the given time.For the frequency f=400Hz of standard pitch A: A, the cycle of its correspondence is: T=1/f=1/400=2272 μ s.Utilize the down trigger mode of processing module 120 to gather, if the cycle collected now is 2272 μ s, then identify that the tone of the note now played is A, namely judge the tone of described note according to the cycle of frequency.In addition, if the tone gathered in certain a period of time is A, find that tone becomes B by the contrast of processing module 120, now namely processing module judges how long tone A plays, then the playing time of this section of note is orientated as beat, namely according to the playing time location beat of note.
As shown in table 1 below, be the different note that identified by processing module and beat.
Tone |
1 |
1” |
2 |
2” |
3 |
4 |
4” |
5 |
5” |
6 |
6” |
7 |
Note |
523 |
553 |
586 |
621 |
658 |
697 |
739 |
783 |
830 |
879 |
931 |
987 |
Beat |
1.2 |
1.5 |
1.7 |
1.3 |
1.5 |
1.6 |
1.3 |
1.2 |
0.5 |
0.7 |
1.3 |
2 |
Table 1
Thus, the note of the voice signal (such as song) that described sound acquisition module 110 reception is come in and beat present with the form of quantized data, and are stored in described processing module 120.
Then, signal output module 130 obtains note and the beat of voice signal from processing module 120, and send according to these notes and beat and control signal to light fixture (step S120) accordingly, wherein, control signal comprises the number of repetition etc. of lights signal, the delay time of lights, light start signal and switch light, allow light fixture can in delay time blackout; Light is opened after delay time; Further, determine to repeat blackout and the number of operations opening light according to cycle and beat; And repeat the operation etc. of blackout and described unlatching light.Such as, for note frequencies be 525Hz, beat is for the tone 1 of 1.2 seconds (s), the control signal that signal output module 130 sends can be first include the string data that data field is 0 entirely, now the light of light fixture goes out entirely, and after the delay time of 1916 μ s (cycle T=1/525), send the string data that another data field is 1 entirely again, now the light of light fixture is bright, thus realizes the note of tone 1.Then, repeat the action 626 times (in 1.2 seconds) of above-mentioned lights and unlatching, namely realize the beat of tone 1.
Thus, the rhythm of light of light fixture and music rhythm just can be made to reach an agreement, and beautiful sound and light program is dazzled in generation.
Embodiment 2
Please refer to Fig. 2, the block diagram of the lamp dimmer disclosed by the application second embodiment, the present embodiment is on the basis of embodiment one, and described controller 10 optionally can also add noise reduction module 140 and/or display module 150.
Described noise reduction module 140 is coupled between sound acquisition module 110 and processing module 120, voice signal in order to collect sound acquisition module 110 carries out noise reduction process and/or eliminates the voice optimization programs such as echo process, makes the identification of processing module 120 pairs of notes and beat more accurate.
Described display module 150 is coupled to processing module 120, in order to show actions menu on lamp dimmer 10, thus adds convenience in the operation of lamp dimmer 10.
Please refer to Fig. 3, in other preferred embodiments of the application, described controller 10 can also optionally add in memory module 160, JTAG DLL (dynamic link library) module 170, supply module 180 and voltage regulator module 190 one or more.
Described memory module 160 is for providing memory space for described reason module 120, so that note in described voice signal and beat.
Described JTAG DLL (dynamic link library) module 170 is coupled to described processing module 120, for testing and upgrade maintenance described processing module 120.Here, described JTAG DLL (dynamic link library) module 170 is mainly tested the master chip with described processing module 120, safeguard and upgrading etc., to ensure that described processing module 120 has good performance.
Described supply module 180 is coupled to described processing module 120, for powering to described controller 10.Further, described voltage regulator module 190 between described processing module 120 and described supply module 180, for carrying out voltage stabilizing process to described supply module 180, to ensure the palace safety to described processing module 120.Here, take described processing module 120 as the Cortex-A8 processor of ARM company, its digital I/O mouth is all resistance to 5V voltage, and normal need of work 2.5V and 3.3V of VS1003 chip powers simultaneously, and system needs to choose different voltage stabilizing chips and carries out voltage stabilizing.5V voltage stabilizing chip selected in native system is linear three-terminal voltage-stabilizing chip LM7805,3.3V and the 2.5V voltage stabilizing chip that what 3.3V and 2.5V voltage stabilizing chip was selected is in AMS1117 series voltage stabilizing chip.3.4.1LM7805 voltage stabilizing chip is current, the lm78 series that common circuit of three-terminal voltage-stabilizing integrated has positive voltage to export and the lm79 series that negative voltage exports.As its name suggests, three end IC refer to the integrated circuit of this voltage stabilizing, and only having three pins to export, is input, earth terminal and output respectively.LM7805 is the one in lm78 series, and its inside circuit also has the protective circuit of overcurrent, overheated and Correctional tube, and it is reliable, convenient to use, and low price.The output voltage of this three ends integrated stable voltage circuit of digitized representation below of lm78 or lm79 in this serial integrated voltage-stabilized IC model, the lm7805 used as the design represents that output voltage is positive 5V.
Above lifted example is wherein several way of realization of the present invention, it is conceivable that can derive other multiple ways of realization under design of the present invention, but should be understood to belong to thought category of the present invention, should fall into protection scope of the present invention.
Embodiment 3
Please refer to Fig. 4, be the lamp light control method flow chart of the lamp dimmer of the application the 3rd embodiment, described method comprises:
Step S100, collected sound signal;
Step S200, the note in sound recognition signal and beat; And
Step S300, sends according to note and beat and controls signal to light fixture accordingly.
In step 100, in the standby state, whether the sound acquisition module detecting of lamp dimmer has voice signal to be passed to lamp dimmer, if having, sound acquisition module gathers this voice signal; If do not have described sound acquisition module can continue detecting, it is conceivable that described sound acquisition module to be detecting real-time no has voice signal to be passed to lamp dimmer.
Accept above-mentioned steps S100, in step s 200, processing module is adopted progressive die block from sound and is received voice signal, and identifies the note in voice signal and beat.Please refer to Fig. 5, is the another flow chart of the lamp light control method of the lamp dimmer of the application the 3rd embodiment, identifies that the method for note in described voice signal and beat comprises:
Step S210, detects the frequency of described voice signal in the given time;
Step S220, judges the tone of described note according to the cycle of described frequency;
Step S230, locates described beat according to the playing time of described note.
Particularly, when voice signal is by input/output port (I/O mouth) that sound acquisition module configures, frequency can be produced on input/output port, now by processing module, this frequency is fetched, and closed in the given time by the timer that processing module configures and interruption processing module to the detecting of voice signal and fetch, namely detect the frequency of described voice signal in the given time.For the frequency f=400Hz of standard pitch A: A, the cycle of its correspondence is: T=1/f=1/400=2272 μ s.Utilize the down trigger mode of processing module 120 to gather, if the cycle collected now is 2272 μ s, then identify that the tone of the note now played is A, namely judge the tone of described note according to the cycle of frequency.In addition, if the tone gathered in certain a period of time is A, find that tone becomes B by the contrast of processing module 120, now namely processing module judges how long tone A plays, then the playing time of this section of note is orientated as beat, namely according to the playing time location beat of note.
As shown in table 2 below, be the different note that identified by processing module and beat.
Tone |
1 |
1” |
2 |
2” |
3 |
4 |
4” |
5 |
5” |
6 |
6” |
7 |
Note |
523 |
553 |
586 |
621 |
658 |
697 |
739 |
783 |
830 |
879 |
931 |
987 |
Beat |
1.2 |
1.5 |
1.7 |
1.3 |
1.5 |
1.6 |
1.3 |
1.2 |
0.5 |
0.7 |
1.3 |
2 |
Table 2
Thus, note and the beat of the voice signal (such as song) just sound acquisition module reception can come in by above method are presented with the form of quantized data, and are stored in processing module.
In addition, in other preferred embodiments of the application, before the note identified in described voice signal and beat, noise reduction process to be carried out to the described described voice signal collected, more accurate to ensure the identification of note and beat.
Accept above-mentioned steps S200, in step S300, signal output module obtains note and the beat of voice signal from processing module, and send according to these notes and beat and control signal to light fixture accordingly, wherein, control signal comprises the number of repetition etc. of lights signal, the delay time of lights, light start signal and switch light, allow light fixture can in delay time blackout; Light is opened after delay time; Further, determine to repeat blackout and the number of operations opening light according to cycle and beat; And repeat the operation etc. of blackout and described unlatching light.Such as, for note frequencies be 525Hz, beat is for the tone 1 of 1.2 seconds (s), the control signal that signal output module sends can be first include the string data that data field is 0 entirely, now the light of light fixture goes out entirely, and after the delay time of 1916 μ s (cycle T=1/525), send the string data that another data field is 1 entirely again, now the light of light fixture is bright, thus realizes the note of tone 1.Then, repeat the action 626 times (in 1.2 seconds) of above-mentioned lights and unlatching, namely realize the beat of tone 1.
It is to be noted, the type of described control signal can comprise DMX512 signal, it observes DMX512 agreement, the agreement that its simplicity had, reliability and flexibility are selected under making it become rapidly fund permission situation, except dimmer, a series of ever-increasing control appliance is exactly evidence.DMX512 remains a scientific frontier, has the various marvellous technology produced on rule-based approach.
Thus, the rhythm of light of light fixture and music rhythm just can be made to reach an agreement, and beautiful sound and light program is dazzled in generation.
Above lifted example is wherein several way of realization of the present invention, it is conceivable that can derive other multiple ways of realization under design of the present invention, but should be understood to belong to thought category of the present invention, should fall into protection scope of the present invention.
In addition, it is pointed out that the device embodiment of the control method embodiment of above lifted controller and controller can reference mutually, if one is clear not, please refer to another embodiment.
Above-mentioned explanation illustrate and describes some preferred embodiments of the application, but as previously mentioned, be to be understood that the application is not limited to the form disclosed by this paper, should not regard the eliminating to other embodiments as, and can be used for other combinations various, amendment and environment, and can in invention contemplated scope described herein, changed by the technology of above-mentioned instruction or association area or knowledge.And the change that those skilled in the art carry out and change do not depart from the spirit and scope of the application, then all should in the protection range of the application's claims.