DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 12th May 2008
vi5in's Avatar
vi5in vi5in is offline
Real Name: Vivin Paliath
Port Guard
 
Join Date: May 2008
Location: Arizona
Posts: 17
Thanked 0 Times in 0 Posts
Default Netgear Rangemax Wireless-N (WN311T) on FreeBSD [solved]

I originally posted this on the PC-BSD forum. I haven't had much luck getting replies. I thought I'd post this here also. What follows is a summary of everything I tried:

I got a Netgear RangeMax Next Wireless-N PCI Adapter (WN311T). I plugged it in, and PC-BSD was unable to find it. So I figured I'd do an lspci:

Code:
tardis# lspci
00:00.0 Host bridge: Intel Corporation 82875P/E7210 Memory Controller Hub (rev 02)
00:01.0 PCI bridge: Intel Corporation 82875P Processor to AGP Controller (rev 02)
00:03.0 PCI bridge: Intel Corporation 82875P/E7210 Processor to PCI to CSA Bridge (rev 02)
00:1d.0 USB Controller: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #1 (rev 02)
00:1d.1 USB Controller: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #2 (rev 02)
00:1d.2 USB Controller: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #3 (rev 02)
00:1d.3 USB Controller: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #4 (rev 02)
00:1d.7 USB Controller: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB2 EHCI Controller (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev c2)
00:1f.0 ISA bridge: Intel Corporation 82801EB/ER (ICH5/ICH5R) LPC Interface Bridge (rev 02)
00:1f.1 IDE interface: Intel Corporation 82801EB/ER (ICH5/ICH5R) IDE Controller (rev 02)
00:1f.2 IDE interface: Intel Corporation 82801EB (ICH5) SATA Controller (rev 02)
00:1f.3 SMBus: Intel Corporation 82801EB/ER (ICH5/ICH5R) SMBus Controller (rev 02)
01:00.0 VGA compatible controller: nVidia Corporation NV31 [GeForce FX 5600] (rev a1)
02:01.0 Ethernet controller: Intel Corporation 82547EI Gigabit Ethernet Controller (LOM)
03:01.0 Ethernet controller: Marvell Technology Group Ltd. Unknown device 2a02 (rev 03)
03:02.0 Serial controller: 3Com Corp, Modem Division 56K FaxModem Model 5610 (rev 01)
03:03.0 Multimedia audio controller: Creative Labs SB Audigy (rev 03)
03:03.1 Input device controller: Creative Labs SB Audigy MIDI/Game port (rev 03)
03:03.2 FireWire (IEEE 1394): Creative Labs SB Audigy FireWire Port
03:04.0 Multimedia controller: Sigma Designs, Inc. REALmagic Hollywood Plus DVD Decoder (rev 02)
As you can see, the Ethernet Controller is from Marvell. I figured that I'd try and use ndisgen with the drivers supplied on the CD. I mounted the CD and found out that there were no .inf or .sys files. It was most probably in the .cab or .exe files. I wasn't sure if there was a way to extract cab files in PC-BSD and I wasn't going to find out now. So I fired up Wine and ran the setup files. The files were extracted to ~usename/.wine/drive_c/Program Files/NETGEAR/WN311T.

I cd'd to the directory and ran ndisgen. It complained of a syntax error in line 995. I opened up the .inf file in vi and noticed that there wasn't a ^M (CRLF on DOS/Win systems) on the last line. I removed all ^M with a substitution command (:%s/[CTRL+V][CTRL+M]//g (actually press the ctrl+v and ctrl+m)). I ran ndisgen and this time it was able to parse the file. However, when it tried to build the driver, I got the following error:

Code:
./windrv.h:147:4: unknown escape sequence '\p'
./windrv.h:147:4: unknown escape sequence '\H'
./windrv.h:312:4: unknown escape sequence '\p'
./windrv.h:312:4: unknown escape sequence '\H'
I opened up windrv.h and found that the offending lines contained unescaped backslash characters. I fixed the errors and started up ndisgen again. That's when I realized that when it would regenerate the header files, my changes would be overwritten. So I copied windrv.h to windrv2.h and ran ndisgen again. Right before it tells you to press any key to build, I copied windrv2.h over windrv.h and continued the build process. This time, it worked and it created a .ko file.

At this point, I noticed that there were .sys files. I wasn't sure which one to use, so I compiled modules for both. I kldloaded netmw145_sys.ko first, and the device showed up under Network Control. Unfortunately, I wasn't able to see any networks (I was able to with the D-Link, but unable to connect to the WPA protected network even after using wpa_supplicant). I kldunloaded the module and tried netmw143_sys.ko. This time I wasn't able to see ANY device. Fine. So I kldloaded BOTH of them. This time, I was able to see the device, but still unable to see any networks.

So that's where I stand right now. Any help in resolving this matter will be appreciated. Should I try to use the Marvell driver for this? Any other things I can try?

Update:

I checked out this page and it says that the driver is supposed to work (but makes no mention of the two sys files - I tried out the latest drivers on Netgear's site that the page links to. Same problem, although this time, both sys files loaded on their own will cause the card to be shown in the list of devices). I have another one of these cards running fine on a WinXP system. I will swap the card to see if it's a hardware problem. Oh yeah, and the light shows up on the card and it flashes while it tries to search for Wireless networks. But it doesn't find any.

Update:

I swapped out the cards with the XP machine. The new card I bought works fine, so I know it's not a hardware problem (the antenna also works fine). I'm going to keep researching this issue, but if anyone knows of anything else I can try, please do help.

Update:

I'm trying to use wpa_supplicant. I've set up /etc/wpa_supplicant.conf and I am running

Code:
wpa_supplicant -i ndis0 -c /etc/wpa_supplicant.conf
But I get:

Code:
ioctl[SIOCG80211, op 24, len 24576]: No space left on device
over and over again.

FIXED!!!

Ok, so I fixed it! (I hope it stays that way!) I really didn't do anything different. All I did was unload and then reload the modules after I ran wpa_supplicant.

Code:
network={
                    ssid="myssid"
                    psk="mypsk"
                   }
Then I kldloaded both the modules. Right after I did that, the blue network ball thing at the bottom-right showed a notification saying that the card is now associated. I am able to access the internet without any problems. All I have to do now is automate it. I have to edit my loader file to load the drivers and then add the following line to /etc/rc.conf:

Code:
wpa_supplicant_enable="YES"
Update

Ok, so another thing. I reinstalled by system and was unable to get it to work using my own instructions. *sigh*. But I found out the problem. Make sure you have this in your rc.conf:

Code:
if_ndis0="WPA DHCP"
wpa_supplicant_enable="YES"
This should be enough to help you start up wpa_supplicant on startup. If not, you might have to do this:

Code:
/usr/local/etc/rc.d/wpa_supplicant forcestart ndis0
/sbin/dhclient ndis0
This should bring it up. On my system, it doesn't start up automatically. I don't know why. So I have to use the above two commands.

Remember that there are two wpa_supplicant. Once is the binary, and the other is the startup script. For some reason, using the script works! I don't get the ioctl errors.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
HOWTO: Wireless with Intel 3945ABG/4965AGN on FreeBSD 8.0 vermaden Guides 4 28th July 2014 07:54 PM
FreeBSD 7.0: PCMCIA wireless NIC anomie FreeBSD General 5 19th July 2008 02:58 AM


All times are GMT. The time now is 04:01 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick