Leds have been tested on rb111/112 and rb153
[openwrt.git] / target / linux / adm5120 / base-files / lib / adm5120.sh
1 #!/bin/sh
2 #
3 # Copyright (C) 2007 OpenWrt.org
4 #
5 # $Id$
6 #
7
8 board_name=""
9 status_led=""
10 sys_mtd_part=""
11
12 adm5120_detect() {
13 board_name=$(awk 'BEGIN{FS="[ \t]+:[ \t]"} /system type/ {print $2}' /proc/cpuinfo)
14
15 case "$board_name" in
16 "Cellvision"*)
17 status_led="status"
18 sys_mtd_part="firmware"
19 ;;
20 "Compex"*)
21 status_led="diag"
22 case "$board_name" in
23 *-WRT)
24 sys_mtd_part="trx"
25 ;;
26 *)
27 sys_mtd_part="partition1"
28 ;;
29 esac
30 ;;
31 "Edimax"*)
32 status_led="power"
33 sys_mtd_part="firmware"
34 ;;
35 "Infineon"*)
36 sys_mtd_part="firmware"
37 ;;
38 "Mikrotik"*)
39 status_led="power"
40 ;;
41 "ZyXEL"*)
42 status_led="power"
43 sys_mtd_part="trx"
44 ;;
45 *)
46 ;;
47 esac
48 }
49
50 adm5120_detect
This page took 0.052988 seconds and 5 git commands to generate.