* Core translation
[project/luci.git] / modules / admin-core / luasrc / model / cbi / admin_wifi / devices.lua
1 --[[
2 LuCI - Lua Configuration Interface
3
4 Copyright 2008 Steven Barth <steven@midlink.org>
5
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9
10         http://www.apache.org/licenses/LICENSE-2.0
11
12 $Id$
13 ]]--
14 m = Map("wireless", translate("devices", "Geräte"), translate("a_w_devices1", 
15         "An dieser Stelle können eingebaute WLAN-Geräte konfiguriert werden."))
16
17 s = m:section(TypedSection, "wifi-device", "")
18 --s.addremove = true
19
20 en = s:option(Flag, "disabled", translate("enable", "Aktivieren"))
21 en.enabled = "0"
22 en.disabled = "1"
23
24 t = s:option(ListValue, "type", translate("type", "Typ"))
25 t:value("broadcom")
26 t:value("atheros")
27 t:value("mac80211")
28 t:value("prism2")
29 --[[
30 require("luci.sys")
31 local c = ". /etc/functions.sh;for i in /lib/wifi/*;do . $i;done;echo $DRIVERS"
32 for driver in luci.sys.execl(c)[1]:gmatch("[^ ]+") do
33         t:value(driver)
34 end
35 ]]--
36
37 mode = s:option(ListValue, "mode", translate("mode", "Modus"))
38 mode:value("", "standard")
39 mode:value("11b", "802.11b")
40 mode:value("11g", "802.11g")
41 mode:value("11a", "802.11a")
42 mode:value("11bg", "802.11b+g")
43 mode.rmempty = true
44
45 s:option(Value, "channel", translate("a_w_channel", "Funkkanal"))
46
47 s:option(Value, "txantenna", translate("a_w_txantenna", "Sendeantenne")).rmempty = true
48
49 s:option(Value, "rxantenna", translate("a_w_rxantenna", "Empfangsantenne")).rmempty = true
50
51 s:option(Value, "distance", translate("distance", "Distanz"),
52         translate("a_w_distance1", "Distanz zum am weitesten entfernten Funkpartner (m)")).rmempty = true
53
54 s:option(Value, "diversity", translate("a_w_diversity", "Diversität")):depends("type", "atheros")
55         
56 country = s:option(Value, "country", translate("a_w_countrycode", "Ländercode"))
57 country.optional = true
58 country:depends("type", "broadcom")
59
60 maxassoc = s:option(Value, "maxassoc", translate("a_w_connlimit", "Verbindungslimit"))
61 maxassoc:depends("type", "broadcom")
62 maxassoc.optional = true
63
64 return m