[go: up one dir, main page]

JP2025104069A - Embedded Devices - Google Patents

Embedded Devices Download PDF

Info

Publication number
JP2025104069A
JP2025104069A JP2023221901A JP2023221901A JP2025104069A JP 2025104069 A JP2025104069 A JP 2025104069A JP 2023221901 A JP2023221901 A JP 2023221901A JP 2023221901 A JP2023221901 A JP 2023221901A JP 2025104069 A JP2025104069 A JP 2025104069A
Authority
JP
Japan
Prior art keywords
embedded device
eeprom
operation log
cpu
flash rom
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2023221901A
Other languages
Japanese (ja)
Inventor
宏 松藤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fuji Electric Co Ltd
Original Assignee
Fuji Electric Co Ltd
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 Fuji Electric Co Ltd filed Critical Fuji Electric Co Ltd
Priority to JP2023221901A priority Critical patent/JP2025104069A/en
Publication of JP2025104069A publication Critical patent/JP2025104069A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Control Of Vending Devices And Auxiliary Devices For Vending Devices (AREA)
  • Memory System (AREA)

Abstract

Figure 2025104069000001

【課題】小規模な組み込み機器であっても装置構成に影響を及ぼさずに大容量の稼働ログを確実に保持することができる組み込み機器を提供する。
【解決手段】上位の主装置に組み込まれる組み込み機器であるコインメック11であって、コインメック11内の制御基板20上において制御基板20上のCPU21に接続され、コインメック11が取り扱う稼働ログをリアルタイムに一時的に記憶するEEPROM24を備え、CPU21は、所定条件が合致したタイミングでEEPROM24に一時記憶された稼働ログをコインメック11内あるいはコインメック11外の他の記憶媒体に転送する。例えば、EEPROM24内の稼働ログをフラッシュROM23内の稼働ログ領域に一括転送する。
【選択図】図2

Figure 2025104069000001

An object of the present invention is to provide an embedded device that can reliably hold a large capacity operation log without affecting the device configuration, even if the embedded device is small in size.
[Solution] The coin mech 11 is an embedded device incorporated in a higher-level main device, and is equipped with an EEPROM 24 that is connected to a CPU 21 on a control board 20 inside the coin mech 11 and temporarily stores operation logs handled by the coin mech 11 in real time, and when a predetermined condition is met, the CPU 21 transfers the operation logs temporarily stored in the EEPROM 24 to another storage medium inside the coin mech 11 or outside the coin mech 11. For example, the operation logs in the EEPROM 24 are transferred all at once to an operation log area in a flash ROM 23.
[Selected figure] Figure 2

Description

本発明は、小規模な組み込み機器であっても装置構成に影響を及ぼさずに大容量の稼働ログを確実に保持することができる組み込み機器に関する。 The present invention relates to an embedded device that can reliably store large volumes of operation logs without affecting the device configuration, even if the device is small-scale.

自動販売機には、硬貨処理装置(コインメック)や紙幣処理装置(ビルバリ)などが組み込み機器として搭載される。これらの組み込み機器は、貨幣の汚れ、摩擦や粉塵等に起因した障害が発生する場合があり、動作寿命が設けられているとともに、障害発生時の動作状況を把握する必要がある。このため、これらの組み込み機器は稼働ログを記憶するようにしている。稼働データとしては、組み込み機器の保証期間を特定する稼働時間、動作寿命を特定する貨幣の受け入れ枚数や払い出し枚数、故障発生履歴や回数、受け入れ貨幣のセンサーデータ、上位の主装置との通信ログなどである。 Vending machines are equipped with built-in devices such as a coin handling device (coin mechanism) and a bill validator (bill validator). These built-in devices can malfunction due to dirt on the currency, friction, dust, etc., so they have an operating lifespan and it is necessary to know the operating status when a malfunction occurs. For this reason, these built-in devices are designed to store operation logs. Operational data includes the operating time that determines the warranty period of the built-in device, the number of accepted and dispensed currency that determines the operating lifespan, the history and number of malfunctions, sensor data on accepted currency, and communication logs with the higher-level main unit.

ここで、特許文献1では、不揮発性メモリであるEEPROM(Electronically Erasable and Programmable Read Only Memory)を組み込み機器内に搭載し、組み込み機器内の稼働ログを選択的に記憶するようにしている。 Here, in Patent Document 1, an EEPROM (Electronically Erasable and Programmable Read Only Memory), which is a non-volatile memory, is installed in the embedded device, and operation logs within the embedded device are selectively stored.

特開2004-318472号公報JP 2004-318472 A

ところで、組み込み機器内に保持すべき稼働ログの情報量は多い方が望ましいが、小規模かつ安価な組み込み機器では搭載可能な不揮発性メモリが限られる。ここで、EEPROMなどの不揮発性メモリを用いることが考えられるが記憶容量を大きくすると、組み込み機器の装置規模に影響を及ぼすとともにコストアップとなる。 Incidentally, it is desirable to store a large amount of operation log information within an embedded device, but small, inexpensive embedded devices are limited in the amount of non-volatile memory that can be installed. In this case, it is possible to use non-volatile memory such as EEPROM, but increasing the memory capacity will affect the size of the embedded device and increase costs.

本発明は、上記に鑑みてなされたものであって、小規模な組み込み機器であっても装置構成に影響を及ぼさずに大容量の稼働ログを確実に保持することができる組み込み機器を提供することを目的とする。 The present invention has been made in consideration of the above, and aims to provide an embedded device that can reliably store large amounts of operation logs without affecting the device configuration, even if the embedded device is small in size.

上述した課題を解決し、目的を達成するために、本発明は、上位の主装置に組み込まれる組み込み機器であって、前記組み込み機器内の制御基板上において該制御基板上のCPUに接続され、該組み込み機器が取り扱う稼働ログをリアルタイムに一時的に記憶するEEPROMを備え、前記CPUは、所定条件が合致したタイミングで前記EEPROMに一時記憶された前記稼働ログを前記組み込み機器内あるいは前記組み込み機器外の他の記憶媒体に転送することを特徴とする。 To solve the above problems and achieve the object, the present invention provides an embedded device that is incorporated into a higher-level main unit, and includes an EEPROM that is connected to a CPU on a control board within the embedded device and temporarily stores operation logs handled by the embedded device in real time, and the CPU transfers the operation logs temporarily stored in the EEPROM to another storage medium within the embedded device or outside the embedded device when a predetermined condition is met.

また、本発明は、上記の発明において、前記所定条件は、前記EEPROMの空き領域が所定値未満となる場合であることを特徴とする。 In the above invention, the predetermined condition is when the free space in the EEPROM is less than a predetermined value.

また、本発明は、上記の発明において、前記所定条件は、前記主装置がアイドル状態となった場合であることを特徴とする。 In the above invention, the predetermined condition is when the main device is in an idle state.

また、本発明は、上記の発明において、前記所定条件は、定期的な所定時刻になった場合であることを特徴とする。 The present invention is also characterized in that, in the above invention, the predetermined condition is when a regular predetermined time is reached.

また、本発明は、上記の発明において、前記他の記憶媒体は、前記CPUのフラッシュROMであり、前記フラッシュROMは、機器制御プログラム領域と稼働ログ領域とに分割され、前記CPUは、前記EEPROMに一時記憶された稼働ログを前記稼働ログ領域に転送することを特徴とする。 The present invention is also characterized in that, in the above invention, the other storage medium is a flash ROM of the CPU, the flash ROM is divided into a device control program area and an operation log area, and the CPU transfers the operation log temporarily stored in the EEPROM to the operation log area.

また、本発明は、上記の発明において、前記EEPROMの記憶容量は、前記フラッシュROMの記憶容量よりも小さいことを特徴とする。 The present invention is also characterized in that, in the above invention, the storage capacity of the EEPROM is smaller than the storage capacity of the flash ROM.

また、本発明は、上記の発明において、前記CPUは、前記EEPROMに一時記憶された前記稼働ログが前記他の記憶媒体に対する転送が完了した場合に前記EEPROM内の稼働ログを消去することを特徴とする。 In the above invention, the CPU erases the operation log temporarily stored in the EEPROM when the transfer of the operation log to the other storage medium is completed.

また、本発明は、上記の発明において、前記CPUは、前記組み込み機器外の他の記憶媒体に転送する場合、前記稼働ログには、該組み込み機器の識別番号が付されることを特徴とする。 In the above invention, when the CPU transfers the operation log to another storage medium outside the embedded device, the operation log is assigned the identification number of the embedded device.

本発明によれば、小規模な組み込み機器であっても装置構成に影響を及ぼさずに大容量の稼働ログを確実に保持することができる。 According to the present invention, even small-scale embedded devices can reliably store large volumes of operation logs without affecting the device configuration.

図1は、組み込み機器であるコインメックやビルバリを搭載する上位の主装置である自動販売機の概要構成を示すブロック図である。FIG. 1 is a block diagram showing the general configuration of a vending machine, which is a higher-level main device equipped with a coin mechanism and a bill validator, which are built-in devices. 図2は、組み込み機器であるコインメックの構成を示すブロック図である。FIG. 2 is a block diagram showing the configuration of a coin mechanism which is an embedded device. 図3は、稼働ログの記憶処理を説明する説明図である。FIG. 3 is an explanatory diagram illustrating the operation log storage process. 図4は、コインメックの稼働ログの一例を示す図である。FIG. 4 is a diagram showing an example of an operation log of the coin mechanism. 図5は、CPUによる稼働ログの記憶処理手順を示すフローチャートである。FIG. 5 is a flowchart showing a procedure of the operation log storage process performed by the CPU. 図6は、変形例1のCPUによる稼働ログの記憶処理手順を示すフローチャートである。FIG. 6 is a flowchart showing a process of storing an operation log by a CPU according to the first modification. 図7は、変形例2のCPUによる稼働ログの記憶処理手順を示すフローチャートである。FIG. 7 is a flowchart showing a process of storing an operation log by a CPU according to the second modification.

以下、添付図面を参照してこの発明を実施するための形態について説明する。 The following describes the embodiment of the invention with reference to the attached drawings.

<自動販売機の構成>
図1は、組み込み機器であるコインメック11やビルバリ12を搭載する上位の主装置である自動販売機1の概要構成を示すブロック図である。なお、自動販売機1は、ネットワークなどを介してさらに上位の管理サーバ100などに接続される。自動販売機1は、例えば缶入り飲料、ビン入り飲料、ペットボトル入り飲料などの商品を販売する自動販売機であるが、各種の自動販売機であってもよく、例えばカップ式自動販売機であってもよい。
<Vending machine configuration>
1 is a block diagram showing the general configuration of a vending machine 1, which is a higher-level main device equipped with a built-in device such as a coin mechanism 11 and a bill validator 12. The vending machine 1 is further connected to a higher-level management server 100 via a network or the like. The vending machine 1 is a vending machine that sells products such as canned drinks, bottled drinks, and PET bottled drinks, but it may be any type of vending machine, such as a cup-type vending machine.

図1に示すように、自動販売機1は、自販機主制御部8を有し、自販機主制御部8には、表示部2、商品選択部3、金銭処理部4、商品払出部5、冷熱部6、通信部7が接続される。 As shown in FIG. 1, the vending machine 1 has a vending machine main control unit 8, which is connected to a display unit 2, a product selection unit 3, a money handling unit 4, a product dispensing unit 5, a cooling/heating unit 6, and a communication unit 7.

表示部2は、販売中、釣り切れ、準備中、お札中止のほか、投入金額、各種設定時の情報等の各種情報を表示する。商品選択部3は、商品選択ボタンであり、商品価格や販売状態を表示機能も有する。 The display unit 2 displays various information such as on sale, out of change, in preparation, and bill cancellation, as well as the amount inserted and information on various settings. The product selection unit 3 is a product selection button, and also has the function of displaying product prices and sales status.

金銭処理部4は、コインメック11、ビルバリ12、電子決済部13を有する。コインメック11は、各種硬貨の投入枚数を整理し、自販機主制御部8に送信する一方、この自販機主制御部8からの指令に従い、各種硬貨を払い出す。なお、コインメック11は、硬貨の真贋及び金種を識別する金銭識別機能を有する。 The money processing unit 4 has a coin mech 11, a bill validator 12, and an electronic payment unit 13. The coin mech 11 organizes the numbers of various coins inserted and sends this to the vending machine main control unit 8, while dispensing various coins according to instructions from the vending machine main control unit 8. The coin mech 11 also has a money identification function that identifies the authenticity and denomination of coins.

ビルバリ12は、紙幣の投入枚数を整理し、自販機主制御部8に送信する一方、この自販機主制御部8からの指令に従い、紙幣を払い出す。なお、ビルバリ12は、紙幣の真贋及び金種を識別する金銭識別機能を有する。 The bill validator 12 counts the number of bills inserted and sends this to the vending machine main control unit 8, while dispensing the bills according to instructions from the vending machine main control unit 8. The bill validator 12 also has a money identification function that identifies the authenticity and denomination of bills.

電子決済部13は、例えば、電子マネーリーダライタであり、電子マネーカードにチャージされた電子マネーを読み込みむとともに、決済後の電子マネーを書き込む処理を行う。また、電子決済部13は、電子マネーカードに釣銭分の電子マネーをチャージする書き込み処理を行う。電子決済部13は、電子マネーカードを検出するとともに電子マネーカードの有効無効や種別を識別する電子マネー識別機能を有する。 The electronic payment unit 13 is, for example, an electronic money reader/writer, and performs a process of reading the electronic money loaded onto the electronic money card and writing the electronic money after payment. The electronic payment unit 13 also performs a writing process of loading the electronic money for change onto the electronic money card. The electronic payment unit 13 has an electronic money identification function that detects the electronic money card and identifies whether the electronic money card is valid or invalid and the type of the electronic money card.

商品払出部5は、ラックごとに設けられたベンドソレノイド、売切スイッチを管理し、自販機主制御部8から送信された搬出命令に従ってラックから商品を搬出する。また、商品払出部5は、ラックに収納された商品のすべてを搬出した場合に売切信号を自販機主制御部8に出力する。 The product dispensing unit 5 manages the bend solenoids and sold-out switches provided for each rack, and dispenses products from the rack in accordance with dispense commands sent from the vending machine main control unit 8. The product dispensing unit 5 also outputs a sold-out signal to the vending machine main control unit 8 when all products stored in the rack have been dispensed.

冷熱部6は、本体キャビネット内の商品収納庫を設定された状態に管理し、冷却設定された商品収納庫の内部を冷却する一方、加温設定された商品収納庫の内部を加温する。 The cooling/heating section 6 manages the product storage compartments in the main cabinet to a set state, cooling the inside of the product storage compartments that are set to be cooled, while heating the inside of the product storage compartments that are set to be heated.

通信部7は、外部の管理サーバ100との通信を行うための通信インターフェースである。 The communication unit 7 is a communication interface for communicating with an external management server 100.

自販機主制御部8は、商品選択部3によって選択された商品の払い出し、決済処理等を行う。なお、メモリ18は、売上データ、設定データ、制御プログラムを有する。 The vending machine main control unit 8 dispenses the product selected by the product selection unit 3, processes payments, etc. The memory 18 stores sales data, setting data, and control programs.

<組み込み機器の構成>
図2は、組み込み機器であるコインメック11の構成を示すブロック図である。図2に示すように、コインメック11は、制御基板20、貨幣受入機構部31、貨幣払出機構部32を有する。制御基板20は、コインメック11の全体を制御する機能を有する基板である。貨幣受入機構部31は、硬貨を受け入れて識別する機構部である。また、貨幣払出機構部32は、釣銭がある場合に硬貨を払い出す機構部である。なお、コインメック11は、硬貨が識別できなかった場合、そのまま払い出す。
<Configuration of embedded devices>
Fig. 2 is a block diagram showing the configuration of the coin mech 11, which is an embedded device. As shown in Fig. 2, the coin mech 11 has a control board 20, a money receiving mechanism 31, and a money dispensing mechanism 32. The control board 20 is a board that has the function of controlling the entire coin mech 11. The money receiving mechanism 31 is a mechanism that receives and identifies coins. Furthermore, the money dispensing mechanism 32 is a mechanism that pays out coins when change is available. Note that if the coin mech 11 cannot identify the coin, it pays it out as is.

