1. Field of the Invention
The present invention relates to a frequency switching method and a frequency switching device. The frequency switching method is executed under the control of a microcomputer. The frequency switching device controls the operation of various types of application devices based on pulse signals. And, more particularly, the present invention relates to a frequency switching method based on the control of a microcomputer and a frequency switching device for supplying pulse signals of a desired frequency to a driver in order to control the operation of each application device.
2. Description of the Related Art
There are devices whose operation are controlled based on pulse signals having a desired frequency. Those devices have been widely used in various application fields. For example, there is a lighting device of an inverter fluorescent lamp as one of examples of those application devices. In order to operate the lighting device of the inverter fluorescent lamp efficiently, it must be required to heat the inverter fluorescent lamp, and then to discharge the inverter fluorescent lamp, and finally to light the inverter fluorescent lamp. For each of the three operations above, it must be required to supply a pulse signal of an optimum frequency. In other words, it must be required to generate and supply an optimum resonance frequency for each of the three operations, the heating operation, the discharging operation, and the lighting operation. In order to achieve this, it is required to oscillate the pulse signal by slightly changing the frequency of the pulse signal during the lighting process for the inverter fluorescent lamp. And it is then required to supply the pulse signal having the optimum frequency to the driver circuit for the inverter fluorescent lamp.
A conventional inverter lighting device of the inverter fluorescent lamp incorporates an analogue circuit to generate a pulse signal of a high frequency of several ten KHz and to supply the generated pulse signal to the inverter fluorescent lamp. There is a CR oscillator as this analogue circuit. The CR oscillator generates the pulse signal of the desired optimum high frequency by changing the values of an internal resistance and a capacitance that are made up of the CR oscillator.
Recently, the lighting device incorporates the driver circuit comprising a microcomputer, and the frequency of a clock signal to be used in the microcomputer is divided into a half dividing ratio (xc2xd) of the frequency. Thereby, the driver circuit provides the pulse signal having a high frequency of a half-dividing ratio to the inverter fluorescent lamp.
There is a conventional patent document as a prior art, Japanese Laid-open Publication Number JP-A-5/211098 that has disclosed a conventional inverter lighting circuit.
FIG. 1 is a circuit diagram showing the conventional inverter lighting circuit. In FIG. 1, the reference number 91 designates an AC power source, 92 denotes a DC power circuit, 93 indicates a control circuit, 94 designates a microcomputer incorporated in the control circuit 93. The control circuit 93 inputs pulse signals that are generated by and transferred from the microcomputer 94. The microcomputer 93 switches (or changes) the pulse signal into another pulse signal having a desired frequency by which a switching element 95 consisting of a MOS FET is controlled. The microcomputer 93 then outputs the desired pulse signal to the switching element 95. The reference number 95 designates the switching element consisting of the MOS FET that operates under the control of the pulse signal provided from the control circuit 93. The reference number 96 indicates an inverter fluorescent lamp.
A description will be given of the operation of the conventional inverter lighting circuit shown in FIG. 1.
In the conventional inverter lighting circuit shown in FIG. 1, a dividing ratio of the clock signal used in the microcomputer 94 is switched (or changed). In addition, the lighting operation of the fluorescent lamp 96 is controlled by using the pulse signal of a 50 percent duty that has been obtained by dividing the frequency of the clock signal.
Since the pulse generation method and the control circuit for generating the pulse signals of a desired frequency has the configuration described above, some types of the microcomputers causes following drawbacks.
For example, when the timer value of the timer incorporated in the microcomputer is switched (or changed), namely, when the dividing rate of the clock signal is changed, some types of the microcomputers require the halt of the operation of the timer in order to switch the timer value and then to re-start the operation of the timer. In addition, other types of the microprocessors are automatically reset when a new timer value is written into the timer. The conventional inverter lighting circuits incorporating those microcomputers have a drawback in which an abnormal pulse having a small pulse width (for example, a half or less) that is very smaller than the width of the pulse that being currently oscillated is generated, and the abnormal pulse gives a damage to the switching device (for example, the switching element 95 consisting of the MOS FET shown in FIG. 1), and sometimes breaks the switching device by receiving the abnormal pulse.
Accordingly, in the frequency switching method of generating an optimum frequency of the pulse signal to change an inverter vibration-frequency to be used by the inverter lighting circuit, it must be required to provide the microcomputer capable of switching or changing a newly desired timer value at a following start timing without any changing of the timer value that is currently used.
In the explanation described above, this requirement arises in the conventional inverter lighting circuit. However, the same problem also arises in various kinds of devices whose operations are controlled based on pulse signals of different frequencies.
Accordingly, an object of the present invention is, with due consideration to the drawbacks of the conventional technique, to provide a frequency switching method and frequency switching device that is capable of switching a current timer value in a timer to a desired timer value based on the timing of the pulse signal of a current frequency. This feature can avoid to damage a driver such as a switching device and can switch the pulse signal of the current frequency to a pulse signal of a desired frequency smoothly.
In accordance with a preferred embodiment of the present invention, a frequency switching method to be executed by a microcomputer has the following steps of: detecting required times signal levels of pulse signals continuously generated by and outputted from a timer incorporated in said microcomputer; halting an operation of said timer, simultaneously outputting a predetermined level of a signal from said microcomputer while the operation of said timer is halted, and setting a desired timer value to said timer within a predetermined time period counted from a detection time of a last pulse signal having a predetermined level in said detected pulse signals when said detection results of the signal levels of the pulse signals is matched to a predetermined pattern; restarting the operation of said timer after said predetermined time period is passed, and setting a level of a first pulse signal, to be outputted firstly at the restart time of said timer, into a predetermined level; and outputting said pulse signal having the predetermined frequency to outside of said microcomputer.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a H level, a L level, and a H level, in order, and said predetermined time period is a time of a xc2xd wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer is the H level while the operation of said timer is halted, and a level of a first pulse signal to be outputted is the L level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a L level, a H level, and a L level, in order, and said predetermined time period is a time of a xc2xd wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer is the L level while the operation of said timer is halted, and a level of a first pulse signal to be outputted firstly is the H level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a L level, a H level, and a L level, in order, and said predetermined time period is a time of one wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer during a first half in said one wavelength is the L level while the operation of said timer is halted, and the level of the signal to be outputted from said microcomputer during a latter half in said one wavelength is the H level while the operation of said timer is halted, and a level of a first pulse signal to be outputted firstly is the L level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a H level, a L level, and a H level, in order, and said predetermined time period is a time of one wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer during a first half in said one wavelength is the H level while the operation of said timer is halted, and the level of the signal to be outputted from said microcomputer during a latter half in said one wavelength is the L level while the operation of said timer is halted, and a level of a first pulse signal to be outputted firstly is the H level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a L level and a H level, in order, and said predetermined time period is a time of a xc2xd wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer is the H level while the operation of said timer is halted, and a level of a first pulse signal to be outputted is the L level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a H level and a L level, in order, and said predetermined time period is a time of a xc2xd wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer is the L level while the operation of said timer is halted, and a level of a first pulse signal to be outputted firstly is the H level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a H level and a L level, in order, and said predetermined time period is a time of one wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer during a first half in said one wavelength is the L level while the operation of said timer is halted, and the level of the signal to be outputted from said microcomputer during a latter half in said one wavelength is the H level while the operation of said timer is halted, and a level of a first pulse signal to be outputted firstly is the L level when said timer is restarted.
In the frequency switching method as another preferred embodiment of the present invention, the agreement of the matching of said detection results of the signal levels of the pulse signals to said predetermined pattern means that said detection results indicate a L level and a H level, in order, and said predetermined time period is a time of one wavelength of said pulse signal, and the level of the signal to be outputted from said microcomputer during a first half in said one wavelength is the H level while the operation of said timer is halted, and the level of the signal to be outputted from said microcomputer during a latter half in said one wavelength is the L level while the operation of said timer is halted, and a level of a first pulse signal to be outputted firstly is the H level when said timer is restarted.
In accordance with a preferred embodiment of the present invention, a frequency switching device has a microcomputer and a driver circuit for controlling a device as a target of control operation. Said microcomputer includes: a memory circuit for storing a control program and control data for controlling operation of said target device; a timer for generating and outputting pulse signals of xc2xd duty of a desired frequency by changing a timer value; and an input/output port through which said control data and said pulse signals are transferred to said driver circuit. Said driver circuit is connected to said input/output port, and said driver circuit inputs said pulse signals outputted from said microcomputer through said input/output port, and said microcomputer executes said control program capable of performing each of said frequency switching methods according to the present invention described above.
USPTO Backgrounds
USPTO Backgrounds