Specific embodiment
In being described below, for illustration and not for limitation, the tool of such as particular system structure, technology etc is proposed
Body details, to understand thoroughly the embodiment of the present invention.However, it will be clear to one skilled in the art that there is no these specific
The present invention also may be implemented in the other embodiments of details.In other situations, it omits to well-known system, device, electricity
The detailed description of road and method, in case unnecessary details interferes description of the invention.
In order to illustrate technical solutions according to the invention, the following is a description of specific embodiments.
Fig. 1 shows the realization stream of the illumination control method of the lighting device provided in an embodiment of the present invention for tent
Journey, details are as follows:
Step S101 detects the current value of the lighting device predeterminated position and the ambient sound data of tent.
In embodiments of the present invention, it is necessary first to detect two class data, be adjusted in the next steps for these two types of data
Lighting device in tent, one type data are the current values of tent predeterminated position, and another kind of data are ambient sound data,
It is to be appreciated that the voiceprint for including according to ambient sound data can classify to ambient sound, in addition, ambient sound
Data also include the decibel of ambient sound.
Optionally, a little pre- for tent on the main line for the power supply circuit for selecting the lighting device of tent to connect with power supply
If position, and detect the current value at this.
Optionally, ambient sound detection device is set in tent inside, ambient sound detection device can recorde ambient sound
The decibel and voiceprint of sound.
Step S102 determines the type of the power supply of the lighting device according to the current value.
In an embodiment of the present invention, tent is mounted on the interior such as factory floor, the confession of the lighting device of tent
Power supply can select external power supply or internal cell power supply, since the connect plug of the lighting device of tent can be inserted in room
On interior socket, therefore indoor power supply can be used as external power supply.It is to be appreciated that under normal circumstances, when using external electrical
Internal cell power supply is determined as the photograph of tent when surprisingly happening by power supply of the source as the lighting device of tent
The power supply of bright device.It in other embodiments, can be using generator as the illumination of tent if tent is installed in outdoor
The external power supply of device.
Step S102 is specifically included: when the power supply is external power supply, if the current value is less than or equal to default
Current threshold or the current value be greater than the preset current threshold and the current value and be greater than the preset current threshold
The duration of value is less than preset time threshold, it is determined that power supply of the external power supply as the lighting device;If institute
Current value is stated greater than the preset current threshold and the current value be greater than the preset current threshold duration it is big
In or equal to the preset time threshold, it is determined that power supply of the internal cell power supply as the lighting device.
Specifically, when lighting device using external power supply as power supply in the case of, detect lighting device preset
The current value of any on the main line of position, i.e. lighting device and external power supply, judges whether the current value meets preset condition, with
Determine whether the power supply circuit of the lighting device of current tent is in a safe condition.
On the one hand, if the current value of predeterminated position is less than or equal to preset current threshold, prove that current tent supplies
Circuit is in the state of safety, it is thus determined that continuing using external power supply as the power supply of tent;
When the current value is greater than the preset current threshold, then start to calculate the current value be greater than it is described default
Current threshold duration.It is not straight when the current value of lighting device predeterminated position is greater than preset current threshold
It connects under assert that the power supply circuit of the lighting device of current tent is in the hole, but further counts the current value and be greater than in advance
If current threshold duration, and in subsequent steps based on the duration determine tent power supply circuit be in safety
Or in the state of danger.If current value is greater than the preset current threshold and the current value is greater than the preset electric current
The duration of threshold value is less than preset time threshold, it is determined that power supply of the external power supply as the lighting device.This
Field technical staff is appreciated that in embodiments of the present invention preset current threshold and preset time threshold can bases
Actual conditions are selected, and the present invention is not specifically limited it.
On the other hand, if the current value is greater than the preset current threshold and the current value is greater than described preset
The duration of current threshold is greater than or equal to the preset time threshold, it is determined that internal cell power supply is as the illumination
The power supply of device.When the current value of lighting device predeterminated position is greater than preset current threshold, the electricity is further counted
Flow valuve is greater than the duration of preset current threshold, if the duration is greater than preset time threshold, it is determined that internal electricity
Power supply of the pond power supply as the lighting device.
It is to be appreciated that in embodiments of the present invention, only when current value is greater than the preset current threshold and described
When the duration that current value is greater than the preset current threshold is greater than or equal to the preset time threshold, just assert and work as
The power supply circuit of the lighting device of preceding tent is under dangerous transition, it is thus determined that internal cell power supply is as the illumination
The power supply of device.
It is to be appreciated that the voltage of internal cell power supply will be far smaller than external power supply, therefore select internal cell power supply
The power supply of lighting device as tent helps to protect account when the failures such as short circuit occur for the power supply circuit of lighting device
Paulin interior lighting device using safe.
Step S103, according to the decibel of the classification of the ambient sound data environment-identification sound and ambient sound, and base
In the classification of the ambient sound, the type of the decibel of the ambient sound and the power supply, the illumination dress is adjusted
The brightness set.
In embodiments of the present invention, by the lighting device of the classification of ambient sound, the decibel of ambient sound and tent
Three parameters of the type of power supply as adjustment tent interior lighting device brightness, the wherein classification and ambient sound of ambient sound
The decibel of sound can reflect the ambient conditions inside and outside tent and the work and rest of tent user, such as sleep and get up, and the photograph of tent
The type of the power supply of bright device determines by the fortuitous event of the power supply circuit thus according to lighting device, therefore can be anti-
Reflect the fortuitous event that tent encounters.To sum up, by ambient sound data and the type of the power supply of the lighting device of tent,
The brightness of the lighting device of tent can more scientifically be adjusted.And it is illuminated according to the adjusting of the work and rest adaptability of tent user
The brightness of device provides more intelligent illumination scheme.
Fig. 2 shows the specific of the illumination control method S103 of the lighting device provided in an embodiment of the present invention for tent
Implementation process, details are as follows:
Step S201, if the power supply of the lighting device of the tent is external power supply, according to the ambient sound
The classification of data environment-identification sound and the decibel of ambient sound, and judge whether the classification of the ambient sound belongs to default class
Not.
Optionally, in embodiments of the present invention, only when the type of the power supply of the lighting device of tent is external electrical
When source, the program of the decibel of the subsequent classification and ambient sound according to ambient sound data environment-identification sound is just carried out.It can
To understand ground, since in embodiments of the present invention, the brightness of the lighting device of tent is the classification and decibel by ambient sound
With the power supply type joint effect of lighting device, therefore only when the type of power supply of the lighting device of tent is
When external power supply, the power supply system of tent just will use the brightness of the lighting device of enough electric power de-regulation tents, and work as account
When the type of the power supply of the lighting device of paulin is internal cell power supply, the power supply system of tent can automatically save electric power,
Therefore the brightness of maintenance lighting device inferior grade, so not identified to ambient sound.
Optionally, in embodiments of the present invention, mode can be carried out to ambient sound according to the voiceprint of ambient sound
Classification, so that ambient sound to be divided into different classifications based on algorithm for pattern recognition and voice print database.For example, ambient sound
It is divided into human speech, footsteps, natural environment sound and mankind's activity sound, it is possible to understand that ground, human speech classification refer to
The mankind carry out the sound of speech exchange by speaking, due to the mobile sound generated when footsteps refers to the mankind outside tent close to tent
Sound, or since the mobile sound generated, natural environment sound refer to the sound that non-human generates inside and outside tent, mankind's activity in tent
Sound includes the sound of all still non-human voices and footsteps generated by the mankind.
It optionally, can be by the vocal print of freshly harvested ambient sound and intrinsic vocal print number by algorithm of support vector machine
It is compared classification according to library, identifies the classification of the ambient sound acquired in preset time period.It is to be appreciated that one section of ambient sound
Sound is unlikely to be simple a kind of sound, such as within 2 second time, collected sound had both included human speech or included nature
Ambient sound, but the sound can be classified as by existing algorithm of support vector machine by human speech or natural environment sound therein one
Class, it is possible to understand that ground, such as algorithm of support vector machine isotype recognizer, being exactly may compound a plurality of types of number one
According to being divided into and the immediate classification of the data.So in embodiments of the present invention, can be identified by algorithm of support vector machine
The classification of collected ambient sound.
Optionally, in embodiments of the present invention, classified by the identification to ambient sound, to treat all kinds of sound with a certain discrimination.
In embodiments of the present invention, user can select classification of one or more classifications as preset ambient sound first.For example,
As described in example above, ambient sound is divided into human speech, footsteps, natural environment sound and mankind's activity sound, institute
That human speech and footsteps can be chosen to be pre-set categories.In embodiments of the present invention, in the type of environment-identification sound
Later, need to judge whether the classification of ambient sound belongs to pre-set categories.
Step S202, according to the decibel of the ambient sound, is adjusted if the classification of the ambient sound belongs to pre-set categories
Save the brightness of the lighting device, the decibel positive correlation of the brightness of the lighting device and the ambient sound.
As described above, the embodiment of the present invention can also detect the decibel of ambient sound, if the classification of current environmental sound
Belong to preset classification, so that it may the brightness of lighting device is adjusted by the decibel of ambient sound.For example, pre-set categories are the mankind
Voice, and the ambient sound currently acquired is just identified as human speech, then according to the size of the decibel of current environmental sound
Adjust lighting device.
Optionally, the decibel positive correlation of the brightness of lighting device and the ambient sound, i.e. point of ambient sound
The brightness of Bei Yue great, lighting device are brighter.
Fig. 3 shows the specific of the illumination control method S202 of the lighting device provided in an embodiment of the present invention for tent
Implementation process, details are as follows:
Step 301, obtain preset corresponding relationship, the corresponding relationship include the ambient sound decibel and pulse it is wide
The corresponding relationship of the duty ratio of degree modulation (Pulse Width Modulation, PWM) wave.
It in embodiments of the present invention, can be using LED light as lighting device.
In embodiments of the present invention, by setting the duty ratio of pulse width modulation (PWM) wave, reach according to the ambient sound
The decibel of sound adjusts the purpose of the brightness of the lighting device.
Specifically, in embodiments of the present invention, the brightness value that the method for using pulse width to modulate sets each region can be with
Avoid light that color drift occurs during lamplight brightness variation.It is to be appreciated that being used in traditional light regulating technology
By increasing or reducing the prevention of lighting device, to reduce electric current, to reduce the brightness of light, however this mode can change
While degree of brightening, change the color of light.
Specifically, in embodiments of the present invention, common voltage signal is converted into pulse width by pulse width modulation
Modulating wave, pulse width modulation wave are actually to be made of the square wave one by one with certain duty ratio.And pulse width is modulated
The duty ratio of wave can directly determine the size of average output voltage, and the change of average output voltage can influence light
Brightness.
Such as: if the maximum voltage of PWM wave is 5V, and duty ratio is 0.75, then average output voltage is 3.75V.
If the maximum voltage of PWM wave is 5V, and duty ratio is 0.5, then average output voltage is 2.5V.It is to be appreciated that due to
The frequency of PWM wave is very high, so human eye can not actually perceive lamp and not shine when voltage is 0 in one cycle.
It is to be appreciated that in embodiments of the present invention, it is necessary first to which decibel and the pulse for transferring preset ambient sound are wide
The corresponding relationship of the duty ratio of modulation (PWM) wave is spent, to carry out subsequent setting.
Step S302 determines PWM wave corresponding with the decibel of current environmental sound according to the preset corresponding relationship
Duty ratio, the duty ratio of the PWM wave as the lighting device, to adjust the brightness of the lighting device.
Step S203 keeps the present intensity of lighting device if the classification of the ambient sound is not belonging to pre-set categories
It is constant.
It is to be appreciated that if the classification of ambient sound is not belonging to pre-set categories, no matter ambient sound decibel it is much,
The brightness of lighting device is also without changing.
Step S204, if the power supply of the lighting device is internal cell power supply, by the brightness tune of lighting device
Whole is preset brightness.
As described above, after fortuitous event occurs, if in the state that the power supply circuit of tent is in dangerous, tent
The power supply of lighting device be switched to internal cell power supply, be not necessarily to the classification of environment-identification sound at this time, but directly
It is preset brightness by the brightness adjustment of lighting device, it is possible to understand that the brightness value on ground, preset brightness here is lower, only uses
In the most basic brightness demand for meeting personnel in tent.
Further, when the power supply of the lighting device of the tent changes, the lighting device of the tent is controlled
Change the color of transmitting light.
In embodiments of the present invention, when different power supplies is the power illuminating device of tent, the illumination dress of tent
The color for setting transmitting light is not identical, and the power supply circuit of user's tent in tent can be reminded to have gone out in this way
Existing failure.
Further, in other embodiments of the present invention, the type of the power supply of different lighting devices is corresponding is
Different lighting devices controls photograph different in the tent that is, when the power supply of the lighting device of the tent changes
Bright device lights, and reminds customer power supply circuit in tent to break down to play.
Further, in other embodiments of the present invention, harmful gas detecting device is equipped in tent, when preset nocuousness
When gas is more than preset concentration, the warning lamp in tent will be lighted.
Corresponding to application upgrade method described in foregoing embodiments, Fig. 4 shows provided in an embodiment of the present invention for account
The structural block diagram of the illumination control apparatus of the lighting device of paulin illustrates only related to the embodiment of the present invention for ease of description
Part.
Referring to Fig. 4, which includes:
Detection module 401, for detecting the current value of the lighting device predeterminated position and the ambient sound number of tent
According to;
Power supply determining module 402, for determining the type of the power supply of the lighting device according to the current value;
Module 403 is adjusted, for according to the classification of the ambient sound data environment-identification sound and point of ambient sound
Shellfish, and the type of the decibel of the classification based on the ambient sound, the ambient sound and the power supply, described in adjustment
The brightness of lighting device.
Further, power supply determining module includes:
First determines submodule, for being external power supply when the power supply, if the current value is less than or equal to pre-
If current threshold or the current value be greater than the preset current threshold and the current value and be greater than the preset electric current
The duration of threshold value is less than preset time threshold, it is determined that power supply of the external power supply as the lighting device;
Second determines submodule, is greater than if being greater than the preset current threshold and the current value for the current value
The duration of the preset current threshold is greater than or equal to the preset time threshold, it is determined that internal cell power supply is made
For the power supply of the lighting device.
Further, adjustment module includes:
Judging submodule, if the power supply for the lighting device is external power supply, according to the ambient sound
The classification of data environment-identification sound and the decibel of ambient sound, and judge whether the classification of the ambient sound belongs to default class
Not;
Submodule is adjusted, if the classification for the ambient sound belongs to pre-set categories, according to the ambient sound
Decibel, adjusts the brightness of the lighting device, and the brightness of the lighting device and the decibel of the ambient sound are positively correlated pass
System;
First implementation sub-module keeps lighting device if the classification for the ambient sound is not belonging to pre-set categories
Present intensity it is constant;
Second implementation sub-module fills illumination if the power supply for the lighting device is internal cell power supply
The brightness adjustment set is preset brightness.
The adjusting submodule, is specifically used for:
Preset corresponding relationship is obtained, the corresponding relationship includes the decibel and pulse width modulation wave of the ambient sound
Duty ratio corresponding relationship;
According to the preset corresponding relationship, pulse width modulation wave corresponding with the decibel of current environmental sound is determined
Duty ratio, the duty ratio of the pulse width modulation wave as the lighting device, to adjust the brightness of the lighting device.
Further, further includes:
Color change module, for controlling the lighting device and changing when the change of the power supply of the lighting device
Emit the color of light.
Fig. 5 is the schematic diagram of the illumination control apparatus for the lighting device for tent that one embodiment of the invention provides.Such as
Shown in Fig. 5, the illumination control apparatus of the lighting device for tent of the embodiment include: processor 50, memory 51 and
It is stored in the computer program 52 that can be run in the memory 51 and on the processor 50, such as the illumination for tent
The Lighting control program of device.The processor 50 realizes above-mentioned each photograph for tent when executing the computer program 52
Step in the illumination control method embodiment of bright device, such as step S101 to S103 shown in FIG. 1.Alternatively, the processing
Device 50 realizes the function of each module/unit in above-mentioned each Installation practice when executing the computer program 52, such as shown in Fig. 5
The function of module 401 to 403.
Illustratively, the computer program 52 can be divided into one or more module/units, it is one or
Multiple module/units are stored in the memory 51, and are executed by the processor 50, to complete the present invention.Described one
A or multiple module/units can be the series of computation machine program instruction section that can complete specific function, which is used for
Implementation procedure of the computer program 52 in the illumination control apparatus 5 of the lighting device for tent is described.For example,
The computer program 52 can be divided into identification module and search module (module in virtual bench), and each module is specific
Function is as follows:
Detection module, for detecting the current value and ambient sound data of the lighting device predeterminated position;
Power supply determining module, for determining the type of the power supply of the lighting device according to the current value;
Module is adjusted, for according to the classification of the ambient sound data environment-identification sound and the decibel of ambient sound,
And the decibel of the classification, the ambient sound based on the ambient sound and the type of the power supply, adjust the photograph
The brightness of bright device.
The illumination control apparatus 5 of the lighting device for tent can be desktop PC, notebook, palm electricity
Brain and cloud server etc. calculate equipment.Illumination control apparatus/device of the lighting device for tent may include, but not
It is only limitted to, processor 50, memory 51.It will be understood by those skilled in the art that Fig. 5 is only used for the lighting device of tent
The example of illumination control apparatus 5 does not constitute the restriction to the illumination control apparatus 5 of the lighting device for tent, can wrap
It includes than illustrating more or fewer components, perhaps combines certain components or different components, such as the photograph for being used for tent
The illumination control apparatus of bright device can also include input-output equipment, network access equipment, bus etc..
Alleged processor 50 can be central processing unit (Central Processing Unit, CPU), can also be
Other general processors, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit
(Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field-
Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic,
Discrete hardware components etc..General processor can be microprocessor or the processor is also possible to any conventional processor
Deng.
The memory 51 can be the internal storage unit of the illumination control apparatus of the lighting device for tent,
Such as the hard disk or memory of the illumination control apparatus 5 of the lighting device for tent.The memory 51 is also possible to the use
In the External memory equipment of illumination control apparatus/device 5 of the lighting device of tent, such as the lighting device for being used for tent
Illumination control apparatus/device 5 on the plug-in type hard disk that is equipped with, intelligent memory card (Smart Media Card, SMC), safety
Digital (Secure Digital, SD) card, flash card (Flash Card) etc..Further, the memory 51 can also be both
The internal storage unit of illumination control apparatus/device 5 including the lighting device for tent is also set including external storage
It is standby.The memory 51 is used to store the Lighting control dress of the computer program and the lighting device for tent
Set/device needed for other programs and data.The memory 51, which can be also used for temporarily storing, have been exported or will
The data of output.It is apparent to those skilled in the art that for convenience of description and succinctly, only with above-mentioned each
The division progress of functional unit, module can according to need and for example, in practical application by above-mentioned function distribution by difference
Functional unit, module complete, i.e., the internal structure of described device is divided into different functional unit or module, with complete with
The all or part of function of upper description.Each functional unit in embodiment, module can integrate in one processing unit,
It can be each unit to physically exist alone, can also be integrated in one unit with two or more units, it is above-mentioned integrated
Unit both can take the form of hardware realization, can also realize in the form of software functional units.In addition, each function list
Member, the specific name of module are also only for convenience of distinguishing each other, the protection scope being not intended to limit this application.Above system
The specific work process of middle unit, module, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, is not described in detail or remembers in some embodiment
The part of load may refer to the associated description of other embodiments.
Those of ordinary skill in the art may be aware that list described in conjunction with the examples disclosed in the embodiments of the present disclosure
Member and algorithm steps can be realized with the combination of electronic hardware or computer software and electronic hardware.These functions are actually
It is implemented in hardware or software, the specific application and design constraint depending on technical solution.Professional technician
Each specific application can be used different methods to achieve the described function, but this realization is it is not considered that exceed
The scope of the present invention.
In embodiment provided by the present invention, it should be understood that disclosed device/device and method can pass through
Other modes are realized.For example, device/Installation practice described above is only schematical, for example, the module or
The division of unit, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units
Or component can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, institute
Display or the mutual coupling or direct-coupling or communication connection discussed can be through some interfaces, device or unit
INDIRECT COUPLING or communication connection can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list
Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated module/unit be realized in the form of SFU software functional unit and as independent product sale or
In use, can store in a computer readable storage medium.Based on this understanding, the present invention realizes above-mentioned implementation
All or part of the process in example method, can also instruct relevant hardware to complete, the meter by computer program
Calculation machine program can be stored in a computer readable storage medium, the computer program when being executed by processor, it can be achieved that on
The step of stating each embodiment of the method.Wherein, the computer program includes computer program code, the computer program
Code can be source code form, object identification code form, executable file or certain intermediate forms etc..Computer-readable Jie
Matter may include: can carry the computer program code any entity or device, recording medium, USB flash disk, mobile hard disk,
Magnetic disk, CD, computer storage, read-only memory (Read-Only Memory, ROM), random access memory (Random
Access Memory, RAM), electric carrier signal, telecommunication signal and software distribution medium etc..It should be noted that the meter
The content that calculation machine readable medium includes can carry out increase and decrease appropriate according to the requirement made laws in jurisdiction with patent practice,
It such as does not include electric carrier signal and telecommunications according to legislation and patent practice, computer-readable medium in certain jurisdictions
Signal.
Embodiment described above is merely illustrative of the technical solution of the present invention, rather than its limitations;Although referring to aforementioned reality
Applying example, invention is explained in detail, those skilled in the art should understand that: it still can be to aforementioned each
Technical solution documented by embodiment is modified or equivalent replacement of some of the technical features;And these are modified
Or replacement, the spirit and scope for technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution should all
It is included within protection scope of the present invention.