JP5125363B2 - Waveform measuring device - Google Patents

Waveform measuring device Download PDF

Info

Publication number
JP5125363B2
JP5125363B2 JP2007254330A JP2007254330A JP5125363B2 JP 5125363 B2 JP5125363 B2 JP 5125363B2 JP 2007254330 A JP2007254330 A JP 2007254330A JP 2007254330 A JP2007254330 A JP 2007254330A JP 5125363 B2 JP5125363 B2 JP 5125363B2
Authority
JP
Japan
Prior art keywords
data
bus
waveform
bit rate
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.)
Active
Application number
JP2007254330A
Other languages
Japanese (ja)
Other versions
JP2009085710A (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.)
Yokogawa Electric Corp
Original Assignee
Yokogawa Electric 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 Yokogawa Electric Corp filed Critical Yokogawa Electric Corp
Priority to JP2007254330A priority Critical patent/JP5125363B2/en
Publication of JP2009085710A publication Critical patent/JP2009085710A/en
Application granted granted Critical
Publication of JP5125363B2 publication Critical patent/JP5125363B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Dc Digital Transmission (AREA)
  • Information Transfer Systems (AREA)

Description

本発明は、シリアルバスを介して伝送されるデータの波形を測定する波形測定装置に関する。   The present invention relates to a waveform measuring apparatus that measures the waveform of data transmitted via a serial bus.

デジタルオシロスコープ等の波形測定装置は、被測定信号の信号波形等を測定してその測定結果(信号波形等)を表示する装置であり、シリアルバスを介して伝送されるデータを測定する場合にも用いられる。近年において、波形測定装置は多機能化が進められており、単に測定結果を表示するのみならず、シリアルバスを介して伝送されるデータのプロトコルを解析する解析機能を備えるものがある。また、被測定信号の電圧ピーク値や周波数に基づいて自動的に表示画面の縦軸(例えば、信号レベルの軸)及び横軸(例えば、時間軸)のスケール(レンジ)を自動的に設定する自動設定機能(所謂オートセットアップ機能)を備えるものも多くなっている。   A waveform measurement device such as a digital oscilloscope is a device that measures the signal waveform of a signal under measurement and displays the measurement result (signal waveform, etc.). Even when measuring data transmitted via a serial bus, Used. In recent years, waveform measuring apparatuses have been increasingly multifunctional, and some of them have an analysis function for analyzing a protocol of data transmitted via a serial bus as well as simply displaying a measurement result. Also, the scale (range) of the vertical axis (eg, signal level axis) and horizontal axis (eg, time axis) of the display screen is automatically set based on the voltage peak value and frequency of the signal under measurement. Many have an automatic setting function (so-called auto setup function).

以下の特許文献1には、シリアルバスを介して伝送されるデータの波形歪やCRC(Cyclic Redundancy Check:巡回冗長検査)エラー情報等を解析し、その解析結果を表示するデータ解析装置が開示されている。また、以下の特許文献2,3には、表示画面の縦軸及び横軸のスケールを自動設定する技術が開示されてる、
特開2002−148283号公報 特開平6−213933号公報 特開平11−161520号公報
Patent Document 1 below discloses a data analysis device that analyzes waveform distortion, CRC (Cyclic Redundancy Check) error information, and the like of data transmitted via a serial bus, and displays the analysis results. ing. Further, the following Patent Documents 2 and 3 disclose techniques for automatically setting the scales of the vertical axis and the horizontal axis of the display screen.
JP 2002-148283 A JP-A-6-213933 JP 11-161520 A

ところで、被測定信号の波形を波形測定装置の表示画面に表示する場合において、上述したオートセットアップ機能を有効にすれば、表示画面の縦軸及び横軸のスケール(レンジ)の設定が自動的に行われる。このため、ユーザが手動で表示画面の縦軸及び横軸のスケールの設定を行わなくとも被測定信号に応じた適当なスケールが自動的に設定され、これにより適当な被測定信号の波形が表示画面に表示される。   By the way, when displaying the waveform of the signal under measurement on the display screen of the waveform measuring device, if the above-mentioned auto setup function is enabled, the scale (range) of the vertical and horizontal axes of the display screen is automatically set. Done. For this reason, an appropriate scale corresponding to the signal under measurement is automatically set without manually setting the vertical and horizontal scales of the display screen, thereby displaying the waveform of the appropriate signal under measurement. Displayed on the screen.

しかしながら、波形測定装置を用いてシリアルバスを解析する場合においては、測定対象のシリアルバスの種類に応じた初期設定をユーザが手動で行うことが必須となる。ここで、シリアルバスを解析するために必要な設定項目は、波形測定装置に設けられた設定メニューから設定しなければならないため、ユーザが設定メニューを熟知している必要がある。また、シリアルバスを解析するために必要な設定項目は、シリアルバスの種類に応じて多数あるため、初期設定に長時間を要するとともに煩雑な操作が必要になり、利便性が高いとは言えない状況にある。   However, when analyzing a serial bus using a waveform measuring apparatus, it is essential for the user to manually perform initial settings according to the type of serial bus to be measured. Here, since the setting items necessary for analyzing the serial bus must be set from the setting menu provided in the waveform measuring apparatus, the user needs to be familiar with the setting menu. In addition, since there are many setting items necessary for analyzing the serial bus depending on the type of serial bus, it takes a long time for the initial setting and requires complicated operations, which is not convenient. Is in the situation.

本発明は上記事情に鑑みてなされたものであり、シリアルバスを解析する際に必要な初期設定を自動化することにより、ユーザの利便性を高めることができる波形測定装置を提供することを目的とする。   The present invention has been made in view of the above circumstances, and an object of the present invention is to provide a waveform measuring apparatus that can enhance user convenience by automating initial settings required when analyzing a serial bus. To do.

上記課題を解決するために、本発明の波形測定装置は、シリアルバスを介して伝送されるデータの波形を測定する波形測定装置(1)において、前記データのビットレートを検出するビットレート検出手段(22)と、前記データに関する信号数を検出する入力信号検出手段(23)、前記データに関するクロック信号を検出するクロック検出手段(24)、及び前記データの極性を検出する極性検出手段(25)の少なくとも1つと、前記ビットレート検出手段の検出結果に加えて、前記入力信号検出手段、前記クロック検出手段、及び前記極性検出手段の検出結果の少なくとも1つに基づいて、前記シリアルバスの種類を判定する判定手段(27)とを備えることを特徴としている。
この発明によると、シリアルバスを介して伝送されるデータのビットレートがビットレート検出手段で検出され、データに関する信号数、データに関するクロック信号、及びデータの極性の少なくとも1つが入力信号検出手段、クロック検出手段、及び極性検出手段の少なくとも1つで検出され、ビットレート検出手段の検出結果に加えて、入力信号検出手段、クロック検出手段、及び極性検出手段の検出結果の少なくとも1つに基づいて判定手段でシリアルバスの種類が判定される
また、本発明の波形測定装置は、前記データに含まれる特定パターンを検出するパターン検出手段(26)を備えており、前記判定手段は、前記パターン検出手段の検出結果も加味して前記シリアルバスの種類を判定することを特徴としている。
また、本発明の波形測定装置は、前記ビットレート検出手段が、前記データの立ち上がりエッジと立ち下がりエッジとのエッジ位置をそれぞれ求め、当該エッジ位置の最短時間間隔から前記ビットレートを検出することを特徴としている。
また、本発明の波形測定装置は、前記クロック検出手段が、前記データのデューティ比に関するヒストグラムを求め、当該ヒストグラムの平均値及び標準偏差の少なくとも一方を用いて前記クロック信号の有無を検出することを特徴としている。
更に、本発明の波形測定装置は、前記極性検出手段が、前記データの電圧レベルに関するヒストグラムを求め、当該ヒストグラムの分布に基づいて前記データの極性を検出することを特徴としている。
In order to solve the above problems, a waveform measuring apparatus according to the present invention is a bit rate detecting means for detecting a bit rate of the data in the waveform measuring apparatus (1) for measuring a waveform of data transmitted via a serial bus. (22), an input signal detecting means (23) for detecting the number of signals relating to the data, a clock detecting means (24) for detecting a clock signal relating to the data, and a polarity detecting means (25) for detecting the polarity of the data. In addition to the detection result of the bit rate detection means and at least one of the detection results of the input signal detection means, the clock detection means, and the polarity detection means, the type of the serial bus is determined. And a judging means (27) for judging.
According to the present invention, the bit rate of the data transmitted via the serial bus is detected by the bit rate detecting means , and at least one of the number of signals related to data, the clock signal related to data, and the polarity of the data is the input signal detecting means, the clock Detected by at least one of the detection means and the polarity detection means, and determined based on at least one of the detection results of the input signal detection means, the clock detection means, and the polarity detection means in addition to the detection result of the bit rate detection means The type of serial bus is determined by means .
The waveform measuring apparatus of the present invention includes a pattern detecting means for detecting (26) a specific pattern contained in the data, said determining means, said serial bus also taken into consideration detection results of said pattern detecting means It is characterized by determining the type of the.
In the waveform measuring apparatus according to the present invention, the bit rate detecting means obtains edge positions of a rising edge and a falling edge of the data, and detects the bit rate from the shortest time interval between the edge positions. It is a feature.
In the waveform measurement apparatus of the present invention, the clock detection unit obtains a histogram relating to the duty ratio of the data, and detects the presence or absence of the clock signal using at least one of an average value and a standard deviation of the histogram. It is a feature.
Furthermore, the waveform measuring apparatus of the present invention is characterized in that the polarity detection means obtains a histogram relating to the voltage level of the data and detects the polarity of the data based on the distribution of the histogram.

