This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2.

2025/10/1520:11:35 technology 1910

This article focuses on how to develop Web in the source code

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews. Create directories and files (the following focuses on the two functions of RSSI and NicRate)


Enter openwrt source code/qsdk/qca/feeds/luci/applications
, add the directory file structure in the figure below:

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews. Add the following code to the luci-app-myapplication/Makefile file above:

include $(TOPDIR)/rules.mk




LUCI_TITLE:=LuCI Support for Test

LUCI_DEPENDS:=




include ../../luci.mk

# call BuildPackage - OpenWrt buildroot signature

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews. Add the following code in luasrc/controller/myapp/mobi.lua:

function index()

entry({"admin", "MOBI"}, firstchild(),"MOBI", 30).dependent=false

entry({"admin", "MOBI", "RSSI"}, template("rssi_test"), _("signal strength"), 1)

entry({"admin", "MOBI", "NicRate"}, cbi("mymodule/gateway"), translate("network card rate"), 2)

end

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews. Add the following code to /luasrc/view/myview/rssi_test:

%

local fs = require "nixio.fs"

local util = require "luci.util"

local log = require "luci.log"

require "luci.model.uci"

if luci.http.formvalue("status") == "1" then

local file = io.open('/sys/class/net/wlan0/device/prs_attrs/rx_rssi','r')

local ret

if file then

ret = file:read('*all')

file:close()

luci.http.prepare_content("application/json")

luci.http.write_json(ret)

return

else

ret = "Error"

log.print("ret="..ret)

luci.http.prepare_content("application/json")

luci.http.write_json(ret)

return

end

end

-%

%+header%

script type="text/javascript" src="%=resource%/cbi.js"/script

script type="text/javaScript"

XHR.poll(2,'%=REQUEST_URI%',{status:1},function(x,info) {

var ret = info;

document.getElementById("contxt").innerText = info;

}

);

/script

h1a id="content" name="content"%:Signal Strength:%/a/h1

h2b id="contxt" name="content"%%/b/h2

%+footer%

5. Add the following code in /luasrc/model/cbi/mymodule/gateway.lua:

local fs = require "nixio.fs"

m = Map("test_file","Nic Rate" ,translate("Nic Rate")) -- cbi_file is the config file in /etc/config

s = m:section(TypedSection,"arguments","")

s.addremove=false

s.anonymous=true

o = s:option(ListValue,"collection","NicRate")

o:value("first item","10G")

o:value("second item","2.5G")

local apply = luci.http.formvalue("cbi.apply")

if apply then

io.popen("/etc/init.d/NicTestSH.sh start")

end

return m

6. Add the following code to the openwrt source code/qsdk/package/base-files/files/etc/init.d/NisTestSH.sh:

#!/bin/sh etc/rc.common

START=50

run_mobi()

{

local enable

config_get_bool enable $1 enable

local collection

config_get collection $1 collection

if [ "$collection" == "first item" ]; then

ethtool -s eth1 speed 2500 duplex full

else

ethtool -s eth1 speed 10000 duplex full

fi

}

start()

{

config_load test_file

config_foreach run_mobi arguments

}

7. Execute Luci update:

Return to the openwrt source directory and execute the following command:

./scripts/feeds update luci

./scripts/feeds install -a -p luci

8. Make menuconfig check:

LuCI --- Collections --- * luci * luci-ssl Translations--- * Chinese(zh-cn) //Support Chinese * English (en) Support English 
LuCI --- Applications --- * luci-app-myapplication............ LuCI Support for Test 

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews

9. Then execute make V=s to compile

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews0. Burn the firmware, check the web interface

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews

This article focuses on how to develop Web in source code 1. Create directories and files (the following focuses on the two functions of RSSI and NicRate). Enter the openwrt source code/qsdk/qca/feeds/luci/applications and add the directory file structure in the figure below: 2. - DayDayNews

and your first page is completed. Are you very excited?

, let’s continue digging and research!

technology Category Latest News