JP3517314B2 - Clock supply device - Google Patents

Clock supply device

Info

Publication number
JP3517314B2
JP3517314B2 JP27824695A JP27824695A JP3517314B2 JP 3517314 B2 JP3517314 B2 JP 3517314B2 JP 27824695 A JP27824695 A JP 27824695A JP 27824695 A JP27824695 A JP 27824695A JP 3517314 B2 JP3517314 B2 JP 3517314B2
Authority
JP
Japan
Prior art keywords
signal
clock
frequency
pulse
oscillation signal
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.)
Expired - Fee Related
Application number
JP27824695A
Other languages
Japanese (ja)
Other versions
JPH09101836A (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.)
Dai Nippon Printing Co Ltd
Original Assignee
Dai Nippon Printing 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 Dai Nippon Printing Co Ltd filed Critical Dai Nippon Printing Co Ltd
Priority to JP27824695A priority Critical patent/JP3517314B2/en
Publication of JPH09101836A publication Critical patent/JPH09101836A/en
Application granted granted Critical
Publication of JP3517314B2 publication Critical patent/JP3517314B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【発明の属する技術分野】本発明はディジタル信号の処
理技術およびその回路技術の分野に属する。特に、コン
ピュータやICカードのクロック供給装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to the field of digital signal processing technology and its circuit technology. In particular, it relates to a clock supply device for a computer or an IC card.

【0002】[0002]

【従来の技術】ディジタル回路には非同期回路と同期回
路とがあり、同期回路においてはクロック信号に同期し
て回路の動作が進行する。このクロック信号をディジタ
ル回路に供給する装置がクロック供給装置である。同期
回路の動作はクロック信号の周波数(クロック周波数)
に依存しており、クロック周波数が高いと高速処理が可
能となる。しかし実際は、同期回路の動作限界や周辺装
置の動作限界、さらに信頼性をも考慮して適正なクロッ
ク周波数が選択される。また動作限界とは全く関係な
く、用途によって適正なクロック周波数が設定される場
合がある。たとえば、計測装置におけるサンプリング
時間等がクロック周波数に依存する、通信装置におけ
る接続された外部装置の仕様に応じてクロック周波数を
変化させる等の場合である。このように同期回路を有す
る装置においてクロック周波数には適正値があり、それ
が状況によって変わる場合には、複数のクロック周波数
を用意し選択使用するものがある。
2. Description of the Related Art A digital circuit includes an asynchronous circuit and a synchronous circuit. In the synchronous circuit, the operation of the circuit proceeds in synchronization with a clock signal. A device that supplies this clock signal to the digital circuit is a clock supply device. The operation of the synchronous circuit is the frequency of the clock signal (clock frequency)
High-speed processing is possible when the clock frequency is high. However, in reality, an appropriate clock frequency is selected in consideration of the operational limits of the synchronous circuit, the operational limits of the peripheral devices, and the reliability. Also, regardless of the operation limit, an appropriate clock frequency may be set depending on the application. For example, the sampling time or the like in the measuring device depends on the clock frequency, or the clock frequency is changed according to the specifications of the connected external device in the communication device. As described above, in a device having a synchronous circuit, there is an appropriate value for the clock frequency, and if the clock frequency changes depending on the situation, there are some that prepare and select and use a plurality of clock frequencies.

【0003】ICカードもその一例であり、ICカード
の我が国における標準クロック周波数は、4.9MHz
が主流であるのに対し、ISO規格における標準クロッ
ク周波数は、3.5MHzと規定されている。したがっ
て、ISO規格に合わせたICカードを実現するために
は、リーダ/ライタ装置でICカードをアクセスする場
合、初期段階ではISO規格における3.5MHzのク
ロックを供給し、その後、我が国の標準である4.9M
Hzのクロックに切り換える処理を行う必要がある。
An example is an IC card, and the standard clock frequency of the IC card in Japan is 4.9 MHz.
Is standard, the standard clock frequency in the ISO standard is 3.5 MHz. Therefore, in order to realize an IC card conforming to the ISO standard, when the IC card is accessed by the reader / writer device, the 3.5 MHz clock in the ISO standard is supplied in the initial stage, and then the standard of Japan is used. 4.9M
It is necessary to perform processing to switch to the Hz clock.

【0004】[0004]

【発明が解決しようとする課題】しかし、このように状
況に応じてクロック周波数を変更する場合において無条
件に変更することができない場合がある。たとえば動作
を中断することなく、CPU(Central Processing Uni
t ; 中央処理装置) へ供給するクロック信号の周波数を
むやみに変化させると誤動作あるいは暴走する恐れがあ
る。そこで、正常動作を維持しながらクロック周波数の
切り換えを可能とするために、デューティファクターを
一定の範囲に保ちつつクロック周波数を切り換える方法
が提案されている。たとえば、切り換える信号の位相
が一致した瞬間に切り換える方式(位相一致方式)、
PLL回路を用いて切り換え前と後とで段階的に周波数
を変化させる方式(PLL方式)が提案されている。
However, when the clock frequency is changed according to the situation as described above, it may not be possible to unconditionally change it. For example, the CPU (Central Processing Uni
t; If the frequency of the clock signal supplied to the central processing unit) is changed indiscriminately, malfunction or runaway may occur. Therefore, in order to enable the switching of the clock frequency while maintaining the normal operation, a method of switching the clock frequency while keeping the duty factor within a certain range has been proposed. For example, a method of switching at the moment when the phases of signals to be switched match (phase matching method),
There has been proposed a system (PLL system) in which a frequency is changed stepwise before and after switching using a PLL circuit.

【0005】しかしながら、位相一致方式において
は、切り換える周波数の数だけタイミング制御回路を必
要とし切り換えタイミングの制御回路が複雑となる上、
切り換えを指令する信号の入力から実際にクロックが切
り換わるまでの時間が、クロック周波数やタイミングに
依存し、一定しない。また、PLL方式においては、
VCOやローパスフィルターなどPLL回路の構成その
ものが複雑である上、ローパスフィルターの特性によっ
て決まる切り換わるまでの所要時間が長い。そこで本発
明の目的は、CPUを通常動作させたままの状態でクロ
ック周波数を切り換えてもCPUが誤動作することがな
く、さらに装置構成が簡単でかつクロックの切り替えが
迅速なクロック供給装置を提供することにある。
However, in the phase matching method, the timing control circuit is required for the number of switching frequencies, and the control circuit for switching timing becomes complicated.
The time from the input of the signal instructing the switching to the actual switching of the clock depends on the clock frequency and timing and is not constant. Also, in the PLL system,
The configuration itself of the PLL circuit such as the VCO and the low-pass filter is complicated, and the time required for switching is long depending on the characteristics of the low-pass filter. Therefore, an object of the present invention is to provide a clock supply device in which the CPU does not malfunction even if the clock frequency is switched while the CPU is operating normally, and the device configuration is simple and the clock can be switched quickly. Especially.

【0006】[0006]

【課題を解決するための手段】上記目的は、下記の本発
明により達成される。すなわち、本発明は、「パルス発
振手段と、分周手段と、選択手段と、を有し、前記パル
ス発振手段は複数あって、各々所望のクロック周波数に
対応する周波数のパルス発振信号を出力し、前記分周器
は選択された前記パルス発振信号を入力し、2≦nの整
数値であるnにおいて2n分周し、クロック信号を生成
し、前記選択手段は前記クロック信号の立ち上がりおよ
び立ち下がりにおいて前記パルス発振信号のパルス数の
計数を開始し、計数値が1≦m≦(n−1)なる計数設
定値mに達する時点に同期し、選択入力に対応する前記
パルス発振信号に選択を切り換える、クロック供給装
置」である。
The above object can be achieved by the present invention described below. That is, the present invention has "a pulse oscillating means, a frequency dividing means, and a selecting means, and there are a plurality of the pulse oscillating means, each of which outputs a pulse oscillating signal of a frequency corresponding to a desired clock frequency. The frequency divider inputs the selected pulse oscillation signal, divides it by 2n in n, which is an integer value of 2 ≦ n, and generates a clock signal, and the selecting means raises and falls the clock signal. In the step 1, the counting of the number of pulses of the pulse oscillation signal is started, and the pulse oscillation signal corresponding to the selection input is selected in synchronization with the point when the count value reaches the count setting value m of 1 ≦ m ≦ (n−1). It is a switching clock supply device. "

【0007】本発明のクロック供給装置において、パル
ス発振手段は所望のクロック周波数の数だけ存在し、所
望のクロック周波数の2n倍の周波数でパルス発振信号
を出力する。このパルス発振信号は分周手段により2n
分周され、クロック信号が生成される。また選択手段は
選択入力に対応し複数あるパルス発振手段のパルス発振
信号の一つを選択して分周手段に出力する。ここで選択
入力が切り換わった場合に、選択手段は直ちに選択する
パルス発振信号を切り換えるのではなく、選択手段は所
定のタイミングに同期してパルス発振信号を切り換え
る。そのタイミングは、クロック信号の立ち上がりおよ
び立ち下がりにおいてパルス発振信号のパルス数の計数
を開始し、計数値が1≦m≦(n−1)なる計数設定値
mに達する時点である。
In the clock supply device of the present invention, the pulse oscillating means exists in the number of the desired clock frequency, and outputs the pulse oscillating signal at the frequency of 2n times the desired clock frequency. This pulse oscillation signal is 2n by the frequency dividing means.
The frequency is divided and a clock signal is generated. Further, the selection means selects one of a plurality of pulse oscillation signals of the pulse oscillation means corresponding to the selection input and outputs it to the frequency division means. Here, when the selection input is switched, the selection means does not immediately switch the pulse oscillation signal to be selected, but the selection means switches the pulse oscillation signal in synchronization with a predetermined timing. The timing is the time when the counting of the pulse number of the pulse oscillation signal is started at the rising and falling edges of the clock signal and the count value reaches the count setting value m of 1 ≦ m ≦ (n−1).

