I have a Raspberry Pi 4 with Raspbian 10 (buster) installed. This device will be placed in a waterproof metal box which will limit the on-board wifi range. So, I want to use a USB wifi adapter with an external antenna.
I have configured the on-board wifi adapter to connect to my wifi router successfully. ifconfig returns the following
wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.10 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::512c:3a96:6ee9:d7c3 prefixlen 64 scopeid 0x20<link>
ether dc:a6:32:1a:79:93 txqueuelen 1000 (Ethernet)
RX packets 124 bytes 12486 (12.1 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 136 bytes 16805 (16.4 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
My /etc/dhcpcd.conf file contains the following:
interface wlan0
inform 192.168.1.10
static routers=192.168.1.1
static domain_name_servers=8.8.8.8
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
metric 100;
interface wlan1
inform 192.168.1.3
static routers=192.168.1.1
static domain_name_servers=8.8.8.8
metric 200;
wpa-conf /etc/wpa_supplicant/wpa_supplicant_wlan1.conf
My /etc/wpa_supplicant/wpa_supplicant.conf file contains:
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=US
network={
ssid="MYWIFI"
psk="password"
key_mgmt=WPA-PSK
}
and the second wpa_supplicant.conf file contains the credentials for the same network with a different IP. However, when I do an ifconfig command wlan1 never shows up.
The antenna I have is ASUS USB-AC56 which uses the Realtek RTL8812AU chipset. When I plug it into a USB port and run lsusb I get the following:
Bus 001 Device 004: ID 0b05:17d2 ASUSTek Computer, Inc. USB-AC56 802.11a/b/g/n/ac Wireless Adapter [Realtek RTL8812AU]
So the Pi sees the USB wifi adapter, but it doesn't bring up wlan1. What am I missing here?