CN109195263B - Device state synchronous control device and synchronous control method - Google Patents

Device state synchronous control device and synchronous control method Download PDF

Info

Publication number
CN109195263B
CN109195263B CN201811177440.9A CN201811177440A CN109195263B CN 109195263 B CN109195263 B CN 109195263B CN 201811177440 A CN201811177440 A CN 201811177440A CN 109195263 B CN109195263 B CN 109195263B
Authority
CN
China
Prior art keywords
state data
module
state
line voltage
count value
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.)
Active
Application number
CN201811177440.9A
Other languages
Chinese (zh)
Other versions
CN109195263A (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.)
Shenzhen Sendis Semiconductor Co Ltd
Original Assignee
Shenzhen Sendis Semiconductor 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 Shenzhen Sendis Semiconductor Co Ltd filed Critical Shenzhen Sendis Semiconductor Co Ltd
Priority to CN201811177440.9A priority Critical patent/CN109195263B/en
Publication of CN109195263A publication Critical patent/CN109195263A/en
Application granted granted Critical
Publication of CN109195263B publication Critical patent/CN109195263B/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
    • H05B45/00Circuit arrangements for operating light-emitting diodes [LED]
    • H05B45/10Controlling the intensity of the light

Abstract

The invention discloses a device state synchronous control device and a synchronous control method, comprising a power supply module, a line voltage detection module, a control module and a wireless module; the power supply module rectifies the input alternating current and outputs the line voltage to the line voltage detection module; the line voltage detection module outputs a detection signal to the control module according to the line voltage; the wireless module receives state data input from the outside and stores the state data to the control module; the control module counts according to the detection signal, reads the currently stored state data when the detection signal is interrupted and the count value is a first set value, outputs a corresponding dimming signal to the controlled equipment according to the current count value and the state data, and clears the count value when the count value is a second set value. The invention takes the output interruption of the detection signal as the synchronous signal and the counting value as the state change period to control the working state of the equipment when simultaneously adjusting the working states of a plurality of pieces of equipment, thereby effectively eliminating the influence of the transmission distance and the speed of the wireless instruction on the state synchronization.

Description

Device state synchronous control device and synchronous control method
Technical Field
The invention relates to the technical field of intelligent control, in particular to a device state synchronous control device and a synchronous control method.
Background
At present, when a wireless controller is used for controlling the states of a plurality of independent devices, the time difference of receiving a controller instruction by each device is large due to low wireless data transmission rate or long device interval and the like, the devices are not used as a synchronous processing mechanism in a traditional processing mode, the devices update the states of the devices to the states set by the controller after receiving the wireless control instruction, the states of the devices receiving the wireless instruction are changed firstly, then the states of the devices receiving the wireless instruction are changed later, if the devices dynamically change according to a certain rule, the state change of the devices after receiving the instruction is not synchronous any more.
Thus, the prior art has yet to be improved and enhanced.
Disclosure of Invention
In view of the above-mentioned shortcomings in the prior art, an object of the present invention is to provide a device state synchronization control apparatus and a synchronization control method, which can detect a line voltage and count an output detection signal, use an interruption of the detection signal output as a synchronization signal, and use a count value as a state change period to control the state of a controlled device, and can accurately control the state synchronization of each device when adjusting the operating states of a plurality of devices simultaneously, thereby avoiding the problem of state inconsistency caused by a time difference between received commands.
In order to achieve the purpose, the invention adopts the following technical scheme:
the equipment state synchronous control device is connected with controlled equipment and comprises a power supply module, a line voltage detection module, a control module and a wireless module; the power supply module rectifies input alternating current and outputs line voltage to the line voltage detection module, and simultaneously outputs power supply voltage to the control module and the wireless receiving module; the line voltage detection module outputs a detection signal to the control module according to the line voltage; the wireless module receives state data input from the outside and stores the state data to the control module; the control module counts according to the detection signal, reads currently stored state data when the detection signal is interrupted and the count value is a first set value, outputs a corresponding dimming signal to controlled equipment according to the current count value and the state data, and clears the count value when the count value is a second set value, wherein the first set value and the second set value adopt the same value or different values.
In the device state synchronization control device, the control module comprises a counter, an instruction receiving unit and an output conversion unit; the counter is used for adding 1 when the rising edge interruption or the falling edge interruption of the detection signal is detected every time, and clearing and restarting counting when the count value is a second set value; the instruction receiving unit is used for receiving and storing the state data when the output interruption of the wireless module is detected; the output conversion unit is used for reading the currently stored state data when the detection signal outputs rising edge interruption or falling edge interruption and the counting value is a first set value, and outputting a corresponding dimming signal to the controlled equipment according to the current counting value and the state data.
In the device state synchronization control apparatus, the control module further includes a data register and a state memory, and the instruction receiving unit is specifically configured to receive the state data and shift the state data to the data register when detecting that the output of the wireless module is interrupted, determine whether a preamble of the current state data is equal to a preset value, and store the state data in the state memory if the preamble of the current state data is equal to the preset value.
In the device state synchronization control apparatus, the output conversion unit is specifically configured to map a dimming state corresponding to a current count value in the read state data to a dimming signal, and output the dimming signal to a controlled device.
In the device state synchronization control apparatus, the dimming signal is a PWM dimming signal or an analog voltage signal.
In the device state synchronization control device, the power supply module comprises a rectifier bridge, a first resistor, a first diode, a voltage stabilizing diode, a first capacitor, a second capacitor and a voltage stabilizer; the input end of the rectifier bridge is connected with the alternating current input end, and the output end of the rectifier bridge is connected with one end of the first resistor, the line voltage detection module and the controlled equipment; the other end of the first resistor is connected with the anode of the first diode and the cathode of the voltage stabilizing diode; the negative electrode of the first diode is connected with one end of the first capacitor and the input end of the voltage stabilizer; the output end of the voltage stabilizer is connected with one end of the second capacitor, the control module and the wireless module; the anode of the voltage stabilizing diode, the other end of the first capacitor, the GND end of the voltage stabilizer and the other end of the second capacitor are all grounded.
In the device state synchronization control device, the line voltage detection module comprises a second resistor and a third resistor, one end of the second resistor is connected with the power supply module, the other end of the second resistor is connected with one end of the third resistor and the control module, and the other end of the third resistor is grounded.
A device state synchronization control method comprises the following steps:
the power supply module rectifies input alternating current and outputs line voltage to the line voltage detection module;
the line voltage detection module outputs a detection signal to the control module according to the line voltage;
when the state of the equipment is adjusted, state data input from the outside is received through the wireless module and is stored in the control module;
the control module counts according to the detection signal, and reads currently stored state data when the detection signal is interrupted and the counting value is a first set value;
and outputting a corresponding dimming signal to the controlled equipment according to the current count value and the state data, and clearing the count value when the count value is a second set value.
In the method for synchronously controlling the equipment state, the step of receiving externally input state data through the wireless module and storing the state data into the control module when the equipment state is adjusted comprises the following steps:
receiving the state data and shifting the state data to a data register when an output interrupt of the wireless module is detected;
and judging whether the lead code of the current state data is equal to a preset value or not, and if so, storing the state data into a state memory.
In the device state synchronization control method, the control module counts according to the detection signal, and the step of reading the currently stored state data when the detection signal is interrupted and the count value is a first set value comprises the steps of:
adding 1 by a counter every time a rising edge interruption or a falling edge interruption of the detection signal is detected;
and reading currently stored state data when the detection signal outputs rising edge interruption or falling edge interruption and the counting value is a first set value.
Compared with the prior art, in the device state synchronous control device and the synchronous control method provided by the invention, the device state synchronous control device is connected with the controlled device and comprises a power supply module, a line voltage detection module, a control module and a wireless module; the power supply module rectifies input alternating current and outputs line voltage to the line voltage detection module, and simultaneously outputs power supply voltage to the control module and the wireless receiving module; the line voltage detection module outputs a detection signal to the control module according to the line voltage; the wireless module receives state data input from the outside and stores the state data to the control module; the control module counts according to the detection signal, reads the currently stored state data when the detection signal is interrupted and the count value is a first set value, outputs a corresponding dimming signal to the controlled equipment according to the current count value and the state data, and clears the count value when the count value is a second set value. The line voltage is detected, the output detection signals are counted, the detection signal output interruption is used as a synchronous signal, the state of the controlled equipment is controlled by using the counting value as a state change period, the state synchronism of each equipment can be accurately controlled when the working states of a plurality of equipment are adjusted simultaneously, and the problem of inconsistent states caused by time difference of receiving instructions is avoided.
Drawings
Fig. 1 is a block diagram of a device state synchronization control apparatus provided in the present invention.
Fig. 2 is a circuit diagram of the device state synchronization control apparatus provided in the present invention.
Fig. 3 is a block diagram of a control module in the device state synchronization control apparatus provided in the present invention.
Fig. 4 is a flowchart of the operation of the control module in the device state synchronization control apparatus provided in the present invention.
Fig. 5 is a flowchart of a device state synchronization control method provided in the present invention.
Fig. 6 is a flowchart of step S300 in the method for controlling device state synchronization according to the present invention.
Fig. 7 is a flowchart of step S400 in the device state synchronization control method provided in the present invention.
Detailed Description
In view of the defects of the prior art that the receiving time difference of the control command is large due to the transmission rate or the distance, the updating of the states of a plurality of devices is not synchronous, and the like, the invention aims to provide a device state synchronous control device and a synchronous control method.
In order to make the objects, technical solutions and effects of the present invention clearer and clearer, the present invention is further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Referring to fig. 1, the device state synchronization control device provided by the present invention is connected to a controlled device 10, and includes a power supply module 11, a line voltage detection module 12, a control module 13, and a wireless module 14, wherein an input end of the power supply module 11 inputs ac power, an output end of the power supply module 11 is connected to the line voltage detection module 12, the control module 13, and the wireless module 14, the line voltage detection module 12 and the wireless module 14 are both connected to the control module 13, and the control module 13 is further connected to the controlled device 10.
In the invention, the power supply module 11 rectifies the input alternating current and outputs two paths of voltages, one path of output line voltage is used as a detection source and is output to the line voltage detection module 12, in addition, the line voltage rectified by the power supply module 11 in the embodiment can also be output to the controlled equipment 10 to supply power to the controlled equipment, and certainly, the line voltage can also be accessed to the alternating current through an independent rectifier bridge and then supplies power to the controlled equipment 10, and the selection can be specifically carried out according to the actual requirement; the other path outputs power supply voltage to the control module 13 and the wireless module 14 to supply power to the control module 13 and the wireless module 14; the line voltage detection module 12 outputs a detection signal to the control module 13 according to the line voltage, specifically converts the rectified periodic high-voltage signal into a periodic low-voltage signal and outputs the periodic low-voltage signal to the control module 13, so that the control module 13 can obtain a detection signal with a period equal to the line voltage period for subsequent synchronous control; when the working state of the controlled device 10 needs to be adjusted, the control module 13 receives and stores state data input from the outside through the wireless module 14, the control module 13 counts according to the detection signal, reads the currently stored state data when the output of the detection signal is interrupted and the count value is a first set value, outputs a corresponding dimming signal to the controlled device 10 according to the current count value and the state data, and clears the count value when the count value is a second set value, wherein the first set value and the second set value adopt the same value or different values, that is, the moment of acquiring the currently stored state data and the clearing moment of the counter can be synchronous or asynchronous, specifically can be selected according to needs, the device state synchronization control device provided by the invention can acquire a periodic detection signal by detecting the line voltage, when the states of a plurality of independent devices are controlled, the output detection signals are counted, the output interruption of the detection signals is taken as a synchronous signal, the latest state data is read at the moment, the state of the controlled device 10 is controlled by taking the counting value as a state change period, the state synchronism of each device can be accurately controlled when the working states of the plurality of devices are adjusted simultaneously, and the problem of state inconsistency caused by time difference of command receiving is avoided.
Further, referring to fig. 2, the power supply module 11 includes a rectifier bridge, a first resistor R1, a first diode D1, a zener diode DZ1, a first capacitor C1, a second capacitor C2, and a voltage regulator L DO, an input end of the rectifier bridge is connected to an ac input end, an output end of the rectifier bridge is connected to one end of the first resistor R1, the line voltage detection module 12, and the controlled device 10, another end of the first resistor R1 is connected to an anode of the first diode D1 and a cathode of the zener diode DZ1, a cathode of the first diode D1 is connected to one end of the first capacitor C1 and an input end of the voltage regulator L DO, an output end of the voltage regulator L DO is connected to one end of the second capacitor C2, the control module 13, and the wireless module 14, and an anode of the zener diode DZ1, another end of the first capacitor C1, a GND terminal of the first capacitor C L, and another end of the second capacitor C2 are all grounded.
In specific implementation, after the high-voltage alternating current is rectified by the rectifier bridge, one path of the alternating current outputs a line voltage to the line voltage detection module 12 and the controlled device 10, so as to provide a detection source for the subsequent control module 13 to obtain a detection signal with the same period as the line voltage, and synchronously supply power to the controlled device 10, and the other path of the alternating current converts the high-voltage alternating current into 18V direct current through the first resistor R1 and the voltage stabilizing diode DZ1, then charges the first capacitor C1 after being isolated by the first diode D1, and outputs the 18V direct current after being reduced into stable 3.3V direct current through the voltage stabilizer L DO to the control module 13 and the wireless module 14 so as to provide stable power supply voltage for the control module 13 and the wireless module 14, so.
Furthermore, the line voltage detecting module 12 includes a second resistor R2 and a third resistor R3, one end of the second resistor R2 is connected to the power supply module 11, the other end of the second resistor R2 is connected to one end of the third resistor R3 and the control module 13, and the other end of the third resistor R3 is grounded. In this embodiment, the line voltage detection module 12 is a voltage division circuit composed of a second resistor R2 and a third resistor R3, converts the rectified periodic line voltage into a periodic low-voltage signal with the highest voltage of 3.3V, and inputs the periodic low-voltage signal as a detection signal to the control module 13, so that the control module 13 can obtain a detection signal with a period equal to the output period of the line voltage detection module 12, and since the detection signal is obtained based on the line voltage conversion and the periods of the line voltages of the devices after being powered on are the same, when performing state synchronization control subsequently, the state synchronization control is performed by taking the output interruption of the line voltage detection module 12 as a synchronization signal, and the speed and distance of wireless data transmission do not need to be considered, thereby ensuring the synchronization of the device states.
Preferably, referring to fig. 3, the control module 13 includes a counter 131, an instruction receiving unit 132 and an output conversion unit 133, the counter 131 and the instruction receiving unit 132 are both connected to the output conversion unit 133, the counter 131 is further connected to the line voltage detection module 12, the instruction receiving unit 132 is further connected to the wireless module 14, and the output conversion unit 133 is further connected to the controlled device 10. In this embodiment, the counter 131, the instruction receiving unit 132, and the output converting unit 133 may be integrated in the microcontroller U1, but other implementation manners such as a separate arrangement may also be adopted in other embodiments, and the present invention is not limited thereto. The counter 131 is configured to add 1 when a rising edge interrupt or a falling edge interrupt of the detection signal is detected every time, and clear to restart counting when a count value is a second set value; the instruction receiving unit 132 is configured to receive and store the status data when detecting an output interruption of the wireless module 14; the output conversion unit 133 is configured to read currently stored state data when the detection signal outputs a rising edge interrupt or a falling edge interrupt and the count value is a first set value, and output a corresponding dimming signal to the controlled device 10 according to the current count value and the state data.
Specifically, the counter 131 counts the period of the detection signal output by the line voltage detection module 12, in a specific implementation, the analog comparator in the microcontroller U1 is used to compare the detection signal output by the line voltage detection module 12 with a reference voltage, or an IO rollover threshold is directly used to obtain a square wave signal with a period equal to the period of the detection signal in the microcontroller U1, the period is denoted as Tvc, the counter 131 is cleared after the power-on initialization is completed, 1 is added when the rising edge or the falling edge of the detection signal is interrupted every time, and counting is restarted after the count value is a second set value is cleared, because the power-on initialization time difference of the same microcontroller U1 in each device is very small, when multiple devices are powered on simultaneously, the influence on the synchronous control can be almost ignored. And the control module 13 further receives and stores the state data when the instruction receiving unit 132 detects that the output of the wireless module 14 is interrupted, that is, when the state synchronization control of a plurality of devices is performed, the wireless module 14 of each device receives and transmits the state data input from the outside to the instruction receiving unit 132, the instruction receiving unit 132 receives and stores the state data when the wireless module 14 detects that the rising edge interruption or the falling edge interruption is output by the wireless module 14 for subsequent call, and when the device state is adjusted, the output conversion unit 133 reads the currently stored state data when the rising edge interruption or the falling edge interruption is output by the detection signal and the count value is the first setting value, and outputs the corresponding dimming signal to the controlled device 10 according to the current count value and the state data.
That is, the output conversion unit 133 outputs the rising edge interrupt or the falling edge interrupt as the synchronous signal by the detection signal, and uses the count value as the state change period, specifically, reads the currently stored latest state data when the first setting value is used, clears the first setting value to restart the counting when the second setting value is used, if no new state data is received before the first setting value is counted again, the obtained state data is not changed, the dimming signal is also not changed, the controlled device 10 continues to work according to the current state, if new state data is received before the first setting value is counted again, the obtained state data is the updated state data, and outputs a corresponding new dimming signal to the controlled device 10 according to the new state data, because the line voltage detection module 12 of each device is synchronized after the devices are powered on, the count value of the counter 131 is equal when the line voltage detection module 12 outputs the interrupt, therefore, when the output conversion unit 133 outputs the dimming signal to the controlled device 10, the state of the controlled device 10 is also updated synchronously, so that the state synchronous control of the plurality of devices without time difference is realized.
The control module 13 further includes a data register and a status memory, and the instruction receiving unit 132 is specifically configured to receive the status data and shift the status data to the data register when detecting that the output of the wireless module 14 is interrupted, determine whether a preamble of the current status data is equal to a preset value, and store the status data in the status memory if the preamble is equal to the preset value, that is, when receiving the status data, receive the current status data after detecting that the output of the wireless module 14 is interrupted, but not store the current status data in the status memory, but shift the current status data to the data register, determine whether the preamble is equal to the preset value, that is, determine whether the current status data is valid data, store the status data in the status memory if the current status data is valid, otherwise discard the current status data to ensure that each time the received status data is valid data, avoid a subsequent device status control error due to a status data error, and ensure the stability and reliability of the device operation.
Further, the output conversion unit 133 is specifically configured to map the dimming state corresponding to the current count value in the read state data to a dimming signal, and output the dimming signal to the controlled device 10, where the dimming signal may be a PWM dimming signal or an analog voltage signal, and for example, the controlled device 10 is an RGB three-color lamp, and may adjust brightness or color by receiving three dimming signals of R-OUT, G-OUT, and B-OUT output by the output conversion unit 133, a duty ratio or a dimming voltage of the dimming signal is linear to brightness of the L ED lamp, when the duty ratio is 100% or the dimming voltage is 3.3V, the L ED brightness is maximum, and when the duty ratio is 0% or the dimming voltage is 0V, the corresponding L ED lamp is turned off.
For example, the first setting value of the preset counter 131 is 0, the second setting value is 299, and if the dimming state corresponding to the currently received state data 1 is Red on 50 Tvc cycles and off 50 Tvc cycles; green lights 50 Tvc cycles, lights 50 Tvc cycles; the Blue lights 50 Tvc cycles and goes OUT 50 Tvc cycles, and periodically flashes according to the rule, the output conversion unit 133 outputs a corresponding dimming state according to the current count value and the dimming state, specifically, when the line voltage detection module 12 interrupts the output and the count value is equal to 0-49, the R-OUT outputs 3.3V, G-OUT and the B-OUT outputs 0V, and when the count value is equal to 50-99, the R-OUT, the G-OUT and the B-OUT outputs 0V; when the line voltage detection module 12 outputs interrupt and the count value is equal to 100-149, the G-OUT outputs 3.3V, R-OUT and the B-OUT outputs 0V, and when the count value is equal to 150-199, the R-OUT, the G-OUT and the B-OUT outputs 0V; when the line voltage detection module 12 outputs interrupt and the count value is equal to 200-249, B-OUT outputs 3.3V, R-OUT and G-OUT outputs 0V, and R-OUT, G-OUT and B-OUT outputs 0V when the count value is equal to 250-299; because the counter 131 counts continuously from 0 to 299 periodically, the line voltage detection module 12 outputs an interrupt as a synchronous signal, the counter 131 counts as a state change period, and the PWM dimming signal or the analog voltage signal is periodically output to the controlled device 10, and each count value is added by 1 to represent a Tvc period, so that the working state of each device can be adjusted by the count value and the dimming state in the state data in combination with outputting a corresponding dimming signal, and synchronous control of a plurality of devices is realized.
In order to better understand the synchronous control process of the device state synchronous control device provided by the present invention, the following describes the working process of the device state synchronous control device provided by the present invention by taking an application embodiment with reference to fig. 4:
similarly, taking the controlled device 10 as an RGB three-color lamp as an example, the first setting value of the preset counter 131 is 0, the second setting value is 299, and the dimming state corresponding to the state data 1 is that Red is on for 50 Tvc cycles, and Red is off for 50 Tvc cycles; green lights 50 Tvc cycles, lights 50 Tvc cycles; blue lights 50 Tvc cycles, goes out 50 Tvc cycles, and periodically flickers according to the rule, and state data 2 corresponds to the state: red Red lights 20 Tvc cycles, goes out 80 Tvc cycles; green lights 20 Tvc cycles and goes out 80 Tvc cycles; blue lights 20 Tvc cycles and goes out 80 Tvc cycles; periodically flashing according to the rule.
When the two RGB three-color lamps are controlled to work synchronously, after power-on, the two L ED lamps L EDA and L EDB are initialized and reset the corresponding counters 131CNTA and CNTB respectively, the output period Tvc of the 300 line voltage detection modules 12 is counted periodically, when the output interruption of the line voltage output modules is detected and the counters 131CNT are the first set value 0, the L EDA and L EDB read out state data from the state memories respectively and flicker according to the state set by the state data, and when the output interruption of the line voltage output modules is detected and the counters 131CNT are the second set value 299, the corresponding counters 131A and CNTB are reset respectively.
For example, in the first counting period, when CNT is 0, status data 1 is read from the status memory, and the status of L EDA and L EDB is changed correspondingly according to the status set by status data 1 according to the count value of counter 131, that is, the red, green and blue lamps are alternately turned on for 50 Tvc cycles in sequence and then turned off for 50 Tvc cycles, in the second counting period, L EDA and L EDB continue to change according to the status set by status data 1, at a certain moment, due to the wireless transmission rate or distance difference, L EDA and L EDB detect the interruption of the output of wireless module 14 in sequence, receive new status data 2 and store it in the respective status memories, in the third counting period, when CNT is 0, status data 2 is read from the status memory, and the status of L EDB and L EDB is changed correspondingly according to the status set by status data 2 of counter 131, that the red, green and blue lamps are alternately turned on for 80 Tvc cycles and then turned off for 20 Tvc cycles, thereby realizing that two devices are synchronously controlled in the third cycle, and providing more effective synchronization control over the synchronization of the wireless module, and further avoiding the problem of the synchronization of the control of the device, and the synchronization of the invention, and the synchronization control of the synchronization of the wireless modules, which the synchronization control of the wireless module, and the synchronization of the synchronization control device, and the synchronization of the synchronization control device, which the synchronization control device, and.
Correspondingly, the present invention further provides an apparatus state synchronization control method, as shown in fig. 5, the apparatus state synchronization control method includes the following steps:
s100, a power supply module rectifies input alternating current and outputs line voltage to a line voltage detection module;
s200, the line voltage detection module outputs a detection signal to a control module according to the line voltage;
s300, receiving externally input state data through the wireless module and storing the state data to the control module when the equipment state is adjusted;
s400, the control module counts according to the detection signal, and reads currently stored state data when the detection signal is interrupted and the count value is a first set value;
and S500, outputting a corresponding dimming signal to the controlled equipment according to the current count value and the state data, and clearing the count value when the count value is a second set value.
As shown in fig. 6, wherein the step S300 includes:
s301, receiving the state data and shifting the state data to a data register when the output interruption of the wireless module is detected;
s302, judging whether the lead code of the current state data is equal to a preset value or not, and storing the state data into a state memory if the lead code of the current state data is equal to the preset value.
As shown in fig. 7, the step S400 includes:
s401, adding 1 when detecting the rising edge interruption or the falling edge interruption of the detection signal every time through a counter;
s402, reading the currently stored state data when the detection signal outputs rising edge interruption or falling edge interruption and the counting value is a first set value.
In summary, in the device state synchronization control apparatus and the synchronization control method provided by the present invention, the device state synchronization control apparatus is connected to a controlled device, and includes a power supply module, a line voltage detection module, a control module, and a wireless module; the power supply module rectifies input alternating current and outputs line voltage to the line voltage detection module, and simultaneously outputs power supply voltage to the control module and the wireless receiving module; the line voltage detection module outputs a detection signal to the control module according to the line voltage; the wireless module receives state data input from the outside and stores the state data to the control module; the control module counts according to the detection signal, reads the currently stored state data when the detection signal is interrupted and the count value is a first set value, outputs a corresponding dimming signal to the controlled equipment according to the current count value and the state data, and clears the count value when the count value is a second set value. The line voltage is detected, the output detection signals are counted, the detection signal output interruption is used as a synchronous signal, the state of the controlled equipment is controlled by using the counting value as a state change period, the state synchronism of each equipment can be accurately controlled when the working states of a plurality of equipment are adjusted simultaneously, and the problem of inconsistent states caused by time difference of receiving instructions is avoided.
It should be understood that equivalents and modifications of the technical solution and inventive concept thereof may occur to those skilled in the art, and all such modifications and alterations should fall within the scope of the appended claims.

Claims (8)

1. The equipment state synchronous control device is connected with a controlled device and is characterized by comprising a power supply module, a line voltage detection module, a control module and a wireless module; the power supply module rectifies input alternating current and outputs line voltage to the line voltage detection module, and simultaneously outputs power supply voltage to the control module and the wireless receiving module; the line voltage detection module outputs a detection signal to the control module according to the line voltage; the wireless module receives state data input from the outside and stores the state data to the control module; the control module counts according to the detection signal, reads currently stored state data when the detection signal is interrupted and the count value is a first set value, outputs a corresponding dimming signal to controlled equipment according to the current count value and the state data, and clears the count value when the count value is a second set value, wherein the first set value and the second set value adopt the same value or different values;
the control module comprises a counter, an instruction receiving unit and an output conversion unit; the counter is used for adding 1 when the rising edge interruption or the falling edge interruption of the detection signal is detected every time, clearing and restarting counting when the count value is a second set value, and controlling the state of the controlled equipment by taking the count value as a state change period; the instruction receiving unit is used for receiving and storing the state data when the output interruption of the wireless module is detected; the output conversion unit is used for reading currently stored state data when the detection signal outputs rising edge interruption or falling edge interruption and the counting value is a first set value, and outputting a corresponding dimming signal to the controlled equipment according to the current counting value and the state data;
if the new state data is not received before the first set value is counted again, the obtained state data is unchanged, the dimming signal is also unchanged, the controlled equipment continues to work according to the current state, if the new state data is received before the first set value is counted again, the obtained updated state data is obtained, and the corresponding new dimming signal is output to the controlled equipment according to the new state data.
2. The device state synchronization control apparatus according to claim 1, wherein the control module further includes a data register and a state memory, and the instruction receiving unit is specifically configured to receive the state data and shift the state data to the data register when detecting that the output of the wireless module is interrupted, determine whether a preamble of the current state data is equal to a preset value, and store the state data in the state memory if the preamble of the current state data is equal to the preset value.
3. The device state synchronization control apparatus according to claim 1, wherein the output conversion unit is specifically configured to map a dimming state corresponding to a current count value in the read state data to a dimming signal, and output the dimming signal to a controlled device.
4. The device state synchronization control apparatus according to any one of claims 1-3, wherein the dimming signal is a PWM dimming signal or an analog voltage signal.
5. The device state synchronous control device according to claim 1, wherein the power supply module comprises a rectifier bridge, a first resistor, a first diode, a voltage regulator diode, a first capacitor, a second capacitor and a voltage regulator; the input end of the rectifier bridge is connected with the alternating current input end, and the output end of the rectifier bridge is connected with one end of the first resistor, the line voltage detection module and the controlled equipment; the other end of the first resistor is connected with the anode of the first diode and the cathode of the voltage stabilizing diode; the negative electrode of the first diode is connected with one end of the first capacitor and the input end of the voltage stabilizer; the output end of the voltage stabilizer is connected with one end of the second capacitor, the control module and the wireless module; the anode of the voltage stabilizing diode, the other end of the first capacitor, the GND end of the voltage stabilizer and the other end of the second capacitor are all grounded.
6. The device state synchronous control device according to claim 1, wherein the line voltage detection module comprises a second resistor and a third resistor, one end of the second resistor is connected to the power supply module, the other end of the second resistor is connected to one end of the third resistor and the control module, and the other end of the third resistor is grounded.
7. A device state synchronization control method is characterized by comprising the following steps:
the power supply module rectifies input alternating current and outputs line voltage to the line voltage detection module;
the line voltage detection module outputs a detection signal to the control module according to the line voltage;
when the state of the equipment is adjusted, state data input from the outside is received through the wireless module and is stored in the control module;
the control module counts according to the detection signal, and reads currently stored state data when the detection signal is interrupted and the counting value is a first set value;
outputting a corresponding dimming signal to the controlled equipment according to the current count value and the state data, and clearing the count value when the count value is a second set value;
the control module counts according to the detection signal, and the step of reading the currently stored state data when the detection signal is interrupted and the count value is a first set value comprises the following steps:
adding 1 by a counter every time a rising edge interruption or a falling edge interruption of the detection signal is detected;
reading currently stored state data when the detection signal outputs rising edge interruption or falling edge interruption and the counting value is a first set value;
if the new state data is not received before the first set value is counted again, the obtained state data is unchanged, the dimming signal is also unchanged, the controlled equipment continues to work according to the current state, if the new state data is received before the first set value is counted again, the obtained updated state data is obtained, and the corresponding new dimming signal is output to the controlled equipment according to the new state data.
8. The device status synchronization control method according to claim 7, wherein the step of receiving status data inputted from outside through the wireless module and storing the status data in the control module when adjusting the device status comprises:
receiving the state data and shifting the state data to a data register when an output interrupt of the wireless module is detected;
and judging whether the lead code of the current state data is equal to a preset value or not, and if so, storing the state data into a state memory.
CN201811177440.9A 2018-10-10 2018-10-10 Device state synchronous control device and synchronous control method Active CN109195263B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811177440.9A CN109195263B (en) 2018-10-10 2018-10-10 Device state synchronous control device and synchronous control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811177440.9A CN109195263B (en) 2018-10-10 2018-10-10 Device state synchronous control device and synchronous control method

