JPS6275822A - Computer system - Google Patents

Computer system

Info

Publication number
JPS6275822A
JPS6275822A JP60216474A JP21647485A JPS6275822A JP S6275822 A JPS6275822 A JP S6275822A JP 60216474 A JP60216474 A JP 60216474A JP 21647485 A JP21647485 A JP 21647485A JP S6275822 A JPS6275822 A JP S6275822A
Authority
JP
Japan
Prior art keywords
clock
program
clocks
timer
port
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
JP60216474A
Other languages
Japanese (ja)
Other versions
JPH0740213B2 (en
Inventor
Toshikazu Konno
俊和 今野
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.)
Toshiba Corp
Original Assignee
Toshiba Corp
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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP60216474A priority Critical patent/JPH0740213B2/en
Publication of JPS6275822A publication Critical patent/JPS6275822A/en
Publication of JPH0740213B2 publication Critical patent/JPH0740213B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Abstract

PURPOSE:To reduce the load of a programmer by providing a clock selecting circuit and a clock switching program and giving the dynamic change to the clock speed at the part of a software timer. CONSTITUTION:Both clocks A and B are supplied to a clock selecting circuit 1 via lines 2 and 3 respectively and either one of both clocks is usually delivered through a line 5. When the input clock is changed, the control signal SEL of a line 4 is allocated to a certain port address. Then an access is given to the relevant port by a program and the signal SEL is inverted. In other words, the count frequency is set at a part equivalent to a timer (loop) by a prepared program and an access is given to the port to which the circuit 1 is allocated. Then this port is switched as necessary to the logic clock obtained when the program is designed. Thus the clocks are fixed during an actual loop and the replacement of programs is omitted. As a result, the load of a programmer is reduced.

Description

【発明の詳細な説明】 〔発明の技術分野〕 本発明はソフトウェアタイマを持っフンピユータシステ
ムに関する。
DETAILED DESCRIPTION OF THE INVENTION [Technical Field of the Invention] The present invention relates to a computer system having a software timer.

〔発明の技術的背景とその問題点〕[Technical background of the invention and its problems]

マイクロプロセッサ(MPU)は開発の過程でスピード
アップがはかられる。例えばインチ/I/社の16ビツ
トMPU8086H先f5MHz(メガヘルツ)クロッ
クのものが発表され、七〇後8MHzクロフクのものに
グレードアップされた。ディ0グ社の8ビットMPU、
Z80は2M82版でスタートし、これも4MHzがら
6M HZへとグレードアップされた。これらのM P
 Uを使う次システムではMPUの性能【ftセテ”c