本発明によれば、シリアルバスを介して伝送されるデータのビットレートを検出し、データに関する信号数、データに関するクロック信号、及びデータの極性の少なくとも1つを検出し、ビットレートの検出結果に加えて、データに関するクロック信号、及びデータの極性の検出結果の少なくとも1つに基づいてシリアルバスの種類を判定しているため、ユーザが煩雑な操作を行わなくともシリアルバスを解析する際に必要なシリアルバスの種類に応じた初期設定を自動化でき、ユーザの利便性を高めることができるという効果がある。また、シリアルバスの解析を行う際に必要であったユーザによる煩雑な操作を省くことができるため、シリアルバスの解析に要する時間を短縮することができるという効果がある。 According to the present invention, the bit rate of data transmitted via the serial bus is detected , and at least one of the number of signals related to data, the clock signal related to data, and the polarity of data is detected, and the bit rate detection result is obtained. In addition, since the type of serial bus is determined based on at least one of the clock signal related to data and the detection result of the polarity of the data, it is necessary for analyzing the serial bus without any complicated operation by the user. This makes it possible to automate the initial setting according to the type of serial bus and to improve user convenience. In addition, since it is possible to omit a complicated operation required by the user when analyzing the serial bus, the time required for the analysis of the serial bus can be shortened.

以下、図面を参照して本発明の一実施形態による波形測定装置について詳細に説明する。図1は、本発明の一実施形態による波形測定装置の正面図である。図1に示す通り、本実施形態の波形測定装置1は、その正面に入力端子部2、操作キー部3、及びディスプレイ4を備えており、入力端子部2から入力される被測定信号を測定し、その測定結果(信号波形等)をディスプレイ4に表示する。また、本実施形態の波形測定装置1は、シリアルバスを介して伝送されるデータのプロトコルを解析する解析機能を備えており、その解析結果もディスプレイ4に表示する。   Hereinafter, a waveform measuring apparatus according to an embodiment of the present invention will be described in detail with reference to the drawings. FIG. 1 is a front view of a waveform measuring apparatus according to an embodiment of the present invention. As shown in FIG. 1, the waveform measuring apparatus 1 according to this embodiment includes an input terminal unit 2, an operation key unit 3, and a display 4 on the front surface thereof, and measures a signal under measurement input from the input terminal unit 2. The measurement result (signal waveform or the like) is displayed on the display 4. Further, the waveform measuring apparatus 1 of the present embodiment has an analysis function for analyzing the protocol of data transmitted via the serial bus, and displays the analysis result on the display 4.

入力端子部2は複数の入力端子2aを備えており、各々の入力端子2aには必要に応じてプローブが接続される。本実施形態においては、入力端子部2に設けられた入力端子2aの1つに接続された1つのプローブ、又は複数の入力端子2aの各々に接続された複数のプローブの先端が、シリアルバスに電気的に接続されるものとする。尚、シリアルバスに電位的に接続されるプローブの数は、シリアルバスの種類に応じて変化する。操作キー部3は、ユーザの指示を波形測定装置1に入力するためのものであり、ユーザによって操作される複数のプッシュボタン3a、ロータリーノブ3b、初期設定ボタン3c等を備えている。   The input terminal unit 2 includes a plurality of input terminals 2a, and a probe is connected to each input terminal 2a as necessary. In this embodiment, the tip of one probe connected to one of the input terminals 2a provided in the input terminal portion 2 or the plurality of probes connected to each of the plurality of input terminals 2a is connected to the serial bus. It shall be electrically connected. Note that the number of probes connected to the serial bus in potential varies depending on the type of serial bus. The operation key unit 3 is for inputting a user instruction to the waveform measuring apparatus 1, and includes a plurality of push buttons 3a, a rotary knob 3b, an initial setting button 3c, and the like operated by the user.

ディスプレイ4は、例えば液晶表示装置又はCRT(Cathode Ray Tube)であり、測定した波形データ、波形データを波形解析して得られたデータ値、プロトコルの解析結果等の各種データを表示する。尚、ユーザが操作キー部3に対して所定の操作を行うことにより、ディスプレイ4の表示内容を切り替えることができる。尚、ディスプレイ4の表面にはタッチパネルが設けられており、ユーザがディスプレイの表面を押圧することによって、その操作内容に応じた指示を入力することができる。   The display 4 is, for example, a liquid crystal display device or a CRT (Cathode Ray Tube), and displays various data such as measured waveform data, data values obtained by waveform analysis of the waveform data, and protocol analysis results. Note that the display content of the display 4 can be switched when the user performs a predetermined operation on the operation key unit 3. Note that a touch panel is provided on the surface of the display 4, and the user can input an instruction corresponding to the operation content by pressing the surface of the display.

図2は、本発明の一実施形態による波形測定装置の要部構成を示すブロック図である。図2に示す通り、本実施形態の波形測定装置1は、プリアンプ11、A/D変換部12、データ処理部13、波形データメモリ14、制御部15、メモリ16、操作部17、表示処理部18、及び表示部19を備える。   FIG. 2 is a block diagram showing a main configuration of the waveform measuring apparatus according to the embodiment of the present invention. As shown in FIG. 2, the waveform measuring apparatus 1 according to the present embodiment includes a preamplifier 11, an A / D converter 12, a data processor 13, a waveform data memory 14, a controller 15, a memory 16, an operation unit 17, and a display processor. 18 and a display unit 19.

プリアンプ11は、図1に示す入力端子部2に設けられた入力端子2aの何れかである入力端子TM1から入力される信号を所定の増幅率で増幅する。A/D変換部12は、プリアンプ11で増幅された信号に対して標本化及び量子化を行って二値化し、ディジタル信号である波形データに変換する。尚、プリアンプ11及びA/D変換部12は図1に示した入力端子2aの数(入力チャネル数)に応じた数だけ設けられているが、図2においては1つのみを図示している。また、プリアンプ11の増幅率及びA/D変換部12のサンプリングレート等は制御部15によって制御される。   The preamplifier 11 amplifies a signal input from the input terminal TM1 which is one of the input terminals 2a provided in the input terminal unit 2 shown in FIG. 1 with a predetermined amplification factor. The A / D converter 12 performs sampling and quantization on the signal amplified by the preamplifier 11, binarizes it, and converts it into waveform data that is a digital signal. Note that the number of preamplifiers 11 and A / D converters 12 is the same as the number of input terminals 2a (number of input channels) shown in FIG. 1, but only one is shown in FIG. . The amplification factor of the preamplifier 11 and the sampling rate of the A / D converter 12 are controlled by the controller 15.

データ処理部13は、制御部15の制御の下で、A/D変換部12から出力される波形データ、又は波形データメモリ14から読み出した波形データに対して所定のデータ処理を行う。具体的には、制御部15の制御の下で、波形データメモリ14に対して波形データの読み出し処理及び書き込み処理を行う。また、制御部15の制御の下で、波形データの立ち上がりエッジや立ち下がりエッジのエッジ位置を検出する処理も行う。   The data processing unit 13 performs predetermined data processing on the waveform data output from the A / D conversion unit 12 or the waveform data read from the waveform data memory 14 under the control of the control unit 15. Specifically, under the control of the control unit 15, waveform data read processing and write processing are performed on the waveform data memory 14. Further, under the control of the control unit 15, processing for detecting the edge positions of the rising edge and the falling edge of the waveform data is also performed.

更に、データ処理部13は、制御部15の制御の下で、波形データメモリ14から読み出した波形データに対してシリアルバスの種類に応じた波形解析を行ってデータ値を求める。具体的には、シリアルバスを介して伝送されるデータを、その大きな区切りであるフレーム毎に切り出し、フレーム内におけるビットの並び(値「0」と「1」との並び)に応じたデータ値を求める。ここで、波形解析により得られるデータ値としては、例えばシリアルバスに接続された機器の種別を示す識別子であるID、機器から出力されるデータの種別を示す識別子であるID、機器から出力されるデータの値等がある。波形データメモリ14は、データ処理部13によって書き込まれる波形データを記憶するRAM(Random Access Memory)等のメモリ(アクイジションメモリ)である。   Further, under the control of the control unit 15, the data processing unit 13 obtains a data value by performing waveform analysis corresponding to the type of serial bus on the waveform data read from the waveform data memory 14. Specifically, the data transmitted via the serial bus is cut out for each large frame, and a data value corresponding to the bit sequence (sequence of values “0” and “1”) in the frame. Ask for. Here, as the data value obtained by the waveform analysis, for example, an ID that is an identifier indicating the type of the device connected to the serial bus, an ID that is an identifier indicating the type of data output from the device, and an output from the device There are data values. The waveform data memory 14 is a memory (acquisition memory) such as a RAM (Random Access Memory) that stores waveform data written by the data processing unit 13.

制御部15は、前述したデータ処理部13で行われるデータ処理、プリアンプ11の増幅率やA/D変換部12のサンプリングレートの制御、表示処理部18で行われる表示処理等を制御することにより波形測定装置1の動作を統括的に制御する。この制御部15は、初期条件設定部21、ビットレート検出部22(ビットレート検出手段)、入力信号検出部23(入力信号検出手段)、クロック検出部24(クロック検出手段)、バス信号検出部25(極性検出手段)、パターン検出部26(パターン検出手段)、及び判定部27(判定手段)を備える。   The control unit 15 controls the data processing performed by the data processing unit 13, the control of the amplification factor of the preamplifier 11 and the sampling rate of the A / D conversion unit 12, the display processing performed by the display processing unit 18, and the like. The operation of the waveform measuring apparatus 1 is comprehensively controlled. The control unit 15 includes an initial condition setting unit 21, a bit rate detection unit 22 (bit rate detection unit), an input signal detection unit 23 (input signal detection unit), a clock detection unit 24 (clock detection unit), and a bus signal detection unit. 25 (polarity detection means), a pattern detection section 26 (pattern detection means), and a determination section 27 (determination means).

初期条件設定部21は、ユーザによって、バス自動設定(シリアルバスの解析に必要な初期設定を自動化する設定)の指示がなされた場合に、バス自動設定を行うために最低限必要な初期条件を設定する。具体的には、入力チャネルの全てをオン状態(入力可能状態)に設定し、所定の基準ビットレート(例えば、10Mbps(bit per second))の信号に対して1ビット当たり十数点でアクイジションが可能なように、取り込み時間(時間軸)、その取り込み時間内における取り込み点数(レコード長)、及びトリガ条件、アクイジションモードを設定する。   The initial condition setting unit 21 sets a minimum initial condition necessary for performing automatic bus setting when a user gives an instruction for automatic bus setting (setting for automating initial settings necessary for serial bus analysis). Set. Specifically, all input channels are set to an on state (input enabled state), and acquisition is performed at a dozen points per bit with respect to a signal of a predetermined reference bit rate (for example, 10 Mbps (bit per second)). As possible, the acquisition time (time axis), the number of acquisition points (record length) within the acquisition time, the trigger condition, and the acquisition mode are set.

ビットレート検出部22は、データ処理部13を制御して波形データメモリ14に記憶された波形データに対して立ち上がりエッジ及び立ち下がりエッジのエッジ位置を検出させ、その検出結果を用いて入力端子TM1から入力されたデータのビットレートを算出する。図3は、ビットレート検出部22で行われる処理を説明するための図である。図3において、時刻t1,t3,t5,…は波形データの立ち上がりエッジのエッジ位置であり、時刻t2,t4,t6,…は波形データの立ち下がりエッジのエッジ位置である。   The bit rate detection unit 22 controls the data processing unit 13 to detect the edge position of the rising edge and the falling edge of the waveform data stored in the waveform data memory 14, and uses the detection result to input terminal TM1. The bit rate of the data input from is calculated. FIG. 3 is a diagram for explaining processing performed by the bit rate detection unit 22. 3, times t1, t3, t5,... Are edge positions of rising edges of waveform data, and times t2, t4, t6,... Are edge positions of falling edges of waveform data.

ビットレート検出部22は、データ処理部13で得られた立ち上がりエッジのエッジ位置と立ち下がりエッジのエッジ位置との時間間隔を求め(図3中の時間間隔T1〜T3)、次いでこの時間間隔の中から最短時間間隔(図3中の時間間隔T2)を求め、最後に最短時間間隔の逆数を求めてこれをビットレートとする。例えば、図3中の最短時間間隔T2が1μsecである場合には、ビットレートは1Mbpsになる。   The bit rate detection unit 22 obtains the time interval between the edge position of the rising edge and the edge position of the falling edge obtained by the data processing unit 13 (time intervals T1 to T3 in FIG. 3), and then the time interval The shortest time interval (time interval T2 in FIG. 3) is obtained from the inside, and finally the reciprocal of the shortest time interval is obtained and used as the bit rate. For example, when the shortest time interval T2 in FIG. 3 is 1 μsec, the bit rate is 1 Mbps.

入力信号検出部23は、シリアルバスを介して伝送されるデータに関する信号数(チャネル数)を検出する。例えば、シリアルバスの一種であるSPI(登録商標)(Serial Peripheral Interface)バスやIC(登録商標)(Inter-Integrated Circuit)バスにおいては、データ以外にCS信号(チップセレクト信号)が用いられている。入力信号検出部23はこのようなデータに関する信号が、データが入力される入力端子2a以外の入力端子2aから入力されているか否かを検出する。信号の有無は、例えば入力される信号の電圧値の最大ピーク値と最小ピーク値との差が所定の電圧値以上であるか否かにより検出する。 The input signal detection unit 23 detects the number of signals (number of channels) related to data transmitted via the serial bus. For example, an SPI (registered trademark) (Serial Peripheral Interface) bus or an I 2 C (registered trademark) (Inter-Integrated Circuit) bus, which is a kind of serial bus, uses a CS signal (chip select signal) in addition to data. ing. The input signal detector 23 detects whether or not a signal related to such data is input from an input terminal 2a other than the input terminal 2a to which data is input. The presence / absence of a signal is detected by, for example, whether or not the difference between the maximum peak value and the minimum peak value of the voltage value of the input signal is equal to or greater than a predetermined voltage value.

クロック検出部24は、シリアルバスを介して伝送されるデータに関するクロック信号を検出する。具体的には、データ処理部13を制御して波形データメモリ14に記憶された入力チャネル毎の波形データのデューティ比に関するヒストグラムを求め、このヒストグラムの平均値及び標準偏差の少なくとも一方を用いてクロック信号の有無を検出する。図4は、クロック検出部24で行われる処理を説明するための図である。   The clock detection unit 24 detects a clock signal related to data transmitted via the serial bus. Specifically, the data processing unit 13 is controlled to obtain a histogram relating to the duty ratio of the waveform data for each input channel stored in the waveform data memory 14, and the clock is obtained using at least one of the average value and the standard deviation of the histogram. Detect the presence or absence of a signal. FIG. 4 is a diagram for explaining processing performed by the clock detection unit 24.

図4(a)に示す通り、クロック信号は一定の周波数を有する信号であるとともにデューティ比が一定の信号である。このクロック信号のデューティ比に関するヒストグラムを求めると、図4(a)に示す通り、あるデューティ比DR1の頻度が突出して高く、デューティ比DR1以外のデューティ比では頻度が極端に小さくなってバラツキの小さなヒストグラムが得られる。例えば、クロック信号のデューティ比が30%であるとすると、ヒストグラムの平均値はクロック信号のデューティ比に近い値になり、標準偏差σは数%以下になる。   As shown in FIG. 4A, the clock signal is a signal having a constant frequency and a constant duty ratio. When the histogram relating to the duty ratio of the clock signal is obtained, as shown in FIG. 4A, the frequency of a certain duty ratio DR1 is prominently high, and the frequency is extremely small and the variation is small at duty ratios other than the duty ratio DR1. A histogram is obtained. For example, if the duty ratio of the clock signal is 30%, the average value of the histogram is close to the duty ratio of the clock signal, and the standard deviation σ is several percent or less.

これに対し、図4(b)に示す通り、データはその値に応じてデューティ比が頻繁に変化する信号である。このデータのデューティ比に関するヒストグラムを求めると、図4(b)に示す通り、特定のデューティ比の頻度が突出して高くなる訳ではなく、様々なデューティ比である程度の頻度をとり、分布が広がってバラツキが大きくなる。例えば、ヒストグラムの平均値はクロック信号のデューティ比から大きく異なった値になり、標準偏差σも数十%と大きくなる。   On the other hand, as shown in FIG. 4B, the data is a signal whose duty ratio changes frequently according to the value. When the histogram regarding the duty ratio of this data is obtained, as shown in FIG. 4B, the frequency of the specific duty ratio does not increase prominently, and the distribution spreads to some extent at various duty ratios. Variations increase. For example, the average value of the histogram is greatly different from the duty ratio of the clock signal, and the standard deviation σ is also as large as several tens of percent.

クロック検出部24は、図4(a)に示す通り、デューティ比の平均値がクロック信号のデューティ比とほぼ一致し、且つ標準偏差が小さな場合(例えば、5%以下)である場合にはクロック信号であると検出する。これに対し、図4(b)に示す通り、デューティ比の平均値がクロック信号のデューティ比と大きく相違し(例えば、10%以上相違)、、且つ標準偏差が大きな場合(例えば、10%以上)である場合にはデータであると検出する。尚、クロック信号を検出するにあたっては、デューティ比のヒストグラムの平均値のみ、又は標準偏差のみを用いても良い。   As shown in FIG. 4A, the clock detection unit 24 determines the clock when the average value of the duty ratio substantially matches the duty ratio of the clock signal and the standard deviation is small (for example, 5% or less). It is detected as a signal. On the other hand, as shown in FIG. 4B, the average value of the duty ratio is significantly different from the duty ratio of the clock signal (for example, 10% or more) and the standard deviation is large (for example, 10% or more). ) Is detected as data. In detecting the clock signal, only the average value of the duty ratio histogram or only the standard deviation may be used.

バス信号検出部25は、入力されている信号がバス信号であるか否かを検出する。具体的には、データ処理部13を制御して波形データメモリ14に記憶されたデータに関する波形データの電圧値(電圧レベル)のヒストグラムを求め、このヒストグラムの分布に基づいてバス信号を検出する。また、バス信号検出部25は、入力されている信号がバス信号である場合には、その極性を検出することもできる。   The bus signal detection unit 25 detects whether or not the input signal is a bus signal. Specifically, the data processing unit 13 is controlled to obtain a histogram of voltage values (voltage levels) of waveform data relating to data stored in the waveform data memory 14, and a bus signal is detected based on the distribution of the histogram. Moreover, the bus signal detection part 25 can also detect the polarity, when the input signal is a bus signal.

図5は、バス信号検出部25で行われる処理を説明するための図である。入力される信号がバス信号であるとすると、その波形は図5に示す通り矩形波状になる。また、バス信号の極性が負極性であるとすると、データが送信されない場合には電圧値V1であるが、データが送信されるときには電圧値がより低い電圧値V2に変化する。このような波形データの電圧値のヒストグラムを求めると、図5に示す通り、電圧値V1,V2で頻度が突出するヒストグラムが得られる。   FIG. 5 is a diagram for explaining processing performed by the bus signal detection unit 25. Assuming that the input signal is a bus signal, the waveform is rectangular as shown in FIG. If the polarity of the bus signal is negative, the voltage value is V1 when data is not transmitted, but the voltage value changes to a lower voltage value V2 when data is transmitted. When a histogram of voltage values of such waveform data is obtained, a histogram in which the frequency protrudes with the voltage values V1 and V2 is obtained as shown in FIG.

バス信号検出部25は、ヒストグラムの分布が電圧値V1,V2の2箇所に集中していればバス信号を検出し、ヒストグラムの分布が電圧値V1,V2の何れに集中しているかによってデータの極性を検出する。図5に示す例においては、ヒストグラムの分布が電圧値V1,V2の2箇所に集中しているとともに、電圧V1の頻度が電圧V2の頻度よりも突出して高いため、バス信号検出部25は負極性のバス信号を検出する。尚、入力される信号の種類によっては、電圧値V1,V2に対するヒストグラムの分布の集中度が同程度になる場合も考えられる。かかる場合には、各々の分布の標準偏差や分散から分布のバラツキ具合を考慮したり、各々の分布の重なり具合を考慮してバス信号及び極性を検出するのが望ましい。   The bus signal detection unit 25 detects a bus signal if the distribution of the histogram is concentrated at two locations of the voltage values V1 and V2, and determines whether the data of the data depends on which of the voltage values V1 and V2 the distribution of the histogram is concentrated. Detect polarity. In the example shown in FIG. 5, the distribution of the histogram is concentrated at two locations of the voltage values V1 and V2, and the frequency of the voltage V1 is much higher than the frequency of the voltage V2. Detecting sex bus signals. Depending on the type of input signal, the concentration of the histogram distribution with respect to the voltage values V1 and V2 may be approximately the same. In such a case, it is desirable to detect the bus signal and the polarity in consideration of the distribution variation from the standard deviation and variance of each distribution, and the overlap of each distribution.

パターン検出部26は、シリアルバスを介して伝送されるデータに含まれる特定のパターンを検出する。ここで、被測定対象のシリアルバスがCAN(Controller Area Network)バスである場合には、シリアルバスを介して伝送されるデータは、データフレーム、リモートフレーム等のフレームを単位としたデータである。図6は、CANバスで用いられるデータフレームの構成を示す図である。図6に示す通り、データフレームは、フレーム先頭から1ビットのSOF(スタート・オブ・フレーム)フィールドF1、12ビットのアービトレーションフィールドF2、6ビットのコントロールフィールドF3、0〜64ビットのデータフィールドF4、16ビットのCRC(Cyclic Redundancy Check:巡回冗長検査)フィールドF5、2ビットのACK(ACKnowledge)フィールドF6、及び7ビットのEOF(エンド・オブ・フレーム)フィールドF7の7つのフィールドから構成される。   The pattern detection unit 26 detects a specific pattern included in data transmitted via the serial bus. Here, when the serial bus to be measured is a CAN (Controller Area Network) bus, the data transmitted through the serial bus is data in units of frames such as a data frame and a remote frame. FIG. 6 is a diagram showing a configuration of a data frame used in the CAN bus. As shown in FIG. 6, the data frame is composed of a 1-bit SOF (start of frame) field F1, a 12-bit arbitration field F2, a 6-bit control field F3, a 0-64-bit data field F4, It consists of seven fields, a 16-bit CRC (Cyclic Redundancy Check) field F5, a 2-bit ACK (ACKnowledge) field F6, and a 7-bit EOF (end of frame) field F7.

上記のSOFフィールドF1は値が「1」にされている。また、アービトレーションフィールドF2の最後の1ビットは値が「1」のRTRビットにされており、更に、コントロールフィールドF3の先頭2ビットは値が「1」のIDEビット及びRB0ビットにそれぞれされている。このため、図6に示すデータフレームは、先頭に値「1」のビットが必ず現れ、その後13ビット目から3ビット連続して値「1」のビットが必ず現れる。パターン検出部26は、このようなデータに含まれる特定のパターンを検出する。   The value of the SOF field F1 is set to “1”. The last 1 bit of the arbitration field F2 is an RTR bit having a value of “1”, and the first 2 bits of the control field F3 are respectively an IDE bit and an RB0 bit having a value of “1”. . For this reason, in the data frame shown in FIG. 6, the bit having the value “1” always appears at the head, and thereafter, the bit having the value “1” always appears three consecutive bits from the 13th bit. The pattern detection unit 26 detects a specific pattern included in such data.

判定部27は、少なくとも上述したビットレート検出部22の検出結果に基づいてシリアルバスの種類を判定する。ここで、判定部27は、ビットレート検出部22の検出結果に加えて、入力信号検出部23、クロック検出部24、及びバス信号検出部25の検出結果の少なくとも1つに基づいてシリアルバスの種類を判定することもできる。更には、上述したパターン検出部26の検出結果も加味してシリアルバスの種類を判定することも可能である。また、判定部27はペア信号(詳細は後述する)の割り出し結果に基づいてシリアルバスの種類を判定する。   The determination unit 27 determines the type of serial bus based on at least the detection result of the bit rate detection unit 22 described above. Here, in addition to the detection result of the bit rate detection unit 22, the determination unit 27 determines the serial bus based on at least one of the detection results of the input signal detection unit 23, the clock detection unit 24, and the bus signal detection unit 25. The type can also be determined. Furthermore, it is also possible to determine the type of serial bus in consideration of the detection result of the pattern detection unit 26 described above. The determination unit 27 determines the type of the serial bus based on the result of determining the pair signal (details will be described later).