【0008】上記の本発明によれば、CPUを通常動作
させたままの状態でクロック周波数を切り換えてもCP
Uが誤動作することがなく、さらに装置構成が簡単でか
つクロックの切り替えが迅速である。また上記の本発明
において、前記nと前記mが下記の数2を満たすと、効
果がさらに顕著である。数2において計数設定値mが小
数点以下の値を有するのは、mが“計数値”というより
も、切り換えの“タイミング”としての値を意味するた
めである。小数点以下の値で0.5は半周期を意味す
る。
According to the present invention described above, even if the clock frequency is switched while the CPU is operating normally, the CP
The U does not malfunction, and the device configuration is simple and the clock can be switched quickly. Further, in the above-mentioned present invention, the effect is more remarkable when the n and the m satisfy the following formula 2. The reason why the count setting value m has a value below the decimal point in Expression 2 is that m means not a “count value” but a value as “timing” of switching. The value below the decimal point is 0.5, which means a half cycle.

【数2】n = 2x-1 m = 2x-2 + 0.5 ただし、3 ≦ x## EQU2 ## n = 2 x-1 m = 2 x-2 +0.5 where 3 ≤ x

【0009】[0009]

【発明の実施の形態】以下本発明の実施の形態について
説明する。図1は本発明のクロック供給装置の構成を示
す図である。図1において、1,2,3はパルス発振手
段であり、複数あってそれぞれ、1は第1のパルス発振
手段、2は第2のパルス発振手段、3は第kのパルス発
振手段である。また4は選択手段、5は分周手段であ
る。選択手段4は パルス発振手段1〜3が出力するパ
ルス発振信号を入力し、その内の一つを選択して分周手
段に出力する。分周手段5は選択手段4が出力するパル
ス発振信号を入力し、それを2n分周してクロック信号
を出力する。ここに、nは2以上(2と同じか大)の整
数値である。
BEST MODE FOR CARRYING OUT THE INVENTION Embodiments of the present invention will be described below. FIG. 1 is a diagram showing a configuration of a clock supply device of the present invention. In FIG. 1, 1, 2 and 3 are pulse oscillating means, and there are a plurality of them, 1 is a first pulse oscillating means, 2 is a second pulse oscillating means, and 3 is a k-th pulse oscillating means. Further, 4 is a selecting means, and 5 is a frequency dividing means. The selecting means 4 inputs the pulse oscillation signals output from the pulse oscillating means 1 to 3, selects one of them and outputs it to the frequency dividing means. The frequency dividing means 5 receives the pulse oscillation signal output from the selecting means 4, divides it by 2n, and outputs a clock signal. Here, n is an integer value of 2 or more (the same as or larger than 2).

【0010】選択手段4は、クロック信号の立ち上がり
立ち下がりを検出できる信号、すなわち立ち上がり立ち
下がり信号を入力する。立ち上がり立ち下がり信号は、
直接のクロック信号でなくても、たとえば分周手段のク
ロック信号の一段前の信号でもよく、そのことを示すた
め図1においてはクロック信号は破線で立ち上がり立ち
下がり信号に接続されている。さらに選択手段4は、ク
ロック信号の立ち上がり立ち下がりにおいて、選択され
ているパルス発振信号のパルス数の計測を開始する。そ
して選択手段4は、計数値が1≦m≦(n−1)なる計
数設定値mに達する時点に同期し、選択入力に対応する
前記パルス発振信号に選択を切り換える。
The selecting means 4 inputs a signal capable of detecting the rising and falling edges of the clock signal, that is, a rising and falling edge signal. The rising and falling signals are
Instead of the direct clock signal, for example, it may be a signal one stage before the clock signal of the frequency dividing means, and in order to show that, the clock signal is connected to the rising and falling signals by broken lines in FIG. Further, the selecting means 4 starts measuring the number of pulses of the selected pulse oscillation signal at the rising and falling edges of the clock signal. Then, the selection means 4 switches the selection to the pulse oscillation signal corresponding to the selection input in synchronization with the time when the count value reaches the count setting value m of 1 ≦ m ≦ (n−1).

