CN103546638B - A kind of flash memory cards fall card restoration methods and mobile terminal thereof - Google Patents

A kind of flash memory cards fall card restoration methods and mobile terminal thereof Download PDF

Info

Publication number
CN103546638B
CN103546638B CN201310518426.1A CN201310518426A CN103546638B CN 103546638 B CN103546638 B CN 103546638B CN 201310518426 A CN201310518426 A CN 201310518426A CN 103546638 B CN103546638 B CN 103546638B
Authority
CN
China
Prior art keywords
flash memory
memory cards
flag bit
status register
read
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
Application number
CN201310518426.1A
Other languages
Chinese (zh)
Other versions
CN103546638A (en
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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201310518426.1A priority Critical patent/CN103546638B/en
Publication of CN103546638A publication Critical patent/CN103546638A/en
Application granted granted Critical
Publication of CN103546638B publication Critical patent/CN103546638B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Read Only Memory (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

Flash memory cards fall card restoration methods and a mobile terminal thereof, the step of described method comprises: S1, add one represent this flash memory cards flag bit whether in place in the status register of flash memory cards, and default settings; S2, detect in the read-write process of flash memory cards whether occur read and write interrupt event, if so, then revise the described flag bit of status register; After the central processing unit of S3, described electronic equipment detects modified flag bit, control the initialization carry of flash memory cards, and described flag bit is reverted to default value.Utilize the present invention, terminal can detect that the exception of flash memory cards is fallen card and initiatively re-starts the action of initialization carry voluntarily, the read-write of flash memory cards can be repaired extremely instantaneously, the card phenomenon of falling of flash memory cards is reduced as much as possible to the harmful effect that user causes, promotes Consumer's Experience greatly.

Description

A kind of flash memory cards fall card restoration methods and mobile terminal thereof
Technical field
The present invention relates to technical field of electronic equipment, what particularly relate to a kind of flash memory cards falls card restoration methods and mobile terminal thereof.
Background technology
The fast development of smart mobile phone makes memory have also been obtained development at full speed, and existing interior of mobile phone memory can provide the ROM memory space up to 64GB even higher.But storage chip is also multiplied usually along with its price of increase of memory capacity, himself memory capacity of the flagship type that therefore price general charged is comparatively high is just larger.Such as, some brand mobile phone will be distinguished into several version with a series of mobile phone according to the difference of memory capacity: 16GB, 32GB, 64GB etc., and its price variance is obviously big.The mobile phone products of the low and middle-end location thus on market, for the dual ROM considering larger capacity of generally can not arranging in pairs or groups of product orientation and cost, is all adopt 4GB or 8GB at present substantially.And in the ROM space of 4GB or 8GB, cell phone system software will take about 2GB, the space so leaving user oneself use for is just fewer.Therefore the machine that ROM is less meets the demand in user extension storage space voluntarily in its hardware designs by a reserved outside extension storage interface, the extension storage be widely used at present on mobile phone comprises TF card, TF card can reach the even higher memory space of 16GB, enough makes up the impact that mobile phone self ROM deficiency is brought.
And due to extension storage card such as TF card be manual plug-in card, hot plug also supported by some mobile phone, so draw-in groove generally exposes, is so just easy to be subject to the interference from the external world, such as electrostatic interference etc.The interference being subject to the factors such as electrostatic is easy to cause the read-write of TF card to make a mistake, and then falls to carry, Here it is often say card phenomenon.And after falling card user must restart mobile phone could carry again, bring inconvenience to the use of user, Consumer's Experience is not good.
Summary of the invention
In order to overcome the weak point of the prior art of above-mentioned indication, what the invention provides a kind of flash memory cards falls card restoration methods and mobile terminal thereof, to solve the inconvenience that brings of the use of card phenomenon to user and puzzlement, the normal work of fast quick-recovery flash memory cards.
The present invention is achieved by the following technical solutions:
Flash memory cards fall a card restoration methods, be applied to electronic equipment, its step comprises:
S1, the flag bit that whether this flash memory cards of interpolation expression is in place in the status register of flash memory cards, and default settings;
S2, detect in the read-write process of flash memory cards whether occur read and write interrupt event, if so, then revise the described flag bit of status register;
After the central processing unit of S3, described electronic equipment detects modified flag bit, control the initialization carry of flash memory cards, and described flag bit is reverted to default value.
Preferably, the default value that described step S1 arranges the flag bit that status register adds is 1, represents that flash memory cards is in place when this flag bit is 1.
Preferably, the flag bit that described step S2 revises status register interpolation is 0, represents that flash memory cards falls to carry when this flag bit is 0.
The initialization carry that described step S3 controls flash memory cards refers to the power cut-off of control flash memory cards and powers on, reloads the setup code of flash memory cards simultaneously.
Preferably, described flash memory cards is TF card.
The invention also discloses a kind of mobile terminal, be equipped with flash memory cards, comprising:
Flag bit memory cell, for adding the flag bit representing that whether this flash memory cards is in place in the status register of flash memory cards, and default settings;
Interrupt detecting unit, whether occurring to read and write interrupt event for detecting in the read-write process of flash memory cards, if so, then revising the described flag bit of status register;
Initialization unit, for after modified flag bit being detected, controls the initialization carry of flash memory cards, and described flag bit is reverted to default value.
Preferably, described flag bit memory cell is 1 for the default value of the flag bit arranging status register interpolation, represents that flash memory cards is in place when this flag bit is 1.
Preferably, described interruption detecting unit is 0 for revising the flag bit of status register interpolation, represents that flash memory cards falls to carry when this flag bit is 0.
Described initialization unit refers to the power cut-off of control flash memory cards for the initialization carry controlling flash memory cards and powers on, reloads the setup code of flash memory cards simultaneously.
Preferably, the flash memory cards of this mobile terminal is TF card.
Compared with prior art, utilize of the present invention fall card restoration methods, after flash memory cards causes falling card by interference such as electrostatic, terminal can detect this exception voluntarily and initiatively re-start the action of initialization carry, the read-write of flash memory cards can be repaired extremely instantaneously, the card phenomenon of falling of flash memory cards is reduced as much as possible to the harmful effect that user causes, promotes Consumer's Experience greatly.
Accompanying drawing explanation
Accompanying drawing 1 is the realization flow schematic diagram falling card restoration methods of the flash memory cards of an embodiment of the present invention.
Embodiment
For the ease of the understanding of those skilled in the art, below in conjunction with drawings and Examples, the invention will be further described.
Flash memory cards fall a card restoration methods, be applied to electronic equipment, in the present invention, described electronic equipment is preferably the intelligent mobile terminal comprising smart mobile phone, and the step of described method comprises:
S1, the flag bit that whether this flash memory cards of interpolation expression is in place in the status register of flash memory cards, and default settings;
S2, detect in the read-write process of flash memory cards whether occur read and write interrupt event, if so, then revise the described flag bit of status register;
After the central processing unit of S3, described electronic equipment detects modified flag bit, control the initialization carry of flash memory cards, and described flag bit is reverted to default value.
In step sl, by adding a register flag bit (Status Flag) to represent that flash memory cards is in place or falls to carry, preferably, the default value of the flag bit that status register adds is set for " 1 ", when for time " 1 ", this flag bit represents that flash memory cards is in place, otherwise when for time " 0 ", this flag bit represents that flash memory cards is not in place.Of the present invention not in place refer to that flash is stuck in and is subject to the interference such as electrostatic after, reading and writing data between electronic device body and flash memory cards is abnormal to interrupt, although now electrical connection is between the two normal, transfer of data is obstructed, cannot normally read and write data.Rely on existing fall carry detect only can detect that the bad connection caused of interface contact is obstructed, and can not detect in such cases because the interference such as electrostatic cause reading and writing disruption, thus initiatively can only carry out reboot operation again to identify flash memory cards to equipment by user.Object of the present invention is exactly fall to carry a problem for flash memory cards, and when by the interference such as electrostatic, read-write is interrupted for it, end side can detect voluntarily and repair fast.
In step s 2, when flash memory cards generation data read-write operation, start abnormal detection function, to detect the read-write abnormal interruption in read-write process.It is be connected disconnection because the Signal transmissions between electronic device terminal with flash memory cards is obstructed that described read-write is interrupted, and both cannot normally receive and send data each other.In the preferred embodiment, when receiving read-write abnormal interruption information, by the flag bit reset that status register adds, be namely revised as " 0 " by default value " 1 ", when this flag bit is for representing time " 0 " that flash memory cards falls to carry.
In step step S3, as the CPU of electronic equipment, namely after central processing unit detects described flag bit reset, control the initialization carry of flash memory cards, namely the power supply power-off of flash memory cards is controlled, and then power on, the setup code simultaneously reloading flash memory cards, to find flash memory cards, connects.After the initialization of flash memory cards has loaded, flag bit is reset to " 1 ".
In the preferred embodiment, described flash memory cards is TF(Trans-flashCard) card, i.e. MicroSDCard card, also can comprise SD card (SecureDigitalMemoryCard) etc.
Particularly, as shown in Figure 1, for smart mobile phone, present invention also offers a kind of realization flow falling card restoration methods of flash memory cards of embodiment, its step comprises:
S101, add in the status register of flash memory cards and represent this flash memory cards flag bit whether in place, and to arrange its default value be 1;
S102, the behavior of flash memory cards generation reading and writing data;
Monitoring function is interrupted in S103, startup read-write;
S104, detect in the read-write process of flash memory cards whether occur read and write interrupt event, if so, perform step S105, otherwise repeat step S104;
S105, by the described mark position 0 of status register;
The central processing unit of S106, electronic equipment detects mark position 0;
S107, control flash memory cards power cut-off and power on again, reload the setup code of flash memory cards;
S108, initialization complete, and described flag bit is reverted to default value.
The invention also discloses a kind of mobile terminal, be equipped with flash memory cards, comprising:
Flag bit memory cell, represents for adding one in the status register of flash memory cards the flag bit whether this flash memory cards is in place, and default settings;
Interrupt detecting unit, whether occurring to read and write interrupt event for detecting in the read-write process of flash memory cards, if so, then revising the described flag bit of status register;
Initialization unit, for after modified flag bit being detected, controls the initialization carry of flash memory cards, and described flag bit is reverted to default value.
Preferably, described flag bit memory cell is 1 for the default value of the flag bit arranging status register interpolation, represents that flash memory cards is in place when this flag bit is 1.
Preferably, described interruption detecting unit is 0 for revising the flag bit of status register interpolation, represents that flash memory cards falls to carry when this flag bit is 0.
Described initialization unit refers to the power cut-off of control flash memory cards for the initialization carry controlling flash memory cards and powers on, reloads the setup code of flash memory cards simultaneously.
Preferably, the flash memory cards of this mobile terminal is TF card.
Above content is in conjunction with concrete optimal way further description made for the present invention, should not assert that specific embodiment of the invention is confined to above explanation.For those skilled in the art, without departing from the inventive concept of the premise, some simple deduction or replace can also be made, within the protection range that the claim that all should be considered as being submitted to by the present invention is determined.

Claims (6)

1. flash memory cards fall a card restoration methods, be applied to electronic equipment, its step comprises:
S1, the flag bit that whether this flash memory cards of interpolation one expression is in place in the status register of flash memory cards, and default settings;
S2, detect in the read-write process of flash memory cards whether occur read and write interrupt event, if so, then revise the described flag bit of status register;
After the central processing unit of S3, described electronic equipment detects modified flag bit, control the initialization carry of flash memory cards, and described flag bit is reverted to default value;
The default value that described step S1 arranges the flag bit that status register adds is 1, represents that flash memory cards is in place when this flag bit is 1;
The flag bit that described step S2 revises status register interpolation is 0, represents that flash memory cards falls to carry when this flag bit is 0.
2. flash memory cards according to claim 1 fall card restoration methods, it is characterized in that: the initialization carry that described step S3 controls flash memory cards refers to the power cut-off of control flash memory cards and powers on, reloads the setup code of flash memory cards simultaneously.
3. the flash memory cards according to any one of claim 1-2 fall card restoration methods, it is characterized in that: described flash memory cards is TF card.
4. a mobile terminal, is equipped with flash memory cards, it is characterized in that, comprising:
Flag bit memory cell, represents for adding one in the status register of flash memory cards the flag bit whether this flash memory cards is in place, and default settings;
Interrupt detecting unit, whether occurring to read and write interrupt event for detecting in the read-write process of flash memory cards, if so, then revising the described flag bit of status register;
Initialization unit, for after modified flag bit being detected, controls the initialization carry of flash memory cards, and described flag bit is reverted to default value;
Described flag bit memory cell is 1 for the default value of the flag bit arranging status register interpolation, represents that flash memory cards is in place when this flag bit is 1;
Described interruption detecting unit is 0 for revising the flag bit of status register interpolation, represents that flash memory cards falls to carry when this flag bit is 0.
5. mobile terminal according to claim 4, it is characterized in that: described initialization carry unit refers to the power cut-off of control flash memory cards for the initialization carry controlling flash memory cards and powers on, reloads the setup code of flash memory cards simultaneously.
6. the mobile terminal according to any one of claim 4-5, is characterized in that: described flash memory cards is TF card.
CN201310518426.1A 2013-10-29 2013-10-29 A kind of flash memory cards fall card restoration methods and mobile terminal thereof Expired - Fee Related CN103546638B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310518426.1A CN103546638B (en) 2013-10-29 2013-10-29 A kind of flash memory cards fall card restoration methods and mobile terminal thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310518426.1A CN103546638B (en) 2013-10-29 2013-10-29 A kind of flash memory cards fall card restoration methods and mobile terminal thereof

Publications (2)

Publication Number Publication Date
CN103546638A CN103546638A (en) 2014-01-29
CN103546638B true CN103546638B (en) 2016-02-03

Family

ID=49969671

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310518426.1A Expired - Fee Related CN103546638B (en) 2013-10-29 2013-10-29 A kind of flash memory cards fall card restoration methods and mobile terminal thereof

Country Status (1)

Country Link
CN (1) CN103546638B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104077250B (en) * 2014-06-27 2019-02-01 Tcl集团股份有限公司 A kind of connection processing method and device of intelligent terminal and storage equipment
CN105045671B (en) * 2015-08-17 2018-04-03 广东欧珀移动通信有限公司 The method for upgrading system and device of a kind of intelligent terminal
CN108399135B (en) * 2018-03-02 2021-05-18 郑州云海信息技术有限公司 Control method for disk equipment identification and related device
CN110412927A (en) * 2019-08-23 2019-11-05 深圳市欧深特信息技术有限公司 A kind of optical module is in position detecting method and optical module

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1914627A (en) * 2004-02-03 2007-02-14 松下电器产业株式会社 Memory card, data processor, memory card control method and memory card setting method
CN101150697A (en) * 2006-09-18 2008-03-26 三星电子株式会社 Electronic device mounted with memory card and reset method of the memory card
CN101751098A (en) * 2008-12-02 2010-06-23 华为技术有限公司 Method, device and system for realizing reset control
CN101945165A (en) * 2010-08-30 2011-01-12 龙金(北京)投资有限公司 Service processing method and device of expansion card
CN102955755A (en) * 2011-08-23 2013-03-06 华为终端有限公司 Data card and method for repairing abnormal communication between data card and main unit

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6463559B1 (en) * 1999-06-30 2002-10-08 International Business Machines Corporation Non-volatile fault indicator

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1914627A (en) * 2004-02-03 2007-02-14 松下电器产业株式会社 Memory card, data processor, memory card control method and memory card setting method
CN101150697A (en) * 2006-09-18 2008-03-26 三星电子株式会社 Electronic device mounted with memory card and reset method of the memory card
CN101751098A (en) * 2008-12-02 2010-06-23 华为技术有限公司 Method, device and system for realizing reset control
CN101945165A (en) * 2010-08-30 2011-01-12 龙金(北京)投资有限公司 Service processing method and device of expansion card
CN102955755A (en) * 2011-08-23 2013-03-06 华为终端有限公司 Data card and method for repairing abnormal communication between data card and main unit

Also Published As

Publication number Publication date
CN103546638A (en) 2014-01-29

Similar Documents

Publication Publication Date Title
CN103546638B (en) A kind of flash memory cards fall card restoration methods and mobile terminal thereof
EP2843768B1 (en) Sim card connector and mobile terminal
CN103823769A (en) Computer system and data recovery method
CN102387022A (en) Power over Ethernet method and device
CN201269902Y (en) Break-down detection circuit for electronic electrical energy meter
CN205195387U (en) Stake of charging and fall electric memory circuit thereof
CN102970432B (en) A kind of mobile terminal and the method controlling SIM card hot plug thereof
CN108027780B (en) Memory content protection circuit
CN104777891A (en) OTG (on-the-go) connecting control method applied to intelligent terminal and connecting control device
US9489002B2 (en) Providing power to a component
CN103024195A (en) Smart mobile terminal and implementation method of charging of smart mobile terminal
CN102054370A (en) USB (universal serial bus) cable controller and electronic reading device using same
CN102043933A (en) SD (Secure Digital) card reader module with controllable operating state
CN102915209B (en) Storage control chip, storage equipment and system data writing method
CN210925482U (en) Storage device based on Loongson processor
CN105654003B (en) A kind of IC card detection method and device in place
US9575535B2 (en) Integrated circuit and operation method thereof
CN209821822U (en) Control circuit and computer of PCIE equipment hot plug
CN202486769U (en) Protective circuit of block storage
CN102420899B (en) Device and method for automatically switching working state of Bluetooth terminal equipment according to working state of mainframe
CN108648781A (en) A kind of storage device detection device
US20130061030A1 (en) System capable of booting through a universal serial bus device and method thereof
CN105098854A (en) Charging method and electronic apparatus
CN110442539B (en) Mobile phone OTG switching method and device
CN110908673B (en) Digital power supply chip burning method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Patentee after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

Address before: Changan Town, Guangdong province 523860 usha Beach Road Dongguan City, No. 18 Guangdong Oupo Mobile Communication Co Ltd

Patentee before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20160203