JPS5915334A - Programmable frequency generator - Google Patents

Programmable frequency generator

Info

Publication number
JPS5915334A
JPS5915334A JP57124660A JP12466082A JPS5915334A JP S5915334 A JPS5915334 A JP S5915334A JP 57124660 A JP57124660 A JP 57124660A JP 12466082 A JP12466082 A JP 12466082A JP S5915334 A JPS5915334 A JP S5915334A
Authority
JP
Japan
Prior art keywords
output
frequency
microcomputer
counter
programmable
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.)
Granted
Application number
JP57124660A
Other languages
Japanese (ja)
Other versions
JPH0153810B2 (en
Inventor
Takashi Deguchi
隆 出口
Kazumi Kamiyama
神山 一実
Hidekazu Tadamatsu
只松 英一
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP57124660A priority Critical patent/JPS5915334A/en
Publication of JPS5915334A publication Critical patent/JPS5915334A/en
Publication of JPH0153810B2 publication Critical patent/JPH0153810B2/ja
Granted legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03KPULSE TECHNIQUE
    • H03K23/00Pulse counters comprising counting chains; Frequency dividers comprising counting chains
    • H03K23/64Pulse counters comprising counting chains; Frequency dividers comprising counting chains with a base or radix other than a power of two
    • H03K23/66Pulse counters comprising counting chains; Frequency dividers comprising counting chains with a base or radix other than a power of two with a variable counting base, e.g. by presetting or by adding or suppressing pulses
    • H03K23/665Pulse counters comprising counting chains; Frequency dividers comprising counting chains with a base or radix other than a power of two with a variable counting base, e.g. by presetting or by adding or suppressing pulses by presetting

Landscapes

  • Inverter Devices (AREA)

Abstract

PURPOSE:To change freely the frequency dividing ratio without increasing the number of component parts, by securing a part of a comparatively low frequency with division of a microcomputer MC. CONSTITUTION:A frequency fOSC generated from a reference frequency generator 1 is supplied to a CLK terminal of a programmable counter 2. The address codes are fed to address inputs P0-P7 from outputs O0-O7 of a microcomputer MC2. Thus the frequency dividing ratio is decided. The direct output of the counter 2 is set at f1 and then turned into an output f2 of a binary counter 4 which is incorporated into the counter 2. Then the output f2 is fed to an interruption input I0 of an MC3. An output f3 is obtained by dividing the output f2 with the software of the MC3. The final frequency output fOUT is delivered selectively via a selection output circuit 5 designated by output terminals O01- O03 of the MC3 and on the basis of a frequency range.

Description

【発明の詳細な説明】 産業上の利用分野 本発明は、主として可変速のエアコン用コンプレッサモ
ータなどに適用でき、またメロディ合成用としても利用
できるプログラマブル周波数発生器に関するものである
DETAILED DESCRIPTION OF THE INVENTION Field of Industrial Application The present invention relates to a programmable frequency generator that can be mainly applied to variable speed compressor motors for air conditioners, and can also be used for melody synthesis.

従来例の構成とその問題点 従来、分周比が広帯域にわたるプログラマブルタイマを
構成するには第1図に示すように分周率を広範囲とする
か、第2図に示すように低ビットのプログラマブルカウ
ンタと、バイナリカウンタなどの縦続接続による方法が
知られている。ちなみにプログラマブルカウンタにより
分周された周波数出力は次式で表わされる。
Conventional configurations and their problems Traditionally, in order to configure a programmable timer with a wide frequency division ratio, it is necessary to use a wide range of frequency division ratios as shown in Figure 1, or to use a low-bit programmable timer as shown in Figure 2. A method using a cascade connection of a counter and a binary counter is known. Incidentally, the frequency output divided by the programmable counter is expressed by the following equation.

ここで、foscは基準発振器入力、foUTは周波数
出力、nは分周比、aはプログラマブルカウンタのアド
レスビット数である。
Here, fosc is the reference oscillator input, foUT is the frequency output, n is the frequency division ratio, and a is the number of address bits of the programmable counter.

第1図は上式のアドレスビット数aを増加した例である
FIG. 1 is an example in which the number a of address bits in the above formula is increased.

第1図の回路は基準発振部1で周波数foscを発生し
、これをプログラマブルカウンタ2に入力スル。一方マ
イクロコンビーータ3の出力端子Φ 〜Φ −よりプロ
グラマブルカウンタ2のQ  (al) アドレス人力P −P −に2進数のアドレス○  (
al) コードが設定されている。fOUTはfoscを分周し
た出力端子である。
In the circuit shown in FIG. 1, a reference oscillator 1 generates a frequency fosc and inputs it to a programmable counter 2. On the other hand, from the output terminals Φ ~ Φ - of the microconbeater 3, the Q (al) address P - P - of the programmable counter 2 is input to the binary address ○ (
al) Code is set. fOUT is an output terminal obtained by frequency-dividing fosc.

ここで、アドレスビット数aを8とすると分周比nは1
〜256となり、まだアドレスビット数aを10とする
と、分周比nは1〜1023となり、さらにアドレスビ
ット数aを12とすると、分周比nは1〜4096とな
り、このようにアドレスビット数aを適当に選ぶことに
より所期の目的を達することはできるが、この構造は市
場に多ビットのプログラマブルカウンタが存在しないこ
トド、マイクロコンビーータのアドレス出力本数が増加
し、ソフトウェアが繁雑となるなどの欠点を有している
Here, if the number of address bits a is 8, the division ratio n is 1
~256, and if the number of address bits a is still 10, the division ratio n will be 1 to 1023. Furthermore, if the number of address bits a is 12, the division ratio n will be 1 to 4096, and in this way, the number of address bits will be Although it is possible to achieve the desired purpose by appropriately selecting a, this structure requires an increase in the number of address outputs of the microconbeater, as there are no multi-bit programmable counters on the market, and the software becomes complicated. It has disadvantages such as:

次に第2図の構造について説明する。Next, the structure shown in FIG. 2 will be explained.

同図において、1・2・3は第1図と同じ基準発振部、
プログラマブルカウンタ、マイクロコンピュータを示し
、4は数段のバイナリ−カウンタ部である。この回路の
出力foUTはバイナリ−カウンタ部4の各段の出力を
マイクロコンピュータ3の出力d。1〜Φ。□を用いて
選択する出力選択部6により選択出力される。
In the figure, 1, 2, and 3 are the same reference oscillation parts as in Figure 1;
A programmable counter and a microcomputer are shown, and 4 is a binary counter section with several stages. The output foUT of this circuit is the output of each stage of the binary counter section 4 and the output d of the microcomputer 3. 1~Φ. Selected output is made by the output selection section 6 which selects using □.

一例としで、プログラマブルカウンタ2が8ビツトで出
力fOUTとしてfO8c/eoo  が必要な場合プ
ログラマブルカウンタ2の分周範囲は分周比nが1〜2
65であるからその出力はfoUT−fO8C/(15
0X22)となる0 したがって、マイクロコンピュータ3の出力端子07〜
C5゜から出力されるアドレスコードは1001011
0となり、マイクロコンピュータ3の出力端子Φ。(x
−2)のみを”H”とすることにより得られる。この方
法では分周比がある程度任意に作り出せ、市場にある汎
用のICを用いて構成できるという利点はあるものの、
部品点数が多く、マイクロコンビーータの出力端子も多
く占有し、実用的ではない。
As an example, if the programmable counter 2 has 8 bits and fO8c/eoo is required as the output fOUT, the frequency division range of the programmable counter 2 is a frequency division ratio n of 1 to 2.
65, its output is foUT−fO8C/(15
0X22) Therefore, the output terminals 07 to 0 of the microcomputer 3
The address code output from C5° is 1001011
0, and the output terminal Φ of the microcomputer 3. (x
-2) can be obtained by setting only "H". Although this method has the advantage that the frequency division ratio can be created arbitrarily to some extent and can be configured using general-purpose ICs on the market,
It has a large number of parts and occupies many output terminals of the microconbeater, making it impractical.

発明の目的 本発明は、上記従来の欠点を克服するべく、汎用のIC
を用い、マイクロコンピュータのソフトウェアに大きな
負担をかけず、まだ出力端子も多く占有せず、簡単な回
路構成のプログラマブルカウンタが得られることを目的
とするものである。
Purpose of the Invention The present invention aims to overcome the above-mentioned drawbacks of the conventional IC.
The purpose of this invention is to obtain a programmable counter with a simple circuit configuration that does not place a large burden on the software of the microcomputer and does not occupy many output terminals.

発明の構成 本発明は、マイクロコンピュータで充分追随できる領域
の周波数をマイクロコンピュータのソフトウェアによる
分周で合成し、その周波数以上の周波数領域をプログラ
マブルカウンタの出力を直接出力することにより合わせ
てプログラマブルカウンタとバイナリカウンタの縦続接
続回路を等価的に構成し、ソフトウェア分周を任意の整
数としてバイナリカウンタを使用するよりはより自由度
を高くしたものである。
Structure of the Invention The present invention synthesizes frequencies in a range that can be tracked sufficiently by a microcomputer by frequency division using microcomputer software, and directly outputs the output of a programmable counter in a frequency range above that frequency. A cascade circuit of binary counters is equivalently configured, and the software frequency division is set to an arbitrary integer, giving a higher degree of freedom than using a binary counter.

実施例の説明 以下、本発明の一実施例としてルームエアコン用インバ
ータのPWM方式の原発振回路の構成について第3図に
より説明する。ここでPWM方式とはパルス巾変調方式
の略語でインバータに加える電圧の時間による積分値が
正弦波に近似するように電圧のチョッピングアルゴリズ
ムを構成した方式である。
DESCRIPTION OF EMBODIMENTS The structure of a PWM type original oscillation circuit for a room air conditioner inverter will be described below as an embodiment of the present invention with reference to FIG. The PWM method is an abbreviation for pulse width modulation method, and is a method in which a voltage chopping algorithm is configured so that the integral value over time of the voltage applied to the inverter approximates a sine wave.

同図において、1は基準周波数、roscを発生する基
準周波数発生器、2はバイナリカウンタを内蔵した汎用
のプログラマブルカウンタ、3はP−MOSのマイクロ
コンピュータ、4はプログラマブルカウンタ2に内蔵さ
れたバイナリカウンタ、6は出力周波数レンジによりデ
ータf1.f2およびf3を切換え出力する選択出力回
路である。
In the figure, 1 is a reference frequency generator that generates a reference frequency and ROSC, 2 is a general-purpose programmable counter with a built-in binary counter, 3 is a P-MOS microcomputer, and 4 is a binary counter built in the programmable counter 2. , 6 are data f1., 6 depending on the output frequency range. This is a selection output circuit that switches and outputs f2 and f3.

上記構成において、基準周波数発振器1により発生した
周波数foscはプログラマブルカウンタ2のCLK端
子に入力され、アドレス人力P。〜P7ヘマイクロコン
ピユータ3の出力Φ。〜0□よりアドレスコードが入力
され分周比が決定される。
In the above configuration, the frequency fosc generated by the reference frequency oscillator 1 is input to the CLK terminal of the programmable counter 2, and the address input P is inputted to the CLK terminal of the programmable counter 2. ~P7 Output Φ of microcomputer 3. An address code is input from ~0□ and the frequency division ratio is determined.

プログラマブルカウンタ2の直接出力はfl であり、
プログラムカウンタ2に内蔵されたバイナリカウンタ4
の出力はf2で、この出力f2はマイクロコンピュータ
3の割り込み入カニ。に入力されている。前記出力f2
をマイクロコンピュータ3のソフトウェアにより分周し
た出力がf3で、最終周波数出力fOUTは周波数レン
ジによりマイクロコンピーータ3の出力端子・Φ。1〜
○o3により指定された選択出力回路5を経て選択出力
される。ここでfl−foSC/n (n−1〜265
)。
The direct output of programmable counter 2 is fl,
Binary counter 4 built into program counter 2
The output is f2, and this output f2 is the interrupt input crab for the microcomputer 3. has been entered. Said output f2
The output obtained by dividing the frequency by the software of the microcomputer 3 is f3, and the final frequency output fOUT is determined by the frequency range of the output terminal of the microcomputer 3. 1~
It is selectively outputted via the selective output circuit 5 specified by o3. Here fl-foSC/n (n-1~265
).

’2”fO8C/(2xn)(n=1〜265)、f3
−fO8C/ (2XnXm) (n、=1〜255 
、m=1 、2 、3・・・・・)となる。ちなみにn
はプログラマブルカウンタ2のアドレス入力(Po〜P
7)に加えられるバイナリ−コードであり、mはマイク
ロコンピュータ3のソフトウェアによる分周比である。
'2"fO8C/(2xn) (n=1~265), f3
-fO8C/ (2XnXm) (n, = 1 ~ 255
, m=1, 2, 3...). By the way, n
is the address input of programmable counter 2 (Po~P
7), where m is a frequency division ratio determined by the software of the microcomputer 3.

ここでマイクロコンピュータ3は通常、他のシステム制
御も受は持っており、スピードもそれほど早くできない
ので、出力f3の出方時における出力f2は比較的低い
周波数に設定する必要がある。
Here, the microcomputer 3 usually has control over other systems and cannot operate at a very high speed, so it is necessary to set the output f2 at a relatively low frequency when the output f3 is output.

ルームエアコン用インバータのPWM方式は通常モータ
の同期周波数f。にキャリアを乗じたものを原発振とす
る場合が多いが、ここでその一実施例の計算結果を第4
図に示す。同図に示すものはキャリアを42 、 f 
03c = 320 KHz 、、周波数出力範囲を同
期周波数に換算して、2〜90 HzとしてIHzステ
ップで出力できるようにしたものである。分周比の欄に
おいて左側第1項の85〜264はプログラマブルカウ
ンタ分周比、第2項はプログラマブルカウンタに付属し
たバイナリカウンタの出力指定、第3項の2の乗数はマ
イクロコンピュータのソフトウェアにょる分周比ヲ示し
ている6゜ 第4図よりf3の出力時はマイクロコンピュータに入力
している周波数の最大値が’O8C/(2x136)−
41,1KHz程度となっており、この程度のf直であ
れば市販の4ピツトのマイクロコンピー−タでも充分追
随して処理しうる値である。まだマイクロコンピュータ
3の入カニ。が割り込み入力できない場合は、ソフトウ
ェアによるタイマを使用して出力f3を合成することも
できる。
The PWM method of inverters for room air conditioners usually uses the motor's synchronous frequency f. In many cases, the original oscillation is obtained by multiplying
As shown in the figure. The one shown in the same figure has a carrier of 42, f
03c = 320 KHz, the frequency output range is converted into a synchronous frequency, which can be output in IHz steps as 2 to 90 Hz. In the frequency division ratio column, the first term on the left, 85 to 264, is the programmable counter frequency division ratio, the second term is the output specification of the binary counter attached to the programmable counter, and the third term, the multiplier of 2, is determined by the microcomputer software. From Figure 4, which shows the frequency division ratio of 6°, when outputting f3, the maximum value of the frequency input to the microcomputer is 'O8C/(2x136)-
The frequency is approximately 41.1 KHz, which is a value that can be sufficiently followed and processed by a commercially available 4-pit microcomputer with an f-speed of this level. Microcomputer 3 is still in its infancy. If f3 cannot be input as an interrupt, a software timer can be used to synthesize the output f3.

なお、本実施例においてはルームエアコン用インバータ
のPWM方式について説明したが、ダイナミックレンジ
の広い周波数を必要としている用途、例えばメロディ合
成用としても同様に実施できる。
In this embodiment, the PWM method of an inverter for a room air conditioner has been described, but the present invention can be similarly implemented for applications requiring frequencies with a wide dynamic range, such as melody synthesis.

発明の効果 本発明によればプログラマブル周波数発生器により任意
の周波数を発生させる際に比較的周波数の低い部分をマ
イクロコンピュータによる分周で受は持っているため、
構成部品を増加させることなく、システムとしての分周
比を自在に変えることができ、その結果、基本的なプロ
グラマブルカウンタを汎用の安価なもので構成でき、コ
スト的に多大のメリットが得られ、1だソフトウェアに
よる分周比は整数分の1とできるので、従来のようなプ
ログラマブルカウンタとバイナリカウンタの構成に比較
して分周比の自由度が高くなり、さらにソフトウェアに
かかる負担については割シ込み入力を使用した場合は単
に分周指定および出力選択だけであるため、多ビットの
プログラマブルカウンタを使用するよりもいたって簡略
化することができるなど、種々の利点を有するものであ
る。
Effects of the Invention According to the present invention, when a programmable frequency generator generates an arbitrary frequency, a relatively low frequency portion is divided by a microcomputer, so that
The frequency division ratio of the system can be changed freely without increasing the number of component parts, and as a result, the basic programmable counter can be configured with a general-purpose, inexpensive one, resulting in a great cost advantage. Since the frequency division ratio by software can be set to 1/integer, there is a higher degree of freedom in the frequency division ratio compared to the conventional configuration of a programmable counter and a binary counter, and the burden on the software can be reduced. When using a built-in input, only the frequency division specification and output selection are required, so it has various advantages such as being much simpler than using a multi-bit programmable counter.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図および第2図はそれぞれ異なる従来例を示すプロ
グラマブルタイマの回路図、第3図は本発明の一実施例
を示すプログラマブル周波数発生器の回路図、第4図は
同プログラマブル周波数発生器における具体的な設計例
を示す説明図である。 1・・・・・・基準周波数発生器、2・・・・・・プロ
グラマブルカウンタ、3・・・・マイクロコンピュータ
、4・・・・・・バイナリカウンタ、5・・・・・・選
択出力回路。 代理人の氏名 弁理士 中 尾 敏 男 ほか1名第1
図 第3図 第4図
1 and 2 are circuit diagrams of a programmable timer showing different conventional examples, FIG. 3 is a circuit diagram of a programmable frequency generator showing an embodiment of the present invention, and FIG. 4 is a circuit diagram of a programmable frequency generator showing an embodiment of the present invention. FIG. 2 is an explanatory diagram showing a specific design example. 1... Reference frequency generator, 2... Programmable counter, 3... Microcomputer, 4... Binary counter, 5... Selective output circuit . Name of agent: Patent attorney Toshio Nakao and 1 other person No. 1
Figure 3 Figure 4

Claims (1)

【特許請求の範囲】[Claims] アドレス入力を備えだプログラマブルカウンタと、選択
出力を備えだマイクロコンピュータとからなり、前記プ
ログラマブルカウンタのアドレス入力を前記マイクロコ
ンピコ、−夕により操作し、前記プログラマブルカウン
タの出力を前記マイクロコンピュータの入力端子に取り
込み、分岐周波数として固定の周波数を設定し、前記マ
イクロコンピュータの選択出力を切換えることにより、
前記分岐周波数以上でかつ上限周波数までの周波数域で
は前記プログラムカウンタの出力をそのまま出力し、前
記分岐周波数以下でかつ下限周波数までの周波数域では
前記プログラマブルカウンタの出力を前記マイクロコン
ピュータのソフトウェアによる分周により出力するよう
にしたプログラマブル周波数発生器。
It consists of a programmable counter equipped with an address input and a microcomputer equipped with a selection output, the address input of the programmable counter is operated by the microcomputer, and the output of the programmable counter is sent to the input terminal of the microcomputer. by setting a fixed frequency as the branch frequency and switching the selection output of the microcomputer.
In the frequency range above the branch frequency and up to the upper limit frequency, the output of the program counter is output as is, and in the frequency range below the branch frequency and up to the lower limit frequency, the output of the programmable counter is divided by the software of the microcomputer. A programmable frequency generator that outputs
JP57124660A 1982-07-16 1982-07-16 Programmable frequency generator Granted JPS5915334A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP57124660A JPS5915334A (en) 1982-07-16 1982-07-16 Programmable frequency generator

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP57124660A JPS5915334A (en) 1982-07-16 1982-07-16 Programmable frequency generator

Publications (2)

Publication Number Publication Date
JPS5915334A true JPS5915334A (en) 1984-01-26
JPH0153810B2 JPH0153810B2 (en) 1989-11-15

Family

ID=14890893

Family Applications (1)

Application Number Title Priority Date Filing Date
JP57124660A Granted JPS5915334A (en) 1982-07-16 1982-07-16 Programmable frequency generator

Country Status (1)

Country Link
JP (1) JPS5915334A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0191991A2 (en) * 1984-12-21 1986-08-27 Gpt Limited Control circuit including a memory providing step functions
US4998075A (en) * 1989-10-26 1991-03-05 Western Digital Corporation Programmable multiple oscillator circuit
US5020082A (en) * 1988-06-15 1991-05-28 Seiko Epson Corporation Asynchronous counter

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5376654A (en) * 1976-12-17 1978-07-07 Nec Corp Asynchronism-type numerical control counter
JPS5514758A (en) * 1978-07-17 1980-02-01 Mitsubishi Electric Corp Pulse counter
JPS5553234U (en) * 1978-10-05 1980-04-10

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5376654A (en) * 1976-12-17 1978-07-07 Nec Corp Asynchronism-type numerical control counter
JPS5514758A (en) * 1978-07-17 1980-02-01 Mitsubishi Electric Corp Pulse counter
JPS5553234U (en) * 1978-10-05 1980-04-10

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0191991A2 (en) * 1984-12-21 1986-08-27 Gpt Limited Control circuit including a memory providing step functions
US5020082A (en) * 1988-06-15 1991-05-28 Seiko Epson Corporation Asynchronous counter
US4998075A (en) * 1989-10-26 1991-03-05 Western Digital Corporation Programmable multiple oscillator circuit

Also Published As

Publication number Publication date
JPH0153810B2 (en) 1989-11-15

Similar Documents

Publication Publication Date Title
US4356544A (en) Apparatus for controlling an inverter main circuit
JPH07297642A (en) Frequency multiplying circuit
JPS5915334A (en) Programmable frequency generator
JPH0210768A (en) Semiconductor chip
JPS5916427A (en) Programmable frequency generator
JPS5917726A (en) Programmable frequency generator for inverter driving having inductive load
JPH0153812B2 (en)
JPH0622556A (en) Pwm pattern generator circuit
JPH05276775A (en) Circuit for counting revolution number of servo motor
JPS59190724A (en) Frequency variable pulse generator
JP3132810B2 (en) Diffuse fractional frequency divider
JPH0338925A (en) Digital/analog converter
JPS6126476A (en) Control circuit for inverter
JPS6074973A (en) Reference signal forming circuit of synchronous pwm inverter
JPH01227627A (en) Power controlling trigger pulse generator circuit
JP2827968B2 (en) PLL frequency synthesizer
JPS62132406A (en) Sinusoidal wave generator
SU1457141A1 (en) Device for controlling a.c. motor
JPS6399777A (en) Variable frequency inverter
JPH09116432A (en) Variable frequency generator and its output frequency control method
KR970008366B1 (en) Control circuit of stepping motor
JPS6074972A (en) Reference signal forming circuit of synchronous pwm inverter
JPH0691425B2 (en) Frequency divider using D-type flip-flop
JP3281833B2 (en) PLL circuit
JPS63186567A (en) Output frequency control circuit for inverter