Hello everyone,
There is a Raspberry Pi 5B, and I want to plug in a mouse or keyboard into the Raspberry Pi and then control my PC via Bluetooth or wireless connection. Many of the cases in the community are based on the ZERO model. Now I want to know if the 5B can accomplish this task, and how should I go about doing it?
If remote desktop/VNC isn't what you want, the Pi5 can work as a USB gadget in the same way that a 4B can. (via its USB C port.) Power is likely to be more of an issue though.
The software side to get the Pi5 working as a USB gadget is the same as on other models (remember that on Bookworm config.txt is in /boot/firmware not /boot).
Thanks, i've tried USB gadget via the USB C port, be sure that before you add your usb gadget, there is not /dev/hidg0
then
echo "dtoverlay=dwc2" | sudo tee -a /boot/firmware/config.txt
echo "dwc2" | sudo tee -a /etc/modules # loat at boot
echo "libcomposite" | sudo tee -a /etc/modules
sed -i '/^exit 0/i /usr/bin/your_usb_gadget' /etc/rc.local
reboot, and chmod 777 /dev/hidg0 and so on
Statistics: Posted by wangshuaishuai — Wed Jan 01, 2025 5:04 pm