Skip to content

Commit 4df083a

Browse files
committed
Only make CIRCUITPY readonly with USB
CIRCUITPY will be writable from CP on all non-USB boards now. This includes micro:bit v2 and C3 boards. It should allow it to work with serial file loading programs. Fixes #5901
1 parent 9a353a4 commit 4df083a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -838,7 +838,7 @@ int __attribute__((used)) main(void) {
838838
// By default our internal flash is readonly to local python code and
839839
// writable over USB. Set it here so that boot.py can change it.
840840
filesystem_set_internal_concurrent_write_protection(true);
841-
filesystem_set_internal_writable_by_usb(true);
841+
filesystem_set_internal_writable_by_usb(CIRCUITPY_USB == 1);
842842

843843
run_boot_py(safe_mode);
844844

0 commit comments

Comments
 (0)