【0011】図2は本発明のクロック供給装置の構成
を、より実際に近い形態で示す図である。また図3は図
2に示すクロック供給装置の動作を示すタイミングチャ
ートである。図2において、21は複数のパルス発振信
号の内から一つを選択する切換器、22は選択されたク
ロック信号を2n分周する分周器、23は選択信号
(“選択入力”と同等)をトリガ信号のタイミングで入
力保持し切換器21に出力するラッチである。図3に示
すように、パルス発振信号1とパルス発振信号2は周波
数が異なる信号であり、この例ではパルス発振信号2の
周波数が高い。選択信号1および選択信号2は、通常は
非同期で外部から入力される信号であり、複数ある選択
信号が排他的動作を行い、その内の一つだけが選択状態
の信号レベルとなる。ラッチ出力はラッチ23から切換
器21に出力される信号であり、トリガ信号(図2参
照)に同期してラッチ出力が変化し、切換器21が分周
器22に出力するパルス発振信号が切り換わる。
FIG. 2 is a diagram showing the configuration of the clock supply device of the present invention in a more practical form. FIG. 3 is a timing chart showing the operation of the clock supply device shown in FIG. In FIG. 2, reference numeral 21 is a switch for selecting one of a plurality of pulse oscillation signals, 22 is a frequency divider for dividing the selected clock signal by 2n, and 23 is a selection signal (equivalent to "selection input"). Is a latch for input-holding at the timing of the trigger signal and outputting it to the switch 21. As shown in FIG. 3, the pulse oscillation signal 1 and the pulse oscillation signal 2 have different frequencies, and the frequency of the pulse oscillation signal 2 is high in this example. The selection signal 1 and the selection signal 2 are signals that are normally input asynchronously from the outside, and a plurality of selection signals perform an exclusive operation, and only one of them has a selected signal level. The latch output is a signal output from the latch 23 to the switch 21, and the latch output changes in synchronization with the trigger signal (see FIG. 2), and the pulse oscillation signal output from the switch 21 to the frequency divider 22 is switched off. Replace

