Dlink DWL-G122 C1 works (rt73 drivers) + selfmade reflector

Post Reply
Message
Author
User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

Dlink DWL-G122 C1 works (rt73 drivers) + selfmade reflector

#1 Post by MU »

This is a wireless USB-adapter, costs 30 Euro in germany.
This first message describes some tests I made.
Read the second message for a short summary.

My tests also resulted in a small wizard:
http://murga-linux.com/puppy/viewtopic. ... 6084#96084


You need a new KERNELMODULE :!:
See the message about my wizard.

You can ignore the rest of this thread, except you look for an easy to use "antenna" (reflector).

--------------------------
---------------------------------------
old stuff following
----------------------------------------
-------------------------
There are different revisions of the Dlink DWL-G122 using different chipsets:
http://support.dlink.com/products/revis ... d=DWL-G122

A1:
A2:
B1:
C1: rt73
D1:

I have C1, so to load the kernelmodule, in a consolewindow I type (Puppy 2.12):
modprobe rt73

To check if it was recognized:
First, I activate it:
ifconfig rausb0 up

Now I check, if it was recognized:
ifconfig

This lists 3 entries (I also have an ethernet card):
sh-3.00# ifconfig

Code: Select all

eth0      Link encap:Ethernet  HWaddr 00:0F:B5:F8:E0:76  
          inet addr:192.168.123.164  Bcast:192.168.123.255  Mask:255.255.255.0
          UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:24838 errors:0 dropped:0 overruns:0 frame:0
          TX packets:25186 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:18264168 (17.4 MiB)  TX bytes:10647303 (10.1 MiB)
          Interrupt:4 Base address:0x2000 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:17 errors:0 dropped:0 overruns:0 frame:0
          TX packets:17 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:1480 (1.4 KiB)  TX bytes:1480 (1.4 KiB)

rausb0    Link encap:Ethernet  HWaddr 00:19:5B:3A:B7:96  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:20 errors:0 dropped:0 overruns:0 frame:0
          TX packets:40 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:771059 (752.9 KiB)  TX bytes:784656 (766.2 KiB)

I see rausb0, very good.
Now I scan for networks:
iwlist scan

Code: Select all

sh-3.00# iwlist scan
lo        Interface doesn't support scanning.

eth0      Interface doesn't support scanning.

rausb0    Scan completed :
          Cell 01 - Address: 00:17:9A:61:B0:B9
                    ESSID:"Hamburg"
                    Mode:Managed
                    Channel:11
                    Encryption key:off
                    Bit Rates:130 Mb/s
          Cell 02 - Address: 00:A0:C5:DA:21:86
                    ESSID:"ArcorWirelessLANWgod"
                    Mode:Managed
                    Channel:6
                    Encryption key:on
                    Bit Rates:6 Mb/s
If I type that twice, I see 2 networks.
When I typed it once, I only saw "Hamburg".

So what must be done next?
I tried the WAG-wizard in Puppy too.
But it showed no networks, just if I typed ifconfig rausb0 up from time to time in a console, the WAG-wizard detected the networks, too.
For this reason at moment I try to learn how to set up this piece in the console.
This will allow me to give rarsa feedback for the wizard, and I also want to learn how things work.

To be continued...

connect to "Hamburg":
iwconfig rausb0 essid Hamburg mode Managed

Code: Select all

ifconfig:
rausb0    Link encap:Ethernet  HWaddr 00:19:5B:3A:B7:96  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4238 errors:0 dropped:0 overruns:0 frame:0
          TX packets:573 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1337182 (1.2 MiB)  TX bytes:1609320 (1.5 MiB)

dhcpcd rausb0 <-- ERROR: this disconnects from Hamburg after 60 secs.

Ok, this is better:
ifconfig rausb0 192.168.0.12 broadcast 192.168.0.255 netmask 255.255.255.0

Now I get:
ifconfig

Code: Select all

rausb0    Link encap:Ethernet  HWaddr 00:19:5B:3A:B7:96  
          inet addr:192.168.0.12  Bcast:192.168.0.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1343 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4259 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1551467 (1.4 MiB)  TX bytes:1940940 (1.8 MiB)

So there seems to be a connection, but I cannot access internet.
But the permanent LED is not litten, there is only blinking one permanently.
Maybe I should not try it in the middle of the night?
If it is a public hotspot, it might be online during daytime only.
Time to sleep now...

