yashsingh1/xdaforums huggingface dataset:
[Wing, P4350 General] peraspera:
Hi everybody,

I am following xda developers a couple of weeks, and I saw that wonderful people came together in a spectacular site :) I have learned many things from you, thank you.

I own a Herald (I guess :)) and trying to learn cooking my own ROM and I am still a beginner, rookie, junior whatever you call :) There is one thing I want to learn how can we control the LEDs of Herald. I mean I want to use i.e. the wifi LED as a SDCard read/write indicator like pc's hdd indicators, or the orange one for the internal storage access indicator. I searched everywhere found a couple of software like nueled, aksoft's LED Control etc. Any of them worked also I found the Allledmgr.dll tried with it and nothing. So is there a way to control these LEDs?

Thanks.
[Wing, P4350 General] neiltoe:
You can get LED activity using WM5torage.

It is just a simple check box. Of course the is only when you are using your phone as USB storage for your PC.
[Wing, P4350 General] peraspera:
I see, thank you so much for your help neiltoe :)
[G1 Android Development] NickPDX:
I have been wavering back and forth on deciding to root or not. I am leaning toward doing it but I am so freakin busy with school and work that I was going to wait a few weeks until I had a chunk of time to read up and really understand what I am about to do.

My decision seems to have been forcibly accelerated today when the t-mobile update screen popped up. I have pressed update later a few times so far but wanted to ask a quick question before I decide which way to go with this. I want the new features in RC33 (and maybe better battery too?!?), but the additional features with the JF rooted versions seem way better.

Can anybody verify yet if I go ahead with the official RC33 update will I still be able to get root using the current methods? If not, any ideas if this is going to be possible? I know that is speculation but since its been out for a bit now I figured somebody would have some insight on this.

Thanks for any input you all can offer. All you guys around this site were great when I was messin around with my Shadow/Juno before I got the G1.

Thanks again!

Nick
[G1 Android Development] Proxin:
Go ahead and go to the official RC33 update, it will still work. JesusFreke himself said that the update doesn't touch the bootloader, so the downgrader still works on this version.

It worked for me from RC33 official, it'll work for you too.
[G1 Android Development] ichigoismyhomie:
I understand your feeling about rooting. I also have limited free time between school, work, gf, and families. I say just do the rooting. It only took me couple hours on the weekend to get it done. To be honest, I found the tutorial on this site is a little too complicated and can be intimidating for those that not comfortable with linux command line.

just follow the rooting method on this thread below:

http://androidcommunity.com/forums/f28/rooting-your-g1-made-easy-11825/

I did it and never look back. I haven't heard that RC33 does any significant change on battery life, so I don't think it's worth the upgrade. I say go with Developer firmware (ADP1.x). ability to dump cache on sdcard + 3G wifi tethering + no google initial login = WIN with root
[G1 Android Development] M9x3mos:
Yeh if you don't have time go for it. Like the previous posters have mentioned is does not make any irreversible changes that you would not be able to root the phone later when you have time. I would rather suggest following the tutorial on this page:

http://xdaforums.com/showthread.php?t=442480

because it has all the links needed embeded right into the tutorial and is very straight forward about what and how to do to get a modified root rc33 on your phone and start living Android like it was intended lol.
[G1 Android Development] NickPDX:
Thanks...

Thanks for the info in all of your responses. I went ahead and updated to RC33 with the official update this morning. I think that it seems to be running better. After the update my avaliable storage space went from like 6 to 23 mb which I thought was odd. I think that I will end up rooting my G1 before cupcake, or the next update that comes our way. I am just going to wait until I have time to mess around with it some more. It does seem like an easy process but it is not without chance for issues as I have read from other posts.

Thanks again for the responses and advice.

Nick
[G1 Android Development] aziwoqpd:
This is a program I wrote a while back that allows transparent tethering over USB without requiring root access. It works by simulating an unencrypted OpenVPN server and then internally running everything through a Java-based NAT. I get decent speeds off it, but your mileage may vary. It's a bit beta! Might explode! Wear eye protection!

It has a really basic website at http://lfx.org/azilink/, but to spare your eyes I'll just paste the instructions below:

Required files:

- ADB from the 1.1 SDK or from http://lfx.org/azilink/adb.zip

- OpenVPN 2.1 (not 2.0) from http://openvpn.net/index.php/downloads.html

- AziLink.apk from http://lfx.org/azilink/azilink.apk

- AziLink.ovpn from http://lfx.org/azilink/azilink.ovpn

Installation:

1) Install OpenVPN on the host. I use version 2.1_rc15, but any version should work. Apparently if you use version 2.0 you'll need to remove the NO_DELAY option from the AziLink.ovpn configuration file. You can find OpenVPN at:

http://openvpn.net/index.php/downloads.html

2) Enable USB debugging on the phone. From the home screen, this is under

Settings>Applications>Development>USB debugging.

3) Install the Android USB driver (if you don't already have one installed).

See http://code.google.com/android/intro/develop-and-debug.html#developingondevicehardware

4) Install the program. You can either use ADB to install by typing

"adb install azilink.apk" with the file in the current directory, or you can browse (on the phone!) to: http://lfx.org/azilink/azilink.apk

Either way you might need to allow installation from unknown sources

under Settings>Applications>Unknown Sources.

Configuration steps:

1) On the host, run "adb forward tcp:41927 tcp:41927" to set up port forwarding. Be sure to use adb from the Android 1.1 SDK! The version from 1.0 will lock up under heavy load. If you don't want to download the entire SDK, you can get a copy of ADB+drivers from http://lfx.org/azilink/adb.zip

2) On the phone, run AziLink and make sure "Service active" is checked.

3) Right click AziLink.ovpn on the host (not in the web browser!) and select "Start OpenVPN on this configuration file." You can find this file at: http://lfx.org/azilink/azilink.ovpn. If you're using Linux or, god forbid, MacOS, you'll also need to manually set the nameserver to 192.168.56.1 (the phone's NAT IP address).
[G1 Android Development] neoobs:
Nice work around.
[G1 Android Development] vitriolix:
Wow, amazing work! I'll definitely have to mess around with this tomorrow...
[G1 Android Development] koekwaus:
OpenVPN 2.0.9

Thnx for the manual..!! Took me something to get it working, i'll find out, that it isn't working with OpenVPN version 2.0.9

OpenVPN 2.0.9 doesn't recognize the following rule in azilink.ovpn:

socket-flags TCP_NODELAY

And it worked with version 2.1rc15...

So no more Internet Sharing on Windows Mobile... :D
[G1 Android Development] koekwaus:
OpenVPN 2.0.9

Thnx for the manual..!! Took me sometime to get it working, i'll find out, that it isn't working with OpenVPN version 2.0.9

OpenVPN 2.0.9 doesn't recognize the following rule in azilink.ovpn:

socket-flags TCP_NODELAY

And it worked with version 2.1rc15...

So no more Internet Sharing on Windows Mobile... :D
[G1 Android Development] zecbmo:
help

Ok I'm a complete noob and I've played about with this but can't get it to work. How do I run adb? As in the very first step? Where do I type that. Do I need to install adb and how do I do it?

Thanks
[G1 Android Development] zecbmo:
Got it working

Man this is awesome.

I realised i needed to run the adb from cmd. see when i tried to open adb.exe it just kept closing.

thanks alot. this rocks

ps im writing this off my tethered pc
[G1 Android Development] aziwoqpd:
Nah, you can just unzip adb and run it directly from that folder. It's a command line program, so you'd need to run it from a command prompt (cmd.exe). I'm not sure whether adb needs to run as an administrator or not (I disable all that UAC garbage in Vista). If you have the proper driver installed, then the ADB command should return immediately without saying anything. If it says "waiting for device..." that means it wasn't able to find the Android debug driver.

I know this is all a bit hacky, but now that we've got root and wifi tethering I figured that there wouldn't be too much interest.
[G1 Android Development] zecbmo:
cheers

its working great like. im using this cus i havent rooted my phone yet. tethering was the only reason why i wanted to root it but this is a great alternative
[G1 Android Development] hole423:
Works Great. Thanks for the easy instructions.
[G1 Android Development] vovkab:
Here is translation of post on Russian with images http://androidteam.ru/faq/azilink-tethering-with-android-usb.html

