Rubber Ducky scripts use a simple syntax to simulate keyboard input.
Below are some common commands you can use in your scripts.
REM:
CommentDELAY:
Pause for a specified number of millisecondsSTRING:
Type a string of charactersENTER:
Press the Enter keyMENU:
Press the Windows key or Command key on MacALT:
Hold the Alt keyCONTROL or CTRL:
Hold the Control keySHIFT:
Hold the Shift keyGUI:
Hold the Windows key or Command key on Mac
WINDOWS:
Hold the Windows key
COMMAND:
Hold the Command key
GUI h
: Simulate pressing the Home button.GUI SPACE
: Open Spotlight Search.STRING [text]
: Type the specified text.ENTER
: Simulate pressing the Enter key.DOWN ARROW
: Navigate down in menus or lists.UP ARROW
: Navigate up in menus or lists.RIGHT ARROW
: Navigate right in menus or lists.LEFT ARROW
: Navigate left in menus or lists.SPACE
: Simulate pressing the Space key.GUI t
: Open a new tab in Safari.GUI l
: Focus on the address bar in Safari.GUI SHIFT 4
: Take a screenshot.BACKSPACE
: Simulate pressing the Backspace key.TAB
: Move focus to the next control element.GUI n
: Open a new message or email.GUI v
: Paste from clipboard.GUI SHIFT d
: Send an email in the Mail app.
These commands enable functionalities from basic navigation and text entry to specific actions like taking screenshots or sending emails.
To use these commands, ensure Full Keyboard Access
is enabled on your iOS device.
CTRL-ALT:
Hold the Control and Alt keysCTRL-SHIFT:
Hold the Control and Shift keysCTRL-ALT-SHIFT:
Hold the Control, Alt, and Shift keys
CTRL ALT DEL:
Press Control, Alt, and Delete keys togetherCTRL SHIFT ESC:
Press Control, Shift, and Escape keys togetherCTRL ALT T:
Open terminal in Linux