CN113849194B - Burning method and terminal equipment - Google Patents

Burning method and terminal equipment Download PDF

Info

Publication number
CN113849194B
CN113849194B CN202110963738.8A CN202110963738A CN113849194B CN 113849194 B CN113849194 B CN 113849194B CN 202110963738 A CN202110963738 A CN 202110963738A CN 113849194 B CN113849194 B CN 113849194B
Authority
CN
China
Prior art keywords
data
flash memory
information
module
burned
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.)
Active
Application number
CN202110963738.8A
Other languages
Chinese (zh)
Other versions
CN113849194A (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.)
Honor Device Co Ltd
Original Assignee
Honor Device 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 Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202110963738.8A priority Critical patent/CN113849194B/en
Publication of CN113849194A publication Critical patent/CN113849194A/en
Application granted granted Critical
Publication of CN113849194B publication Critical patent/CN113849194B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • G06F8/63Image based installation; Cloning; Build to order

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

The application provides a burning method and terminal equipment, which can shorten the data burning time and improve the data burning efficiency. The method is applied to a terminal device comprising a NAND flash memory and a NOR flash memory, and comprises the following steps: the method comprises the steps that terminal equipment obtains data to be burned, wherein the data to be burned comprises a plurality of data blocks and information of the data blocks; the terminal equipment determines whether the NOR flash memory is empty; in the case where the NOR flash memory is not empty, the terminal device determines whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same; and under the condition that the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the terminal equipment writes all or part of the data to be burned into the NAND flash memory.

Description

Burning method and terminal equipment
Technical Field
The present application relates to the field of storage technologies, and in particular, to a burning method and a terminal device.
Background
Before the terminal device leaves the factory, factory data needs to be burned into the terminal device through a special burning tool (e.g., a computer). At present, two burning methods, namely serial port burning and U disk burning, are mainly adopted. Taking a large screen as an example, the time consumption for serial port burning is about 15 minutes, the time consumption for U disk burning is about 8 minutes, and both the time consumption are more, which seriously affects the development efficiency.
Under the condition that the terminal device has recorded data and needs to record data again, the current serial port recording mode mainly adopted in the industry is an erasing and writing mode, the erasing is full disk erasing, and the data transmitted by the recording tool is written into a single board of the terminal device after the erasing is finished. The whole disk erasing and rewriting process takes longer time, resulting in lower burning efficiency.
Disclosure of Invention
The application provides a burning method and terminal equipment, which can shorten the data burning time and improve the data burning efficiency.
In a first aspect, a burning method is provided, which is applied to terminal devices of a NAND flash memory and a NOR flash memory, and the method includes: and the terminal equipment acquires data to be burned. The data to be burned comprises a plurality of data blocks and information of the data blocks. The terminal device determines whether the NOR flash memory is empty. In the case where the NOR flash memory is not empty, the terminal device determines whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same. And under the condition that the information of the plurality of data blocks is different from the information of the data blocks recorded in the NOR flash memory, the terminal equipment writes all or part of the data to be burned into the NAND flash memory.
The application provides a burning method, a NOR flash memory with high data reading speed is additionally arranged in a flash memory of terminal equipment, after data to be burnt is obtained, data block information in the current data to be burnt and data block information of the data to be burnt recorded at the last time can be compared under the condition that the NOR flash memory is not empty, the data to be burnt corresponding to different data block information can be written into the NAND flash memory, and burning of the data is completed. The method does not need to write all the data to be burned into the NAND flash memory every time, so that the time for burning the data is reduced, and the burning efficiency of the data is improved.
With reference to the first aspect, in some implementations of the first aspect, in a case that information of the plurality of data blocks is different from information of the data blocks recorded in the NOR flash memory, the writing, by the terminal device, all or part of the data to be burned into the NAND flash memory includes: the information of at least one data block in the information of the plurality of data blocks is different from the information of the data blocks recorded in the NOR flash memory, and the terminal equipment writes the data to be burned corresponding to the information of the at least one data block into the NAND flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the information of the data block includes a data name and a verification code; the terminal device determining whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same, including: the terminal device determines whether a plurality of data names in the information of the plurality of data blocks are the same as data names in the information of the data blocks recorded in the NOR flash memory; the information of at least one data block in the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, and the terminal equipment writes the data to be burned corresponding to the information of the at least one data block into the NAND flash memory, and the method comprises the following steps: and the terminal equipment writes the data to be burned corresponding to the at least one first data name into the NAND flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: the terminal equipment determines whether a first verification code is the same as a second verification code or not, wherein the first verification code is a verification code corresponding to at least one second data name, and the second verification code is a verification code corresponding to the data name which is recorded in the NOR flash memory and is the same as the at least one second data name; and under the condition that the first verification code is different from the second verification code, the terminal equipment writes the data to be burned corresponding to at least one second data name into the NAND flash memory.
With reference to the first aspect, in some implementations of the first aspect, after the terminal device writes all or part of the data to be burned into the NAND flash memory, the method further includes: the information of the data blocks recorded in the NOR flash memory is updated. Information for updating a data block recorded in the NOR flash memory includes: and replacing the information of the data blocks recorded in the NOR flash memory with the information of a plurality of data blocks included in the data to be burned.
With reference to the first aspect, in some implementations of the first aspect, updating the data block information recorded in the NOR flash memory includes: adding at least one second data name and at least one check code corresponding to the second data name in the NOR flash memory; and/or replacing a data name and a verification code which are different from the verification code corresponding to the at least one third data name in the NOR flash memory with a check code corresponding to the at least one third data name and the at least one third data name.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: under the condition that the information of the plurality of data blocks is the same as the information of the data blocks recorded in the NOR flash memory, the terminal equipment does not write the data to be burned into the NAND flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: in the case where the NOR flash memory is empty, the terminal device stores a plurality of data blocks in the NOR flash memory; the NOR flash memory records data block information of data to be burned.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: and under the condition that the NOR flash memory is empty, the terminal equipment stores the data to be burned in the NOR flash memory.
With reference to the first aspect, in some implementation manners of the first aspect, the terminal device further includes: the terminal equipment acquires data to be burned, and the method comprises the following steps: the reading module acquires the data to be burned; the terminal equipment determines whether the NOR flash memory is empty or not, including; in a case where the NOR flash memory is not empty, the terminal device determining whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same, including: in a case where the NOR flash memory is not empty, the read module determines whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same; under the condition that the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the terminal equipment writes all or part of the data to be burned into the NAND flash memory, and the method comprises the following steps: under the condition that the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the read module sends all or part of the data to be burned to the write module; and the quick writing module writes all or part of the received data to be burned into the NAND flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the determining, by the reading module, whether the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are the same in a case that the NOR flash memory is not empty includes: the information of at least one data block in the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, and the read module sends the data to be burned corresponding to the information of the at least one data block to the write module; and the writing module writes the received data to be burned corresponding to the information of the at least one data block into the NAND flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the determining, by the reading module, whether the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are the same in a case where the NOR flash memory is not empty includes: the read module determines whether a plurality of data names in the information of the plurality of data blocks are the same as data names in the information of the data blocks recorded in the NOR flash memory; the determining, by the reading module, whether the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are the same in a case where the NOR flash memory is not empty, includes: the information of the at least one data block has at least one first data name different from the data name recorded in the NOR flash memory, and the read module sends the data to be burned corresponding to the at least one first data name to the write module; and the writing module writes the received data to be burned corresponding to the at least one first data name into the NAND flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: the read module determines whether a first verification code is the same as a second verification code, wherein the first verification code is a verification code corresponding to the at least one second data name, and the second verification code is a verification code corresponding to the data name which is recorded in the NOR flash memory and is the same as the at least one second data name; under the condition that the first verification code is different from the second verification code, the reading module sends the data to be burned corresponding to the at least one second data name to the writing module; and the writing module writes the received data to be burned corresponding to the at least one second data name into the NAND flash memory.
With reference to the first aspect, in some implementations of the first aspect, after the writing module writes the data to be burned corresponding to the received information of the at least one data block into the NAND flash memory, the method further includes: the reading module updates the information of the data block recorded in the NOR flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the updating, by the reading module, information of the data block recorded in the NOR flash memory includes: and the reading module replaces the information of the data blocks recorded in the NOR flash memory with the information of a plurality of data blocks included in the data to be burned.
With reference to the first aspect, in certain implementations of the first aspect, the updating, by the reading module, data block information recorded in the NOR flash memory includes: the reading module adds the at least one second data name and a check code corresponding to the at least one second data name in the NOR flash memory; and/or the reading module replaces a data name and a verification code which are different from the verification code corresponding to the at least one third data name in the NOR flash memory with a check code corresponding to the at least one third data name and the at least one third data name.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: and under the condition that the information of the data blocks is the same as the information of the data blocks recorded in the NOR flash memory, the reading module does not send the data to be burned to the writing module.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: in a case where the NOR flash memory is empty, the read module stores the plurality of data blocks in the NOR flash memory; and the reading module records the data block information of the data to be burned in the NOR flash memory.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: and under the condition that the NOR flash memory is empty, the reading module stores the data to be burned in the NOR flash memory.
With reference to the first aspect, in some implementations of the first aspect, before the read module sends all or part of the data to be burned to the write module, the method further includes: and establishing a transmission channel between the reading module and the writing module, wherein the transmission channel is used for data interaction between the reading module and the writing module.
With reference to the first aspect, in certain implementation manners of the first aspect, the terminal device further includes a WIFI module, and the establishing a transmission channel between the read module and the write module includes: the reading module acquires a first internet Interconnection Protocol (IP) address, wherein the first IP address is an IP address of burning equipment, and the burning equipment is used for providing the data to be burned; when the terminal equipment is powered on, the writing module obtains a second IP address from the WIFI module, wherein the second IP address is the IP address of the terminal equipment; and the data interaction between the reading module and the writing module is realized by setting a socket and a Transmission Control Protocol (TCP).
In a second aspect, there is provided a terminal device, including a processor, coupled to a memory, and configured to execute instructions in the memory to implement the method in any one of the possible implementations of the first aspect. Optionally, the terminal device further comprises a memory. Optionally, the terminal device further comprises a communication interface, the processor being coupled to the communication interface.
In a third aspect, a processor is provided, including: input circuit, output circuit and processing circuit. The processing circuit is configured to receive a signal via the input circuit and transmit a signal via the output circuit, so that the processor performs the method of any one of the possible implementations of the first aspect.
In a specific implementation process, the processor may be a chip, the input circuit may be an input pin, the output circuit may be an output pin, and the processing circuit may be a transistor, a gate circuit, a flip-flop, various logic circuits, and the like. The input signal received by the input circuit may be received and input by, for example and without limitation, a receiver, the signal output by the output circuit may be output to and transmitted by a transmitter, for example and without limitation, and the input circuit and the output circuit may be the same circuit that functions as the input circuit and the output circuit, respectively, at different times. The embodiment of the present application does not limit the specific implementation manner of the processor and various circuits.
In a fourth aspect, a processing apparatus is provided that includes a processor and a memory. The processor is configured to read instructions stored in the memory, and may receive signals via the receiver and transmit signals via the transmitter to perform the method of any one of the possible implementations of the first aspect.
Optionally, there are one or more processors and one or more memories.
Alternatively, the memory may be integrated with the processor, or provided separately from the processor.
In a specific implementation process, the memory may be a non-transient memory, such as a Read Only Memory (ROM), which may be integrated on the same chip as the processor, or may be separately disposed on different chips.
It will be appreciated that the associated data interaction process, for example, sending the indication information, may be a process of outputting the indication information from the processor, and receiving the capability information may be a process of receiving the input capability information from the processor. In particular, the data output by the processor may be output to a transmitter and the input data received by the processor may be from a receiver. The transmitter and receiver may be collectively referred to as a transceiver, among others.
The processing device in the fourth aspect may be a chip, and the processor may be implemented by hardware or software, and when implemented by hardware, the processor may be a logic circuit, an integrated circuit, or the like; when implemented in software, the processor may be a general-purpose processor implemented by reading software code stored in a memory, which may be integrated with the processor, located external to the processor, or stand-alone.
In a fifth aspect, there is provided a computer program product comprising: computer program (also called code, or instructions), which when executed, causes a computer to perform the method of any of the possible implementations of the first aspect.
In a sixth aspect, a computer-readable storage medium is provided, which stores a computer program (which may also be referred to as code or instructions) that, when executed on a computer, causes the computer to perform the method of any one of the possible implementations of the first aspect.
Drawings
FIG. 1 is a schematic diagram of a burn scenario;
fig. 2 is a schematic diagram of a system architecture of a terminal device according to an embodiment of the present application;
FIG. 3 is a block diagram of a system architecture provided by an embodiment of the present application;
FIG. 4 is a schematic flow chart of a burning method provided in an embodiment of the present application;
fig. 5 is a schematic flowchart of another burning method according to an embodiment of the present disclosure.
Detailed Description
The technical solution in the present application will be described below with reference to the accompanying drawings.
For ease of understanding, the relevant terms referred to in this application will first be described.
1. Burning: that is, the desired data is recorded on the media such as optical disc, recording card, etc. by the tools such as recorder, recording software, etc.
2. Flash memory (flash): is a form of electrically erasable programmable read-only memory that allows for multiple erases or writes during operation. This technology is mainly used for general data storage and data exchange between computers and other digital products, such as memory cards and usb disks. Flash memory is a type of non-volatile memory, i.e., power-off data is not lost.
The flash memory includes NAND flash memory and NOR flash memory. The NAND flash memory has the advantages of large capacity, high rewriting speed, and the like, and is suitable for storing a large amount of data, so that the NAND flash memory is more and more widely applied in the industry, for example, embedded products include a digital camera, an MP3 walkman memory card, a small-sized usb disk, and the like, but the storage and reading of information are slow. NOR flash memory has high transfer efficiency, fast data reading speed, high cost efficiency at small capacity of 1-4 MB, but slow writing and erasing speed.
Before the terminal device leaves the factory, factory parameter data needs to be burned into the terminal device through a special burning tool device (e.g., a computer). Currently, two burning methods, namely serial port burning and U disk burning, are mainly adopted.
Fig. 1 shows a burning scene diagram. As shown in fig. 1, the scenario 100 includes: burning device 110 and terminal device 120. The burning device 110 may burn the mirror image data to be burned in the burning device 110 into the terminal device 120 in a manner of burning a usb disk or burning a serial port.
The burning device in the embodiment of the present application may be a computer or other electronic devices with burning function.
The terminal device in the embodiment of the present application may be any electronic device having a storage function. For example, the mobile terminal may be a large screen, a mobile phone, a tablet computer, a notebook computer, a palm computer, a Mobile Internet Device (MID), a wearable device, or the like.
Fig. 2 shows a system architecture 200 of a terminal device according to an embodiment of the present application. As shown in fig. 2, the terminal device includes a processor 210 and a memory 230. The memory 230 may include NAND flash memory and NOR flash memory, among others.
Optionally, the terminal device may further include a transceiver 220. The processor 210, the transceiver 220, and the memory 230 may communicate with each other via internal connection paths to transfer control and/or data signals, the transceiver 230 may be configured to receive and transmit data, and the processor 210 may be configured to process data obtained by the transceiver.
Optionally, the terminal device may further include an antenna 240 for transmitting the wireless signal output from the transceiver 220.
The processor 210 may be combined with the memory 230 into a processing device, and more generally, separate components, and the processor 210 is configured to execute the program code stored in the memory 230 to implement the functions described above. In particular implementations, the memory 230 may be integrated into the processor 210 or may be separate from the processor 210.
In addition, in order to make the functions of the terminal device more complete, the terminal device may further include one or more of an input unit 260, a display unit 270, an audio circuit 280, a camera 290, a sensor 202, and the like, and the audio circuit may further include a speaker 282, a microphone 284, and the like.
Optionally, the terminal device may further include a power supply 250 for supplying power to various devices or circuits in the terminal device.
It is understood that the operations and/or functions of the respective modules in the terminal device shown in fig. 2 are respectively for implementing the corresponding flows in the following method embodiments. Specifically, reference may be made to the description of the method embodiments described below, and a detailed description is appropriately omitted herein to avoid redundancy.
It will be appreciated that the processor 210 in the terminal device shown in fig. 2 may include one or more processing units, such as: the processor 210 may include an Application Processor (AP), a modem processor, a Graphics Processor (GPU), an Image Signal Processor (ISP), a controller, a video codec, a Digital Signal Processor (DSP), a baseband processor, and/or a neural-Network Processing Unit (NPU), among others. The different processing units may be separate devices or may be integrated into one or more processors.
A memory may also be provided in processor 210 for storing instructions and data. In some embodiments, the memory in the processor 210 is a cache memory. The memory may hold instructions or data that have just been used or recycled by the processor 210. If the processor 210 needs to use the instruction or data again, it can be called directly from the memory. Avoiding repeated accesses reduces the latency of the processor 210, thereby increasing the efficiency of the system.
In some embodiments, processor 210 may include one or more interfaces. The interface may include an integrated circuit (I2C) interface, an integrated circuit built-in audio (I2S) interface, a Pulse Code Modulation (PCM) interface, a universal asynchronous receiver/transmitter (UART) interface, a Mobile Industry Processor Interface (MIPI), a general-purpose input/output (GPIO) interface, a Subscriber Identity Module (SIM) interface, and/or a Universal Serial Bus (USB) interface, etc.
The I2C interface is a bidirectional synchronous serial bus including a serial data line (SDA) and a Serial Clock Line (SCL). In some embodiments, processor 210 may include multiple sets of I2C buses. The processor 210 may be coupled to the touch sensor 280K, the charger, the flash, the camera 290, etc. through different I2C bus interfaces. For example: the processor 210 may be coupled to the touch sensor 280K through an I2C interface, so that the processor 210 and the touch sensor 280K communicate through an I2C bus interface to implement a touch function of the terminal device.
The I2S interface may be used for audio communication. In some embodiments, processor 210 may include multiple sets of I2S buses. Processor 210 may be coupled to audio circuitry 280 via an I2S bus, enabling communication between processor 210 and audio circuitry 280. In some embodiments, the audio circuit 280 may transmit the audio signal to the transceiver 220 through the I2S interface, so as to implement the function of answering a voice call through a bluetooth headset.
The PCM interface may also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, audio circuitry 280 and transceiver 220 may be coupled by a PCM bus interface. In some embodiments, the audio circuit 280 may also transmit audio signals to the transceiver 220 through the PCM interface, so as to implement the function of answering a voice call through a bluetooth headset. Both the I2S interface and the PCM interface may be used for audio communication.
The UART interface is a universal serial data bus used for asynchronous communications. The bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is generally used to connect the processor 210 and the transceiver 220. For example: the processor 210 communicates with the bluetooth module in the transceiver 220 through the UART interface to implement the bluetooth function. In some embodiments, the audio circuit 280 may transmit the audio signal to the transceiver 220 through the UART interface, so as to realize the function of playing music through the bluetooth headset.
The MIPI interface may be used to connect the processor 210 with peripheral devices such as the display unit 270, the camera 290, and the like. The MIPI interface includes a Camera Serial Interface (CSI), a Display Serial Interface (DSI), and the like. In some embodiments, processor 210 and camera 290 communicate via a CSI interface to implement the capture function of the terminal device. The processor 210 and the display unit 270 communicate through a DSI interface to implement a display function of the terminal device.
The GPIO interface may be configured by software. The GPIO interface may be configured as a control signal and may also be configured as a data signal. In some embodiments, a GPIO interface may be used to connect the processor 210 with the camera 290, the display unit 270, the transceiver 220, the audio mode circuitry 280, the sensor 202, and the like. The GPIO interface may also be configured as an I2C interface, I2S interface, UART interface, MIPI interface, and the like.
It should be understood that the connection relationship between the modules illustrated in the embodiment of the present application is only an exemplary illustration, and does not form a limitation on the structure of the terminal device. In other embodiments of the present application, the terminal device may also adopt different interface connection manners or a combination of multiple interface connection manners in the foregoing embodiments.
It will be appreciated that the power supply 250 shown in fig. 2 is used to power the processor 210, memory 230, display unit 270, camera 290, input unit 260, transceiver 220, etc.
The antenna 240 is used to transmit and receive electromagnetic wave signals. Each antenna in a terminal device may be used to cover a single or multiple communication bands. Different antennas can also be multiplexed to improve the utilization of the antennas. For example: the antenna 240 may be multiplexed as a diversity antenna for a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The transceiver 220 may provide solutions for wireless communication applied to a terminal device, including Wireless Local Area Networks (WLANs) (e.g., wireless fidelity (Wi-Fi) networks), bluetooth (BT), global Navigation Satellite System (GNSS), frequency Modulation (FM), near Field Communication (NFC), infrared (IR), and the like. The transceiver 220 may be one or more devices that integrate at least one communication processing module. The transceiver 220 receives electromagnetic waves via the antenna 240, frequency modulates and filters electromagnetic wave signals, and transmits the processed signals to the processor 210. The transceiver 220 may also receive signals to be transmitted from the processor 210, frequency modulate them, amplify them, and convert them into electromagnetic waves via the antenna 240 for radiation.
In some embodiments, the antenna 240 and the transceiver 220 of the terminal device are coupled such that the terminal device can communicate with the network and other devices via wireless communication techniques. The wireless communication technology may include global system for mobile communications (GSM), general Packet Radio Service (GPRS), code division multiple access (code division multiple access, CDMA), wideband Code Division Multiple Access (WCDMA), time-division code division multiple access (time-division code division multiple access, TD-SCDMA), long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and/or IR technologies, etc. The GNSS may include a Global Positioning System (GPS), a global navigation satellite system (GLONASS), a beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS), and/or a Satellite Based Augmentation System (SBAS).
The terminal device implements a display function by the GPU, the display unit 270, and the application processor, etc. The GPU is a microprocessor for image processing, and is connected to the display unit 270 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 210 may include one or more GPUs that execute program instructions to generate or alter display information.
The display unit 270 is used to display images, videos, and the like. The display unit 270 includes a display panel. The display panel may adopt a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (active-matrix organic light-emitting diode, AMOLED), a flexible light-emitting diode (FLED), a miniature, a Micro-oeld, a quantum dot light-emitting diode (QLED), and the like. In some embodiments, the terminal device may include 2 or N display units 270, N being a positive integer greater than 2.
The terminal device can implement a photographing function through the ISP, the camera 290, the video codec, the GPU, the display unit 270, the application processor, and the like.
The ISP is used to process the data fed back by the camera 290. For example, when a video is recorded, the camera is turned on, light is transmitted to the camera photosensitive element through the lens, an optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing and converting into an image visible to naked eyes. The ISP can also carry out algorithm optimization on noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in camera 290.
Camera 290 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image to the photosensitive element. The photosensitive element may be a Charge Coupled Device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The light sensing element converts the optical signal into an electrical signal, which is then passed to the ISP where it is converted into a digital image signal. And the ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into image signal in standard RGB, YUV and other formats. In some embodiments, the terminal device may include 2 or N cameras 290, N being a positive integer greater than 2.
The digital signal processor is used for processing digital signals, and can process digital image signals and other digital signals. For example, when the terminal device selects the frequency point, the digital signal processor is used for performing fourier transform and the like on the frequency point energy.
Video codecs are used to compress or decompress digital video. The terminal device may support one or more video codecs. Thus, the terminal device can play or record videos in various encoding formats, such as: moving Picture Experts Group (MPEG) 2, MPEG2, MPEG3, MPEG4, and the like.
The NPU is a neural-network (NN) computing processor that processes input information quickly by using a biological neural network structure, for example, by using a transfer mode between neurons of a human brain, and can also learn by itself continuously. The NPU can realize the intelligent cognition and other applications of the terminal equipment, such as: image recognition, face recognition, speech recognition, text understanding, and the like.
Memory 230 may be used to store computer-executable program code, which includes instructions. The memory 230 may include a program storage area and a data storage area. The storage program area may store an operating system, an application program (such as a sound playing function, an image playing function, etc.) required by at least one function, and the like. The storage data area may store data (such as audio data, a phonebook, etc.) created during use of the terminal device, and the like. In addition, the memory 230 may include a high speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, a Universal Flash Storage (UFS), and the like. The processor 210 executes various functional applications of the terminal device and data processing by executing instructions stored in the memory 230 and/or instructions stored in a memory provided in the processor.
The terminal device may implement audio functions through audio circuitry 280, speaker 282, microphone 284, and an application processor, among other things. Such as music playing, recording, etc.
Audio circuit 280 is used to convert digital audio information to an analog audio signal output and also to convert an analog audio input to a digital audio signal. The audio circuit 280 may also be used to encode and decode audio signals. In some embodiments, the audio circuit 280 may be disposed in the processor 210, or some functional blocks of the audio circuit 280 may be disposed in the processor 210.
The speaker 282, also called a "horn", is used to convert electrical audio signals into sound signals. The terminal device can listen to music through the speaker 282 or listen to a handsfree call.
The microphone 284, also known as a "microphone," is used to convert acoustic signals into electrical signals. When making a call or transmitting voice information, the user can input a voice signal into the microphone 284 by sounding a sound near the microphone 284. The terminal device may be provided with at least one microphone 284. In other embodiments, the terminal device may be provided with two microphones 284, which may also implement a noise reduction function in addition to collecting sound signals. In other embodiments, the terminal device may further include three, four or more microphones 284 for collecting sound signals, reducing noise, identifying sound sources, and implementing directional recording functions.
At present, most of the storage supported by the terminal equipment is a NAND flash memory, and the storage is slow in information reading and fast in writing speed. Exemplarily, in fig. 1, the burning device 110 transmits the mirror image data to be burned to the terminal device 120 through a network cable, and after the read-write module corresponding to the NAND flash memory in the terminal device 120 acquires the mirror image data to be burned, all original data in the memory (NAND flash memory) of the terminal device are directly erased, and then all new mirror image data transmitted by the PC are rewritten. The whole disk erasing and rewriting process takes longer time, resulting in lower burning efficiency.
In view of this, the present application provides a recording method, in which a NOR flash memory with a higher data reading speed is newly added in a flash memory of a terminal device, and a corresponding relationship between a NAND flash memory and a writing module and a corresponding relationship between the NOR flash memory and a reading module are established, so that the writing module can write data into the NAND flash memory, and the reading module can quickly read data to be recorded transmitted by a recording device. Under the condition that the data to be burned exists, the data to be burned and the data which are burned and written into the flash memory at the previous time can be compared through the reading module, second data which are different from the data in the flash memory are obtained, and the second data are written into the NAND flash memory through the writing module, so that the burning of the data is completed. The method can reduce the data burning time and improve the data burning efficiency.
Hereinafter, the recording method according to the embodiment of the present application will be described in detail with reference to the system architecture diagram shown in fig. 3, taking a recording device as a Personal Computer (PC) and a terminal device as a large screen as examples. As shown in fig. 3, the PC 310 and the large screen 320 are connected by a network cable. The PC 310 includes therein mirror image data to be burned. The large screen 320 comprises a software layer and a hardware layer, an application framework layer of the software layer comprises a WIFI module, a reading module and a writing module, a RAN of the hardware layer comprises a flash memory partition, and the flash memory partition comprises a NAND flash memory and a NOR flash memory. The WIFI module is used for providing an Internet Protocol (IP) address, the reading module is used for acquiring mirror image data to be burnt transmitted to the terminal device by the burning device, and the writing module is used for acquiring the mirror image data to be burnt from the reading module and writing the acquired mirror image data into the NAND flash memory. Further, the NOR flash memory may read the image data to be burned from the PC 310 through the read module, and the NAND flash memory may store the data in the NAND flash memory through the write module. Data transmission can be carried out between the reading module and the writing module. The WIFI module is used for providing an IP address for the writing module.
It should be understood that the mirror data to be burned may include tens of mirror data, and each mirror data has a data name and a corresponding check code, for example, the chip changer vendor.
Step one, the PC 310 transmits first mirror image data to be burned to the large screen 320 through a network cable, and a read module of the large screen 320 acquires the first mirror image data to be burned, where the first mirror image data includes a plurality of first sub-mirror image data (data blocks) and information of the plurality of first sub-mirror image data (information of the data blocks), and the information of the first sub-mirror image data includes a data name and a check code of the first sub-mirror image data.
In the embodiment of the application, the data to be burned for the first time is called as first mirror image data.
And step two, the reading module judges whether the storage of the NOR flash memory is empty.
In case the storage of the NOR flash memory is empty (i.e. no data is currently stored in the NOR flash memory), the read module stores a plurality of first sub-mirror data comprised by the first mirror data in the NOR flash memory.
It is understood that the storage of the NOR flash memory as empty indicates that the recording is the first recording, and the first mirror data can be written into the NAND flash memory without the writing module.
And step three, recording the data names and the check codes corresponding to all the first sub-mirror image data stored in the NOR flash memory by the reading module in the NOR flash memory to complete the burning of the first mirror image data.
Optionally, in the second step, when the read module determines that the NOR flash memory is empty, the plurality of first sub-image data included in the first image data, and the data names and the verification codes corresponding to the plurality of first sub-image data may be directly stored in the NOR flash memory.
In the embodiment of the application, the data which is burned for the first time is stored in the NOR flash memory, so that the time for reading the data during the second burning can be shortened, namely after the mirror image data to be burned for the second time is obtained, the data to be burned can be quickly read and compared through the reading module.
It can be understood that, if the first mirror image data is the 1.1 version of the software a, the first burning is completed after the third step, and at this time, the software a with the version of 1.1 can be run on the large screen.
Step four, the PC 310 transmits the second mirror image data to be burned to the large screen 320 through the network cable, and the reading module in the large screen 320 acquires the second mirror image data, where the second mirror image data includes a plurality of second sub-mirror image data (data blocks) and information of the second sub-mirror image data (information of the data blocks), and the information of the second sub-mirror image data includes a data name and a check code of the second sub-mirror image data.
In the embodiment of the application, the data to be burned for the second time is referred to as second mirror image data.
It should be understood that the second mirrored data may be identical to the first mirrored data, or the first mirrored data may be included in the second mirrored data, or a part of the second mirrored data may be identical to the first mirrored data (e.g., mirrored data with different data names, or mirrored data with the same data name and different check codes).
And step five, the reading module judges whether the NOR flash memory is empty.
And under the condition that the storage of the NOR flash memory is not empty, the reading module compares the data name and the verification code of each piece of second sub-mirror image data in the second mirror image data with the data name and the verification code of the recorded first mirror image data respectively and judges whether the data name and the verification code are the same or not.
It is understood that, in the comparison process, the reading module may read the name and the verification code of the data stored in the NOR flash memory last time from the NOR flash memory, so as to perform the comparison process; or, the read module itself records the data name and the verification code corresponding to the mirror image data stored in the current flash memory, so that the comparison process can be directly performed, and the specific implementation manner is not limited in this application.
It is understood that the storage of the NOR flash is not empty indicating that this burst is not the first burst.
Further, the reading module may select one of the second data names in the second sub-mirror data one by one, and compare the selected one (currently) at a time with the first data names in the first sub-mirror data recorded in the NOR flash memory:
1. and if the same data name does not exist, the reading module directly sends the second sub-mirror image data corresponding to the currently selected second data name to the writing module, and the writing module writes the second sub-mirror image data into the NAND flash memory.
2. If the same data name exists (i.e. the currently selected second data name is recorded in the NOR flash memory), the read module may compare the verification code (e.g. MD5 code) corresponding to the currently selected second data name with the verification code corresponding to the same data name recorded in the NOR flash memory:
(1) If the check codes are different, it is indicated that the second sub-image data corresponding to the currently selected second data name does not exist in the NOR flash memory, the second sub-image data corresponding to the currently selected second data name is directly sent to the write module (namely, it is determined that there is different second sub-image data), and the write module writes the second sub-image data into the NAND flash memory.
Optionally, when the same data name or different check codes do not exist, the read module may add an identification bit to the second sub-mirror data corresponding to the currently selected second data name until all the second sub-mirror data are compared, then send all the second sub-mirror data with the identification bit to the write module, and the write module writes all the second sub-mirror data with the identification bit into the NAND flash memory.
Alternatively, the read module may only add the identification bits to the second sub-mirror data with the same data name and the same verification code until all the second sub-mirror data are compared, and then send all the second sub-mirror data without the identification bits to the write module, and the write module writes all the second sub-mirror data without the identification bits into the NAND flash memory.
Alternatively, the reading module may add an identification bit with an identification number of 1 to second sub-mirror image data which has no same data name and has the same data name but different check codes, and add an identification bit with an identification number of 0 to second sub-mirror image data which has the same data name and same verification code until all second sub-mirror image data are compared, and then send all second sub-mirror image data with an identification number of 1 to the writing module, and the writing module writes all second sub-mirror image data with an identification number of 1 into the NAND flash memory.
(2) If the check codes are the same, the NOR flash memory is indicated to store the second sub-mirror image data corresponding to the currently selected second data name.
Optionally, the reading module may directly discard the currently selected second sub-mirror data, or no longer send the second sub-mirror data to the writing module, and a specific processing manner is not limited in this embodiment of the present application.
In the embodiment of the application, the reading module sends the sub-mirror image data needing to be written into the NAND flash memory to the writing module according to the comparison result, the writing module writes the sub-mirror image data into the NAND flash memory, and at the moment, the data name and the verification code corresponding to the sub-mirror image data to be written into the NAND flash memory can be written into the NAND flash memory together.
And step six, the reading module updates the mirror image data name and the check code recorded in the NOR flash memory to complete data burning.
Alternatively, the read module may delete all the data name and the check code recorded in the NOR flash memory last time, and re-record the data name and the check code (i.e., the information of the plurality of second sub-mirror data included in the second mirror data) included in the current flash memory (the NOR flash memory and the NAND flash memory).
Optionally, the reading module may directly delete information that is recorded in the NOR flash memory last time and is the same as the currently selected second data name and has a different check code in the process of comparing the data name with the check code, and re-record the currently selected second data name and the check code corresponding to the second data name. If the currently selected second data name is not recorded in the NOR flash memory, the currently selected second data name and the check code corresponding to the second data name are also required to be recorded.
Optionally, the read module may backup a data name and a corresponding verification code, which are recorded in the NOR flash memory last time and are the same as the currently selected second data name, and place the backup in the backup area, and record the currently selected second data name and the corresponding verification code. If the currently selected second data name is not recorded in the NOR flash memory, the currently selected second data name and the check code corresponding to the second data name also need to be recorded.
In the embodiment of the application, the data to be burned transmitted by the burning device can be quickly read through the reading module corresponding to the NOR flash memory in the terminal device, the second mirror image data and the first mirror image data are compared in the reading module, and the sub-mirror image data different from the first mirror image data in the second mirror image data is obtained, so that the different sub-mirror image data can be written into the NAND flash memory through the writing module, and all the data to be burned transmitted by the burning device do not need to be written into the NAND flash memory. The method can shorten the time of data burning and improve the efficiency of data burning.
It can be understood that if the second mirror image data is the 1.2 version of the software a, after the sixth step, the second burning is completed, at this time, the version of the software a is updated, and when the large screen runs the software a again, the software a with the version of 1.2 is obtained.
Step seven, the PC 310 transmits third mirror image data to be burned to the large screen 320 through the network cable, and the reading module in the large screen 320 acquires the third mirror image data, where the third mirror image data includes a plurality of third sub-mirror image data (data blocks) and information of the third sub-mirror image data (information of the data blocks), and the information of the third sub-mirror image data includes a data name and a check code of the third sub-mirror image data.
The third mirror image data can be understood as data to be burned for the second time or later.
It should be understood that the third mirror data may be identical to the second mirror data, or the second mirror data may be included in the third mirror data, or a part of the third mirror data may be identical to the second mirror data (e.g., mirror data with different data names, or mirror data with the same data name and different check codes).
And step eight, the reading module judges whether the NOR flash memory is empty. The specific comparison process in step eight may refer to the related description in step five, and is not described herein again.
It should be understood that when the third mirror data is burned, the NAND flash memory has data written therein at this time. And in the process of comparing the data name recorded in the NOR flash memory with the data name in the third mirror image data, if part of or all of the data name in the third mirror image data is not recorded in the NOR flash memory, the reading module writes the third sub-mirror image data corresponding to the part of or all of the data name into the NAND flash memory.
It should also be understood that if a part of data names or all data names in the third mirror data are recorded in the NOR flash memory, but the check codes are different, the third sub-mirror data corresponding to the part of data names or all data names are written into the NAND flash memory, but at this time, mirror data with the same data name as that of the third sub-mirror data to be written exists in the NAND flash memory, and then the third sub-mirror data to be written may directly overwrite mirror data with the same data name in the NAND flash memory. It can be understood that, this process requires that the NAND flash memory stores the data name corresponding to the sub-mirror data that was written last time, that is, the NAND flash memory needs to be written with the data name corresponding to the sub-mirror data to be written currently.
Exemplarily, before the mirror image data is burned for the third time, the NAND flash memory stores the mirror image data with the data name of vendor.img, and if the mirror image data burned for the third time still includes the mirror image data with the data name of vendor.img but is inconsistent with the verification code stored in the NAND flash memory with the data name of vendor.img, at this time, the mirror image data with the data name of vendor.img in the mirror image data burned for the third time needs to be written into the NAND flash memory, and the mirror image data with the data name of vendor.img stored before is covered (i.e., the mirror image data is erased first and written in).
And step nine, the reading module updates the mirror image data name and the check code recorded in the NOR flash memory to complete data burning. For a specific updating process, reference may be made to the related description of step six above, which is not described herein again.
It can be understood that, if the third mirror image data is the 1.3 version of the software a, after the ninth step, the third burning is completed, at this time, the version of the software a is updated, and when the large screen runs the software a again, the software a with the version of 1.3 is obtained.
In the embodiment of the application, in the process of data interaction between the read module and the write module, data transmission can be performed through a transmission channel established between the read module and the write module.
Illustratively, the transmission channel between the read module and the write module may be established through a socket communication mechanism. According to the principle of socket communication, two different IP addresses are needed firstly, namely the IP addresses of the reading module and the writing module are different.
In the embodiment of the application, when the burning device is connected with the reading module through a network cable, the reading module can determine the IP address of the burning device as the first IP address; when the large screen is powered on, the writing module can obtain a second IP address from the WIFI module through an interface (e.g., getIPaddres ()).
Illustratively, the process of the write module obtaining the second IP address is as follows:
adding the following judgment in the WIFI module:
if (with net wire)
{ WIFI IP takes effect in write module };
namely, under the condition that the large screen is connected with the network cable, when the large screen is connected with the WIFI, the default is the WIFI connected with the NAND flash memory, and therefore, the IP address of the WIFI module can be determined as the IP address of the writing module.
After the reading module and the writing module respectively obtain the IP addresses, data interaction between the two modules may be implemented by setting a socket and using a Transmission Control Protocol (TCP) (i.e., three-way handshake). It should be understood that data interaction between the read module and the write module may use the TCP protocol to encapsulate and send data to the peer.
Fig. 4 is a schematic flowchart of a burning method according to an embodiment of the present disclosure. The burning method may be executed by the terminal device shown in fig. 2, and as shown in fig. 4, the method 400 may include:
s401, the reading module obtains data to be burned.
S402, the reading module determines whether the NOR flash memory is empty.
S403, in case the NOR flash memory is not empty, the read module determines whether the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are the same.
S404, under the condition that the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the read module sends all or part of the data to be burned to the write module.
S405, the writing module writes all or part of the received data to be burned into the NAND flash memory.
It should be understood that the specific processes of the method 400 can refer to the related descriptions of the read module and the write module in fig. 3, which are not described herein again.
The embodiments of the present application have the same effects as those of the embodiments described above, and reference may be made to the description of the embodiments described above.
Fig. 5 illustrates a burning method 500 according to an embodiment of the present disclosure. The burning method 500 may be executed by the terminal device shown in fig. 2, and as shown in fig. 5, the method 500 may include the following steps:
s501, the terminal device obtains data to be burned.
The data to be burned comprises a plurality of data blocks and information of the data blocks.
S502, the terminal device determines whether the NOR flash memory is empty.
In the case where the NOR flash memory is not empty, the terminal device determines whether the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are the same S503.
S504, under the condition that the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the terminal equipment writes all or part of the data to be burned into the NAND flash memory.
As an alternative embodiment, in a case that information of a plurality of data blocks is different from information of data blocks recorded in the NOR flash memory, the writing of all or part of data to be burned into the NAND flash memory by the terminal device includes: and the terminal equipment writes the data to be burnt corresponding to the information of at least one data block into the NAND flash memory.
As an alternative embodiment, the information of the data block includes a data name and a verification code; the terminal device determining whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same, including: the terminal device determines whether a plurality of data names in the information of the plurality of data blocks are the same as data names in the information of the data blocks recorded in the NOR flash memory; the information of at least one data block in the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, and the terminal equipment writes the data to be burned corresponding to the information of the at least one data block into the NAND flash memory, and the method comprises the following steps: and the terminal equipment writes the data to be burned corresponding to the at least one first data name into the NAND flash memory.
As an optional embodiment, the method further comprises: the terminal equipment determines whether a first verification code is the same as a second verification code or not, wherein the first verification code is a verification code corresponding to at least one second data name, and the second verification code is a verification code corresponding to the data name which is recorded in the NOR flash memory and is the same as the at least one second data name; and under the condition that the first verification code is different from the second verification code, the terminal equipment writes the data to be burned corresponding to at least one second data name into the NAND flash memory.
As an optional embodiment, after the terminal device writes all or part of the data to be burned into the NAND flash memory, the method further includes: the information of the data blocks recorded in the NOR flash memory is updated. Information for updating a data block recorded in a NOR flash memory, including: and replacing the information of the data blocks recorded in the NOR flash memory with the information of a plurality of data blocks included in the data to be burned.
As an alternative embodiment, updating the data block information recorded in the NOR flash memory includes: adding at least one second data name and a check code corresponding to the at least one second data name in the NOR flash memory; and/or replacing a data name and a verification code which are different from the verification code corresponding to the at least one third data name in the NOR flash memory with a check code corresponding to the at least one third data name and the at least one third data name.
As an optional embodiment, the method further comprises: under the condition that the information of the plurality of data blocks is the same as the information of the data blocks recorded in the NOR flash memory, the terminal equipment does not write the data to be burned into the NAND flash memory.
As an optional embodiment, the method further comprises: in the case where the NOR flash memory is empty, the terminal device stores a plurality of data blocks in the NOR flash memory; the NOR flash memory records data block information of data to be burned.
As an optional embodiment, the method further comprises: and under the condition that the NOR flash memory is empty, the terminal equipment stores the data to be burned in the NOR flash memory.
The embodiments of the present application have the same effects as those of the embodiments described above, and reference may be made to the description of the embodiments described above.
It should be noted that the modules shown in fig. 3 or fig. 4 may be one or more integrated circuits configured to implement the above methods, for example: one or more Application Specific Integrated Circuits (ASICs), or one or more microprocessors (DSPs), or one or more Field Programmable Gate Arrays (FPGAs), etc. For another example, when some of the above modules are implemented in the form of a processing element scheduler code, the processing element may be a general-purpose processor, such as a Central Processing Unit (CPU) or other processor that can call program code. As another example, these modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, it may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. The procedures or functions according to the embodiments of the present application are all or partially generated when the computer program instructions are loaded and executed on a computer. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid State Disk (SSD)), among others.
The term "plurality" herein means two or more. The term "and/or" herein is merely an association describing an associated object, meaning that three relationships may exist, e.g., a and/or B, may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the character "/" herein generally indicates that the former and latter related objects are in an "or" relationship; in the formula, the character "/" indicates that the preceding and following related objects are in a relationship of "division".
It is to be understood that the various numerical references referred to in the embodiments of the present application are merely for convenience of description and distinction and are not intended to limit the scope of the embodiments of the present application. In the embodiment of the present application, the sequence numbers of the above-mentioned processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiment of the present application.
The term "plurality" herein means two or more. The term "and/or" herein is merely an association describing an associated object, meaning that three relationships may exist, e.g., a and/or B, may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the character "/" herein generally indicates that the former and latter related objects are in an "or" relationship; in the formula, the character "/" indicates that the preceding and following related objects are in a relationship of "division". The terms "first" and "second" are used for distinguishing and describing, and do not limit the implementation process of the embodiments of the present application in any way.
It is to be understood that the various numerical references referred to in the embodiments of the present application are merely for descriptive convenience and are not intended to limit the scope of the embodiments of the present application.
It should be understood that, in the embodiment of the present application, the sequence numbers of the above-mentioned processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiment of the present application.

