Difference between revisions of "Template:FriendlyWrt19"

From FriendlyELEC WiKi
Jump to: navigation, search
(Work with USB WiFi)
(Work with USB WiFi)
Line 40: Line 40:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
===Work with USB WiFi===
+
===Work with USB WiFi Device===
 
====Check USB WiFi Device with Command Line Utility====
 
====Check USB WiFi Device with Command Line Utility====
 
(1) Click on "service>ttyd" to start the command line utility<br />
 
(1) Click on "service>ttyd" to start the command line utility<br />
Line 58: Line 58:
 
[[File:R2swrt+usbwifi-10.jpg|frameless|800px]]<br />
 
[[File:R2swrt+usbwifi-10.jpg|frameless|800px]]<br />
  
(4) 以“0BDA:C811”或“VID_0BDA&PID_C811”作为关键词在搜索引擎上搜索,搜索结果显示VID_0BDA&PID_C811的对应WIFI芯片为Realtek 8811CU
+
(4) Type your device's ID (in our case it was "0BDA:C811" or "VID_0BDA&PID_C811") in a search engine and you may find a device that matches the ID. In our case the device we got was Realtek 8811CU.
  
 
====如何使用USB WiFi作为AP====
 
====如何使用USB WiFi作为AP====

Revision as of 09:12, 18 November 2020

1 Work with FriendlyWrt

1.1 Introduction to FriendlyWrt

FriendlyWrt is a customized system made by FriendlyElec based on an OpenWrt distribution. It is open source and well suitable for developing IoT applications, NAS applications, smart home gateways etc.

1.2 Account & Password

By default the password is NULL. You can set a password for root for web and SSH login.

1.3 Network Connection

Use a network cable to connect {{{1}}}'s WAN to a master router and the board will get an IP address via DHCP. Login into the router and check {{{1}}}'s IP address.

1.4 Login FriendlyWrt

Type {{{1}}}'s IP address or http://friendlywrt/ in a browser's address bar and enter to open FriendlyWrt's administration page or you can login into FriendlyWrt's administration page via SSH.
By default, the IP address of the LAN port is 192.168.2.1, and the WAN will dynamically obtain the IP address from your main router.

1.5 Install Software Packages

1.5.1 Update Package List

Before install software packages update the package list:

$ opkg update

1.5.2 List Available Packages

$ opkg list

1.5.3 List Installed Packages

$ opkg list-installed

1.5.4 Install Packages

$ opkg install <package names>

1.5.5 Remove Packages

$ opkg remove <package names>

1.6 Work with USB WiFi Device

1.6.1 Check USB WiFi Device with Command Line Utility

(1) Click on "service>ttyd" to start the command line utility
R2s-wrt-jellyfin-002.jpg

(2) Make sure no USB devices are connected to the board and run the following command to check if any USB devices are connected or not

lsusb

R2swrt+usbwifi-09.jpg

(3) Connect a USB WiFi device to the board and run the command again

lsusb

You will see a new device is detected. In our test the device's ID was 0BDA:C811
R2swrt+usbwifi-10.jpg

(4) Type your device's ID (in our case it was "0BDA:C811" or "VID_0BDA&PID_C811") in a search engine and you may find a device that matches the ID. In our case the device we got was Realtek 8811CU.

1.6.2 如何使用USB WiFi作为AP

(1) 把USB WiFi插入NanoPi R2S,推荐使用以下列表中支持AP模式的WiFi芯片模块(以下列表基于rk3328-sd-friendlywrt-5.4-20200514.img固件经测试可用)
R2swrt+usbwifi-08.jpg
注:符合以上WiFi芯片型号并符合以上VID&PID信息的USB无线网卡都可以使用,支持的型号不局限于某个品牌某个型号

(2) 插入USB WiFi后,点击上方菜单栏的“系统>重启”,点击“执行重启”按钮重启NanoPi R2S
R2swrt+usbwifi-01.jpg

R2swrt+usbwifi-02.jpg

(3) 点击“网络>无线”进入配置无线WiFi界面
R2swrt+usbwifi-03.jpg

(4) 点击“编辑”按钮可编辑WiFi设置
R2swrt+usbwifi-04.jpg

(5) 在“接口配置”中可设置WiFi 模式和SSID等,然后点击到“无线安全”项可修改加密方式和WiFi密码,默认密码为password,设置完成后点击“保存”
R2swrt+usbwifi-05.jpg

R2swrt+usbwifi-06.jpg

(4) 配置完成后使用手机端或电脑端搜索对应SSID的WiFi即可
R2swrt+usbwifi-07.png

1.7 Work with Docker Applications

1.7.1 Work with Docker: Install JellyBin

mkdir -p /jellyfin/config
mkdir -p /jellyfin/videos
docker run --restart=always -d -p 8096:8096 -v /jellyfin/config:/config -v /jellyfin/videos:/videos jellyfin/jellyfin:10.1.0-arm64 -name myjellyfin

After installation, visit port 8096 and here is what you would find:
FriendlyWrt+JerryFin

1.7.2 Work with Docker: Install Personal Nextcloud

mkdir /nextcloud -p
docker run -d -p 8888:80  --name nextcloud  -v /nextcloud/:/var/www/html/ --restart=always --privileged=true  arm64v8/nextcloud

After installtion, visit port 8888.

1.8 Enable Swap Partition

Run the following commands in a commandline utility and reboot:

/etc/enable-swap.sh
reboot

1.9 Mount smbfs

mount -t cifs //192.168.1.10/shared /movie -o username=xxx,password=yyy,file_mode=0644


1.10 Compile u-boot,kernel or friendlywrt