# Netgear WG511T with 2005.0 x86

## maxweld

I have Gentoo 2005.0 x86 running on an IBM Thinkpad 770 (standard Genkernel). It is working fine with a standatrd network connection, but I now want to make it more mobile with the Netgear WG511T wireless card that I have.

I am confused by the possible driver/package options that seem to be in use for this card, and seek some clarification.

Should I use wireless-tools or wpa-supplicant?

Do I still need madwifi, and if so, which bits of madwifi?

Are there any tricks or gotchas?

Are there any sample configs available for the suggested combination?

Thanks in advance

----------

## Specialized

The Netgear WG511T uses the atheros-chipset, so you will have to use the madwifi-driver.

I don't think you need the madwifi-tools.

The wireless-tools I would emerge, because if you want to access to a Wlan just for one time it's easier to use the tools instead of the wpa_supplicant.

The wpa_supplicant you need if your network is protected with an wpa-key, but you can use it for all kind of protection.

It's very usefull if you want to access to different Accesspoints.

You have to update your baselayout to >1.11 and add this to your /etc/conf.d/net:

```
modules=( "wpa_supplicant" )

wpa_supplicant_ath0="-Dmadwifi"

wpa_timeout_ath0=60 
```

then emerge the wpa_supplican, do rc-update add wpa_supplicant default and add your accesspoints to the /etc/wpa_supplicant.conf.

In my case it looks like this:

```
network={

   ssid="my essid"

   scan_ssid=1

   key_mgmt=WPA-PSK

   pairwise=TKIP

   psk="my keyword"

   priority=5

}
```

But there is a very good wpa_supplicant.conf.example.

By adding more network={ ... to the .conf you can add as much accesspoints as you want.

----------

## maxweld

Thanks Specialised

As I only want to use this at home, with WPA security, have gone for the wpa_supplicant, although took your advice and have emerged wireless-tools also.

At boot up, I now get the following, presumably because I have removed the ethernet network card to put in the wireless card:

```
* Starting eth0

*   Loading networking modules for eth0

*     modules: wpa_supplicant essidnet iptunnel ifconfig dhcpcd apipa

*       wpa_supplicant provides wireless

*       ifconfig provides interface

*       dhcpcd provides dhcp

*   Bringing up eth0

*     dhcp

*       eth0 does not exist
```

I then get, a little later after starting the HAL

```
*  ERROR:   Problem starting needed services

*                "netmount" was not started

*  Starting wpa_supplicant ...

*     eth1 ...

eth1: unknown interface: No such device
```

I am a little stumped. I have used your code for the .etc.conf.d/net and virtually identical code for the /etc/wpa_supplicant.conf, changing just the ssid and psk values. Why does it start eth1?

I am also not sure if the Netgear card is being recognised, as lspci does not show it at all. Is there perhaps something more fundamental at fault. 

I hope this means something to somebody.

----------

## widan

 *maxweld wrote:*   

> I then get, a little later after starting the HAL
> 
> ```
> *  ERROR:   Problem starting needed services
> 
> ...

 

Your Atheros card will show up as ath0, not eth1, so your net init script should be /etc/init.d/net.ath0, not net.eth1.

 *maxweld wrote:*   

> I am also not sure if the Netgear card is being recognised, as lspci does not show it at all.

 

lspci will show your cardbus bridge, but I don't think it will show the cards themselves. Try "cardctl ident", it should give you some info about the card.

EDIT: It seems that Cardbus cards do show up in lspci (but not in "cardctl ident"), but older PCMCIA cards only show up in "cardctl ident".Last edited by widan on Wed Jul 27, 2005 4:43 pm; edited 2 times in total

----------

## Specialized

Can you post your /etc/conf.d/net?

----------

## maxweld

Thanks Specialized & widan

/etc/conf.d/net is as follows (other lines commented out with leading #):

```

modules=( "wpa_supplicant" ) 

wpa_supplicant_ath0="-Dmadwifi" 

wpa_timeout_ath0=60 
```

In /etc/init.d there are the following:

```
lrwxrwxrwx  1 root root     6 Jul 23 22:45 net.ath0 -> net.lo

lrwxrwxrwx  1 root root     6 Jul 23 22:45 net.eth0 -> net.lo
```

```
# cardctl ident

Socket 0:

  no product info available

Socket 1:

  no product info available
```

The card is flashing slowly in the socket  :Confused: 

----------

## Specialized

Have you got the setup for your wirelesscard in the /etc/conf.d/wireless?

If not, try adding this to your /etc/conf.d/net:

```
iface_ath0="dhcp"

dhcpcd_ath0="-t 2 -N -HD"

wireless_essid_ath0="any"

wireless_mode_ath0="Managed"

```

After that you got to link your net.ath0 to the net.eth0:

```
cd /etc/init.d/

ln -s net.eth0 net.ath0

rc-update add net.ath0 default

```

If it is an PCMCIA-Card, have you  installed it correctly and have you emerged the pcmcia-cs?

----------

## maxweld

Hi Specialized - thanks for persisting.

I have just seen your post and do not have the time tonight to give it my full attention. However I did try one thing - simply running the rc-update command that you suggest without changing anything else. 

now get : 

```
merlot ~ # rc

 * Starting ath0

 *   Loading networking modules for ath0

 *     modules: wpa_supplicant essidnet iptunnel ifconfig dhcpcd apipa

 *       wpa_supplicant provides wireless

 *       ifconfig provides interface

 *       dhcpcd provides dhcp

 *   Bringing up ath0

 *     Configuration not set for ath0 - assuming dhcp

 *     dhcp

 *       ath0 does not exist                                              [ !! ]

 * Starting eth0

 *   Loading networking modules for eth0

 *     modules: wpa_supplicant essidnet iptunnel ifconfig dhcpcd apipa

 *       wpa_supplicant provides wireless

 *       ifconfig provides interface

 *       dhcpcd provides dhcp

 *   Bringing up eth0

 *     Configuration not set for eth0 - assuming dhcp

 *     dhcp

 *       eth0 does not exist                                              [ !! ] 

 * ERROR:  Problem starting needed services.

 *         "netmount" was not started.
```

eth0 is not starting as the Ethernet card is removed. If I reinsert and run 'rc' again, lan connection is restored and eth0 works fine. It looks like the Wireless card is not being recognised. Is this a MadWifi problem?

I am also including contents of /etc/wpa_supplicant.conf:

```
ctrl_interface=/var/run/wpa_supplicant

ctrl_interface_group=wheel

network={

        ssid="testessid"

        scan_ssid=1

        key_mgmt=WPA-PSK

        pairwise=TKIP

        psk="abcd345"

        priority=5

}

```

I will also try your other suggestions as soon as I can, and let you know what they reveal?

Thanks again

----------

## sinisterdomestik

so far, yalls posts have helped me out alot. i get mine as far as 

```
root@BlackBeauty:~ /etc/init.d/net.ath0 start

 * Caching service dependencies ...                                                                         [ ok ]

 * Starting ath0

 *   Configuring wireless network for ath0

 *   Couldn't associate with any access points on ath0

 *   Failed to configure wireless for ath0
```

 gonna try a coupla things, but no luck yet.

/EDIT

before i forget, i cant rc-update wpa_supplicant 

```
root@BlackBeauty:/etc/init.d rc-update add wpa_supplicant default

 * /sbin/rc-update: /etc/init.d/wpa_supplicant not found; aborting.
```

 any reason for that??

----------

## Specialized

Which baselayout are you using?

----------

## maxweld

Baselayout is version 1.11.13

----------

## Specialized

Sorry I meant sinisterdomestik. If your not already using 1.11.* you should upgrade.

@maxweld: Had the changes in /etc/conf.d/net any effects?

----------

## maxweld

Hi Specialized.

I added the additional lines you suggested to the /etc/conf.d/net file but there was no discernable change.

Other things I have attempted or observed are:

1. If I tail dmesg, there are no lines created when I insert the Netgear card. If I insert a borrowed Belkin card it is recognised and multiple lines are added if I insert or remove the card. It is obviously recognised. I am not sure what I should expect when I insert the Netgear card, but there is nothing.

2. The madwifi README file suggests using the following line to turn debugging on. When I execute it, I get dubious results:

```
# sysctl -w dev.ath.debug=0xXXX

error: "Invalid arguement" setting key "dev.ath.debug"
```

3. When the Belkin card is inserted I get details for eth0 with iwconfig. However if the Netgear card is inserted, iwconfig reports nothing for either eth0 or ath0. 

```
# iwconfig

lo           no wireless extensions.
```

It is as though the Netgear card is not recognised at all. Its little green light is flashing slowly, but thats it.

I do not know if any of the above will shed any light. Here's hoping ... 

Thanks

----------

## widan

Do you have errors when you insert the Netgear, or nothing at all ? What does lspci say about the card (apparently it's Cardbus, not PCMCIA, and so won't show with cardctl, but it should appear in lspci) ? Check that the ath_pci module is loaded. If it is not, try to "modprobe ath_pci", and recheck dmesg. There should be something, if only an error. Also you should have some lines saying:

```
ath_hal: 0.9.14.9 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413)

wlan: 0.8.6.0 (EXPERIMENTAL)

ath_rate_sample: 1.2

ath_pci: 0.9.6.0 (EXPERIMENTAL)
```

The lspci should give you some info about the chipset (ARxxxx). Check that this chipset is in the ath_hal list. Maybe you got a newer version of the chipset, and you just need a newer version of madwifi (actually, of the ath_hal). Try using the "madwifi-bsd" driver, it's more up-to-date than the "madwifi-driver".

```
# sysctl -w dev.ath.debug=0xXXX

error: "Invalid arguement" setting key "dev.ath.debug"
```

0xXXX is not a valid hexadecimal number... The debug value is a bitfield I think, so try 0xFFFFFFFF to enable all the debugging features.

----------

## maxweld

ath_pci module is loaded during startup. dmesg shows the following lines with or without the card being inserted at startup

```
ath_hal: module license 'Proprietary' taints kernel.

ath_hal: 0.9.14.9 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413)

wlan: 0.8.4.5 (EXPERIMENTAL)

wlan: mac acl policy registered

ath_rate_amrr: no version for "ether_sprintf" found: kernel tainted.

ath_rate_amrr: 0.1

ath_rate_onoe: 1.0

ath_pci: 0.9.4.12 (EXPERIMENTAL)
```

If I insert or remove the card no additional lines appear in dmesg output.

output from both lspci or cardctl ident shows nothing useful, even if I use -v or -vv

```
merlot ~ # lspci

0000:00:00.0 Host bridge: Intel Corporation 430TX - 82439TX MTXC (rev 01)

0000:00:01.0 Bridge: Intel Corporation 82371AB/EB/MB PIIX4 ISA (rev 01)

0000:00:01.1 IDE interface: Intel Corporation 82371AB/EB/MB PIIX4 IDE (rev 01)

0000:00:01.2 USB Controller: Intel Corporation 82371AB/EB/MB PIIX4 USB (rev 01)

0000:00:01.3 Bridge: Intel Corporation 82371AB/EB/MB PIIX4 ACPI (rev 01)

0000:00:02.0 CardBus bridge: Texas Instruments PCI1250 (rev 01)

0000:00:02.1 CardBus bridge: Texas Instruments PCI1250 (rev 01)

0000:00:03.0 VGA compatible controller: Trident Microsystems Cyber 9397 (rev f3)

merlot ~ # cardctl ident

Socket 0:

  no product info available

Socket 1:

  no product info available

merlot ~ #

```

I will get around to setting a correct debug address and exploring with that later today.

----------

## maxweld

well I can get no response from the Netgear card. lspci shows nothing.

 I can get a response from a Belkin card.

```
# cardctl ident

Socket 1:

  product info: " belkin", 11mbps .... etc.
```

 I have also managed to get a response from the Netgear card on another machine under Windows XP  :Sad: 

I am starting to wonder if this is a problem with my Laptop not recognising this type of card. I am not sure how to check on that. It is a IBM Thinkpad 770.

----------