メモリ16は、制御部15で行われる各種信号処理で用いられる一時的なデータ(ワークデータ)等を記憶する。このメモリ16としては、RAM(Random Access Memory)等の揮発性のメモリを用いることができる。操作部17は、図1に示す操作キー部3を備えており、ユーザの指示を制御部15に入力するものである。表示処理部18は、制御部15の制御の下で、表示部19に表示させる表示内容の制御を行う。例えば、制御部15から波形データが出力された場合には、その波形データを表示部19に表示させる。また、波形データに加えてデータ値が出力された場合には、波形データに加えてデータ値及びデータ値リストを表示させる。ここで、表示処理部18は、制御部15の判定部27で判定されたシリアルバスの種類に適した形式で波形データ等を表示する処理を行う。表示部19は、図1に示すディスプレイ4を備えており、表示処理部18で処理された波形データ等の各種データを表示する。   The memory 16 stores temporary data (work data) used in various signal processing performed by the control unit 15. As the memory 16, a volatile memory such as a RAM (Random Access Memory) can be used. The operation unit 17 includes the operation key unit 3 shown in FIG. 1 and inputs a user instruction to the control unit 15. The display processing unit 18 controls display contents displayed on the display unit 19 under the control of the control unit 15. For example, when waveform data is output from the control unit 15, the waveform data is displayed on the display unit 19. When a data value is output in addition to the waveform data, a data value and a data value list are displayed in addition to the waveform data. Here, the display processing unit 18 performs processing for displaying waveform data and the like in a format suitable for the type of serial bus determined by the determination unit 27 of the control unit 15. The display unit 19 includes the display 4 shown in FIG. 1 and displays various data such as waveform data processed by the display processing unit 18.

次に、波形測定装置1の動作について説明する。尚、以下の説明では、測定対象であるシリアルバスが、上述したSPIバス、ICバス、及びCANバスに加えてFlexRay(登録商標)バス及びLIN(Local Interconnect Network)バスである場合を例に挙げて説明する。図7は、波形測定装置1で行われるバス自動設定の処理を示すフローチャートである。波形測定にあたり、ユーザは図1に示す波形測定装置1の入力端子2aの少なくとも1つにプローブを接続し、このプローブの先端を測定対象のシリアルバスに接続する。次いで、ユーザが操作キー部3に設けられた初期設定ボタン3cを押圧するとディスプレイ4にメニュー画面が操作され、そのメニュー画面内のバス自動設定ボタン(オートボタン)をタッチすることで、図7に示すバス自動設定処理が開始される。 Next, the operation of the waveform measuring apparatus 1 will be described. In the following description, an example in which the serial bus to be measured is a FlexRay (registered trademark) bus and a LIN (Local Interconnect Network) bus in addition to the SPI bus, I 2 C bus, and CAN bus described above. Will be described. FIG. 7 is a flowchart showing a bus automatic setting process performed by the waveform measuring apparatus 1. In waveform measurement, the user connects a probe to at least one of the input terminals 2a of the waveform measuring apparatus 1 shown in FIG. 1, and connects the tip of the probe to the serial bus to be measured. Next, when the user presses the initial setting button 3c provided on the operation key unit 3, the menu screen is operated on the display 4, and a bus automatic setting button (auto button) in the menu screen is touched, so that FIG. The bus automatic setting process shown is started.

バス自動設定処理が開始されると、制御部15の初期条件設定部21によって、バス自動設定を行うために最低限必要な初期条件が設定される(ステップS11)。具体的には、入力チャネルの全てがオン状態(入力可能状態)に設定され、例えばディスプレイ4の横軸(時間軸)のスケールが5msec/divに設定され、レコード長が625万点(6.25M)点に設定される。尚、トリガ条件及びアクイジションモードについても適当な設定が自動的になされる。   When the bus automatic setting process is started, the initial condition setting unit 21 of the control unit 15 sets initial conditions necessary for automatic bus setting (step S11). Specifically, all the input channels are set to an on state (input enabled state), for example, the horizontal axis (time axis) scale of the display 4 is set to 5 msec / div, and the record length is 6.25 million points (6. 25M) point. Appropriate settings are automatically made for the trigger condition and the acquisition mode.

初期条件の設定が終了すると、入力端子TM1から入力された信号がプリアンプ11で増幅された後、A/D変換器12においてステップS11で設定された初期条件に応じたサンプリングレートでサンプリングされて波形データに変換されて波形データメモリ14に記憶される。尚、複数の入力チャネルが存在する場合には、各々の入力チャネルで波形データへの変換が行われる。   When the setting of the initial conditions is completed, the signal input from the input terminal TM1 is amplified by the preamplifier 11 and then sampled at the sampling rate corresponding to the initial condition set in step S11 by the A / D converter 12 to be a waveform. It is converted into data and stored in the waveform data memory 14. When there are a plurality of input channels, conversion into waveform data is performed in each input channel.

次に、制御部15の入力信号検出部23で入力チャネルの検出が行われる(ステップS12)。具体的には、まず入力信号検出部23の制御の下でデータ処理部13において各入力チャネル毎の信号の電圧値の最大ピーク値と最小ピーク値とが求められる。次に、入力チャネル毎の電圧値の最大ピーク値と最小ピーク値との差が入力信号検出部23で算出され、この差が予め設定された所定の電圧値以上である入力チャネルの数が検出される。尚、電圧値の最大ピーク値と最小ピーク値との差が閾値よりも小さな入力チャネルは、入力信号検出部23によりオフ状態(入力不可能状態)に設定される。また、制御部15は、ここで求められた電圧値の最大ピーク値と最小ピーク値を用いてディスプレイ4の縦軸(信号レベルの軸)のスケールを設定する。   Next, the input signal detection unit 23 of the control unit 15 detects the input channel (step S12). Specifically, first, under the control of the input signal detector 23, the data processor 13 determines the maximum peak value and the minimum peak value of the voltage value of the signal for each input channel. Next, the difference between the maximum peak value and the minimum peak value of the voltage value for each input channel is calculated by the input signal detection unit 23, and the number of input channels whose difference is equal to or greater than a predetermined voltage value is detected. Is done. An input channel in which the difference between the maximum peak value and the minimum peak value of the voltage value is smaller than the threshold value is set to an off state (input disabled state) by the input signal detection unit 23. Further, the control unit 15 sets the scale of the vertical axis (signal level axis) of the display 4 using the maximum peak value and the minimum peak value of the voltage value obtained here.

次いで、制御部15のバス信号検出部25でバス信号の検出が行われる(ステップS13)。具体的には、バス信号検出部25によるデータ処理部13の制御の下で、波形データメモリ14に記憶されたデータに関する波形データの電圧値(電圧レベル)のヒストグラム(図5参照)を求め、このヒストグラムの分布に基づいてバス信号及びその極性が検出される。次に、制御部15のクロック検出部24でクロック信号の検出が行われる(ステップS14)。具体的には、データ処理部13を制御して波形データメモリ14に記憶された入力チャネル毎の波形データのデューティ比に関するヒストグラム(図4参照)を求め、このヒストグラムの平均値及び標準偏差の少なくとも一方を用いてクロック信号の有無を検出する。   Next, the bus signal detection unit 25 of the control unit 15 detects the bus signal (step S13). Specifically, under the control of the data processing unit 13 by the bus signal detection unit 25, a histogram (see FIG. 5) of voltage values (voltage levels) of waveform data related to data stored in the waveform data memory 14 is obtained. Based on this histogram distribution, the bus signal and its polarity are detected. Next, the clock detection unit 24 of the control unit 15 detects the clock signal (step S14). Specifically, the data processing unit 13 is controlled to obtain a histogram (see FIG. 4) regarding the duty ratio of the waveform data for each input channel stored in the waveform data memory 14, and at least the average value and standard deviation of this histogram are obtained. One is used to detect the presence or absence of a clock signal.

次に、制御部15のビットレート検出部22でシリアルバスを介して伝送されるデータのビットレートが求められる(ステップS15)。具体的には、まずビットレート検出部22の制御の下で、データ処理部13において波形データメモリ14に記憶された波形データの立ち上がりエッジ及び立ち下がりエッジのエッジ位置が検出される。次いで、データ処理部13で検出された立ち上がりエッジのエッジ位置と立ち下がりエッジのエッジ位置との時間間隔がビットレート検出部22で求められる。そして、この時間間隔の中の最短時間間隔の逆数が求められることによりビットレートが検出される。   Next, the bit rate of the data transmitted via the serial bus is obtained by the bit rate detection unit 22 of the control unit 15 (step S15). Specifically, first, under the control of the bit rate detection unit 22, the edge position of the rising edge and the falling edge of the waveform data stored in the waveform data memory 14 is detected by the data processing unit 13. Next, the time interval between the edge position of the rising edge and the edge position of the falling edge detected by the data processing unit 13 is obtained by the bit rate detection unit 22. Then, the bit rate is detected by obtaining the reciprocal of the shortest time interval in this time interval.

