mirror of
https://github.com/dbisu/pico-ducky.git
synced 2025-12-06 02:41:45 +00:00
Added USB enable-disable mode (#25)
This commit is contained in:
14
README.md
14
README.md
@@ -43,6 +43,20 @@ The easiest way to so is by using a jumper wire between those pins as seen bello
|
||||
|
||||

|
||||
|
||||
### USB enable/disable mode
|
||||
|
||||
If you need the pico-ducky to not show up as a USB mass storage device for stealth, follow these instructions.
|
||||
Enter setup mode.
|
||||
Copy boot.py to the root of the pico-ducky.
|
||||
Copy your payload script to the pico-ducky.
|
||||
Disconnect the pico from your host PC.
|
||||
Connect a jumper wire between pin 18 and pin 20.
|
||||
This will prevent the pico-ducky from showing up as a USB drive when plugged into the target computer.
|
||||
Remove the jumper and reconnect to your PC to reprogram.
|
||||
The default mode is USB mass storage enabled.
|
||||
|
||||

|
||||
|
||||
## Useful links and resources
|
||||
|
||||
### Docs
|
||||
|
||||
16
boot.py
Normal file
16
boot.py
Normal file
@@ -0,0 +1,16 @@
|
||||
from board import *
|
||||
import digitalio
|
||||
import storage
|
||||
|
||||
noStorageStatus = False
|
||||
noStoragePin = digitalio.DigitalInOut(GP15)
|
||||
noStoragePin.switch_to_input(pull=digitalio.Pull.UP)
|
||||
noStorageStatus = not noStoragePin.value
|
||||
|
||||
if(noStorageStatus == True):
|
||||
# don't show USB drive to host PC
|
||||
storage.disable_usb_drive()
|
||||
print("Disabling USB drive")
|
||||
else:
|
||||
# normal boot
|
||||
print("USB drive enabled")
|
||||
BIN
images/usb-boot-mode.png
Normal file
BIN
images/usb-boot-mode.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.1 MiB |
Reference in New Issue
Block a user