Author: Weiwei Wan, Date: 09/2021, Place: Toyonaka, Osaka

Step 1: Set up the network interfaces. This allows the two WiFi adapters to connect to different networks using DHCP.

sudo vi /etc/network/interfaces
# setup wlan0 and wlan1
>> auto wlan0
>> iface wlan0 inet dhcp
>> wpa-ssid "your ssid"
>> wpa-psk "your psk"
>> auto wlan1
>> iface wlan1 inet dhcp
>> wpa-ssid "yunji_WT_03484"
>> wpa_psk "yunjiwater"

In case a static IP is preferred, use:

allow-hotplug eth0
iface eth0 inet static
address 10.2.0.203
netmask 255.255.255.0
gateway 10.2.0.254
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

iface default inetdhcp (20220509 it seems this one should be deleted)

Step 2: Ensure WPA authentication works. (Maybe not necessary)

sudo vi /etc/wpa_supplicant/wpa_supplicant.conf
# make sure the content is as follows
>> ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
>> update_config=1
>> country=JP
>> network={
>>         ssid="yunji_WT_03484"
>>         psk="yunjiwater"
>>         key_mgmt=WPA-PSK
>> }
>> network={
>>         ssid="hlab-f522"
>>         psk="wan_office"
>>         key_mgmt=WPA-PSK
>> }
Step 3: Reboot