LittleFS on Flash (w25q128) | STM32 Tutorial #94
504 views on YouTube
We continue an earlier video covering the W25Q128 flash by putting a proper file system (LittlefS) on it. We will be using a Winbond W25Q128 flash chip on the CurrentMakers Streamline.
Buy Streamline here: https://currentmakers.com/products/streamline/
Streamline Storage Flash on STM32World: https://stm32world.com/wiki/Streamline_Storage_Flash
Previous video on W25Q128: https://www.youtube.com/watch?v=9BRciMkJ0Fc
Earlier video on SPI Flash: https://www.youtube.com/watch?v=7Lacq—U9c
LittleFS on 24M01 EEPROM: https://www.youtube.com/watch?v=iAjY9P2lb5s
STM32World wiki page: https://stm32world.com/wiki/STM32_W25Qxx_LittleFS
The library is available at Github: https://github.com/lbthomsen/stm32-w25qxx
STM32World wiki page: https://stm32world.com/wiki/STM32_W25Qxx
STM32World library page: https://stm32world.com/wiki/STM32_W25Qxx
STM32World Black Pill page: https://stm32world.com/wiki/Black_Pill
#STM32 #GettingStarted #Tutorial #STM32CubeIDE #STM32CubeMX #SPI #Flash #W25Qxx #W25Q64 #W25Q128 #Winbond #STM32World #CurrentMakers #Streamline #LittleFS
00:00 Intro
00:36 Welcome
01:08 Earlier videos using FatFS on SD Card and W25Q128
02:23 Why FatFS is NOT suitable for flash chips – the NEED for wear leveling
04:00 The wear leveling options – SPIFS and LittleFS
06:06 Introducing the stm32-w25qxx library
06:55 Adding LittleFS as a sub module
07:24 Recap of how the stm32-w25qxx library is working
10:29 Running the earlier example without LittleFS
11:02 Adding LittleFS to previous example – the cloned project
13:28 Creating the interface layer between littlefs and w25q128
14:18 The source of w25qxx_littlefs.c – four functions
16:02 The littlefs_read function
17:11 The littlefs_write function
17:41 The littlefs_erase
17:51 The littlefs_sync – just waiting for the flash to finish
18:50 The w25qxxx handler
19:21 The littlefs automatic configuration from w25qxx
22:54 Using littlefs in main.c – the include defines and global variables
23:41 Initializing littlefs
24:21 Maintaining a boot counter
24:46 Keeping track of total uptime
25:10 A speed test – creating a 1 MB file
25:57 Building and flashing – working
28:12 Final thoughts and outtro
Corrections:
00:01 This is the first video ever where I used AI to generate the thumb. Of course AI got the number of pins wrong. Hilarious.
06:06 It is actually erase cycles not write cycles
22:07 Pretty sloppy to reformat on mount error – that should be done more careful. Code in repository have been updated