JP6113374B1 - Programmable logic controller - Google Patents
Programmable logic controller Download PDFInfo
- Publication number
- JP6113374B1 JP6113374B1 JP2016559470A JP2016559470A JP6113374B1 JP 6113374 B1 JP6113374 B1 JP 6113374B1 JP 2016559470 A JP2016559470 A JP 2016559470A JP 2016559470 A JP2016559470 A JP 2016559470A JP 6113374 B1 JP6113374 B1 JP 6113374B1
- Authority
- JP
- Japan
- Prior art keywords
- memory
- nonvolatile memory
- volatile memory
- data
- microprocessor
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/16—Protection against loss of memory contents
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Techniques For Improving Reliability Of Storages (AREA)
- Programmable Controllers (AREA)
- Memory System (AREA)
Abstract
データを記憶する揮発性メモリ(5)と、データを記憶する不揮発性メモリ(6)と、データを揮発性メモリまたは不揮発性メモリに書き込む制御部(1)と、制御部から不揮発性メモリへの書き込み回数を検知する書き込み回数検知回路(3)と、制御部からのデータの書き込み先を揮発性メモリまたは不揮発性メモリのいずれかに切り替えるアクセス先メモリ切り替え回路(4)と、を備え、アクセス先メモリ切り替え回路は、書き込み回数が計測時間内に閾値を超えた場合は、データの書き込み先を不揮発性メモリから揮発性メモリに切り替え、制御部は、アクセス先メモリ切り替え回路がデータの書き込み先を不揮発性メモリから揮発性メモリに切り替えた後に、揮発性メモリに書き込まれたデータを不揮発性メモリへ書き込む。A volatile memory (5) for storing data, a non-volatile memory (6) for storing data, a control unit (1) for writing data to the volatile memory or the non-volatile memory, and a control unit to the non-volatile memory A write frequency detection circuit (3) for detecting the write frequency, and an access destination memory switching circuit (4) for switching a data write destination from the control unit to either a volatile memory or a nonvolatile memory. The memory switching circuit switches the data write destination from the non-volatile memory to the volatile memory when the number of write times exceeds the threshold within the measurement time, and the control unit switches the data write destination to the non-volatile memory. After switching from the volatile memory to the volatile memory, the data written to the volatile memory is written to the nonvolatile memory.
Description
本発明は、シーケンス制御を実行するプログラマブルロジックコントローラに関する。 The present invention relates to a programmable logic controller that executes sequence control.
近年のプログラマブルロジックコントローラにおいては、データ保持用メモリのためのバッテリの交換にかかるメンテナンス工数を削減するといった理由により、バッテリレス化の要望が高まっている。 In recent programmable logic controllers, there is an increasing demand for a battery-less system for the purpose of reducing maintenance man-hours required for replacing a battery for a data holding memory.
バッテリレス化を実現するためには、バッテリを用いてデータを保持していたSRAM(Static Random Access Memory)といった揮発性メモリを不揮発性メモリに変更する必要がある。しかし、強誘電体メモリといった安価な不揮発性メモリには、書き込み回数の上限値がある。プログラマブルロジックコントローラのような工業用機器は長期間使用されるため、このような不揮発性メモリを使用した場合、使用期間内に不揮発性メモリの書き込み回数の上限値を上回る書き込みが発生する可能性がある。 In order to realize battery-less operation, it is necessary to change a volatile memory such as an SRAM (Static Random Access Memory) that holds data using a battery to a nonvolatile memory. However, an inexpensive nonvolatile memory such as a ferroelectric memory has an upper limit value of the number of times of writing. Since industrial devices such as programmable logic controllers are used for a long period of time, when such a nonvolatile memory is used, there is a possibility that writing exceeding the upper limit of the number of times of writing to the nonvolatile memory may occur within the usage period. is there.
この問題に対して、不揮発性メモリの書き換え保証回数内で書き換え頻度を変更する技術が、特許文献1に提案されている。特許文献1においては、CPU(Central Processing Unit)が不揮発性メモリの書き換え回数をカウントし、書き換え回数が所定値以上であると判断すると、不揮発性メモリへの書き換え頻度を変更している。
For this problem,
しかしながら、特許文献1の技術によれば、不揮発性メモリへの書き換えの回数が所定値以上になると、CPUが不揮発性メモリへの書き換え頻度を低減して調整しているため、メモリへの書き込み速度が低下するという問題点がある。
However, according to the technique of
本発明は、上記に鑑みてなされたものであって、メモリへの書き込み速度に影響を与えずに、不揮発性メモリの書き込み回数を低減し、揮発性メモリのためのバッテリを不要にすることが可能なプログラマブルロジックコントローラを得ることを目的とする。 The present invention has been made in view of the above, and it is possible to reduce the number of times of writing to the nonvolatile memory without affecting the writing speed to the memory, and to eliminate the need for a battery for the volatile memory. The object is to obtain a programmable logic controller.
上述した課題を解決し、目的を達成するために、本発明は、データを記憶する揮発性メモリと、データを記憶する不揮発性メモリと、データを揮発性メモリまたは不揮発性メモリに書き込む制御部と、制御部から不揮発性メモリへの書き込み回数を検知する書き込み回数検知回路と、制御部からのデータの書き込み先を揮発性メモリまたは不揮発性メモリのいずれかに切り替えるアクセス先メモリ切り替え回路と、を備える。本発明は、アクセス先メモリ切り替え回路は、書き込み回数が計測時間内に閾値を超えた場合は、データの書き込み先を不揮発性メモリから揮発性メモリに切り替え、制御部は、アクセス先メモリ切り替え回路がデータの書き込み先を不揮発性メモリから揮発性メモリに切り替えた後に、揮発性メモリに書き込まれたデータを不揮発性メモリへ書き込むことを特徴とする。 In order to solve the above-described problems and achieve the object, the present invention includes a volatile memory that stores data, a nonvolatile memory that stores data, and a control unit that writes data to the volatile memory or the nonvolatile memory. A write number detection circuit for detecting the number of writes from the control unit to the non-volatile memory, and an access destination memory switching circuit for switching a data write destination from the control unit to either the volatile memory or the non-volatile memory. . In the present invention, the access destination memory switching circuit switches the data writing destination from the nonvolatile memory to the volatile memory when the number of times of writing exceeds the threshold value within the measurement time, and the control unit After the data write destination is switched from the nonvolatile memory to the volatile memory, the data written to the volatile memory is written to the nonvolatile memory.
本発明にかかるプログラマブルロジックコントローラは、メモリへの書き込み速度に影響を与えずに、不揮発性メモリの書き込み回数を低減し、揮発性メモリのためのバッテリを不要にすることが可能になるという効果を奏する。 The programmable logic controller according to the present invention has the effect of reducing the number of times of writing to the nonvolatile memory without affecting the writing speed to the memory and making it unnecessary to use a battery for the volatile memory. Play.
以下に、本発明の実施の形態にかかるプログラマブルロジックコントローラを図面に基づいて詳細に説明する。なお、この実施の形態によりこの発明が限定されるものではない。 Below, the programmable logic controller concerning an embodiment of the invention is explained in detail based on a drawing. Note that the present invention is not limited to the embodiments.
実施の形態1.
図1は、本発明の実施の形態1にかかるプログラマブルロジックコントローラ100の構成を示す図である。
FIG. 1 is a diagram showing a configuration of a
プログラマブルロジックコントローラ100は、指令を行う入力機器またはシーケンス制御の対象となる出力機器である外部機器50に接続されている。外部機器50は、デバイスとも呼ばれ、複数存在してよいが、図1では簡単のため1つにしてある。
The
プログラマブルロジックコントローラ100は、演算処理を実行する制御部であるマイクロプロセッサー1と、マイクロプロセッサー1のワークエリアとなる記憶領域であるRAM(Random Access Memory)7と、外部機器50から取得したデータを記憶する揮発性メモリ5と、外部機器50から取得したデータを記憶する不揮発性メモリ6と、マイクロプロセッサー1から不揮発性メモリ6への書き込み回数を検知する書き込み回数検知回路3と、マイクロプロセッサー1からのアクセス先を切り替えるアクセス先メモリ切り替え回路4と、を備える。なお、RAM7はマイクロプロセッサー1に設けられてもかまわない。
The
マイクロプロセッサー1とアクセス先メモリ切り替え回路4とはバス71で接続されている。アクセス先メモリ切り替え回路4と揮発性メモリ5とはバス72で接続されている。アクセス先メモリ切り替え回路4と不揮発性メモリ6とはバス73で接続されている。バス71と書き込み回数検知回路3とは制御線8で接続されている。書き込み回数検知回路3とアクセス先メモリ切り替え回路4とは制御線9で接続されている。マイクロプロセッサー1とアクセス先メモリ切り替え回路4とは制御線10で接続されている。
The
アクセス先メモリ切り替え回路4は、マイクロプロセッサー1からのデータの書き込み先を揮発性メモリ5または不揮発性メモリ6のいずれかに切り替える。マイクロプロセッサー1からのデータの書き込み先のアクセス先メモリ切り替え回路4による切り替えは、マイクロプロセッサー1からの書き込みデータの信号の宛先のアドレスを揮発性メモリ5宛または不揮発性メモリ6宛のいずれかに設定するといった手段でもよい。或いは、アクセス先メモリ切り替え回路4がバス71をバス72またはバス73のいずれか一方としか接続しないスイッチング処理を実行することにより、マイクロプロセッサー1からのデータの書き込み先および読み出し元を揮発性メモリ5または不揮発性メモリ6のいずれかに切り替えるようにしてもよい。揮発性メモリ5は、アクセス先メモリ切り替え回路4によってマイクロプロセッサー1からのデータの書き込み先に切り替えられたときに、データの書き込み先の記憶領域となるデータ保持エリア51を備える。
The access destination memory switching circuit 4 switches the data write destination from the
マイクロプロセッサー1は、ファームウェアおよびOS(Operating System)を記憶する記憶手段であるROM(Read Only Memory)2を備えている。このファームウェアには、不揮発性メモリ6への書き込み回数の閾値と、不揮発性メモリ6への書き込み回数が当該閾値を超えるか否かを判定する期間である計測時間と、が設定されている。計測時間は、プログラマブルロジックコントローラ100の電源がオンになってから予め定められた期間である。上記閾値および計測時間は、不揮発性メモリ6への書き込み可能な回数の最初の上限値N0と、プログラマブルロジックコントローラ100の最初の保証期間T0とに基づいて、最初の保証期間T0内に書き込み回数が最初の上限値N0を超えないような安全側の条件として予め求めておき、上記ファームウェアに設定しておく。不揮発性メモリ6への書き込み可能な回数の最初の上限値N0は、不揮発性メモリ6が書き込みデータの信頼性を保証できる範囲内の書き込み回数として与えられている。また、最初の保証期間T0は、プログラマブルロジックコントローラ100の製造日情報および製品保証期限日とから与えられる場合もある。The
書き込み回数検知回路3は、制御線8を介してマイクロプロセッサー1によるバス71を介した不揮発性メモリ6への書き込みを検知するインタフェースを備えており、不揮発性メモリ6への書き込み回数をカウントすることができる。具体的には、書き込み回数検知回路3は、アクセス先メモリ切り替え回路4によりマイクロプロセッサー1からのアクセス先が不揮発性メモリ6に切り替えられている状態での、マイクロプロセッサー1による不揮発性メモリ6への書き込みを検知する。書き込み回数検知回路3は、さらに、内部にタイマを有している。書き込み回数検知回路3は、このタイマを用いて、上記計測時間内における不揮発性メモリ6への書き込み回数を検知することができる。
The write count detection circuit 3 includes an interface for detecting a write to the nonvolatile memory 6 via the
書き込み回数検知回路3は、上記計測時間内に上記閾値以上の不揮発性メモリ6への書き込み回数を検知すると、高速なメモリアクセスが発生していると判断して、制御線9を介してアクセス先メモリ切り替え回路4にマイクロプロセッサー1からの書き込み先を切り替えることを指示するアクセス先切り替え信号を送信する。アクセス先切り替え信号を受信したアクセス先メモリ切り替え回路4は、マイクロプロセッサー1からのデータの書き込み先および読み出し元を不揮発性メモリ6から揮発性メモリ5に切り替える。なお、マイクロプロセッサー1もアクセス先切り替え信号を制御線10を介して送信することによりアクセス先メモリ切り替え回路4を制御することが可能であり、マイクロプロセッサー1の書き込み先を揮発性メモリ5または不揮発性メモリ6のいずれかに切り替えることが可能である。
When the number of write detection circuit 3 detects the number of writes to the nonvolatile memory 6 that is equal to or greater than the threshold value within the measurement time, the write number detection circuit 3 determines that a high-speed memory access has occurred, An access destination switching signal for instructing the memory switching circuit 4 to switch the write destination from the
書き込み回数検知回路3およびアクセス先メモリ切り替え回路4は、単一回路、複合回路、プログラム化したプロセッサー、並列プログラム化したプロセッサー、ASIC(Application Specific Integrated Circuit)、FPGA(Field Programmable Gate Array)、またはこれらを組み合わせたハードウェアで構成される。書き込み回数検知回路3およびアクセス先メモリ切り替え回路4の機能それぞれを処理回路で実現してもよいし、両者の機能をまとめて処理回路で実現してもよい。 The write count detection circuit 3 and the access destination memory switching circuit 4 are a single circuit, a composite circuit, a programmed processor, a parallel programmed processor, an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array), or these Consists of hardware that combines. The functions of the write count detection circuit 3 and the access destination memory switching circuit 4 may be realized by a processing circuit, or the functions of both may be realized by a processing circuit.
図2は、実施の形態1にかかるマイクロプロセッサー1、書き込み回数検知回路3およびアクセス先メモリ切り替え回路4の動作を説明する通信タイムチャートである。
FIG. 2 is a communication time chart for explaining operations of the
プログラマブルロジックコントローラ100の電源がオンにされると、初期処理として、マイクロプロセッサー1は、ファームウェアを実行することにより書き込み回数の閾値を書き込み回数検知回路3に設定する(ステップS1)。さらに、マイクロプロセッサー1は、ファームウェアから読み取った計測時間を書き込み回数検知回路3に設定する(ステップS2)。また、プログラマブルロジックコントローラ100の電源がオンにされると、書き込み回数検知回路3は、タイマを起動させて電源がオンになってからの時間の計測を開始する。
When the power of the
書き込み回数の閾値および計測時間が設定された書き込み回数検知回路3は、マイクロプロセッサー1のアクセス先を不揮発性メモリ6に設定するようにアクセス先メモリ切り替え回路4に命じる(ステップS3)。これにより、マイクロプロセッサー1のメモリアクセス開始時のアクセス先、すなわちデータの書き込み先および読み出し元は、不揮発性メモリ6に設定される。そして、書き込み回数検知回路3は、タイマ起動後の不揮発性メモリ6への書き込み動作を制御線8を介して検知して書き込み回数の記録を開始する(ステップS4)。不揮発性メモリ6へ書き込まれるデータは、プログラマブルロジックコントローラ100に接続された外部機器50の制御または監視のためのデータであり、頻繁に書き換えられることが想定される。
The write count detection circuit 3 in which the write count threshold and measurement time are set instructs the access destination memory switching circuit 4 to set the access destination of the
その後、タイマの計測した時間が設定された計測時間を経た時点で、書き込み回数検知回路3は、不揮発性メモリ6への計測時間内の書き込み回数と閾値とを比較する(ステップS5)。不揮発性メモリ6への書き込み回数が閾値を超えた場合は、書き込み回数検知回路3はアクセス先切り替え信号を送信し、アクセス先メモリ切り替え回路4にマイクロプロセッサー1のアクセス先を不揮発性メモリ6から揮発性メモリ5に切り替えさせる(ステップS6)。その後、マイクロプロセッサー1からの外部機器50のデータは、揮発性メモリ5のデータ保持エリア51に書き込まれる。
Thereafter, when the time measured by the timer has passed the set measurement time, the write count detection circuit 3 compares the write count within the measurement time to the nonvolatile memory 6 with a threshold value (step S5). When the number of writes to the nonvolatile memory 6 exceeds the threshold value, the write number detection circuit 3 transmits an access destination switching signal, and the access destination of the
ステップS6を経て、データ保持エリア51にデータが書き込まれた後、予め定めたタイミングで、データ保持エリア51に書き込まれたデータを不揮発性メモリ6へ書き移す。具体的には、ステップS6の切り替えが生じてから予め定めたタイミングで、マイクロプロセッサー1は、データ保持エリア51に書き込まれたデータをRAM7に読み出し、制御線10を介してアクセス先メモリ切り替え回路4にマイクロプロセッサー1のアクセス先を揮発性メモリ5から不揮発性メモリ6に切り替えさせる(ステップS7)。そして、マイクロプロセッサー1はデータ保持エリア51から読み出したデータを不揮発性メモリ6に書き込む。このとき、データ保持エリア51に書き込まれたデータを纏めて不揮発性メモリ6に書き込む。データ保持エリア51から読み出したデータを不揮発性メモリ6に書き込むと、マイクロプロセッサー1は、制御線10を介してアクセス先メモリ切り替え回路4にマイクロプロセッサー1のアクセス先を不揮発性メモリ6から揮発性メモリ5に戻すように切り替えさせる(ステップS8)。
After the data is written in the
上記したデータの書き移し動作、すなわちステップS7およびS8は繰り返し実行される。すなわち、ステップS8の切り替えが生じてから予め定めたタイミングで、マイクロプロセッサー1は、再度ステップS7を実行する。マイクロプロセッサー1によるステップS7およびS8の繰り返しは、定期的に実行してもよい。プログラマブルロジックコントローラ100は、ラダープログラムといったユーザプログラムをスキャンタイムの間に1回実行し、これを反復的に繰り返す。従って、ステップS7およびS8を定期的に実行する具体例としては、スキャンタイムとスキャンタイムとの間であるシステム処理中のタイミングで実行する。このように、データの書き移し動作をスキャンタイム中のメモリアクセスとは独立して実行させることで、マイクロプロセッサー1のメモリアクセス速度の低下を回避することができる。ただし、データの書き移し動作は、他のタイミングで実行してもかまわない。
The above-described data transfer operation, that is, steps S7 and S8 are repeatedly executed. That is, the
上記したように、データ保持エリア51に書き込まれたデータを纏めて不揮発性メモリ6に書き込むことにより、揮発性メモリ5を用いないで、不揮発性メモリ6に全てデータを書き込んでいった場合に比べて、不揮発性メモリ6への書き込み回数を大幅に削減することが可能となる。すなわち、マイクロプロセッサー1からのデータ書き込み速度は維持したまま、ステップS6以降の不揮発性メモリ6への書き込み頻度を低減させることが可能になる。なお、ステップS5で不揮発性メモリ6への書き込み回数が閾値を超えない場合は、ステップS6からS8は実行されない。
As described above, the data written in the
その後、プログラマブルロジックコントローラ100が電源オフの指示を受けると、マイクロプロセッサー1は、書き込み回数検知回路3に電源がオフになることを通知する(ステップS9)。通知を受けた書き込み回数検知回路3は、タイマ起動後の不揮発性メモリ6への書き込みの総回数およびタイマで測定したプログラマブルロジックコントローラ100の電源がオンになってからの稼働時間をマイクロプロセッサー1に送信する(ステップS10)。マイクロプロセッサー1は、受信した不揮発性メモリ6への書き込みの稼働時間内の総回数および稼働時間をROM2或いは不揮発性メモリ6に記録する。その後、プログラマブルロジックコントローラ100の電源はオフされる。なお、プログラマブルロジックコントローラ100が電源オフの指示を受けない場合であっても、ステップS10は一定時間毎に実行されてもよい。この場合は、ステップS9を除いたステップS1からステップS10までの処理が一定時間毎に実行されることになる。
Thereafter, when the
以上説明したように、実施の形態1にかかるプログラマブルロジックコントローラ100においては、マイクロプロセッサー1から高速なデータの書き込みが発生した場合は、揮発性メモリ5に一旦データを書き込んで、その後、揮発性メモリ5に書き込まれたデータは、纏めて不揮発性メモリ6へ書き込む。これにより、マイクロプロセッサー1からメモリへの書き込み性能に影響を与えずに、不揮発性メモリ6への書き込み回数を低減することが可能になる。それと共に、プログラマブルロジックコントローラ100の電源がオフになった時に揮発性メモリ5の記憶を保持させるためのバッテリも不要となる。すなわち、記憶データの保証とバッテリレス化の両立が可能になる。また、マイクロプロセッサー1とは別に、書き込み回数検知回路3およびアクセス先メモリ切り替え回路4を設けるので、マイクロプロセッサー1の処理負担の増大も回避できる。
As described above, in the
図3は、実施の形態1にかかるマイクロプロセッサー1が不揮発性メモリ6の書き込み回数の閾値を変更するためのフローチャートである。上記したように不揮発性メモリ6への書き込みの総回数および稼働時間が記録された後に、ROM2に記憶されたファームウェアをマイクロプロセッサー1が実行することにより、図3のフローチャートは実行される。
FIG. 3 is a flowchart for the
まず、マイクロプロセッサー1は、図2のステップS10で受信して記録された稼働時間とプログラマブルロジックコントローラ100の現在の残存保証期間Tn(n=0,1,2,・・・)とから、新たな残存保証期間Tn+1を求める(ステップS11)。現在の残存保証期間Tnは、記録された稼働時間の始点でプログラマブルロジックコントローラ100の動作が保証される期間であって、図3のフローチャートを最初に実行する場合は、プログラマブルロジックコントローラ100の最初の保証期間T0となる。従って、新たな残存保証期間Tn+1は、現在の残存保証期間TnからステップS10で受信して記録した稼働時間を減じた値となる。First, the
ステップS11の後、マイクロプロセッサー1は、不揮発性メモリ6の書き込み回数の閾値の前回の設定から定めた期間が経過しているか否かを判定する(ステップS12)。この定めた期間は、具体的には、計測時間より長い期間であって、年単位の期間を用いることができる。不揮発性メモリ6の書き込み回数の閾値の前回の設定から定めた期間が経過していない場合(ステップS12:No)は終了である。
After step S11, the
不揮発性メモリ6の書き込み回数の閾値の前回の設定から定めた期間が経過している場合(ステップS12:Yes)は、マイクロプロセッサー1は、不揮発性メモリ6へ書き込み可能な回数の新たな上限値Nn+1(n=0,1,2,・・・)を求める(ステップS13)。具体的には、不揮発性メモリ6の書き込み回数の現在の上限値Nnから図2のステップS10で受信して記録した稼働時間内の不揮発性メモリ6への書き込みの総回数を減じることにより不揮発性メモリ6へ書き込み可能な回数の新たな上限値Nn+1を求めることができる。図3のフローチャートを最初に実行する場合の不揮発性メモリ6の書き込み回数の現在の上限値Nnは、最初の上限値N0となる。If the predetermined period has elapsed since the previous setting of the threshold value of the number of times of writing in the nonvolatile memory 6 (step S12: Yes), the
そして、マイクロプロセッサー1は、ステップS11で求めた新たな残存保証期間Tn+1と、ステップS13で求めた不揮発性メモリ6へ書き込み可能な回数の新たな上限値Nn+1と、に基づいて、不揮発性メモリ6への書き込み回数の新たな閾値を求めて、閾値を変更する(ステップS14)。新たな閾値は、不揮発性メモリ6への書き込み可能な回数の新たな上限値Nn+1を新たな残存保証期間Tn+1で割った値に計測時間を乗じた数値といった値を参考にして、新たな残存保証期間Tn+1内に書き込み回数が新たな上限値Nn+1を超えないような安全側の条件として求める。Then, the
以上説明した、図3のフローチャートは、マイクロプロセッサー1が不揮発性メモリ6への書き込みの総回数および稼働時間を記録した後であって、プログラマブルロジックコントローラ100の電源が実際にオフにされるまでの間に実行されてもよいし、プログラマブルロジックコントローラ100の電源が再度オンにされた直後に実行されてもよい。なお、上述したようにステップS10が一定時間毎に実行される場合は、プログラマブルロジックコントローラ100の電源がオフにされるまでの間に図3のフローチャートも一定時間毎に実行される。
The flowchart of FIG. 3 described above is after the
プログラマブルロジックコントローラ100の電源が再度オンされると、それから電源がオフされるまでの次の稼働時間においては、ステップS14で求めた新たな閾値を用いて、図2で説明した動作が再度実行される。その後、図3のフローチャートも再度実行される。このように、図2および図3の動作は交互に実行される。したがって、プログラマブルロジックコントローラ100の電源がオフにされるまでの間に図3のフローチャートが一定時間毎に実行される場合は、その都度その後に実行される図2で説明した動作においては、直前のステップS14で求めた新たな閾値が用いられる。このようにして、図2および図3の動作は、プログラマブルロジックコントローラ100の電源がオンとなる毎に、または一定時間毎に繰り返し実行される。なお、ステップS14では、新たな残存保証期間Tn+1と不揮発性メモリ6へ書き込み可能な回数の新たな上限値Nn+1とに基づいて、閾値に加えて計測時間も変更してかまわない。When the power of the
図3のフローチャートを実行することにより、図2のステップS10で受信して記録した稼働時間に対する不揮発性メモリ6への書き込みの総回数の割合が、現在の残存保証期間Tnに対する書き込み回数の現在の上限値Nnの割合に比べて小さい場合は、ステップS14で新たな閾値を前より大きな値に変更することで、揮発性メモリ5への切り替え条件を緩和することが可能となる。これにより、厳しい閾値により揮発性メモリ5への切り替えが頻繁に発生することを防ぐことができる。By executing the flowchart in FIG. 3, the ratio of the total number of writes to nonvolatile memory 6 for operating time recorded is received by the step S10 in FIG. 2, the current write count for the current remaining warranty period T n When the ratio is smaller than the ratio of the upper limit value N n , the switching condition to the
以上の実施の形態に示した構成は、本発明の内容の一例を示すものであり、別の公知の技術と組み合わせることも可能であるし、本発明の要旨を逸脱しない範囲で、構成の一部を省略、変更することも可能である。 The configuration described in the above embodiment shows an example of the contents of the present invention, and can be combined with another known technique, and can be combined with other configurations without departing from the gist of the present invention. It is also possible to omit or change the part.
1 マイクロプロセッサー、2 ROM、3 書き込み回数検知回路、4 アクセス先メモリ切り替え回路、5 揮発性メモリ、6 不揮発性メモリ、7 RAM、8,9,10 制御線、50 外部機器、71,72,73 バス、100 プログラマブルロジックコントローラ。 1 Microprocessor, 2 ROM, 3 Write count detection circuit, 4 Access destination memory switching circuit, 5 Volatile memory, 6 Non-volatile memory, 7 RAM, 8, 9, 10 Control line, 50 External device, 71, 72, 73 Bus, 100 Programmable logic controller.
Claims (2)
前記データを記憶する不揮発性メモリと、
前記データを前記揮発性メモリまたは前記不揮発性メモリに書き込む制御部と、
前記制御部から前記不揮発性メモリへの書き込み回数を検知する書き込み回数検知回路と、
前記制御部からの前記データの書き込み先を前記揮発性メモリまたは前記不揮発性メモリのいずれかに切り替えるアクセス先メモリ切り替え回路と、
を備え、
前記アクセス先メモリ切り替え回路は、前記書き込み回数が計測時間内に閾値を超えた場合は、前記データの書き込み先を前記不揮発性メモリから前記揮発性メモリに切り替え、前記制御部は、前記アクセス先メモリ切り替え回路が前記データの書き込み先を前記不揮発性メモリから前記揮発性メモリに切り替えた後に、前記揮発性メモリに書き込まれた前記データを前記不揮発性メモリへ書き込み、稼働時間と、前記稼働時間の始点で動作が保証される期間と、前記稼働時間内の前記不揮発性メモリへの書き込みの総回数とに基づいて、次の稼働時間における前記閾値を変更する
ことを特徴とするプログラマブルロジックコントローラ。 Volatile memory for storing data;
A non-volatile memory for storing the data;
A control unit for writing the data to the volatile memory or the nonvolatile memory;
A writing number detection circuit for detecting the number of writings from the control unit to the nonvolatile memory;
An access destination memory switching circuit that switches the write destination of the data from the control unit to either the volatile memory or the nonvolatile memory;
With
The access destination memory switching circuit switches the data write destination from the nonvolatile memory to the volatile memory when the number of times of writing exceeds a threshold value within a measurement time, and the control unit After the switching circuit switches the data write destination from the nonvolatile memory to the volatile memory, the data written to the volatile memory is written to the nonvolatile memory, the operation time, and the start point of the operation time The threshold value in the next operation time is changed based on a period during which the operation is guaranteed at and the total number of writes to the nonvolatile memory within the operation time.
ことを特徴とする請求項1に記載のプログラマブルロジックコントローラ。 The programmable logic controller according to claim 1 , wherein the control unit changes the threshold value after a period longer than the measurement time.
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/JP2016/051037 WO2017122332A1 (en) | 2016-01-14 | 2016-01-14 | Programmable logic controller |
Publications (2)
Publication Number | Publication Date |
---|---|
JP6113374B1 true JP6113374B1 (en) | 2017-04-12 |
JPWO2017122332A1 JPWO2017122332A1 (en) | 2018-01-18 |
Family
ID=58666767
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2016559470A Expired - Fee Related JP6113374B1 (en) | 2016-01-14 | 2016-01-14 | Programmable logic controller |
Country Status (2)
Country | Link |
---|---|
JP (1) | JP6113374B1 (en) |
WO (1) | WO2017122332A1 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10514858B2 (en) | 2017-08-30 | 2019-12-24 | Fujitsu Limited | Information processing apparatus, computer-readable recording medium, and information processing method |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2023162544A1 (en) * | 2022-02-24 | 2023-08-31 | 株式会社デンソートリム | Engine control device |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH0675836A (en) * | 1992-08-25 | 1994-03-18 | Nippon Densan Corp | Auxiliary storage device |
JPH10154005A (en) * | 1996-11-25 | 1998-06-09 | Meidensha Corp | Input/output control system for programmable controller |
JP2013182505A (en) * | 2012-03-02 | 2013-09-12 | Toshiba Corp | Storage system and driving method thereof |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012226575A (en) * | 2011-04-20 | 2012-11-15 | Mitsubishi Electric Corp | Method for storing data in non-volatile memory and control device |
-
2016
- 2016-01-14 JP JP2016559470A patent/JP6113374B1/en not_active Expired - Fee Related
- 2016-01-14 WO PCT/JP2016/051037 patent/WO2017122332A1/en active Application Filing
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH0675836A (en) * | 1992-08-25 | 1994-03-18 | Nippon Densan Corp | Auxiliary storage device |
JPH10154005A (en) * | 1996-11-25 | 1998-06-09 | Meidensha Corp | Input/output control system for programmable controller |
JP2013182505A (en) * | 2012-03-02 | 2013-09-12 | Toshiba Corp | Storage system and driving method thereof |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10514858B2 (en) | 2017-08-30 | 2019-12-24 | Fujitsu Limited | Information processing apparatus, computer-readable recording medium, and information processing method |
Also Published As
Publication number | Publication date |
---|---|
JPWO2017122332A1 (en) | 2018-01-18 |
WO2017122332A1 (en) | 2017-07-20 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2017054487A1 (en) | Power-down protection method and apparatus, and electronic device | |
US8683249B2 (en) | Switching a processor and memory to a power saving mode when waiting to access a second slower non-volatile memory on-demand | |
JP5981906B2 (en) | Image forming apparatus | |
JP6113374B1 (en) | Programmable logic controller | |
JP7095566B2 (en) | Memory controller and flash memory system equipped with it | |
US20210096770A1 (en) | Memory system, memory system control method, and information processing system | |
JP2010204851A (en) | Storage device and information processing apparatus | |
US10915257B2 (en) | Semiconductor device and semiconductor system | |
JP6148129B2 (en) | Information processing apparatus, firmware update method, and firmware update program | |
JP5875558B2 (en) | Information processing device | |
JP5915740B2 (en) | Programmable controller and power-off countermeasure method | |
JP6672623B2 (en) | Control system and its control device | |
JP5450352B2 (en) | Power supply monitoring apparatus and information processing apparatus | |
JP6123282B2 (en) | Programmable controller and power-off countermeasure method | |
JP2009230425A (en) | Information processor | |
JP7007223B2 (en) | Control device and abnormality detection method | |
KR20180039802A (en) | Data storage device and operating method thereof | |
JP2008096381A (en) | Data recorder | |
JP2005078489A (en) | Microcontroller and its control method | |
US20230335198A1 (en) | Semiconductor device | |
JP2013171600A (en) | Nonvolatile memory device | |
WO2018186453A1 (en) | Nonvolatile memory with increased number of usable times | |
JP2014071834A (en) | Communication device and program | |
JP6079915B2 (en) | Programmable controller and power-off countermeasure method | |
JP2014229116A (en) | Programmable controller and method for coping with power disconnection |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
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: 20170214 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20170314 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6113374 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
LAPS | Cancellation because of no payment of annual fees |