mirror of https://github.com/aredn/aredn.git
Merge branch 'release-3.17.1.0' into develop.
Bring current changes in release to develop to allow development to continue. Change-Id: I6c6e44026978ac4f938e687d540d476e5e8a610e
This commit is contained in:
commit
17b9d5357c
|
@ -20,6 +20,18 @@ uci_type_count() {
|
|||
}
|
||||
|
||||
######### UTILITY FUNCTIONS END ###########
|
||||
default_config() {
|
||||
local cfg="$1"
|
||||
local new_file="$2"
|
||||
local persist
|
||||
|
||||
config_get persist "$persist" persist "yes"
|
||||
|
||||
echo "default {" >> $new_file
|
||||
echo " persist $persist;" >> $new_file
|
||||
echo "}" >> $new_file
|
||||
echo " " >> $new_file
|
||||
}
|
||||
|
||||
options_config() {
|
||||
local cfg="$1"
|
||||
|
@ -112,22 +124,32 @@ start() {
|
|||
then
|
||||
apply_uci_config
|
||||
config_load vtun
|
||||
|
||||
|
||||
#if options section doesn't exist, add it
|
||||
j=`uci get vtun.@options[0]`
|
||||
if [ $? -ne 0 ]
|
||||
if [ $? -ne 0 ]
|
||||
then
|
||||
j=`uci add vtun options`
|
||||
j='uci commit vtun'
|
||||
config_load vtun
|
||||
fi
|
||||
|
||||
|
||||
#if default section doesn't exist, add it
|
||||
j=`uci get vtun.@default[0]`
|
||||
if [ $? -ne 0 ]
|
||||
then
|
||||
j=`uci add vtun default`
|
||||
j='uci commit vtun'
|
||||
config_load vtun
|
||||
fi
|
||||
|
||||
# Remove the current vtun config file
|
||||
mkdir -p /tmp/vtun
|
||||
rm -f $CLIENT_CONF
|
||||
|
||||
# config_foreach network_config network
|
||||
config_foreach options_config options "$CLIENT_CONF"
|
||||
config_foreach default_config default "$CLIENT_CONF"
|
||||
config_foreach to_server_config server "$CLIENT_CONF"
|
||||
|
||||
# STARTUP CLIENT TO SERVER CONNECTIONS
|
||||
|
|
|
@ -121,7 +121,7 @@ $header = <<EOF;
|
|||
content += "Signal: N/A<br/>";
|
||||
}
|
||||
content += "Noise: " + e.entries[0].dataPoint.y[1] + "dBm<br/>";
|
||||
content += "SNR: " + e.entries[0].dataPoint.m + "dBm<br/>";
|
||||
content += "SNR: " + e.entries[0].dataPoint.m + "dB<br/>";
|
||||
content += "TX Rate: " + e.entries[0].dataPoint.tx_rate + "Mbps<br/>";
|
||||
content += "TX MCS: " + e.entries[0].dataPoint.tx_mcs + "<br/>";
|
||||
content += "RX Rate: " + e.entries[0].dataPoint.rx_rate + "Mbps<br/>";
|
||||
|
@ -144,7 +144,9 @@ $header = <<EOF;
|
|||
\$.getJSON("/cgi-bin/signal.json?device=$parms{device}", function (result) {
|
||||
chart.options.data[0].dataPoints = result[0];
|
||||
// chart.options.data[1].dataPoints = result[1];
|
||||
chart.render();
|
||||
if(result.constructor === Array) {
|
||||
chart.render();
|
||||
};
|
||||
});
|
||||
};
|
||||
|
||||
|
@ -203,7 +205,7 @@ $parms{device}="" if(!/$parms{device}/ ~~ @files);
|
|||
|
||||
# default to "Strongest Signal" for Realtime
|
||||
if(! $parms{device} and $parms{realtime}) {
|
||||
$page = $page . "<option selected value='strongest'>Strongest Signal</option>";
|
||||
$page = $page . "<option selected value='strongest'>Average signal for all connected stations</option>";
|
||||
}
|
||||
|
||||
$firstSel=1;
|
||||
|
|
|
@ -93,7 +93,7 @@ if parms.realtime then
|
|||
end
|
||||
-- get strongest signal
|
||||
s=iwinfo["nl80211"].signal(wifiiface)
|
||||
m=tonumber(n)-tonumber(s)
|
||||
m=tonumber(s)-tonumber(n)
|
||||
if s==0 then
|
||||
s="null"
|
||||
end
|
||||
|
|
|
@ -219,7 +219,7 @@ if string.find(nixio.getenv("QUERY_STRING"):lower(),"services=1") then
|
|||
hfile:close()
|
||||
for pos,val in pairs(lines) do
|
||||
local service={}
|
||||
local link,protocol,name = string.match(val,"^(.*)|(.+)|(.*)\t+%s+.*")
|
||||
local link,protocol,name = string.match(val,"^([^|]*)|(.+)|([^\t]*)\t#.*")
|
||||
if link and protocol and name then
|
||||
service['link']=link
|
||||
service['protocol']=protocol
|
||||
|
|
|
@ -102,7 +102,7 @@ name (if known) of the device accessing this page.
|
|||
<p>
|
||||
The right column contains the signal strength reading and other attributes of
|
||||
your node. The <b>Signal/Noise/Ratio</b> is a reading of the strongest neighbor Mesh RF signal
|
||||
strength in dBm, and it is available only when the node is in a Mesh or Client
|
||||
strength (in dBm) from all connected stations, and it is available only when the node is in a Mesh or Client
|
||||
configuration. The <strong>Auto</strong> button will take you to an
|
||||
automatically refreshing display of the current signal strength and an average
|
||||
of the last 20 readings. This is provided as an aid to assist in antenna
|
||||
|
@ -142,7 +142,7 @@ temporary files. Memory is the amount of RAM available for running processes.
|
|||
|
||||
<br><br><hr>
|
||||
<a name=charts><h2>Charts Page</h2></a>
|
||||
<p>This page shows RF signal information in both a realtime and an archived view. The default view shows the STRONGEST RF signal in realtime.<br>
|
||||
<p>This page shows RF signal information in both a realtime and an archived view. The default view shows the Average signal of all connected stations in realtime.<br>
|
||||
Below the node name, there will be a few control buttons:<br>
|
||||
<ul>
|
||||
<li><strong>Archive</strong>: takes you to the charts for any archived signal data on this node.</li>
|
||||
|
|
Loading…
Reference in New Issue