Categories
SysOps

How to disable onboard WiFi and Bluetooth on Raspberry Pi 4

Disable onboard WiFi and Bluetooth on Raspberry Pi 4 device.

List Bluetooth devices.

$ hcitool dev
Devices:
	hci0	E4:5F:01:42:3A:4B

List wireless devices

$ iw dev
phy#0
	Unnamed/non-netdev interface
		wdev 0x2
		addr e6:5f:01:42:3a:4a
		type P2P-device
	Interface wlan0
		ifindex 3
		wdev 0x1
		addr e4:5f:01:42:3a:4a
		type managed
		channel 34 (5170 MHz), width: 20 MHz, center1: 5170 MHz

Inspect available options.

$ less /boot/overlays/README
[...]

Name:   disable-bt
Info:   Disable onboard Bluetooth on Pi 3B, 3B+, 3A+, 4B and Zero W, restoring
        UART0/ttyAMA0 over GPIOs 14 & 15.
        N.B. To disable the systemd service that initialises the modem so it
        doesn't use the UART, use 'sudo systemctl disable hciuart'.
Load:   dtoverlay=disable-bt
Params: 

[...]

Name:   disable-wifi
Info:   Disable onboard WLAN on Pi 3B, 3B+, 3A+, 4B and Zero W.
Load:   dtoverlay=disable-wifi
Params: 

[...]

Disable onboard Bluetooth devices.

$ echo "dtoverlay=disable-bt" | sudo tee -a /boot/config.txt

Disable onboard WLAN devices.

$ echo "dtoverlay=disable-wifi" | sudo tee -a /boot/config.txt

Disable systemd service that initializes Bluetooth Modems connected by UART.

$ sudo systemctl disable hciuart

Reboot Raspberry Pi device.

$ sudo reboot

Ensure that Bluetooth devices are not available.

$ hcitool dev
Devices:

Ensure that wireless devices are not available.

$ iw dev

Inspect network devices.

$ ip -br a
lo               UNKNOWN        127.0.0.1/8 ::1/128 
eth0             UP             172.16.1.101/16 fe80::12b8:2400:4357:ec24/64

That is all.