制御基板は、CPU21、EEPROM24、検銭・鑑別回路25、機器駆動制御回路26、センサ部27を有する。CPU21は、揮発性メモリであるSRAM(Static Random Access Memory)22、不揮発性メモリであるフラッシュROM(Flash ROM)23を有する。CPU21は、フラッシュROM23内に保持された機器制御プログラムをもとに各種演算処理を行う。この際、SRAM22はキャッシュメモリとして機能する。EEPROM24は、コインメック11の稼働データを稼働ログとしてリアルタイムに一時記憶する不揮発性メモリである。このEEPROM24の記憶容量は、フラッシュROM23の記憶容量に比して小さく、一定量の稼働ログを一時記憶する。 The control board has a CPU 21, an EEPROM 24, a coin validation and identification circuit 25, a device drive control circuit 26, and a sensor unit 27. The CPU 21 has a static random access memory (SRAM) 22, which is a volatile memory, and a flash ROM (Flash ROM) 23, which is a non-volatile memory. The CPU 21 performs various calculation processes based on the device control program stored in the flash ROM 23. At this time, the SRAM 22 functions as a cache memory. The EEPROM 24 is a non-volatile memory that temporarily stores operation data of the coin mechanism 11 in real time as an operation log. The storage capacity of this EEPROM 24 is smaller than that of the flash ROM 23, and it temporarily stores a certain amount of operation log.

フラッシュROMの機器制御プログラムには、稼働データをリアルタイムでEEPROM24に一時記憶し、所定条件が合致したタイミングでEEPROM24に一時記憶された稼働ログをフラッシュROM23に転送するプログラムが含まれる。この所定条件は、例えばEEPROM24の空き領域が所定値未満となる場合である。すなわち、EEPROM24内に一時記憶された稼働ログの記憶量に所定マージン(空き容量)を加えた量がEEPROM24の記憶容量を超える場合である。 The device control program in the flash ROM includes a program that temporarily stores operation data in EEPROM 24 in real time, and transfers the operation log temporarily stored in EEPROM 24 to flash ROM 23 when a specified condition is met. This specified condition is, for example, when the free space in EEPROM 24 falls below a specified value. In other words, the amount of storage of the operation log temporarily stored in EEPROM 24 plus a specified margin (free space) exceeds the storage capacity of EEPROM 24.

検銭・鑑別回路25は、投入された硬貨が正貨であるか否かを鑑別し、金種を識別する。機器駆動制御回路26は、貨幣受入機構部31及び貨幣払出機構部32を駆動制御する回路である。センサ部27は、貨幣受入機構部31及び貨幣払出機構部32の状態を検出する。検銭・鑑別回路25又は機器駆動制御回路26は、この検出結果をもとに回路を動作させる。 The validation and identification circuit 25 determines whether the inserted coins are genuine and identifies the denomination. The device drive control circuit 26 is a circuit that drives and controls the money receiving mechanism 31 and the money dispensing mechanism 32. The sensor unit 27 detects the state of the money receiving mechanism 31 and the money dispensing mechanism 32. The validation and identification circuit 25 or the device drive control circuit 26 operates the circuit based on the detection result.

<稼働ログの記憶処理>
図3は、稼働ログの記憶処理を説明する説明図である。図3に示すように、CPU21は、EEPROM24にリアルタイムで発生した稼働データを稼働ログとして一時記憶する。この稼働ログは、稼働ログ一時記憶領域E10に一時記憶される。そして、EEPROM24の空き領域が所定値未満になると、フラッシュROM23の稼働ログ領域E1に一括転送し、転送後に稼働ログ一時記憶領域E10内の稼働ログを消去し、空き領域にする。
<Operation log storage process>
Fig. 3 is an explanatory diagram illustrating the operation log storage process. As shown in Fig. 3, the CPU 21 temporarily stores operation data generated in real time in the EEPROM 24 as an operation log. This operation log is temporarily stored in the operation log temporary storage area E10. Then, when the free space in the EEPROM 24 falls below a predetermined value, the operation log is transferred in one go to the operation log area E1 in the flash ROM 23, and after the transfer, the operation logs in the operation log temporary storage area E10 are erased to make the area free.

ここで、フラッシュROM23は、基本的に機器制御プログラムを記憶するが、空き領域も存在し、フラッシュROM23は、稼働ログ領域E1と機器制御プログラム領域E2とに分割され、稼働ログ領域E1には、一括転送された稼働ログが順次記憶される。一方、機器制御プログラム領域E2には、機器制御プログラムが記憶される。ここで、フラッシュROM23は、小規模な16bitCPUでも512Kbyte程度備えているものもあり、この半分の256Kbyteを稼働ログ領域E1として活用することができる。この256Kbyteの容量は、比較的大容量な8KbitのEEPROM24の256倍もの容量を確保することが可能である。 The flash ROM 23 basically stores the device control program, but it also has free space, and is divided into an operation log area E1 and a device control program area E2. Operation logs transferred in bulk are stored sequentially in the operation log area E1. Meanwhile, the device control program area E2 stores the device control program. Some flash ROMs 23 have around 512 Kbytes even on small 16-bit CPUs, and half of this, 256 Kbytes, can be used as the operation log area E1. This 256 Kbyte capacity is 256 times the capacity of the relatively large 8 Kbit EEPROM 24.

したがって、EEPROM24は、フラッシュROM23よりも小さな記憶容量で済み、逐次リアルタイムで一時記憶するとともに一括転送することにより、組み込み機器内で発生する大容量の稼働ログを記憶することができる。しかも、稼働ログは常に不揮発性メモリ上に記憶されるため、組み込み機器が電源断になる障害が発生しても確実に全稼働ログを保持することができる。 Therefore, the EEPROM 24 requires a smaller storage capacity than the flash ROM 23, and can store large volumes of operation logs generated within the embedded device by temporarily storing the logs in real time and transferring them all at once. Furthermore, because the operation logs are always stored in non-volatile memory, all operation logs can be reliably retained even if a failure occurs that cuts off the power to the embedded device.

また、組み込み機器は、寿命による更新や故障により交換される場合があるので、自動販売機1本体側のみで稼働データを保持すると、稼働データの不一致が発生しやすく、稼働データの不一致が発生する可能性がある。本実施の形態では、稼働ログが組み込み機器内に保持しているので、稼働ログの不一致が生ずることがない。 In addition, since embedded devices may need to be updated due to their lifespan or replaced due to malfunction, if operation data is stored only on the vending machine 1 main unit, inconsistencies in the operation data are likely to occur, and there is a possibility that inconsistencies in the operation data will occur. In this embodiment, the operation log is stored within the embedded device, so inconsistencies in the operation logs will not occur.

ここで、EEPROMは、フラッシュROMに比べて消去書き込みブロックが小さいため、非常に小さなデータセットを保存したり消去したりする場合に有用であり、一度に1byteや個々のワードなどの小さなデータの保存や消去に適している。なお、EEPROMは、書き込み回数がフラッシュROMの10倍度と大きいため、転送を前提とした一時記憶媒体として適している。一方、フラッシュROMはEEPROMと比べて、一般的に書込み時間が長いためリアルタイムの稼働ログ保存に適さず、本実施の形態では、メモリ(フラッシュROMとEEPROM)の特性を生かしてメモリを適材適所に活用している。 Since EEPROM has a smaller erase/write block than flash ROM, it is useful for storing and erasing very small data sets, and is suitable for storing and erasing small data such as 1 byte or individual words at a time. EEPROM can be written to 10 times as many times as flash ROM, making it suitable as a temporary storage medium for transfer purposes. On the other hand, flash ROM generally has a longer write time than EEPROM, making it unsuitable for storing real-time operation logs. In this embodiment, the characteristics of memory (flash ROM and EEPROM) are utilized to make the most of the memory in the right place.

<稼働ログの一例>
図4は、コインメック11の稼働ログの一例を示す図である。図4に示すように、コインメック11では、商品購入に伴って、検銭データ、投入金種データ、払出金種データなどの稼働ログが発生する。具体的に、商品購入のために500円硬貨が投入されると、検銭データ(500円の正貨と識別)が発生し、その結果、投入金種データ(500円投入データ)が発生する。ここで、商品購入者が400円の商品を選択して購入すると、コインメック11は、釣銭として100円を払い出して、払出金種データ(100円払出データ)が発生する。その後、商品購入のために100円硬貨が投入されると、検銭データ(100円の正貨と識別)が発生し、その結果、投入金種データ(100円投入データ)が発生する。この場合、釣銭がないため、払出金種データは発生しない。以下、同様にして、商品購入時の稼働データが稼働ログとして発生し、EEPROM24の稼働ログ一時記憶領域E10内の一時記憶領域E11として、順次稼働データが書き込まれる。
<Example of operation log>
FIG. 4 is a diagram showing an example of an operation log of the coin mechanism 11. As shown in FIG. 4, in the coin mechanism 11, operation logs such as validation data, inserted denomination data, and payout denomination data are generated in association with the purchase of a product. Specifically, when a 500 yen coin is inserted to purchase a product, validation data (identified as a genuine 500 yen coin) is generated, and as a result, inserted denomination data (500 yen inserted data) is generated. Here, when a product purchaser selects and purchases a 400 yen product, the coin mechanism 11 pays out 100 yen as change, and payout denomination data (100 yen paid data) is generated. Thereafter, when a 100 yen coin is inserted to purchase a product, validation data (identified as a genuine 100 yen coin) is generated, and as a result, inserted denomination data (100 yen inserted data) is generated. In this case, since there is no change, payout denomination data is not generated. Thereafter, in a similar manner, operation data at the time of purchasing a product is generated as an operation log, and the operation data is sequentially written as a temporary storage area E11 in the operation log temporary storage area E10 of the EEPROM 24.

ここで、EEPROM24内の空き領域E12が所定値未満、例えば5%になった場合、これまで一時記憶された稼働ログをフラッシュROM23内の稼働ログ領域E1に一括転送し、その後、消去する。 If the free space E12 in the EEPROM 24 falls below a predetermined value, for example 5%, the operation logs that have been temporarily stored up to that point are transferred in one go to the operation log area E1 in the flash ROM 23, and then erased.

<稼働ログの記憶処理手順>
図5は、CPU21による稼働ログの記憶処理手順を示すフローチャートである。図5に示すように、まず、CPU21は、稼働データが発生したか否かを判断する(ステップS101)。稼働データが発生していない場合(ステップS101:No)、本判定処理を繰り返す。一方、稼働データが発生した場合(ステップS101:Yes)、発生した稼働データを稼働ログとしてEEPROM24に書き込む(ステップS102)。
<Operation log storage process procedure>
5 is a flowchart showing the procedure for storing an operation log by the CPU 21. As shown in FIG. 5, the CPU 21 first determines whether operation data has been generated (step S101). If operation data has not been generated (step S101: No), the CPU 21 repeats this determination process. On the other hand, if operation data has been generated (step S101: Yes), the CPU 21 writes the generated operation data as an operation log in the EEPROM 24 (step S102).

その後、CPU21は、EEPROM24の空き領域が所定値未満であるか否かを判定する(ステップS103)。EEPROM24の空き領域が所定値未満でない場合(ステップS103:No)、ステップS101に移行して上記の処理を繰り返す。一方、EEPROM24の空き領域が所定値未満である場合(ステップS103:Yes)、EEPROM24内の稼働ログをフラッシュROM23の稼働ログ領域E1に一括転送する(ステップS104)。 Then, the CPU 21 determines whether the free space in the EEPROM 24 is less than a predetermined value (step S103). If the free space in the EEPROM 24 is not less than the predetermined value (step S103: No), the CPU 21 proceeds to step S101 and repeats the above process. On the other hand, if the free space in the EEPROM 24 is less than the predetermined value (step S103: Yes), the CPU 21 transfers the operation logs in the EEPROM 24 to the operation log area E1 of the flash ROM 23 in one batch (step S104).

その後、CPU21は、一括転送が正常終了したか否かを判定する(ステップS105)。一括転送が正常終了しない場合(ステップS105:No)、本判定処理を繰り返す。なお、本判定処理が所定時間過ぎても正常終了しない場合には、自販機主制御部8等にエラー通知を行う。 Then, the CPU 21 determines whether the batch transfer has been completed successfully (step S105). If the batch transfer has not been completed successfully (step S105: No), this determination process is repeated. Note that if this determination process has not been completed successfully after a predetermined time has elapsed, an error notification is sent to the vending machine main control unit 8, etc.

一方、一括転送が正常終了した場合(ステップS105:Yes)、EEPROM24内の全稼働ロムを消去し(ステップS106)、ステップS101に戻って上記の処理を繰り返す。 On the other hand, if the batch transfer is completed successfully (step S105: Yes), all active ROMs in the EEPROM 24 are erased (step S106), and the process returns to step S101 and the above process is repeated.

本実施の形態では、小さい記憶容量のEEPROM24で済むため、搭載スペースが少ない組み込み機器であっても大容量の全ての稼働ログを確実に記憶することができる。 In this embodiment, a small-capacity EEPROM 24 is sufficient, so even embedded devices with limited mounting space can reliably store all large-capacity operation logs.

<変形例1>
上記の実施の形態では、EEPROM24内の稼働データを一括転送する所定条件を、EEPROM24の空き領域が所定値未満であるとしていたが、本変形例1では、自動販売機1本体の動作がアイドル状態であることを所定条件として一括転送するようにしている。
<Modification 1>
In the above embodiment, the specified condition for transferring all the operational data in EEPROM 24 in one batch was that the free space in EEPROM 24 was less than a specified value, but in this variant example 1, the specified condition for transferring all the operational data in one batch is that the operation of the vending machine 1 main body is in an idle state.

図6は、変形例1のCPU21による稼働ログの記憶処理手順を示すフローチャートである。図6に示すように、CPU21は、稼働データを稼働ログとしてEEPROM24に書き込んだ(ステップS202)後、自動販売機1本体の動作がアイドル状態であるか否かを判定し(ステップS203)、自動販売機1本体の動作がアイドル状態である場合(ステップS203:Yes)に、稼働データをフラッシュROM23の稼働ログ領域E1に一括転送するようにしている。なお、ステップS201、S202、S204~S206は、ステップS101、S102、S104~S106と同じ処理である。 Figure 6 is a flow chart showing the procedure for storing an operation log by the CPU 21 in Variation 1. As shown in Figure 6, after the CPU 21 writes operation data to the EEPROM 24 as an operation log (step S202), it determines whether the operation of the vending machine 1 main body is in an idle state (step S203), and if the operation of the vending machine 1 main body is in an idle state (step S203: Yes), it transfers the operation data in one batch to the operation log area E1 of the flash ROM 23. Note that steps S201, S202, S204 to S206 are the same processes as steps S101, S102, S104 to S106.

一般に、フラッシュROM23への書き込みには数秒から数分の時間を要する。このため、書き込み処理が行われているときに、CPU21と自販機主制御部8との間の本来の処理が発生した場合、この処理に影響が及ぶことになる。そこで、本変形例1では、自動販売機1がアイドル状態のときに書き込み処理を行うことによって、自動販売機1の本来の処理に影響が及ばないようにしている。 Generally, writing to the flash ROM 23 takes anywhere from a few seconds to a few minutes. For this reason, if the original processing between the CPU 21 and the vending machine main control unit 8 occurs while the writing process is being performed, this processing will be affected. Therefore, in this variation 1, the writing process is performed when the vending machine 1 is in an idle state, so that the original processing of the vending machine 1 is not affected.

<変形例2>
上記の実施の形態では、EEPROM24内の稼働データを一括転送する所定条件を、EEPROM24の空き領域が所定値未満であるとしていたが、本変形例2では、定期的な所定時刻になった場合を所定条件として一括転送するようにしている。
<Modification 2>
In the above embodiment, the specified condition for transferring the operational data in EEPROM 24 in bulk was that the free space in EEPROM 24 was less than a specified value, but in this second variant, the specified condition for transferring the operational data in bulk is when a regularly scheduled time has arrived.

図7は、変形例2のCPU21による稼働ログの記憶処理手順を示すフローチャートである。図7に示すように、CPU21は、稼働データを稼働ログとしてEEPROM24に書き込んだ(ステップS302)後、所定時刻になったか否かを判定し(ステップS303)、所定時刻である場合(ステップS303:Yes)に、稼働データをフラッシュROM23の稼働ログ領域E1に一括転送するようにしている。なお、ステップS301、S302、S304~S306は、ステップS101、S102、S104~S106と同じ処理である。 Figure 7 is a flowchart showing the procedure for storing an operation log by the CPU 21 in Modification 2. As shown in Figure 7, after the CPU 21 writes operation data to the EEPROM 24 as an operation log (step S302), it determines whether a predetermined time has arrived (step S303), and if the predetermined time has arrived (step S303: Yes), it transfers the operation data in one batch to the operation log area E1 of the flash ROM 23. Note that steps S301, S302, S304 to S306 are the same process as steps S101, S102, S104 to S106.

本変形例2では、自動販売機1の本来の処理が発生しない所定時刻、例えば、午前3時に稼働ログを一括転送するようにしている。これにより、自動販売機1の本来の処理に影響を及ぼさないようにすることができる。なお、所定時刻は、1日ごとでもよいし、3日や7日ごとの所定時刻であってもよい。 In this second variation, the operation logs are transferred in bulk at a specified time when the vending machine 1 is not performing its normal processing, for example, at 3:00 a.m. This makes it possible to avoid affecting the vending machine 1's normal processing. The specified time may be once a day, or once every three or seven days.

なお、上記の実施の形態及び変形例における所定条件は、複数の所定条件を組み合わせてもよい。すなわち、いずれかの所定条件が合致した場合に一括転送を行ったり、全ての条件あるいは一部の条件がすべて合致した場合に一括転送を行うようにしてもよい。 The predetermined conditions in the above embodiment and modified examples may be a combination of multiple predetermined conditions. In other words, a batch transfer may be performed when any of the predetermined conditions are met, or when all or some of the conditions are met.

また、上記の実施の形態及び変形例では、EEPROM24からフラッシュROM23に一括転送するようにしていたが、組み込み機器内の他の不揮発性メモリ(他の記憶場体)あるいは組み込み機器外の他のメモリ(他の記憶媒体)に直接一括転送を行うようにしてもよい。組み込み機器外の他のメモリ(他の記憶媒体)には、自販機主制御部8内のメモリ18でもよいし、自販機主制御部8に接続されたUSBメモリなどであってもよいし、管理サーバ100内の記憶媒体であってもよい。また、組み込み機器外の他のメモリ(他の記憶媒体)への稼働ログの転送は、EEPROM24からフラッシュROM23に一括転送された後に、フラッシュROM23から転送するようにしてもよい。 In addition, in the above embodiment and modified example, the data is transferred in bulk from EEPROM 24 to flash ROM 23, but the data may be transferred in bulk directly to another non-volatile memory (another storage area) within the embedded device or to another memory (another storage medium) outside the embedded device. The other memory (another storage medium) outside the embedded device may be memory 18 within the vending machine main control unit 8, a USB memory connected to the vending machine main control unit 8, or a storage medium within the management server 100. The operation log may be transferred to another memory (another storage medium) outside the embedded device after being transferred in bulk from EEPROM 24 to flash ROM 23, and then transferred from flash ROM 23.

なお、組み込み機器外に稼働ログを転送する場合、各稼働ログに組み込み機器の識別番号を付する。これにより、組み込み機器外に稼働ログが転送された場合であっても、組み込み機器の全稼働ログを特定することができる。また、外部の他の記憶媒体に稼働ログを転送する場合であっても、直近の稼働ログは必ずEEPROMに記憶されているため、組み込み機器の全ての稼働ログを確実に得ることができる。 When operation logs are transferred outside the embedded device, the identification number of the embedded device is assigned to each operation log. This makes it possible to identify all operation logs of the embedded device even if the operation logs are transferred outside the embedded device. Even when operation logs are transferred to another external storage medium, the most recent operation log is always stored in the EEPROM, so it is possible to reliably obtain all operation logs of the embedded device.

また、上記の実施の形態及び変形例で図示した各構成は機能概略的なものであり、必ずしも物理的に図示の構成をされていることを要しない。すなわち、各装置及び構成要素の分散・統合の形態は図示のものに限られず、その全部又は一部を各種の使用状況などに応じて、任意の単位で機能的又は物理的に分散・統合して構成することができる。 In addition, the configurations illustrated in the above embodiments and variations are merely functional schematics, and do not necessarily have to be physically configured as illustrated. In other words, the form of distribution and integration of each device and component is not limited to that illustrated, and all or part of them can be functionally or physically distributed and integrated in any unit depending on various usage conditions, etc.

1 自動販売機
2 表示部
3 商品選択部
4 金銭処理部
5 商品払出部
6 冷熱部
7 通信部
8 自販機主制御部
11 コインメック
12 ビルバリ
13 電子決済部
18 メモリ
20 制御基板
21 CPU
22 SRAM
23 フラッシュROM
24 EEPROM
25 検銭・鑑別回路
26 機器駆動制御回路
27 センサ部
31 貨幣受入機構部
32 貨幣払出機構部
100 管理サーバ
E1 稼働ログ領域
E10 稼働ログ一時記憶領域
E11 一時記憶領域
E12 空き領域
E2 機器制御プログラム領域
REFERENCE SIGNS LIST 1 Vending machine 2 Display unit 3 Product selection unit 4 Money processing unit 5 Product dispensing unit 6 Heating and cooling unit 7 Communication unit 8 Vending machine main control unit 11 Coin mechanism 12 Bill validator 13 Electronic payment unit 18 Memory 20 Control board 21 CPU
22 SRAM
23 Flash ROM
24 EEPROM
25 Validation and discrimination circuit 26 Device drive control circuit 27 Sensor unit 31 Money receiving mechanism unit 32 Money dispensing mechanism unit 100 Management server E1 Operation log area E10 Operation log temporary storage area E11 Temporary storage area E12 Free area E2 Device control program area

Claims (8)

上位の主装置に組み込まれる組み込み機器であって、
前記組み込み機器内の制御基板上において該制御基板上のCPUに接続され、該組み込み機器が取り扱う稼働ログをリアルタイムに一時的に記憶するEEPROMを備え、
前記CPUは、所定条件が合致したタイミングで前記EEPROMに一時記憶された前記稼働ログを前記組み込み機器内あるいは前記組み込み機器外の他の記憶媒体に転送することを特徴とする組み込み機器。
An embedded device that is incorporated into a host main device,
an EEPROM connected to a CPU on a control board in the embedded device and configured to temporarily store an operation log handled by the embedded device in real time;
The CPU transfers the operation log temporarily stored in the EEPROM to another storage medium within the embedded device or outside the embedded device when a predetermined condition is met.
前記所定条件は、前記EEPROMの空き領域が所定値未満となる場合であることを特徴とする請求項1に記載の組み込み機器。 The embedded device according to claim 1, characterized in that the specified condition is when the free space in the EEPROM is less than a specified value. 前記所定条件は、前記主装置がアイドル状態となった場合であることを特徴とする請求項1に記載の組み込み機器。 The embedded device according to claim 1, characterized in that the predetermined condition is when the main device is in an idle state. 前記所定条件は、定期的な所定時刻になった場合であることを特徴とする請求項1に記載の組み込み機器。 The embedded device according to claim 1, characterized in that the specified condition is when a regular specified time is reached. 前記他の記憶媒体は、前記CPUのフラッシュROMであり、
前記フラッシュROMは、機器制御プログラム領域と稼働ログ領域とに分割され、前記CPUは、前記EEPROMに一時記憶された稼働ログを前記稼働ログ領域に転送することを特徴とする請求項1に記載の組み込み機器。
the other storage medium is a flash ROM of the CPU,
2. The embedded device according to claim 1, wherein the flash ROM is divided into a device control program area and an operation log area, and the CPU transfers the operation log temporarily stored in the EEPROM to the operation log area.
前記EEPROMの記憶容量は、前記フラッシュROMの記憶容量よりも小さいことを特徴とする請求項5に記載の組み込み機器。 The embedded device according to claim 5, characterized in that the storage capacity of the EEPROM is smaller than the storage capacity of the flash ROM. 前記CPUは、前記EEPROMに一時記憶された前記稼働ログが前記他の記憶媒体に対する転送が完了した場合に前記EEPROM内の稼働ログを消去することを特徴とする請求項1に記載の組み込み機器。 The embedded device according to claim 1, characterized in that the CPU erases the operation log in the EEPROM when the operation log temporarily stored in the EEPROM has been transferred to the other storage medium. 前記CPUは、前記組み込み機器外の他の記憶媒体に転送する場合、前記稼働ログには、該組み込み機器の識別番号が付されることを特徴とする請求項1に記載の組み込み機器。 The embedded device according to claim 1, characterized in that when the CPU transfers the operation log to another storage medium outside the embedded device, the identification number of the embedded device is added to the operation log.
JP2023221901A 2023-12-27 2023-12-27 Embedded Devices Pending JP2025104069A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2023221901A JP2025104069A (en) 2023-12-27 2023-12-27 Embedded Devices

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2023221901A JP2025104069A (en) 2023-12-27 2023-12-27 Embedded Devices

Publications (1)

Publication Number Publication Date
JP2025104069A true JP2025104069A (en) 2025-07-09

Family

ID=96305729

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2023221901A Pending JP2025104069A (en) 2023-12-27 2023-12-27 Embedded Devices

Country Status (1)

Country Link
JP (1) JP2025104069A (en)

Similar Documents

Publication Publication Date Title
US5734150A (en) Electronic funds acceptor for vending machines
JPH0682427B2 (en) vending machine
RU2145436C1 (en) Devices and methods for retail trade
JP4420553B2 (en) Price transaction system
JPH0785342A (en) Method for electronic payment by, especially, smart card
KR19990007880A (en) How to charge your electronic debit card and electronic debit card
JP2025104069A (en) Embedded Devices
JP5384381B2 (en) Voting ticketing system, management device, and ticketing permission notification method
US7229016B2 (en) System, method and apparatus for use in a transportation system
JP2015069271A (en) Voting data keeping device, voting data keeping system, voting data keeping method, and program
JPH1170264A (en) Game machine
JP4347711B2 (en) vending machine
JP4612963B2 (en) Card type vending machine system
AU2009217373A1 (en) A transaction method and a method of controlling use of a game
JPH11267343A (en) Game machine
JPH10108959A (en) Game prize exchange system
JP3960702B2 (en) Gaming machines and card clearing machines
EP1002301B1 (en) Method and apparatus for performing transactions
JP2002325952A (en) Game medium lending device
JP2013016126A (en) Automatic vending machine
WO2022018955A1 (en) Automatic vending machine
JP4915039B2 (en) Point service system linked with cashout function
JP2010086134A (en) Electronic money adjustment system, server, terminal, and program
JP2007286668A (en) Vending machine management system
JP2002113249A (en) Game medium renting device and system therefor