Hi, I am trying to get Raspberry PI Zero W to work in simultaneous AP+STA mode. This kind of sort of works in raspbian, however I haven't been able to get it to work on OpenWrt. For raspbian I used the instructions from https://blog.thewalr.us/2017/09/26/raspberry-pi-zero-w-simultaneous-ap-and-managed-mode-wifi/.
On booting with raspbian, I see this in dmesg for brcmfmac driver load.
[ 10.473651] brcmfmac: F1 signature read @0x18000000=0x1541a9a6
[ 10.486165] brcmfmac: brcmf_fw_map_chip_to_name: using brcm/brcmfmac43430-sdio.bin for chip 0x00a9a6(43430) rev 0x000001
[ 10.486550] usbcore: registered new interface driver brcmfmac
[ 10.969625] brcmfmac: brcmf_c_preinit_dcmds: Firmware version = wl0: Oct 23 2017 03:55:53 version 7.45.98.38 (r674442 CY) FWID 01-e58d219f
[ 10.970748] brcmfmac: brcmf_c_preinit_dcmds: CLM version = API: 12.2 Data: 7.11.15 Compiler: 1.24.2 ClmImport: 1.24.1 Creation: 2014-05-26 10:53:55 Inc Data: 9.10.39 Inc Compiler: 1.29.4 Inc ClmImport: 1.36.3 Creation: 2017-10-23 03:47:14
[ 17.965633] brcmfmac: power management disabled
However, booting with openwrt I see this in dmesg
root@OpenWrt:/# dmesg | grep brcm
[ 7.185771] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1
[ 7.350199] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1
[ 7.363651] brcmfmac mmc1:0001:1: Direct firmware load for brcm/brcmfmac43430-sdio.clm_blob failed with error -2
[ 7.378675] brcmfmac mmc1:0001:1: Falling back to user helper
[ 7.409063] firmware brcm!brcmfmac43430-sdio.clm_blob: firmware_loading_store: map pages failed
[ 7.426381] brcmfmac: brcmf_c_process_clm_blob: no clm_blob available (err=-11), device may have limited channels available
[ 7.449007] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM43430/1 wl0: Oct 23 2017 03:55:53 version 7.45.98.38 (r674442 CY) FWID 01-e58d219f
[ 7.522293] usbcore: registered new interface driver brcmfmac
[ 17.650538] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 19.146820] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 20.698133] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 31.842257] ieee80211 phy0: brcmf_escan_timeout: timer expired
[ 32.762086] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 43.362267] ieee80211 phy0: brcmf_escan_timeout: timer expired
[ 44.235513] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 45.693247] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 47.209139] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
[ 48.652918] ieee80211 phy0: brcmf_link_down: WLC_DISASSOC failed (-52)
Is this a firmware issue? or am i missing something basic here? I checked the MD5 for the firmware bin file and that checks out.
Any help is greatly appreciated.
In case of the RPi, the wireless situation isn't as dire as for most other Broadcom wireless chipsets. It is using the mainline brcmfmac (cfg80211 based) driver and the public brcmfmac firmware from linux-wireless. I'm not sure about the exact feature set brcmfmac supports, but iw list should anser that question.
Thanks for the response guys! Yes @slh, both raspbian and openwrt in this case are using the brcmfmac driver. I tried adding more debugs in the driver and it looks like the firmware load works the same way on both; so I can pretty much rule that out.
First of all, please use the "preformatted text" feature of the online editor, whenever you post any configs for better readability - thanks.
In 'wifi-device' section I would change channel to 'auto' and remove the 'disabled' option. 'wifi-iface' section for ap looks OK (maybe you should enable psk2 encryption anyway), same goes to 'sta' section ... only ...
looks unusual. Is this network 'wlan' really configured as WAN network? Please post also your network and firewall configuration. In general I would test 'sta' and 'ap' separately ... start with the 'sta' stuff, if the uplink connection works OK, add the 'ap' and check if the WLAN comes up.
Ok, will set channel to auto, the disabled option was for me to control them separately from a script.
ap encryption is for test purpose right now, will change it once everything is set
Yes I have wlan configured similar to lan and I think it is configured properly; I have tested them separately and they work fine. Anyhow, following are the configurations
No, your firewall config looks wrong to me. Please remove list network 'wlan' from your lan zone and add it to your wan zone. Restart your firewall config afterwards (/etc/init.d/firewall restart).
Why is that a problem if I want to configure the routing for 'wlan' similar to 'lan'?
Also, I tried your suggestion and that does not seem to solve the issue. Also, I get the following warnings in the output when I restart the firewall; anything to be worried about?
Warning: Unable to locate ipset utility, disabling ipset support
Warning: Section @zone[1] (wan) cannot resolve device of network 'wan'
Warning: Section @zone[1] (wan) cannot resolve device of network 'wlan'
Warning: Section @zone[1] (wan) has no device, network, subnet or extra options
I've been working on this for a couple days and have not gotten it working. I was wondering if you ever figured it out.
Im just trying to use my pi 0 as a repeater and have a nice web interface that less tech savy people can use
darn, well thanks for the reply. I'm able to get it working on pi 0 with raspbian, but i think there's a driver issue that prevents it from working with openWRT. Im going to make my own post about it in a bit.
I did find a version of claims to work however it only worked for about five minutes and then completely locked up the zero because it overheated.
Unless you actually rewrite the Broadcom driver I suspect that this at least with the zero is nearly impossible. Using a zero with an ath H9K USB dongle seems like the best option which I’ll be testing this weekend.
Well that's disappointing. Nonetheless I'd be interested to know what configuration you used to get it working with a single radio for even a few minutes.
At this point I just want to know what exactly is wrong and get it working even temporarily.