【0012】選択発振信号は切換器21が切り換えて、
選択したパルス発振信号、すなわち分周器22に出力さ
れているパルス発振信号である。図3の例ではラッチ出
力が変化する前はパルス発振信号1、変化した後はパル
ス発振信号2の切換器21からの出力である。クロック
信号は、その選択発振信号を2n分周した出力であり、
当然ラッチ出力が変化する前後で変化する。ラッチ出力
が変化する原因のトリガ信号は、選択発振信号の周期数
(すなわちパルス発振信号のパルス数)を、クロック信
号の立ち上がり立ち下がりにおいて計数を開始し、計数
値が計数設定値m(1≦m≦(n−1))に達する時点
に出力される。トリガ信号が出力されても、選択信号が
変化しない場合には何も起こらないが、選択信号が変化
した後の最初のトリガ信号によって選択発振信号の切り
換えが起こる。
The selector 21 switches the selected oscillation signal,
It is the selected pulse oscillation signal, that is, the pulse oscillation signal output to the frequency divider 22. In the example of FIG. 3, the pulse output signal 1 is output before the latch output changes, and the pulse output signal 2 is output after the change from the switch 21. The clock signal is an output obtained by dividing the selected oscillation signal by 2n,
Naturally, it changes before and after the latch output changes. The trigger signal that causes the change of the latch output starts counting the number of cycles of the selected oscillation signal (that is, the number of pulses of the pulse oscillation signal) at the rising and falling edges of the clock signal, and the count value is the count setting value m (1 ≦ It is output when m ≦ (n−1) is reached. Even if the trigger signal is output, nothing happens if the selection signal does not change, but the selection oscillation signal is switched by the first trigger signal after the selection signal changes.

【0013】以上の説明から明らかなように、図1にお
ける選択手段4は図2における切換器21の全てと、分
周器22の一部と、ラッチ23の全てから構成されてい
る。また、図1における分周手段5は図2における分周
器22の一部から構成されている。次に説明する実施例
によって、その構成の詳細がより明確にされる。
As is apparent from the above description, the selecting means 4 in FIG. 1 is composed of all of the switching device 21, the part of the frequency divider 22 and the latch 23 of FIG. The frequency dividing means 5 in FIG. 1 is composed of a part of the frequency divider 22 in FIG. The details of the configuration will be made clearer by the embodiments described below.

【0014】[0014]

【実施例】図4は本発明のクロック供給装置の回路構成
の一例である。図4において、X1,X2はパルス発振
手段が出力するパルス発振信号の入力端子であり、パル
ス発振手段そのものは省略されている。この実施例にお
いては以下の説明から明らかなように、n=4,M=
2.5であり、本発明の請求項1におけるnとmの関
係、および、請求項2におけるnとmの関係が満たされ
ている。BUF1,BUF2はスリーステートバッファ
であり図2の切換器21に相当する。スリーステートバ
ッファは信号入力端子,信号出力端子,制御入力端子の
3端子を有し、制御入力端子が“H”ならば、信号入力
端子と信号出力端子は論理値は一致する。制御入力端子
が“L”ならば、信号入力端子の論理値に係わらず、信
号出力端子は“ハイインピーダンス”となる。信号出力
端子が通常の論理素子の“H”,“L”だけでなく“ハ
イインピーダンス”の3つの状態となるためスリーステ
ートバッファと呼ばれる。BUF1,BUF2のいずれ
かの制御入力端子を排他的に“H”とすることで、
“H”とされたスリーステートバッファの信号入力端子
の信号(X1,X2のいずれかのパルス発振信号)だけ
が信号出力端子に選択発振信号として出力される。
FIG. 4 shows an example of the circuit configuration of the clock supply device of the present invention. In FIG. 4, X1 and X2 are input terminals for the pulse oscillation signal output by the pulse oscillation means, and the pulse oscillation means itself is omitted. In this embodiment, as is clear from the following description, n = 4 and M =
2.5, which satisfies the relationship between n and m in claim 1 and the relationship between n and m in claim 2 of the present invention. BUF1 and BUF2 are three-state buffers and correspond to the switch 21 of FIG. The three-state buffer has three terminals: a signal input terminal, a signal output terminal, and a control input terminal. If the control input terminal is "H", the signal input terminal and the signal output terminal have the same logical value. When the control input terminal is "L", the signal output terminal becomes "high impedance" regardless of the logical value of the signal input terminal. It is called a three-state buffer because the signal output terminal has three states of "high impedance" as well as "H" and "L" of normal logic elements. By setting the control input terminal of either BUF1 or BUF2 to "H" exclusively,
Only the signal (the pulse oscillation signal of either X1 or X2) at the signal input terminal of the three-state buffer which is set to "H" is output to the signal output terminal as the selective oscillation signal.

【0015】CNTはカウンターであり図2の分周器2
2に相当する。CNTにおいてCKはクロック入力端
子、Q1は2分周出力端子、Q2は4分周出力端子、Q
3は8分周出力端子である。このQ3は8分周出力端子
であるとともにクロック信号出力端子でもある。すなわ
ち、CNTはカウンターであるとともに分周手段となっ
ている。またCK,Q1は直接ANDゲートの入力端子
に接続され、Q2はインバータを介してANDゲートの
入力端子に接続されている。このANDゲートは入力端
子が全て“H”となった時だけ出力端子が“H”とな
り、それ以外の時は“L”である。したがって、AND
ゲートはCKに入力される選択発振信号の8周期毎に1
回の割合で“H”となる(タイミングの詳細は図5参
照)。
CNT is a counter, and the frequency divider 2 in FIG.
Equivalent to 2. In CNT, CK is a clock input terminal, Q1 is a divide-by-2 output terminal, Q2 is a divide-by-4 output terminal, Q
Reference numeral 3 is an output terminal divided by eight. This Q3 is not only a divide-by-8 output terminal but also a clock signal output terminal. That is, the CNT is both a counter and a frequency dividing means. Further, CK and Q1 are directly connected to the input terminal of the AND gate, and Q2 is connected to the input terminal of the AND gate through the inverter. This AND gate has an output terminal that is "H" only when all the input terminals are "H", and is "L" otherwise. Therefore, AND
The gate is 1 every 8 cycles of the selective oscillation signal input to CK.
It becomes “H” at a rate of times (see FIG. 5 for details of timing).

【0016】FF1,FF2はDタイプフィリップフロ
ップであり図2のラッチに相当する。S1,S2はX
1,X2のパルス発振信号を選択するための選択信号の
入力端子であり、FF1,FF2のD入力端子に接続さ
れている。またFF1,FF2においてQは出力端子で
ある。CKはクロック入力端子であり、D入力端子に入
力された論理値は(“H”または“L”)は、CKに入
力されるパルスの立ち上がりでQ出力端子に出力され保
持される。S1,S2には“H”となるのは一つだけで
ある排他的な信号が入力される。したがって、BUF
1,BUF2のいずれかの制御入力端子が“H”とな
り、“H”となった側のパルス発振信号が選択される。
FF1 and FF2 are D-type flip-flops and correspond to the latch shown in FIG. S1 and S2 are X
It is an input terminal of a selection signal for selecting the pulse oscillation signals of 1 and X2, and is connected to the D input terminals of FF1 and FF2. In FF1 and FF2, Q is an output terminal. CK is a clock input terminal, and the logical value (“H” or “L”) input to the D input terminal is output to the Q output terminal and held at the rising edge of the pulse input to CK. An exclusive signal of which only one signal is "H" is input to S1 and S2. Therefore, BUF
One of the control input terminals of 1 and BUF2 becomes "H", and the pulse oscillation signal on the side that becomes "H" is selected.

【0017】図5は図4のクロック供給装置のタイミン
グチャートを示す図である。図5のタイミングチャート
において、パルス発振信号X1は28MHz、パルス発
振信号X2は40MHzである。また初期状態でクロッ
クX1が選択され、その後クロックX2が選択され、出
力されるクロック信号を3.5MHz(28MHzの8
分周)から5MHz(40MHzの8分周)に切り換え
る。時刻t1において選択信号S1,S2が切り換わ
る。FF1,FF2はそのCK端子に“L”→“H”と
なるANDゲートからの信号を受ける時刻t2まで、そ
れまでのQ出力端子の論理値を保持し、時刻t2以降に
切り換わる。時刻t2以降はカウンターCNTのCKに
入力される選択発振信号の周波数が変わるため、パルス
発振信号X2の立ち上がりを計数しQ2出力、Q3出力
はそれぞれパルス発振信号X2の4分周、8分周とな
る。そして、Q3出力の出力の状態が変わる時間t3以
降は、Q3出力信号は、パルス発振信号X2(40MH
z)の8分周である5MHzとなる。
FIG. 5 is a diagram showing a timing chart of the clock supply device of FIG. In the timing chart of FIG. 5, the pulse oscillation signal X1 is 28 MHz and the pulse oscillation signal X2 is 40 MHz. Further, the clock X1 is selected in the initial state, and then the clock X2 is selected, and the output clock signal is set to 3.5 MHz (8 MHz of 28 MHz).
(Division) to 5 MHz (40 MHz divided by 8). At time t1, the selection signals S1 and S2 switch. The FF1 and FF2 hold the logical value of the Q output terminal up to that time until the time t2 at which the CK terminal receives the signal from the AND gate which changes from "L" to "H", and switch after the time t2. Since the frequency of the selective oscillation signal input to the CK of the counter CNT changes after time t2, the rise of the pulse oscillation signal X2 is counted, and the Q2 output and the Q3 output are divided into 4 and 8 of the pulse oscillation signal X2, respectively. Become. Then, after the time t3 when the output state of the Q3 output changes, the Q3 output signal is the pulse oscillation signal X2 (40 MH).
It becomes 5 MHz which is a frequency division of 8 of z).

【0018】さて、CPUが正常に動作するためにはク
ロック信号のデューティファクターは一定の範囲に収ま
っていることが必要であり、この実施例におけるデュー
ティファクターについて調べる。選択信号S1,S2が
変更された時刻t1より前の半周期の時間をTa、t1
を含む1/2周期をTb、Tbの次以降の半周期の時間
をTcとする。Ta,Tc、はX1,X2によってだけ
決まるから一定であるが、Tbについては切り換えの瞬
間のX1,X2の位相によって多少の変動がある。すな
わち、CNTのCKへ入力される選択発振信号が切り換
わる時刻t2において、X1とX2の位相が必ずしも一
致するとは限らず、最大でX2の1周期分の時間差が出
る可能性がある。
In order for the CPU to operate normally, it is necessary that the duty factor of the clock signal be within a certain range. The duty factor in this embodiment will be examined. The half cycle time before the time t1 when the selection signals S1 and S2 are changed is Ta, t1.
The half cycle including Tb is Tb, and the time of the half cycle after Tb is Tc. Ta and Tc are constant because they are determined only by X1 and X2, but there is some variation in Tb depending on the phases of X1 and X2 at the switching instant. That is, at time t2 when the selective oscillation signal input to CK of CNT switches, the phases of X1 and X2 do not always match, and there is a possibility that a maximum time difference of one cycle of X2 will occur.

【0019】この位相が最大にずれるときのX2の信号
をX2’、CNTのCKへ入力される信号をCK’とし
て、位相が一致した場合と比較する。図5において、X
1は切り換え前に選択されていたパルス発振信号で周波
数は28MHzである。X2,X2’は切り換え後に選
択されるパルス発振信号で周波数は40MHzであり、
X1とt2において位相が一致する場合をX2、それよ
りわずかに遅れる場合をX2’とする。またCNTC
K,CNTCK’は、CNTのCKに入力される信号で
あり、切り換え後の選択発振信号がX2からの信号であ
る場合をCNTCK、X2’からの信号である場合をC
NTCK’とする。CNTはCKに入力されるパルスを
8分周してQ3に出力する。CKに入力されるパルスが
CNTCKの場合の出力信号がCNTQ3であり、CN
TCK’の場合の出力信号がCNTQ3’である。
The signal of X2 when the phase shifts to the maximum is X2 'and the signal input to the CK of the CNT is CK', and the case where the phases match is compared. In FIG. 5, X
Reference numeral 1 is a pulse oscillation signal selected before switching, and its frequency is 28 MHz. X2 and X2 'are pulse oscillation signals selected after switching and have a frequency of 40 MHz,
The case where the phases match at X1 and t2 is X2, and the case where the phases are slightly delayed is X2 ′. Also CNTC
K and CNTCK ′ are signals input to the CK of CNT, and when the selected oscillation signal after switching is a signal from X2, CNTCK, and when it is a signal from X2 ′, C
NTCK '. The CNT divides the pulse input to CK by 8 and outputs it to Q3. When the pulse input to CK is CNTCK, the output signal is CNTQ3 and CN
The output signal in the case of TCK 'is CNTQ3'.

【0020】図5において、CNTCKとCNTCK’
とを比較した場合、時刻t2に2カウント目を計数して
から3カウント目を計数するまでの時間は、CNTCK
とCNTCK’とでは、CNTCK’がほぼX2の半周
期短くなる。したがって、CNTQ3の出力パルス幅T
bと、CNTQ3’の出力パルス幅Tb’は以下のよう
になる。 Tb = 126.79ns Tb’ = 114.29ns ここで、Ta = 142.85ns Tc = 100.00ns である。
In FIG. 5, CNTCK and CNTCK '
When compared with, the time from counting the second count at time t2 to counting the third count is CNTCK.
And CNTCK ', CNTCK' is shortened by about half a cycle of X2. Therefore, the output pulse width T of CNTQ3
b and the output pulse width Tb 'of CNTQ3' are as follows. Tb = 126.79 ns Tb ′ = 114.29 ns where Ta = 142.85 ns Tc = 100.00 ns.

【0021】パルス発振信号の切り換え前のデューティ
ファクターDFA,DFA’、切り換え後のデューティ
ファクターDFB,DFB’は下記のように計算され
る。いずれも40〜60%の範囲内に収まり、マイクロ
プロセッサの入力の標準仕様を満たしつつ、クロックを
切り換えることができる。 DFA = Ta/(Ta+Tb) = 0.530 DFA’ = Ta/(Ta+Tb’) = 0.556 DFB = Ta/(Tc+Tb) = 0.441 DFB’ = Ta/(Tc+Tb’) = 0.467
The duty factors DFA and DFA 'before switching the pulse oscillation signal and the duty factors DFB and DFB' after switching are calculated as follows. Both fall within the range of 40 to 60%, and the clock can be switched while satisfying the standard specifications of the input of the microprocessor. DFA = Ta / (Ta + Tb) = 0.530 DFA '= Ta / (Ta + Tb') = 0.556 DFB = Ta / (Tc + Tb) = 0.441 DFB '= Ta / (Tc + Tb') = 0.467

【0022】[0022]

【発明の効果】以上のように本発明によれば、CPUを
通常動作させたままの状態でクロック周波数を切り換え
てもCPUが誤動作することがなく、さらに装置構成が
簡単でかつクロックの切り替えが迅速なクロック供給装
置が提供される。
As described above, according to the present invention, the CPU does not malfunction even if the clock frequency is switched while the CPU is normally operating, and the device configuration is simple and the clock can be switched. A quick clock supply is provided.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明のクロック供給装置の構成を示す図であ
る。
FIG. 1 is a diagram showing a configuration of a clock supply device of the present invention.

【図2】本発明のクロック供給装置の構成を、より実際
に近い形態で示す図である。
FIG. 2 is a diagram showing a configuration of a clock supply device of the present invention in a more practical form.

【図3】図2に示すクロック供給装置の動作を示すタイ
ミングチャートである。
FIG. 3 is a timing chart showing an operation of the clock supply device shown in FIG.

【図4】本発明のクロック供給装置の回路構成の一例で
ある。
FIG. 4 is an example of a circuit configuration of a clock supply device of the present invention.

【図5】図4のクロック供給装置のタイミングチャート
を示す図である。
5 is a diagram showing a timing chart of the clock supply device of FIG.

【符号の説明】[Explanation of symbols]

