a18e2c4f6638f3d1f412bc6691fabbde5fe9c952
[project/luci.git] / applications / luci-mmc_over_gpio / luasrc / model / cbi / mmc_over_gpio.lua
1 --[[
2
3 LuCI mmc_over_gpio
4 (c) 2008 Yanira <forum-2008@email.de>
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 ]]--
15
16 m = Map("mmc_over_gpio", translate("mmc_over_gpio"),
17 translate("mmc_over_gpio_desc"))
18
19 s = m:section(TypedSection, "mmc_over_gpio", translate("settings"))
20 s.addremove = true
21 s.anonymous = true
22
23 s:option(Flag, "enabled", translate("enabled", "Enable"))
24
25 s:option(Value, "name", translate("name"))
26
27 pin = s:option(Value, "DI_pin", translate("DI_pin"))
28 for i = 0,7 do pin:value(i) end
29
30 pin = s:option(Value, "DO_pin", translate("DO_pin"))
31 for i = 0,7 do pin:value(i) end
32
33 pin = s:option(Value, "CLK_pin", translate("CLK_pin"))
34 for i = 0,7 do pin:value(i) end
35
36 pin = s:option(Value, "CS_pin", translate("CS_pin"))
37 for i = 0,7 do pin:value(i) end
38
39 s:option(Value, "mode", translate("mode"))
40
41 return m