以上の処理が終了すると、制御部15の判定部27でシリアルバスの種類を判定する処理が行われる(ステップS16)。図8はシリアルバスの種類を判定する判定処理を示すフローチャートであり、図9はシリアルバスの種類の判定基準を示す図表である。判定処理が開始されると、まずクロック検出部24でクロック信号が検出されたか否かが判定部27で判断される(ステップS21)。ここで、図9を参照すると、クロック信号の有無により、ICバス、SPIバスからなる第1候補と、LINバス、CANバス、FlexRayバスからなる第2候補に区分することができる。 When the above processing is completed, the determination unit 27 of the control unit 15 determines the type of serial bus (step S16). FIG. 8 is a flowchart showing determination processing for determining the type of serial bus, and FIG. 9 is a chart showing determination criteria for the type of serial bus. When the determination process is started, the determination unit 27 first determines whether or not the clock signal is detected by the clock detection unit 24 (step S21). Here, referring to FIG. 9, it can be divided into a first candidate consisting of an I 2 C bus and an SPI bus and a second candidate consisting of a LIN bus, a CAN bus and a FlexRay bus depending on the presence or absence of a clock signal.

ステップS21でクロック信号が検出されていないと判断した場合(判断結果が「NO」の場合)には、判定部27はビットレート検出部22の検出結果に基づいてシリアルバスの種類を判定する(ステップS22)。ここで、LINバス、CANバス、FlexRayバスからなる第2候補のビットレートは、図9に示す通り、上下限値が重ならないように規格で定まっている。このため、判定部27は、ビットレート検出部22で検出されたビットレートを用いればLINバス、CANバス、及びFlexRayバスの何れかを判定することができる。   When it is determined in step S21 that the clock signal is not detected (when the determination result is “NO”), the determination unit 27 determines the type of serial bus based on the detection result of the bit rate detection unit 22 ( Step S22). Here, as shown in FIG. 9, the bit rate of the second candidate consisting of the LIN bus, the CAN bus, and the FlexRay bus is determined by the standard so that the upper and lower limit values do not overlap. Therefore, the determination unit 27 can determine any one of the LIN bus, the CAN bus, and the FlexRay bus using the bit rate detected by the bit rate detection unit 22.

また、図9を参照すると、第2候補のうちのLINバス及びFlexRayバスについては極性が正極である。このため、判定部27は、ビットレート検出部22の検出結果のみに基づいて判定されたLINバス又はFlexRayバスの正否を、バス信号検出部25の極性検出結果に基づいて確認することができる。尚、ビットレートに基づいた判定結果と極性検出結果を用いた判定結果とが相違する場合には、判定部27はシリアルバスの判定結果を「不定」とする。   Referring to FIG. 9, the polarity of the LIN bus and the FlexRay bus among the second candidates is positive. Therefore, the determination unit 27 can confirm whether the LIN bus or the FlexRay bus is determined based only on the detection result of the bit rate detection unit 22 based on the polarity detection result of the bus signal detection unit 25. When the determination result based on the bit rate is different from the determination result using the polarity detection result, the determination unit 27 sets the determination result of the serial bus to “undefined”.

一方、ステップS21でクロック信号が検出されたと判断した場合(判断結果が「YES」の場合)には、判定部27はペア信号の割り出しを行う(ステップS23)。ここで、ペア信号とはクロック信号に対応したデータやCS信号等をいう。図9を参照すると、第1候補をなすICバス、SPIバスの双方はクロック信号を有している。このため、これらのバスにおいてはクロック信号とともにデータやCS信号が同期歩調方式で伝送されることになりペア信号が存在する。 On the other hand, when it is determined in step S21 that the clock signal has been detected (when the determination result is “YES”), the determination unit 27 calculates a pair signal (step S23). Here, the pair signal means data corresponding to the clock signal, CS signal, or the like. Referring to FIG. 9, both the I 2 C bus and the SPI bus that are the first candidates have clock signals. For this reason, in these buses, data and CS signals are transmitted together with a clock signal in a synchronous pacing system, and a pair signal exists.

判定部27による具体的なペア信号の割り出し方法は、ビットレート検出部22で検出された各入力チャネルのビットレートが互いに関連しているか、又はメッセージ間のアイドル区間の位置が同期しているか等を考慮する。ビットレートが互いに関連しているかは、例えばICバスについては、クロック信号のビットレートが100kbpsであってデータのビットレートがクロック信号のビットレートの半分である50kbpsであるかにより判断される。また、アイドル区間の位置が同期しているかは、例えば立ち上がりエッジ及び立ち下がりエッジのエッジ位置がほぼ一致しているかにより判断される。 The determination method of the pair signal by the determination unit 27 is, for example, whether the bit rates of the input channels detected by the bit rate detection unit 22 are related to each other, or whether the position of the idle interval between messages is synchronized, etc. Consider. Whether the bit rates are related to each other is determined, for example, for the I 2 C bus by whether the clock signal bit rate is 100 kbps and the data bit rate is 50 kbps, which is half the clock signal bit rate. . Whether the positions of the idle sections are synchronized is determined, for example, based on whether the edge positions of the rising edge and the falling edge are substantially the same.

ペア信号の割り出しを終えると、判定部27はステップS23で割り出したペア信号を用いてシリアルバスの種類が、第1候補をなすICバス、SPIバスの何れであるかを判定する(ステップS24)。尚、判定部27は、まずICバスであるか否かを判定し、次いでSPIバスであるか否かを判定する。以下、ICバス及びSPIバスの判定方法について順に説明する。 When the determination of the pair signal is completed, the determination unit 27 determines whether the type of the serial bus is the I 2 C bus or the SPI bus forming the first candidate using the pair signal determined in step S23 (step S23). S24). The determination unit 27 first determines whether the bus is an I 2 C bus, and then determines whether the bus is an SPI bus. Hereinafter, the determination method of the I 2 C bus and the SPI bus will be described in order.

〈ICバスの判定方法〉
図10は、ICバスにおけるシリアルデータ(SDA)及びシリアルクロック(SCL)のタイミングチャートである。図10に示す通り、ICバスでは、シリアルデータ(SDA)のスタートバイト及びデータバイトがそれぞれシリアルクロック(SCL)の9ビット分に割り当てられている。このため、1メッセージ内に存在するシリアルクロック(SCL)の立ち上がりエッジ数は、メッセージ最後尾のストップコンディションの1ビットを加えると、9n+1(nは1以上の整数)になる。
<I 2 C bus determination method>
FIG. 10 is a timing chart of serial data (SDA) and serial clock (SCL) in the I 2 C bus. As shown in FIG. 10, on the I 2 C bus, the start byte and the data byte of serial data (SDA) are allocated to 9 bits of the serial clock (SCL), respectively. Therefore, the number of rising edges of the serial clock (SCL) existing in one message is 9n + 1 (n is an integer of 1 or more) when 1 bit of the stop condition at the end of the message is added.

図11は、ICバスのメッセージ送信時における開始条件(スタート)及び終了条件(エンド)を示すタイミングチャートである。図9に示す通り、メッセージの開始条件は、シリアルデータ(SDA)が「L(ロー)」レベルに遷移した後にシリアルクロック(SCL)が「L」レベルに遷移することで満たされる。これに対し、メッセージの終了条件は、シリアルクロック(SCL)が「H(ハイ)」レベルに遷移した後にシリアルデータ(SDA)が「H」レベルに遷移することで満たされる。よって、判定部27は、メッセージ内の立ち上がりエッジ数が9n+1であり、且つメッセージの送信時における開始条件及び終了条件が満たされているか否かによって、シリアルバスの種類がICバスであるか否かを判定する。 FIG. 11 is a timing chart showing a start condition (start) and an end condition (end) when an I 2 C bus message is transmitted. As shown in FIG. 9, the message start condition is satisfied when the serial clock (SCL) transitions to the “L” level after the serial data (SDA) transitions to the “L (low)” level. In contrast, the message end condition is satisfied when the serial data (SDA) transitions to the “H” level after the serial clock (SCL) transitions to the “H (high)” level. Therefore, the determination unit 27 determines whether the serial bus type is the I 2 C bus depending on whether the number of rising edges in the message is 9n + 1 and whether the start condition and the end condition at the time of message transmission are satisfied. Determine whether or not.

〈SPIバスの判定方法〉
図12は、SPIバスにおけるクロック(CLK)、データ(Data1,Data2)、及びチップセレクト信号(CS)のタイミングチャートである。SPIバスにおいては、マスタとなるデバイスとスレーブとなる少なくとも1つのデバイスとが接続されており、スレーブとなるデバイスを選択するチップセレクト信号(CS)マスタとなるデバイスによって生成される。図12に示す通り、SPIバスにおいては、チップセレクト信号(CS)のレベル変化の時間がクロック(CLK)の1バイト分の時間幅の整数倍である。このため、判定部27は、チップセレクト信号(CS)のレベル変化の時間に基づいてチップセレクト信号(CS)の有無を判断することにより、SPIバスであるか否かを判定する。
<SPI bus judgment method>
FIG. 12 is a timing chart of the clock (CLK), data (Data1, Data2), and chip select signal (CS) in the SPI bus. In the SPI bus, a master device and at least one device as a slave are connected to each other, and are generated by a device as a chip select signal (CS) master for selecting a slave device. As shown in FIG. 12, in the SPI bus, the level change time of the chip select signal (CS) is an integral multiple of the time width of one byte of the clock (CLK). For this reason, the determination unit 27 determines whether or not it is the SPI bus by determining the presence or absence of the chip select signal (CS) based on the level change time of the chip select signal (CS).

尚、ICバスでは、マスタとなるデバイスがアドレスを指定してスレーブとなるデバイスを呼び出すためにチップセレクト信号は存在しない。よって、チップセレクト信号(CS)の有無からシリアルバスがSPIバスであるのか又はICバスであるのかを判定することができる。尚、上述したICバスの判定条件及びSPIバスの判定条件の何れも満たされない場合には、判定部27はシリアルバスの判定結果を「不定」とする。 In the I 2 C bus, there is no chip select signal for the master device to specify the address and call the slave device. Therefore, it can be determined whether the serial bus is the SPI bus or the I 2 C bus from the presence or absence of the chip select signal (CS). When neither the above-described I 2 C bus determination condition nor the SPI bus determination condition is satisfied, the determination unit 27 sets the determination result of the serial bus to “undefined”.

以上の処理が終了すると、判定部27は、他の入力チャネルの有無を判断する(ステップS25)。他の入力チャネルがあると判断した場合(判断結果が「YES」の場合)には、ステップS21の処理に戻り、他の入力チャネルが無いと判断した場合(判断結果が「NO」の場合)には、シリアルバスの種類を判定する判定処理が終了する。以上の処理が終了すると、判定処理で判定されたシリアルバスの種類に適した時間軸の設定が制御部15で行われる(ステップS17)。この時間軸の設定は、データの少なくとも1メッセージがディスプレイ4に表示されるように行うのが望ましい。具体的には、制御部15は、各シリアルバスの規格における1メッセージ中の最大ビット数と最小ビット数とから時間軸のスケールを設定する。   When the above processing ends, the determination unit 27 determines whether there is another input channel (step S25). When it is determined that there is another input channel (when the determination result is “YES”), the process returns to step S21, and when it is determined that there is no other input channel (when the determination result is “NO”). Then, the determination process for determining the type of serial bus is completed. When the above process is completed, the control unit 15 sets a time axis suitable for the type of serial bus determined in the determination process (step S17). The time axis is preferably set so that at least one message of data is displayed on the display 4. Specifically, the control unit 15 sets the time axis scale from the maximum number of bits and the minimum number of bits in one message in each serial bus standard.

例えば、CANバスでは、最大ビットレートは1Mbps(ビットタイムに換算すると1μsec)であり、1メッセージ中の最大ビット数は126ビットであることから、1メッセージを計測するために必要な時間は126μsecになる。よって、制御部15は、少なくとも時間126μsec分の波形がディスプレイ4に表示されるよう時間軸のスケールを設定する。尚、複数種類のシリアルバスが判定された場合には、1メッセージの時間が最も長いものの波形がディスプレイ4に表示されるように時間軸のスケールを設定する。以上説明した一連の処理によってバス自動設定処理が終了し、ユーザがシリアルバスの種類に応じた煩雑な初期設定を行わずとも、シリアルバスの種類が自動的に解析されて、シリアルバスの種類に適した表示が行われる。   For example, in the CAN bus, the maximum bit rate is 1 Mbps (1 μsec in terms of bit time), and the maximum number of bits in one message is 126 bits, so the time required to measure one message is 126 μsec. Become. Therefore, the control unit 15 sets the scale of the time axis so that the waveform for at least 126 μsec is displayed on the display 4. When a plurality of types of serial buses are determined, the time axis scale is set so that the waveform having the longest time of one message is displayed on the display 4. The automatic bus setting process is completed by the series of processes described above, and the serial bus type is automatically analyzed and converted into the serial bus type without the user performing complicated initial settings according to the serial bus type. Appropriate display is provided.

以上の通り、本実施形態の波形測定装置1は、シリアルバスを介して伝送されるデータ等のビットレートを検出し、少なくともビットレートの検出結果に基づいてシリアルバスの種類を判定しており、ユーザが煩雑な操作を行わなくともシリアルバスを解析する際に必要な初期設定が自動的に行われてシリアルバスの種類に適した表示が行われるため、ユーザの利便性を高めることができる。また、シリアルバスの解析を行う際に必要であったユーザによる煩雑な操作を省くことができるため、シリアルバスの解析に要する時間を短縮することができる。   As described above, the waveform measuring apparatus 1 according to the present embodiment detects the bit rate of data transmitted via the serial bus, and determines the type of the serial bus based on at least the detection result of the bit rate. Even if the user does not perform complicated operations, initial settings necessary for analyzing the serial bus are automatically performed and a display suitable for the type of the serial bus is performed, so that the convenience for the user can be improved. In addition, since it is possible to omit a complicated operation required by the user when analyzing the serial bus, the time required for the analysis of the serial bus can be shortened.

以上、本発明の一実施形態による波形測定装置について説明したが、本発明は上記実施形態に制限されることなく、本発明の範囲内で自由に変更が可能である。例えば、上記実施形態では、測定対象のシリアルバスが、SPIバス、ICバス、CANバス、FlexRayバス、及びLINバスである場合を例に挙げて説明したが、これら以外にもMOST(Media Oriented. Systems Transport)バス、USB(Universal Serial Bus)、IEEE1394バス、PCIExpress(登録商標)バス等の各種シリアルバスを測定する場合にも本発明の波形測定装置を用いることができる。 The waveform measuring apparatus according to the embodiment of the present invention has been described above. However, the present invention is not limited to the above embodiment, and can be freely changed within the scope of the present invention. For example, in the above embodiment, the case where the serial bus to be measured is an SPI bus, an I 2 C bus, a CAN bus, a FlexRay bus, and a LIN bus has been described as an example. The waveform measuring apparatus of the present invention can also be used when measuring various serial buses such as an Oriented. Systems Transport (USB) bus, a USB (Universal Serial Bus), an IEEE 1394 bus, and a PCI Express (registered trademark) bus.

また、上述した実施形態では、第2候補をなすLINバス、CANバス、及びFlexRayバスを判別する処理(図8中のステップS22)では、ビットレートの上下限値が重ならないことを利用した。ビットレートの上下限値が重なることがある場合には、パターン検出部26の検出結果を用いて(加味して)判別を行っても良い。例えば、図6に示す通り、データフレームの先頭に値「1」のビットが現れ、その後13ビット目から3ビット連続して値「1」のビットが現れる場合には、CANバスと判定することができる。   In the above-described embodiment, it is used that the upper and lower limit values of the bit rate do not overlap in the process of determining the LIN bus, CAN bus, and FlexRay bus that are the second candidates (step S22 in FIG. 8). If the upper and lower limit values of the bit rate may overlap, the determination may be performed using (in consideration of) the detection result of the pattern detection unit 26. For example, as shown in FIG. 6, if a bit with a value “1” appears at the beginning of a data frame and then a bit with a value “1” appears three consecutive bits from the 13th bit, it is determined as a CAN bus. Can do.

また、上記実施形態において、制御部15に設けられた初期条件設定部21、ビットレート検出部22、入力信号検出部23、クロック検出部24、バス信号検出部25、パターン検出部26、及び判定部27はハードウェアで実現してもよく、ソフトウェアにより実現しても良い。ソフトウェアにより実現する場合には、制御部15をCPU(中央処理装置)で構成し、上記の各部の機能を実現するプログラムをCPUに実行させることによって実現される。   In the above embodiment, the initial condition setting unit 21, the bit rate detection unit 22, the input signal detection unit 23, the clock detection unit 24, the bus signal detection unit 25, the pattern detection unit 26, and the determination provided in the control unit 15. The unit 27 may be realized by hardware or software. When realized by software, the control unit 15 is configured by a CPU (Central Processing Unit), and the CPU is executed by executing a program that realizes the functions of the above-described units.

本発明の一実施形態による波形測定装置の正面図である。It is a front view of the waveform measuring apparatus by one Embodiment of this invention. 本発明の一実施形態による波形測定装置の要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the waveform measuring apparatus by one Embodiment of this invention. ビットレート検出部22で行われる処理を説明するための図である。4 is a diagram for explaining processing performed in a bit rate detection unit 22. FIG. クロック検出部24で行われる処理を説明するための図である。FIG. 6 is a diagram for explaining processing performed in a clock detection unit 24. バス信号検出部25で行われる処理を説明するための図である。6 is a diagram for explaining processing performed in a bus signal detection unit 25. FIG. CANバスで用いられるデータフレームの構成を示す図である。It is a figure which shows the structure of the data frame used by a CAN bus. 波形測定装置1で行われるバス自動設定の処理を示すフローチャートである。3 is a flowchart showing a bus automatic setting process performed by the waveform measuring apparatus 1; シリアルバスの種類を判定する判定処理を示すフローチャートである。It is a flowchart which shows the determination process which determines the kind of serial bus. シリアルバスの種類の判定基準を示す図表である。It is a chart which shows the judgment standard of the kind of serial bus. Cバスにおけるシリアルデータ及びシリアルクロックのタイミングチャートである。It is a timing chart of the serial data and serial clock in an I 2 C bus. Cバスのメッセージ送信時における開始条件(スタート)及び終了条件(エンド)を示すタイミングチャートである。It is a timing chart which shows the start condition (start) and end condition (end) at the time of message transmission of an I 2 C bus. SPIバスにおけるクロック、データ、及びチップセレクト信号のタイミングチャートである。5 is a timing chart of clock, data, and chip select signals in the SPI bus.

符号の説明Explanation of symbols

1 波形測定装置
22 ビットレート検出部
23 入力信号検出部
24 クロック検出部
25 バス信号検出部
26 パターン検出部
27 判定部
DESCRIPTION OF SYMBOLS 1 Waveform measuring apparatus 22 Bit rate detection part 23 Input signal detection part 24 Clock detection part 25 Bus signal detection part 26 Pattern detection part 27 Determination part

Claims (5)

シリアルバスを介して伝送されるデータの波形を測定する波形測定装置において、
前記データのビットレートを検出するビットレート検出手段と、
前記データに関する信号数を検出する入力信号検出手段、前記データに関するクロック信号を検出するクロック検出手段、及び前記データの極性を検出する極性検出手段の少なくとも1つと、
前記ビットレート検出手段の検出結果に加えて、前記入力信号検出手段、前記クロック検出手段、及び前記極性検出手段の検出結果の少なくとも1つに基づいて、前記シリアルバスの種類を判定する判定手段と
を備えることを特徴とする波形測定装置。
In a waveform measuring device that measures the waveform of data transmitted via a serial bus,
Bit rate detection means for detecting the bit rate of the data;
At least one of input signal detection means for detecting the number of signals related to the data, clock detection means for detecting a clock signal related to the data, and polarity detection means for detecting the polarity of the data;
Determination means for determining the type of the serial bus based on at least one of the detection results of the input signal detection means, the clock detection means, and the polarity detection means in addition to the detection result of the bit rate detection means; A waveform measuring apparatus comprising:
前記データに含まれる特定パターンを検出するパターン検出手段を備えており、Comprising a pattern detecting means for detecting a specific pattern included in the data;
前記判定手段は、前記パターン検出手段の検出結果も加味して前記シリアルバスの種類を判定することを特徴とする請求項1記載の波形測定装置。  The waveform measuring apparatus according to claim 1, wherein the determination unit determines the type of the serial bus in consideration of a detection result of the pattern detection unit.
前記ビットレート検出手段は、前記データの立ち上がりエッジと立ち下がりエッジとのエッジ位置をそれぞれ求め、当該エッジ位置の最短時間間隔から前記ビットレートを検出することを特徴とする請求項1又は請求項2記載の波形測定装置。3. The bit rate detection means obtains edge positions of a rising edge and a falling edge of the data, respectively, and detects the bit rate from the shortest time interval between the edge positions. The waveform measuring apparatus described. 前記クロック検出手段は、前記データのデューティ比に関するヒストグラムを求め、当該ヒストグラムの平均値及び標準偏差の少なくとも一方を用いて前記クロック信号の有無を検出することを特徴とする請求項1又は請求項2記載の波形測定装置。3. The clock detection means obtains a histogram relating to the duty ratio of the data and detects the presence or absence of the clock signal using at least one of an average value and a standard deviation of the histogram. The waveform measuring apparatus described. 前記極性検出手段は、前記データの電圧レベルに関するヒストグラムを求め、当該ヒストグラムの分布に基づいて前記データの極性を検出することを特徴とする請求項1又は請求項2記載の波形測定装置。The waveform measuring apparatus according to claim 1, wherein the polarity detection unit obtains a histogram relating to a voltage level of the data, and detects the polarity of the data based on a distribution of the histogram.
JP2007254330A 2007-09-28 2007-09-28 Waveform measuring device Active JP5125363B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007254330A JP5125363B2 (en) 2007-09-28 2007-09-28 Waveform measuring device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007254330A JP5125363B2 (en) 2007-09-28 2007-09-28 Waveform measuring device

Publications (2)

Publication Number Publication Date
JP2009085710A JP2009085710A (en) 2009-04-23
JP5125363B2 true JP5125363B2 (en) 2013-01-23

Family

ID=40659331

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007254330A Active JP5125363B2 (en) 2007-09-28 2007-09-28 Waveform measuring device

Country Status (1)

Country Link
JP (1) JP5125363B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016038685A1 (en) * 2014-09-09 2016-03-17 富士機械製造株式会社 Multiplex communication apparatus
JP6779113B2 (en) * 2016-11-29 2020-11-04 横河電機株式会社 Waveform measuring device

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11161520A (en) * 1997-11-27 1999-06-18 Yokogawa Electric Corp Bus analyzer
JP4573300B2 (en) * 2005-04-25 2010-11-04 本田技研工業株式会社 Diagnostic device and communication device

Also Published As

Publication number Publication date
JP2009085710A (en) 2009-04-23

Similar Documents

Publication Publication Date Title
US8930155B2 (en) Pulse processing device and radiation measuring device
CN109298657B (en) Time-varying signal power detection and automatic gain control method based on FPGA
EP4060352A1 (en) Automatic trigger type identification method and device, and oscilloscope
JP2001352350A (en) Measurement system and method by statistic eye-diagram of continuous bit stream
WO2019134683A1 (en) Oscilloscope signal decoding method and apparatus, and oscilloscope
US10999095B2 (en) Communication method
JP5125363B2 (en) Waveform measuring device
JP5238369B2 (en) Data receiving apparatus, data receiving method, and data receiving program
KR101526168B1 (en) Effective method for removing noise in capacitive touch sensor and the touch screen device thereof
US20140285177A1 (en) Mobile current measurement equipment, current measurement terminal and current measurement method
CN103220370A (en) Method and device for achieving single wire protocol (SWP) interface and SWP system
EP3280059A1 (en) Touch screen terminal and near field communication method, apparatus and system thereof
JP5131526B2 (en) Waveform measuring device
CN104835500A (en) Method and device for acquiring audio information
JP5115121B2 (en) Waveform measuring device
TWI355148B (en) Method of analyzing a signal strength, method of e
CN114371392A (en) Touch data detection device, touch chip and electronic equipment
EP2876894A1 (en) Acoustic signal processing device, program and processing method for acoustic signals
WO2024142560A1 (en) Waveform measurement device and program
JP2008215897A (en) Average current measurement circuit
JP6779113B2 (en) Waveform measuring device
KR101531841B1 (en) Effective method and module for measuring noise level in capacitive touch sensor
CN114019268B (en) Burn-in test method, device, equipment and storage medium
JP4924882B2 (en) Waveform measuring device
JP2024092729A (en) Waveform measuring instrument and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100607

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20120810

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120821

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120911

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20121002

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20121015

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 5125363

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20151109

Year of fee payment: 3

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250