JP3206010B2 - Time stamp circuit - Google Patents

Time stamp circuit

Info

Publication number
JP3206010B2
JP3206010B2 JP03140491A JP3140491A JP3206010B2 JP 3206010 B2 JP3206010 B2 JP 3206010B2 JP 03140491 A JP03140491 A JP 03140491A JP 3140491 A JP3140491 A JP 3140491A JP 3206010 B2 JP3206010 B2 JP 3206010B2
Authority
JP
Japan
Prior art keywords
clock
count
gray code
output
input
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
JP03140491A
Other languages
Japanese (ja)
Other versions
JPH04246741A (en
Inventor
正康 杉森
正治 田内
Original Assignee
安藤電気株式会社
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 安藤電気株式会社 filed Critical 安藤電気株式会社
Priority to JP03140491A priority Critical patent/JP3206010B2/en
Publication of JPH04246741A publication Critical patent/JPH04246741A/en
Application granted granted Critical
Publication of JP3206010B2 publication Critical patent/JP3206010B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】インサーキットエミュレータのリ
アルタイムトレース機能やロジックアナライザの非同期
サンプリングモードでは、被試験器のマイクロプロセッ
サ(以下、CPUという。)のバス信号にプローブを接
続して、CPUのメモリやIOデバイスに対するアクセ
スをトレースし、CPUを利用した被試験器のデバッグ
情報を得ているが、その際それぞれのアクセス間の時間
間隔がわかると、より有効なデバッグ情報を得られる。
このため、CPUのバス情報と同時に時間情報もトレー
スすることのできるインサーキットエミュレータやロジ
ックアナライザが提供されている。この発明は、これら
の時間測定機能をもつ電子計測器において正確な時間を
測定するためのタイムスタンプ回路についてのものであ
る。
2. Description of the Related Art In a real-time trace function of an in-circuit emulator or an asynchronous sampling mode of a logic analyzer, a probe is connected to a bus signal of a microprocessor (hereinafter, referred to as a CPU) of a device under test so that a memory of the CPU or the like can be used. The access to the IO device is traced, and the debug information of the device under test using the CPU is obtained. If the time interval between the accesses is known, more effective debug information can be obtained.
For this reason, in-circuit emulators and logic analyzers that can trace time information as well as CPU bus information are provided. The present invention relates to a time stamp circuit for measuring accurate time in an electronic measuring instrument having such a time measuring function.

【0002】[0002]

【従来の技術】次に、従来技術によるタイムスタンプ回
路の構成を図2により説明する。図2の1はバイナリカ
ウンタ、4はアドレスカウンタ、5はメモリである。バ
イナリカウンタ1にはカウントクロック11が入力さ
れ、アドレスカウンタ4とメモリ5にはストアクロック
12が入力される。カウントクロック11はタイムスタ
ンプ回路に要求される時間分解能によって決まる周期ク
ロックである。
2. Description of the Related Art Next, the configuration of a conventional time stamp circuit will be described with reference to FIG. 2 is a binary counter, 4 is an address counter, and 5 is a memory. A count clock 11 is input to the binary counter 1, and a store clock 12 is input to the address counter 4 and the memory 5. The count clock 11 is a periodic clock determined by the time resolution required for the time stamp circuit.

【0003】例えば、タイムスタンプ回路に1μsの分
解能が必要であれば、カウントクロック11には1MH
z以上のクロックが供給される必要がある。一方、スト
アクロック12は被試験器がメモリやIOデバイスをア
クセスする度にアクティブとなる非周期的なクロックで
あり、通常は被試験器のCPUのデータストローブ信号
等が供給される。バイナリカウンタ1のカウント出力1
3はメモリ5のデータ入力端子に接続され、アドレスカ
ウンタ4のカウント出力14はメモリ5のアドレス入力
端子に接続される。
For example, if the time stamp circuit requires a resolution of 1 μs, the count clock 11 needs to be 1 MHz.
Clocks of z or more need to be supplied. On the other hand, the store clock 12 is an aperiodic clock that is activated every time the device under test accesses a memory or an IO device, and is usually supplied with a data strobe signal of the CPU of the device under test. Count output 1 of binary counter 1
3 is connected to the data input terminal of the memory 5, and the count output 14 of the address counter 4 is connected to the address input terminal of the memory 5.

【0004】バイナリカウンタ1は周期クロックのカウ
ントクロック11でカウントアップされるので、被試験
器の動きとは独立に周期的にカウントアップされる。一
方、図示を省略した被試験器のCPUがメモリなどをア
クセスすると、ストアクロック12がアクティブとな
り、アドレスカウンタ4が指す番地にそのときのバイナ
リカウンタ1のカウント出力13がメモリ5に書き込ま
れる。同時にアドレスカウンタ4にはカウントクロック
が供給され、+1だけカウントアップされ、メモリ5の
次の番地を指す。これらの動作をストアクロック12が
アクティブとなる度に実行することにより、メモリ5に
は被試験器のメモリなどへのアクセスごとの時間情報が
書き込まれ、アクセス間の時間間隔がトレースされる。
Since the binary counter 1 is counted up by the count clock 11 of the periodic clock, it is counted up independently of the movement of the device under test. On the other hand, when the CPU of the UUT (not shown) accesses the memory or the like, the store clock 12 becomes active, and the count output 13 of the binary counter 1 at that time is written into the memory 5 at the address indicated by the address counter 4. At the same time, a count clock is supplied to the address counter 4 and counted up by +1 to indicate the next address of the memory 5. By executing these operations each time the store clock 12 becomes active, time information for each access to the memory of the device under test is written in the memory 5 and the time interval between accesses is traced.

【0005】[0005]

【発明が解決しようとする課題】カウントクロック11
は一定周期ごとの周期クロックであり、ストアクロック
12は被試験器の動きに同期した非周期クロックであ
る。したがって、一般にはカウントクロック11とスト
アクロック12は同期しておらず、それぞれのクロック
の立上りエッジが同じタイミングで供給される場合があ
り得る。そのようなタイミングでは、バイナリカウンタ
1のカウント出力13が安定していないので、メモリ5
にはカウンタが変化する途中の無効なデータが書き込ま
れる場合がある。
SUMMARY OF THE INVENTION Count clock 11
Is a periodic clock at regular intervals, and the store clock 12 is an aperiodic clock synchronized with the movement of the device under test. Therefore, in general, the count clock 11 and the store clock 12 are not synchronized, and the rising edges of the respective clocks may be supplied at the same timing. At such a timing, since the count output 13 of the binary counter 1 is not stable, the memory 5
In some cases, invalid data is written while the counter is changing.

【0006】例えば、バイナリカウンタ1の出力13が
「3」(2進数で「011」)のときにカウントクロッ
ク11とストアクロック12が同時に供給されると、バ
イナリカウンタ1を構成するフリップフロップの微妙な
動作タイミングの違いにより、メモリ5には「0」から
「7」のどの値が書き込まれるかわからないことにな
る。
For example, if the count clock 11 and the store clock 12 are supplied at the same time when the output 13 of the binary counter 1 is "3"("011" in binary number), the flip-flops constituting the binary counter 1 are delicate. Due to such a difference in operation timing, it is not known which value from “0” to “7” is written in the memory 5.

【0007】従来はカウントクロック11とストアクロ
ック12の間で位相を調整して2つのクロックが重なら
ないようにする等の手段がとられてきたが、回路構成が
複雑になるとともに、被試験器の動作の高速化に伴って
ストアクロック12が高速化され、位相調整回路を挿入
するのが困難となっている。
Conventionally, means such as adjusting the phase between the count clock 11 and the store clock 12 so that the two clocks do not overlap with each other have been taken. As the operation speed increases, the store clock 12 speeds up, making it difficult to insert a phase adjustment circuit.

【0008】この発明は、バイナリカウンタ1の後にグ
レイコード変換回路とレジスタを設け、時間データをグ
レイコードとしてメモリ5に書き込むことにより、無効
なデータを書き込むことのないタイムスタンプ回路の提
供を目的とする。
An object of the present invention is to provide a time stamp circuit which does not write invalid data by providing a gray code conversion circuit and a register after a binary counter 1 and writing time data as a gray code in a memory 5. I do.

【0009】[0009]

【課題を解決するための手段】この目的を達成するた
め、この発明では、(a)カウントクロック11により
カウントアップするバイナリカウンタ1と、(b)バイ
ナリカウンタ1のカウント出力を入力とし、グレイコー
ドを出力するグレイコード変換回路2と、(c)グレイ
コード変換回路2の出力を入力とし、バイナリカウンタ
1における前記カウンタクロック11から前記カウント
出力までの遅延時間と、グレイコード変換回路2におけ
るカウント出力の入力からグレイコードの出力までの遅
延時間との総和以上の時間だけカウントクロック11と
比べて位相が遅延し、かつ、カウンタクロック11と同
一の周期を有するラッチクロック15によりラッチする
レジスタ3と、(d)カウントクロック11とは非同期
なストアクロック12によってカウントアップするアド
レスカウンタ4と、(e)データ信号としてレジスタ3
の出力17が入力され、アドレス信号としてアドレスカ
ウンタ4の、出力14が入力され、ライトイネーブル信
号として前記ストアクロック12が入力されるメモリ5
とを備えて、タイムスタンプ回路を構成する。ここで、
ラッチクロック15を、カウンタクロック11の反転信
号として構成することも可能である。
In order to achieve this object, according to the present invention, (a) a binary counter 1 which counts up by a count clock 11 and (b) a count output of the binary counter 1 are input and a gray code And (c) a delay time from the counter clock 11 in the binary counter 1 to the count output, and a count output in the gray code conversion circuit 2. A register 3 that is delayed by a time equal to or longer than the sum of the delay time from the input of the gray code to the output of the gray code compared with the count clock 11 and latched by a latch clock 15 having the same cycle as the counter clock 11; (D) Store clock 1 asynchronous with count clock 11 An address counter 4 which counts up by the register 3 as (e) a data signal
Of the address counter 4 as an address signal, and the store clock 12 as a write enable signal.
To form a time stamp circuit. here,
The latch clock 15 can be configured as an inverted signal of the counter clock 11.

【0010】[0010]

【作用】次に、この発明によるタイムスタンプ回路の構
成を図1により説明する。バイナリカウンタ1には周期
クロックのカウントクロック11が入力され、周期的に
カウントアップされる。カウント出力13はグレイコー
ド変換回路2によりグレイコード16に変換される。グ
レイコード変換回路2の出力16は、レジスタ3により
ラッチクロック15に同期してグレイコード17として
出力される。グレイコード17はメモリ5のデータ入力
端子に接続される。
Next, the configuration of the time stamp circuit according to the present invention will be described with reference to FIG. The count clock 11 of the periodic clock is input to the binary counter 1 and is counted up periodically. The count output 13 is converted into a gray code 16 by the gray code conversion circuit 2. The output 16 of the gray code conversion circuit 2 is output as a gray code 17 by the register 3 in synchronization with the latch clock 15. The gray code 17 is connected to a data input terminal of the memory 5.

【0011】ラッチクロック15は、カウントクロック
11の立上りエッジの後、グレイコード変換回路2が動
作するのに十分な時間だけ遅れてから立上がる周期クロ
ックであり、カウントクロック11とは周波数が同じで
位相だけが異なる。したがって、ラッチクロック15に
よってグレイコード変換回路2の出力16がレジスタ3
にラッチされる時点においては、カウントクロック11
によるカウントアップに伴うバイナリカウンタ1のカウ
ント出力13における過渡状態、および、入力の変化に
伴うグレイコード変換回路2の出力16における過渡状
態は終了しているので、レジスタ3には、カウント出力
13に対して論理的に正確なグレイコードがラッチされ
る。アドレスカウンタ4にはストアクロック12が入力
され、被試験器の動作に応じてカウントアップされると
ともに、出力14がメモリ5のアドレス端子に接続され
る。メモリ5のライトイネーブル端子にはストアクロッ
ク12が入力される。
The latch clock 15 is a periodic clock that rises after a sufficient time for the Gray code conversion circuit 2 to operate after the rising edge of the count clock 11, and has the same frequency as the count clock 11. Only the phase differs. Therefore, the output 16 of the gray code conversion circuit 2 is changed to the register 3 by the latch clock 15.
At the time when the count clock 11
Since the transient state at the count output 13 of the binary counter 1 due to the count-up and the transient state at the output 16 of the gray code conversion circuit 2 due to the change in the input have been completed, the register 3 A logically correct gray code is latched. The store clock 12 is input to the address counter 4, the count is incremented according to the operation of the device under test, and the output 14 is connected to the address terminal of the memory 5. The store clock 12 is input to the write enable terminal of the memory 5.

【0012】被試験器のCPUがメモリなどをアクセス
してストアクロック12がアクティブになると、メモリ
5のアドレスカウンタ4が指す番地に、そのときのバイ
ナリカウンタ1の出力13をグレイコードに変換したレ
ジスタ3の出力17が書き込まれる。同時にアドレスカ
ウンタ4は+1だけカウントアップされ、次に書き込む
メモリ5の番地をポイントする。上述のように、レジス
タ3からはカウント出力13に対して論理的に正確なグ
レイコードが出力されており、かつ、グレイコードは、
表1に示すように+1のカウントアップに対して常に1
ビットしか変化しないので、ストアクロック12がラッ
チクロック15と同時のタイミングで入力しても無意味
なデータがメモリに書き込まれることはない。なお、カ
ウントクロック11のハイレベルの時間が、カウントク
ロック11の立上りエッジの後、グレイコード変換回路
2が動作するのに十分な時間を有する場合には、カウン
トクロック11を反転することによりラッチクロック1
5を簡易に得ることができる。
When the CPU of the device under test accesses the memory or the like and the store clock 12 is activated, the output 13 of the binary counter 1 at that time is stored in the address indicated by the address counter 4 of the memory 5 in the form of a gray code. The output 17 of 3 is written. At the same time, the address counter 4 counts up by +1 and points to the address of the memory 5 to be written next. As described above, a logically accurate Gray code is output from the register 3 with respect to the count output 13, and the Gray code is
As shown in Table 1, the count value of +1 is always 1
Since only the bits change, even if the store clock 12 is input at the same time as the latch clock 15, meaningless data will not be written to the memory. If the high-level time of the count clock 11 has a sufficient time after the rising edge of the count clock 11 for the gray code conversion circuit 2 to operate, the count clock 11 is inverted to obtain the latch clock. 1
5 can be easily obtained.

【0013】[0013]

【表1】 [Table 1]

【0014】例えば、バイナリカウンタ1のカウント値
13が「3」(011)から「4」(100)に変化し
たときにストアクロック12とラッチクロック15が同
時に入力されたとしても、グレイコードの上では変化す
るのはビット2だけなので、メモリ5に書き込まれるの
は、グレイコードの「3」(010)か「4」(11
0)のどちらかであり、カウント出力14を直接書き込
んだときのように「0」から「7」のどの値が書かれる
かわからないといった、無意味なデータが書き込まれる
ことはない。
For example, even if the store clock 12 and the latch clock 15 are input simultaneously when the count value 13 of the binary counter 1 changes from "3" (011) to "4" (100), the gray code Since only the bit 2 changes, the gray code “3” (010) or “4” (11
0), and meaningless data is not written, such as not knowing which value from “0” to “7” is to be written as when the count output 14 is directly written.

【0015】[0015]

【実施例】次に、この発明による実施例の構成を図3に
より説明する。バイナリカウンタ1は16ビットで構成
され、カウントクロック11として1MHzの周期クロ
ックが入力される。したがって、図3では時間分解能が
1μs、最大計数時間65.535msのタイムスタン
プ回路が構成される。バイナリカウンタ1のカウント出
力13はグレイコード変換回路2に接続され、グレイコ
ード変換回路2の出力であるグレイコード16はレジス
タ3に入力される。レジスタ3にはラッチクロック15
としてカウントクロック11の反転信号が接続されるの
で、カウントクロック11の立上りエッジでカウントさ
れた値が立下りエッジでレジスタ3にラッチされ、グレ
イコード17として出力される。グレイコード17はメ
モリ5のデータ入力端子に接続される。
Next, the configuration of an embodiment according to the present invention will be described with reference to FIG. The binary counter 1 is composed of 16 bits, and a 1 MHz periodic clock is input as the count clock 11. Therefore, in FIG. 3, a time stamp circuit having a time resolution of 1 μs and a maximum counting time of 65.535 ms is configured. The count output 13 of the binary counter 1 is connected to the gray code conversion circuit 2, and the gray code 16 output from the gray code conversion circuit 2 is input to the register 3. Register 3 has latch clock 15
Since the inverted signal of the count clock 11 is connected, the value counted at the rising edge of the count clock 11 is latched in the register 3 at the falling edge and output as the gray code 17. The gray code 17 is connected to a data input terminal of the memory 5.

【0016】アドレスカウンタ4は12ビットで構成さ
れ、ストアクロック12の立上りエッジでカウントアッ
プされる。アドレスカウンタ4の出力14は、メモリ5
のアドレス入力端子に接続される。したがって、図3で
は「4096」ステップまでの時間情報のトレースをす
ることができる。メモリ5のライトイネーブル端子には
ストアクロック12が接続され、ストアクロック12が
低レベルのときカウント出力14の指す番地にグレイコ
ード17のデータを書き込む。
The address counter 4 has 12 bits and counts up at the rising edge of the store clock 12. The output 14 of the address counter 4 is
Is connected to the address input terminal of Therefore, in FIG. 3, the time information up to the “4096” step can be traced. A store clock 12 is connected to a write enable terminal of the memory 5, and when the store clock 12 is at a low level, data of a gray code 17 is written to an address indicated by the count output 14.

【0017】次に、グレイコード変換回路2の実施例の
回路図を図4により説明する。図4では簡単のために、
5ビットのグレイコード変換回路を図示しているが、1
6ビットであっても排他的論理和回路素子を15個用い
ることにより同様に構成することができる。すなわち、
グレイコードの任意のビット位置の値を得るには、それ
に対応するバイナリコードの同ビットの値とその1ビッ
ト上位の値の排他的論理和をとればよい。図4では、I
N0とOUT0側がLSB、IN4とOUT4側がMS
Bである。
Next, a circuit diagram of an embodiment of the gray code conversion circuit 2 will be described with reference to FIG. In FIG. 4, for simplicity,
Although a 5-bit Gray code conversion circuit is shown in FIG.
Even with 6 bits, the same configuration can be achieved by using 15 exclusive OR circuit elements. That is,
In order to obtain a value at an arbitrary bit position of the Gray code, the value of the same bit of the binary code corresponding to the Gray code and the value of one bit higher than the exclusive OR may be calculated. In FIG.
N0 and OUT0 side are LSB, IN4 and OUT4 side are MS
B.

【0018】次に、図3の作用を説明する。バイナリカ
ウンタ1には1MHzのカウントクロック11が入力さ
れるので、1μsごとにカウント出力13がカウントア
ップされる。このカウント出力13は、グレイコード変
換回路2によりグレイコード16に変換され、レジスタ
3に入力される。レジスタ3にはラッチクロック15と
してカウントクロック11の反転信号が入力されるの
で、バイナリカウンタ1がカウントアップして500n
s後に立上りエッジが入力される。
Next, the operation of FIG. 3 will be described. Since the 1 MHz count clock 11 is input to the binary counter 1, the count output 13 is incremented every 1 μs. The count output 13 is converted into a gray code 16 by the gray code conversion circuit 2 and input to the register 3. Since the inverted signal of the count clock 11 is input to the register 3 as the latch clock 15, the binary counter 1 counts up to 500n
A rising edge is input after s.

【0019】バイナリカウンタ1とグレイコード変換回
路2の遅延時間とレジスタ3のセットアップ時間をすべ
て合わせても500ns以下なので、ラッチクロック1
5が入力されるまでにはグレイコード16は安定してお
り、無意味なデータがラッチされることはない。ラッチ
クロック15が入力されると、レジスタ3はグレイコー
ド16をラッチしてグレイコード17として出力する。
ここで重要なことは、グレイコードは+1のカウントア
ップに対して常に1ビットしか変化しないことである。
The total of the delay time of the binary counter 1 and the gray code conversion circuit 2 and the setup time of the register 3 is 500 ns or less.
By the time 5 is input, the gray code 16 is stable, and no meaningless data is latched. When the latch clock 15 is input, the register 3 latches the gray code 16 and outputs the gray code 17.
What is important here is that the Gray code always changes only one bit for a count-up of +1.

【0020】すなわち、ラッチクロック15が入力され
てレジスタ3にグレイコード16がラッチされても、グ
レイコード17はその前の値からは1ビットしか変化せ
ず、それ以外のビットは安定している。このため、ラッ
チクロック15が入力された瞬間の過渡状態でも、グレ
イコード17はクロック入力前の値か入力後の値のどち
らかしか取り得ず、複数のビットが同時に変化できるバ
イナリコードのように瞬間的に無意味なデータになるこ
とはない。グレイコード17はメモリ5のデータ入力端
子に接続されるので、メモリ5にはグレイコード17が
書き込まれる。
That is, even if the gray code 16 is latched in the register 3 by the input of the latch clock 15, the gray code 17 changes only one bit from its previous value, and the other bits are stable. . For this reason, even in the transient state at the moment when the latch clock 15 is input, the gray code 17 can take only the value before the clock input or the value after the input, and the gray code 17 has an instantaneous value like a binary code in which a plurality of bits can change simultaneously. It does not become meaningless data. Since the gray code 17 is connected to the data input terminal of the memory 5, the gray code 17 is written in the memory 5.

【0021】メモリ5のアドレス入力端子にはアドレス
カウンタ4のカウント出力14が接続され、アドレスカ
ウンタ4のカウントクロックとメモリ5のライトイネー
ブル信号にはストアクロック12が接続されるので、被
試験器からストアクロック12が入力されると、そのと
きアドレスカウンタ4が指していたメモリ5の番地に、
そのときのグレイコード17の値が書き込まれる。書き
込み完了後、ストアクロック12の立上りエッジでアド
レスカウンタ4が+1だけカウントアップされ、メモリ
5の次の番地を指す。
The count output 14 of the address counter 4 is connected to the address input terminal of the memory 5, and the store clock 12 is connected to the count clock of the address counter 4 and the write enable signal of the memory 5. When the store clock 12 is input, the address of the memory 5 pointed to by the address counter 4 at that time is
The value of the gray code 17 at that time is written. After the writing is completed, the address counter 4 is counted up by +1 at the rising edge of the store clock 12, and indicates the next address of the memory 5.

【0022】例えば、アドレスカウンタ4のカウント出
力14が16進数で「103H」、バイナリカウンタ1
のカウント出力13が16進数で「275FH」のとき
にストアクロック12が入力されると、メモリ5の「1
03H」番地に「275FH」のグレイコードである
「0011010011110000」が書き込まれた
後、アドレスカウンタ4がカウントアップされ、カウン
ト出力14が16進数の「104H」となる。
For example, if the count output 14 of the address counter 4 is "103H" in hexadecimal, the binary counter 1
When the store clock 12 is input when the count output 13 of the memory 5 is “275FH” in hexadecimal,
After "0011010011110000", which is the gray code of "275FH", is written into the address "03H", the address counter 4 is counted up, and the count output 14 becomes "104H" in hexadecimal.

【0023】次に、この状態でカウントクロック11が
1回入力された後、カウントクロック11の立下りエッ
ジ、すなわちラッチクロック15の立上りエッジがスト
アクロック12と同時に入力された場合を考える。カウ
ントクロック11が入力されたことにより、カウント出
力13は「2760H」にカウントアップされ、そのグ
レイコードである「001101001101000
0」がグレイコード16としてレジスタ3に入力され
る。
Next, it is assumed that, in this state, after the count clock 11 is input once, the falling edge of the count clock 11, that is, the rising edge of the latch clock 15 is input simultaneously with the store clock 12. As the count clock 11 is input, the count output 13 is counted up to “2760H” and its gray code “0011101001101000”
“0” is input to the register 3 as a gray code 16.

【0024】レジスタ3はラッチクロック15によりこ
の値をラッチしてグレイコード17として出力するが、
前の値である「0011010011110000」と
新しい値である「0011010011010000」
ではビット5の値だけ変化し、それ以外のビットは「0
011010011X10000」で変化しない。その
ため、ストアクロック12がラッチクロック15と同時
に入力されても、メモリ5の「104H」番地には「2
75FH」に対応するグレイコードか「2760H」に
対応するグレイコードのどちらかが書き込まれることに
なり、それ以外の無意味なデータが書き込まれることは
ない。
The register 3 latches this value by the latch clock 15 and outputs it as a gray code 17.
The previous value “0011010011110000” and the new value “001110100110000”
Then, only the value of bit 5 changes, and the other bits
011010011X10000 ". Therefore, even if the store clock 12 is input simultaneously with the latch clock 15, the address “104H” of the memory 5 is “2”.
Either the gray code corresponding to "75FH" or the gray code corresponding to "2760H" is written, and no other meaningless data is written.

【0025】「275FH」に対応するグレイコードと
「2760H」に対応するグレイコードのどちらが書き
込まれるかは、レジスタ3の遅延時間やメモリ5のセッ
トアップ時間などの微妙な関係により決まるので、あら
かじめ予測することはできない。しかし、どちらが書き
込まれても真の値に対してプラス・マイナス1ビット
(1μs)以下であり、誤差範囲に入っている。また、
ここで説明した以外の値に対しても同様に、ストアクロ
ック12とラッチクロック15が重なった場合でも、メ
モリ5には真の値に対してプラス・マイナス1ビットの
誤差範囲以下の正確な値が書き込まれる。
Whether the gray code corresponding to "275FH" or the gray code corresponding to "2760H" is written is determined in advance by a delicate relationship such as the delay time of the register 3 and the setup time of the memory 5, and so on. It is not possible. However, whichever is written, it is less than plus or minus 1 bit (1 μs) with respect to the true value, and is within the error range. Also,
Similarly, even when the store clock 12 and the latch clock 15 overlap each other for values other than those described above, the memory 5 stores an accurate value within an error range of plus or minus 1 bit with respect to the true value. Is written.

【0026】[0026]

【発明の効果】この発明によれば、計時のためにカウン
トアップされるバイナリカウンタのカウント出力をグレ
イコードに変換後、バイナリカウンタのカウント出力に
対して論理的に正確なグレイコードをラッチするととも
に、ラッチされたグレイコードをメモリに書き込むの
で、メモリに書き込み指示を与えるストアクロックとメ
モリへの書き込みデータであるグレイコードの発生のた
めのクロックとの間の位相関係がどのようなものであっ
ても、正確なデータを書き込むことができる。また、ス
トアクロックとグレイコードの発生のためのクロックと
の間における位相調整のような複雑な制御は必要でない
ので、クロックの上限周波数に対する制限も少なく、か
つ簡単な回路で実現できる。
According to the present invention, after converting the count output of the binary counter, which is counted up for time counting, into a gray code, a logically accurate gray code is latched with respect to the count output of the binary counter. Since the latched Gray code is written to the memory, what is the phase relationship between the store clock that gives the write instruction to the memory and the clock for generating the Gray code that is the data to be written to the memory? Also, accurate data can be written. Further, since complicated control such as phase adjustment between the store clock and the clock for generating the gray code is not required, the upper limit frequency of the clock is less restricted and can be realized with a simple circuit.

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

【図1】この発明によるタイムスタンプ回路の構成図で
ある。
FIG. 1 is a configuration diagram of a time stamp circuit according to the present invention.

【図2】従来技術によるタイムスタンプ回路の構成図で
ある。
FIG. 2 is a configuration diagram of a conventional time stamp circuit.

【図3】この発明による実施例の構成図である。FIG. 3 is a configuration diagram of an embodiment according to the present invention.

【図4】グレイコード変換回路2の実施例の回路図であ
る。
FIG. 4 is a circuit diagram of an embodiment of a gray code conversion circuit 2.

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

1 バイナリカウンタ 2 グレイコード変換回路 3 レジスタ 4 アドレスカウンタ 5 メモリ 11 カウントクロック 12 ストアクロック 15 ラッチクロック 17 グレイコード DESCRIPTION OF SYMBOLS 1 Binary counter 2 Gray code conversion circuit 3 Register 4 Address counter 5 Memory 11 Count clock 12 Store clock 15 Latch clock 17 Gray code

───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 昭63−163934(JP,A) 特開 昭53−111253(JP,A) 特開 昭62−242447(JP,A) 特開 昭58−142622(JP,A) 特開 昭63−150747(JP,A) ──────────────────────────────────────────────────続 き Continuation of the front page (56) References JP-A-63-163934 (JP, A) JP-A-53-111253 (JP, A) JP-A-62-242447 (JP, A) JP-A-58-1983 142622 (JP, A) JP-A-63-150747 (JP, A)

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 カウントクロック(11)によりカウン
トアップするバイナリカウンタ(1)と、 前記バイナリカウンタ(1)のカウント出力を入力と
し、グレイコードを出力するグレイコード変換回路
(2)と、 グレイコード変換回路(2)の出力を入力とし、前記バ
イナリカウンタ(1)における前記カウンタクロック
(11)から前記カウント出力までの遅延時間と、前記
グレイコード変換回路(2)における前記カウント出力
の入力からグレイコードの出力までの遅延時間との時間
との総和以上の時間だけ前記カウントクロック(11)
と比べて位相が遅延し、かつ、カウンタクロック(1
1)と同一の周期を有するラッチクロック(15)によ
りラッチするレジスタ(3)と、 前記カウントクロック(11)とは非同期なストアクロ
ック(12)によってカウントアップするアドレスカウ
ンタ(4)と、 データ信号として前記レジスタ(3)の出力(17)が
入力され、アドレス信号として前記アドレスカウンタ
(4)の出力(14)が入力され、ライトイネーブル信
号として前記ストアクロック(12)が入力されるメモ
リ(5)とを備えることを特徴とするタイムスタンプ回
路。
1. A binary counter (1) that counts up by a count clock (11), a gray code conversion circuit (2) that receives a count output of the binary counter (1) and outputs a gray code, The output of the conversion circuit (2) is input, the delay time from the counter clock (11) to the count output in the binary counter (1), and the delay time from the input of the count output in the Gray code conversion circuit (2) to gray The count clock (11) for a time equal to or longer than the sum of the delay time until the output of the code and the time.
And the counter clock (1
A register (3) latched by a latch clock (15) having the same cycle as 1); an address counter (4) counting up by a store clock (12) asynchronous to the count clock (11); The memory (5) to which the output (17) of the register (3) is input, the output (14) of the address counter (4) is input as an address signal, and the store clock (12) is input as a write enable signal. And a time stamp circuit.
【請求項2】 前記カウンタクロック(11)を論理反
転して、前記ラッチクロック(15)を生成するインバ
ータを更に備える、ことを特徴とする請求項1に記載の
タイムスタンプ回路。
2. The time stamp circuit according to claim 1, further comprising an inverter that logically inverts the counter clock (11) to generate the latch clock (15).
JP03140491A 1991-02-01 1991-02-01 Time stamp circuit Expired - Fee Related JP3206010B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP03140491A JP3206010B2 (en) 1991-02-01 1991-02-01 Time stamp circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP03140491A JP3206010B2 (en) 1991-02-01 1991-02-01 Time stamp circuit

Publications (2)

Publication Number Publication Date
JPH04246741A JPH04246741A (en) 1992-09-02
JP3206010B2 true JP3206010B2 (en) 2001-09-04

Family

ID=12330322

Family Applications (1)

Application Number Title Priority Date Filing Date
JP03140491A Expired - Fee Related JP3206010B2 (en) 1991-02-01 1991-02-01 Time stamp circuit

Country Status (1)

Country Link
JP (1) JP3206010B2 (en)

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS605097B2 (en) * 1977-02-18 1985-02-08 株式会社日立製作所 Gray code generation circuit
JPS63163934A (en) * 1986-12-26 1988-07-07 Fujitsu Ltd Bus trace system

Also Published As

Publication number Publication date
JPH04246741A (en) 1992-09-02

Similar Documents

Publication Publication Date Title
EP0225642B1 (en) Memory test pattern generator
JP2569589B2 (en) Counter circuit
US4731768A (en) Autoranging time stamp circuit
JPH0511329B2 (en)
US5592659A (en) Timing signal generator
JP3206010B2 (en) Time stamp circuit
US20100042373A1 (en) Signal measuring device and signal measuring method
JP2000035463A (en) Jitter measuring device and integrated circuit incorporating the device
JP2786033B2 (en) Time measuring device
JPS6067869A (en) Timing signal generator
JP2532718B2 (en) Semiconductor integrated circuit device
JPH052030A (en) Digital storage oscilloscope
JPH1194905A (en) Semiconductor tester
JP4189729B2 (en) Asynchronous readout method of timer count value and timer
JPS60100063A (en) Test pattern generating apparatus
JPH0536752B2 (en)
JPH09145798A (en) Timing signal generator
JPH0774818B2 (en) Timing signal generation circuit for tester
KR100446722B1 (en) Timer circuit, specially enabling a stable operation by generating a counter enable signal, and effectively conducting a test function by predicting a counting value of a timer
JP2709201B2 (en) Microcomputer
SU1513457A1 (en) Program debugging device
SU1509871A1 (en) Device for sorting information
SU1697105A1 (en) Apparatus for formation of vectors
JPH0894716A (en) Data logging circuit
JPH0526960A (en) Lsi tester

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313113

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees