TWI396080B - Electronic device and method for recording on use time thereof - Google Patents

Electronic device and method for recording on use time thereof Download PDF

Info

Publication number
TWI396080B
TWI396080B TW98116236A TW98116236A TWI396080B TW I396080 B TWI396080 B TW I396080B TW 98116236 A TW98116236 A TW 98116236A TW 98116236 A TW98116236 A TW 98116236A TW I396080 B TWI396080 B TW I396080B
Authority
TW
Taiwan
Prior art keywords
time
bit
random access
flash memory
electronic device
Prior art date
Application number
TW98116236A
Other languages
Chinese (zh)
Other versions
TW201040718A (en
Inventor
Shao Ming Kuo
Original Assignee
Hon Hai Prec Ind 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 Hon Hai Prec Ind Co Ltd filed Critical Hon Hai Prec Ind Co Ltd
Priority to TW98116236A priority Critical patent/TWI396080B/en
Publication of TW201040718A publication Critical patent/TW201040718A/en
Application granted granted Critical
Publication of TWI396080B publication Critical patent/TWI396080B/en

Links

Description

電子設備及其記錄使用時間之方法 ELECTRONIC DEVICE AND METHOD FOR RECORDING ON USE TIME THEREOFElectronic equipment and method of recording the time of use ELECTRONIC DEVICE AND METHOD FOR RECORDING ON USE TIME THEREOF

本發明涉及電子設備,尤其涉及一種電子設備及其記錄使用時間之方法。The present invention relates to electronic devices, and more particularly to an electronic device and a method of recording the time of use thereof.

一般在電子設備售出後,其可能會因硬體或軟體的問題而無法開機使用。通常電子設備的廠商在電子設備售出後,會開放一段時間做為品質保證期,以提供電子設備的售後服務。然而,在這段時間有些用戶可能會反映電子設備無法開機使用,向電子設備的廠商要求退貨。Generally, after the electronic device is sold, it may not be able to be turned on due to hardware or software problems. Usually, after the electronic equipment is sold, the manufacturer of the electronic equipment will open for a period of time as a quality guarantee period to provide after-sales service for the electronic equipment. However, during this time, some users may reflect that the electronic device cannot be turned on, and the manufacturer of the electronic device is required to return the product.

當發生此狀況時,電子設備的廠商無法得知電子設備是否真的在未曾開機使用過的狀況下損壞,因此容易造成消費糾紛,從而導致損壞電子設備的廠商的形象及提高電子設備的廠商的成本。When this happens, the manufacturer of the electronic device cannot know whether the electronic device is actually damaged under the condition that it has not been used up, so it is easy to cause a consumer dispute, which leads to the image of the manufacturer who damages the electronic device and the manufacturer of the electronic device. cost.

有鑑於此,需要提供一種電子設備,可記錄其使用時間,避免電子設備的廠商與用戶之間的消費糾紛。In view of this, it is necessary to provide an electronic device that can record its use time and avoid consumer disputes between manufacturers and users of electronic devices.

此外,還需要提供一種電子設備記錄使用時間之方法,可記錄電子設備之使用時間,避免電子設備的廠商與用戶之間的消費糾紛。In addition, there is a need to provide a method for recording the usage time of an electronic device, which can record the usage time of the electronic device and avoid consumer disputes between the manufacturer and the user of the electronic device.

本發明實施方式中提供的電子設備用於記錄電子設備之使用時間。該電子設備包括快閃記憶體、隨機存取記憶體、設定模組、複製模組、記錄模組及寫入模組。快閃記憶體用於儲存表徵使用時間的位元。設定模組用於將快閃記憶體中表徵使用時間的位元初始化為第一值,以及設定電子設備使用期間覆寫快閃記憶體中表徵使用時間的位元之時間間隔。複製模組用於在電子設備每次開機使用時將快閃記憶體中表徵使用時間的位元複製到隨機存取記憶體。記錄模組用於在隨機存取記憶體中表徵使用時間的位元中找尋第一個為第一值的位元並將其索引值記錄於變數中,其中每當時間間隔到達時記錄模組將隨機存取記憶體中變數對應之位元覆寫為第二值,並將變數加1,其中該被覆寫為第二值之位元用於表徵新增使用時間。寫入模組用於判斷當前隨機存取記憶體中表徵使用時間的位元是否超過快閃記憶體所能記錄的最大使用時間,並在當前隨機存取記憶體中表徵使用時間的位元未超過快閃記憶體所能記錄的最大使用時間時將隨機存取記憶體中表徵新增使用時間的位元寫入快閃記憶體。The electronic device provided in the embodiment of the present invention is used to record the usage time of the electronic device. The electronic device includes a flash memory, a random access memory, a setting module, a copying module, a recording module, and a writing module. Flash memory is used to store bits that characterize usage time. The setting module is configured to initialize a bit characterizing the usage time in the flash memory to a first value, and set a time interval for overwriting a bit characterizing the usage time in the flash memory during use of the electronic device. The copy module is configured to copy the bits characterizing the usage time in the flash memory to the random access memory each time the electronic device is powered on. The recording module is configured to find the first bit with the first value in the bit symbolizing the usage time in the random access memory and record the index value in the variable, wherein the recording module is recorded whenever the time interval arrives. The bit corresponding to the variable in the random access memory is overwritten with the second value, and the variable is incremented by 1, wherein the bit that is overwritten with the second value is used to represent the new usage time. The write module is configured to determine whether the bit character representing the use time in the current random access memory exceeds the maximum use time that the flash memory can record, and the bit that characterizes the use time in the current random access memory is not The bit characterizing the newly used time in the random access memory is written to the flash memory when the maximum usage time that can be recorded by the flash memory is exceeded.

本發明實施方式中提供的電子設備記錄使用時間之方法,包括以下步驟:提供快閃記憶體以及隨機存取記憶體,快閃記憶體用於儲存表徵使用時間的位元;將快閃記憶體中表徵使用時間的位元初始化為第一值;在該電子設備開機使用時將快閃記憶體中表徵使用時間的位元複製到隨機存取記憶體;在隨機存取記憶體中表徵使用時間的位元中找尋第一個為第一值的位元並將其索引值記錄於變數中;設定該電子設備使用期間覆寫該快閃記憶體中表徵使用時間的位元之時間間隔;每當時間間隔到達時將隨機存取記憶體中變數對應之位元覆寫為第二值,並將變數加1,其中該被覆寫為第二值之位元用於表徵新增使用時間;判斷當前隨機存取記憶體中表徵使用時間的位元是否超過快閃記憶體所能記錄的最大使用時間;若當前隨機存取記憶體中表徵使用時間的位元未超過快閃記憶體所能記錄的最大使用時間,則將隨機存取記憶體中表徵新增使用時間的位元寫入快閃記憶體。The method for recording the usage time of the electronic device provided by the embodiment of the present invention includes the following steps: providing a flash memory and a random access memory, the flash memory is used to store a bit characterizing the use time; and the flash memory is The bit characterizing the time of use is initialized to a first value; the bit character representing the time of use in the flash memory is copied to the random access memory when the electronic device is powered on; and the time of use is characterized in the random access memory Finding the first bit of the first value and recording the index value in the variable; setting a time interval during which the electronic device overwrites the bit characterizing the use time in the flash memory; When the time interval arrives, the bit corresponding to the variable in the random access memory is overwritten as the second value, and the variable is incremented by 1, wherein the bit that is overwritten as the second value is used to represent the new use time; Whether the bit characterizing the usage time in the current random access memory exceeds the maximum usage time that the flash memory can record; if the bit characterizing the usage time in the current random access memory The maximum usage time that can be recorded by the flash memory is not exceeded, and the bit characterizing the newly used time in the random access memory is written into the flash memory.

藉由以下對具體實施方式詳細的描述並結合附圖,將可輕易的瞭解上述內容及此項發明之技術效果。The above and the technical effects of the invention can be easily understood from the following detailed description of the embodiments and the accompanying drawings.

圖1係本發明電子設備100一實施方式之模組圖。在本實施方式中,電子設備100可記錄其使用時間,其包括快閃記憶體(Flash memory)200、隨機存取記憶體(Random Access Memory)300、設定模組110、複製模組120、記錄模組130及寫入模組140。其中,隨機存取記憶體300用於儲存當前正在運行之資料。1 is a block diagram of an embodiment of an electronic device 100 of the present invention. In this embodiment, the electronic device 100 can record the usage time thereof, and includes a flash memory 200, a random access memory 300, a setting module 110, a copy module 120, and a record. Module 130 and write module 140. The random access memory 300 is used to store the currently running data.

快閃記憶體200用於儲存表徵使用時間的位元。在本實施方式中,快閃記憶體200從其儲存空間中劃分了一個固定大小的區塊,如64Kbits,用於儲存表徵使用時間的位元。The flash memory 200 is used to store bits characterizing the time of use. In the present embodiment, the flash memory 200 divides a fixed size block, such as 64 Kbits, from its storage space for storing bits characterizing the usage time.

設定模組110用於將快閃記憶體200中表徵使用時間的位元初始化為第一值,以及設定電子設備100於使用期間覆寫快閃記憶體200中表徵使用時間的位元之時間間隔。在本實施方式中,該第一值為1。The setting module 110 is configured to initialize a bit characterizing the usage time in the flash memory 200 to a first value, and set a time interval during which the electronic device 100 overwrites the bit characterizing the usage time in the flash memory 200 during use. . In the present embodiment, the first value is 1.

複製模組120用於在電子設備100每次開機使用時將快閃記憶體200中表徵使用時間的位元複製到隨機存取記憶體300。The copy module 120 is configured to copy the bits representing the usage time in the flash memory 200 to the random access memory 300 each time the electronic device 100 is powered on.

記錄模組130用於在隨機存取記憶體300中表徵使用時間的位元中找尋第一個為第一值的位元並將其索引值記錄於變數n中,其中每當時間間隔到達時記錄模組130將隨機存取記憶體300中變數n對應之位元覆寫為第二值,並將該變數n加1。其中被覆寫為第二值之位元用於表徵新增使用時間。在本實施方式中,第二值為0。The recording module 130 is configured to find the first bit with the first value in the bit characterizing the usage time in the random access memory 300 and record the index value in the variable n, where the time interval arrives. The recording module 130 overwrites the bit corresponding to the variable n in the random access memory 300 to the second value, and increments the variable n by one. The bit that is overwritten with the second value is used to characterize the new usage time. In the present embodiment, the second value is zero.

寫入模組140用於判斷當前隨機存取記憶體300中表徵使用時間的位元是否超過快閃記憶體200所能記錄的最大使用時間,並在當前隨機存取記憶體300中表徵使用時間的位元未超過快閃記憶體200所能記錄的最大使用時間時將隨機存取記憶體300中表徵新增使用時間的位元寫入快閃記憶體200。在本實施方式中,快閃記憶體200從其儲存空間中劃分了一個固定大小的區塊來儲存表徵使用時間的位元。快閃記憶體200所能記錄的最大使用時間等於該固定大小的區塊所能記錄的最大值。The write module 140 is configured to determine whether the bit in the current random access memory 300 characterizing the usage time exceeds the maximum usage time that the flash memory 200 can record, and characterize the use time in the current random access memory 300. The bit characterizing the new usage time in the random access memory 300 is written to the flash memory 200 when the bit does not exceed the maximum usage time that can be recorded by the flash memory 200. In the present embodiment, the flash memory 200 divides a block of a fixed size from its storage space to store bits characterizing the time of use. The maximum usage time that the flash memory 200 can record is equal to the maximum value that can be recorded by the fixed size block.

圖2係本發明電子設備100記錄使用時間一實施方式之示意圖。在本實施方式中,當廠商出售電子設備100至用戶時,可以利用設定模組110將快閃記憶體200中表徵使用時間的位元全部初始化為1。2 is a schematic diagram of an embodiment of the electronic device 100 of the present invention recording usage time. In the present embodiment, when the manufacturer sells the electronic device 100 to the user, the setting module 110 can be used to initialize all the bits in the flash memory 200 that characterize the usage time to 1.

當用戶首次使用電子設備100時,複製模組120將快閃記憶體200中表徵使用時間的位元複製到隨機存取記憶體300,設定模組110設定電子設備100使用期間覆寫快閃記憶體200中表徵使用時間的位元之時間間隔為1分鐘,記錄模組130在隨機存取記憶體300中表徵使用時間的位元中找尋第一個為1的位元並將其索引值記錄於變數n中。由於電子設備100是首次使用,所以隨機存取記憶體300中表徵使用時間的位元中表徵使用時間的位元初始值全部為1,其中第一個為1的位元的索引值即為1,故變數n等於1。When the user first uses the electronic device 100, the copy module 120 copies the bits representing the usage time in the flash memory 200 to the random access memory 300, and the setting module 110 sets the flash memory to be overwritten during use of the electronic device 100. The time interval of the bit characterization time of the body 200 is 1 minute, and the recording module 130 finds the first bit of 1 in the bit characterizing the use time in the random access memory 300 and records the index value thereof. In the variable n. Since the electronic device 100 is used for the first time, the initial values of the bits characterizing the usage time in the bits characterizing the usage time in the random access memory 300 are all 1, wherein the index value of the first bit of 1 is 1 Therefore, the variable n is equal to 1.

當1分鐘的時間間隔到達時(即使用1分鐘後),記錄模組130將隨機存取記憶體300中變數n為1所對應之位元覆寫為0,並將該變數n加1。換言之,記錄模組130將隨機存取記憶體300中第一個為1的位元覆寫為0,並將變數n加1成為2。其中被覆寫為0之位元用於表徵新增使用時間。When the 1-minute time interval is reached (i.e., after 1 minute of use), the recording module 130 overwrites the bit corresponding to the variable n of 1 in the random access memory 300 to 0, and increments the variable n by one. In other words, the recording module 130 overwrites the first bit of the random access memory 300 with 1 as 0, and increments the variable n by 1. The bit that is overwritten with 0 is used to characterize the new usage time.

此時,寫入模組140判斷當前隨機存取記憶體300中表徵使用時間的位元是否超過快閃記憶體200所能記錄的最大使用時間。若當前隨機存取記憶體300中表徵使用時間的位元未超過快閃記憶體200所能記錄的最大使用時間時,則寫入模組140僅將隨機存取記憶體300中表徵新增使用時間的位元寫入快閃記憶體200。換言之,寫入模組140僅將隨機存取記憶體300中被覆寫為0的位元寫入快閃記憶體200。如圖2所示,此時快閃記憶體200中表徵使用時間的位元中第一個位元為0,其他位元均為1。At this time, the writing module 140 determines whether the bit characterizing the usage time in the current random access memory 300 exceeds the maximum usage time that the flash memory 200 can record. If the bit characterizing the usage time in the current random access memory 300 does not exceed the maximum usage time that the flash memory 200 can record, the write module 140 only adds the representation in the random access memory 300. The bits of time are written to the flash memory 200. In other words, the write module 140 writes only the bits of the random access memory 300 that are written as 0 to the flash memory 200. As shown in FIG. 2, at this time, the first bit in the bit characterizing the usage time in the flash memory 200 is 0, and the other bits are all 1.

當1分鐘的時間間隔再次到達時(即使用2分鐘後),記錄模組130將隨機存取記憶體300中變數n為2所對應之位元覆寫為0,並將該變數n加1。在本實施例中,記錄模組130將隨機存取記憶體300中第二個為1的位元覆寫為0,並將變數n加1成為3。其中被覆寫為0之位元亦用於表徵新增使用時間。When the time interval of 1 minute arrives again (that is, after 2 minutes of use), the recording module 130 overwrites the bit corresponding to the variable n of 2 in the random access memory 300 to 0, and adds 1 to the variable n. . In the present embodiment, the recording module 130 overwrites the second bit of the random access memory 300 with 1 as 0, and increments the variable n by 1. The bit that is written as 0 is also used to characterize the new usage time.

此時,寫入模組140判斷當前隨機存取記憶體300中表徵使用時間的位元是否超過快閃記憶體200所能記錄的最大使用時間。若當前隨機存取記憶體300中表徵使用時間的位元未超過快閃記憶體200所能記錄的最大使用時間時,則寫入模組140僅將隨機存取記憶體300中表徵新增使用時間的位元寫入快閃記憶體200。換言之,寫入模組140僅將隨機存取記憶體300中被覆寫為0的位元寫入快閃記憶體。如圖2所示,此時快閃記憶體200中表徵使用時間的位元中第一個與第二個位元為0,其他位元均為1。At this time, the writing module 140 determines whether the bit characterizing the usage time in the current random access memory 300 exceeds the maximum usage time that the flash memory 200 can record. If the bit characterizing the usage time in the current random access memory 300 does not exceed the maximum usage time that the flash memory 200 can record, the write module 140 only adds the representation in the random access memory 300. The bits of time are written to the flash memory 200. In other words, the write module 140 writes only the bits in the random access memory 300 that are written as 0 to the flash memory. As shown in FIG. 2, at this time, the first and second bits in the bits representing the usage time in the flash memory 200 are 0, and the other bits are all 1.

以此類推,當使用n分鐘後,快閃記憶體200中表徵使用時間的位元中第一個至第n個位元為0,其他位元均為1。By analogy, after n minutes of use, the first to nth bits in the bits characterizing the usage time in the flash memory 200 are 0, and all other bits are 1.

因此,快閃記憶體200中表徵使用時間的位元可靠地記錄了電子設備100之使用時間,避免電子設備100的廠商與用戶之間的消費糾紛。Therefore, the bits characterizing the usage time in the flash memory 200 reliably record the usage time of the electronic device 100, avoiding consumption disputes between the manufacturer and the user of the electronic device 100.

圖3係本發明電子設備100記錄使用時間之方法一實施方式之流程圖。在本實施方式中,電子設備100記錄使用時間之方法藉由圖1中的功能模組來實施。FIG. 3 is a flow chart of an embodiment of a method for recording usage time of the electronic device 100 of the present invention. In the present embodiment, the method of recording the usage time of the electronic device 100 is implemented by the function module in FIG. 1.

在步驟S300,設定模組110將快閃記憶體200中表徵使用時間的位元初始化為第一值。在本實施方式中,第一值為1。In step S300, the setting module 110 initializes the bit characterizing the usage time in the flash memory 200 to the first value. In the present embodiment, the first value is 1.

在步驟S302,複製模組120在電子設備100開機使用時將快閃記憶體200中表徵使用時間的位元複製到隨機存取記憶體300。In step S302, the copy module 120 copies the bits representing the usage time in the flash memory 200 to the random access memory 300 when the electronic device 100 is powered on.

在步驟S304,記錄模組130在隨機存取記憶體300中表徵使用時間的位元中找尋第一個為第一值的位元並將其索引值記錄於變數n中。In step S304, the recording module 130 finds the first bit in the random access memory 300 that is the first value in the bit time of use and records its index value in the variable n.

在步驟S306,設定模組110設定電子設備100使用期間覆寫快閃記憶體200中表徵使用時間的位元之時間間隔。In step S306, the setting module 110 sets a time interval during which the electronic device 100 overwrites the bit in the flash memory 200 that characterizes the usage time.

在步驟S308,每當時間間隔到達時記錄模組130將隨機存取記憶體300中變數n對應之位元覆寫為第二值,並將該變數n加1。其中被覆寫為第二值之位元用於表徵新增使用時間。在本實施方式中,第二值為0。In step S308, the recording module 130 overwrites the bit corresponding to the variable n in the random access memory 300 to the second value every time the time interval arrives, and increments the variable n by one. The bit that is overwritten with the second value is used to characterize the new usage time. In the present embodiment, the second value is zero.

在步驟S310,寫入模組140判斷當前隨機存取記憶體300中表徵使用時間的位元是否超過快閃記憶體200所能記錄的最大使用時間。在本實施方式中,快閃記憶體200從其儲存空間中劃分了一個固定大小的區塊來儲存表徵使用時間的位元,快閃記憶體200所能記錄的最大使用時間等於該固定大小的區塊所能記錄的最大值。In step S310, the writing module 140 determines whether the bit in the current random access memory 300 characterizing the usage time exceeds the maximum usage time that the flash memory 200 can record. In this embodiment, the flash memory 200 divides a fixed-size block from its storage space to store a bit characterizing the usage time, and the maximum usage time that the flash memory 200 can record is equal to the fixed size. The maximum value that can be recorded by the block.

若當前隨機存取記憶體300中表徵使用時間的位元未超過快閃記憶體200所能記錄的最大使用時間,則在步驟S312,寫入模組140將隨機存取記憶體300中表徵新增使用時間的位元寫入快閃記憶體200。If the bit characterizing the usage time in the current random access memory 300 does not exceed the maximum usage time that the flash memory 200 can record, then in step S312, the write module 140 will characterize the new in the random access memory 300. The bits of the increased usage time are written to the flash memory 200.

上述步驟S308-S312在電子設備100使用期間循環執行,直到電子設備100關機或當前隨機存取記憶體300中表徵使用時間的位元超過快閃記憶體200所能記錄的最大使用時間為止。The above steps S308-S312 are cyclically executed during use of the electronic device 100 until the electronic device 100 is turned off or the bit in the current random access memory 300 characterizing the usage time exceeds the maximum usage time that the flash memory 200 can record.

在本發明實施方式中,由於寫入模組140僅將隨機存取記憶體300中表徵新增使用時間的位元寫入快閃記憶體200,亦即,僅對快閃記憶體200做寫入的動作,不做抹除,從而可以避免在抹除時電子設備100斷電造成資料錯誤。另外,複製模組120與寫入模組140皆是以位元為單位對快閃記憶體200進行複製與寫入,從而節省快閃記憶體200的使用空間。In the embodiment of the present invention, since the write module 140 only writes the bit in the random access memory 300 that represents the newly used time to the flash memory 200, that is, only writes to the flash memory 200. The incoming action is not erased, so that the electronic device 100 can be prevented from being powered off due to data loss during erasing. In addition, both the copy module 120 and the write module 140 copy and write the flash memory 200 in units of bits, thereby saving the use space of the flash memory 200.

綜上所述,本發明符合發明專利要件,爰依法提出專利申請。惟,以上所述者僅為本發明之較佳實施例,舉凡熟悉本案技藝之人士,在爰依本案發明精神所作之等效修飾或變化,皆應包含於以下之申請專利範圍內。In summary, the present invention complies with the requirements of the invention patent and submits a patent application according to law. The above description is only the preferred embodiment of the present invention, and equivalent modifications or variations made by those skilled in the art of the present invention should be included in the following claims.

100...電子設備100. . . Electronic equipment

110...設定模組110. . . Setting module

120...複製模組120. . . Copy module

130...記錄模組130. . . Recording module

140...寫入模組140. . . Write module

200...快閃記憶體200. . . Flash memory

300...隨機存取記憶體300. . . Random access memory

圖1係本發明電子設備一實施方式之模組圖。1 is a block diagram of an embodiment of an electronic device of the present invention.

圖2係本發明電子設備記錄使用時間一實施方式之示意圖。2 is a schematic diagram of an embodiment of recording electronic usage time of the electronic device of the present invention.

圖3係本發明電子設備記錄使用時間一實施方式之流程圖。3 is a flow chart of an embodiment of recording the use time of the electronic device of the present invention.

100...電子設備100. . . Electronic equipment

110...設定模組110. . . Setting module

120...複製模組120. . . Copy module

130...記錄模組130. . . Recording module

140...寫入模組140. . . Write module

200...快閃記憶體200. . . Flash memory

300...隨機存取記憶體300. . . Random access memory

Claims (4)

一種電子設備,用於記錄該電子設備之使用時間,該電子設備包括:快閃記憶體,用於儲存表徵使用時間的位元;隨機存取記憶體;設定模組,用於將該快閃記憶體中表徵使用時間的位元初始化為第一值,以及設定該電子設備使用期間覆寫該快閃記憶體中表徵使用時間的位元之時間間隔;複製模組,用於在該電子設備每次開機使用時將該快閃記憶體中表徵使用時間的位元複製到該隨機存取記憶體;記錄模組,用於在該隨機存取記憶體中表徵使用時間的位元中找尋第一個為該第一值的位元並將其索引值記錄於變數中,其中每當該時間間隔到達時該記錄模組將該隨機存取記憶體中該變數對應之位元覆寫為第二值,並將該變數加1,其中該被覆寫為第二值之位元用於表徵新增使用時間;及寫入模組,用於判斷當前該隨機存取記憶體中表徵使用時間的位元是否超過該快閃記憶體所能記錄的最大使用時間,並在當前該隨機存取記憶體中表徵使用時間的位元未超過該快閃記憶體所能記錄的最大使用時間時將該隨機存取記憶體中表徵新增使用時間的位元寫入該快閃記憶體。An electronic device for recording a usage time of the electronic device, the electronic device comprising: a flash memory for storing a bit characterizing a usage time; a random access memory; and a setting module for flashing the flash a bit in the memory that characterizes the usage time is initialized to a first value, and a time interval for overwriting the bit characterizing the usage time in the flash memory during use of the electronic device is set; a copy module is used in the electronic device Copying the time-characterized bits in the flash memory to the random access memory each time the power is turned on; the recording module is configured to search for the time in the random access memory a bit of the first value and recording the index value in the variable, wherein the recording module overwrites the bit corresponding to the variable in the random access memory as the first time the time interval arrives Binary value, and adding 1 to the variable, wherein the bit written as the second value is used to represent the new use time; and the write module is used to determine the current use time of the random access memory. Bit is Whether the maximum usage time of the flash memory can be exceeded, and the random storage time in the random access memory that indicates the usage time does not exceed the maximum usage time recorded by the flash memory The bit in the memory that characterizes the new usage time is written to the flash memory. 如申請專利範圍第1項所述之電子設備,其中該第一值與該第二值分別為1與0。The electronic device of claim 1, wherein the first value and the second value are 1 and 0, respectively. 一種電子設備記錄使用時間之方法,包括以下步驟:提供快閃記憶體以及隨機存取記憶體,該快閃記憶體用於儲存表徵使用時間的位元;將該快閃記憶體中表徵使用時間的位元初始化為第一值;在該電子設備開機使用時將該快閃記憶體中表徵使用時間的位元複製到該隨機存取記憶體;設定該電子設備使用期間覆寫該快閃記憶體中表徵使用時間的位元之時間間隔;在該隨機存取記憶體中表徵使用時間的位元中找尋第一個為該第一值的位元並將其索引值記錄於變數中;每當該時間間隔到達時將該隨機存取記憶體中該變數對應之位元覆寫為第二值,並將該變數加1,其中該被覆寫為第二值之位元用於表徵新增使用時間;判斷當前該隨機存取記憶體中表徵使用時間的位元是否超過該快閃記憶體所能記錄的最大使用時間;及若當前該隨機存取記憶體中表徵使用時間的位元未超過該快閃記憶體所能記錄的最大使用時間,則將該隨機存取記憶體中表徵新增使用時間的位元寫入該快閃記憶體。A method for recording usage time of an electronic device, comprising the steps of: providing a flash memory and a random access memory, the flash memory for storing a bit characterizing a usage time; and characterizing the usage time in the flash memory The bit is initialized to a first value; the bit character representing the time of use in the flash memory is copied to the random access memory when the electronic device is powered on; setting the flash memory to be overwritten during use of the electronic device a time interval in the body that characterizes the time in use; finding the first bit in the random access memory that is the first value and recording the index value in the variable; When the time interval arrives, the bit corresponding to the variable in the random access memory is overwritten with the second value, and the variable is incremented by 1, wherein the bit that is overwritten with the second value is used to represent the new one. Using time; determining whether the current character in the random access memory characterizes the usage time exceeds the maximum usage time that the flash memory can record; and if the characterization in the random access memory is currently used The bit of the time does not exceed the maximum usage time that the flash memory can record, and the bit characterizing the newly used time in the random access memory is written into the flash memory. 如申請專利範圍第3項所述之電子設備記錄使用時間之方法,其中該第一值與該第二值分別為1與0。The method for recording an use time of an electronic device according to claim 3, wherein the first value and the second value are 1 and 0, respectively.
TW98116236A 2009-05-15 2009-05-15 Electronic device and method for recording on use time thereof TWI396080B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW98116236A TWI396080B (en) 2009-05-15 2009-05-15 Electronic device and method for recording on use time thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW98116236A TWI396080B (en) 2009-05-15 2009-05-15 Electronic device and method for recording on use time thereof

Publications (2)

Publication Number Publication Date
TW201040718A TW201040718A (en) 2010-11-16
TWI396080B true TWI396080B (en) 2013-05-11

Family

ID=44996047

Family Applications (1)

Application Number Title Priority Date Filing Date
TW98116236A TWI396080B (en) 2009-05-15 2009-05-15 Electronic device and method for recording on use time thereof

Country Status (1)

Country Link
TW (1) TWI396080B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW527564B (en) * 2000-08-21 2003-04-11 Proton Electronic Ind Co Ltd Logging method of activation time of electronic device
CN1202492C (en) * 2001-03-30 2005-05-18 大买家科技股份有限公司 System and method for protecting soft ware by storage card
TW200739457A (en) * 2006-04-03 2007-10-16 Dmp Electronics Inc Processor capable of early warning its life expectancy and method thereof
TW200805033A (en) * 2006-07-03 2008-01-16 Giga Byte Tech Co Ltd Method for recording use time of a computer system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW527564B (en) * 2000-08-21 2003-04-11 Proton Electronic Ind Co Ltd Logging method of activation time of electronic device
CN1202492C (en) * 2001-03-30 2005-05-18 大买家科技股份有限公司 System and method for protecting soft ware by storage card
TW200739457A (en) * 2006-04-03 2007-10-16 Dmp Electronics Inc Processor capable of early warning its life expectancy and method thereof
TW200805033A (en) * 2006-07-03 2008-01-16 Giga Byte Tech Co Ltd Method for recording use time of a computer system

Also Published As

Publication number Publication date
TW201040718A (en) 2010-11-16

Similar Documents

Publication Publication Date Title
TWI386804B (en) Interface for non-volatile memories
US9836392B2 (en) Storage control apparatus to control pre-processing operations
TWI461913B (en) Flash memory device and data reading method thereof
MX2020010933A (en) System startup method and apparatus, electronic device and storage medium.
KR101819014B1 (en) Method and controller for managing memory device
US8996933B2 (en) Memory management method, controller, and storage system
US20090067303A1 (en) Data storage device using two types or storage medium
US20110264842A1 (en) Memory controller, nonvolatile memory device, access device, and nonvolatile memory system
WO2016180093A1 (en) Read/write control circuit and method for flash chip, and amoled application circuit
TWI591533B (en) Data storage method and data recovery method for data storage device, and data storage device using the same methods
CN101882331B (en) Electronic equipment and method for recording use time
CN106681874B (en) Test method and device for storage power-down protection function
JP6055047B1 (en) Erase system for nonvolatile memory device, nonvolatile memory device, external erase device and method
US7921340B2 (en) Nonvolatile memory device, nonvolatile memory system, and defect management method for nonvolatile memory device
TWI396080B (en) Electronic device and method for recording on use time thereof
US20150058550A1 (en) Information recording apparatus that performs refresh of memory and control method therefor
US20120079166A1 (en) Electronic device and method for initializing data storage
JP2005267761A (en) Method for monitoring degradation of flash memory
JP4645043B2 (en) MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE, AND NONVOLATILE MEMORY SYSTEM
JP2009301680A (en) Semiconductor memory device and host device
JP4655545B2 (en) Memory card and playback device
JP7004033B1 (en) Storage equipment, storage systems, control methods and programs
TWI436367B (en) Method for operating non-volatile flash memory with write protection mechanism
JP2016091059A (en) Information processing device
CN111324286A (en) Memory and control method and device thereof