rツク周波数をあげシステムの性能アップを行うのが通
例である。
The speed of microprocessors (MPUs) is increased during the development process. For example, Inch/I/'s 16-bit MPU8086H with a f5MHz (megahertz) clock was announced, and after 1970, it was upgraded to an 8MHz clock. Di0g's 8-bit MPU,
The Z80 started with the 2M82 version, which was also upgraded from 4MHz to 6MHz. These MP
In the next system that uses U, the MPU performance [ftset”c
It is customary to increase the r-track frequency to improve system performance.

この場合に唯一問題となるのがソフトウェアタイマルー
チンである。即ち、ある一定時間ウェイトさせる(例え
ば、フロッピィディスクドライブのセットリングタイム
を確保するといった場合)とき、MPUクロックが4M
Hzの場合とBMHzの場合とではループ回数を1対2
としなければならない。また8MH2を想定してループ
回数を設定しておくと、4MH2では2倍のウェイト時
間になってしまう。従って、周#数が変わる毎にループ
回数を変更する必要があり、プログラマの負担となって
いたものである。
The only problem in this case is the software timer routine. In other words, when waiting for a certain period of time (for example, to ensure the settling time of a floppy disk drive), the MPU clock is set to 4M.
The number of loops is 1:2 for Hz and BMHz.
Must be. Furthermore, if the number of loops is set assuming 8MH2, the wait time will be twice as long for 4MH2. Therefore, it is necessary to change the number of loops each time the number of cycles changes, which is a burden on the programmer.

〔発明の目的〕[Purpose of the invention]

本発明は上記事情Oで基づいてなされ;tものであり、
ソフ;・ウェアタイマ部分のクロックスピードをダイナ
ミックに変更することにより、ブt−ゴグラマの負担を
軽減したコンピュータシスチー−に提供することを目的
とする。
The present invention is made based on the above circumstances O;
The object of the present invention is to provide a computer system that reduces the burden on a computer programmer by dynamically changing the clock speed of a software/ware timer section.

[5^明の饋要〕 本祐明は、上記目的を実現するため、この櫨コンピュー
タシステムが従来から持つコンポーネントに更Vこクロ
7り選択回路全付加して人力さt′L/り殉教櫨のクロ
ックのいずれか1個をプσA(yザユニットに対し供給
する構成にすると共ンC、カウント値をセットした後、
上記選択回路か、!、lJ jMてられているボートを
アクセスし、クロックとタイマ用のものに切洟え、タイ
マ終了後にも、−のクロック〆こ切換える処理を行なう
ブ「コグラムを・用意した5、該プログラムに従い、ダ
イブ−ミックC′こソフトウェアタイマのクロックスピ
ードを固定とし、ソフトウェアタイマをクロックスピー
ドによって再作成する作業を不要としたものである。
[5^ Akira's main message] In order to achieve the above purpose, Motosukeaki added all the selection circuits to the conventional components of this Hashi computer system, and saved human power. If one of the clocks of Haji is configured to supply σA (y) to the unit, then after setting the count value,
The above selection circuit? , lJ jM accesses the board that is set, changes it to one for the clock and timer, and even after the timer ends, performs the process of switching the -clock clock.5, according to the program, Divemic C' The clock speed of the software timer is fixed, eliminating the need to recreate the software timer at different clock speeds.

このことによりプログラムの変更が不要となす、ソフト
ウェアプログラマの負担が軽減される。
This eliminates the need to change the program and reduces the burden on the software programmer.

〔発明の実施例〕[Embodiments of the invention]

以下、図面を使用して本発明実施例につき詳細に説明す
る。第1図は本発明の実施例を示すブロック図である。
Hereinafter, embodiments of the present invention will be described in detail using the drawings. FIG. 1 is a block diagram showing an embodiment of the present invention.

図において、Jはクロック選択え回路であり、周波数の
異なるクロックA1クロックBがそれぞれライン2.3
を介して供給される。ライン3を介して供給さnる信号
は制御信号であり、クロックA、Hのいずれか一万をラ
イン5を介して選択出力する。
In the figure, J is a clock selection circuit, and clocks A and B with different frequencies are connected to lines 2 and 3, respectively.
Supplied via. The signal supplied via line 3 is a control signal, and one of the clocks A and H is selectively output via line 5.

第2図は、タイマ部分のクロックスピードを固定とする
プログラムの動作フローを示す。該プログラムは、カウ
ントをセットした後に第1因に示したクロック選択回路
りが割当てられている?−・トをアクセスし、クロック
をタイマ用のイ)・)に切換え、タイマ終了後に元のク
ロックに切換える処理を行なうものである。詳細は後述
する。。
FIG. 2 shows the operation flow of a program in which the clock speed of the timer section is fixed. Is the program assigned the clock selection circuit shown in the first factor after setting the count? -), the clock is switched to the clock for the timer, and the clock is switched to the original clock after the timer ends. Details will be described later. .

第3図は、第1図に示したクロック選択回路!の具体的
回路構成を示す図である。クロック選択(用路1は、5
個のDタイプフリップフロップI1.12.13,14
.15と2個のオアゲート16.17.1個のアンドゲ
ート18から成る。図中、第1図Vこ付された記号ある
いは番号と同一記号あるいは番号の付されたものはII
’、 l J榎のそれと同じものとする。又、Dnはデ
ータビク)、OUTはCIUT命令により到来する41
号を示す。
Figure 3 shows the clock selection circuit shown in Figure 1! FIG. 2 is a diagram showing a specific circuit configuration. Clock selection (path 1 is 5
D-type flip-flops I1.12.13,14
.. 15, two OR gates 16, 17. and one AND gate 18. In the figure, the symbols or numbers that are the same as those in Figure 1 are II.
', l It is the same as that of J Enoki. In addition, Dn is data signal), and OUT is 41 that arrives due to the CIUT command.
Indicates the number.

第4図は本発明実施例の動作を示すタイミングチ+ −
)である。図中、第3図に付され九番号と同一番号の付
されたブロックもしくはラインは第3図のそれと同じも
のとする。
FIG. 4 is a timing chart showing the operation of the embodiment of the present invention.
). In the figure, blocks or lines numbered the same as number 9 in FIG. 3 are the same as those in FIG. 3.

以下、本発明実施例の動作につき詳細に説明する。まず
、第1図、第2因を用いて概略動作から説明する。クロ
ック選択回路7にはり【JツクΔとクロックBがそれぞ
れ、ライン2.3を介し人力されている。クロッグ、N
とクロックBは周波数の異なるクロックである。通常、
クロックA又はクロックBのどちらか一万のクロック(
g号出力(ライン5)にてCPUが動作している。他方
のクロックに切換えるには制御信号(ライン4)をある
ボートアドレスに割υ当てておき、プログラムにてその
ボートをアクセスし制御fg号を反転させることVこよ
っ工行なう。
Hereinafter, the operation of the embodiment of the present invention will be explained in detail. First, the general operation will be explained using FIG. 1 and the second factor. The clock selection circuit 7 is supplied with a clock Δ and a clock B, respectively, via lines 2.3. Clog, N.
and clock B are clocks with different frequencies. usually,
10,000 clocks, either clock A or clock B (
The CPU is operating on the g output (line 5). To switch to the other clock, allocate the control signal (line 4) to a certain boat address, access that port using a program, and invert the control signal fg.

21Jち、あるツーミグラムにおいてタイマ(ループ)
に相当する部分(:」2図C′ζ7バすフローチャート
のwa日)でカウント回数をセットした後に第1図に示
したクロック選択回w!!rLが割シ当てられているボ
ートを゛アクセスしプログラム設計時の処理クロックに
必要に応じて切交えることによって実際にループする間
のクロックを固定する。ループが終了したならば、また
ボートをアク+!入ヒ進常のCP Uクロックに切換え
て続く処理?行なうようにする。
21J, a timer (loop) in a certain Tumigram
After setting the count number in the part corresponding to (: wa day in the flowchart shown in Figure 2 C'ζ7 bus), the clock selection time w! shown in Figure 1 is set. ! The clock during the actual loop is fixed by accessing the port to which rL is assigned and switching the processing clock at the time of program design as necessary. Once the loop is complete, activate the boat again! Processing that continues after switching to the normal CPU clock? Let's do it.

q下、第3図、第4図を用い−〔り1jツク切換えの動
作につき詳細に説明する。
The operation of switching from 1 to 1 will be explained in detail with reference to FIGS. 3 and 4 below.

フリップフロップ11はOUT命令によシデータビット
Dnの到来を待ってセット/リセットされ、クロック選
択信号(ライン4)を記憶する。ここでライン4を仁播
する信号がHigh“レベルであるとき、ブリップフロ
ップ12〜15はセット状態忙あシ、オアダート16の
一方は“Hi g h”レベルであるのでクロッグΔは
無視されている。オアゲートZ7の一方の入方’d、 
” Low ”レベルにあるので、クロック13がアン
ドゲートI8を通してライン5に出力されティる。OU
1゛命令によりフリップフロップ11がリセットされる
と、クロックBの立上りでフリップフロップ14及び1
5がリセッ上される。フリップフロップ15がリセット
されると、オアゲート17の一方が” High″レベ
ルになりクロックBが無視される。フリップフロップI
2のプリセットが”Hlgh”レベルとなるとクロック
Aの)1上シでフリップフロップ12及び13がリセッ
トされ、オアゲート16の一方が”Low”レベルとな
るので、クロ=y’7^がアンドゲートlBを湧し1ラ
イン5に出力はれ乙ようになる。プリップフロップ11
がセットはれるときはこの逆の動作でクロックAからク
ロックBへの切換オ、が行われる。
Flip-flop 11 is set/reset by the OUT command waiting for the arrival of data bit Dn and stores the clock selection signal (line 4). Here, when the signal transmitted on line 4 is at a high level, flip-flops 12 to 15 are busy in the set state, and one of the ordarts 16 is at a high level, so the clog Δ is ignored. .One way of entering Or Gate Z7'd,
Since it is at "Low" level, clock 13 is output to line 5 through AND gate I8. OU
When flip-flop 11 is reset by the 1'' instruction, flip-flops 14 and 1 are reset at the rising edge of clock B.
5 is reset. When the flip-flop 15 is reset, one of the OR gates 17 becomes "High" level and the clock B is ignored. flip flop I
When the preset number 2 becomes "Hlgh" level, the flip-flops 12 and 13 are reset by 1 of the clock A, and one of the OR gates 16 becomes "Low" level, so that the clock signal y'7^ becomes the AND gate 1B. The output will appear on line 1 and 5. flip flop 11
When the clock is set, the switching from clock A to clock B is performed in the reverse operation.

この回路の特徴は切換えの時に高周波数の″ブロック(
この実施例ではクロックA)の7497幅より狭いノ々
ルスとならないことにより、ダイナミックに切換えを行
ってもMPUの動作が保証されることである。クロック
の遅いシステムではクロック選択(ロ)路りを持たさな
ければ切喚えのためのIJUT命令はNOオペレーシプ
ンとなる。故にソフトウェアは42図に示すようにコー
ディングさえしておけば性能アップのためにクロツク周
波数を上げてもループ回数を変更する必要はなくなるっ 〔発明の効果〕 以上説明の様に、上述したーフロック選択回路を付加し
、且つフローチャートで示すタイマ部のプログラムを用
意することンこよ)以下に示す効果が得られる−0即ち
、クロックAにてCPUが動作していると仮定し、その
クロックスピードにてクロックBのスピードで作らnた
ソフトウェアタイマを実行すると論理的なWai1時間
が確保できなくなる。(クロックAがクロックBより速
ければWait時間は短かくなる。)従来はクロックが
変わるごとにタイマのプログラムを変更しなければなら
なかったが、本発明の様に選択回#!!を付加して複数
のクロックをへカしておき、C1’Uのクロックがスピ
ードアップさtとてもタイマに使われているクロックが
選択回路に人力きれていればタイマ部のクロックは常に
固定されることになシ、従ってプログラムの変更が不要
となるものである。
The feature of this circuit is that a high frequency block (
In this embodiment, since the clock pulses are not narrower than the 7497 width of the clock A), the operation of the MPU is guaranteed even if dynamic switching is performed. In a system with a slow clock, unless a clock selection method is provided, the IJUT command for switching will be a NO operation. Therefore, as long as the software is coded as shown in Figure 42, there is no need to change the number of loops even if the clock frequency is increased to improve performance. Add a circuit and prepare the timer program shown in the flowchart) The following effects can be obtained: -0 That is, assuming that the CPU is operating at clock A, at that clock speed. If a software timer created at the speed of clock B is executed, the logical Wait1 time cannot be secured. (If clock A is faster than clock B, the Wait time will be shorter.) Conventionally, the timer program had to be changed every time the clock changed, but with the present invention, the timer program can be changed every time the clock changes. ! If multiple clocks are separated by adding , the speed of C1'U's clock will be sped up.If the clock used in the timer is fully loaded in the selection circuit, the clock in the timer section will always be fixed. In particular, there is no need to change the program.

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

第1図は本発明の実施例を示すブロック図、第2図はタ
イマ部分のクロックのスピードを固定とするプログラム
の動作フローを示す図、第3図は第1図に示したクロッ
ク選択回路の畦細な回′#5榴fii、?I−示す図、
第4図は本発明実施例の動作を示すタイミングチャート
である。 L・・・クロック選択回路、11〜15・・・Dタイプ
フリップフロップ、16.17・・・オアゲート、18
・・・アンドゲート。
FIG. 1 is a block diagram showing an embodiment of the present invention, FIG. 2 is a diagram showing the operation flow of a program in which the clock speed of the timer section is fixed, and FIG. A detailed episode'#5? I - diagram showing,
FIG. 4 is a timing chart showing the operation of the embodiment of the present invention. L... Clock selection circuit, 11-15... D type flip-flop, 16.17... OR gate, 18
...and gate.

Claims (1)

【特許請求の範囲】[Claims] 互いに周波数の異なるクロックが複数入力され、制御信
号によりいずれか一方のクロックを動作クロックとして
プロセッサユニットへ供給するクロック選択回路と、タ
イマに相当するカウント値が設定され、あらかじめ上記
クロック選択回路が割りあてられてあるポートをアクセ
スして上記制御信号を生成し、必要に応じて上記クロッ
クを切換える様にプログラムされたメモリとを具備する
ことを特徴とするコンピュータシステム。
A plurality of clocks with different frequencies are input, and a clock selection circuit supplies one of the clocks to the processor unit as an operating clock according to a control signal, and a count value corresponding to a timer is set, and the clock selection circuit is assigned in advance. a memory programmed to generate the control signal by accessing a port configured to control the clock, and to switch the clock as necessary.
JP60216474A 1985-09-30 1985-09-30 Computer system Expired - Lifetime JPH0740213B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP60216474A JPH0740213B2 (en) 1985-09-30 1985-09-30 Computer system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP60216474A JPH0740213B2 (en) 1985-09-30 1985-09-30 Computer system

Publications (2)

Publication Number Publication Date
JPS6275822A true JPS6275822A (en) 1987-04-07
JPH0740213B2 JPH0740213B2 (en) 1995-05-01

Family

ID=16689011

Family Applications (1)

Application Number Title Priority Date Filing Date
JP60216474A Expired - Lifetime JPH0740213B2 (en) 1985-09-30 1985-09-30 Computer system

Country Status (1)

Country Link
JP (1) JPH0740213B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016143402A (en) * 2015-02-05 2016-08-08 富士通株式会社 Timer control device, radio communication device and timer control method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6020224A (en) * 1983-07-15 1985-02-01 Hitachi Ltd Semiconductor integrated circuit device
JPS61109126A (en) * 1984-10-31 1986-05-27 Mitsubishi Electric Corp One-chip microcomputer

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6020224A (en) * 1983-07-15 1985-02-01 Hitachi Ltd Semiconductor integrated circuit device
JPS61109126A (en) * 1984-10-31 1986-05-27 Mitsubishi Electric Corp One-chip microcomputer

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016143402A (en) * 2015-02-05 2016-08-08 富士通株式会社 Timer control device, radio communication device and timer control method

Also Published As

Publication number Publication date
JPH0740213B2 (en) 1995-05-01

Similar Documents

Publication Publication Date Title
EP0242010B1 (en) Clock circuit for a data processor
CA1091355A (en) Microprocessor system
CA1236582A (en) Processor i/o and interrupt filters
US4271466A (en) Direct memory access control system with byte/word control of data bus
JPH11238030A (en) Pci-pci bridge and its fast-in fast-out memory
JPS6312049A (en) Microcomputer
EP0355462B1 (en) Dedicated service processor with inter-channel communication features
US20030079152A1 (en) Microprocessor with multiple low power modes and emulation apparatus for said microprocessor
JPS63282511A (en) Clock generating circuit for microcomputer
JPH0574862B2 (en)
EP0110227B1 (en) Control memory organization
EP0363567B1 (en) A computer with interrupt controlled clock speed and its method of operation
JPS6275822A (en) Computer system
JPS6312286B2 (en)
JPS61141064A (en) Electronic circuit
JP2623833B2 (en) Clock advance control system
JP2870812B2 (en) Parallel processor
JPS59189435A (en) Data transfer control device
CA1103367A (en) Microprocessor system
JPH0616304B2 (en) Alternative method of CPU function at low power consumption
JPH01112335A (en) Electronic equipment
JPH0782463B2 (en) Communication control device
JPH087608B2 (en) Pulse output device
JP2002207531A (en) Semiconductor integrated circuit
JPS6214866B2 (en)