Embedded networking

DISCLAIMER OF LIABILITY

THE PROCEDURES AND SAMPLES IN THIS PAGE ARE PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND (EITHER EXPRESS OR IMPLIED), INCLUDING BUT NOT LIMITED TO ANY IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A SPECIFIC OR GENERAL PURPOSE AND THOSE ARISING BY STATUTE OR BY LAW, OR FROM A CAUSE OF DEALING OR USAGE OF TRADE.

THIS ALSO APPLIES TO THE CONSEQUENCES OF ANY ACTIONS TAKEN ON THE BASIS OF THE INFORMATION PROVIDED.

Ethernet Network settings

It is possible to manually change the network settings.

Changing the network settings may result in a non-accessible device, please make sure to follow the guidelines as exactly stated.

In case of the device becoming inaccessible, follow instruction from the recovery chapter.

Use DHCP

Follow the steps:

    • Make sure the file /etc/network/interfaces looks like:

auto lo

iface lo inet loopback

# The primary network interface

allow-hotplug eth0

iface eth0 inet dhcp

auto eth0:1

allow-hotplug eth0:1

iface eth0:1 inet static

address 172.31.61.2

netmask 255.255.255.0

# Ethernet/RNDIS gadget (g_ether)

# ... or on host side, usbnet and random hwaddr

# Note on some boards, usb0 is automaticly setup with an init script

allow-hotplug usb0

iface usb0 inet static

address 192.168.7.2

netmask 255.255.255.0

network 192.168.7.0

    • Restart networking:

$sudo /etc/init.d/networking restart

Make sure a DHCP server is enabled in the network, otherwise the device won't be available.

Use static IP address

Follow the steps:

    • Make sure the file /etc/network/interfaces looks like:

auto lo

iface lo inet loopback

# The primary network interface

allow-hotplug eth0

iface eth0 inet static

address ${address}

netmask ${netmask}

gateway ${gateway}

auto eth0:1

allow-hotplug eth0:1

iface eth0:1 inet static

address 172.31.61.2

netmask 255.255.255.0

allow-hotplug usb0

iface usb0 inet static

address 192.168.7.2

netmask 255.255.255.0

network 192.168.7.0

Change ${address}, ${netmask} and ${gateway} by the real values. For example:

auto lo

iface lo inet loopback

# The primary network interface

allow-hotplug eth0

iface eth0 inet static

address 192.168.1.23

netmask 255.255.255.0

gateway 192.168.1.1

auto eth0:1

allow-hotplug eth0:1

iface eth0:1 inet static

address 172.31.61.2

netmask 255.255.255.0

allow-hotplug usb0

iface usb0 inet static

address 192.168.7.2

netmask 255.255.255.0

network 192.168.7.0

    • Change /etc/resolve.conf file to

nameserver 8.8.8.8

nameserver 8.8.4.4

It is also possible to use other DNS servers.

    • Restart networking:

$sudo /etc/init.d/networking restart

Wifi Network settings

Keonn does not provide any form of active support to install and/or configure Wifi USB dongles.

We strongly recommend to use a wired connection or a 4G router with an Ethernet port instead.

Only people with experience in the Linux command line should attempt to install and configure Wifi dongles.

Use this guide at your own risk.

DISCLAIMER OF LIABILITY

THE PROCEDURES AND WIFI DONGLES SUGGESTED IN THIS PAGE ARE PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND (EITHER EXPRESS OR IMPLIED), INCLUDING BUT NOT LIMITED TO ANY IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A SPECIFIC OR GENERAL PURPOSE AND THOSE ARISING BY STATUTE OR BY LAW, OR FROM A CAUSE OF DEALING OR USAGE OF TRADE.

THIS ALSO APPLIES TO THE CONSEQUENCES OF ANY ACTIONS TAKEN ON THE BASIS OF THE INFORMATION PROVIDED.

It is possible to use a usb wifi adapter to provide of Wireless connection to the AdvanReader. However, due to the low reliability and the big differences between devices we don't recommend the use of it and don't provide support at all. This guide lists some USB dongles successfully tested at Keonn, and the steps to get them running. As it has been stated, using a listed device and correctly following the steps doesn't guarantee that the device will work correctly, since new versions of the device are launched from time to time and may not work with the same drivers / procedure as older versions tested here.

Requirements

    • AdvanReader connected to a network.

    • A computer in the same network as the AdvanReader

    • A compatible USB WiFi Adapter.

USB WiFi Adapters

TP-Link TL-WN821N (V4)

Edimax EW-7811Un (v1.0A)

TP-Link TL-WN725N (v3.0)

How to configure the wireless connection (steps for TP-Link TL-WN725N v3.0)

    1. Power on the AdvanReader without the USB adapter.

    2. Connect to the AdvanReader via SSH (Putty, Linux terminal...). You will need the user and password. To obtain them, please visit Get SSH-Credentials

    3. Once there is a connection, execute the following commands:

sudo apt-get update

sudo apt-get install wireless-tools

sudo apt-get install wpasupplicant

sudo apt-get install usbutils

(Only for TP-Link TL-WN725N v3.0). Also run the following commands:

sudo mkdir /lib/firmware/rtlwifi

sudo wget https://github.com/lwfinger/rtl8188eu/raw/c83976d1dfb4793893158461430261562b3a5bf0/rtl8188eufw.bin -O /lib/firmware/rtlwifi/rtl8188eufw.bin

The following command:

sudo iwconfig

Should give you the name of the interface (similar to wlan0). Otherwise, the system does not recognize the dongle and you need to reboot the device and try again. Depending on the dongle model, you may need to install additional drivers. Check the dongle official's website for further information.

Configure the network by modifying the file /etc/network/interfaces:

Any misconfiguration might render the device inaccessible!

Make sure there are no typos before saving the file

1. Open the file /etc/network/interfaces using an editor like "vi" or "nano" (Remember to use sudo vi or sudo nano).

2. Add the following information to this file, changin the "wlan0" for the identifier showed in the first command and filling the information about the network's ssid and password:

allow-hotplug wlan0

iface wlan0 inet dhcp

wpa-ssid ssid

wpa-psk password

3. Unplug the AdvanReader

4. Insert the WiFi dongle.

5. Plug the AdvanReader back

6. Execute the following command (replacing wlan0 for your interface name):

sudo ifup wlan0

At this point, you should be able to access the internet without any other wired connection. To check if the AdvanReader has connectivity, please run again:

sudo iwconfig

The output should be similar to this:

usb0 no wireless extensions.

eth0 no wireless extensions.

lo no wireless extensions.

wlan0 IEEE 802.11bgn ESSID:"yourSSID" Nickname:"<WIFI@REALTEK>"

Mode:Managed Frequency:2.412 GHz Access Point: XX:XX:XX:XX:XX:XX

Bit Rate:72.2 Mb/s Sensitivity:0/0

Retry:off RTS thr:off Fragment thr:off

Encryption key:****-****-****-****-****-****-****-**** Security mode:open

Power Management:off

Link Quality=100/100 Signal level=86/100 Noise level=0/100

Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0

Tx excessive retries:0 Invalid misc:0 Missed beacon:0

can1 no wireless extensions.

can0 no wireless extensions.

Also, your new interface should show up when executing the command:

sudo ifconfig

We recommend adding a crontab that call this script every few minutes (replace wlan0 for the name of the interface):

#!/bin/bash

i=$(cat /sys/class/net/wlan0/carrier)

if [ $? -eq 0 ]; then

if[$i -wq 1];

echo "connected"

else

echo "reconnecting"

ifup wlan0

else

echo "reconnecting"

ifup wlan0

fi

If after rebooting, the wlan0 is not accessible, remove any static ip address set in the device

5 Ghz support

Readers and systems using Debian 9 or Debian 10 have support for RTL 88x2bu chipsets

For example the ASUS family:

    • ASUS USB-AC53 Nano

    • Asus USB-AC54 B1 Adaptador USB 3.0 WIFI AC1300 MU-MIMO

The module was build following this link: https://www.embeddedpi.com/documentation/wifi-configuration/sparklan-wpet-236acn-mpcie-raspberry-pi-wifi-install-guide

For devices that use rtl8812bu chipset such as

    • TP-Link Archer T3U

choose the file 88x2bu.archert3u.zip and decompress it to obtain the module. The source of this file is: https://github.com/cilynx/rtl88x2bu

Copy module to:

/lib/modules/4.14.115-bone23/kernel/drivers/net/wireless/

Alternatives

What we suggest to provide the reader with Wi-Fi capabilities is using a Wi-Fi bridge with Ethernet. However, due to the fast changing pace of the technology landscape we can't affort testing all the devices on the market although we are confident that a good device is but a quick google search of Wi-Fi extender with ethernet port away.