rajan72 / android-wifi-tether

Automatically exported from code.google.com/p/android-wifi-tether
0 stars 1 forks source link

Droid/ IPAD 2.2 rom issues, changing mac address for droid see also issue 350 #374

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Which device (manufacturer, type)?
Droid
Which firmware is installed?
2.2 rom from droid life (newest)kernel 2.6.32.9-g103d848android-build@apa26#1
buildnumber voles-userdebug 2.2 FR5F57 38829 test keys
What version of wireless tether are you using?
2.02
What steps will reproduce the problem?
1. start wireless tether with no device connected
2. monitor ssid info, it changes the mac address like every 30 seconds until 
device connects, this prevents the ipad from connecting most of the time
3. connect to another device, like xp laptop, mac address for droid stays fixed 
and then ipad will connect properly using dhcp

What is the expected output? What do you see instead?
ipad will not connect under regular starup, except sometimes right after 
changing access control, it will get the proper ip address and work, sometimes 
it gets the right ip address but still will not resolve names, i think because 
the mac address changes before safari can open a new site

Please provide any additional information below.
Sorry for the long post, hope this info helps,
hey, i think i know what the problem is, worked on this for hours today. i am 
usung the latest droid-life 2.2 rom (the one that is supposed to be a direct 
copy of 2.2)and it looks like wireless tether keeps changing the mac address it 
broadcasts while it is trying to connect. I watched this with a couple of 
wireless watchers while playing with the droid. Anyway, while watching the 
signals, I was able to see that mac address changing left and right until I was 
able to get a device connected. Once I connected my laptop (XP) then the mac 
address of the droid stopped changing and I was easily able to connect the ipad 
and other devices without a problem in the world. Before that, it was just pure 
luck of timing getting the ipad to connect, because I think when the mac 
address of the droid changed, the ipad took a dump and configures its own 
internal 169 address.

I know barnacle tether includes an option to set the mac address, maybe that is 
what is needed here too, because this problem happens even on the latest droid 
apk 2.02 or whatever it is. Please feel free to contact me for any additional 
info. I am writing this on a now tethered computer, but it was hard work, while 
streaming youtube on the ipad, so the connection works great once they connect. 
Before i figured this out, the ipad would find the wireless and then most of 
the time fault when trying to dhcp and instead of getting the right address, it 
would drop to the internal 169.xx.xx.xxx

I was also able to get it to connect once or twice by switching the access 
control on and off and such until the ipad connected,but i bet it is completely 
related to the changing mac address. I have been watching the stream for a half 
hour now and the mac address of the droid has stayed the same, before anything 
was connected, it would change every 30 seconds or so. Also, I rebooted just to 
the rom and only installed the 2.02 apk, nothing else but the stock droid apps, 
so hope that helps too.
I also noted that when I install the titanium backup program, it downloads a 
newer/older different version of busybox, so maybe that has something to do 
with it, but wireless tether has the same issue on both the older version 
included in the droid life rom and the newer version that titanium backup 
downloads today. I will update his later with what versions they are. Hope this 
helps devs, i use 2.1 all the time, but on 2.2 there is this problem or maybe 
with the droid itself, i had not played with this under 2.1.

Original issue reported on code.google.com by sanjo...@gmail.com on 9 Jun 2010 at 7:35

GoogleCodeExporter commented 9 years ago
just checked and titanium backup downloads the 1.15.3 busybox version

Original comment by sanjo...@gmail.com on 9 Jun 2010 at 7:45

GoogleCodeExporter commented 9 years ago
just wanted to update that now am running the bugless beast implementation of 
froyo, the latest build and downloaded the 2.05 pre 1 version and the changing 
mac address issue continues. 
I am able to get the ipad to connect after starting encryption and timing the 
change to the wireless tether network just right, it will work and then the mac 
id stays put, but it is a timing thing, if you miss it, it will give you the 
local ip (169.xx) and not connect.

Original comment by sanjo...@gmail.com on 12 Jun 2010 at 6:23

GoogleCodeExporter commented 9 years ago
Thanks for your report.

> I was also able to get it to connect once or twice by switching the access 
control 
> on and off
That makes no sense. Turning the access-control on and off changes 
iptables-rules. This has IMHO nothing to do with wifi-interface or 
wifi-connection.

> different version of busybox
Busybox is not used at all for this app.

So, you think the issue is that the device is changing the mac-address? I don't 
know any other device wich shows such a behavior (which has nothing to mean). 
You are talking about an "easy fix" - what should that be now?

Original comment by harald....@gmail.com on 12 Jun 2010 at 6:39

GoogleCodeExporter commented 9 years ago
first of all, i do not know much about how the tethering process works, so i 
was just reporting everything i see in regards to what software I was using. i 
have no idea if busybox is required or not, so I was just noting it.

I would think the "easy fix" would be to have the mac address of the droid or 
any phone be fixed or be the built in mac address. Does changing the access 
control cause the mac address or wifi connection to restart? MAybe it lets the 
timing work out so that the ipad detects it and gets the "right" ip address 
from dhcp. I will say that access control seems a bit weird because when I have 
say an xp laptop connected and switch the access control on it will lose 
connection even when that laptop is connected. 

I can also say that the changing mac address seems to be a problem for the ipod 
touch too. So when I try to connect an ipod touch, it is very similar to 
connecting the ipad, timing is critical. I really think that because the mac 
address changes, maybe apple systems expect the connection to have the same mac 
address so if your timing is not right, the apple device looks for the mac 
address it originally was talking to and decides that since it isn't there 
anymore, it will just give you a local ip address instead of the dhcp address. 

Like i said, wireless tether, once locked into a device like the xp laptop 
stops changing the mac address every thirty second and then the ipad can 
connect easily.

I would also think that that may be the problem other devices might have with 
the software not being able to see the dhcp server or whatever. I have read 
several bug reports that say that they can connect to the ssid like you can 
with the ipad but the internet connection is down. I don't know if maybe this 
changing mac address causes a problem for linux based drivers or whatever, but 
maybe having it be fixed might clear up some of those other errors too.

I am very happy to try anything you suggest to give you more info, I am trying 
to give you any information that I can think of to allow you to fix the 
problem. The program I am using to monitor the wifi signal coming from the 
droid is called netsurveyor or also there is one called network stumbler, they 
both work under xp and let you monitor all kinds of things with the signals, so 
that is where I found out that the mac address was changing. It usually only 
changes by increments of one as you can see in the attached file, the wireless 
tether ssid is called android and you can see the mac address changing from say 
02:00:00:61:16:35  to 02:00:00:61:16:36.

using an xp laptop, once i try to connect to wireless tether, the mac address 
will stop changing and stay fixed on the droid phone, i need a second wireless 
computer to show that in the logs but basically, then the ipad connects without 
a problem at all.

I should also add probably on an unrelated note that when you switch 
connections, say for me switching from the wireless tether network to my home 
network and back again, it will not restart, you have to stop wireless tether 
and restart it again in order for the connection to work. 

Anyway, attached is wire 3 and 4 which should both show the mac address 
switching, one of them should have time codes so you can see when it switches. 
I will also run this program on another laptop to capture all the input when 
connecting an ipad and the laptop if that helps you any.

Hopefully i have given enough detail to help. I am sending this thru wifi 
tether right now on the xp laptop and the ipad is connected. 
Without a fixed mac address, i think it is probably just timing luck that 
allows the ipad to connect, but once the mac is fixed, there is no issue 
connecting at all. Feel free to email me at sanjonny@yahoo.com directly if you 
want any more information of logs. I will try and upload the logs of the ipad 
connection later today.

I am attaching wireless which i think is a summary report, wire3 and wire4 are 
logs from the connections and wire2 which is either an early log of wire3 and 4 
or just a simple summary report.

Original comment by sanjo...@gmail.com on 13 Jun 2010 at 4:36

Attachments:

GoogleCodeExporter commented 9 years ago
Could you please try the latest test-release:
http://android-wifi-tether.googlecode.com/files/wireless_tether_2_0_5-pre2-test1
.apk

It dives a wifi-interface a different name. Maybe this has a positiv effect. 
I've never seen such a behavior on my device (I don't have a droid) ...

Original comment by harald....@gmail.com on 15 Jun 2010 at 8:36

GoogleCodeExporter commented 9 years ago
okay, i didn't even think this might be a droid specific issue, but duh, maybe 
it only changes the mac on the droid. So i did some in depth testing on the 
latest build you sent and here is what i found.

I am attaching the log from netstumbler or whatever the program is, you can see 
the android changing the mac address basically until a device is connected 
every 9 to 12 seconds. I tested this for about 30 time periods and with nothing 
trying to attach, if you wait, it will change the mac address after 12 seconds, 
then 12 seconds, then 9.5 seconds, then 12, 12, 9.5 and over and over again.

since I can audibly hear when the new mac address is found, if i timed it just 
right, i could get the ipad to connect. Basically I would wait for the sound of 
the mac address changing and then hit the connect on the ipad. Once the ipad 
connects, the mac address doesn't change unless the ipad disconnects or you 
stop and restart the tether, if i did not get the timing correct, i got the 
local address, say if i tried to get the ipad to connect like 3 seconds after 
the mac address changed, it would get the local address (169.xx.xx) and not 
connect. i forgot to check if it stays fixed and works correctly if i have a 
laptop connected but I imagine that is what happens, two other things i will 
try also, when if first starts up, since i had it set for a different channel 
than default (channel 6) it starts up in channel 11 and then changes to channel 
6. I am going to try not changing the channel and see if that is causing the 
mac address change. anyway, most of the changes are in the attached logfile 
with timecodes. 

Original comment by sanjo...@gmail.com on 15 Jun 2010 at 10:45

Attachments:

GoogleCodeExporter commented 9 years ago
Okay ran some more tests. Wanted to let you know that the version i downloads 
is 2.05.pre2 but appears on the droid as 2.05.pre3. Anyway, channel changing is 
not working at all. the phone begins at channel 11 and then by default changes 
to channel 6. If you try to change it to any other channel, nothing changes, it 
just returns to channel 6. Maybe temporarily change the default channel to 11 
and see if that stops the changing behavior? 

Also, I verified that once you connect an xp laptop to the droid, the mac 
address stops switching and the ipad connects without any problems. I 
completely deleted all the data and files from my droid and did a fresh install 
of the latest version and this is where the channel changing or rather not 
changing showed up. As you can see in this log, at times it is broadcasting 
AndroidTether, but then I changed the name hoping that might change something 
and it did change the ssid, but not the channel or anything else. I tried 
channel 9, 5, 3 and it would not change the channel at all. I also tried 
rebooting etc and no joy.

Hopefully this helps, let me know what you want to do next.

Original comment by sanjo...@gmail.com on 15 Jun 2010 at 11:21

Attachments:

GoogleCodeExporter commented 9 years ago
FYI, I'm using 2_0_5-pre3-test3.apk on an HTC MyTouch Slide, and sanjonny's fix 
doesn't work for me.  That is, I first connect my laptop (MacBook) to the 
Android Tether - which works, and then connect my iPad.  I get full DHCP info, 
but no traffic gets through from the iPad, it can't connect to anything and it 
doesn't change the data counts on the application (even though the Android 
buzzes and says the iPad has connected)

Original comment by patriss...@gmail.com on 30 Jun 2010 at 11:41

GoogleCodeExporter commented 9 years ago
On your laptop, can you see if the mac address is changing, use one of the 
programs I mentioned to check it out. I will also say i found another 
workaround that seems to work everytime. IF you set your static ip addresses to 
something like the following for the default settings, it will maintain 
tethering. 

I basically put the ipad connection to manual and used 192.168.2.100 as the ip 
address for the ipad ip address and the rest as follows below:

192.168.2.100 ip
255.255.255.0 subnet
192.168.2.254 router
192.168.2.254 dns

That will connect, and sometimes, even though the android will not make any 
noise as if the connection is working, the ipad will still get data. The 
counters most of the time work.

This seems to work every time I connect the ipad to the phone now, using the 
latest (at leastt the last I tried build .05 and the old stable build. I will 
play around some more with it this week and report back but hopefully that 
helps some people. This is one petes bugless beast rom, not that it probably 
matters and the kernel is either what pete has put there or the stock 2.2, not 
sure about that, I just know I have never put on a custom kernel.

Original comment by sanjo...@gmail.com on 4 Jul 2010 at 5:59

GoogleCodeExporter commented 9 years ago
Sorry, one other thing i thought about. Since my laptops are all xp or win7, 
maybe the macbook is not forcing the mac address to stay stable after 
connecting. Like i said also patrissimo, you can also keep trying the ipad and 
catch it the android when it switches the mac address and timed just right, you 
can get it to automatically connect without a laptop around. I before noted it 
changes every 12 10 or 8 seconds until it is connected, so hit the wifi in the 
ipad switch and if your have the ipad jailbroken, it is good to use sbsettings 
to note your ipaddress in the top bar (an easy setting you can find in 
sbsettings, if your ipad is not jailbroken, good god man, jailbreak the thing, 
you don't have to let Steve Jobs control you like that and obviously your 
android phone is rooted so go for it. When the connection works, you should get 
an autoip address like the one above. Once you get an address that works, set 
your ipad for android to use that all the time and then you no longer have to 
go thru the pain of timing it again by making it a fixed address.

Original comment by sanjo...@gmail.com on 4 Jul 2010 at 6:05

GoogleCodeExporter commented 9 years ago
I'm having the same issue running 2.2 rooted on an htc incredible. I'd guess 
you're right that it is a Mac address issue.  Hoping there is a solution as I'm 
keen to get wifi for the iPad running.  Thanks for the hard work and cheers

Original comment by faryan.a...@gmail.com on 10 Dec 2010 at 3:50

GoogleCodeExporter commented 9 years ago
I have had okay luck by switching on tether, turning off wifi on the ipad and 
turning it on right after I set tether to transmit the signal. I can now 
usually get it to lock in the mac address one out of three tries or so. The key 
is hitting that 10 second window just about right.

So turn off wifi on the ipad, get yourself ready and then set wireless tether 
to start up and hit the wifi button on the ipad. You want to time it so that 
wifi is searching just about the same time that tether is actually 
broadcasting. You can also use the rebrocast button to send the signal when the 
ipad is ready. You can practice by watching when the Mac address is changing by 
using something like netstumbler or insidder that will make an audible noise 
when a new mac appears, so you can get the timing down for when you do not have 
a pc around. Another interesting thought is if you have a win7 computer, you 
can use tethering on that computer and then use connectify to share the phone 
connection with the ipad. It only works on win7, but I tried it and it does 
work as a way to share the connection.

Does anyone know if the droid 2 has the same stupid mac address changing 
problem? Also is there anyway to fake or maually set the mac address on the 
droid?

Original comment by sanjo...@gmail.com on 14 Dec 2010 at 5:38