This web page was created programmatically, to learn the article in its unique location you may go to the hyperlink bellow:
https://www.cnx-software.com/2026/01/22/raspberry-pi-os-adds-easier-usb-gadget-mode-support/
and if you wish to take away this text from our website please contact us
Raspberry Pi OS Trixie now helps USB gadget mode out of the field, permitting customers to hook up with their Raspberry Pi boards over IP via USB with out the necessity for a router.
My first expertise with USB gadget performance was after I reviewed the Beaglebone Green Wireless SBC in 2016, however for some motive, official help for the Raspberry Pi ecosystem took rather a lot longer, and it was solely formally carried out in Raspberry Pi OS Trixie photographs dated 20.10.2025 and later via the rpi-usb-gadget package deal.

It’s been attainable to make use of the USB gadget mode on Raspberry Pi OS for some time, however it was somewhat convoluted with outdated scripts, guide configuration steps, and platform-specific directions. The new rpi-usb-gadget package deal streamlines the method and makes issues a lot simpler:
- The Raspberry Pi SBC will current itself as a USB Ethernet system when related to a PC
- Users can SSH instantly utilizing the hostname set in Raspberry Pi Imager with out having to configure Wi-Fi or Ethernet
- If your PC has an energetic web connection and Internet Connection Sharing (ICS) is enabled, the Raspberry Pi will mechanically obtain web entry via the USB cable
- A light-weight background service runs mechanically change between standalone mode and ICS-backed networking
So it’s like USB tethering in your telephone, however for a Raspberry Pi. It works on Windows, macOS, and Linux.
How nicely it really works will depend on your particular Raspberry Pi SBC mannequin, because it have to be related to a USB port that helps OTG (system mode).
| Raspberry Pi mannequin | USB port to make use of |
|---|---|
| Raspberry Pi Zero, Zero W, Zero 2 W | The micro USB port closest to HDMI — not ‘PWR IN’ |
| Raspberry Pi 4, 5, 500, 500+ | The USB-C port instantly on the board |
| Compute Module 5 | The USB-C port on the Raspberry Pi CM5 IO Board |
| Compute Module 4 | Requires further guide setup and isn’t auto-configured |
Once gadget mode is enabled, the OTG port will not work as a daily USB port and can solely perform as a USB Ethernet port with energy enter. In different phrases, meaning keyboards, storage units, or different peripherals gained’t be acknowledged.

USB gadget mode could be enabled instantly from the Raspberry Pi Imager 2.x while you flash the picture to a microSD card. On an current Trixie set up, run the next instructions:
|
sudo apt replace sudo apt set up rpi–usb–gadget sudo rpi–usb–gadget on sudo reboot |
The implementation is open-source, and also you’ll discover the code on GitHub.




Jean-Luc began CNX Software in 2010 as a part-time endeavor, earlier than quitting his job as a software program engineering supervisor, and beginning to write each day information, and opinions full time later in 2011.
Support CNX Software! Donate by way of cryptocurrencies, become a Patron on Patreon, or buy items on Amazon or Aliexpress. We additionally use affiliate hyperlinks in articles to earn commissions in the event you make a purchase order after clicking on these hyperlinks.
This web page was created programmatically, to learn the article in its unique location you may go to the hyperlink bellow:
https://www.cnx-software.com/2026/01/22/raspberry-pi-os-adds-easier-usb-gadget-mode-support/
and if you wish to take away this text from our website please contact us