Publications (2)

Publication Number Publication Date
CN109195263A CN109195263A (en) 2019-01-11
CN109195263B true CN109195263B (en) 2020-07-14

Family

ID=64947507

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811177440.9A Active CN109195263B (en) 2018-10-10 2018-10-10 Device state synchronous control device and synchronous control method

Country Status (1)

Country Link
CN (1) CN109195263B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112469166B (en) * 2020-11-06 2023-03-17 深圳市晟碟半导体有限公司 LED lamp control circuit, control method and LED lamp

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN203313462U (en) * 2013-05-03 2013-11-27 深圳市雷达光电科技有限公司 LED street lamp synchronization control device
CN104582057A (en) * 2013-10-11 2015-04-29 东林科技股份有限公司 Control method for multiple lamps

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004030954A (en) * 2002-06-21 2004-01-29 Toshiba Lighting & Technology Corp Wireless dimmer and wireless dimmer lighting system
US8362713B2 (en) * 2006-03-28 2013-01-29 Wireless Environment, Llc Wireless lighting devices and grid-shifting applications
WO2014007981A1 (en) * 2012-07-03 2014-01-09 Smartlabs, Inc. Simulcast mesh dimmable illumination source
CN205847695U (en) * 2016-07-01 2016-12-28 浙江大邦科技有限公司 Illuminator, illumination driving power source and controller thereof
CN205956907U (en) * 2016-07-22 2017-02-15 福建船政交通职业学院 Tunnel lamp
CN107277914B (en) * 2017-06-15 2018-06-29 深圳市晟碟半导体有限公司 Equipment time synchronization control method and system in a kind of wireless mesh network

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN203313462U (en) * 2013-05-03 2013-11-27 深圳市雷达光电科技有限公司 LED street lamp synchronization control device
CN104582057A (en) * 2013-10-11 2015-04-29 东林科技股份有限公司 Control method for multiple lamps

Also Published As

Publication number Publication date
CN109195263A (en) 2019-01-11

Similar Documents

Publication Publication Date Title
US10660173B2 (en) System and method using switch to realize light fixture dimming and state restoration
US8072164B2 (en) Unified 0-10V and DALI dimming interface circuit
US9736915B2 (en) Driver for a light source
TWI377871B (en) Power supply system and liquid crystal display device having the same
JP5078706B2 (en) Lighting device
JP2009205841A (en) Illumination control system
CN109892010B (en) Dimmable lighting device
CN110022630B (en) PWM flicker-free digital dimming device and method
CN109195263B (en) Device state synchronous control device and synchronous control method
US20200305249A1 (en) Combinational circuit and control circuit
WO2021146984A1 (en) Illumination apparatus and illumination control system thereof
CN116614916B (en) Intelligent lighting driving multi-signal detection circuit and device
US9445479B2 (en) Dimming control method and apparatus and dimming system
CN205793511U (en) A kind of LED drive circuit of configurable parameter
TW201515509A (en) LED driver circuits
CN210899726U (en) Trinity control interface circuit of lamps and lanterns
CN210609797U (en) Power supply driving equipment capable of automatically matching multi-specification light source loads and lamp
CN109743807B (en) Anti-interference infrared dimming control system and infrared dimming control method
CN110856319A (en) Multi-lamp synchronous control method, single chip microcomputer and multi-lamp control system
JP4971076B2 (en) Lighting dimming system
JP2009032493A (en) Illumination light control system
CN212163779U (en) Light-operated synchronous circuit of LED lamp and LED lamp
CN211240202U (en) Light detection circuit of LED lamp and LED lamp
CN219421090U (en) Light source controller
TWI398963B (en) Light emitting diode driving device and light system

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