Jump to content

Orange Pi Plus 2E as wifi client + AP [SOLVED]


jimg

Recommended Posts

I'm trying to configure the RTL8189FTV module on an Orange Pi+ 2E in SoftAP + STA mode so I can use it as wifi hotspot.  According to this old document from Realtek (http://www.ofeixin.com/downloadRepository/8da8dda7-6721-4ac8-a7db-47cc4d9b218c.pdf), it's possible to do so using an RTL8189ETV, so I'm assuming it's possible on the RTL8189FTV, too.

 

The default driver doesn't allow concurrent connections like this, tho, so it must be recompiled.  I downloaded the source recommended on the sunxi wiki (http://linux-sunxi.org/Wifi#RTL8189FTV):

git clone https://github.com/jwrdegoede/rtl8189ES_linux.git
cd rtl8189ES_linux
git checkout -B rtl8189fs origin/rtl8189fs

I edited the file ./include/autoconf.h to turn on concurrent mode:

#define CONFIG_CONCURRENT_MODE  1

then compiled the driver using the repository's Makefile:

make -j4 ARCH=arm KSRC=/lib/modules/$(uname -r)/build

I renamed the old module, copied the new one to the proper directory, removed the old module, and inserted the new one:

cd /lib/modules/4.14.70-sunxi/kernel/drivers/net/wireless/realtek/rtl8189fs
sudo mv 8189fs.ko  8189fs.ko.orig
sudo cp ~/rtl8189ES_linux/8189fs.ko .
sudo rmmod 8189fs.ko
sudo insmod 8189fs.ko

After doing so, I have two wifi interfaces, wlan0 and wlan1.

 

The trouble I'm having is I cannot get wlan0 to authenticate when configured as a wifi client, nor accept clients when configured as a wifi hotspot.  It attempts to make a connection but always fails, even when the hotspot is configured as open (no password).  wlan1, however, works fine when configured either as a wifi client or hotspot.

 

FWIW, I'm using the latest version of Armbian Bionic.

 

UPDATE:  The problem was both devices had the same mac address.  I solved this by running the following script at boot:

 

#!/bin/sh

# Set up access point
AP_IFACE=wlan0
AP_NAME="MyAP"
AP_PASSWORD="abcd1234"
CON_NAME=hotspot

if [ ! $(nmcli -t con show | grep "$CON_NAME") ]
then
    nmcli con add type wifi ifname "$AP_IFACE" con-name "$CON_NAME" autoconnect yes ssid "$AP_NAME" mode ap
    nmcli con modify "$CON_NAME" 802-11-wireless.cloned-mac-address 12:34:56:78:90:AB 802-11-wireless.mode ap 802-11-wireless-security.key-mgmt wpa-psk ipv4.method shared 802-11-wireless-security.psk "$AP_PASSWORD"
fi
nmcli connection up "$CON_NAME"

 

 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines