Jump to content

Recommended Posts

Posted

Hi,

First of all thanks for this awesome product, BananaPi M7 is really great in many ways!

Only one last thing appears to be broken on our project, I'm having connection troubles from IoT in 2.4Ghz against BananaPi setup as an AP.I'm using the latest up to date armbian server image
 

$ uname -a
Linux bananapim7 6.1.75-vendor-rk35xx #1 SMP Tue Nov 12 08:48:32 UTC 2024 aarch64 aarch64 aarch64 GNU/Linux

$ cat /etc/*release
# PLEASE DO NOT EDIT THIS FILE
BOARD=bananapim7
BOARD_NAME="Banana Pi M7"
BOARDFAMILY=rockchip-rk3588
BUILD_REPOSITORY_URL=https://github.com/armbian/build
BUILD_REPOSITORY_COMMIT=26d182157
LINUXFAMILY=rk35xx
ARCH=arm64
BOOT_SOC=rk3588
IMAGE_TYPE=stable
BOARD_TYPE=conf
INITRD_ARCH=arm64
KERNEL_IMAGE_TYPE=Image
KERNEL_TARGET=edge,current,vendor
KERNEL_TEST_TARGET=vendor,current
FORCE_BOOTSCRIPT_UPDATE=
FORCE_UBOOT_UPDATE=
OVERLAY_DIR="/boot/dtb/rockchip/overlay"
VENDOR="Armbian"
VENDORDOCS="https://docs.armbian.com"
VENDORURL="https://www.armbian.com"
VENDORSUPPORT="https://forum.armbian.com"
VENDORBUGS="https://www.armbian.com/bugs"
BOOTSCRIPT_FORCE_UPDATE="no"
BOOTSCRIPT_DST="boot.cmd"
VERSION=24.11.1
REVISION=24.11.1
IMAGE_UUID=14f1a719-8726-4abf-a76a-d0c4da1658c6
# PLEASE DO NOT EDIT THIS FILE
BOARD=bananapim7
BOARD_NAME="Banana Pi M7"
BOARDFAMILY=rockchip-rk3588
BUILD_REPOSITORY_URL=https://github.com/armbian/build
BUILD_REPOSITORY_COMMIT=26d182157
LINUXFAMILY=rk35xx
ARCH=arm64
BOOT_SOC=rk3588
IMAGE_TYPE=stable
BOARD_TYPE=conf
INITRD_ARCH=arm64
KERNEL_IMAGE_TYPE=Image
KERNEL_TARGET=edge,current,vendor
KERNEL_TEST_TARGET=vendor,current
FORCE_BOOTSCRIPT_UPDATE=
FORCE_UBOOT_UPDATE=
OVERLAY_DIR="/boot/dtb/rockchip/overlay"
VENDOR="Armbian"
VENDORDOCS="https://docs.armbian.com"
VENDORURL="https://www.armbian.com"
VENDORSUPPORT="https://forum.armbian.com"
VENDORBUGS="https://www.armbian.com/bugs"
BOOTSCRIPT_FORCE_UPDATE="no"
BOOTSCRIPT_DST="boot.cmd"
VERSION=24.11.1
REVISION=24.11.1
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=24.04
DISTRIB_CODENAME=noble
DISTRIB_DESCRIPTION="Ubuntu 24.04 LTS"
PRETTY_NAME="Armbian 24.11.1 noble"
NAME="Ubuntu"
VERSION_ID="24.04"
VERSION="24.04 LTS (Noble Numbat)"
VERSION_CODENAME=noble
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.armbian.com"
SUPPORT_URL="https://forum.armbian.com"
BUG_REPORT_URL="https://www.armbian.com/bugs"
PRIVACY_POLICY_URL="https://www.armbian.com"
UBUNTU_CODENAME=noble
LOGO="armbian-logo"
ARMBIAN_PRETTY_NAME="Armbian 24.11.1 noble"

 

The wireless config seems to be alright:

 

$ iwconfig                                                                                                                                                                             
...

wlan0     IEEE 802.11  ESSID:""  
          Mode:Master  Channel:34  Access Point: Not-Associated   
          Bit Rate:1.2005 Gb/s   Tx-Power:32 dBm   
          Retry min limit:7   RTS thr:off   Fragment thr:off
          Power Managementmode:All packets received
          Link Quality=5/5  Signal level=-2 dBm  Noise level=-99 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

$ iw wlan0 info
Interface wlan0
    ifindex 4
    wdev 0x1
    addr b8:2d:28:5a:56:f6
    type managed
    wiphy 0
    channel 1 (2412 MHz), width: 20 MHz, center1: 2412 MHz
    txpower 31.00 dBm

$ iw ap0 info
Interface ap0
    ifindex 16
    wdev 0x4
    addr ba:2d:28:5a:56:f6
    ssid XXXXXXXX
    type AP
    wiphy 0
    channel 1 (2412 MHz), width: 20 MHz, center1: 2412 MHz
    txpower 31.00 dBm


 

 

The interface is correctly setup:

$ ip a
...
16: ap0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether ba:2d:28:5a:56:f6 brd ff:ff:ff:ff:ff:ff
    inet 10.1.0.1/8 brd 10.255.255.255 scope global noprefixroute ap0
       valid_lft forever preferred_lft forever
    inet6 fe80::be9a:7773:f8dc:f9fa/64 scope link noprefixroute
       valid_lft forever preferred_lft forever

$ nmcli con show
NAME                 UUID                                  TYPE       DEVICE    
XXXXXXXX           7c89f803-bd17-42e1-8134-e2f6f33edc28  wifi       ap0
...

 

I'm able to connect to my AP using my laptop (the only differences I see is that I'm using a 5Ghz capable network card even if 2.4Ghz is setup in nmcli config...)
But the IoT equipement keep being deauthenticated with messages like:

 

$ sudo dmesg
...
[ 2279.531130] [dhd] __dhd_add_sta: Adding  STA 00:XX:XX:XX:70:90
[ 2279.535314] [dhd] [ap0] wl_ext_iapsta_link : [A] connected device 00:XX:XX:XX:70:90
[ 2279.536101] [dhd] dhd_update_sta_chanspec_info: updated chanspec:0x1001 for STA:00:XX:XX:XX:70:90
[ 2279.536133] [dhd] [ap0] wl_notify_connect_status_ap : new sta event for 00:XX:XX:XX:70:90
[ 2279.537036] [dhd] CFG80211-ERROR) wl_cfg80211_change_station : WLC_SCB_AUTHORIZE sta_flags_mask not set


 

A quick google search led me to this line in wl_cfg80211.c driver -> https://android.googlesource.com/kernel/msm/+/9a5104b845c1558cc204abfe97c120d14677baa5/drivers/net/wireless/bcmdhd/wl_cfg80211.c#6928
It appear to be a question about params->sta_flags_mask not set, as NL80211_STA_FLAG_AUTHORIZED is set to 0 in include files

 

Question: Where are set the struct station_parameters ? How could it be modified ?

 

Reproduce steps script:
 

#!/bin/bash

HOTSPOT="XXXXXXXX"
AP_PASS="XXXXXXXX"
AP_IFACE="ap0"

# Setup iface
sudo iw dev wlan0 interface add $AP_IFACE type __ap

# Setup HotSpot
sudo nmcli con add type wifi con-name $HOTSPOT ssid $HOTSPOT
sudo nmcli con modify $HOTSPOT 802-11-wireless.mode ap 802-11-wireless.band bg 802-11-wireless.channel 1 ipv4.method shared
sudo nmcli con modify $HOTSPOT wifi-sec.key-mgmt none
sudo nmcli con modify $HOTSPOT wifi-sec.wep-key-type 1
sudo nmcli con modify $HOTSPOT wifi-sec.wep-key0 $AP_PASS
sudo nmcli con modify $HOTSPOT ifname $AP_IFACE
sudo nmcli con modify $HOTSPOT ipv4.address 10.1.0.1/8
sudo nmcli con modify $HOTSPOT ipv4.gateway 10.1.0.1
sudo nmcli con up $HOTSPOT

 


Thanks for your help !

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines