Topic: Determining WRT54G/GS model using nvram variables

Hi,

I got two wrt at home.

The WRT54G v2.0 has the following nvram variables :

boardrev=0x10
boardtype=0x0101
boardflags2=0
boardflags=0x0188
boardnum=42

And the WRT54G v.2.2 has the following :

boardrev=0x10
boardtype=0x0708
boardflags2=0
boardflags=0x0118
boardnum=42

So it seems that the identification can be done using only boardflags and boardtype. Can somebody paste me the nvram variables for a wrt54gs v1.1, a v3.0 and older if you have ?

Thanks a lof by advance

Re: Determining WRT54G/GS model using nvram variables

My GS v1.1 has following settings:

boardrev=0x10
boardtype=0x0708
boardflags2=0
boardflags=0x0318
boardnum=42

Re: Determining WRT54G/GS model using nvram variables

It would be great if we can get a general algorithm to extract the model from this two variables. Thanks a lot for posting the WRT54GS v1.1 infos smile

Re: Determining WRT54G/GS model using nvram variables

On a G v1.1:
boardtype=bcm94710dev
boardrev=
boardflags=
boardflags2=
boardnum=42

yes, all the rest of the board* variables are empty on this revision.

Mebbe we should compare wl0_corerev as well?
G v1.1 wl0_corerev=5
G v2.2 wl0_corerev=7


Thanks for the input!

Re: Determining WRT54G/GS model using nvram variables

This oughta work, but is incomplete (need some data for GS models yet):

#!/bin/ash
BF=$(nvram get boardflags)
BT=$(nvram get boardtype)

if [ "$BF" = "0x0118" ]
then
  echo "G2.2";
else
  if [ "$BF" = "0x0188" ]
  then
    echo "G2.0";
  else
    if [ "$BF" = "0x0318" ]
    then
      echo "GS1.1";
    else
      if [ "$BT" = "bcm94710dev" ]
      then
        echo "G1.1";
      fi;
    fi;
  fi;
fi;

Re: Determining WRT54G/GS model using nvram variables

well

I got here on Buffalo WBR-54G

nvram show |grep board
boardrev=0x10
boardtype=bcm94710ap
boardflags2=0
boardflags=0x0188
boardnum=42
boardtype_2=0

and on Toshiba WRC1000

boardtype=bcm94710r4
boardnum=100

and on Buffalo WBR2-G54S

boardrev=0x10
boardtype=0x0101
boardflags2=0
boardflags=0x0188
boardnum=00

Re: Determining WRT54G/GS model using nvram variables

Thanks a lot for all these contributions. In fact I was just looking for WRT54G relating variables, but I will put this informations on the wiki smile

Re: Determining WRT54G/GS model using nvram variables

My WRT54G v3.0 has the following specs:

boardrev=0x10
boardtype=0x0708
boardflags2=0
boardflags=0x0118
boardnum=42

Linksys WRT54G v3
OpenWrt 2.4.30 #1
White Russian RC2
:cool:

Re: Determining WRT54G/GS model using nvram variables

I have writen a script doing a task like that. The idea is to get information from nvram to guess hardware type. After that, all we need is mainly to get specific hardware values guested from hardwre modele (wireless, lan interface).

May be this script be completed now we know all specific nvram values.

Re: Determining WRT54G/GS model using nvram variables

Thanks _marc_ I forgot that you already wrote this kind of script. You are right, we only need informations about that. I added some nvram infos in the wiki.

Re: Determining WRT54G/GS model using nvram variables

I have made a summary table for all know values :
* please help to complete this table.
* we should insert a new table with interface names for each of them.

Re: Determining WRT54G/GS model using nvram variables

i have a wrt54gs v4 with the following nvram parameters set:

root@(none):/# nvram show | grep board | sort
size: 1495 bytes (31273 left)
boardflags2=0
boardflags=0x2758
boardnum=42
boardrev=0x10
boardtype=0x0467
root@(none):/# cat /proc/cpuinfo | grep cpu
cpu model               : BCM3302 V0.8
root@(none):/#

Re: Determining WRT54G/GS model using nvram variables

I use a WRT54GS 1.0 (?) router. The hardware identification is not straightforward: there's no version number and according to FAQ this means v1.0. The serial number starts with CGN1 and this also makes me think I have v1.0 here. But original Linksys firmware reported (http://192.168.1.1/SysInfo.htm ) "Hardware Version:2.0". The board has ADM switch on it.

_marc_ wrote:

* please help to complete this table.

Here's what I get:

boardflags2=0
boardflags=0x0388
boardnum=42
boardrev=0x10
boardtype=0x0101

cpu model               : BCM3302 V0.7

Re: Determining WRT54G/GS model using nvram variables

Output from a WRT54GSv3:

root@OpenWrt:~# nvram show | grep board | sort
size: 9997 bytes (22771 left)
boardflags2=0
boardflags=0x2758
boardnum=42
boardrev=0x10
boardtype=0x0467
root@OpenWrt:~# cat /proc/cpuinfo | grep cpu
cpu model               : BCM3302 V0.8

Seems like it's the same values that mistay is reporting on a v4.

15 (edited by mnezor 2005-12-27 22:53:21)

Re: Determining WRT54G/GS model using nvram variables

I got 2   wrt54gs v2.0

  output  ---> 

~# nvram show | grep board | sort

size: 15420 bytes (17348 left)
boardflags2=0
boardflags=0x0388
boardnum=42
boardrev=0x10
boardtype=0x0101

~# cat /proc/cpuinfo | grep cpu

cpu model               : BCM3302 V0.7

16 (edited by AllTimeSToneD 2006-01-05 23:21:09)

Re: Determining WRT54G/GS model using nvram variables

I got a WRT54G v2.2 running DD-WRT V23

output information:

~ # nvram show | grep board | sort
size: 24413 bytes (8355 left)
boardflags2=0
boardflags=0x0318
boardnum=42
boardrev=0x10
boardtype=0x0708

~ # cat /proc/cpuinfo | grep cpu
cpu model               : BCM3302 V0.7

boot_ver: v3.4
pmon_ver: 3.61.13.0


How good are the chances that my 2.2 is fitted with a 32mb module?
As my boardflag is that of the v1.1 (accourding to the wiki-list).

Re: Determining WRT54G/GS model using nvram variables

_marc_ wrote:

* please help to complete this table.

I have the WRT54G v3.1 router, currently running a slightly old version of the Freeman software. My reported values do not line up exactly with those found in the table at http://wiki.openwrt.org/OpenWrtDocs/Hardware/Linksys/WRT54G (section 1.1.8), so I thought I'd report them here on the off chance that they'll be of use. I bought the router at Best Buy about a year ago, and got quite lucky that I ended up with a <V3.1 router, considering I didn't check first.

nvram show | grep board | sort - reports the following:
boardflags2=0
boardflags=0x0318
boardnum=42
boardrev=0x10
boardtype=0x0708

grep cpu /proc/cpuinfo - reports the following:
cpu model : BCM3302 V0.7

The difference I note is the boardflags value; your table shows 0x0118 whereas mine reports 0x0318. Not sure if this is terribly handy info, but I thought I'd pass it along just in case.

Thanks for helping with open firmwares on these linksys (and other) devices.

-M