I have repacked all in one zip, and make some command files to make process a little easy.
[G1 Android Development] sonikamd:
another trick that may help on XP machines, probably other versions as well.

Create a shortcut to adb.exe on your windows desktop (mine is located in C:\and\tools)

Modify the 'target' (right-click,properties) of the shortcut to read C:\and\tools\adb.exe forward tcp:41927 tcp:41927 <I think this is the right code, I'm still using tetherbot on 1080> :p

That's it. Once everything's set up connecting is easy. one click on the computer, no cmds required :)
[G1 Android Development] clevetbs:
does this allow for media such as flash on web site to play on the laptop?
[G1 Android Development] aziwoqpd:
If you've got enough bandwidth. I'm not really sure what bitrate flash video runs at though.
[G1 Android Development] scaphoid:
Many thanks for this, aziwoqpd. I've not had the time to root, but have been looking for an easy way to tether. A usb connection is great, since the battery drains so quickly anyway it's nice to keep a charge going.

sonikamd - thanks for the suggestion, it's a great idea. Unfortunately my XP doesn't want to accept your syntax. I wish I could offer something else, but my skills (ha!) are nonexistant. I'm embarassed to say that I had to refresh my memory on how to maneuver around command lines...

Got any other suggestions?

Thanks again for all your work!
[G1 Android Development] wizern23:
the AziLink.ovpn file wont download for me.
[G1 Android Development] dadennis:
works fine for me, GREAT WORK!
[G1 Android Development] lindsayt:
Okay, so I'm trying this out on a mac. I've successfully built openvpn and have my tunneling device (/dev/tun0, /dev/tun1, etc.). I run the adb forward command and it starts the daemon successfully, I fire up azilink on the phone and it says it's waiting for the connection, I fire up openvpn and the phone changes to stating that it's connected. Openvpn does not exit out - it starts the tunnel - BUT in the logging it reports " ROUTE: problem writing to routing socket" twice (which oddly appears to be a non-fatal error to the application), and traffic is unable to flow. I'm guessing it's something about openvpn not correctly manipulating the darwin routing tables, but I've been unsuccessful thus far in figuring out the nature of the problem so I thought I'd check here.