1 第1のパルス発振手段 2 第2のパルス発振手段 3 第Kのパルス発振手段 4 選択手段 5 分周手段 21 切換器 22 分周器 23 ラッチ 1 First pulse oscillating means 2 Second pulse oscillating means 3 Kth pulse oscillating means 4 selection means 5 frequency dividing means 21 Switch 22 frequency divider 23 Latch

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】パルス発振手段と、分周手段と、選択手段
と、を有し、 前記パルス発振手段は複数あって、各々所望のクロック
周波数に対応する周波数のパルス発振信号を出力し、 前記分周器は選択された前記パルス発振信号を入力し、
2≦nの整数値であるnにおいて2n分周し、クロック
信号を生成し、 前記選択手段は前記クロック信号の立ち上がりおよび立
ち下がりにおいて前記パルス発振信号のパルス数の計数
を開始し、計数値が1≦m≦(n−1)なる計数設定値
mに達する時点に同期し、選択入力に対応する前記パル
ス発振信号に選択を切替える、 ことを特徴とするクロック供給装置。
1. A pulse oscillating means, a frequency dividing means, and a selecting means, wherein there are a plurality of the pulse oscillating means, each of which outputs a pulse oscillating signal having a frequency corresponding to a desired clock frequency, The frequency divider inputs the selected pulsed oscillation signal,
The frequency is divided by 2n in n, which is an integer value of 2≤n, to generate a clock signal, and the selection means starts counting the number of pulses of the pulse oscillation signal at the rising and falling edges of the clock signal, and the count value is A clock supply device, wherein the selection is switched to the pulse oscillation signal corresponding to the selection input in synchronization with the time when the count setting value m of 1 ≦ m ≦ (n−1) is reached.
【請求項2】前記nと前記mは、下記の数1を満たすこ
とを特徴とする請求項1記載のクロック供給装置。 【数1】n = 2x-1 m = 2x-2 + 0.5 ただし、3 ≦ x
2. The clock supply device according to claim 1, wherein the n and the m satisfy the following formula 1. N = 2 x-1 m = 2 x-2 + 0.5 where 3 ≤ x
JP27824695A 1995-10-03 1995-10-03 Clock supply device Expired - Fee Related JP3517314B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP27824695A JP3517314B2 (en) 1995-10-03 1995-10-03 Clock supply device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP27824695A JP3517314B2 (en) 1995-10-03 1995-10-03 Clock supply device

Publications (2)

Publication Number Publication Date
JPH09101836A JPH09101836A (en) 1997-04-15
JP3517314B2 true JP3517314B2 (en) 2004-04-12

Family

ID=17594663

Family Applications (1)

Application Number Title Priority Date Filing Date
JP27824695A Expired - Fee Related JP3517314B2 (en) 1995-10-03 1995-10-03 Clock supply device

Country Status (1)

Country Link
JP (1) JP3517314B2 (en)

Also Published As

Publication number Publication date
JPH09101836A (en) 1997-04-15

Similar Documents

Publication Publication Date Title
US10511312B1 (en) Metastable-free output synchronization for multiple-chip systems and the like
US6794944B2 (en) Lock detection circuit
US5361290A (en) Clock generating circuit for use in single chip microcomputer
US7994828B2 (en) Frequency divider, frequency dividing method thereof, and phase locked loop utilizing the frequency divider
EP0596656A2 (en) Programmable clock skew adjustment circuit
KR100862317B1 (en) Digital frequency multiplier and method of generating an output signal
US10972112B1 (en) 50%-duty-cycle consecutive integer frequency divider and phase-locked loop circuit
JPH0439690B2 (en)
EP0954106B1 (en) Clock signal multiplier circuit for a clock signal generator circuit
JP5184680B2 (en) Frequency divider circuit, PLL circuit including the same, and semiconductor integrated circuit
US6459310B1 (en) Divide by 15 clock circuit
US6316982B1 (en) Digital clock with controllable phase skew
US20060023822A1 (en) Electronic circuit
US6108393A (en) Enhanced prescaler phase interface
US8466720B2 (en) Frequency division of an input clock signal
KR100299195B1 (en) Variable frequency divider and pll circuit
JP3517314B2 (en) Clock supply device
US5969548A (en) Frequency divider with low power consumption
JP3649874B2 (en) Frequency divider circuit
EP0930706A2 (en) Variable frequency oscillator
KR100721727B1 (en) Pll circuit and frequency division method
JP2000286703A (en) Reset circuit and pll frequency synthesizer
JP3375770B2 (en) Prescaler and PLL frequency synthesizer circuit
JP2011040934A (en) Frequency divider circuit
US7643580B2 (en) Signal generator circuit having multiple output frequencies

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20040120

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20040123

LAPS Cancellation because of no payment of annual fees