Font Size: a A A

Design Of Mass Storage Based On STM32 And USB

Posted on:2021-05-03Degree:MasterType:Thesis
Country:ChinaCandidate:B Y PangFull Text:PDF
GTID:2428330602465406Subject:Engineering
Abstract/Summary:PDF Full Text Request
High-speed large-capacity storage equipment is an indispensable part of the data collection system.Its main role is to store and effectively manage the collected data in real time.In the modern military,missiles occupy an important strategic position.In the process of missile development,various flight data are very important for scientific researchers.This poses a difficult problem that has always puzzled the R & D personnel.The large amount of data obtained is stored in the memory at high speed and accurately.Starting from this purpose,this design mainly develops a high-speed memory for missile flight data acquisition system to achieve high-speed and effective storage of missile flight data.This design chooses STM32 as the main control chip and NAND FLASH as the storage medium.First,receive and buffer the 8-bit FIFO data of the acquisition system through the asynchronous static memory on STM32.Then store the cached data in NAND FLASH.Finally,read,write and delete the data in NAND FLASH through the USB interface,thus completing the design of the entire system.Problems that this design focuses on:The first question is how to store the data accurately in NAND FLASH,because in the factory and use process,invalid blocks will be generated,so that the data is lost.We implement it in three steps.First,all blocks are scanned using ECC check,and the bad blocks obtained are marked.Then create a bad block mapping table,the main purpose of the bad block mapping table is to make the physical address of the NAND FLASH and the logical address of the file system later map to each other.Finally,a reserved area is established,and bad block management is achieved by leaving a certain amount of valid blocks in the reserved area instead of bad blocks,and wear leveling is also achieved by equally dividing the number of erasures when using the reserved area for data replication.The second problem is the data loss caused by system power failure.This is because when the file system writes data,it needs to close the file after writing the file to complete the data writing operation,otherwise the data will be lost.The environment where this design is located may be powered down at any time,and the file cannot be accurately closed before the system is powered down.Therefore,it is necessary to design power-down protection.The method used in this design is to set the method of automatic saving in stages according to the time when writing the file,so that even if the power is lost,the data at the last moment can be completely saved to prevent data loss.
Keywords/Search Tags:NAND FLASH, STM32, file system, USB
PDF Full Text Request
Related items