Posts

LM811: Using WiFi Access Point and WiFi Station simultaneously

Introduction

The LM811 can function as a WiFi Access Point and a WiFi station at the same time.  Concurrent mode allows the device to perform 2 separate wireless tasks at the same time.

This is dependant on how much bandwidth is allocated for a specific application. For example on Linux (x86), the LM811 can function as a WiFi AP and 8 WiFi Clients at the same time. The driver must be configured to concurrent mode. Please note that the channel under concurrent mode must be the same with both the WiFi STA and AP.

Three combinations of concurrent mode are supported:

  1. Station mode + Station mode
  2. Station mode + AP mode
  3. Station mode + P2P mode

 

Enabling Concurrent Mode

In Realtek’s WiFi driver source code folder, edit the Makefile to add EXTRA_CFLAGS += -DCONFIG_CONCURRENT_MODE to the target platform. After modification you have to rebuild the driver and then reload it.

Use the I386 as an example:

ifeq ($(CONFIG_PLATFORM_I386_PC), y)
EXTRA_CFLAGS += -DCONFIG_CONCURRENT_MODE
EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN
… …
endif

You can verify if it works by typing “ifconfig –a” command, It is supposed to show two wireless interfaces, and MAC address of secondary interface is nearly the same except the bit1 of byte0 was assigned as 1.

Based on past experiences, we recommend our customers to verify the whole system step by step – first check station mode, then check AP mode, finally the station + AP mode (concurrent mode).

  • Please reference “wpa_cli_with_wpa_supplicant.pdf” to understand how to run in station mode, “Quick_Start_Guide_for_Station_Mode.pdf” is also a good choice.
  • Please reference “Quick_Start_Guide_for_SoftAP.pdf” to understand how to run in AP mode.

For further instructions please refer to the document “Realtek_WiFi_concurrent_mode_Introduction.pdf” in the Linux driver ZIP package.

 

Common Questions

Q1: Why does the system still only have one interface after rebuilding module with insmdo?

A: Please make sure you edit the correct autoconf.h and insmod the correct module, and also provide your autoconf.h and kernel message log to us.

Q2: Everything is fine when I only start hostapd, but when I start running station mode in another interface at the same time, the hostapd will disconnect for a second then be reconnected again; however the channel is different from the prior setting. Is anything wrong?

A: Don’t worry, this is fine! As described before, those two wireless interfaces actually share the same physical hardware device. That means those 2 wireless interfaces must work under the same channel. Our rule is AP/P2P interface should follow the channel of the station interface; if both interface are running station mode, the connected AP’s must be the same channel.

Q3: How is the throughput when using 2 wireless interfaces in concurrent mode?

A: Because there is only one physical hardware device, the two wireless interface (wlan0, wlan1) will share the transmit bandwidth, for example: Assume the throughput limitation of current environment is 85Mb/s, then the throughput of wlan0 + the throughput of wlan1 is basically equal or smaller than 85Mb/s.

Q4: Which wireless interface can run in station mode? Which wireless interface can run in AP mode?

A: We recommend runing station mode in wlan0, run AP or P2P mode in wlan1.

 

LM811: Power supply FAQ

Question:

The power supply on the board will supply the required current for the module, but do I also need to add any decoupling caps close to the supply pins of the module? Or are they already on the module, and all i need to supply is the +3.3V to the module?

Answer:

  • The LM811 doesn’t require any additional capacitors as long as the correct voltage is being used.

 

Question:

I’ve ordered the WIFI/BT combo-module LM811 with IPEX connector. In the datashaeet I found, that the DC power input is 3.3V. Is it possible to connect a 5V USB interface to the module? Are the USB D+ and D- inputs 5V tolerant? 

Answer:

  • It should be fine. However we do not recommend it as it is very easy to damage the module with the wrong voltage signals.

 

Question:

I’m designing the LM811-0461 into a new design.  I’m not intending to use the WO-WLAN, SUSPEND or BT_PCM functionality, I just want to connect power and USB.  I would like advice on how to connect the unused signals. The BT_PCM_IN pin is documented as an input – should I tie this to ground to prevent the input from floating?

Answer;

  • All unused pins can be left unconnected. It is not necessary to tie them to ground.

 

Migrating to the LM811

How to migrate from the LM820/821/822/823 to the LM811?

The LM811 and LM820/821/822/823 have the same dimensions of 25mm x 12mm x 2mm and the USB interface (pin 2 to pin 5) are in exactly the same position.

When moving to the LM811, consider the following:

  • Pin 1 and Pin 6 have different pin assignments to LM820/821/822/823 .
  • The LM811 has extra pins for a PCM interface. If PCM is not required, this will not affect the design.

Please refer to the datasheets for further information.

 

 

LM811: Linux driver installation

WiFi

The WiFi driver can be downloaded from here: https://github.com/lwfinger/rtl8723bu If you are compiling on the Raspberry Pi 2 or another ARM device you will need to change the SUBARCH build parameter in the Makefile to “arm”.

Read more

Linux WiFi Ad-hoc mode

Ad-hoc, or IBSS mode allows you to create a wireless network without a central access point. This guide demonstrates a simple Ad-hoc network using one of our adapters and some basic tools found in most modern Linux distributions.

  • At the present time, IBSS may suffer from high levels of packet loss due to an issue with the driver.

Read more