JP2004038541A - Memory check system, memory check method, signal processor, memory check method of signal processor, and memory check program - Google Patents

Memory check system, memory check method, signal processor, memory check method of signal processor, and memory check program Download PDF

Info

Publication number
JP2004038541A
JP2004038541A JP2002194452A JP2002194452A JP2004038541A JP 2004038541 A JP2004038541 A JP 2004038541A JP 2002194452 A JP2002194452 A JP 2002194452A JP 2002194452 A JP2002194452 A JP 2002194452A JP 2004038541 A JP2004038541 A JP 2004038541A
Authority
JP
Japan
Prior art keywords
parity
program
memory
check
check program
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2002194452A
Other languages
Japanese (ja)
Other versions
JP4135413B2 (en
Inventor
Isao Miyai
宮井 功
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.)
Sony Corp
Original Assignee
Sony 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 Sony Corp filed Critical Sony Corp
Priority to JP2002194452A priority Critical patent/JP4135413B2/en
Publication of JP2004038541A publication Critical patent/JP2004038541A/en
Application granted granted Critical
Publication of JP4135413B2 publication Critical patent/JP4135413B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Techniques For Improving Reliability Of Storages (AREA)
  • For Increasing The Reliability Of Semiconductor Memories (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To precisely check a program or coefficient data on a RAM at high speed. <P>SOLUTION: A program 22 stored in a block having a prescribed size checks a DSP program 23 for every block, compares an operation result 41 with a corresponding parity code 40, and sets a fixed value 44, when the both are matched, or the operation result 41, when the both are not matched, to a register 46. The program 22 on the RAM 20 is similarly checked in the block unit, and sets a fixed value 34, when an operation result 31 is matched to a corresponding parity code 30, or the operation result 31, when the both are not matched, to a register 36. A host determines the validity of the parity code 21 and the programs 22 and 23 on the RAM 20 based on the values of the registers 36 and 46. The host supplies right data to a DSP 2 based on the determination result to correct the content of the RAM 20. The program 22 and the program 23 are alternately checked for each block, and the validity is regularly kept. <P>COPYRIGHT: (C)2004,JPO

Description

【0001】
【発明の属する技術分野】
この発明は、メモリに記憶されたデータやプログラムのチェックを行うメモリチェックシステム、メモリチェック装置および方法、ならびに、メモリチェックプログラムに関する。
【0002】
【従来の技術】
従来から、例えばディジタルフィルタを用いた信号処理を行うために、DSP(Digital Signal Processor)が多く用いられている。DSPは、ROM(Read Only Memory)やRAM(Random Access Memory)に記憶されたプログラム(インストラクション)や係数データに基づき、加減乗除を行う演算器を構成し、入力されたディジタル信号に対して信号処理を行うようにされている。特に、RAMにプログラムや係数データを記憶するタイプのDSPは、RAMの記憶内容を書き換えることでDSPの機能をフレキシブルに変更することができるので、近年では需要が非常に多い。このようなDSPでは、例えば、DSPを制御するマイクロコンピュータなどから、インストラクションのデータや係数データをダウンロードし、RAMに記憶させるのが一般的である。
【0003】
DSPは、プログラムコードが記憶されるインストラクションRAMと、係数データが記憶される係数RAMとを有し、これらがバスにより接続される。また、RAMは、インストラクションRAMと係数RAM、さらに、係数RAMは、例えばX係数データを格納するRAMおよびY係数データを格納するRAMがそれぞれ物理的に独立され、各RAMに接続されるバスも、それぞれ物理的に独立した構成とされる。
【0004】
これにより、DSPでは、各RAMのデータの読み出しや書き込みを並列的に行うことができ、例えばX係数およびY係数をRAMから読み込んで演算処理し、演算結果をRAMに一旦記憶させる、といったような一連の処理を、一つのコマンドで実行することができる。一方、CPU(Central Processing Unit)を用いた構成では、CPUとRAMとが1本のバスで接続されるのが一般的とされ、上述の処理を行うために、各係数データ読み出し、演算処理、演算処理結果のRAMへの格納などのそれぞれの処理に応じた複数のコマンドが必要とされる。したがって、DSPは、CPUに比べ、積和演算を中心とした処理に対して高速に動作することができる。
【0005】
RAMに格納されたデータは、静電気やノイズなどの影響で部分的に破壊される可能性がある。また、RAMにデータを書き込む際にタイミングが合わないなど、書き込み途中にエラーが発生した場合、誤ったデータが格納されてしまうことになる。また、プログラム自体にバグがあり、プログラム実行中にRAMの領域を壊してしまうことも起こり得る。DSPのプログラムや係数データをRAMに格納してDSPを用いる場合、RAMに格納された内容にエラーがあると、DSPが期待される動作をしないばかりか、DSPが暴走してしまうおそれがある。
【0006】
【発明が解決しようとする課題】
そこで、従来から、DSPの暴走を検出したり、RAMに格納された内容をチェックする方法が幾つか考えられてきた。一例として、ある一定周期毎にプログラムカウンタをリセットすることにより、プログラムの異常ループや暴走を検出するウォッチドッグタイマが知られている。これによれば、例えばプログラムの実行箇所を示すプログラムカウンタが異常を来しているようなときに、これを検出することができる。
【0007】
また、他の例として、特開平5−313908号公報には、外部メモリに予め実行用プログラムの異常を検出するためのプログラム異常検出用プログラムを格納しておき、このプログラム異常検出用プログラムを用いてRAM上の誤りを検出する方法が開示されている。プログラム異常検出用プログラムを実行用プログラムと共に外部メモリからRAMにダウンロードする。このプログラム異常検出用プログラムにより、RAM上の実行用プログラムおよびプログラム異常検出用プログラムの異常の有無を調べ、異常が検出された実行用プログラムやプログラム異常検出用プログラムを修正する。
【0008】
プログラム異常検出用プログラムは、例えばRAMに格納されたプログラムデータや係数データに対してチェックサムやXORなどを求め、求められた値と予め用意された正しいチェックサム値やXOR結果といったチェックコードとを比較することにより、プログラムやデータの検査を行う。
【0009】
しかしながら、この方法では、RAMのアドレス単位でアクセスを行い、RAMに記憶されたデータを読み出した後、読み出されたデータを誤り検出のプログラムや誤り検出手段に転送して誤りを検出しているため、CPUやDSPの処理能力の向上に伴い大量のデータやプログラムコードを容易に処理可能となった場合、チェックしなければならないRAMの容量が増大し、チェック時間に非常に多くの時間を費やさねばならないという問題点があった。
【0010】
また、この方法では、プログラムの異常を検出するためのプログラム異常検出用プログラムおよびチェックコードと、検出の対象となる実行用プログラムおよび係数データとが同一のRAM上に存在する。そのため、静電気などの影響で、RAMに記憶されたプログラム異常検出用プログラムおよびチェックコードそのものや、これらと共に実行用プログラムおよび係数データが破壊されてしまう可能性があるという問題点があった。
【0011】
さらに他の例として、特開2000−339230号公報には、DMA(Direct Memory Access)を用いてRAM上の記憶情報を誤り検出手段に直接的に転送して、RAMに記憶された内容に誤りが含まれるか否かを判定する方法が開示されている。この方法によれば、RAMに格納されたプログラムデータのみならず、RAMに格納された係数データなどの誤り検出も可能とされる。そのため、RAMに格納されたデータに基づき動作するDSPやCPUが暴走に至らないようなデータ誤りも検出することができる。
【0012】
また、この特開2000−339230号公報の方法によれば、RAMに格納されたプログラムデータや係数データなどの誤りを検出する際に、検出のためのプログラムをCPU上で実行させる必要が無いため、データ誤り検出を考慮してCPUの処理能力を多めに見積もる必要が無いという利点がある。また、誤り検出手段をRAMとは別に有するため、RAM内容が破壊されても、誤り検出自体は問題なく行われる。
【0013】
しかしながら、この方法でも、上述したような、RAM容量の増大に伴いチェック時間が増加してしまうという問題点があった。
【0014】
したがって、この発明の目的は、RAMに格納されたプログラムデータや係数データのチェックおよび修正を、高速且つ正確に行うことができるメモリチェックシステム、メモリチェック装置および方法、ならびに、メモリチェックプログラムを提供することにある。
【0015】
【課題を解決するための手段】
この発明は、上述した課題を解決するために、書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置の書き換え可能なメモリの内容をチェックするメモリチェックシステムにおいて、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置と、ホスト装置と接続され、ホスト装置から供給された実行用プログラム、パリティチェックプログラムおよびパリティコードを格納する書き換え可能なメモリを有し、書き換え可能なメモリに格納された実行用プログラムに基づき信号処理を行う信号処理装置とを備え、信号処理装置では、書き換え可能なメモリに格納されたパリティチェックプログラムにより、書き換え可能なメモリに格納された実行用プログラムおよびパリティチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行い、パリティ演算の結果に基づいた検出コードを出力するようにしたことを特徴とするメモリチェックシステムである。
【0016】
また、この発明は、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置と接続され、ホスト装置から供給された実行用プログラム、パリティチェックプログラムおよびパリティコードを格納する書き換え可能なメモリを有し、書き換え可能なメモリに格納された実行用プログラムに基づき信号処理を行う信号処理装置の書き換え可能なメモリの内容をチェックするメモリチェック方法において、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置から供給された実行用プログラム、パリティチェックプログラムおよびパリティコードを格納する書き換え可能なメモリに格納されたパリティチェックプログラムにより、書き換え可能なメモリに格納された実行用プログラムおよびパリティチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、パリティ演算のステップによるパリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップとを有することを特徴とするメモリチェック方法である。
【0017】
また、この発明は、書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置において、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが格納される書き換え可能なメモリと、書き換え可能なメモリに格納された実行用プログラムに基づき信号処理を行う信号処理手段とを備え、書き換え可能なメモリに格納されたパリティチェックプログラムにより、書き換え可能なメモリに格納された実行用プログラムおよびパリティチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行い、パリティ演算の結果に基づいた検出コードを出力するようにしたことを特徴とする信号処理装置である。
【0018】
また、この発明は、書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置のメモリチェック方法において、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが格納される書き換え可能なメモリに格納されたパリティチェックプログラムにより、書き換え可能なメモリに格納された実行用プログラムおよびパリティチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、パリティ演算のステップによるパリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップとを有することを特徴とする信号処理装置のメモリチェック方法である。
【0019】
また、この発明は、書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置の書き換え可能なメモリに対するメモリチェックを実行させるメモリチェックプログラムにおいて、実行用プログラムと、パリティ演算によりメモリをチェックするメモリチェックプログラムと、実行用プログラムおよびメモリチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが書き換え可能なメモリに格納され、書き換え可能なメモリ上の実行用プログラムおよびメモリチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、パリティ演算のステップによるパリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップとを有することを特徴とするメモリチェックプログラムである。
【0020】
上述したように、請求項1および7に記載の発明は、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置と、ホスト装置と接続され、ホスト装置から供給された実行用プログラム、パリティチェックプログラムおよびパリティコードを格納する書き換え可能なメモリを有し、書き換え可能なメモリに格納された実行用プログラムに基づき信号処理を行う信号処理装置とを備え、信号処理装置では、書き換え可能なメモリに格納されたパリティチェックプログラムにより、書き換え可能なメモリに格納された実行用プログラムおよびパリティチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行い、パリティ演算の結果に基づいた検出コードを出力するようにしているため、メモリチェックに要する時間が短縮されると共に、実行用プログラムのチェックとパリティチェックプログラム自身のチェックとを交互に行うことができる。
【0021】
また、請求項8および13に記載の発明は、実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが格納される書き換え可能なメモリと、書き換え可能なメモリに格納された実行用プログラムに基づき信号処理を行う信号処理手段とを備え、書き換え可能なメモリに格納されたパリティチェックプログラムにより、書き換え可能なメモリに格納された実行用プログラムおよびパリティチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行い、パリティ演算の結果に基づいた検出コードを出力するようにしているため、メモリチェックに要する時間が短縮されると共に、実行用プログラムのチェックとパリティチェックプログラム自身のチェックとを交互に行うことができる。
【0022】
また、請求項14に記載の発明によるメモリチェックプログラムは、実行用プログラムと、パリティ演算によりメモリをチェックするメモリチェックプログラムと、実行用プログラムおよびメモリチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが書き換え可能なメモリに格納され、書き換え可能なメモリ上の実行用プログラムおよびメモリチェックプログラムに対して、書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、パリティ演算のステップによるパリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップとを有するため、メモリチェックに要する時間が短縮されると共に、実行用プログラムのチェックと自分自身のチェックとを交互に行うことができる。
【0023】
【発明の実施の形態】
以下、この発明の実施の一形態について説明する。この発明では、DSP(Digital Signal Processor)で用いられる実行用プログラムや係数データを、ホストとなるマイクロコンピュータ(以下、ホストマイコンと称する)が有するメモリからDSPのRAM(Random Access Memory)にダウンロードし、DSPが有するRAMに格納するようにした構成において、ダウンロードされDSPのRAMに格納された実行用プログラムおよびデータをパリティ演算によりチェックするパリティチェックプログラムを、DSP実行用プログラムおよびデータと共にDSPのRAMにダウンロードおよび格納し、DSP側で、ダウンロードされたパリティチェックプログラムを用いてRAMに格納された実行用プログラムおよび係数データ、ならびに、パリティチェックプログラム自身のチェックを行う。
【0024】
このとき、この発明によれば、RAMに格納された実行用プログラムおよびパリティチェックプログラムに対するパリティチェックプログラムによるチェックは、RAMの単位アドレスの複数のサイズからなるブロック毎に行われる。
【0025】
実行用プログラムおよび係数データ、ならびに、パリティチェックプログラムのチェックが所定サイズのブロック単位で行われるため、チェックに要する時間を短縮できる。また、パリティチェックプログラム自身のチェックもブロック単位で行うため、RAMに格納された実行用プログラムおよび係数データとパリティチェックプログラムとを、ブロック毎に交互にチェックすることができる。これにより、パリティチェックプログラム自身が正常か否かを常にチェックすることができる。
【0026】
さらに、この発明では、ホストマイコン側のメモリに格納されているチェックプログラムを用いて、DSP側にダウンロードされRAMに格納された実行用プログラムおよび係数データ、ならびに、チェックプログラムのチェックを所定サイズのブロック単位で行うようにしている。チェックをDSP側およびホストマイコン側の双方で行うため、チェックに用いるチェックコードと、チェックプログラムとの何方が正常でないかを判断することができる。
【0027】
図1は、この発明の実施の一形態に適用可能なDSPシステムの一例の構成を概略的に示す。ホストマイコン1は、例えば、CPU10およびRAMおよび/またはROM(Read Only Memory)によるメモリ11を有する、マイクロコンピュータである。DSP2は、RAM20を有し、RAM20に格納された実行用プログラムや係数データに基づき動作する。DSP2の実行用プログラムは、DSP2が解読可能なインストラクションコードによって記述される。
【0028】
ホストマイコン1とDSP2とがアドレスバス3およびデータバス4で接続される。例えばホストマイコン1からDSP2に対して、DSP2の動作を指示するコマンドなどがバス3、4を介して送信され、ホストマイコン1によりDSP2が制御される。
【0029】
ホストマイコン1のメモリ11には、DSP2の実行用プログラムであるDSPプログラム12や係数データ(図示しない)などが予め格納される。このホストマイコン1のメモリ11に格納されるDSPプログラムも、上述したインストラクションコードを用いて記述される。以下では、DSPプログラムおよび当該DSPプログラムで用いられる係数データを、まとめてDSPプログラムと称する。
【0030】
ホストマイコン1からDSP2に対してDSPプログラムがアップロードされ、DSP2のRAM20に格納される。例えば、ホストマイコン1からDSP2に対して、アドレスバス3を介してRAM20のアドレスが指定される。ホストマイコン1からDSP2に対して、データバス4を介してDSPプログラムがアップロードされる。アップロードされたDSPプログラムは、アドレスバス3を用いて指定されたアドレスに基づきRAM20に書き込まれる。
【0031】
DSP2は、ホストマイコン1からダウンロードされたDSPプログラムに従った動作を行う。ホストマイコン1からDSP2にアップロードされるDSPプログラムの内容を変更することで、DSP2に異なる処理を行わせることができる。
【0032】
さらに、ホストマイコン1のメモリ11には、DSP2にアップロードされRAM20に格納されたDSPプログラム12のパリティチェックを行うためのパリティチェックプログラム13と、メモリ11に格納されたDSPプログラム12およびパリティチェックプログラム13に対してパリティチェックプログラム13を用いて予めパリティ演算を行った結果であるパリティコード14とが格納される。パリティチェックプログラム13は、DSP2において実行可能なように、上述したインストラクションコードで記述される。これらパリティチェックプログラム13およびパリティコード14は、上述のDSPプログラム12と共に、ホストマイコン1からDSP2にアップロードされ、RAM20に格納される。
【0033】
図2は、RAM20における一例のデータ配置を示す。図2の例では、RAM20が64kB(キロバイト)の容量を有しており、アドレスが「0x0000」乃至「0x10000」で指定される。なお、アドレスの記述において、「0x」は、記述が16進表記であることを示す。アドレス「0x0400」乃至「0xAFFF」は、DSPプログラム23が格納される。アドレス「0xB000」乃至「0xFFFF」は、バッファ領域24である。バッファ領域24は、DSP2においてDSPプログラム23が動作する際に用いられる領域であって、DSPプログラムの実行に伴い内容が変化される。
【0034】
アドレス「0x0000」乃至「0x02FF」は、パリティコード21が格納される。アドレス「0x0300」乃至「0x03FF」は、パリティチェックプログラム22が格納される。パリティコード21は、RAM20における、バッファ領域24を除く全ての領域のデータに対するパリティコードとなる。すなわち、パリティコード21は、RAM20のバッファ領域24を除く全ての領域のデータに対して、パリティチェックプログラム22を用いて予めパリティ演算を行った結果に対応する。バッファ領域24は、上述したようにDSPプログラムの実行に伴い内容が変化されるため、パリティが確定しない。
【0035】
なお、RAM20の容量は、64kBに限定されるものではなく、この図2に示されるアドレス配置も、一例であって、この例に限定されるものではない。
【0036】
この発明では、パリティチェックプログラム22によるパリティチェック演算を、所定サイズのブロックを単位として、1ブロック毎に行う。例えば、RAM20における単位アドレスが複数集合したサイズで1ブロックが構成される。一例として、パリティチェックプログラム22が格納される領域に対応するサイズのブロックを1単位ブロックとする。RAM20の容量が64kBであって、パリティチェックプログラム22がアドレス幅「0x0100」を有するこの例では、アドレス幅「0x0100」に対応する、サイズが256バイトのブロックが1単位ブロックとされる。したがって、図2の例では、パリティコード21が3ブロック、DSPプログラム23が172ブロックでそれぞれ構成されることになる。
【0037】
パリティチェックプログラム22によるパリティチェック演算は、このサイズが256バイトの1ブロックを単位として、1ブロック毎に行われる。予め計算されRAM20に格納されるパリティコード21も、DSPプログラム23およびパリティチェックプログラム22がこの1ブロックを単位としてパリティ演算されたものである。RAM20に対して所定にアドレスを指定することで、パリティコード21から、ブロック単位のパリティ演算に対応するパリティコードを取り出すことができるようにされている。
【0038】
なお、上述では、ブロックのサイズがパリティチェックプログラム22のサイズと同一であるように説明したが、これはこの例に限定されない。ブロックのサイズは、RAM20のアドレス指定の単位で任意に設定することができる。例えば、パリティチェックプログラム22が複数のブロックに格納されるようなブロックサイズとしてもよい。これに限らず、例えば、アドレス指定の最小単位、例えば図2における1行をブロックとすることも可能である。
【0039】
次に、この発明の実施の一形態によるパリティチェックの動作について、図3を用いて説明する。パリティチェックに先立って、ホストマイコン1からDSP2に対して、プログラムチェック開始コマンドが発行される。そして、ホストマイコン1からDSP2に対して、チェックを行いたいブロックが指示される。例えば、チェックを行いたいブロックのRAM20における先頭アドレスがホストマイコン1により指示される。DSP2では、この指示に基づきチェックを行うブロックが確認される。ブロックが確認されたら、RAM20に格納されるパリティチェックプログラム22が実行され、指定されたブロックに対するパリティチェックが実行される。
【0040】
なお、パリティチェックは、様々な方法により行うことが可能である。例えば、偶数パリティや奇数パリティといった単純パリティを用いてパリティチェックを行うことが考えられる。パリティチェックプログラム22により単純パリティ演算を行い、演算結果をブロック毎に積算した値を出力する。これに限らず、パリティチェックをXOR(Exclusive OR)を用いて行うこともできる。ブロックのデータに対して、予め用意された所定のビット列を用いてXORを求める。XORによるチェックは、より高速に処理を行うことができる利点がある。また、パリティチェック方法としてCRC(cyclic redundancy check)を用いることもできる。
【0041】
一例として、パリティチェックプログラム22によりDSPプログラム23の4ブロック目のパリティチェックを行うものとする。先ず、パリティチェックプログラム22により、DSPプログラム23の4ブロック目のパリティ演算が行われ、パリティ演算結果41が得られる。続いてRAM20から、パリティコード21のうち、パリティチェック対象である、DSPプログラム23の4ブロック目のパリティ演算結果に対応するパリティコード40が取り出される。この取り出されたパリティコード40とパリティ演算結果41とが比較処理42により比較される。
【0042】
若し、比較処理42によるパリティコード40およびパリティ演算結果41の比較の結果、両者が同一の値を示しているとされた場合には、判断処理43により、RAM20上のDSPプログラム23の4ブロック目には誤りが無かったと判断され、その旨を示す正解固定値44がレジスタ46にセットされる。例えばRAM20のバッファ領域24内の所定領域をレジスタ46として用いることができる。
【0043】
一方、比較処理42によるパリティコード40およびパリティ演算結果41の比較の結果、両者が異なる値であるとされた場合には、判断処理43により、パリティコード40および/またはパリティ演算結果41に誤りが存在すると判断され、パリティチェックプログラム22によるパリティ演算結果41がレジスタ46にセットされる。
【0044】
すなわち、レジスタ46には、パリティチェックプログラム22のパリティ演算結果41に基づき、パリティチェックの対象となるブロック(この例では、DSPプログラム23の4ブロック目)に誤りが無いと判断されれば正解固定値44がセットされ、誤りがあると判断されれば、誤りがあると判断された当該パリティ演算の演算結果41そのものがレジスタ46にセットされる。
【0045】
DSPプログラム23の1ブロック分のパリティチェックが終了すると、次に、RAM20に格納されたパリティチェックプログラム22に対するパリティチェックが行われる。パリティチェックプログラム22により、パリティチェックプログラム22が格納されているブロック(この例ではアドレス「0x0300」乃至「0x03FF」のブロック)を対象に、パリティ演算を行なわれ、パリティ演算結果31が得られる。続いてRAM20から、パリティコード21のうち、パリティチェックプログラム22のパリティ演算結果に対応するパリティコード30が取り出される。この取り出されたパリティコード30とパリティ演算結果31とが比較処理32により比較される。
【0046】
若し、比較処理32によるパリティコード30およびパリティ演算結果31の比較の結果、両者が同一の値を示ている場合には、判断処理33によりRAM20上のパリティチェックプログラム22には誤りが無かったと判断され、その旨を示す正解固定値34がレジスタ36にセットされる。例えばRAM20のバッファ領域24の、上述したレジスタ46として用いられた領域とは異なる領域がレジスタ36として用いられる。
【0047】
一方、比較処理32によるパリティコード30およびパリティ演算結果31の比較の結果、両者が異なる値であるとされた場合には、判断処理43により、パリティコード30および/またはパリティ演算結果31に誤りが存在すると判断され、パリティチェックプログラム22によるパリティ演算結果31がレジスタ36にセットされる。
【0048】
すなわち、レジスタ36には、上述のレジスタ46と同様に、パリティチェックプログラム22のパリティ演算結果31に基づき、パリティチェックの対象となるRAM20上のパリティチェックプログラム22に誤りが無いと判断されれば正解固定値34がセットされ、誤りがあると判断されれば、誤りがあると判断された当該パリティ演算のパリティ演算結果31そのものがセットされる。
【0049】
こうして、DSPプログラム23の4ブロック目およびパリティチェックプログラム22そのものの、それぞれ1ブロック分のパリティチェック処理が終了すると、DSP2からホストマイコン1に対して、パリティチェックが行われたブロックのRAM20におけるアドレスが通知される。
【0050】
ホストマイコン1により、DSP2から通知された、パリティチェックが行われたブロックのアドレスが受け取られると、DSP2のRAM20におけるレジスタ36および46にセットされたデータがホストマイコン1により取り込まれる。そして、取り込まれたレジスタ36および46のデータに基づき、RAM20にアップロードしたデータの修正が必要か否かの判断処理が行われる。データ修正が必要であると判断されれば、RAM20に対するデータの再アップロードが行われ、RAM20に格納されたデータが修正される。
【0051】
なお、正解固定値34および44は、パリティチェックプログラム22によるパリティ演算の演算結果と重複しない所定の値が用いられる。
【0052】
図4は、ホストマイコン1による、パリティチェック結果に基づく一例のデータ修正処理を示すフローチャートである。最初のステップS10で、DSP2から送信された、パリティチェックを行ったブロックのアドレスがホストマイコン1に受信される。次のステップS11で、ホストマイコン1により、レジスタ36にセットされた、パリティチェックプログラム22に対するパリティチェック結果が取り込まれる。
【0053】
ステップS12で、ステップS11でレジスタ36から取り込まれたパリティチェック結果が正解固定値34であるか否かが判断される。若し、レジスタ36から取り込まれた値が正解固定値34であると判断された場合には、RAM20に格納されたパリティチェックプログラム22およびパリティコード21には問題が無かったと判断され、処理はステップS13に移行する。
【0054】
一方、ステップS12でレジスタ36から取り込まれた値が正解固定値34ではないと判断されれば、処理はステップS16に移行される。ステップS16では、ホストマイコン1のメモリ11内のパリティコード14のうち、パリティチェックプログラム22、すなわちメモリ11内のパリティチェックプログラム13に対するパリティチェック結果に対応するパリティコードが取り出される。そして、ステップS17において、取り出されたパリティコードと、上述のステップS11によりレジスタ36から取り込まれた値とが一致しているか否かが判断される。
【0055】
若し、両者が一致していると判断されれば、RAM20内のパリティチェックプログラム22は正しいが、パリティコード21が誤っていると考えられる。すなわち、パリティチェックプログラム22に対するパリティ演算結果31が正しい値となっても、比較処理32で当該パリティ演算結果31と比較されるパリティコード30が誤った値であれば、当該パリティ演算結果31とパリティコード30とが一致せず、レジスタ36に正解固定値34がセットされない。このときには、レジスタ36に対してパリティチェックプログラム22に対する正しいパリティ演算結果がセットされることになる。
【0056】
この場合、処理はステップS18に移行し、ホストマイコン1のメモリ11に格納されるパリティコード14のうちパリティチェックプログラム22(パリティチェックプログラム13)に対するパリティ演算結果に対応するパリティコードが取り出され、DSP2に送信され再アップロードされる。再アップロードされたこのパリティコードは、上述のパリティコード30としてRAM20の対応する領域に書き込まれる。パリティコードの再アップロードが完了すると、処理はステップS15に移行される。
【0057】
なお、上述では、パリティコードの再アップロードに際して、メモリ11に格納されるパリティコード14のうち対応するデータだけを取り出し、DSP2に送信しているが、これはこの例に限定されない。メモリ11に格納されるパリティコード14のうち対応するデータを含むブロックを、ホストマイコン1からDSP2に送信してもよい。また、メモリ11に格納されるパリティコード14を全てDSP2に送信することもできる。
【0058】
ステップS15では、次のブロックに対するチェック処理が準備される。すなわち、ホストマイコン1からDSP2に対して、次にチェックを行うブロックのアドレスが通知される。例えば、この例では、RAM20におけるDSPプログラム23の5ブロック目のアドレスと、パリティチェックプログラム22のアドレスとがDSP2に対して通知される。
【0059】
アドレスが通知されると、DSP2において上述したようにして、RAM20における通知されたアドレスのブロックに対してパリティ演算が行われ、パリティ演算結果に基づきレジスタ36および46に正解固定値34、44やパリティ演算結果がセットされる。そして、ホストマイコン1では、処理はステップS10に移行され、レジスタ36および46にセットされた値に基づくチェック処理が行われる。
【0060】
この発明の実施の一形態では、このように、RAMに格納されたDSPプログラム23およびパリティチェックプログラム22に対するチェックを、ブロック単位で交互に行うようにしている。これにより、パリティチェックプログラム22を常に正常な状態に保ちながらDSPプログラム23に対するチェックを行うことができ、チェック結果の信頼性が向上される。
【0061】
一方、上述のステップS17で、両者が一致していないと判断された場合、RAM20上のパリティチェックプログラム22が誤っていると判断される。またこの場合、さらに、RAM20上のパリティチェックプログラム22と共にパリティコード30も誤っている可能性がある。そこで、処理はステップS19に移行し、ホストマイコン1のメモリ11内に格納されたパリティチェックプログラム13がDSP2に対して再アップロードされる。再アップロードされたこのパリティチェックプログラム13は、パリティチェックプログラム22としてRAM20に格納される。パリティチェックプログラムの再アップロードが完了されると、処理はステップS15に移行される。
【0062】
このパリティチェックプログラム22に対するパリティチェック処理は、DSPプログラム23に対して行われるパリティチェック処理に対して、ブロック毎に交互に実行される。したがって、上述のステップS19でパリティチェックプログラム22の再アップロードを行った後に、再び同様のチェック処理が再アップロードされたチェックプログラム22に対して実行されることになる。その際に、上述のステップS17の判断においてパリティコード30に誤りがあったか否かを判定することができる。
【0063】
上述したように、ステップS12において、レジスタ36から取り込まれた値が正解固定値34であると判断された場合、RAM20上のパリティチェックプログラム22には誤りが無いとされ、処理はステップS13に移行され、RAM20のDSPプログラム23に対するブロック単位での修正処理が行われる。
【0064】
ステップS13では、ホストマイコン1により、レジスタ46にセットされた、DSPプログラム23のチェック対象とされるブロック(DSPプログラムの4ブロック目とする)に対するパリティチェック結果が取り込まれる。次のステップS14で、ステップS13でレジスタ46から取り込まれたパリティチェック結果が正解固定値44であるか否かが判断される。若し、レジスタ46から取り込まれたチェック結果が正解固定値44であると判断された場合には、RAM20に格納されたDSPプログラム23の4ブロック目には問題が無かったと判断され、処理はステップS15に移行される。
【0065】
一方、ステップS14で、レジスタ46から取り込まれた値が正解固定値44ではないと判断されれば、処理はステップS20に移行される。ステップS20では、ホストマイコン1のメモリ11内のパリティコード14のうち、パリティ演算の対象であるDSPプログラム23の4ブロック目、すなわちメモリ11内のDSPプログラム12における対応ブロックに対するパリティコードが取り出される。そして、ステップS21において、取り出されたパリティコードと、上述のステップS13によりレジスタ46から取り込まれた値とが一致しているか否かが判断される。
【0066】
若し、両者が一致していると判断されれば、上述のパリティチェックプログラム22に対する判断の場合と同様にして、RAM20内のDSPプログラム23の4ブロック目は正しいが、パリティコード21が誤っていると考えられる。この場合、処理はステップS22に移行し、ホストマイコン1のメモリ11に格納されるパリティコードのうちDSPプログラム23の4ブロック目に対するパリティ演算結果に対応するパリティコードが取り出され、DSP2に再アップロードされる。再アップロードされたこのパリティコードは、上述のパリティコード40としてRAM20の対応する領域に書き込まれる。パリティコードの再アップロードが完了すると、処理はステップS15に移行される。
【0067】
一方、ステップS21で、両者が一致していないと判断された場合、パリティチェック対象であるDSPプログラム23の4ブロック目が誤っていると判断される。そこで、処理はステップS23に移行され、ホストマイコン1のメモリ11内に格納されたDSPプログラム12における、DSPプログラム23の4ブロック目に対応するブロックがDSP2に対して再アップロードされる。再アップロードされたこのブロックは、RAM20の対応する位置に書き込まれる。この際アップロード処理が完了されると、処理はステップS15に移行される。
【0068】
なお、図3および図4を用いて説明した、この発明の実施の一形態によるメモリチェックは、DSP2の起動時に行うことができる。例えば、ホストマイコン1からDSP2に対して処理開始が指示されてから、実際にDSP2における処理が開始されるまでの間に、一連のメモリチェック処理が行われる。これに限らず、DSP2の稼働中においてDSP2本来の処理が行われていないときに、メモリチェック処理を実行することもできる。また、メモリチェック処理は、DSP2の稼働中において実行可能なタイミングで随時行ってもよいし、DSP2の起動時などに1度だけ行ってもよい。さらに、DSP2の処理能力に余裕があれば、DSP2の動作中に本来の処理に対するバックグラウンドとして、常時、メモリチェック処理を行うようにしてもよい。
【0069】
さらにまた、一連のメモリチェック動作において、RAM20の全てのブロックに対してチェックを行う必要は無い。例えば、RAM20途中のブロックまでチェックを行った時点で一時的に処理を中断し、再びチェック可能となったときに、処理が中断されたブロックから再びチェック処理を再開するようにできる。
【0070】
上述では、この発明の実施の一形態によるメモリチェックがホストマイコン1およびDSP2で行われるように説明したが、これはこの例に限定されず、この発明に本質的な部分はDSP2側だけでも実現可能である。例えば、上述の図4において、データの再アップロード処理、すなわち、ステップS18、S19、S22およびS23の処理を除いた処理は、DSP2のみで実行可能である。パリティコードやパリティチェックプログラム、DSPプログラムの再アップロードは、DSPからホストマイコンに対して再アップロード要求を出すことで可能である。また、DSPのRAMに、同一のパリティコードを複数、格納することで、図4におけるステップS16およびS17、ならびに、ステップS20およびS21の、パリティチェックプログラムによるパリティ演算結果と、正しいパリティコードとを比較する処理を代用することが可能である。
【0071】
【発明の効果】
以上説明したように、この発明は、DSPのRAMに対するパリティチェックを、所定サイズのブロック毎に行うようにしているため、DSPとホストマイコンとの通信回数などが減少するため、チェック時間を短縮できる効果がある。
【0072】
また、DSPのRAMにアップロードしたDSPプログラムおよびパリティチェックプログラムについて、アップロードされたパリティチェックプログラムにより、RAMに格納されたパリティチェックプログラムに対するパリティチェックが行われる。このときには、パリティチェックプログラム自身に誤りが無いことが前提となる。したがって、DSPプログラムのパリティチェックを行う前に、パリティチェックプログラム自身のチェックを行う必要がある。
【0073】
この発明の実施の一形態では、パリティチェックをブロック単位で行うと共に、パリティチェックプログラムを1ブロックに収めるようにしているため、1回のパリティチェック処理でパリティチェックプログラム自身のチェックを終了できる。したがって、DSPプログラムのパリティチェックとパリティチェックプログラム自身のパリティチェックとを、ブロック単位で交互に行うことで、パリティチェックプログラム自身が正常か否かを常に確認できるという効果がある。
【0074】
またこれにより、DSPプログラムに対するパリティチェック結果と、パリティチェックプログラム自身に対するパリティチェック結果の2つのパリティチェック結果が確認できるので、DSPプログラムに誤りがあるのか、パリティチェックプログラム自身に誤りがあるのかが瞬時に判断できるという効果がある。
【0075】
さらに、この発明の実施の一形態では、パリティチェックの結果、パリティチェックプログラム自身に誤りがあるとされた場合に、当該パリティチェックによるパリティコードがそのまま出力されるため、ホストマイコン側で、アップロード元としてメモリに格納してあるデータを用いて再度チェックを行うことができる。このため、チェック対象のプログラムに誤りがあるのか、チェックにおいてパリティ演算結果との比較を行うパリティコードに誤りがあるのかを判断することができる効果がある。
【図面の簡単な説明】
【図1】この発明の実施の一形態に適用可能なDSPシステムの一例の構成を概略的に示す略線図である。
【図2】DSP内のRAMにおける一例のデータ配置を示す略線図である。
【図3】この発明の実施の一形態によるパリティチェックの動作について説明するための図である。
【図4】ホストマイコンによる、パリティチェック結果に基づく一例のデータ修正処理を示すフローチャートである。
【符号の説明】
1・・・ホストマイコン、2・・・DSP、11・・・メモリ、12・・・DSPプログラム、13・・・パリティチェックプログラム、14・・・パリティコード、20・・・RAM、21・・・パリティコード、22・・・パリティチェックプログラム、23・・・DSPプログラム、24・・・バッファ領域、30,40・・・パリティコード、31,41・・・パリティ演算結果、34,44・・・正解固定値、36,46・・・レジスタ
[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to a memory check system, a memory check device and a method for checking data and a program stored in a memory, and a memory check program.
[0002]
[Prior art]
2. Description of the Related Art Conventionally, for performing signal processing using a digital filter, for example, a DSP (Digital Signal Processor) has been widely used. The DSP constitutes an arithmetic unit that performs addition, subtraction, multiplication and division based on a program (instruction) and coefficient data stored in a ROM (Read Only Memory) or a RAM (Random Access Memory), and performs signal processing on an input digital signal. Is to do. In particular, a type of DSP that stores programs and coefficient data in a RAM can flexibly change the function of the DSP by rewriting the storage contents of the RAM. In such a DSP, for example, instruction data and coefficient data are generally downloaded from a microcomputer or the like that controls the DSP and stored in a RAM.
[0003]
The DSP has an instruction RAM for storing program codes and a coefficient RAM for storing coefficient data, and these are connected by a bus. The RAM is an instruction RAM and a coefficient RAM, and the coefficient RAM is, for example, a RAM for storing X coefficient data and a RAM for storing Y coefficient data, each of which is physically independent, and a bus connected to each RAM. Each has a physically independent configuration.
[0004]
This allows the DSP to read and write data from and to each RAM in parallel. For example, the DSP reads the X and Y coefficients from the RAM, performs arithmetic processing, and temporarily stores the arithmetic result in the RAM. A series of processes can be executed by one command. On the other hand, in a configuration using a CPU (Central Processing Unit), it is general that the CPU and the RAM are connected by a single bus, and in order to perform the above-described processing, each coefficient data is read, arithmetic processing, A plurality of commands are required according to each processing such as storing the result of the arithmetic processing in the RAM. Therefore, the DSP can operate at higher speed for processing centering on the product-sum operation than the CPU.
[0005]
Data stored in the RAM may be partially destroyed by the influence of static electricity or noise. In addition, if an error occurs during the writing, such as when the timing of writing data to the RAM does not match, incorrect data will be stored. Further, there is a possibility that the program itself has a bug and the RAM area is destroyed during the execution of the program. In the case where a DSP program and coefficient data are stored in the RAM and the DSP is used, if there is an error in the contents stored in the RAM, the DSP may not operate as expected, or the DSP may run away.
[0006]
[Problems to be solved by the invention]
Therefore, conventionally, several methods have been considered for detecting a runaway of the DSP and checking the contents stored in the RAM. As an example, a watchdog timer that detects an abnormal loop or runaway of a program by resetting a program counter every certain fixed period is known. According to this, for example, when the program counter indicating the execution position of the program is abnormal, this can be detected.
[0007]
As another example, in Japanese Patent Application Laid-Open No. Hei 5-313908, a program abnormality detection program for detecting an abnormality of an execution program is stored in an external memory in advance, and the program abnormality detection program is used. A method for detecting an error on a RAM is disclosed. The program for detecting a program abnormality is downloaded from the external memory to the RAM together with the program for execution. The presence / absence of the execution program and the program abnormality detection program in the RAM is checked by the program abnormality detection program, and the execution program and the program abnormality detection program in which the abnormality is detected are corrected.
[0008]
The program for detecting a program abnormality, for example, obtains a checksum or XOR for the program data or coefficient data stored in the RAM, and compares the obtained value with a check code such as a correct checksum value or XOR result prepared in advance. By comparing, programs and data are inspected.
[0009]
However, according to this method, an access is made in units of an address of the RAM, the data stored in the RAM is read, and then the read data is transferred to an error detection program or error detection means to detect an error. Therefore, if a large amount of data or program code can be easily processed with the improvement of the processing capability of the CPU or the DSP, the amount of RAM that must be checked increases, and much time is spent on the check time. There was a problem that it had to be done.
[0010]
In this method, a program abnormality detection program and a check code for detecting a program abnormality, and an execution program and coefficient data to be detected exist on the same RAM. Therefore, there is a problem that the program for detecting a program abnormality and the check code stored in the RAM, and the execution program and the coefficient data together therewith may be destroyed due to the influence of static electricity or the like.
[0011]
As still another example, Japanese Patent Application Laid-Open No. 2000-339230 discloses that information stored in a RAM is directly transferred to an error detection unit using DMA (Direct Memory Access), and an error is detected in the content stored in the RAM. A method for determining whether or not is included is disclosed. According to this method, not only program data stored in the RAM but also error detection of coefficient data and the like stored in the RAM can be detected. Therefore, it is possible to detect a data error such that the DSP or CPU operating based on the data stored in the RAM does not run out of control.
[0012]
Further, according to the method disclosed in Japanese Patent Laid-Open No. 2000-339230, it is not necessary to execute a detection program on the CPU when detecting an error in the program data or coefficient data stored in the RAM. There is an advantage that it is not necessary to overestimate the processing capacity of the CPU in consideration of data error detection. Further, since the error detecting means is provided separately from the RAM, even if the contents of the RAM are destroyed, the error detection itself can be performed without any problem.
[0013]
However, this method also has a problem that the check time increases as the RAM capacity increases, as described above.
[0014]
Therefore, an object of the present invention is to provide a memory check system, a memory check device and a method, and a memory check program that can check and correct program data and coefficient data stored in a RAM at high speed and accurately. It is in.
[0015]
[Means for Solving the Problems]
In order to solve the above-mentioned problem, the present invention provides a rewritable memory of a signal processing device having a rewritable memory and performing signal processing according to contents written in the rewritable memory. In a memory check system for checking contents, a memory for storing an execution program, a parity check program, and a parity code resulting from performing a parity operation on the execution program and the parity check program by the parity check program is provided. A host device, having a rewritable memory connected to the host device and storing an execution program, a parity check program, and a parity code supplied from the host device, based on the execution program stored in the rewritable memory; Signal for signal processing A signal processing device, wherein a parity check program stored in a rewritable memory is used to execute an execution program and a parity check program stored in the rewritable memory. A parity check is performed for each block of a plurality of sizes, and a detection code based on the result of the parity calculation is output.
[0016]
The present invention also provides a host device having a memory for storing an execution program, a parity check program, and a parity code obtained by performing a parity operation on the execution program and the parity check program in the parity check program. A signal processing device that is connected and has a rewritable memory for storing an execution program, a parity check program, and a parity code supplied from a host device, and performs signal processing based on the execution program stored in the rewritable memory In a memory check method for checking the contents of a rewritable memory, an execution program, a parity check program, and a parity operation for the execution program and the parity check program in the parity check program. A memory rewritable by an execution program, a parity check program, and a parity check program stored in a rewritable memory for storing a parity code, which are supplied from a host device having a memory for storing a parity code obtained as a result. Of a parity operation for performing a parity operation for each block having a plurality of unit addresses of a rewritable memory with respect to the execution program and the parity check program stored in the memory, and a result of the parity operation by the parity operation step And a detection code output step of outputting a detection code based on the memory check method.
[0017]
According to another aspect of the present invention, there is provided a signal processing apparatus having a rewritable memory and performing signal processing in accordance with the content written in the rewritable memory. A rewritable memory in which a parity code obtained by performing a parity operation on the execution program and the parity check program in advance by the check program is stored, and signal processing is performed based on the execution program stored in the rewritable memory. And a parity check program stored in the rewritable memory, for executing the execution program and the parity check program stored in the rewritable memory from a plurality of unit addresses of the rewritable memory. Size block Parity operation was carried out, a signal processing apparatus is characterized in that so as to output a detection code based on the result of the parity operation for each.
[0018]
The present invention also relates to a memory check method of a signal processing device having a rewritable memory and performing signal processing in accordance with the content written in the rewritable memory, comprising: an execution program; A parity check program stored in a rewritable memory in which a program and a parity code obtained by performing a parity operation on the execution program and the parity check program in advance by the parity check program are stored in a rewritable memory. A parity calculation step of performing a parity calculation for each of the blocks having a plurality of unit addresses of the rewritable memory with respect to the stored execution program and parity check program, and a result of the parity calculation by the parity calculation step A memory checking method of a signal processing device and having a detection code output step of outputting a detection codes based.
[0019]
Further, the present invention provides a memory check for executing a memory check on a rewritable memory of a signal processing device having a rewritable memory and performing signal processing according to contents written in the rewritable memory. In the program, an execution program, a memory check program for checking a memory by a parity operation, and a parity code obtained by performing a parity operation on the execution program and the memory check program in advance are stored in a rewritable memory, A parity calculation step of performing a parity calculation for each block of a plurality of unit addresses of the rewritable memory with respect to the execution program and the memory check program on the rewritable memory; A memory check program; and a detection code output step of outputting a detection code based on the result of the operation.
[0020]
As described above, the invention according to claims 1 and 7 provides an execution program, a parity check program, and a parity code obtained by performing a parity operation on the execution program and the parity check program in the parity check program. And a rewritable memory connected to the host device and storing an execution program, a parity check program, and a parity code supplied from the host device, and stored in the rewritable memory. A signal processing device that performs signal processing based on the executed program, wherein the signal processing device uses the parity check program stored in the rewritable memory to execute the execution program and the parity check stored in the rewritable memory. Program In contrast, the parity calculation is performed for each block of a plurality of rewritable memory unit addresses, and a detection code is output based on the result of the parity calculation. At the same time, the check of the execution program and the check of the parity check program itself can be performed alternately.
[0021]
According to the eighth and thirteenth aspects of the present invention, an execution program, a parity check program, and a parity code obtained by performing a parity operation on the execution program and the parity check program by the parity check program in advance are stored. A rewritable memory, and signal processing means for performing signal processing based on an execution program stored in the rewritable memory. The stored execution program and the parity check program are subjected to a parity operation for each block having a plurality of sizes of rewritable memory unit addresses, and a detection code based on the result of the parity operation is output. Because the memory With the time required for Ekku is shortened, it is possible to perform the checking check and parity check program itself of the execution program alternately.
[0022]
A memory check program according to a fourteenth aspect of the present invention includes an execution program, a memory check program for checking a memory by a parity operation, and a result of performing a parity operation on the execution program and the memory check program in advance. A parity code is stored in a rewritable memory, and a parity operation is performed on the execution program and the memory check program on the rewritable memory for each block of a plurality of sizes of unit addresses of the rewritable memory. Since it has an operation step and a detection code output step of outputting a detection code based on the result of the parity operation in the parity operation step, the time required for memory check is reduced, and the execution program check and self- Own and check can be performed alternately.
[0023]
BEST MODE FOR CARRYING OUT THE INVENTION
Hereinafter, an embodiment of the present invention will be described. According to the present invention, an execution program and coefficient data used in a DSP (Digital Signal Processor) are downloaded from a memory of a microcomputer serving as a host (hereinafter, referred to as a host microcomputer) to a RAM (Random Access Memory) of the DSP, In a configuration in which the DSP is stored in the RAM of the DSP, a parity check program for checking the downloaded execution program and data stored in the RAM of the DSP by a parity operation is downloaded to the RAM of the DSP together with the DSP execution program and data. On the DSP side, the execution program and coefficient data stored in the RAM using the downloaded parity check program, and Check the program itself.
[0024]
At this time, according to the present invention, the execution program and the parity check program stored in the RAM are checked by the parity check program for each block having a plurality of sizes of the unit address of the RAM.
[0025]
Since the execution program, coefficient data, and parity check program are checked in units of blocks of a predetermined size, the time required for the check can be reduced. In addition, since the parity check program itself is also checked for each block, the execution program, coefficient data, and parity check program stored in the RAM can be alternately checked for each block. This makes it possible to always check whether the parity check program itself is normal or not.
[0026]
Further, according to the present invention, using the check program stored in the memory of the host microcomputer, the execution program and coefficient data downloaded to the DSP and stored in the RAM, and the check of the check program can be checked by a block of a predetermined size. It is done in units. Since the check is performed on both the DSP side and the host microcomputer side, it is possible to determine which of the check code used for the check and the check program is not normal.
[0027]
FIG. 1 schematically shows a configuration of an example of a DSP system applicable to an embodiment of the present invention. The host microcomputer 1 is, for example, a microcomputer having a CPU 10 and a memory 11 formed of a RAM and / or a ROM (Read Only Memory). The DSP 2 has a RAM 20, and operates based on an execution program and coefficient data stored in the RAM 20. The execution program of the DSP 2 is described by instruction codes that can be decoded by the DSP 2.
[0028]
The host microcomputer 1 and the DSP 2 are connected by an address bus 3 and a data bus 4. For example, a command for instructing the operation of the DSP 2 is transmitted from the host microcomputer 1 to the DSP 2 via the buses 3 and 4, and the DSP 2 is controlled by the host microcomputer 1.
[0029]
In the memory 11 of the host microcomputer 1, a DSP program 12, which is an execution program of the DSP 2, and coefficient data (not shown) are stored in advance. The DSP program stored in the memory 11 of the host microcomputer 1 is also described using the above-described instruction code. Hereinafter, the DSP program and the coefficient data used in the DSP program are collectively referred to as a DSP program.
[0030]
The DSP program is uploaded from the host microcomputer 1 to the DSP 2 and stored in the RAM 20 of the DSP 2. For example, an address of the RAM 20 is designated from the host microcomputer 1 to the DSP 2 via the address bus 3. The DSP program is uploaded from the host microcomputer 1 to the DSP 2 via the data bus 4. The uploaded DSP program is written to the RAM 20 based on the address specified using the address bus 3.
[0031]
The DSP 2 operates according to the DSP program downloaded from the host microcomputer 1. By changing the contents of the DSP program uploaded from the host microcomputer 1 to the DSP 2, the DSP 2 can perform different processing.
[0032]
Further, the memory 11 of the host microcomputer 1 includes a parity check program 13 for performing a parity check of the DSP program 12 uploaded to the DSP 2 and stored in the RAM 20, and a DSP program 12 and a parity check program 13 stored in the memory 11. And a parity code 14, which is a result of performing a parity operation in advance using the parity check program 13. The parity check program 13 is described by the above-described instruction code so as to be executable in the DSP 2. The parity check program 13 and the parity code 14 are uploaded from the host microcomputer 1 to the DSP 2 together with the above-mentioned DSP program 12, and stored in the RAM 20.
[0033]
FIG. 2 shows an example of a data arrangement in the RAM 20. In the example of FIG. 2, the RAM 20 has a capacity of 64 kB (kilobytes), and addresses are designated by “0x0000” to “0x10000”. In the address description, “0x” indicates that the description is in hexadecimal notation. The addresses “0x0400” to “0xAFFF” store the DSP program 23. The addresses “0xB000” to “0xFFFF” are the buffer area 24. The buffer area 24 is an area used when the DSP program 23 operates in the DSP 2, and its contents are changed as the DSP program is executed.
[0034]
The parity code 21 is stored in the addresses “0x0000” to “0x02FF”. The addresses “0x0300” to “0x03FF” store the parity check program 22. The parity code 21 is a parity code for data in all areas of the RAM 20 except the buffer area 24. That is, the parity code 21 corresponds to a result of performing a parity operation on the data in all the areas except the buffer area 24 of the RAM 20 using the parity check program 22 in advance. As described above, the parity of the buffer area 24 is not determined because the content is changed in accordance with the execution of the DSP program.
[0035]
Note that the capacity of the RAM 20 is not limited to 64 kB, and the address arrangement shown in FIG. 2 is also an example, and is not limited to this example.
[0036]
In the present invention, the parity check operation by the parity check program 22 is performed for each block in units of a block of a predetermined size. For example, one block is constituted by a size in which a plurality of unit addresses in the RAM 20 are aggregated. As an example, a block having a size corresponding to the area where the parity check program 22 is stored is defined as one unit block. In this example in which the capacity of the RAM 20 is 64 kB and the parity check program 22 has the address width “0x0100”, a block having a size of 256 bytes corresponding to the address width “0x0100” is defined as one unit block. Therefore, in the example of FIG. 2, the parity code 21 is composed of three blocks, and the DSP program 23 is composed of 172 blocks.
[0037]
The parity check operation by the parity check program 22 is performed for each block in units of one block having a size of 256 bytes. The parity code 21 calculated in advance and stored in the RAM 20 is also a parity code calculated by the DSP program 23 and the parity check program 22 in units of one block. By designating an address in the RAM 20 in a predetermined manner, a parity code corresponding to a parity operation in block units can be extracted from the parity code 21.
[0038]
In the above description, the size of the block has been described as being the same as the size of the parity check program 22, but this is not limited to this example. The size of the block can be arbitrarily set in units of address specification of the RAM 20. For example, the block size may be such that the parity check program 22 is stored in a plurality of blocks. However, the present invention is not limited to this. For example, a minimum unit of address specification, for example, one row in FIG. 2 can be a block.
[0039]
Next, the operation of the parity check according to the embodiment of the present invention will be described with reference to FIG. Prior to the parity check, a program check start command is issued from the host microcomputer 1 to the DSP 2. Then, a block to be checked is instructed from the host microcomputer 1 to the DSP 2. For example, the start address of the block to be checked in the RAM 20 is specified by the host microcomputer 1. In the DSP 2, a block to be checked based on this instruction is confirmed. When the block is confirmed, the parity check program 22 stored in the RAM 20 is executed, and the parity check for the designated block is executed.
[0040]
Note that the parity check can be performed by various methods. For example, it is conceivable to perform a parity check using simple parity such as even parity or odd parity. A simple parity calculation is performed by the parity check program 22, and a value obtained by integrating the calculation results for each block is output. The present invention is not limited to this, and the parity check can be performed using XOR (Exclusive OR). An XOR is obtained for the block data using a predetermined bit string prepared in advance. The check by XOR has an advantage that processing can be performed at higher speed. In addition, a CRC (cyclic redundancy check) may be used as a parity check method.
[0041]
As an example, the parity check of the fourth block of the DSP program 23 is performed by the parity check program 22. First, the parity calculation of the fourth block of the DSP program 23 is performed by the parity check program 22, and a parity calculation result 41 is obtained. Subsequently, the parity code 40 corresponding to the parity calculation result of the fourth block of the DSP program 23, which is a parity check target, is extracted from the RAM 20. The extracted parity code 40 and the parity operation result 41 are compared by a comparison process 42.
[0042]
If the result of the comparison between the parity code 40 and the parity operation result 41 by the comparison processing 42 is that they show the same value, the determination processing 43 determines that the four blocks of the DSP program 23 in the RAM 20 It is determined that there is no error in the eyes, and a correct answer fixed value 44 indicating this is set in the register 46. For example, a predetermined area in the buffer area 24 of the RAM 20 can be used as the register 46.
[0043]
On the other hand, as a result of the comparison between the parity code 40 and the parity operation result 41 by the comparison process 42, if both values are different, the judgment process 43 indicates that the parity code 40 and / or the parity operation result 41 have an error. It is determined that it exists, and the parity operation result 41 by the parity check program 22 is set in the register 46.
[0044]
That is, if it is determined in the register 46 based on the parity operation result 41 of the parity check program 22 that there is no error in the block to be parity-checked (the fourth block of the DSP program 23 in this example), the correct answer is fixed. The value 44 is set, and if it is determined that there is an error, the operation result 41 of the parity operation that is determined to have an error is set in the register 46 itself.
[0045]
When the parity check of one block of the DSP program 23 is completed, the parity check for the parity check program 22 stored in the RAM 20 is performed next. A parity operation is performed by the parity check program 22 on the block in which the parity check program 22 is stored (in this example, the blocks at addresses “0x0300” to “0x03FF”), and a parity operation result 31 is obtained. Subsequently, the parity code 30 corresponding to the parity operation result of the parity check program 22 is extracted from the RAM 20 among the parity codes 21. The extracted parity code 30 and the parity operation result 31 are compared by a comparison process 32.
[0046]
If the result of the comparison between the parity code 30 and the parity operation result 31 by the comparison process 32 indicates that the parity code 30 and the parity operation result 31 indicate the same value, it is determined that there is no error in the parity check program 22 on the RAM 20 by the determination process 33. The determination is made, and the correct answer fixed value 34 indicating that is set in the register 36. For example, an area of the buffer area 24 of the RAM 20 that is different from the area used as the register 46 is used as the register 36.
[0047]
On the other hand, as a result of the comparison between the parity code 30 and the parity operation result 31 by the comparison process 32, if both values are different, the judgment process 43 indicates that the parity code 30 and / or the parity operation result 31 have an error. It is determined that it exists, and the parity operation result 31 by the parity check program 22 is set in the register 36.
[0048]
That is, as in the case of the register 46 described above, the correct answer is obtained if it is determined that there is no error in the parity check program 22 on the RAM 20 to be subjected to the parity check based on the parity operation result 31 of the parity check program 22. When the fixed value 34 is set and it is determined that there is an error, the parity operation result 31 itself of the parity operation that is determined to have an error is set.
[0049]
When the parity check processing of the fourth block of the DSP program 23 and the parity check program 22 itself has been completed for one block, the DSP 2 sends the host microcomputer 1 the address of the parity-checked block in the RAM 20 for the host microcomputer 1. Notified.
[0050]
When the host microcomputer 1 receives the address of the block on which the parity check has been notified from the DSP 2, the data set in the registers 36 and 46 in the RAM 20 of the DSP 2 is taken in by the host microcomputer 1. Then, based on the fetched data of the registers 36 and 46, a process of determining whether or not the data uploaded to the RAM 20 needs to be corrected is performed. If it is determined that the data needs to be corrected, the data is re-uploaded to the RAM 20 and the data stored in the RAM 20 is corrected.
[0051]
As the correct answer fixed values 34 and 44, predetermined values that do not overlap with the result of the parity calculation by the parity check program 22 are used.
[0052]
FIG. 4 is a flowchart illustrating an example of a data correction process by the host microcomputer 1 based on a parity check result. In the first step S10, the host microcomputer 1 receives the address of the block on which parity check has been performed, transmitted from the DSP 2. In the next step S11, the host microcomputer 1 fetches the parity check result for the parity check program 22 set in the register 36.
[0053]
In step S12, it is determined whether or not the parity check result fetched from the register 36 in step S11 is the correct answer fixed value 34. If it is determined that the value fetched from the register 36 is the correct answer fixed value 34, it is determined that there is no problem in the parity check program 22 and the parity code 21 stored in the RAM 20, and the process proceeds to step The process moves to S13.
[0054]
On the other hand, if it is determined in step S12 that the value fetched from the register 36 is not the correct answer fixed value 34, the process proceeds to step S16. In step S16, the parity code corresponding to the parity check result of the parity check program 22, that is, the parity check program 13 in the memory 11, is extracted from the parity codes 14 in the memory 11 of the host microcomputer 1. Then, in step S17, it is determined whether or not the extracted parity code matches the value fetched from the register 36 in step S11 described above.
[0055]
If it is determined that they match, the parity check program 22 in the RAM 20 is correct, but the parity code 21 is considered to be incorrect. That is, even if the parity calculation result 31 for the parity check program 22 has a correct value, if the parity code 30 compared with the parity calculation result 31 in the comparison process 32 has an incorrect value, the parity calculation result 31 and the parity calculation result 31 The code 30 does not match, and the correct fixed value 34 is not set in the register 36. At this time, the correct parity operation result for the parity check program 22 is set in the register 36.
[0056]
In this case, the process proceeds to step S18, where the parity code corresponding to the parity operation result for the parity check program 22 (parity check program 13) is extracted from the parity codes 14 stored in the memory 11 of the host microcomputer 1, and the DSP 2 Sent to and re-uploaded. The re-uploaded parity code is written in the corresponding area of the RAM 20 as the parity code 30 described above. When the re-upload of the parity code is completed, the process proceeds to step S15.
[0057]
In the above description, when the parity code is re-uploaded, only the corresponding data from the parity code 14 stored in the memory 11 is extracted and transmitted to the DSP 2, but this is not limited to this example. The block including the corresponding data among the parity codes 14 stored in the memory 11 may be transmitted from the host microcomputer 1 to the DSP 2. Further, all the parity codes 14 stored in the memory 11 can be transmitted to the DSP 2.
[0058]
In step S15, a check process for the next block is prepared. That is, the host microcomputer 1 notifies the DSP 2 of the address of the next block to be checked. For example, in this example, the address of the fifth block of the DSP program 23 in the RAM 20 and the address of the parity check program 22 are notified to the DSP 2.
[0059]
When the address is notified, the DSP 2 performs the parity operation on the block of the notified address in the RAM 20 as described above, and stores the correct answer fixed values 34 and 44 and the parity in the registers 36 and 46 based on the parity operation result. The operation result is set. Then, in the host microcomputer 1, the process proceeds to step S10, and a check process based on the values set in the registers 36 and 46 is performed.
[0060]
In the embodiment of the present invention, the checks on the DSP program 23 and the parity check program 22 stored in the RAM are performed alternately in block units. Accordingly, the DSP program 23 can be checked while the parity check program 22 is always kept in a normal state, and the reliability of the check result is improved.
[0061]
On the other hand, if it is determined in step S17 that the two do not match, it is determined that the parity check program 22 in the RAM 20 is incorrect. In this case, there is a possibility that the parity code 30 as well as the parity check program 22 on the RAM 20 are incorrect. Then, the process proceeds to step S19, and the parity check program 13 stored in the memory 11 of the host microcomputer 1 is uploaded again to the DSP 2. The re-uploaded parity check program 13 is stored in the RAM 20 as the parity check program 22. When the re-upload of the parity check program is completed, the process moves to step S15.
[0062]
The parity check processing for the parity check program 22 is executed alternately for each block with respect to the parity check processing performed for the DSP program 23. Therefore, after re-uploading the parity check program 22 in the above-described step S19, a similar check process is executed again on the re-uploaded check program 22. At this time, it can be determined whether or not the parity code 30 has an error in the determination in step S17 described above.
[0063]
As described above, when it is determined in step S12 that the value fetched from the register 36 is the correct answer fixed value 34, it is determined that there is no error in the parity check program 22 in the RAM 20, and the process proceeds to step S13. Then, a correction process is performed on the DSP program 23 in the RAM 20 in block units.
[0064]
In step S13, the host microcomputer 1 fetches the parity check result of the block to be checked by the DSP program 23 (the fourth block of the DSP program) set in the register 46. In the next step S14, it is determined whether or not the parity check result fetched from the register 46 in step S13 is the correct answer fixed value 44. If it is determined that the check result fetched from the register 46 is the correct fixed value 44, it is determined that there is no problem in the fourth block of the DSP program 23 stored in the RAM 20, and The process moves to S15.
[0065]
On the other hand, if it is determined in step S14 that the value fetched from the register 46 is not the correct answer fixed value 44, the process proceeds to step S20. In step S20, of the parity code 14 in the memory 11 of the host microcomputer 1, the parity code for the fourth block of the DSP program 23, which is the target of the parity operation, that is, the corresponding block in the DSP program 12 in the memory 11 is extracted. Then, in step S21, it is determined whether or not the extracted parity code matches the value fetched from the register 46 in step S13.
[0066]
If it is determined that they match, the fourth block of the DSP program 23 in the RAM 20 is correct, but the parity code 21 is incorrect, as in the case of the above-described determination of the parity check program 22. It is thought that there is. In this case, the process proceeds to step S22, and the parity code corresponding to the parity operation result for the fourth block of the DSP program 23 is extracted from the parity codes stored in the memory 11 of the host microcomputer 1 and re-uploaded to the DSP 2. You. This re-uploaded parity code is written to the corresponding area of the RAM 20 as the parity code 40 described above. When the re-upload of the parity code is completed, the process proceeds to step S15.
[0067]
On the other hand, if it is determined in step S21 that the two do not match, it is determined that the fourth block of the DSP program 23 that is the parity check target is incorrect. Then, the process proceeds to step S23, and the block corresponding to the fourth block of the DSP program 23 in the DSP program 12 stored in the memory 11 of the host microcomputer 1 is re-uploaded to the DSP 2. This re-uploaded block is written to the corresponding location in RAM 20. At this time, when the upload processing is completed, the processing shifts to Step S15.
[0068]
The memory check according to the embodiment of the present invention described with reference to FIGS. 3 and 4 can be performed when the DSP 2 is started. For example, a series of memory check processes is performed from when the host microcomputer 1 instructs the DSP 2 to start processing to when the processing in the DSP 2 is actually started. However, the present invention is not limited to this, and the memory check process can be executed when the DSP2 original process is not performed while the DSP2 is operating. In addition, the memory check process may be performed at any time during the operation of the DSP 2 at an executable timing, or may be performed only once when the DSP 2 is started. Further, if the DSP 2 has sufficient processing capacity, the memory check processing may be performed at all times as a background for the original processing during the operation of the DSP 2.
[0069]
Furthermore, in a series of memory check operations, it is not necessary to check all blocks in the RAM 20. For example, the processing can be temporarily interrupted when a check is performed up to a block in the middle of the RAM 20, and when the check can be performed again, the check processing can be restarted from the block where the processing was interrupted.
[0070]
In the above description, the memory check according to the embodiment of the present invention has been described as being performed by the host microcomputer 1 and the DSP 2, but this is not limited to this example. It is possible. For example, in FIG. 4 described above, the data re-upload processing, that is, the processing excluding the processing of steps S18, S19, S22, and S23 can be executed only by the DSP 2. The re-upload of the parity code, the parity check program, and the DSP program can be performed by issuing a re-upload request from the DSP to the host microcomputer. Also, by storing a plurality of identical parity codes in the RAM of the DSP, the results of the parity calculation by the parity check program in steps S16 and S17 and steps S20 and S21 in FIG. 4 are compared with the correct parity code. Can be substituted.
[0071]
【The invention's effect】
As described above, according to the present invention, the parity check on the RAM of the DSP is performed for each block of a predetermined size, so that the number of times of communication between the DSP and the host microcomputer is reduced, so that the check time can be shortened. effective.
[0072]
In addition, for the DSP program and the parity check program uploaded to the RAM of the DSP, the parity check program uploaded performs a parity check on the parity check program stored in the RAM. At this time, it is assumed that there is no error in the parity check program itself. Therefore, it is necessary to check the parity check program itself before performing the parity check of the DSP program.
[0073]
In the embodiment of the present invention, the parity check is performed in units of blocks and the parity check program is contained in one block. Therefore, the parity check program itself can be completed by one parity check process. Therefore, by performing the parity check of the DSP program and the parity check of the parity check program itself alternately in block units, there is an effect that it is always possible to confirm whether the parity check program itself is normal or not.
[0074]
In addition, since the two parity check results, that is, the parity check result for the DSP program and the parity check result for the parity check program itself, can be confirmed, it is instantaneous whether there is an error in the DSP program or the parity check program itself. There is an effect that can be determined.
[0075]
Further, according to the embodiment of the present invention, when the parity check finds that the parity check program itself has an error, the parity code by the parity check is output as it is. The check can be performed again using the data stored in the memory. Therefore, it is possible to determine whether there is an error in the program to be checked or whether there is an error in the parity code that is compared with the parity operation result in the check.
[Brief description of the drawings]
FIG. 1 is a schematic diagram schematically showing a configuration of an example of a DSP system applicable to an embodiment of the present invention;
FIG. 2 is a schematic diagram illustrating an example of a data arrangement in a RAM in a DSP.
FIG. 3 is a diagram for explaining an operation of a parity check according to the embodiment of the present invention;
FIG. 4 is a flowchart illustrating an example of data correction processing by a host microcomputer based on a parity check result.
[Explanation of symbols]
DESCRIPTION OF SYMBOLS 1 ... Host microcomputer, 2 ... DSP, 11 ... Memory, 12 ... DSP program, 13 ... Parity check program, 14 ... Parity code, 20 ... RAM, 21 ... Parity code, 22 Parity check program, 23 DSP program, 24 Buffer area, 30, 40 Parity code, 31, 41 Parity operation result, 34, 44 -Correct answer fixed value, 36, 46 ... register

Claims (18)

書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置の書き換え可能なメモリの内容をチェックするメモリチェックシステムにおいて、
実行用プログラムと、パリティチェックプログラムと、該パリティチェックプログラムで上記実行用プログラムおよび該パリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置と、
上記ホスト装置と接続され、該ホスト装置から供給された上記実行用プログラム、上記パリティチェックプログラムおよび上記パリティコードを格納する書き換え可能なメモリを有し、該書き換え可能なメモリに格納された上記実行用プログラムに基づき信号処理を行う信号処理装置と
を備え、
上記信号処理装置では、上記書き換え可能なメモリに格納された上記パリティチェックプログラムにより、上記書き換え可能なメモリに格納された上記実行用プログラムおよび上記パリティチェックプログラムに対して、上記書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行い、該パリティ演算の結果に基づいた検出コードを出力するようにしたことを特徴とするメモリチェックシステム。
A memory check system that has a rewritable memory and checks the content of a rewritable memory of a signal processing device that is configured to perform signal processing according to the content written in the rewritable memory,
A host device having a memory for storing an execution program, a parity check program, and a parity code obtained by performing a parity operation on the execution program and the parity check program with the parity check program;
A rewritable memory connected to the host device and storing the execution program, the parity check program, and the parity code supplied from the host device, wherein the execution program stored in the rewritable memory is stored. A signal processing device that performs signal processing based on a program,
In the signal processing device, the parity check program stored in the rewritable memory allows the execution program and the parity check program stored in the rewritable memory to have a unit of the rewritable memory. A memory check system wherein a parity operation is performed for each block having a plurality of addresses and a detection code is output based on a result of the parity operation.
請求項1に記載のメモリチェックシステムにおいて、
上記パリティチェックプログラムは、上記書き換え可能なメモリ内で1または複数の上記ブロックに格納されることを特徴とするメモリチェックシステム。
The memory check system according to claim 1,
The memory check system, wherein the parity check program is stored in one or a plurality of the blocks in the rewritable memory.
請求項1に記載のメモリチェックシステムにおいて、
上記パリティチェックプログラムは、上記パリティ演算の結果が正常を示していれば上記検出コードとして所定の固定値を出力し、上記パリティ演算の結果が異常を示していれば上記検出コードとして該パリティ演算の結果を出力するようにしたことを特徴とするメモリチェックシステム。
The memory check system according to claim 1,
The parity check program outputs a predetermined fixed value as the detection code if the result of the parity operation indicates normal, and outputs the predetermined code as the detection code if the result of the parity operation indicates abnormal. A memory check system characterized by outputting a result.
請求項1に記載のメモリチェックシステムにおいて、
上記パリティチェックプログラムは、上記実行用プログラムに対する上記パリティ演算と、上記パリティチェックプログラムに対する上記パリティ演算とを上記ブロック単位で交互に行うようにしたことを特徴とするメモリチェックシステム。
The memory check system according to claim 1,
The memory check system, wherein the parity check program alternately performs the parity calculation for the execution program and the parity calculation for the parity check program in block units.
請求項4に記載のメモリチェックシステムにおいて、
上記パリティチェックプログラムによる、上記実行用プログラムに対する上記パリティ演算の結果に基づく上記検出コードと、上記パリティチェックプログラムに対する上記パリティ演算の結果に基づく上記検出コードとを上記ホスト装置に対して出力するようにしたことを特徴とするメモリチェックシステム。
The memory check system according to claim 4,
According to the parity check program, the detection code based on the result of the parity operation for the execution program and the detection code based on the result of the parity operation for the parity check program are output to the host device. A memory check system characterized by:
請求項1に記載のメモリチェックシステムにおいて、
さらに、上記ホスト装置により、上記書き換え可能なメモリに格納される上記実行用プログラム、上記パリティチェックプログラムおよび上記パリティコードに対するチェックを、上記検出コードに基づき行うようにしたことを特徴とするメモリチェックシステム。
The memory check system according to claim 1,
A memory check system, wherein the host device performs a check on the execution program, the parity check program, and the parity code stored in the rewritable memory based on the detection code. .
実行用プログラムと、パリティチェックプログラムと、パリティチェックプログラムで実行用プログラムおよびパリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置と接続され、ホスト装置から供給された実行用プログラム、パリティチェックプログラムおよびパリティコードを格納する書き換え可能なメモリを有し、書き換え可能なメモリに格納された上記実行用プログラムに基づき信号処理を行う信号処理装置の書き換え可能なメモリの内容をチェックするメモリチェック方法において、
実行用プログラムと、パリティチェックプログラムと、該パリティチェックプログラムで実行用プログラムおよび該パリティチェックプログラムに対してパリティ演算を行った結果のパリティコードとが格納されるメモリを有するホスト装置から供給された上記実行用プログラム、上記パリティチェックプログラムおよび上記パリティコードを格納する書き換え可能なメモリに格納された上記パリティチェックプログラムにより、上記書き換え可能なメモリに格納された上記実行用プログラムおよび上記パリティチェックプログラムに対して、上記書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、
上記パリティ演算のステップによる上記パリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップと
を有することを特徴とするメモリチェック方法。
An execution program, a parity check program, a parity check program, and a host device having a memory storing a parity code obtained by performing a parity operation on the execution program and the parity check program in the parity check program. A rewritable memory of a signal processing device having a rewritable memory for storing a supplied execution program, a parity check program, and a parity code, and performing signal processing based on the execution program stored in the rewritable memory In the memory check method for checking the contents of
The parity check program supplied from a host device having a memory for storing an execution program, a parity check program, and a parity code obtained by performing a parity operation on the execution program and the parity check program in the parity check program. The execution program, the parity check program, and the parity check program stored in the rewritable memory that stores the parity code are used to execute the parity check program and the execution program stored in the rewritable memory. A parity calculation step of performing a parity calculation for each block having a size of a plurality of unit addresses of the rewritable memory;
Outputting a detection code based on a result of the parity operation in the parity operation step.
書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置において、
実行用プログラムと、パリティチェックプログラムと、該パリティチェックプログラムで上記実行用プログラムおよび該パリティチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが格納される書き換え可能なメモリと、
上記書き換え可能なメモリに格納された上記実行用プログラムに基づき信号処理を行う信号処理手段と
を備え、
上記書き換え可能なメモリに格納された上記パリティチェックプログラムにより、上記書き換え可能なメモリに格納された上記実行用プログラムおよび上記パリティチェックプログラムに対して、上記書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行い、該パリティ演算の結果に基づいた検出コードを出力するようにしたことを特徴とする信号処理装置。
In a signal processing device having a rewritable memory and performing signal processing according to the content written in the rewritable memory,
A rewritable memory in which an execution program, a parity check program, and a parity code obtained by performing a parity operation on the execution program and the parity check program in advance with the parity check program are stored;
Signal processing means for performing signal processing based on the execution program stored in the rewritable memory,
The parity check program stored in the rewritable memory allows the execution program and the parity check program stored in the rewritable memory to have a plurality of unit addresses of the rewritable memory. A signal processing apparatus for performing a parity operation for each of the blocks and outputting a detection code based on a result of the parity operation.
請求項8に記載の信号処理装置において、
上記パリティチェックプログラムは、上記書き換え可能なメモリ内で1または複数の上記ブロックに格納されることを特徴とする信号処理装置。
The signal processing device according to claim 8,
The signal processing device according to claim 1, wherein the parity check program is stored in one or a plurality of the blocks in the rewritable memory.
請求項8に記載の信号処理装置において、
上記パリティチェックプログラムは、上記パリティ演算の結果が正常を示していれば上記検出コードとして所定の固定値を出力し、上記パリティ演算の結果が異常を示していれば上記検出コードとして該パリティ演算の結果を出力するようにしたことを特徴とする信号処理装置。
The signal processing device according to claim 8,
The parity check program outputs a predetermined fixed value as the detection code if the result of the parity operation indicates normal, and outputs the predetermined code as the detection code if the result of the parity operation indicates abnormal. A signal processing device for outputting a result.
請求項8に記載の信号処理装置において、
上記パリティチェックプログラムは、上記実行用プログラムに対する上記パリティ演算と、上記パリティチェックプログラムに対する上記パリティ演算とを上記ブロック単位で交互に行うようにしたことを特徴とする信号処理装置。
The signal processing device according to claim 8,
The signal processing device according to claim 1, wherein the parity check program alternately performs the parity calculation for the execution program and the parity calculation for the parity check program in block units.
請求項11に記載の信号処理装置において、
上記パリティチェックプログラムによる、上記実行用プログラムに対する上記パリティ演算の結果に基づく上記検出コードと、上記パリティチェックプログラムに対する上記パリティ演算の結果に基づく上記検出コードとを、上記書き換え可能なメモリに対して上記実行用プログラム、上記パリティチェックプログラムおよび上記パリティコードを供給するホスト装置に対して出力するようにしたことを特徴とする信号処理装置。
The signal processing device according to claim 11,
By the parity check program, the detection code based on the result of the parity operation on the execution program, and the detection code based on the result of the parity operation on the parity check program, for the rewritable memory, A signal processing device for outputting to a host device that supplies an execution program, the parity check program, and the parity code.
書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置のメモリチェック方法において、
実行用プログラムと、パリティチェックプログラムと、該パリティチェックプログラムで実行用プログラムおよび該パリティチェックプログラムに対して予めパリティ演算を行った結果のパリティコードとが格納される書き換え可能なメモリに格納された上記パリティチェックプログラムにより、上記書き換え可能なメモリに格納された上記実行用プログラムおよび上記パリティチェックプログラムに対して、上記書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、
上記パリティ演算のステップによる上記パリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップと
を有することを特徴とする信号処理装置のメモリチェック方法。
A memory check method of a signal processing device having a rewritable memory and performing signal processing in accordance with the content written in the rewritable memory,
The execution program, the parity check program, and the parity program which are stored in a rewritable memory in which an execution program and a parity code obtained by performing a parity operation on the parity check program in advance are stored. A parity operation for performing a parity operation on the execution program and the parity check program stored in the rewritable memory for each block having a plurality of unit addresses of the rewritable memory by a parity check program. Steps and
A detection code output step of outputting a detection code based on a result of the parity operation in the parity operation step.
書き換え可能なメモリを有し、書き換え可能なメモリに書き込まれた内容に応じた信号処理を行うようにされた信号処理装置の書き換え可能なメモリに対するメモリチェックを実行させるメモリチェックプログラムにおいて、
実行用プログラムと、パリティ演算によりメモリをチェックするメモリチェックプログラムと、上記実行用プログラムおよび上記メモリチェックプログラムに対して予め上記パリティ演算を行った結果のパリティコードとが書き換え可能なメモリに格納され、該書き換え可能なメモリ上の上記実行用プログラムおよび上記メモリチェックプログラムに対して、上記書き換え可能なメモリの単位アドレスの複数からなるサイズのブロック毎にパリティ演算を行うパリティ演算のステップと、
上記パリティ演算のステップによる上記パリティ演算の結果に基づいた検出コードを出力する検出コード出力のステップと
を有することを特徴とするメモリチェックプログラム。
A memory check program that has a rewritable memory and executes a memory check on the rewritable memory of the signal processing device that is configured to perform signal processing according to the content written in the rewritable memory,
An execution program, a memory check program for checking a memory by a parity operation, and a parity code obtained by performing the parity operation on the execution program and the memory check program in advance are stored in a rewritable memory; A parity operation step of performing a parity operation on the execution program and the memory check program on the rewritable memory for each block having a plurality of unit addresses of the rewritable memory;
A detection code output step of outputting a detection code based on a result of the parity operation in the parity operation step.
請求項14に記載のメモリチェックプログラムにおいて、上記書き換え可能なメモリ内で1または複数の上記ブロックに格納されることを特徴とするメモリチェックプログラム。15. The memory check program according to claim 14, wherein the memory check program is stored in one or a plurality of the blocks in the rewritable memory. 請求項14に記載のメモリチェックプログラムにおいて、上記パリティ演算の結果が正常を示していれば上記検出コードとして所定の固定値を出力し、上記パリティ演算の結果が異常を示していれば上記検出コードとして該パリティ演算の結果を出力するようにしたことを特徴とするメモリチェックプログラム。15. The memory check program according to claim 14, wherein a predetermined fixed value is output as the detection code if the result of the parity operation indicates normal, and the detection code is output if the result of the parity operation indicates abnormal. A memory check program for outputting a result of the parity operation. 請求項14に記載のメモリチェックプログラムにおいて、上記書き換え可能なメモリ上の上記実行用プログラムに対する上記パリティ演算と、上記書き換え可能なメモリ上の上記メモリチェックプログラムに対する上記パリティ演算とを上記ブロック単位で交互に行うようにしたことを特徴とするメモリチェックプログラム。15. The memory check program according to claim 14, wherein the parity calculation for the execution program on the rewritable memory and the parity calculation for the memory check program on the rewritable memory are alternately performed in block units. A memory check program characterized in that the program is executed in the following manner. 請求項17に記載のメモリチェックプログラムにおいて、上記書き換え可能なメモリ上の上記実行用プログラムに対する上記パリティ演算の結果に基づく上記検出コードと、上記書き換え可能なメモリ上の上記メモリチェックプログラムに対する上記パリティ演算の結果に基づく上記検出コードとを、上記書き換え可能なメモリに対して上記実行用プログラム、上記パリティチェックプログラムおよび上記パリティコードを供給するホスト装置に対して出力するようにしたことを特徴とするメモリチェックプログラム。18. The memory check program according to claim 17, wherein the detection code based on a result of the parity calculation for the execution program on the rewritable memory, and the parity calculation for the memory check program on the rewritable memory. Wherein the detection code based on the result of the above is output to the host program which supplies the execution program, the parity check program, and the parity code to the rewritable memory. Check program.
JP2002194452A 2002-07-03 2002-07-03 MEMORY CHECK SYSTEM, MEMORY CHECK METHOD, SIGNAL PROCESSING DEVICE, SIGNAL PROCESSING DEVICE MEMORY CHECK METHOD, AND MEMORY CHECK PROGRAM Expired - Fee Related JP4135413B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002194452A JP4135413B2 (en) 2002-07-03 2002-07-03 MEMORY CHECK SYSTEM, MEMORY CHECK METHOD, SIGNAL PROCESSING DEVICE, SIGNAL PROCESSING DEVICE MEMORY CHECK METHOD, AND MEMORY CHECK PROGRAM

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002194452A JP4135413B2 (en) 2002-07-03 2002-07-03 MEMORY CHECK SYSTEM, MEMORY CHECK METHOD, SIGNAL PROCESSING DEVICE, SIGNAL PROCESSING DEVICE MEMORY CHECK METHOD, AND MEMORY CHECK PROGRAM

Publications (2)

Publication Number Publication Date
JP2004038541A true JP2004038541A (en) 2004-02-05
JP4135413B2 JP4135413B2 (en) 2008-08-20

Family

ID=31703140

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002194452A Expired - Fee Related JP4135413B2 (en) 2002-07-03 2002-07-03 MEMORY CHECK SYSTEM, MEMORY CHECK METHOD, SIGNAL PROCESSING DEVICE, SIGNAL PROCESSING DEVICE MEMORY CHECK METHOD, AND MEMORY CHECK PROGRAM

Country Status (1)

Country Link
JP (1) JP4135413B2 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008071101A (en) * 2006-09-14 2008-03-27 Megachips Lsi Solutions Inc Storage device and data output circuit
EP2261810A1 (en) 2009-06-02 2010-12-15 Sanyo Electric Co., Ltd. Data check circuit
JP2013190923A (en) * 2012-03-13 2013-09-26 Dainippon Printing Co Ltd Ic card and computer program
JP2013222348A (en) * 2012-04-17 2013-10-28 Dainippon Printing Co Ltd Ic card and computer program

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0620216U (en) * 1992-05-08 1994-03-15 松下電器産業株式会社 Packaging box with handle
JPH0620217U (en) * 1992-05-20 1994-03-15 八木アンテナ株式会社 Packing box

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008071101A (en) * 2006-09-14 2008-03-27 Megachips Lsi Solutions Inc Storage device and data output circuit
EP2261810A1 (en) 2009-06-02 2010-12-15 Sanyo Electric Co., Ltd. Data check circuit
US8327054B2 (en) 2009-06-02 2012-12-04 Semiconductor Components Industries, Llc Data check circuit for checking program data stored in memory
JP2013190923A (en) * 2012-03-13 2013-09-26 Dainippon Printing Co Ltd Ic card and computer program
JP2013222348A (en) * 2012-04-17 2013-10-28 Dainippon Printing Co Ltd Ic card and computer program

Also Published As

Publication number Publication date
JP4135413B2 (en) 2008-08-20

Similar Documents

Publication Publication Date Title
EP2159709B1 (en) Error correcting method and computing element
US4701915A (en) Error recovery system in a data processor having a control storage
JP5780174B2 (en) System and method for handling bad bit errors
TWI431526B (en) Hardware flow control monitor
TWI803927B (en) Processor, apparatus for protecting the processor, and method for protecting the processor
CN114328316A (en) DMA controller, SOC system and data carrying method based on DMA controller
JP2024513174A (en) Error checking of data used in offloaded operations
JP4135413B2 (en) MEMORY CHECK SYSTEM, MEMORY CHECK METHOD, SIGNAL PROCESSING DEVICE, SIGNAL PROCESSING DEVICE MEMORY CHECK METHOD, AND MEMORY CHECK PROGRAM
JP2003015958A (en) Write-protect method
US8190971B2 (en) Data processing system and method for operating a data processing system
WO2021038923A1 (en) Control device, execution control method for user program, and system program
EP2352092B1 (en) Processor, information processing apparatus, and method of controlling processor
JP2004126658A (en) Processor system
EP0655686B1 (en) Retry control method and device for control processor
JP4543505B2 (en) Microcomputer control method and abnormality monitoring device
JP2016177717A (en) Memory control device and memory control method
KR100216045B1 (en) Bit arithmetic processing method and apparatus of programmable controller
JP2012048445A (en) Program executing device, program generating device, program correctness determination method and program processing method
JP2004171106A (en) Data storage control method and device
JP3616588B2 (en) Micro program check system
JPS6052451B2 (en) Microinstruction execution control method
JPH0229839A (en) Microprogram control device
JPH04255032A (en) Error correcting system for control storage
JPS60238933A (en) Error processing system of control storage device
WO2011096083A1 (en) Error generation indicator circuit, storage device, information processing device and control method of error generation indicator circuit

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050502

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20080212

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080219

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080418

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: 20080513

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: 20080526

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

Free format text: PAYMENT UNTIL: 20110613

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees