Author: Felix Fietkau <nbd@openwrt.org> Date: Tue May 27 13:56:12 2008 +0200 rename src/ to luasrc/
25 lines
591 B
Lua
25 lines
591 B
Lua
module("luci.statistics.rrdtool.definitions.wireless", package.seeall)
|
|
|
|
function rrdargs( graph, host, plugin, plugin_instance )
|
|
|
|
dtypes = { "signal_power", "signal_noise" }
|
|
|
|
opts = { }
|
|
opts.sources = { }
|
|
opts.image = graph:mkpngpath( host, plugin, plugin_instance, "wireless" )
|
|
opts.title = host .. ": WLAN Signal"
|
|
opts.rrd = { "-v", "dBm" }
|
|
opts.colors = {
|
|
signal_power = '0000ff',
|
|
signal_noise = 'ff0000'
|
|
}
|
|
|
|
for i, dtype in ipairs(dtypes) do
|
|
opts.sources[i] = {
|
|
name = dtype,
|
|
rrd = graph:mkrrdpath( host, plugin, plugin_instance, dtype )
|
|
}
|
|
end
|
|
|
|
return opts
|
|
end
|