related links:
http://www.murga-linux.com/puppy/viewtopic.php?t=14252
http://dotpups.de/dotpups/Wifi/drivers- ... README.txt
http://www.ubuntuforums.org/showthread. ... 422&page=2
Last edited by MU on Mon 12 Feb 2007, 00:07, edited 7 times in total.

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#2 Post by MU »

ok, made a crosscheck in Windows XP, same result.
So Puppy seems to work ok.


Short instructions on how to create a connection in a hotel, I use the test-values from an unknown network in Hamburg.
Next week I can verify that it really works in a hotel.

1.) If you go to a hotel, and want to find out what wireless network it has:
Type this in a consolewindow:

modprobe rt73
ifconfig rausb0 up
iwlist scan


Now you will be listed your networks, among them the one of your hotel. Lets assume my "Hamburg" result is our hotel-network.

Code: Select all

          Cell 02 - Address: 00:17:9A:61:B0:B9
                    ESSID:"Hamburg"
                    Mode:Managed
                    Channel:11
                    Encryption key:off
                    Bit Rates:6 Mb/s
Now to connect to Hamburg:

iwconfig rausb0 essid Hamburg mode Managed
rm -f /etc/dhcpc/dhcpcd-*.pid
dhcpcd rausb0


Now you should be able to surf webpages.


2.) Once you know the values for your network, the steps are shorter, and can be run from a script:

Code: Select all

#!/bin/bash

modprobe rt73
ifconfig rausb0 up
iwconfig rausb0 essid Hamburg mode Managed
rm -f /etc/dhcpc/dhcpcd-*.pid
dhcpcd rausb0
Save it as /root/hotel
Make it executable:
chmod 755 /root/hotel

Then drag it on your desktop.
Mark

kirk
Posts: 1553
Joined: Fri 11 Nov 2005, 19:04
Location: florida

#3 Post by kirk »

Mark,

I had a version B1 (ralink rt2570). The lights didn't seem to work right on it ether, But other than that it was fine.

Have you tried Rutilt?

Rickrandom
Posts: 195
Joined: Sat 21 Jan 2006, 05:35
Location: Bedfordshire, UK

#4 Post by Rickrandom »

I thought I was dreaming when MU asked, not answered, a question, but then I read on and found it was rhetorical, and he answered his own question.

Normal service has been resumed. :)

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#5 Post by MU »

Kirk, yes, but with rutilt I also must run
ifconfig rausb0 up

But when I activate one of the found networks, rutilt seems to freeze.
The processor load is extremely high, and it does not react any more.

Rickrandom: grin ;)

Mark

kirk
Posts: 1553
Joined: Fri 11 Nov 2005, 19:04
Location: florida

#6 Post by kirk »

Oh, yes the ifconfig rausb0 up has to be done, but I'm surprised Rutilt is giving you a problem. It has special support for Ralink. I guess the rt73 driver is kind of new though. Romain the developer has been very good about fixing bugs, if you want you can email him: spy84464 at hotmail.com

P.S. Puppy 2.13 has the latest version of Rutilt. The one in 2.12 had a few bugs.

Now that you've got USB wifi, check out some of this crazy stuff:

http://www.usbwifi.orcon.net.nz/

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#7 Post by MU »

This is the startscript I use in the hotel.
I added these commands to /etc/rc.d/rc.muppy-network
This script is run from rc.local.

Code: Select all

ifconfig rausb0 up
sleep 2
iwlist scan 


iwconfig rausb0 essid default mode Managed 

sleep 1
rm -f /etc/dhcpc/dhcpcd-*.pid
dhcpcd rausb0  &
Note that it does not contain the "modprobe rt73", so it seems that Puppy detected it automatically.

"iwlist scan" is not required, I think, I just have it for tests.


The wireless signal is weak in this room.

I have built a simple reflector to gain 4 db (before: 59, after: 63).
More important: It also seems to get less dropouts now (without it, the Link-quality drops to 33 often, now 41 seldom, but I must test over a longer period). Lower than 36 is unusable.

Used a carton with aluminum-foil on it.
It has the size of an opened CD-case, and is opened by 90 degrees.
I have placed it maybe 6 cm behind the wlan-usb-stick, that stands in the stand delivered with it.

To find the best position and orientation, run this command in a console-window:

Code: Select all

while [ 1 ];do iwconfig rausb0| grep Quality ;sleep 5;done
It displays the Link-quality every 5 seconds, so move the reflector, until you get the highest quality :)

Mark
Last edited by MU on Wed 07 Feb 2007, 22:47, edited 3 times in total.

kirk
Posts: 1553
Joined: Fri 11 Nov 2005, 19:04
Location: florida

#8 Post by kirk »

Something else, you probably know, but I'll mention it any way :). If your trying to associate with a weak access point, dropping your rate down to 1MB will give you a better chance of connecting. If your just surfing, you won't notice much difference.

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#9 Post by MU »

here is a painting of the reflector:

Image

Mark

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#10 Post by MU »

Kirk, how can I reduce it?

Thanks for the tip :)
Mark

kirk
Posts: 1553
Joined: Fri 11 Nov 2005, 19:04
Location: florida

#11 Post by kirk »

try,

iwconfig rausb0 rate 1mb

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#12 Post by MU »

ok, will try tomorrow, already midnight here :?
Must get up early :roll:
Many thanks, I'll report back tomorrow evening :)

I also bought a Ravioli can, so more reflector-tests might follow in the next days :)

Mark

John Doe
Posts: 1681
Joined: Mon 01 Aug 2005, 04:46
Location: Michigan, US

#13 Post by John Doe »

MU wrote:I also bought a Ravioli can, so more reflector-tests might follow in the next days :)
Do you have "pringles" (potato chips) in Germany?

http://www.elivrari.ro/images/PRINGLES% ... IGINAL.jpg

We always used those to make yagi shotgun antennas.

http://www.google.com/search?q=yagi+pringles

The diameter is just right for the 2.4ghz wavelength.

This post has the math for determining the collector placement:
http://www.oreillynet.com/cs/weblog/view/wlg/448

Best of Luck.

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#14 Post by MU »

yes we have, will give it a try :)

Thanks and good night, Mark

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#15 Post by MU »

kirk wrote:try,

iwconfig rausb0 rate 1mb
I tried
ifconfig rausb0 up rate 100000
But it still uses higher rates.

However it seems to work well with the reflector.
Only for 2 hours today I had problems:
though I had a good link-quality of 61, I was assigned no inet-adress.

But it seems, maybe there was someone working at the router or so.
For some minutes, ifconfig showed these values:

Code: Select all

rausb0    Link encap:Ethernet  HWaddr 00:19:5B:3A:B7:96  
          inet addr:0.0.39.16  Bcast:255.255.255.255  Mask:0.0.0.0
          UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:595 errors:0 dropped:107 overruns:107 frame:107
          TX packets:27 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1698484 (1.6 MiB)  TX bytes:97572 (95.2 KiB)
That did not work.

Now, later, I got these working values:

Code: Select all

rausb0    Link encap:Ethernet  HWaddr 00:19:5B:3A:B7:96  
          inet addr:192.168.2.169  Bcast:192.168.2.255  Mask:255.255.255.0
          UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1022 errors:0 dropped:108 overruns:108 frame:108
          TX packets:40 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1732708 (1.6 MiB)  TX bytes:99252 (96.9 KiB)
Also bought Pringles today, but had no time yet, to build an antenna from the can. Will try it in the next days :)

Mark

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#16 Post by MU »

I made some small tests adding directors to my antenna, as you know them from old yagi antennas for TV on the roof of a house (building them was my hobby over 10 years ago).
I also changed the reflector-layout to get more bundled waves.

I got maybe 2% higer values, but also the dropouts were worse.

In a room, you have many interferences, so yagi-antennas are no good solution. They require very "clean" waves for good results.
They are only good, if you have direct sight to the sender (for long distances).
If the sender is in another room, simple reflectors as above are the better choice.

Mark

kirk
Posts: 1553
Joined: Fri 11 Nov 2005, 19:04
Location: florida

#17 Post by kirk »

I tried
ifconfig rausb0 up rate 100000
But it still uses higher rates.
No, try:

Iwconfig rausb0 rate 1mb

This works with most drivers, though some don't support rate changing. It works with my rt2570.

tempestuous
Posts: 5464
Joined: Fri 10 Jun 2005, 05:12
Location: Australia

#18 Post by tempestuous »

I believe the correct syntax for the "rate" parameter with iwconfig is "k" - kilobits/sec, "M" megabits/sec, or "G" gigabits/sec.
So -

iwconfig rausb0 rate 1M

I have found that modern wifi adaptors can sometimes work more reliably by forcing them back to the old 11Mbs "B" mode. In this case -

iwconfig rausb0 rate 11M

Post Reply