Skip to content

Commit 7ec2793

Browse files
committed
rp2/modules: Fix FatFS boot script.
This change helps detect if the filesystem is invalid and reformat the FAT if needed. Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
1 parent 09d070a commit 7ec2793

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ports/rp2/modules/_boot_fat.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@
66
bdev = rp2.Flash()
77
try:
88
fs = vfs.VfsFat(bdev)
9+
vfs.mount(fs, "/")
910
except:
1011
vfs.VfsFat.mkfs(bdev)
1112
fs = vfs.VfsFat(bdev)
12-
vfs.mount(fs, "/")
13+
vfs.mount(fs, "/")
1314

1415
del vfs, bdev, fs

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy