parent
d36c79ccd9
commit
8d064986ac
28
boot.py
28
boot.py
|
@ -1,16 +1,16 @@
|
|||
# from board import *
|
||||
# import digitalio
|
||||
# import storage
|
||||
from board import *
|
||||
import digitalio
|
||||
import storage
|
||||
|
||||
# noStorageStatus = False
|
||||
# noStoragePin = digitalio.DigitalInOut(GP0)
|
||||
# noStoragePin.switch_to_input(pull=digitalio.Pull.UP)
|
||||
# noStorageStatus = not noStoragePin.value
|
||||
noStorageStatus = False
|
||||
noStoragePin = digitalio.DigitalInOut(GP15)
|
||||
noStoragePin.switch_to_input(pull=digitalio.Pull.UP)
|
||||
noStorageStatus = not noStoragePin.value
|
||||
|
||||
# if(noStorageStatus == False):
|
||||
# # don't show USB drive to host PC
|
||||
# storage.disable_usb_drive()
|
||||
# print("Disabling USB drive")
|
||||
# else:
|
||||
# # normal boot
|
||||
# print("USB drive enabled")
|
||||
if(noStorageStatus == False):
|
||||
# don't show USB drive to host PC
|
||||
storage.disable_usb_drive()
|
||||
print("Disabling USB drive")
|
||||
else:
|
||||
# normal boot
|
||||
print("USB drive enabled")
|
||||
|
|
Loading…
Reference in New Issue