I'm running the straight azilink openvpn config file, which means if I need any syntactical changes for darwin I haven't applied them. The openvpn documentation is not terribly good and I was unable to find any documentation of routing command differences for MacOS (if that's even the problem, of course).

Edit: I forgot to mention, I've been trying to ping known-good IPs by address to test the routing - after my first attempt at loading a web page failed I figured it best to remove name services from the possible list of problems. The bytes sent count was slowly incrementing (up to about 23K bytes in ten minutes of diagnosis), and the inbound count got up to about 900 bytes in the same period, so clearly *something* was getting through - unless those counters are counting all traffic into and out of the phone and just going over the cable - but I got no ping responses, no websites could load, and by all appearances from the terminal, no data was moving.
[G1 Android Development] aziwoqpd:
The byte counters only include traffic that OpenVPN is forwarding, so something is making it over. Did you try changing the DNS server to either 192.168.56.1 or an external address like 4.2.2.2? OpenVPN on MacOS and Linux won't set the nameserver automatically.

Also, there's a bit of a problem with pinging. The app on the phone can't generate ICMP ping packets since it isn't running as root. When you send an ICMP ping, the phone translates it to a UDP ping, sends it, and translates the reply back to a ICMP ping. Unfortunately, probably about 50% of hosts don't reply to UDP pings. Some that I've tested with that do work are lfx.org and he.net.

I'll see if I can give it a quick test on a Mac sometime tomorrow.

EDIT: I managed to get it working, although T-Mobile's so-called "transparent" web proxy is barely working today so I was having trouble accessing websites without getting errors. SSH was working fine, though. Anyway, here's what I did:

1- Installed a MacOS port of OpenVPN called Tunnelblick (didn't have XCode handy to compile my own and it's got a pretty GUI)

2- Copied azilink.ovpn to /users/azi/library/openvpn or whatever it is

3- Click the Tunnelblick icon in the upper-right, go to details, click "set nameserver"

4- Remove the TCP_NODELAY line because it was complaining that my kernel didn't support it (and would cause my connection to timeout after about 30 seconds).

5- Clicked connect

If you want to see what traffic's going over openvpn, you can just run "sudo tcpdump -n -i tun0"
[G1 Android Development] sebimaurer:
wow ... this works great ... tested using a german G1 under linux (arch 686), win vista (x64) & win xp (x86) ... pretty good speed and low latency (actually i can't notice any latency at all - no mather if using wlan or 3g)!

GREAT WORK!!!
[G1 Android Development] lilithpro:
Nice one, this works great for me. I have ovpn installed anyway and with a simple self-written script it only takes 1 click and a connected phone to be online. Many thanks for this one!
[G1 Android Development] buttkicker:
Nice work.
[G1 Android Development] Dimath:
I have "Connected to host" in status, but Internet does not work and I am getting error to ping command:

From 192.168.56.2 icmp_seq=1 Destination Host Unreachable.

What can be wrong?

I use linux and OpenVPN 2.1_rc10.
[G1 Android Development] mochabyte:
After wresting with this a bit today, I think I've got this working on OS X. Making the vpn connection worked fine with both the openvpn2 client from MacPorts and Tunnelblick, but getting proper DNS resolution setup was the only tricky part.

Setting your DNS resolver on OS X Leopard is a bit trickier than just adding an entry in /etc/resolv.conf, since that file is auto generated by the networking system, and really only exists for backwards compatibility with older tools like 'host' and 'dig'. Properly setting up DNS requires messing with some entries in the 'scutil' command line tool.

I didn't have much luck with Tunnelblick's supposed "Set nameserver" feature, as it only seemed to work when I had an existing wired, wireless, or some other kind of primary connection. So I dug around in the Tunnelblick.app to see if there was anything worth looking at, and came across /Applications/Tunnelblick.app/Contents/Resources/client.up.osx.sh. Tunnelblick calls this script after setting up the vpn connection to apply and DNS settings from your openvpn config to the existing primary adapter (e.g. wired, wireless). Since I'm using this to tether to the phone and don't have an existing primary connection, I think the the client.up.osx.sh script fails when it's unable to find an existing connection.

So, you could modify Tunnelblick's client.up script to do something a little different, but I actually just decided to whip up a custom script that uses the openvpn2 from MacPorts so I could just run one command on a terminal to set the whole thing up for me (including adb port forwarding), and tear it down when I ctrl+c it.

Have a looksie if interested:

http://pastie.org/405289
[G1 Android Development] snetsplit:
Just want to say this app is a God-send. Thanks heaps aziwoqpd! Now I have the whole internet again.

I'm attaching some auto connect scripts. put these in your openvpn config folder with adb.exe and winapi.dll in your windows folder. Then you can open the openvpn gui and connect with a single double click. It'll automatically start adb up, then close it when you disconnect.

Also included is a copy of the openvpn gui called "net connector.exe" with modded android icons. I gave it a new name so you could copy it in there and keep your old openvpn gui too.

Again this freaken rocks! You go aziwoqpd!
[G1 Android Development] FraMu:
This app is excellent

Hi,

I found this very useful when used with Ubuntu. The openvpn is stable with repeated connection and disconnections of the USB cable and the link comes back up almost always. Wifi speeds through the G1 were around 2Mbps which is the wire speed for my broadband link. 3G is pretty good also and I could run IPSec and VoIP over the link making it very useful.

There were a couple of things that tripped me up:

1) If I connect Ubuntu to G1 the openvpn link comes up as expected. If I then disconnect the USB cable and reconnect within 10s or so the openvpn link comes up momentarily. However in adb logcat I then see a message from azilink indicating it is closing the connection because it didn't see a keepalive in the previous 30s. This is odd because data is being sent/received after the reconnection. Either openvpn on Ubuntu has stopped sending keepalives or azilink has stopped receiving. Longer disconnect times do not exhibit this behaviour.

2) Change of WAN link from Wifi<->3G

During an active connection if I change from Wifi to 3G or vice versa I need to restart the azilink service to complete the switchover. From the azilink byte counter the send count continues to rise but the receive stays on zero until I restart the service.

Thought aziwoqpd may find the feedback useful.

Regards,

Frank
[G1 Android Development] Micronics:
PDA Net 4 Android gone Beta on http://www.junefabrics.com/android/
[G1 Android Development] snetsplit:
I think that might be an OS issue. I forget to turn the wifi off and try tethering with it a lot. Never had a problem with it in XP, win7, and hackentosh versions of OS X.
[G1 Android Development] thecrazier:
hey guys i need some help with this "configuration bit'' im really stuck here and confused, i started this project on the website he made and came across this forum becuase i looked for the help; in the website it doesnt mention anything about the AziLink.ovpn but it does here. i installed the program to the phone and the eclipse/driver to my laptop along with the openVPN, but how do i run "adb forward tcp:41927 tcp:41927" ? when i use command prompt, i get the message that it is not a command, internal nor external nor is it recognized as a operable program/ batch file. thanks also, does eclipse have to be running while i tether?
[G1 Android Development] maxisma:
PdaNet works much better..

An of course wifi-tethering!
[G1 Android Development] hotweiss:
This app works great. Thank-you.
[G1 Android Development] 9a3eedi:
Hi,

I seem to be the only one getting this problem. I've google'd with no results. On the openVPN command line, I keep getting this:

Tue Jul 07 01:09:57 2009 read UDPv4: Connection reset by peer (WSAECONNRESET) (code=10054)

repeatedly,

and on AziLink on the phone, it stays on "waiting for connection" the entire time.

I'm pretty much stumped. Can anyone help?
[G1 Android Development] MoreYummy:
http://openvpn.net/index.php/downloads.html is not working.

I downloaded openvpn somewhere else.

Also how do you run openvpn on windows?
[G1 Android Development] ben@M:
You are a genius, Thanks a lot for your script...working perfectly for me
[G1 Android Development] fanaticsurf:
Hi,

nice work. :)

I wonder if it is possible to do it in the other direction?

Android using the internet connection over usb of a laptop/pc connected over ethernet.

This will help to save some mobile data traffic.

fanaticsurf
[G1 Android Development] lbcoder:
Try this as a start: http://xdaforums.com/showthread.php?t=522498
[G1 Android Development] fanaticsurf:
Thanks for your hint lbcoder,

but I am looking for a Windows solution, because my office pc/laptop just has Windows installed.
[G1 Android Development] xda-vinnie:
Hi there,

Just thought I'd register and confirm that after some trial and error I successfully tethered my android phone (no SOCKS, no rooting) to a MacBook pro. Additionally, I got it working using the Tunnelblick openvpn app.

I did this by mainly following the instructions in this thread and here, which got me most of the way (i.e. AziLink showed a connected to host status).

A few notes about my settings and the Tweak I need to do in order to actually get a working 3G Internet connection.

1) I addition to the USB and AziLink setup, I have to turn off WiFi on the phone. (this is fine because if I am able to connect to a WiFi network I might as well do it directly from my MacBook).

2) I created a separate network location to use when tethered with the following settings:

a) deleted all services except Ethernet

b) configured IP4 manually, using the following settings:

i) IP address 192.168.0.20

ii) Subnet Mask: 255.255.0.0 (this varies, see Tweak below)

iii) Router: 192.168.0.1

iv) DNS Server: 192.168.56.1

v) Search Domains: (leave blank, see Tweak below)

c) Apply settings and leave the network preference pane open.

3) After running the adb forward command, opening the Tunnelblick application and connecting to the azilink vpn, the phone will show a Connected to host status. However, I was unable to successfully able to connect to the Internet until I did the following.

4) Tweak: After everything's setup as it should be, I found the following network preference change would actually enable the Internet connection.

a) Go back to the open network preference pane and change the third octet of the Subnet Mask field. i.e. if you originally set the Subnet Mask to 255.255.255.0 change it to 255.255.0.0. Press Apply to activate the changes. At this point you should see a light grey 'openvpn' entry show up in the search domains field. Note that the Tunnelblick icon will show its connecting status and then return to its connected state.

It took a while to get it working today, but at least I can connect my computer to the Internet via the cellular networks if I ever find myself needing to use my laptop in a spot without freely-available Internet access.

I like the idea of the shell script above since once configured it seems more convenient overall. However, since I already use Tunnelblick to connect to my work VPN, and wanted to stay away from the command line, I'm happy knowing I can get a 3G data connection by performing these extra steps.