JP2019149609A - Imaging apparatus and signal processing method in the same - Google Patents

Imaging apparatus and signal processing method in the same Download PDF

Info

Publication number
JP2019149609A
JP2019149609A JP2018031688A JP2018031688A JP2019149609A JP 2019149609 A JP2019149609 A JP 2019149609A JP 2018031688 A JP2018031688 A JP 2018031688A JP 2018031688 A JP2018031688 A JP 2018031688A JP 2019149609 A JP2019149609 A JP 2019149609A
Authority
JP
Japan
Prior art keywords
synchronization
synchronization code
signal
code
detection
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.)
Pending
Application number
JP2018031688A
Other languages
Japanese (ja)
Inventor
直隆 村上
Naotaka Murakami
直隆 村上
祥吾 鉢呂
Shogo Hachiro
祥吾 鉢呂
良典 林
Yoshinori Hayashi
良典 林
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2018031688A priority Critical patent/JP2019149609A/en
Publication of JP2019149609A publication Critical patent/JP2019149609A/en
Pending legal-status Critical Current

Links

Landscapes

  • Synchronizing For Television (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

To reliably detect a synchronization code even when transfer data is scrambled.SOLUTION: The imaging apparatus includes: an oscillator that generates a reference clock; synchronization signal generating means for generating a horizontal synchronization signal and a vertical synchronization signal in synchronization with a reference clock; image signal readout means for reading out an image signal in synchronization with the horizontal synchronization signal and the vertical synchronization signal; synchronization code adding means for adding a synchronization code to the image signal in synchronization with the horizontal synchronization signal; synchronization code detecting means for detecting the synchronization code; an effective period generation circuit that determines a first effective period that is started in synchronization with the vertical synchronization signal and ends by detecting the synchronization code as a period for validating a detection result of the synchronization code detecting means and a second effective period that is started after a predetermined time has elapsed since the detection of the synchronization code detected within the first effective period and ends when the synchronization code is detected.SELECTED DRAWING: Figure 1

Description

本発明は、撮像素子(イメージセンサ)から出力される画像信号に含まれる水平同期信号を検出する技術に関するものである。   The present invention relates to a technique for detecting a horizontal synchronization signal included in an image signal output from an image sensor (image sensor).

近年のイメージセンサの高画質化、高フレームレート化に伴って、イメージセンサからの画素データの高速な読み出しが求められている。
このような高速の画素データの読み出しに対応できるセンサとして、アナログデータをA/D変換したデジタルデータをパラレルシリアル変換によりシリアル化して高速に転送する方法が知られている。
With the recent increase in image quality and frame rate of image sensors, high-speed readout of pixel data from image sensors is required.
As a sensor capable of handling such high-speed pixel data reading, a method of serially converting digital data obtained by A / D converting analog data by parallel-serial conversion and transferring the data at high speed is known.

このような画素データの転送において、画素データの水平、垂直同期のタイミングを取るためにシリアルデータ中に同期コードと呼ばれる複数の符号列を埋め込んで転送することが行われている。画素データを処理するためにはこの同期コードを正しく検出することが重要である。   In such pixel data transfer, in order to obtain horizontal and vertical synchronization timing of pixel data, a plurality of code strings called synchronization codes are embedded and transferred in serial data. In order to process pixel data, it is important to correctly detect this synchronization code.

特許文献1では、この同期コードの誤検出を防ぐ方法について述べられている。データ転送では途中の伝送経路においてデータの誤りが発生する可能性がある。特許文献1では、データの誤りが発生した結果、転送しているデータ中に同期コードの符号列が意図せず存在してしまい、同期コードを誤検出してデータの処理を正しく行えないことが課題に挙げられている。   Patent Document 1 describes a method for preventing erroneous detection of this synchronization code. In data transfer, there is a possibility that a data error occurs in the transmission path on the way. In Patent Document 1, as a result of an error in data, the code string of the synchronization code is unintentionally present in the transferred data, and the synchronization code is erroneously detected and the data cannot be processed correctly. It is listed as an issue.

これを避けるために、受信したデータから抽出したクロック成分のレベルが大きいときのみ検出した同期コードを目的の同期コードであると判断し、それ以外は同期コードと判断しないということが記載されている。   In order to avoid this, it is described that the synchronization code detected only when the level of the clock component extracted from the received data is high is determined as the target synchronization code, and other than that is not determined as the synchronization code. .

特開2000−307540号公報JP 2000-307540 A

近年の高速な画素データの転送においては、転送データにクロック信号を埋め込み、受信した転送データからクロック信号を抽出するクロックデータリカバリ方式と呼ばれる転送方法がしばしば用いられる。   In recent high-speed pixel data transfer, a transfer method called a clock data recovery method in which a clock signal is embedded in transfer data and a clock signal is extracted from the received transfer data is often used.

クロックデータリカバリ方式においてAC結合によりデータを転送する場合はクロックを正常に抽出するために転送データ中の0と1の数がなるべく均一になるようなエンコードを施す。   When data is transferred by AC coupling in the clock data recovery method, encoding is performed so that the numbers of 0 and 1 in the transfer data are as uniform as possible in order to extract the clock normally.

エンコードの1つの手段としてデータにスクランブルをかける方式があるが、転送データにスクランブルをかけた結果、転送データ中に同期コードの符号列が意図せず存在してしまい、同期コードを誤検出してデータの処理を正しく行えない可能性がある。   There is a method of scrambling data as one means of encoding. As a result of scrambling the transfer data, the code string of the synchronization code is unintentionally present in the transfer data, and the synchronization code is erroneously detected. Data may not be processed correctly.

特許文献1では受信データ中の正しい同期コードの位置ではクロック成分が大きく、エラー等で意図せず存在した同期コードの位置ではクロック成分が小さいことを前提としているが、データのエンコードにスクランブル方式を採用した場合は意図せず存在した同期コードの位置でもスクランブルの結果データのクロック成分が大きくなり誤検出をしてしまう可能性がある。   In Patent Document 1, it is assumed that the clock component is large at the position of the correct synchronization code in the received data, and that the clock component is small at the position of the synchronization code that was unintentionally present due to an error or the like, but a scramble method is used for data encoding. If it is adopted, there is a possibility that the clock component of the data resulting from the scrambling becomes large and erroneous detection occurs even at the position of the synchronization code that was not intended.

本発明は上述した課題に鑑みてなされたものであり、転送データにスクランブルが施された場合でも確実に同期コードを検出することを目的とする。   The present invention has been made in view of the above-described problems, and an object thereof is to reliably detect a synchronization code even when transfer data is scrambled.

上記目的を達成するために、本発明の撮像装置は、
基準クロックを発生する発振器と、
前記基準クロックに同期して水平同期信号及び垂直同期信号を発生する同期信号発生手段と、
前記水平同期信号及び前記垂直同期信号に同期して画像信号を読み出す画像信号読み出し手段と、
前記水平同期信号に同期して前記画像信号に同期コードを付加する同期コード付加手段と、
前記同期コードと前記画像信号を送信する送信手段と、
前記同期コードと前記画像信号を受信する受信手段と、
前記同期コードを検出する同期コード検出手段と、
前記同期コード検出手段の検出結果を有効にする期間として
前記垂直同期信号と同期して開始され同期コードの検出によって終了する第1の有効期間と、
前記第1の有効期間内に検出された同期コードの検出から所定の時間が経過した後に開始され同期コードの検出によって終了する第2の有効期間と、
を定める有効期間生成回路
を備えることを特徴とする。
In order to achieve the above object, the imaging apparatus of the present invention provides:
An oscillator that generates a reference clock; and
Synchronization signal generating means for generating a horizontal synchronization signal and a vertical synchronization signal in synchronization with the reference clock;
Image signal readout means for reading out an image signal in synchronization with the horizontal synchronization signal and the vertical synchronization signal;
Synchronization code adding means for adding a synchronization code to the image signal in synchronization with the horizontal synchronization signal;
Transmitting means for transmitting the synchronization code and the image signal;
Receiving means for receiving the synchronization code and the image signal;
Synchronization code detection means for detecting the synchronization code;
A first validity period that is started in synchronization with the vertical synchronization signal and ends by detection of a synchronization code as a period for validating the detection result of the synchronization code detection means;
A second validity period that starts after a predetermined time has elapsed since detection of the synchronization code detected within the first validity period and ends by detection of the synchronization code;
An effective period generation circuit for determining

本発明によれば、転送データにスクランブルが施された場合でも確実に同期コードを検出することができる。   According to the present invention, it is possible to reliably detect a synchronization code even when transfer data is scrambled.

本実施形態における撮像装置のブロック図である。It is a block diagram of the imaging device in this embodiment. 本実施形態における送信データ処理回路の構成を示すブロック図である。It is a block diagram which shows the structure of the transmission data processing circuit in this embodiment. 本実施形態におけるウインドウ生成回路の構成を示すブロック図である。It is a block diagram which shows the structure of the window generation circuit in this embodiment. 本実施形態におけるウインドウ生成回路の動作を示すタイミングチャートである。It is a timing chart which shows operation | movement of the window generation circuit in this embodiment. 本実施形態における同期コード検出回路の構成を示すブロック図である。It is a block diagram which shows the structure of the synchronous code detection circuit in this embodiment. 第2の本実施形態における撮像装置のブロック図である。It is a block diagram of the imaging device in 2nd this embodiment. 第2の本実施形態におけるウインドウ生成回路の構成を示すブロック図である。It is a block diagram which shows the structure of the window generation circuit in 2nd this embodiment. 第2の本実施形態におけるウインドウ生成回路の動作を示すタイミングチャートである。It is a timing chart which shows operation | movement of the window generation circuit in 2nd this embodiment. 第2の本実施形態における同期コード検出回路の構成を示すブロック図である。It is a block diagram which shows the structure of the synchronous code detection circuit in 2nd this embodiment. 第3の本実施形態におけるウインドウ生成回路の構成を示すブロック図である。It is a block diagram which shows the structure of the window generation circuit in 3rd this embodiment. 第3の本実施形態におけるウインドウ生成回路の動作を示すタイミングチャートである。It is a timing chart which shows operation | movement of the window generation circuit in 3rd this embodiment. 第3の本実施形態におけるウインドウ生成回路の閾値の切り替えを説明する表である。It is a table | surface explaining switching of the threshold value of the window generation circuit in 3rd this embodiment. 第4の実施形態における送信データ処理回路の構成を示すブロック図である。It is a block diagram which shows the structure of the transmission data processing circuit in 4th Embodiment. 第4の実施形態におけるウインドウ生成回路の動作を示すタイミングチャートである。14 is a timing chart illustrating an operation of the window generation circuit according to the fourth embodiment.

[実施例1]
以下、本発明の第1の実施形態について詳述する。
[Example 1]
Hereinafter, the first embodiment of the present invention will be described in detail.

図1は、本発明の実施形態における撮像装置の構成を説明するブロック図である。図1において、発信器101は、動作の基準となる基準クロックを出力する。この発振器101から出力される基準クロックに基づいて、後述する各部が動作する。   FIG. 1 is a block diagram illustrating a configuration of an imaging apparatus according to an embodiment of the present invention. In FIG. 1, an oscillator 101 outputs a reference clock that is a reference for operation. Based on the reference clock output from the oscillator 101, each unit described later operates.

同期信号発生器(SSG)110は、基準クロックに同期して水平同期信号HD及び垂直同期信号VDを出力する。タイミング信号発生器(TG)102は、SSG 110から供給される水平同期信号(HD)、垂直同期信号(VD)に基づいて、撮像素子(センサ)120を駆動するための駆動パルス信号を発生する。   The synchronization signal generator (SSG) 110 outputs a horizontal synchronization signal HD and a vertical synchronization signal VD in synchronization with the reference clock. The timing signal generator (TG) 102 generates a driving pulse signal for driving the image sensor (sensor) 120 based on the horizontal synchronizing signal (HD) and the vertical synchronizing signal (VD) supplied from the SSG 110. .

センサ120は、例えばCCDやCMOSから構成される撮像素子である。このセンサ120は、その内部に、光電変換を行うフォトダイオード等の画素部103と、この画素部103で得られた画素信号をTG 102から供給される駆動パルス信号(駆動信号)に従って順次出力する転送路と、画素信号を増幅するアンプ、画素信号をデジタル信号に変換するA/D変換器等を有している。   The sensor 120 is an image pickup device configured by, for example, a CCD or a CMOS. The sensor 120 sequentially outputs a pixel unit 103 such as a photodiode that performs photoelectric conversion and a pixel signal obtained by the pixel unit 103 in accordance with a drive pulse signal (drive signal) supplied from the TG 102. It includes a transfer path, an amplifier that amplifies the pixel signal, an A / D converter that converts the pixel signal into a digital signal, and the like.

送信データ処理回路104は、画素部103からの画素信号とTG 102からのタイミング信号より、所定のプロトコルに従った送信データを生成してパラレルデータとして出力する。   The transmission data processing circuit 104 generates transmission data according to a predetermined protocol from the pixel signal from the pixel unit 103 and the timing signal from the TG 102 and outputs it as parallel data.

具体的には、画素データに対して水平同期信号HDに対応した同期コードの付加等を行う。送信データ処理回路104の構成を図2に示す。ステートマシン回路(FSM)202が、処理サイクルをカウントするカウンタ201からのカウント値と、TG 102からのタイミング信号に従い、出力セレクタ206の出力が所定のプロトコルに従ったデータとなるよう切り替える指示信号を出力する。   Specifically, a synchronization code corresponding to the horizontal synchronization signal HD is added to the pixel data. The configuration of the transmission data processing circuit 104 is shown in FIG. The state machine circuit (FSM) 202 generates an instruction signal for switching the output of the output selector 206 to data according to a predetermined protocol according to the count value from the counter 201 that counts processing cycles and the timing signal from the TG 102. Output.

具体的には垂直同期信号VDに同期したデータの先頭に、固定パターン生成部203が出力する固定パターンのデータを所定時間出力する。固定パターンには予め定められた特定の制御コードが繰返し含まれており、後述する画像処理部130内でのデータ処理に使用される。また、同期コード生成部204が、画素信号の各水平ラインに対して水平同期信号HDに対応した同期コードの付加を行う。   Specifically, the fixed pattern data output by the fixed pattern generation unit 203 is output for a predetermined time at the head of the data synchronized with the vertical synchronization signal VD. The fixed pattern repeatedly includes a predetermined specific control code, and is used for data processing in the image processing unit 130 described later. The synchronization code generation unit 204 adds a synchronization code corresponding to the horizontal synchronization signal HD to each horizontal line of the pixel signal.

同期コードとはあらかじめ決められたワード長のデータ(シンボル)の特定のパターンを指しており、例えば同期コードが4シンボルで構成されるとすると、{同期コード1、同期コード2、同期コード3、同期コード4}={ALL0のシンボル、ALL0のシンボル、ALL1のシンボル、ALL1のシンボル}といったデータの並びである。   The synchronization code refers to a specific pattern of data (symbols) having a predetermined word length. For example, if the synchronization code is composed of 4 symbols, {synchronization code 1, synchronization code 2, synchronization code 3, Synchronization code 4} = {ALL0 symbol, ALL0 symbol, ALL1 symbol, ALL1 symbol}.

受信側はこれらのデータパターンをパターンマッチングにより同期コードとして検出し、水平同期のタイミングを取る。同期コードは固定パターンの直後、または水平同期信号HDに同期したデータの先頭に出力されるようFSM202によって制御される。画素部103からの画素データについてはスクランブル回路205でスクランブル処理を施す。   The receiving side detects these data patterns as synchronization codes by pattern matching and takes the timing of horizontal synchronization. The synchronization code is controlled by the FSM 202 so as to be output immediately after the fixed pattern or at the head of data synchronized with the horizontal synchronization signal HD. The pixel data from the pixel unit 103 is scrambled by the scramble circuit 205.

スクランブル処理については例えば線形帰還シフトレジスタによって生成した乱数と画素データとの排他的論理和を取って実際に送信するデータを生成する。パラレルシリアル変換器106は、送信データ処理回路104から出力されるパラレルデータをシリアルデータに変換する。   For the scramble processing, for example, the data to be actually transmitted is generated by taking the exclusive OR of the random number generated by the linear feedback shift register and the pixel data. The parallel-serial converter 106 converts the parallel data output from the transmission data processing circuit 104 into serial data.

変換されたシリアルデータは、送信ドライバ107を通して基板やケーブルを経由し受信ドライバ111へ供給される。PLL 105は基準クロックからパラレルシリアル変換器106のシリアルデータへの変換レートに合わせたシリアルクロックをパラレルシリアル変換器106へ供給する。   The converted serial data is supplied to the reception driver 111 through the transmission driver 107 via the board and the cable. The PLL 105 supplies a serial clock that matches the conversion rate from the reference clock to the serial data of the parallel-serial converter 106 to the parallel-serial converter 106.

ここでは送信データ処理回路104からの出力データを1つの送信ドライバを介して出力する例を示しているが、実現したいデータレートに応じて複数のドライバにデータを分配して送ってもよい。130は画像処理部である。シリアルパラレル変換器112は受信ドライバ111からのシリアルデータを入力して内部のシフトレジスタに蓄える。   Here, an example in which output data from the transmission data processing circuit 104 is output via one transmission driver is shown, but data may be distributed and sent to a plurality of drivers according to the data rate to be realized. Reference numeral 130 denotes an image processing unit. The serial / parallel converter 112 inputs serial data from the reception driver 111 and stores it in an internal shift register.

蓄えられたシリアルデータを例えば8ビットのパラレルデータとして出力する。さらに、シリアルデータから復元したクロックも出力する。ワードアライン回路113はシリアルパラレル変換器112から出力されたパラレルデータから予め決められたワード長のデータを取り出す回路である。   The stored serial data is output as, for example, 8-bit parallel data. In addition, a clock recovered from the serial data is also output. The word align circuit 113 is a circuit that extracts data having a predetermined word length from the parallel data output from the serial / parallel converter 112.

例えばシリアルパラレル変換器112からのパラレルデータが8ビットで、それに対して画素データが1画素あたり12ビットのワード長であったとすると、8ビット入力から各画素の12ビットの境目を探し出し、12ビットのワードを取り出して出力する。   For example, if the parallel data from the serial / parallel converter 112 is 8 bits and the pixel data has a word length of 12 bits per pixel, the 12-bit boundary of each pixel is searched from the 8-bit input, and 12 bits. Is taken out and output.

このようなワード同期を取る(ワードアライン)動作は前述した固定パターンを受信した際に行われる。固定パターンは予め定められた特定の制御コードであり、ワードアライン回路113はその特定の制御コードのパターンをパターンマッチングにより探すことでワード同期を取る。固定パターンのデータは、例えば{固定パターン1、固定パターン2、固定パターン3、固定パターン4}={ALL1のシンボル、ALL0のシンボル、ALL1のシンボル、ALL1のシンボル}といったデータの並びとする。   Such word synchronization (word alignment) operation is performed when the above-described fixed pattern is received. The fixed pattern is a predetermined specific control code, and the word align circuit 113 obtains the word synchronization by searching for the pattern of the specific control code by pattern matching. The fixed pattern data is, for example, an array of data such as {fixed pattern 1, fixed pattern 2, fixed pattern 3, fixed pattern 4} = {ALL1 symbol, ALL0 symbol, ALL1 symbol, ALL1 symbol}.

ワードアライン回路113はワード同期を取り、固定パターン中の特定の制御コードを検出している間は固定パターン検出信号をHighにしてウインドウ生成回路114へ出力する。特定の制御コードが数シンボル連続で検出できなかった場合には固定パターン検出信号をLowにしてウインドウ生成回路114へ出力する。また、ワード同期を取ったデータ信号を同期コード検出回路115と受信データ処理回路116へ出力する。ウインドウ生成回路114は同期コードの検出結果を有効にする期間を示す信号を生成する。   The word alignment circuit 113 takes word synchronization and outputs a fixed pattern detection signal to the window generation circuit 114 while the fixed pattern detection signal is High while a specific control code in the fixed pattern is detected. When a specific control code cannot be detected continuously for several symbols, the fixed pattern detection signal is set to Low and output to the window generation circuit 114. Further, the data signal having the word synchronization is output to the synchronization code detection circuit 115 and the reception data processing circuit 116. The window generation circuit 114 generates a signal indicating a period for validating the detection result of the synchronization code.

本実施例ではこの期間を示す信号のことをウインドウ信号と呼ぶ。ウインドウ信号と同期コード検出信号とで論理積を取ることで、ウインドウ信号がHighの期間に検出された同期コードは有効、ウインドウ信号がLowの期間に検出された同期コードは無効と判断する。この論理積を取った信号のことをデータ先頭通知信号と呼ぶ。   In this embodiment, a signal indicating this period is called a window signal. By taking the logical product of the window signal and the synchronization code detection signal, it is determined that the synchronization code detected when the window signal is High is valid and the synchronization code detected when the window signal is Low is invalid. A signal obtained by taking the logical product is called a data head notification signal.

ウインドウ生成回路114の構成を図3に示す。また、ウインドウ生成回路114の動作タイミングチャートを図4に示す。SSG 110からのVD信号を受けて、VD受信フラグ生成部301ではVD信号を受信したことを示すフラグ信号をHighにする。フラグ信号はデータ先頭通知信号を受けるとLowとなる。このフラグ信号とワードアライン回路113からの固定パターン検出信号の論理積を取ったものがウインドウ1信号である。   The configuration of the window generation circuit 114 is shown in FIG. An operation timing chart of the window generation circuit 114 is shown in FIG. In response to the VD signal from the SSG 110, the VD reception flag generation unit 301 sets the flag signal indicating that the VD signal has been received to High. The flag signal becomes Low when the data head notification signal is received. The window 1 signal is the logical product of this flag signal and the fixed pattern detection signal from the word align circuit 113.

固定パターン検出信号のみをウインドウ1信号にした場合は、転送データ中に固定パターン中の特定の制御コードが現れてしまった際にウインドウ1信号が意図しない期間でHighになってしまう可能性があるが、フラグ信号との論理積とすることでその可能性を下げることが出来る。   When only the fixed pattern detection signal is the window 1 signal, there is a possibility that the window 1 signal becomes high in an unintended period when a specific control code in the fixed pattern appears in the transfer data. However, the possibility can be lowered by making the logical product with the flag signal.

VDは垂直同期信号であり、固定パターンは垂直同期信号に同期してデータの先頭に付くものであるので、ウインドウ1信号は転送データの一番初めの同期コード検出を有効にする期間を示すことになる。   Since VD is a vertical synchronization signal and the fixed pattern is attached to the head of data in synchronization with the vertical synchronization signal, the window 1 signal indicates a period in which the detection of the first synchronization code of the transfer data is valid. become.

カウンタ302はデータ先頭通知信号を受けるとリセットされてカウントアップを開始する。そして比較器304で所定の値との比較を行い、カウント値のほうが大きい場合にHigh、小さい場合にLowを比較器304からウインドウ2信号として出力する。所定の値については予め画像処理部130内にある複数の設定レジスタに複数の水平カウント設定値が保持されているものとする。   When the counter 302 receives the data head notification signal, it is reset and starts counting up. The comparator 304 compares the value with a predetermined value, and outputs High as a window 2 signal from the comparator 304 when the count value is larger and Low when the count value is smaller. For the predetermined value, a plurality of horizontal count setting values are held in advance in a plurality of setting registers in the image processing unit 130.

本実施例では水平カウント設定値1と水平カウント設定値2を持つものとする。それらの設定値を後述する受信データ処理回路116からのデータ種別通知信号に応じてセレクタ303で切り替えて比較器304で使用する。   In this embodiment, it is assumed that the horizontal count setting value 1 and the horizontal count setting value 2 are provided. These set values are switched by the selector 303 according to a data type notification signal from the received data processing circuit 116 described later and used by the comparator 304.

本実施例では、水平同期信号ごとの転送データ量が一定でない場合を想定しており、各転送データ量はデータの種別毎に決まっているものとする。例えばデータの種別が種別Aと種別Bの2種類あり、種別Aのデータはサイクル数100、種別Bのデータはサイクル数50で処理できる量のデータであるとする。   In this embodiment, it is assumed that the transfer data amount for each horizontal synchronization signal is not constant, and each transfer data amount is determined for each data type. For example, it is assumed that there are two types of data, type A and type B, the data of type A is the amount of data that can be processed with 100 cycles and the data of type B is 50 cycles.

この場合、種別Aと対応する水平カウント設定値1を100、種別Bと対応する水平カウント設定値2を50とする。データ種別通知信号が種別Aを示している場合、セレクタ303では水平カウント設定値1が選択出力され、カウンタ302のカウント値が100を超えた場合にウインドウ2信号がHighとなる。ウインドウ2信号がHighの期間に同期コードが検出されるとデータ先頭通知信号が入力され、カウンタ302がリセットされるのでウインドウ2信号はLowとなる。   In this case, the horizontal count setting value 1 corresponding to the type A is set to 100, and the horizontal count setting value 2 corresponding to the type B is set to 50. When the data type notification signal indicates type A, the selector 303 selects and outputs the horizontal count setting value 1, and when the count value of the counter 302 exceeds 100, the window 2 signal becomes High. When the synchronization code is detected while the window 2 signal is high, the data head notification signal is input and the counter 302 is reset, so that the window 2 signal becomes low.

データ種別通知信号が種別Bを示している場合、セレクタ303では水平カウント設定値2が選択出力され、カウンタ302のカウント値が50を超えた場合にウインドウ2信号がHighとなる。ウインドウ2信号がHighの期間に同期コードが検出されるとデータ先頭通知信号が入力され、カウンタ302がリセットされるのでウインドウ2信号はLowとなる。   When the data type notification signal indicates type B, the selector 303 selects and outputs the horizontal count setting value 2, and when the count value of the counter 302 exceeds 50, the window 2 signal becomes High. When the synchronization code is detected while the window 2 signal is high, the data head notification signal is input and the counter 302 is reset, so that the window 2 signal becomes low.

この動作を繰り返すことで、ウインドウ2信号は周期的に転送される同期コードの検出を有効にする期間を示すことになる。これらのウインドウ1信号とウインドウ2信号との論理和をとったものがウインドウ生成回路114からウインドウ信号として出力される。   By repeating this operation, the window 2 signal indicates a period in which detection of the synchronous code periodically transferred is valid. The window generation circuit 114 outputs a logical sum of the window 1 signal and the window 2 signal as a window signal.

ウインドウ生成回路114の動作について、本実施例では受信データ処理回路116からのデータ種別通知信号に応じてセレクタ303で設定値を切り替えるように記載したが、この構成に限定されるものではない。例えば、受信データ処理回路116から処理するデータの処理に必要なサイクル数を受け取って、そのサイクル数とカウンタ302のカウント値を比較してウインドウ2信号を生成してもよい。   In this embodiment, the operation of the window generation circuit 114 is described so that the setting value is switched by the selector 303 in accordance with the data type notification signal from the reception data processing circuit 116. However, the present invention is not limited to this configuration. For example, the window 2 signal may be generated by receiving the number of cycles necessary for processing the data to be processed from the reception data processing circuit 116 and comparing the number of cycles with the count value of the counter 302.

同期コード検出回路115はワードアライン回路113からのデータ信号を受け、同期コードを検出して同期コード検出信号として出力する。同期コード検出回路115の構成を図5に示す。ここでは同期コードが4シンボルで構成される例を示している。501〜504は入力データを遅延するための遅延素子である。遅延素子501〜504の出力をそれぞれ比較器505〜508にて、同期コード4シンボルそれぞれの期待値と比較する。期待値と一致すれば1、一致しない場合は0を各比較器が出力する。各比較器からの出力を加算器509で加算する。その値とあらかじめ設定された閾値とを比較器510で比較し、その値が閾値以上となった場合に同期コード検出信号を出力する。   The synchronization code detection circuit 115 receives the data signal from the word alignment circuit 113, detects the synchronization code, and outputs it as a synchronization code detection signal. The configuration of the synchronization code detection circuit 115 is shown in FIG. Here, an example is shown in which the synchronization code is composed of four symbols. Reference numerals 501 to 504 denote delay elements for delaying input data. The outputs of the delay elements 501 to 504 are compared with the expected values of the four symbols of the synchronization code by the comparators 505 to 508, respectively. Each comparator outputs 1 if it matches the expected value, and 0 if it does not match. The outputs from the comparators are added by an adder 509. The value is compared with a preset threshold value by a comparator 510, and when the value is equal to or greater than the threshold value, a synchronization code detection signal is output.

このように、同期コードを複数シンボル構成とし、各々のシンボル期待値との比較結果を合わせて評価することで、あるサイクルでビットエラーが起きて同期コードの一部が壊れてしまうといったケースに対してエラー耐性を持つことができる。受信データ処理回路116は、ワードアライン回路113からのデータ信号に対してデータ先頭通知信号を受けたタイミングをデータの先頭として、所定のフォーマットで定義されているデータの中身を解析、処理していく。   In this way, when the synchronization code is composed of multiple symbols and the evaluation result is compared with the expected value of each symbol, a bit error occurs in a certain cycle and a part of the synchronization code is broken. Error tolerance. The reception data processing circuit 116 analyzes and processes the contents of data defined in a predetermined format with the timing at which the data head notification signal is received from the data signal from the word align circuit 113 as the head of the data. .

所定のフォーマットのデータの中身には前述のデータ種別を示す識別信号が含まれている。この識別信号をデータ種別通知信号としてウインドウ生成回路114に通知することで、ウインドウ生成回路114は識別情報の内容によってウインドウ2信号の期間を切り替える。受信データ処理回路116からウインドウ生成回路114に通知する情報については、上述したように識別情報に限定されない。所定のフォーマットのデータ中にデータ長を含むようにしておき、そのデータ長を水平期間に処理するのに必要なサイクル数を通知するようにしてもよい。   The content of the data in a predetermined format includes an identification signal indicating the data type. By notifying the window generation circuit 114 of this identification signal as a data type notification signal, the window generation circuit 114 switches the window 2 signal period according to the content of the identification information. The information notified from the reception data processing circuit 116 to the window generation circuit 114 is not limited to the identification information as described above. The data length may be included in the data of a predetermined format, and the number of cycles required to process the data length in the horizontal period may be notified.

以上、本実施形態によれば、ウインドウ信号がHighである期間のみ同期コードの検出結果を有効にすることで、転送データにスクランブルをかけた結果転送データ中に同期コードの符号列が意図せず存在してしまった場合でも誤検出を防ぐことが出来る。また、本実施例では転送データにスクランブルをかける例を示したが、実施においては転送データにスクランブルをかけることに限定するものではない。転送データにスクランブルがかかっていない場合に転送データにエラーが生じて同期コードの符号列が意図せず存在してしまったような場合でも誤検出を防ぐことができる。   As described above, according to the present embodiment, the detection result of the synchronization code is validated only during the period when the window signal is High, so that the code string of the synchronization code is not intended in the transfer data as a result of scrambling the transfer data. Even if it exists, false detection can be prevented. In this embodiment, the transfer data is scrambled. However, the embodiment is not limited to scramble the transfer data. Even if the transfer data is not scrambled and an error occurs in the transfer data, and the code string of the synchronization code exists unintentionally, erroneous detection can be prevented.

[実施例2]
以下、本発明の第2の実施形態について詳述する。第1の実施形態と同様の箇所については同じ記号で示し、それらの説明は省略する。第1の実施形態において、ウインドウ1信号がHighの期間に転送されるデータは、固定パターンのデータと同期コードである。またウインドウ2信号がHighの期間に転送されるデータは、画素データに対してスクランブル処理を施したデータと同期コードである。
[Example 2]
Hereinafter, the second embodiment of the present invention will be described in detail. The same parts as those in the first embodiment are denoted by the same symbols, and the description thereof is omitted. In the first embodiment, the data transferred during the period in which the window 1 signal is High is a fixed pattern data and a synchronization code. Data transferred during a period when the window 2 signal is High is data obtained by performing scramble processing on pixel data and a synchronization code.

上記のように、各々の期間に転送されるデータの種類が異なるため、同期コードの検出における各々の期間のエラーに対する耐性は異なる。   As described above, since the type of data transferred in each period is different, the tolerance for errors in each period in the detection of the synchronization code is different.

例えば、ウインドウ1信号がHighの期間では、所定数以下のエラーであれば同期コードと判定しない固定パターンにセンサ120側で設定することにより、同期コードの検出におけるエラーに対する耐性を高くすることができる。一方、ウインドウ2信号がHighの期間では、画素データにスクランブル処理を施したデータは固定パターンよりも、同期コードの検出におけるエラーに対する耐性は低い。   For example, in the period when the window 1 signal is High, if the error is equal to or less than a predetermined number, by setting the fixed pattern that is not determined as the synchronization code on the sensor 120 side, the tolerance to the error in the detection of the synchronization code can be increased. . On the other hand, during a period in which the window 2 signal is high, data obtained by subjecting the pixel data to scramble processing is less resistant to errors in detecting the synchronization code than the fixed pattern.

そのため、ウインドウ1信号がHighの期間とウインドウ2信号がHighの期間において、同期コードの検出に用いる閾値を同一の値を設定すると正しく同期コードを検出できない課題がある。第2の実施形態においては、ウインドウ生成回路のウインドウ1信号とウインドウ2信号の状態によって、同期コード検出に用いる閾値を切り替える点が第1の実施形態と異なる。   Therefore, there is a problem that the synchronization code cannot be detected correctly if the same threshold value is used for detecting the synchronization code during the period when the window 1 signal is high and the window 2 signal is high. The second embodiment differs from the first embodiment in that the threshold used for synchronization code detection is switched depending on the state of the window 1 signal and the window 2 signal of the window generation circuit.

図6は、本発明の第2の実施形態における撮像装置の構成を説明するブロック図である。630は画像処理部である。ウインドウ生成回路614は、同期コードの検出結果を有効にする期間を示す信号と同期コードの検出に用いる閾値を切り替える信号を生成する点が図1と異なる。ウインドウ生成回路614の構成を図7に示す。また、ウインドウ生成回路614の動作タイミングチャートを図8に示す。   FIG. 6 is a block diagram illustrating the configuration of the imaging apparatus according to the second embodiment of the present invention. Reference numeral 630 denotes an image processing unit. The window generation circuit 614 differs from FIG. 1 in that it generates a signal indicating a period during which the detection result of the synchronization code is valid and a signal for switching a threshold used for detection of the synchronization code. The configuration of the window generation circuit 614 is shown in FIG. An operation timing chart of the window generation circuit 614 is shown in FIG.

閾値切り替え部701は、ウインドウ1信号とウインドウ2信号を受けて、閾値切り替え信号を出力する。ウインドウ1信号がHighかつウインドウ2信号がLowの場合、同期コードの検出に用いる閾値は閾値1を使用するという閾値切り替え信号を出力する。ウインドウ2信号がHighかつウインドウ1信号がLowの場合、同期コードの検出に用いる閾値は閾値2を使用するという閾値切り替え信号を出力する。   The threshold switching unit 701 receives the window 1 signal and the window 2 signal and outputs a threshold switching signal. When the window 1 signal is high and the window 2 signal is low, a threshold value switching signal is output in which the threshold value 1 is used as the threshold value used for detecting the synchronization code. When the window 2 signal is high and the window 1 signal is low, a threshold value switching signal is output that the threshold value 2 is used as the threshold value used for detecting the synchronization code.

上記以外の場合、同期コードの検出に用いる閾値は閾値3を使用するという閾値切り替え信号を出力する。   In cases other than the above, a threshold value switching signal that uses the threshold value 3 as the threshold value used for detection of the synchronization code is output.

同期コード検出回路615は、ウインドウ生成回路614から閾値切り替え信号とワードアライン回路113からのデータ信号を受け、閾値切り替え信号に基づいてデータ信号から同期コードを検出して同期コード検出信号として出力する。同期コード検出回路615の構成を図9に示す。閾値切り替え信号を受けて、閾値1、閾値2、閾値3の中から選択して同期コードの検出に用いる閾値を出力する。   The synchronization code detection circuit 615 receives the threshold value switching signal from the window generation circuit 614 and the data signal from the word alignment circuit 113, detects the synchronization code from the data signal based on the threshold value switching signal, and outputs it as a synchronization code detection signal. The configuration of the synchronization code detection circuit 615 is shown in FIG. In response to the threshold switching signal, the threshold is selected from threshold 1, threshold 2, and threshold 3, and the threshold used for detecting the synchronization code is output.

加算器509で加算した値とその選択された閾値とを比較器510で比較し、その値が選択された閾値以上となった場合に同期コード検出信号を出力する。   The value added by the adder 509 is compared with the selected threshold value by the comparator 510, and when the value is equal to or greater than the selected threshold value, a synchronization code detection signal is output.

前述通り、ウインドウ1信号がHighの期間はウインドウ2信号がHighの期間よりも同期コードの検出におけるエラーに対する耐性は高い。そのため、同期コードの検出に用いる閾値1は閾値2よりも低い値を設定する。   As described above, during the period when the window 1 signal is high, the tolerance to the error in detecting the synchronization code is higher than when the window 2 signal is high. Therefore, the threshold value 1 used for detecting the synchronization code is set to a value lower than the threshold value 2.

例えば、同期コードが4シンボルで構成されるとすると、閾値1は4シンボル中2シンボル一致で同期コードと判定する閾値に設定する。また閾値2は4シンボル中3シンボル一致で同期コードと判定する閾値に設定する。なお、閾値3は同期コードを検出しない閾値を設定する。   For example, if the synchronization code is composed of 4 symbols, the threshold value 1 is set to a threshold value for determining a synchronization code when two symbols in four symbols match. The threshold 2 is set to a threshold for determining a synchronization code when 3 symbols coincide in 4 symbols. Note that threshold 3 is set to a threshold at which no synchronization code is detected.

以上、本実施形態によれば、ウインドウ生成回路のウインドウ1信号とウインドウ2信号の状態によって、同期コード検出に用いる閾値を切り替えることで、正しく同期コードを検出することが出来る。また、本実施例では転送データにスクランブルをかける例を示したが、実施においては転送データにスクランブルをかけることに限定するものではない。転送データにスクランブルがかかっていない場合に転送データにエラーが生じて同期コードの符号列が意図せず存在してしまったような場合でも誤検出を防ぐことができる。   As described above, according to the present embodiment, the synchronization code can be correctly detected by switching the threshold used for the synchronization code detection according to the state of the window 1 signal and the window 2 signal of the window generation circuit. In this embodiment, the transfer data is scrambled. However, the embodiment is not limited to scramble the transfer data. Even if the transfer data is not scrambled and an error occurs in the transfer data, and the code string of the synchronization code exists unintentionally, erroneous detection can be prevented.

[実施例3]
以下、本発明の第3の実施形態について詳述する。第1の実施形態および第2の実施形態と同様の箇所については同じ記号で示し、それらの説明は省略する。第1の実施形態および第2の実施形態において、カウンタ302のカウント値が所定の水平カウント設定値を超えた場合にウインドウ2信号がHighとなる。センサ120側で同期コードを付加するタイミングは水平同期信号HD毎に変動する可能性があるため、ウインドウ2信号をHighにする水平カウント設定値はその変動量を考慮して特定のマージンを含む値を設定する必要がある。
[Example 3]
Hereinafter, the third embodiment of the present invention will be described in detail. Portions similar to those in the first embodiment and the second embodiment are denoted by the same symbols, and description thereof is omitted. In the first embodiment and the second embodiment, the window 2 signal becomes High when the count value of the counter 302 exceeds a predetermined horizontal count set value. Since the timing at which the synchronization code is added on the sensor 120 side may vary for each horizontal synchronization signal HD, the horizontal count setting value for setting the window 2 signal to High is a value including a specific margin in consideration of the variation amount. Need to be set.

具体的には、センサ120側で同期コードを付加するタイミングが水平同期信号HD毎に変動しない場合に対して、ウインドウ2信号のHighの期間の開始するタイミングを早めるように、所定の水平カウント設定値から特定のマージン値を差し引いて設定する。   Specifically, a predetermined horizontal count setting is set so that the timing at which the high period of the window 2 signal starts is advanced in comparison with the case where the timing of adding the synchronization code on the sensor 120 side does not vary for each horizontal synchronization signal HD Set by subtracting a specific margin value from the value.

上記のようにウインドウ2信号のHighの期間は特定のマージンを含むため、その期間に転送されるデータは画素データに対してスクランブル処理を施したデータと同期コードの両方が含まれる。ウインドウ2信号のHighの期間が開始してから所定の期間は特定のマージンを含む期間であるため、その期間のデータは画素データに対してスクランブル処理を施したデータである可能性が高い。そのため、その期間では転送データ中に同期コードの符号列が意図せず存在してしまい、同期コードを誤検出してデータの処理を正しく行えない可能性が高くなる。   As described above, since the High period of the window 2 signal includes a specific margin, the data transferred during the period includes both the data obtained by performing the scramble processing on the pixel data and the synchronization code. Since the predetermined period from the start of the High period of the window 2 signal is a period including a specific margin, there is a high possibility that the data in that period is data obtained by performing scramble processing on the pixel data. For this reason, the code string of the synchronization code is unintentionally present in the transfer data during that period, and there is a high possibility that the synchronization code is erroneously detected and data processing cannot be performed correctly.

また、ウインドウ2信号のHighの期間が開始してから所定の期間以降の転送データには同期コードが含まれる可能性が高い。   In addition, there is a high possibility that the transfer data after a predetermined period from the start of the High period of the window 2 signal includes a synchronization code.

つまり、ウインドウ2信号のHighの期間が開始してから所定の期間はスクランブル処理を施したデータである可能性が高いため、ウインドウ2信号のHighの期間が開始してから所定の期間以降よりも、同期コードの検出におけるエラーに対する耐性は低い。そのため、ウインドウ2信号がHighの期間において、同期コードの検出に用いる閾値を同一の値を設定すると正しく同期コードを検出できない課題がある。   In other words, since it is highly possible that the predetermined period after the start of the high period of the window 2 signal is scrambled data, the data is higher than the predetermined period after the high period of the window 2 signal starts. The tolerance for errors in the detection of the synchronization code is low. Therefore, there is a problem that the synchronization code cannot be correctly detected if the same threshold value is used for detecting the synchronization code during the period when the window 2 signal is High.

第3の実施形態においては、ウインドウ生成回路のウインドウ1信号とウインドウ2信号の状態およびウインドウ2信号のHighの期間が開始してから所定の期間内か否かによって、同期コード検出に用いる閾値を切り替える点が第2の実施形態と異なる。第3の実施形態のウインドウ生成回路614の構成を図10に示す。また、ウインドウ生成回路614の動作タイミングチャートを図11に示す。ウインドウ生成回路614の閾値の切り替えを説明する表を図12に示す。   In the third embodiment, the threshold value used for synchronous code detection is determined depending on the state of the window 1 signal and window 2 signal of the window generation circuit and whether or not the high period of the window 2 signal is within a predetermined period. The point of switching is different from the second embodiment. The configuration of the window generation circuit 614 of the third embodiment is shown in FIG. An operation timing chart of the window generation circuit 614 is shown in FIG. FIG. 12 shows a table for explaining the threshold value switching of the window generation circuit 614.

カウンタ1001は、ウインドウ2信号がHighになるとカウントアップを開始する。またカウンタ1001のカウント値は、ウインドウ2信号がLowになるとリセットする。閾値切り替え部1002は、ウインドウ1信号とウインドウ2信号およびカウンタ1001のカウント値を受けて、閾値切り替え信号を出力する。   The counter 1001 starts counting up when the window 2 signal becomes High. The count value of the counter 1001 is reset when the window 2 signal becomes low. The threshold switching unit 1002 receives the window 1 signal, the window 2 signal, and the count value of the counter 1001, and outputs a threshold switching signal.

ウインドウ1信号がHighかつウインドウ2信号がLowの場合、同期コードの検出に用いる閾値は閾値1を使用するという閾値切り替え信号を出力する。ウインドウ1信号がLowかつウインドウ2信号がHighでカウント1001のカウント値が所定のカウント値以下の場合、同期コードの検出に用いる閾値は閾値2を使用するという閾値切り替え信号を出力する。なお、図11では所定のカウント値を「1」としている。   When the window 1 signal is high and the window 2 signal is low, a threshold value switching signal is output in which the threshold value 1 is used as the threshold value used for detecting the synchronization code. When the window 1 signal is low and the window 2 signal is high and the count value of the count 1001 is equal to or smaller than the predetermined count value, a threshold value switching signal is output that the threshold value 2 is used as the threshold value used for detecting the synchronization code. In FIG. 11, the predetermined count value is “1”.

ウインドウ1信号がLowかつウインドウ2信号がHighでカウント1001のカウント値が所定のカウント値よりも大きい場合、同期コードの検出に用いる閾値は閾値1を使用するという閾値切り替え信号を出力する。   When the window 1 signal is low and the window 2 signal is high and the count value of the count 1001 is larger than a predetermined count value, a threshold value switching signal is output that the threshold value 1 is used as the threshold value used for detecting the synchronization code.

上記以外の場合、同期コードの検出に用いる閾値は閾値3を使用するという閾値切り替え信号を出力する。   In cases other than the above, a threshold value switching signal that uses the threshold value 3 as the threshold value used for detection of the synchronization code is output.

例えば、同期コードが4シンボルで構成されるとすると、閾値1は4シンボル中2シンボル一致で同期コードと判定する閾値に設定する。また閾値2は4シンボル中3シンボル一致で同期コードと判定する閾値に設定する。なお、閾値3は同期コードを検出しない閾値を設定する。   For example, if the synchronization code is composed of 4 symbols, the threshold value 1 is set to a threshold value for determining a synchronization code when two symbols in four symbols match. The threshold 2 is set to a threshold for determining a synchronization code when 3 symbols coincide in 4 symbols. Note that threshold 3 is set to a threshold at which no synchronization code is detected.

このように、ウインドウ2信号がHighの期間内においては、転送データ中に同期コードの符号列が意図せず存在してしまう可能性がある。そのため、ウインドウ2信号がHighの期間内で同期コード検出の閾値を切り替えることで、同期コードの誤検出を防ぐことができる。   Thus, there is a possibility that the code string of the synchronization code is unintentionally present in the transfer data during the period when the window 2 signal is High. Therefore, it is possible to prevent erroneous detection of the synchronization code by switching the synchronization code detection threshold within the period in which the window 2 signal is High.

以上、本実施形態によれば、ウインドウ生成回路のウインドウ1信号とウインドウ2信号の状態およびカウンタ1001のカウント値によって、同期コード検出に用いる閾値を切り替えることで、正しく同期コードを検出することが出来る。また、本実施例では転送データにスクランブルをかける例を示したが、実施においては転送データにスクランブルをかけることに限定するものではない。   As described above, according to the present embodiment, the synchronization code can be correctly detected by switching the threshold used for the synchronization code detection according to the state of the window 1 signal and the window 2 signal of the window generation circuit and the count value of the counter 1001. . In this embodiment, the transfer data is scrambled. However, the embodiment is not limited to scramble the transfer data.

転送データにスクランブルがかかっていない場合に転送データにエラーが生じて同期コードの符号列が意図せず存在してしまったような場合でも同様の構成で誤検出を防ぐことができる。   Even when the transfer data is not scrambled and an error occurs in the transfer data and the code string of the synchronization code unintentionally exists, erroneous detection can be prevented with the same configuration.

[実施例4]
以下、本発明の第4の実施形態について詳述する。第1の実施形態と同様の箇所については同じ記号で示し、それらの説明は省略する。
[Example 4]
Hereinafter, the fourth embodiment of the present invention will be described in detail. The same parts as those in the first embodiment are denoted by the same symbols, and the description thereof is omitted.

第1の実施形態において、カウンタ302のカウント値が所定の水平カウント設定値を超えた場合にウインドウ2信号がHighとなる。センサ120側で同期コードを付加するタイミングは水平同期信号HD毎に変動する可能性があるため、ウインドウ2信号をHighにする水平カウント設定値はその変動量を考慮して特定のマージンを含む値を設定する必要がある。   In the first embodiment, when the count value of the counter 302 exceeds a predetermined horizontal count setting value, the window 2 signal becomes High. Since the timing at which the synchronization code is added on the sensor 120 side may vary for each horizontal synchronization signal HD, the horizontal count setting value for setting the window 2 signal to High is a value including a specific margin in consideration of the variation amount. Need to be set.

具体的には、センサ120側で同期コードを付加するタイミングが水平同期信号HD毎に変動しない場合に対して、ウインドウ2信号のHighの期間の開始するタイミングを早めるように、所定の水平カウント設定値から特定のマージン値を差し引いて設定する。   Specifically, a predetermined horizontal count setting is set so that the timing at which the high period of the window 2 signal starts is advanced in comparison with the case where the timing of adding the synchronization code on the sensor 120 side does not vary for each horizontal synchronization signal HD. Set by subtracting a specific margin value from the value.

上記のようにウインドウ2信号のHighの期間は特定のマージンを含むため、その期間に転送されるデータは画素データに対してスクランブル処理を施したデータと同期コードの両方が含まれる。   As described above, since the High period of the window 2 signal includes a specific margin, the data transferred during the period includes both the data obtained by performing the scramble processing on the pixel data and the synchronization code.

ウインドウ2信号のHighの期間が開始してから所定の期間は特定のマージンを含む期間であるため、その期間のデータは画素データに対してスクランブル処理を施したデータである可能性が高い。そのため、その期間では転送データ中に同期コードの符号列が意図せず存在してしまい、同期コードを誤検出してデータの処理を正しく行えないという点で課題がある。   Since the predetermined period from the start of the High period of the window 2 signal is a period including a specific margin, there is a high possibility that the data in that period is data obtained by performing scramble processing on the pixel data. Therefore, there is a problem in that the code string of the synchronization code is unintentionally present in the transfer data during that period, and the synchronization code is erroneously detected and data processing cannot be performed correctly.

この第4の実施形態においては、同期コードとは異なるスクランブルされていない所定数のシンボルで形成される終了コードを転送データに付加する点が第1の実施形態と異なる。第4の実施形態の送信データ処理回路104の構成を図13に示す。また、ウインドウ生成回路114の動作タイミングチャートを図14に示す。   The fourth embodiment is different from the first embodiment in that an end code formed by a predetermined number of unscrambled symbols different from the synchronization code is added to the transfer data. FIG. 13 shows the configuration of the transmission data processing circuit 104 according to the fourth embodiment. An operation timing chart of the window generation circuit 114 is shown in FIG.

送信データ処理回路104は、固定パターンのデータ、同期コード、スクランブル処理された画素データの他に同期コードとは異なるスクランブルされていない所定数のシンボルで形成される終了コードを生成する点が図1と異なる。   The transmission data processing circuit 104 generates an end code formed by a predetermined number of unscrambled symbols different from the synchronization code in addition to the fixed pattern data, the synchronization code, and the scrambled pixel data. And different.

終了コード生成部1301は、終了コードを生成する。終了コードは、同期コードを形成する所定のシンボルと異なるシンボルで形成され、かつスクランブルされていない所定数のシンボルで形成される。   The end code generation unit 1301 generates an end code. The end code is formed of a predetermined number of symbols which are formed of symbols different from the predetermined symbols forming the synchronization code and are not scrambled.

例えば、終了コードは固定パターンのデータ、同期コードと同じく4シンボルで構成されるとする。この場合、終了コードは、{終了コード1、終了コード2、終了コード3、終了コード4}={ALL1のシンボル、ALL1のシンボル、ALL0のシンボル、ALL0のシンボル}といったデータの並びであればよい。   For example, it is assumed that the end code is composed of 4 symbols as with the fixed pattern data and the synchronization code. In this case, the end code may be an array of data such as {end code 1, end code 2, end code 3, end code 4} = {ALL1 symbol, ALL1 symbol, ALL0 symbol, ALL0 symbol}. .

ステートマシン回路(FSM)1302は、処理サイクルをカウントするカウンタ201からのカウント値と、TG102からのタイミング信号に従い、出力セレクタ206の出力が所定のプロトコルに従ったデータとなるよう切り替える指示信号を出力する。   The state machine circuit (FSM) 1302 outputs an instruction signal for switching the output of the output selector 206 to data according to a predetermined protocol in accordance with the count value from the counter 201 that counts processing cycles and the timing signal from the TG 102. To do.

具体的には、固定パターン生成部203が出力する固定パターンのデータは、垂直同期信号VDに同期したデータの先頭に所定時間出力する。同期コード生成部204が出力する同期コードは、固定パターンのデータの直後、または水平同期信号HDに同期したデータの先頭に出力する。スクランブル回路205でスクランブル処理された画素データは、同期コードの直後に出力する。終了コード生成部1301が出力する終了コードは、スクランブル処理された画素データの直後に出力する。   Specifically, the fixed pattern data output by the fixed pattern generation unit 203 is output for a predetermined time at the head of the data synchronized with the vertical synchronization signal VD. The synchronization code output by the synchronization code generation unit 204 is output immediately after the fixed pattern data or at the beginning of data synchronized with the horizontal synchronization signal HD. The pixel data scrambled by the scramble circuit 205 is output immediately after the synchronization code. The end code output from the end code generation unit 1301 is output immediately after the scrambled pixel data.

ウインドウ2信号のHighの期間に画素データに対してスクランブル処理を施したデータを含まないようにFSM1302で終了コードの出力タイミングを制御する。その結果、画像処理部130側で終了コードの転送時にウインドウ2信号のHighの期間を開始することができる。   The output timing of the end code is controlled by the FSM 1302 so that the pixel data is not included in the High period of the window 2 signal. As a result, the High period of the window 2 signal can be started when the end code is transferred on the image processing unit 130 side.

このように、ウインドウ2信号がHighの期間内においては、転送データ中に同期コードの符号列が意図せず存在してしまう可能性がある。そのため、ウインドウ2信号のHighの期間に画素データに対してスクランブル処理を施したデータを含まないように終了コードを付加することで、同期コードの誤検出を防ぐことができる。   Thus, there is a possibility that the code string of the synchronization code is unintentionally present in the transfer data during the period when the window 2 signal is High. Therefore, it is possible to prevent erroneous detection of the synchronization code by adding the end code so as not to include the data subjected to the scramble processing on the pixel data during the High period of the window 2 signal.

以上、本実施形態によれば、終了コードを転送データの直後に付加することで、ウインドウ信号がHighである期間、転送データにスクランブルをかけた結果転送データ中に同期コードの符号列が意図せず存在してしまった場合でも誤検出を防ぐことが出来る。また、本実施例では転送データにスクランブルをかける例を示したが、実施においては転送データにスクランブルをかけることに限定するものではない。転送データにスクランブルがかかっていない場合に転送データにエラーが生じて同期コードの符号列が意図せず存在してしまったような場合でも誤検出を防ぐことができる。   As described above, according to the present embodiment, the end code is added immediately after the transfer data, and as a result of scrambled the transfer data while the window signal is High, the code string of the synchronization code is intended in the transfer data. Even if it does exist, false detection can be prevented. In this embodiment, the transfer data is scrambled. However, the embodiment is not limited to scramble the transfer data. Even if the transfer data is not scrambled and an error occurs in the transfer data, and the code string of the synchronization code exists unintentionally, erroneous detection can be prevented.

101 発信器
104 送信データ処理回路
120 センサ(撮像素子)
101 Transmitter 104 Transmission Data Processing Circuit 120 Sensor (Imaging Device)

Claims (16)

基準クロックを発生する発振器と、
前記基準クロックに同期して水平同期信号及び垂直同期信号を発生する同期信号発生手段と、
前記水平同期信号及び前記垂直同期信号に同期して画像信号を読み出す画像信号読み出し手段と、
前記水平同期信号に同期して前記画像信号に同期コードを付加する同期コード付加手段と、
前記同期コードと前記画像信号を送信する送信手段と、
前記同期コードと前記画像信号を受信する受信手段と、
前記同期コードを検出する同期コード検出手段と、
前記同期コード検出手段の検出結果を有効にする期間として
前記垂直同期信号と同期して開始され同期コードの検出によって終了する第1の有効期間と、
前記第1の有効期間内に検出された同期コードの検出から所定の時間が経過した後に開始され同期コードの検出によって終了する第2の有効期間と、
を定める有効期間生成回路
を備えることを特徴とする撮像装置。
An oscillator that generates a reference clock; and
Synchronization signal generating means for generating a horizontal synchronization signal and a vertical synchronization signal in synchronization with the reference clock;
Image signal readout means for reading out an image signal in synchronization with the horizontal synchronization signal and the vertical synchronization signal;
Synchronization code adding means for adding a synchronization code to the image signal in synchronization with the horizontal synchronization signal;
Transmitting means for transmitting the synchronization code and the image signal;
Receiving means for receiving the synchronization code and the image signal;
Synchronization code detection means for detecting the synchronization code;
A first validity period that is started in synchronization with the vertical synchronization signal and ends by detection of a synchronization code as a period for validating the detection result of the synchronization code detection means;
A second validity period that starts after a predetermined time has elapsed since detection of the synchronization code detected within the first validity period and ends by detection of the synchronization code;
An imaging device comprising an effective period generation circuit for determining
前記画像信号に前記画像信号の種別を示す識別信号を付加する識別信号付加手段と
前記識別信号を検出する識別信号検出手段をさらに備え、
前記識別信号検出手段の検出結果によって前記第2の有効期間を開始する前記所定の時間を変えることを特徴とする
請求項1に記載の撮像装置。
An identification signal adding means for adding an identification signal indicating the type of the image signal to the image signal; and an identification signal detecting means for detecting the identification signal;
The imaging apparatus according to claim 1, wherein the predetermined time for starting the second effective period is changed according to a detection result of the identification signal detection unit.
前記画像信号に前記画像信号のデータ長の情報を付加するデータ長情報付加手段と
前記データ長情報を検出するデータ長情報検出手段をさらに備え、
前記データ長情報検出手段からのデータ長情報に応じて前記第2の有効期間を開始する前記所定の時間を設定することを特徴とする
請求項1に記載の撮像装置。
Data length information adding means for adding information on the data length of the image signal to the image signal, and data length information detecting means for detecting the data length information,
The imaging apparatus according to claim 1, wherein the predetermined time for starting the second effective period is set according to data length information from the data length information detection unit.
前記画像信号を所定の係数によりスクランブルするエンコード手段と
前記エンコード手段によってスクランブルされたデータを復元するデコード手段と、をさらに備えることを特徴とする
請求項1乃至請求項3のいずれか1項に記載の撮像装置。
4. The apparatus according to claim 1, further comprising: an encoding unit that scrambles the image signal with a predetermined coefficient; and a decoding unit that restores the data scrambled by the encoding unit. 5. Imaging device.
前記同期コード検出手段は
前記同期コードを形成する所定数のシンボルのうち閾値以上のシンボルを受信した場合に
同期コードを検出したと判断することを特徴とする
請求項1乃至請求項4のいずれか1項に記載の撮像装置。
5. The synchronization code detection unit according to claim 1, wherein the synchronization code detection unit determines that a synchronization code has been detected when a symbol equal to or greater than a threshold value is received among a predetermined number of symbols forming the synchronization code. The imaging apparatus according to item 1.
基準クロックを発生する発振器と、
前記基準クロックに同期して水平同期信号及び垂直同期信号を発生する同期信号発生手段と、
前記水平同期信号及び前記垂直同期信号に同期して画像信号を読み出す画像信号読み出し手段と、
前記水平同期信号に同期して前記画像信号に同期コードを付加する同期コード付加手段と、
前記同期コードと前記画像信号を送信する送信手段と、
前記同期コードと前記画像信号を受信する受信手段と、
前記同期コードを検出する同期コード検出手段と、
前記同期コード検出手段の検出結果を有効にする期間として
前記垂直同期信号と同期して開始され同期コードの検出によって終了する第1の有効期間と、
前記第1の有効期間内に検出された同期コードの検出から所定の時間が経過した後に開始され同期コードの検出によって終了する第2の有効期間と
を定める有効期間生成回路と、
前記有効期間生成回路が定める期間の各々で同期コード検出の閾値を切り替える閾値切り替え手段を備え、
前期同期コード検出手段は、
前記同期コードを形成する所定数のシンボルのうち前記閾値以上のシンボルを受信した場合に同期コードを検出したと判断することを特徴とする
撮像装置。
An oscillator that generates a reference clock; and
Synchronization signal generating means for generating a horizontal synchronization signal and a vertical synchronization signal in synchronization with the reference clock;
Image signal readout means for reading out an image signal in synchronization with the horizontal synchronization signal and the vertical synchronization signal;
Synchronization code adding means for adding a synchronization code to the image signal in synchronization with the horizontal synchronization signal;
Transmitting means for transmitting the synchronization code and the image signal;
Receiving means for receiving the synchronization code and the image signal;
Synchronization code detection means for detecting the synchronization code;
A first validity period that is started in synchronization with the vertical synchronization signal and ends by detection of a synchronization code as a period for validating the detection result of the synchronization code detection means;
An effective period generation circuit that determines a second effective period that is started after a predetermined time has elapsed from the detection of the synchronization code detected within the first effective period and ends by detection of the synchronization code;
A threshold value switching means for switching a threshold value of synchronization code detection in each of the periods defined by the effective period generation circuit;
The synchronization code detection means in the previous period is
An imaging apparatus, wherein a synchronization code is determined to be detected when a symbol equal to or greater than the threshold is received among a predetermined number of symbols forming the synchronization code.
前記閾値切り替え手段は
前記有効期間生成回路が定める第1の有効期間では、同期コードの検出の閾値を低く設定することを特徴とする
請求項6に記載の撮像装置。
The imaging apparatus according to claim 6, wherein the threshold value switching unit sets a threshold value for detecting a synchronization code to be low during a first effective period determined by the effective period generation circuit.
前記閾値切り替え手段は
前記有効期間生成回路が定める第2の有効期間では、同期コードの検出の閾値を高く設定することを特徴とする
請求項6または請求項7に記載の撮像装置。
The imaging apparatus according to claim 6, wherein the threshold value switching unit sets a detection threshold value of the synchronization code high in a second effective period determined by the effective period generation circuit.
基準クロックを発生する発振器と、
前記基準クロックに同期して水平同期信号及び垂直同期信号を発生する同期信号発生手段と、
前記水平同期信号及び前記垂直同期信号に同期して画像信号を読み出す画像信号読み出し手段と、
前記水平同期信号に同期して前記画像信号に同期コードを付加する同期コード付加手段と、
前記同期コードと前記画像信号を送信する送信手段と、
前記同期コードと前記画像信号を受信する受信手段と、
前記同期コードを検出する同期コード検出手段と、
前記同期コード検出手段の検出結果を有効にする期間として
前記垂直同期信号と同期して開始され同期コードの検出によって終了する第1の有効期間と、
前記第1の有効期間内に検出された同期コードの検出から所定の時間が経過した後に開始され同期コードの検出によって終了する第2の有効期間と
を定める有効期間生成回路と、
前記第2の有効期間が開始することによりカウントを開始して前記第2の有効期間が終了することによりカウントをリセットするカウント手段と、
前記有効期間生成回路が定める各々の期間であるかという情報および前記カウント手段のカウント値が所定のカウント値以下であるか否かという情報により同期コード検出の閾値を切り替える閾値切り替え手段を備え、
前期同期コード検出手段は、
前記同期コードを形成する所定数のシンボルのうち前記閾値以上のシンボルを受信した場合に同期コードを検出したと判断することを特徴とする
撮像装置。
An oscillator that generates a reference clock; and
Synchronization signal generating means for generating a horizontal synchronization signal and a vertical synchronization signal in synchronization with the reference clock;
Image signal readout means for reading out an image signal in synchronization with the horizontal synchronization signal and the vertical synchronization signal;
Synchronization code adding means for adding a synchronization code to the image signal in synchronization with the horizontal synchronization signal;
Transmitting means for transmitting the synchronization code and the image signal;
Receiving means for receiving the synchronization code and the image signal;
Synchronization code detection means for detecting the synchronization code;
A first validity period that is started in synchronization with the vertical synchronization signal and ends by detection of a synchronization code as a period for validating the detection result of the synchronization code detection means;
An effective period generation circuit that determines a second effective period that is started after a predetermined time has elapsed from the detection of the synchronization code detected within the first effective period and ends by detection of the synchronization code;
Counting means for starting counting when the second effective period starts and resetting the count when the second effective period ends;
A threshold value switching means for switching a threshold value for detecting a synchronization code according to information about whether each period is determined by the effective period generation circuit and information about whether the count value of the count means is a predetermined count value or less;
The synchronization code detection means in the previous period is
An imaging apparatus, wherein a synchronization code is determined to be detected when a symbol equal to or greater than the threshold is received among a predetermined number of symbols forming the synchronization code.
前記閾値切り替え手段は
前記有効期間生成回路が定める第1の有効期間では、同期コードの検出の閾値を低く設定することを特徴とする
請求項9に記載の撮像装置。
The imaging apparatus according to claim 9, wherein the threshold value switching unit sets a threshold value for detecting a synchronization code to be low during a first effective period determined by the effective period generation circuit.
前記閾値切り替え手段は
前記有効期間生成回路が定める第2の有効期間内において前記カウンタ手段のカウント値が所定のカウント値以下である場合は、同期コードの検出の閾値を高く設定することを特徴とする請求項9または10に記載の撮像装置。
The threshold value switching means sets a synchronization code detection threshold value high when the count value of the counter means is equal to or less than a predetermined count value within a second effective period determined by the effective period generation circuit. The imaging device according to claim 9 or 10.
前記閾値切り替え手段は
前記有効期間生成回路が定める第2の有効期間内において前記カウンタ手段のカウント値が所定のカウント値より大きい場合では、同期コードの検出の閾値を低く設定することを特徴とする
請求項9乃至請求項11のいずれか1項に記載の撮像装置。
The threshold value switching means sets a low threshold value for detecting a synchronization code when the count value of the counter means is larger than a predetermined count value within a second effective period determined by the effective period generation circuit. The imaging device according to any one of claims 9 to 11.
基準クロックを発生する発振器と、
前記基準クロックに同期して水平同期信号及び垂直同期信号を発生する同期信号発生手段と、
前記水平同期信号及び前記垂直同期信号に同期して画像信号を読み出す画像信号読み出し手段と、
前記画像信号を所定の係数によりスクランブルするエンコード手段と、
前記水平同期信号に同期して前記画像信号にスクランブルされていない所定数のシンボルで形成される同期コードを付加する同期コード付加手段と、
前記画像信号にスクランブルされていない所定数のシンボルで形成される終了コードを付加する終了コード付加手段と、
前記同期コードと前記画像信号を送信する送信手段と、
前記同期コードと前記画像信号を受信する受信手段と、
前記同期コードを検出する同期コード検出手段と、
前記同期コード検出手段の検出結果を有効にする期間として
前記垂直同期信号と同期して開始され同期コードの検出によって終了する第1の有効期間と、
前記第1の有効期間内に検出された同期コードの検出から所定の時間が経過した後に開始され同期コードの検出によって終了する第2の有効期間と
を定める有効期間生成回路と、
前記エンコード手段によってスクランブルされたデータを復元するデコード手段を備え
前記終了コード付加手段は前記画像信号のデータ長に応じて前記終了コードを付加する位置を変更すること
を特徴とする撮像装置。
An oscillator that generates a reference clock; and
Synchronization signal generating means for generating a horizontal synchronization signal and a vertical synchronization signal in synchronization with the reference clock;
Image signal readout means for reading out an image signal in synchronization with the horizontal synchronization signal and the vertical synchronization signal;
Encoding means for scrambling the image signal with a predetermined coefficient;
Synchronization code adding means for adding a synchronization code formed by a predetermined number of symbols not scrambled to the image signal in synchronization with the horizontal synchronization signal;
An end code adding means for adding an end code formed of a predetermined number of unscrambled symbols to the image signal;
Transmitting means for transmitting the synchronization code and the image signal;
Receiving means for receiving the synchronization code and the image signal;
Synchronization code detection means for detecting the synchronization code;
A first validity period that is started in synchronization with the vertical synchronization signal and ends by detection of a synchronization code as a period for validating the detection result of the synchronization code detection means;
An effective period generation circuit that determines a second effective period that is started after a predetermined time has elapsed from the detection of the synchronization code detected within the first effective period and ends by detection of the synchronization code;
An imaging apparatus comprising: decoding means for restoring data scrambled by the encoding means, wherein the end code adding means changes a position where the end code is added according to a data length of the image signal.
前記終了コードは
前記同期コードを形成する所定のシンボルと異なるシンボルで形成されることを特徴とする
請求項13に記載の撮像装置。
The imaging apparatus according to claim 13, wherein the end code is formed of a symbol different from the predetermined symbol forming the synchronization code.
前記垂直同期信号に同期して前記画像信号の先頭に特定のパターンを繰返し送信することを特徴とする
請求項1乃至請求項14のいずれか1項に記載の撮像装置。
15. The imaging apparatus according to claim 1, wherein a specific pattern is repeatedly transmitted at the head of the image signal in synchronization with the vertical synchronization signal.
前記特定のパターンは、所定数以下のエラーであれば同期コードと判定しないデータであることを特徴とする
請求項15に記載の撮像装置。
16. The imaging apparatus according to claim 15, wherein the specific pattern is data that is not determined as a synchronization code if an error is equal to or less than a predetermined number.
JP2018031688A 2018-02-26 2018-02-26 Imaging apparatus and signal processing method in the same Pending JP2019149609A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018031688A JP2019149609A (en) 2018-02-26 2018-02-26 Imaging apparatus and signal processing method in the same

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018031688A JP2019149609A (en) 2018-02-26 2018-02-26 Imaging apparatus and signal processing method in the same

Publications (1)

Publication Number Publication Date
JP2019149609A true JP2019149609A (en) 2019-09-05

Family

ID=67850801

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018031688A Pending JP2019149609A (en) 2018-02-26 2018-02-26 Imaging apparatus and signal processing method in the same

Country Status (1)

Country Link
JP (1) JP2019149609A (en)

Similar Documents

Publication Publication Date Title
US8023002B2 (en) Imager, imaging circuit, and image processing circuit
US7340655B2 (en) Skew adjustment circuit, skew adjustment method, data synchronization circuit, and data synchronization method
JP5936030B2 (en) Information processing apparatus, information processing method, and program
JP2013078377A5 (en)
US9847792B2 (en) Communication apparatus, image forming apparatus, communication method, and computer-readable storage medium
JP5850047B2 (en) Data receiving apparatus, marker information extracting method, and marker position detecting method
JP2013078378A5 (en)
US9503253B2 (en) Serial data transmission circuit and reception circuit, transmission system using the same, electronic device, and serial data transmission method
JP2017011470A (en) Serial communication device and serial communication method
EP2684324B1 (en) Apparatus and method for deskewing serial data transmissions
JP5217919B2 (en) Serial communication device, communication control method, communication control program
JP2008005123A (en) Video data transmission device, video data receiving device, and video data transmission system
JP2020088671A (en) Imaging device and signal processing method in the device
JP2019149609A (en) Imaging apparatus and signal processing method in the same
JP2015080702A (en) Endoscope apparatus
KR950007977B1 (en) Method and arrangement for the synchronisation of digital information signals
US10057524B2 (en) Image capturing apparatus
JP2020096281A (en) Imaging device, data processing device, and data processing method
JP2018082282A5 (en)
JP2017050734A (en) Serial communication device, communication system, and communication method
JP3612219B2 (en) Image data transmission / reception processing method and apparatus
JP3465386B2 (en) Frame synchronization circuit and encoding / decoding processing circuit using the same
JP2016111557A (en) Endoscope apparatus
JP2019036833A (en) Signal processing apparatus and signal processing method
JP2022037647A (en) High-speed serial transmission circuit

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20191125