Claims (14)

1. A burning method is applied to a terminal device comprising a NAND flash memory and a NOR flash memory, wherein the terminal device comprises a reading module and a writing module, and the method comprises the following steps:
the reading module acquires data to be burned, wherein the data to be burned comprises a plurality of data blocks and information of the data blocks, and the information of the data blocks comprises data names and verification codes;
the read module determines whether the NOR flash memory is empty;
in a case where the NOR flash memory is not empty, the read module determines whether information of the plurality of data blocks and information of the data blocks recorded in the NOR flash memory are the same;
under the condition that the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the read module sends all or part of the data to be burned to the write module;
and the writing module writes all or part of the received data to be burned into the NAND flash memory.
2. The method as claimed in claim 1, wherein in the case that the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are not the same, the reading module sends all or part of the data to be burned to the writing module, and the writing module writes all or part of the received data to be burned to the NAND flash memory, including:
the information of at least one data block in the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, and the read module sends the data to be burned corresponding to the information of the at least one data block to the write module;
and the writing module writes the received data to be burned corresponding to the information of the at least one data block into the NAND flash memory.
3. The method of claim 2, wherein the reading module determining whether the information of the plurality of data blocks and the information of the data blocks recorded in the NOR flash memory are the same comprises:
the read module determines whether a plurality of data names in the information of the plurality of data blocks are the same as data names in the information of the data blocks recorded in the NOR flash memory;
the information of at least one data block in the information of the data blocks is different from the information of the data blocks recorded in the NOR flash memory, the read module sends the data to be burned corresponding to the information of the at least one data block to the write module, and the write module writes the received data to be burned corresponding to the information of the at least one data block into the NAND flash memory, including:
the information of the at least one data block has at least one first data name different from the data name recorded in the NOR flash memory, and the read module sends the data to be burned corresponding to the at least one first data name to the write module;
and the writing module writes the received data to be burned corresponding to the at least one first data name into the NAND flash memory.
4. The method of claim 3, further comprising:
the read module determines whether a first verification code is the same as a second verification code, wherein the first verification code is a verification code corresponding to the at least one second data name, and the second verification code is a verification code corresponding to the data name which is recorded in the NOR flash memory and is the same as the at least one second data name;
under the condition that the first verification code is different from the second verification code, the reading module sends the data to be burned corresponding to the at least one second data name to the writing module;
and the writing module writes the received data to be burned corresponding to the at least one second data name into the NAND flash memory.
5. The method according to claim 4, wherein after the writing module writes the data to be burned corresponding to the received information of the at least one data block into the NAND flash memory, the method further comprises:
the reading module updates the information of the data block recorded in the NOR flash memory.
6. The method of claim 5, wherein the reading module updates information of the data blocks recorded in the NOR flash memory, comprising:
and the reading module replaces the information of the data blocks recorded in the NOR flash memory with the information of a plurality of data blocks included in the data to be burned.
7. The method of claim 5, wherein the reading module updates the data block information recorded in the NOR flash memory, and comprises:
the reading module adds the at least one second data name and a check code corresponding to the at least one second data name in the NOR flash memory; and/or the presence of a gas in the gas,
and the reading module replaces the data name and the verification code which are different from the verification code corresponding to the at least one third data name in the NOR flash memory with the check code corresponding to the at least one third data name and the at least one third data name.
8. The method of claim 1, further comprising:
and under the condition that the information of the plurality of data blocks is the same as the information of the data blocks recorded in the NOR flash memory, the read module does not write the data to be burned into the NAND flash memory.
9. The method according to any one of claims 1 to 8, further comprising:
in the case where the NOR flash memory is empty, the read module stores the plurality of data blocks in the NOR flash memory;
and the reading module records the data block information of the data to be burned in the NOR flash memory.
10. The method according to any one of claims 1 to 8, further comprising:
and under the condition that the NOR flash memory is empty, the reading module stores the data to be burned in the NOR flash memory.
11. The method according to any one of claims 1 to 8, wherein before the read module sends all or part of the data to be burned to the write module, the method further comprises:
and establishing a transmission channel between the reading module and the writing module, wherein the transmission channel is used for data interaction between the reading module and the writing module.
12. The method of claim 11, wherein the terminal device further comprises a WIFI module, and wherein establishing a transmission channel between the read module and the write module comprises:
the reading module acquires a first IP address, wherein the first IP address is an IP address of burning equipment, and the burning equipment is used for providing the data to be burned;
when the terminal equipment is powered on, the writing module obtains a second IP address from the WIFI module, wherein the second IP address is the IP address of the terminal equipment;
and the data interaction between the reading module and the writing module is realized by setting a socket and a Transmission Control Protocol (TCP).
13. A terminal device, comprising: a processor coupled to a memory, the memory storing computer-executable instructions, the processor executing the computer-executable instructions stored by the memory, the processor performing the method of any of claims 1-12.
14. A computer-readable storage medium for storing a computer program comprising instructions for implementing the method of any one of claims 1 to 12.
CN202110963738.8A 2021-08-20 2021-08-20 Burning method and terminal equipment Active CN113849194B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110963738.8A CN113849194B (en) 2021-08-20 2021-08-20 Burning method and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110963738.8A CN113849194B (en) 2021-08-20 2021-08-20 Burning method and terminal equipment

Publications (2)

Publication Number Publication Date
CN113849194A CN113849194A (en) 2021-12-28
CN113849194B true CN113849194B (en) 2022-10-14

Family

ID=78975903

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110963738.8A Active CN113849194B (en) 2021-08-20 2021-08-20 Burning method and terminal equipment

Country Status (1)

Country Link
CN (1) CN113849194B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117111717A (en) * 2023-10-24 2023-11-24 荣耀终端有限公司 Flash memory control method, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103425602A (en) * 2013-08-15 2013-12-04 深圳市江波龙电子有限公司 Data reading and writing method and device for flash memory equipment and host system
CN108363579A (en) * 2018-02-08 2018-08-03 深圳创维-Rgb电子有限公司 Data burning method, device, equipment and storage medium
CN108733324A (en) * 2018-05-25 2018-11-02 郑州云海信息技术有限公司 A kind of data read-write method of solid state disk, device, equipment and storage medium
CN111966369A (en) * 2020-10-20 2020-11-20 延锋伟世通电子科技(南京)有限公司 Method for manufacturing and verifying off-line burning mirror image of NAND memory

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104317622B (en) * 2014-10-30 2018-05-29 深圳市捷顺科技实业股份有限公司 A kind of embedded device burning program processing method and system
CN106557571A (en) * 2016-11-23 2017-04-05 福建亿榕信息技术有限公司 A kind of data duplicate removal method and device based on K V storage engines
CN109117151A (en) * 2018-07-18 2019-01-01 珠海市杰理科技股份有限公司 Fever writes and program burn writing method, apparatus, computer equipment and storage medium
US11709623B2 (en) * 2018-08-03 2023-07-25 Sk Hynix Nand Product Solutions Corp. NAND-based storage device with partitioned nonvolatile write buffer
CN109656584A (en) * 2019-02-15 2019-04-19 京信通信系统(中国)有限公司 A kind of method for burn-recording and device of program
CN110399143A (en) * 2019-07-29 2019-11-01 Oppo广东移动通信有限公司 Brush machine method, apparatus, computer storage medium and the system of terminal device
CN111176667B (en) * 2019-12-30 2023-01-24 Tcl华星光电技术有限公司 Data burning method and data burning device
CN112148220B (en) * 2020-09-17 2024-03-19 合肥大唐存储科技有限公司 Method, device, computer storage medium and terminal for realizing data processing

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103425602A (en) * 2013-08-15 2013-12-04 深圳市江波龙电子有限公司 Data reading and writing method and device for flash memory equipment and host system
CN108363579A (en) * 2018-02-08 2018-08-03 深圳创维-Rgb电子有限公司 Data burning method, device, equipment and storage medium
CN108733324A (en) * 2018-05-25 2018-11-02 郑州云海信息技术有限公司 A kind of data read-write method of solid state disk, device, equipment and storage medium
CN111966369A (en) * 2020-10-20 2020-11-20 延锋伟世通电子科技(南京)有限公司 Method for manufacturing and verifying off-line burning mirror image of NAND memory

Also Published As

Publication number Publication date
CN113849194A (en) 2021-12-28

Similar Documents

Publication Publication Date Title
CN113704014B (en) Log acquisition system, method, electronic device and storage medium
CN111357014B (en) AI model development method and device
CN115050358A (en) Voice control command generation method and terminal
CN113704205A (en) Log storage method, chip, electronic device and readable storage medium
CN114996168A (en) Multi-device cooperative test method, test device and readable storage medium
CN113849194B (en) Burning method and terminal equipment
CN113438643B (en) Terminal capability reporting system, method, electronic equipment and storage medium
CN116795753A (en) Audio data transmission processing method and electronic equipment
CN117130541A (en) Storage space configuration method and related equipment
CN116382810A (en) META mode starting method, electronic equipment and storage medium
CN113901485B (en) Application program loading method, electronic device and storage medium
CN114443109B (en) Patch repair method, electronic device and storage medium
CN113485969B (en) Storage fragmentation method and device, terminal and computer storage medium
CN116828100A (en) Bluetooth audio playing method, electronic equipment and storage medium
CN114489471A (en) Input and output processing method and electronic equipment
CN117130959B (en) Bus control method, electronic device and computer storage medium
CN115993592B (en) Bluetooth ranging method, electronic equipment and storage medium
CN115619628B (en) Image processing method and terminal equipment
CN113704209B (en) Data sharing method, electronic device and storage medium
CN116719699B (en) Bus monitoring and control method, electronic device, chip and storage medium
CN115482143B (en) Image data calling method and system for application, electronic equipment and storage medium
CN116993619B (en) Image processing method and related equipment
CN116541426B (en) Data storage method and data searching method of semiconductor device and electronic equipment
WO2024045841A1 (en) Storage method and apparatus, and electronic device
CN116486390A (en) Searching method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant