Skip to content

Turn your Raspberry Pi Zero W into a USB keyboard with remote access

Notifications You must be signed in to change notification settings

n0rc/rpi-remote-keyboard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Raspberry Pi Remote Keyboard

This is some Bash and Python code to setup and run a Raspberry Pi Zero W as a USB HID gadget, e.g. to use it as an USB keyboard with remote access via wifi.

The Pi is back-powered over the USB port of the connected computer and doesn't need an additional power supply.

Setup

  1. Connect your Pi to your computer using the Pi's Micro-USB data port
  2. Enable required device tree overlay and modules:
> echo "dtoverlay=dwc2" | sudo tee -a /boot/config.txt
> echo "dwc2" | sudo tee -a /etc/modules
  1. Put /your/absolute/path/to/gadgetsetup.sh into /etc/rc.local to run the script at boot
  2. Reboot the Pi

Usage

> sudo ./sendkeys.py "string"    # send "string" to connected computer, simulating keyboard input
> sudo ./sendkeys.py -l de -p    # send something using german keyboard layout and password mode (no echo)
> sudo ./sendkeys.py -h          # show help

Credits

Specs

About

Turn your Raspberry Pi Zero W into a USB keyboard with remote access

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published