One-key restore method, system, terminal and storage medium based on Android system
Patent Information
- Application Number
- CN202310028153.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-01-09
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2043-01-09
AI Technical Summary
[0003]本发明的目的在于提供一种基于安卓系统一键还原方法、系统、终端及存储介质,旨在解决现有技术无法进入系统卡机在开机l ogo的故障,无法使用的问题
[0024] Compared with the prior art, the embodiments of the present invention have the following advantages: when the computer is turned on, the MCU reads the reset button status. If it detects that the restore button is pressed, it delays pulling the reset IO high to reset the main control IC, and pulls the recovery IO high to make the main control IC enter the recovery interface;
Smart Images

Figure CN115951941B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of one-key restoration, and in particular relates to a one-key restoration method, system, terminal and storage medium based on an Android system. Background Art
[0002] The current Android system's built-in system restore function requires navigating to System -> Advanced -> Reset Options in the Settings menu. This method only works after the device boots normally and enters the system. It cannot be used for issues that prevent the device from entering the system or freeze during the boot-up and login phase. These freezes during the boot-up and login phase are particularly prone to product returns and repairs. Summary of the Invention
[0003] The purpose of the present invention is to provide a one-key restore method, system, terminal and storage medium based on the Android system, aiming to solve the problem that the existing technology cannot enter the system and the machine is stuck at the startup logo, making it unusable.
[0004] In one aspect, the method comprises the steps of:
[0005] When the device is powered on, the MCU reads the reset button status. If it detects that the restore button is pressed, it delays pulling the reset IO high to reset the main control IC, and pulls the recovery IO high to make the main control IC enter the recovery interface.
[0006] At the same time, when the main control IC is turned on, the system kernel checks the set restore button status. If it detects that the restore button is pressed, the system kernel writes the address where the restore firmware is stored to an address that can be recognized by the recovery;
[0007] After the main control IC enters the recovery mode, it reads the path written by the system kernel, enters the restore mode and automatically reads the restore firmware in the path to perform the restore operation.
[0008] On the other hand, the address identifiable by the recovery is by default the update in the USB flash drive.
[0009] On the other hand, when booting up, if the restore button is detected to be pressed, the MCU delay time is 5-15 seconds.
[0010] In addition, to achieve the above purpose, the present invention also provides a one-key restoration system:
[0011] MCU, main control IC and reset button;
[0012] The MCU and the main control IC are both electrically connected to the restore button;
[0013] The reset pin of the main control IC is electrically connected to the MCU;
[0014] The MCU is electrically connected to the recovery pin of the main control.
[0015] On the other hand, the one-key restore system further includes: a detection module, configured to detect whether the restore button is pressed.
[0016] On the other hand, the one-key restore system further includes:
[0017] The control module is used to control the MCU to pull up the reset IO to reset the main control IC and at the same time pull up the recovery IO to make the main control IC enter the recovery interface; at the same time, it controls the system kernel to write the address where the restoration firmware is stored to an address that can be recognized by the recovery.
[0018] On the other hand, the one-key restore system further includes:
[0019] Delay module: MCU delays for five seconds before taking the next action after receiving the signal sent by the sending module.
[0020] On the other hand, the one-key restore system further includes:
[0021] The processing module is used to read the path written by the system kernel, jump into the recovery mode, enter the recovery mode and automatically read the recovery firmware in the path to perform the recovery operation.
[0022] In addition, to achieve the above-mentioned purpose, the present invention also provides a terminal, which includes a memory, a processor, and a computer program stored in the memory and runnable on the processor, characterized in that the processor implements the steps of the above-mentioned one-key restoration method when executing the computer program.
[0023] In addition, to achieve the above-mentioned purpose, the present invention further provides a storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the above-mentioned one-key restoration method are implemented.
[0024] Compared with the prior art, the embodiments of the present invention have the following advantages: when the computer is turned on, the MCU reads the reset button status. If it detects that the restore button is pressed, it delays pulling the reset IO high to reset the main control IC, and pulls the recovery IO high to make the main control IC enter the recovery interface;
[0025] At the same time, when the main control IC is turned on, the system kernel checks the set restore button status. If it detects that the restore button is pressed, the system kernel writes the address where the restore firmware is stored to an address that can be recognized by the recovery;
[0026] After the main control IC enters the recovery mode, it reads the path written by the system kernel, enters the restore mode and automatically reads the restore firmware in the path to perform the restore operation. The present invention achieves one-click system restoration during the boot phase through the mutual cooperation of the MCU and the CPU main control. Regardless of whether the system is damaged, cannot be booted due to a third-party APK root, or the system runs slowly, the problem can be solved with one-click restoration, so that ordinary users no longer need to use professional and cumbersome tools to flash the system, thereby enhancing the affinity and competitiveness of the product. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 This is a circuit diagram of the master reset pin based on the one-key restoration method of the Android system of the present invention;
[0028] Figure 2 This is a circuit diagram of a master reset pin and a single-chip microcomputer connection pin based on an Android system one-key restore method of the present invention;
[0029] Figure 3 The present invention is a circuit diagram of the pins connected to a single-chip microcomputer based on the one-key restoration method of the Android system.
[0030] Figure 4 The present invention is a circuit diagram for connecting the pins of a single-chip microcomputer and the recovery of a main control based on a one-key restoration method of an Android system.
[0031] Figure 5 It is an overall circuit diagram of a single chip microcomputer based on the one-key restoration method of the Android system of the present invention.
[0032] Figure 6 The present invention is a flow chart of a single chip microcomputer based on the one-key restoration method of the Android system.
[0033] Figure 7 It is a structural diagram of the hardware operation of the terminal device involved in the embodiment of the present invention. DETAILED DESCRIPTION
[0034] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0035] The following describes the specific implementation of the present invention in detail with reference to specific embodiments:
[0036] Example 1:
[0037] Figure 6 The following is an implementation flow of a one-key restore method based on an Android system provided in the first embodiment of the present invention. For ease of illustration, only the parts related to the embodiment of the present invention are shown, which are detailed as follows:
[0038] The method comprises the following steps:
[0039] S100, when powering on, MCU reads the reset button status;
[0040] S101, if it is detected that the restore button is pressed, the reset IO is pulled high for a delay to reset the main control IC, and the recovery IO is pulled high to make the main control IC enter the recovery interface;
[0041] S100, at the same time, when the main control IC is turned on, the system core checks the set restore button status;
[0042] S101, if it is detected that the restore button is pressed, the system kernel writes the address where the restore firmware is stored into an address that can be recognized by the recovery;
[0043] S102, after the main control IC enters the recovery mode, it reads the path written by the system kernel, enters the restore mode and automatically reads the restore firmware in the path to perform the restore operation.
[0044] When the method provided in this embodiment is applied, the present invention reads the set restore button status through the MCU when the computer is turned on. If it is detected that the restore button is pressed, the reset IO is pulled high after a delay to reset the main control IC, and the recovery IO is pulled high to make the main control IC enter the recovery interface.
[0045] At the same time, when the main control IC is turned on, the system kernel checks the set restore button status. If it detects that the restore button is pressed, the system kernel writes the address where the restore firmware is stored to an address that can be recognized by the recovery;
[0046] After the main control IC enters the recovery mode, it reads the path written by the system kernel, enters the restore mode and automatically reads the restore firmware in the path to perform the restore operation;
[0047] The present invention achieves one-click system restoration during the boot phase through the cooperation between the MCU and the CPU master control. Whether the system is damaged, cannot be booted due to third-party APK rooting, or the system is running slowly, the problem can be solved with one-click restoration. This eliminates the need for ordinary users to use professional and cumbersome tools to flash the system, thus enhancing the affinity and competitiveness of the product.
[0048] The software program involved in the present invention is:
[0049]
[0050]
[0051] In one embodiment, the address recognizable by the recovery is update in a USB flash drive.
[0052] In one embodiment, when the computer is turned on, if it is detected that the restore button is pressed, the MCU delays for 5-15 seconds.
[0053] Example 2:
[0054] A second embodiment of the present invention provides a reduction system such as Figure 1-Figure 5 As shown, it includes MCU, main control IC and reset button;
[0055] The MCU and the main control IC are both electrically connected to the restore button;
[0056] The reset pin of the main control IC is electrically connected to the MCU;
[0057] The recovery pins of the MCU and the main controller are electrically connected;
[0058] mcu_detect is connected to the MCU, and main_chip_detect is connected to the main controller. The MCU can detect when the user presses the SW_6WGY_269_003 button.
[0059] CPU_RST is connected to the master's RESET_N, so that CPU_RST can control the master's RESET_N to perform a reset operation;
[0060] CPU_RST is connected to the MCU's pin MCU_P2D6_RESET#_OUT through a diode;
[0061] The SW_6WGY_269_003RECOVER button is connected to RECOVER_BT. RECOVER_BT and MCU_P3D1_RECOVER_BT_I N are also connected to ADC_KEY. ADC_KEY is the recover signal received by the main controller. When there is a signal, the main controller performs a reset operation, so that it can enter recovery mode.
[0062] A detection module, configured to detect whether a restore button is pressed;
[0063] The control module is used to control the MCU to pull up the reset IO to reset the main control IC and at the same time pull up the recovery IO to make the main control IC enter the recovery interface; at the same time, it controls the system kernel to write the address where the restored firmware is stored to an address that can be recognized by the recovery;
[0064] Delay module: MCU delays for five seconds to proceed to the next action after receiving the signal sent by the sending module;
[0065] The processing module is used to read the path written by the system kernel, jump into the recovery mode, enter the recovery mode and automatically read the recovery firmware in the path to perform the recovery operation.
[0066] Example 3:
[0067] The embodiment of the present invention further provides a terminal device, which includes: a memory 51, a processor 53, and a computer program 52 stored in the memory 51 and executable on the processor 53. When the processor 53 executes the computer program 52, the steps in the above-mentioned embodiment of the one-key restore method based on the Android system are implemented; for example Figure 6 Alternatively, when the processor 53 executes the computer program 52, the functions of the units in the above-mentioned system embodiments are realized.
[0068] Example 4:
[0069] Embodiment 4 of the present invention further provides a storage medium containing computer-executable instructions, which, when executed by a computer processor, are used to execute the one-key restore method based on the Android system provided in the above embodiment.
[0070] The computer storage medium of the embodiment of the present invention may adopt any combination of one or more computer-readable media. The computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or component, or any combination thereof. More specific examples (a non-exhaustive list) of computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In this document, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device.
[0071] Note that the above are only preferred embodiments of the present invention and the technical principles employed. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and that various obvious changes, readjustments, and substitutions can be made by those skilled in the art without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments and may include many other equivalent embodiments without departing from the concept of the present invention. The scope of the present invention is determined by the scope of the appended claims.
Claims
1. A one-key restore method based on Android system, characterized in that: The method includes the following steps: when the computer is turned on, the MCU reads the status of the reset button. If it detects that the restore button is pressed, it delays pulling the reset IO high to reset the main control IC, and pulls the recovery IO high to make the main control IC enter the recovery interface; At the same time, when the main control IC is turned on, the system kernel checks the set restore button status. If it detects that the restore button is pressed, the system kernel writes the address where the restore firmware is stored to an address that can be recognized by recovery; after the main control IC enters recovery mode, it reads the path written by the system kernel, enters restore mode and automatically reads the restore firmware in the path to perform the restore operation.
2. The method according to claim 1, wherein The method further comprises: The address that can be identified by the recovery is the update in the USB flash drive.
3. The method according to claim 1, wherein The method further comprises: When booting up, if the reset button is detected to be pressed, the MCU will delay for 5-15 seconds.
4. A one-key restore system for implementing the one-key restore method based on the Android system as described in any one of claims 1 to 3, characterized in that: The one-key restore system includes: MCU, main control IC and reset button; The MCU and the main control IC are both electrically connected to the restore button; The reset pin of the main control IC is electrically connected to the MCU; The MCU is electrically connected to the recovery pin of the main control; The one-key restoration system further includes: A detection module is used to detect whether the restore button is pressed; The control module is used to control the MCU to delay pulling up the reset IO to reset the main control IC and simultaneously pull up the recovery IO to make the main control IC enter the recovery interface; at the same time, it controls the system kernel to write the address where the restoration firmware is stored to an address that can be recognized by the recovery; Delay module, detects that the restore button is pressed, and the MCU delays for 5-15 seconds to proceed to the next action; The processing module is used to read the path written by the system kernel, jump into the recovery mode, enter the recovery mode and automatically read the recovery firmware in the path to perform the recovery operation.
5. A one-key restore terminal, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 3 are implemented.
6. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps described in any one of claims 1 to 3 are implemented.