主权项 |
1. A controller configured to control a light source according to a plurality of illumination states subject to determine an event of a plurality of events, wherein the controller is configured to control a power converter that converts power derived from an input voltage waveform of a line voltage power supply into a drive signal for the light source; the controller configured to operate in a power-on mode and in a power-off mode, the controller comprising:
a first clock circuit configured to generate a first clock signal, wherein the first clock circuit is enabled to operate in the power-on mode; a first state processor configured to determine a next illumination state of the plurality of illumination states, based on a detected event and on a current illumination state; wherein the first state processor is configured to operate in the power-on mode and in accordance to the first clock signal; a second clock circuit configured to generate a second clock signal, wherein the second clock circuit is enabled to operate at least in the power-off mode; a control circuit configured to operate in the power-off mode and in accordance to the second clock signal, the control circuit comprising a timing circuit for determining a power-off time value; whereinin response to detection of a line voltage power-off event, the controller changes the operation mode from the power-on mode to the power-off mode and the timing circuit is enabled to start counting, andin response to detection of a line voltage power-on event, the controller changes the operation mode from the power-off mode to the power-on mode. |