https://www.andreagrandi.it/posts/howto-configure-ethernet-connection-ipad-raspberrypi-usbc/ Avatar Andrea Grandi Software Developer 1. 2. 3. 4. 1. Home 2. About 3. Curriculum Buy Me a Coffee at ko-fi.com HowTo How to configure an Ethernet connection between iPad and RaspberryPi through USB-C This tutorial explains how to configure an Ethernet connection between an iPad and a RaspberryPi using the USB-C port. Oct 26, 2024 I recently found out (thanks to this article from Juha-Matti Santala) that not only you can power a RaspberryPi device through the USB-C of an iPad but that you can also get an ethernet connection through it Requirements * an USB-C iPad (I used an iPad Air 4th gen) * a USB-C cable (I used the one that comes with the iPad) * a RaspberryPi (you need at least a RPI 4. I used a RPi 5) * you already have SSH access to the RaspberryPi (I won't cover this part in this tutorial) * an updated bootloader on the RaspberryPi (check this documentation) Configuration 1. Connect to the RaspberryPi using SSH 2. Become super user on the RaspberryPi: sudo su 3. Edit /boot/firmware/cmdline.txt and add these options after rootwait: 1 modules-load=dwc2,g_ether 4. Edit /boot/firmware/config.txt and make sure that otg_mode=1 is uncommented. Then add this line after the [all] section: 1 dtoverlay=dwc2 5. Use this command to add a new connection: 1 nmcli con add type ethernet con-name ethernet-usb0 6. Edit /etc/NetworkManager/system-connections/ ethernet-usb0.nmconnection and make sure you have these settings: 1 [connection] 2 id=ethernet-usb0 3 uuid= 4 type=ethernet 5 autoconnect=true 6 interface-name=usb0 7 8 [ethernet] 9 10 [ipv4] 11 method=shared 12 13 [ipv6] 14 addr-gen-mode=default 15 method=auto 16 17 [proxy] 7. Edit /usr/local/sbin/usb-gadget.sh and add this: 1 #!/bin/bash 2 3 nmcli con up ethernet-usb0 8. Make the file executable: 1 chmod a+rx /usr/local/sbin/usb-gadget.sh 9. Edit /lib/systemd/system/usbgadget.service and add this: 1 [Unit] 2 Description=My USB gadget 3 After=NetworkManager.service 4 Wants=NetworkManager.service 5 6 [Service] 7 Type=oneshot 8 RemainAfterExit=yes 9 ExecStart=/usr/local/sbin/usb-gadget.sh 10 11 [Install] 12 WantedBy=sysinit.target 10. Enable the service using this command: 1 systemctl enable usbgadget.service 11. Reboot the RaspberryPi: 1 reboot Check the configuration is working Connect the RaspberryPi to the iPad using the USB-C cable and wait for it to boot. Once it finishes booting up, open Settings on the iPad and check if there is an Ethernet section below the WiFi Connection. If you find the entry, then it means the connection is successful. References This tutorial has been written thanks to this other tutorial https:// github.com/verxion/RaspberryPi/blob/main/ Pi5-ethernet-and-power-over-usbc.md If you enjoyed this article and want to show your appreciation, consider buying me a coffee using the button below. Your support, even a small gesture, means a lot and will inspire me to continue writing and sharing more articles on my blog [?] Buy Me a Coffee at ko-fi.com Tutorial Hwoto Raspberrypi Ethernet Usbc Connection IPad Configuration Related content Featured image of post It's now possible to use ControlD DNS with Tailscale It's now possible to use ControlD DNS with Tailscale Featured image of post Tracking airplanes with a Raspberry Pi and an ADS-B receiver Tracking airplanes with a Raspberry Pi and an ADS-B receiver Featured image of post Buy or Rent? RaspberryPi vs VPS Buy or Rent? RaspberryPi vs VPS Featured image of post Blogging from an iPad Blogging from an iPad Featured image of post Use OpenAI API to make two GPT bots talk to each other Use OpenAI API to make two GPT bots talk to each other (c) 2007 - 2024 Andrea Grandi source code available on GitHub Built with Hugo Theme Stack designed by Jimmy