yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] TheMasterBaron:
Another update, I've dropped the resignRom.zip project in favor of the resignUpdate.zip project. This zip package has a .bat file where the first parameter is a ROM's update.zip file. It pulls out the APKs, resigns them, puts them back along with Toggle2G.apk and spits out a new zip file with the changes.

I've tested with MIUI on my nexus on and it work great. Should work most any ROM really!

If someone wants to give it a whirl, please let everyone know your results!

Cheers,

MB
[Android Apps and Games] TheMasterBaron:
Seems every phone/rom have different reactions to Toggle2G. Its either the phone's radio, or the rom is having issues with switching. Not anything I can think of that will help.
[Android Apps and Games] mcdevtingz:
Which .zip file do I use to update?
[Android Apps and Games] nupi:
[WISH] Add option to switch to 3G only after unlocking

This works beautifully with my Defy running CM7.1.

Just one thing I am wondering about: how about giving the user the option to have the phone switch to 3G only after unlocking it? Switching it immediately after the screen was turned on means it goes into 3G all the time, even if I want to just check time or switch a song (which I can do from the lock screen).
[Android Apps and Games] kecinzer:
Hi.

Will resignUpdate.zip works with stock Nexus S ROM?

For now I use Oxygen 2.2.2, where 2Gtoggle works perfectly. But I want to back to stock.
[Android Apps and Games] totalcmdext:
In my case HD2 the miui ROM is stack in the bootanimation screen of the MIUI ROM.

The problem that i saw is that the framework didn't change from the .bat file.
[Android Apps and Games] kitecarl:
Will be glad to help on the testing front - I can even work on authoring a Mac/Linux variant. Can you let me know where I can find the zip?
[Android Apps and Games] totalcmdext:
Maybe there is a bug in the resign-update-zip.bat file because the framework doesn't copy in the new signed file after the update.
[Android Apps and Games] TheMasterBaron:
Thanks, the resignUpdate.zip is in the OP.

If you post a link to your ROM, I'll test it myself and make any adjustments that are needed to get the script working.
[Android Apps and Games] chareos12:
Guys, I really like how this is evolving... I wish to thank you all
[Android Apps and Games] imranb:
This would be a great feature. Would love to see this on my CM7 Defy too!
[Android Apps and Games] jocaferlo:
I used resignUpdate with a MIUI ROM for my Nexus. I flashed the new ROM. The phone boots ok, all works fine, Toggle2g.apk is in /system/app BUT I can't use it, it doesn't appear in the apps installed in the phone.

Any help?
[Android Apps and Games] TheMasterBaron:
Can you post a link to the ROM's zip download you used?

Does the new ROM file have updated apk files in it?

Can you send me the output of the update process?
[Android Apps and Games] TheMasterBaron:
My bad, the system/framework apks were not being updated :eek:. I have fixed the script and you can get the latest (v1.0.1) in the OP. (thanks totalcmdext for pointing it out!)

Sorry!
[Android Apps and Games] burntrat:
Has anyone tried using this app for the samsung vibrant running bionix next gen v2?
[Android Apps and Games] edison218:
Hi MasterBaron, thanks for trying to reach out to everyone for your app..really appreciate it. I have been trying for several months but with no success as yet, hope you can help. I am using Android revolution hd 1.1.6. This is the link to the file: http://tiny.cc/tjraj for Android revolution hd 1.1.7 found here http://xdaforums.com/showthread.php?t=1088498

This is the process in command prompt:

java version "1.7.0"

Java(TM) SE Runtime Environment (build1.7.0-b147)

Java HotSpot(TM) Client VM (Build 21.0-b17, mixed mode, sharing)

Pulling system...

Resigning apk files....

Injecting Toggle2g

Rebuilding zip

cleanup

Access is denied

updated zip resigned to file Android_Revolution_HD-Incredible_S_1.1.6.zip-toggle2g.zip

Thanks once again. Hope to hear from you soon.
[Android Apps and Games] jocaferlo:
I tried again with the latest version (1.0.1) and the same result.

The link to the ROM: http://content.wuala.com/contents/Arasthel/Android/MIUI/MIUIEs/ROMs/MIUIEs-N1-1.9.23.0.zip

The sizes of apks in the new ROM file are diferent. Is it supposed they are updated?

The output of the update process..... Is this?:

"C:\resignUpdate>resign-update.bat MIUIEs-N1-1.9.23.0.zip

C:\resignUpdate>echo off

resign-update v1.0.1

java version "1.6.0_26"

Java(TM) SE Runtime Environment (build 1.6.0_26-b03)

Java HotSpot(TM) Client VM (build 20.1-b02, mixed mode, sharing)

Pulling System....

Resigning apk files....

Injecting Toggle2g

Rebuilding zip

cleanup

El sistema no puede encontrar el archivo especificado. (System can't find the specified file)

updated zip resigned to file MIUIEs-N1-1.9.23.0.zip-toggle2g.zip

C:\resignUpdate>"

Regards.
[Android Apps and Games] TheMasterBaron:
OK, got some things going on the next few days that going to kill my time to work on this. I'll take a look and see what I can dig up.
[Android Apps and Games] TheMasterBaron:
It's possible I might have included the unsigned toggle2g.apk in the last update. I have update the script to version 1.0.2 to prevent me from making that mistake again.

jocaferlo, your ROM did work for me! I was also able to get the N1 stock rooted ROM created by fireb33, and the OxygeN1mod to work. QND did not however. Keep in mind everyone, I only have a Nexus One to test with. I can't test other ROMs for other phones. I can only make sure they get processed by the script correctly.

Sorry everyone, looks like this solution is hit or miss. After running through a few ROMs it looks like it works on some and not on others. At this point, all I can do is suggest you try it on you favorite ROM and see if it works.
[Android Apps and Games] bushgegner:
I`m stuipid... how to get this working?

Flashed Toggle2G-Update.zip via CWM.

Installing widget: Toggle 2G Notification Plugin.apk - working.

Installing: Toggle2G.apk-unsigned.apk - not working. Not installed Error.

I´m on MIUI 1.9.23 Nothing Fancy

Do I something wrong?
[Android Apps and Games] edison218:
Hi MasterBaron, no worries its a gd effort..I got no errors this time in command prompt but unfortunately i did not see the toggle2g app in my app list.
[Android Apps and Games] jocaferlo:
I tried again with the new version 1.0.2 and the same result: all runs ok but I can't see toggle2g in the apps. Although Toggle2g.apk it is in /system/app.

This time the output of the update process don't show the line "System can't find the specified file":

C:\resignUpdate>resign-update.bat MIUIEs-N1-1.9.23.0.zip

C:\resignUpdate>echo off

resign-update v1.0.2

java version "1.6.0_26"

Java(TM) SE Runtime Environment (build 1.6.0_26-b03)

Java HotSpot(TM) Client VM (build 20.1-b02, mixed mode, sharing)

Pulling System....

Injecting Toggle2g

Resigning apk files....

Rebuilding zip

cleanup

updated zip resigned to file MIUIEs-N1-1.9.23.0.zip-toggle2g.signed.zip

C:\resignUpdate>

Thanks anyway for your work.
[Android Apps and Games] mcdevtingz:
I keep getting the data off problem... what should my network settings be for uk?
[Android Apps and Games] totalcmdext:
I have tried for MIUI 1.9.30 for HD2 without any success.

The file is inside but there isn't application icon and isn't possible to run it.
[Android Apps and Games] chareos12:
Can you use it trough Tasker ?
[Android Apps and Games] kitecarl:
Just an idea-check the Toggle2g apk file's permissions via an app like Root Explorer compared to other apks in /system/app.
[Android Apps and Games] jocaferlo:
I did it, and the permissions are the same.
[Android Apps and Games] mike_m:
Has anyone got Toggle 2G/3G working on Leomar's Revolution ROM 2.7.1 for the Samsung Galaxy S2?

If you have, please let me have step by step instructions on what you need to do.
[Android Apps and Games] howdid:
Thx for awesome app
[Android Apps and Games] edison218:
hmm I went into system/app clicking on the toggle2g app brings up..application not installed, just like before..
[Android Apps and Games] jocaferlo:
Yes, that happens to me too, but the permissions of Toggle2g.apk and other apk in /system/app are the same.
[Android Apps and Games] TheMasterBaron:
For those having trouble getting Toggle2G to show up, I have to do factory resets on some ROMs to get it to work. Please try this to see if Toggle2G shows up.

EDIT: I'll keep trying what's on the data partition that keeps it from showing up.

EDIT 2: Found the folder that needs wiping to on the data partition to get Toggle2G to show. Trying to narrow down the exact file to see if I can wipe it without affecting anything and saving the need for a full wipe.
[Android Apps and Games] mefistofelis:
Does this work with Leomar's ROM?
[Android Apps and Games] TheMasterBaron:
Version 1.0.3 is now available. This version will fix the issue users are having where after flashing, Toggle2G still does not show. The difference with this update is that it includes a ResignUpdateCleanup.zip that you will need to flash AFTER flashing the updated toggle2g.signed.zip. This flash does some post cleanup work needed to make Android fully re-build existing app's certs.

I hope this helps!

Cheers,

MB
[Android Apps and Games] mcdevtingz:
So what exactly should I flash if I want to update?

I haven't updated since version before last
[Android Apps and Games] TheMasterBaron:
If you already have Toggle2G working, just use the Toggle2G-Update.zip in the OP

Cheers,

MB
[Android Apps and Games] chareos12:
Amazing to see it sorted out !

Nw, hoping for OSX/Linux love :)

This thread is my F5 killer :D
[Android Apps and Games] mcdevtingz:
Its not 100%, data problem. Should I flash the pther thing too then?
[Android Apps and Games] TheMasterBaron:
If you having data issues, it does not sound like Toggle2G is the problem other than it might not be picking the right network. No being from the UK, I'm not sure what network you should be using.

While on 3G, you can try entering *#*#info#*#* the phone dialer to see what network your currently on. Then manually switch to 2G and look again. Use those 2 networks in Toggle2G
[Android Apps and Games] totalcmdext:
Feature Request

Is it possible to add the following feature in the next version.

After a time period (you could declare it) or when the screen is off to switch-off the Data.

Similar like the 2G when the screen is of
[Android Apps and Games] TheMasterBaron:
There are already great apps out there that do that. JuiceDefender comes to mind. I don't want to reinvent what other apps do very well.
[Android Apps and Games] chareos12:
I suggest you try Tasker.

Not only it is (echo) TRUE POOOOWER, but it also lets you control Toggle2G and make your own rules (and disasters).
[Android Apps and Games] edison218:
Hey Masterbaron, good news! I am able to see your app show up on my app list it work for me that update. At first, I was hesitant to do a factory reset as it might take a long time to restore the data. i tried the dalvik cache earlier and fix permissions with no success. Factory reset does the trick! I'm very grateful for your prompt replies and updates this 2 weeks, really appreciate it very much!

So far, everything is working just fine. It really did change to 2g only. I also use tasker and toggle 2g appear on the plug in list in tasker with 4 selections. Yea things can be done with tasker is plenty. It helps me turn off "phone internet" every night at a specified time automatically.

Keep up the gd work! Cheers :)
[Android Apps and Games] mcdevtingz:
I did this and it said gsm only and for 3G gsm auto

Is gsm auto PRL the same as this? I had data problems aswell today.. using wifii instead
[Android Apps and Games] HikenGruven:
How do you uninstall this?
[Android Apps and Games] eliashadow:
Working great in our DeSense rom on DHD!!!

we just build new version included your app!!!

If there is problem send me pm mister...

Thanks for your hard work...
[Android Apps and Games] TheMasterBaron:
Delete Toggle2G.apk from /system/app folder.

Great! Not a problem!

Cheers,

MB
[Android Apps and Games] jocaferlo:
I tried version 1.0.3 without full wipe but I got a lot of FC, so I did full wipe, I took the opportunity to try another rom (also MIUI), and the app runs ok.

Now I have a question: When I update the rom, have I to use again Resignupdate with the new rom? I suppose yes.

Will it work without another full wipe?.....

Thanks TheMarterBaron
[Android Apps and Games] flipdee:
Resign Question

Hey, Really hoping to get Toggle2G working on my samsung galaxy s.

I'm running DarkyROM_v10.2.2_Extreme_Edition_TouchWiz4.zip on it at the moment (love cyanogenmod but love the samsung dialer/contact apps more).

To install Toggle2G do I just run the resign script on the DarkyROM_v10.2.2_Extreme_Edition_TouchWiz4.zip file?

I see there has been a lot of activity surrounding resigning in the past few days, hoping to get Toggle2G installed asap!

Thanks a lot! Keep up the good work (Samsung should take note especially, when i'm in a 2g only coverage area my SGS feels like a new phone! - 1 entire day out of the battery, with heavy use!!!)

flipdee
[Android Apps and Games] TheMasterBaron:
Yes, you will need to resign and new ROM file to re-make it compatible. And, no, you shouldn't have to wipe when updating the same ROM to a newer version as long as you resign it first. If your switching ROMs, be suer to try flashing ResignUpdateCleanup.zip after flashing the ROM to wipe the cert cache.

Yes, run the script on the ROM zip as you stated. It will make a new zip for your to flash with. After flashing, be sure to flash ResignUpdateCleanup.zip before rebooting.

Cheers,

MB
[Android Apps and Games] MadAri:
I get it worked on Bulletproof MIUI.

Hi!

I got this to work with Bulletproof MIUI 1.9.23. I used that resignUpdate-1.0.3.zip

file with BP MIUI Rom. Then i installed that via recovery. It didint work after reboot. Then i tried fix permission, that didnt fix that.

Then i made factory reset and then this app worked.

>MadAri<
[Android Apps and Games] TheMasterBaron:
Did you flash the included ResignUpdateCleanup.zip just after flashing the updated BP MIUI Rom? This is what should fix things without needing a wipe.
[Android Apps and Games] MadAri:
Hi. I tried this so many ways, that im not sure if i did it after flash. I remember that i did it right after flashing rom, but im not 100% sure.

MadAri
[Android Apps and Games] flipdee:
Hey there, thanks for your reply,

I managed to resign the zip ok, I flashed it through cwm and flashed the resignupdatecleanup.zip and then rebooted however I just got a boot loop at the darky rom boot animation, even after trying a fix permissions the sane occurred.

I did a wipe and it worked this time, toggle2g app showing up and running under root permissions etc however it's not actually changing my network state.

I think I've tried every option in the app and even installed the notification plugin but the only tine I think I've got

a change is on initial boot of my phone using the battery low option and then it won't change back to 3g, even when using the manual notification button.

The widget allows me to turn the master switch on and off although the widget icon doesn't change.

I'm going to do a few more tests, firstly doing a wipe to see if it works on a vanilla install.

Is it possible to use tasker or locale to manually trigger the app even just for test purposes?

A test 2g and 3g switch in the app would be cool too.

Really hoping to get it working as my battery barely lasted

4hrs today, ok, that was with unusually heavy use.

Thanks again for all of your help so far.

flipdee
[Android Apps and Games] Aiakio:
Thank you so much, TheMasterBaron, for this amazing App!! :)

Working absolutely great on my HTC Desire HD (Setup in my signature)

Why there is no Thanks-Button on your first Post? oO
[Android Apps and Games] flipdee:
Ok so after a install after wipe I have come to the conclusion i'm getting the exact same symptoms on the clean install as my working titanium restore on top.

The only function that works for me is the switch to 2g when on wifi.

It switches back and forth.

The switch on sleep doesn't work no matter how long I leave it.

I tried using tasker to trigger it instead however it doesn't work, it just seems to untick the main toggle 2g auto option at the top on every change.

Locale doesn't untick this however it still has no effect on the toggle function even when trying to run an activity manually.

Can anyone confirm how long it takes to toggle (from loss of data connection to reconnection)?

I'd really love to get to the bottom of this, has anyone else experienced limited functionality?

Maybe it's an incompatibility with darky rom?

Thanks a lot,

flipdee
[Android Apps and Games] TheMasterBaron:
You'll need to look at some logging. Do you know how to look at logs using logcat?

1. In toggle2g, enable the "Switch When Charging" option.

2. Set timeout to 2 minutes

3. disable wifi

4. plugin your phone to our computer

5. run: adb logcat -s Toggle2G

6. turn your phone off and wait 2 or 3 minutes

7. hopefully you will see some toggle2g logging you can post.
[Android Apps and Games] flipdee:
logs

Hey, Thanks again for your reply.

I ran a log - please see txt file for log output.

I tried it twice, this is the log for the second time when nothing happened.

The first time it seemed to change, even if it was just to 2g, i'm going to try to recreate it and post the log for it too.

Cheers,

flipdee
[Android Apps and Games] flipdee:
logs

Ok, tried and failed to recreate the semi-working state so here is what there was of the log from the first time.

It might be a little confusing.

flipdee
[Android Apps and Games] TheMasterBaron:
Got to love this error :confused: : com.android.internal.telephony.CommandException: GENERIC_FAILURE

I don't this this is a toggle2g issue but aphone issue. I googled the error and other people are seeing this error and its giving them network errors. see: http://www.google.com/support/forum/p/Google+Mobile/thread?tid=747f398a6c1bb2b9&hl=en&start=120

Cheers,

MB
[Android Apps and Games] flipdee:
Hey, thanks for looking into this.

The strange thing is the first time I tried it I think it did work somewhat. Does the switching failure-first log.txt show some successful operations?

Thank goodness i'm not suffering any of the problems that are reported by the people experiencing the reception issues, ironic though that i'm getting the same error message as them.

I had played about with superpower before I had heard about toggle2g, with the help of it's sidekick add on app it was able to switch 3g and 2g flawlessly, unfortunately the superpower app itself uses more battery than my display does due to some issue with wake locks and GB 2.3.4 I think, even when i'm doing the band switching on the app manually.

Superpower development seems to have stopped.

I had thought of trying to install the sidekick app on it's own and trying to do the switching some other way.

Android is such a variable creature,I wonder us anyone else experiencing the same problems as me.

The other thing I was wondering was, with the resigning of the system apps might this stop me updating my Android market app.

cheers,

flipdee
[Android Apps and Games] eliashadow:
Good morning From Greece mister and all...

As we have already speak we want to including this VERY USEFULL app in our our!Im the one that test it 3 days nows and i have some good news and some bad news...

I have the same results with sign and update.zip both.

Good news:

2g when sleep:works

2g when low battery:works

2g when wifi enable:works

switch when charging:works

Bad news:

After first boot i have f/c to phone.apk.After the f/c all working ok cause it take superuser permission.Can we do something to avoid this f/c in first boot cause u know its a little annoying for the users of rom to see this f/c in their first boot after clean installation.

The change to 3g when i enable mobile data,most of the time doesnt working and it stay on 2g.Some times yes but most not.

The 8/10 times,after a normal reboot, the auto settings have unchecking, so i must go again to the app and choose the settings again.

Thank u very much for helping.Its for sure very usefull app thats why i dont give it up...;)

Ilias
[Android Apps and Games] TheMasterBaron:
Can you find the error in logcat and send it to me. I'll see if there is anything I can do with it.

Cheersm,

MB
[Android Apps and Games] eliashadow:
Ok...here the log to show u that it doesnt stay enable after reboot (i must get in the app to enable it).

The f/c is after a fresh install af rom before it takes su permission,so i havent log...

And i notice that if i have enable the fuction to turn 3g when i enable my mobile data, i must let phone for a while until screen off to turn it...

Anyway i have the log after rebooting...

Thank u mister.

View attachment 745279
[Android Apps and Games] xeigen:
Thanks, manage to get it working on galaxy S2..

Update: I used the widget plugin and found that u can manually switch network, eg 2g to 3g OR 3g to 2g, only if data packet is switched off. Is there any workaround for this?
[Android Apps and Games] TheInVisibleGoD:
Same problem here, doesn't change to 3g when mobile data is enabled...

Using CM7 btw.
[Android Apps and Games] xeigen:
Yup, that's what I was referring to in my previous post..

Because if you "manually" change network mode while data packet is on there will be a warning popup first and you can choose either ok or cancel, I guess that what cause this.
[Android Apps and Games] ulsa:
It did not show up for me in the app drawer.

I did flash ResignUpdateCleanup.zip directly after flashing the ROM.

I checked the permissions, same as other apks, -r-. Fixed them in recovery anyway.

I tried a few reboots.

Flashed ResignUpdateCleanup.zip again.

Had to do a factory reset to get it to show up.

If it works as you say it will be worth all the trouble though!

I'm running ienet_miuiandroid.com-1.9.30-V13.zip from:

http://xdaforums.com/showthread.php?t=1241509
[Android Apps and Games] thETImo:
So this is a replacement for Juice Defender or is it vice versa? :)
[Android Apps and Games] soCram:
Hi,

thanks for your good work! I searched a long time for a fast 2G/3G-Toggle-Widget.

I used your windows-script to include the toggle2g into MIUI 1.10.14.

First boot resulted in multiple force-closes. After "Fix permissions" in recovery everything works fine now. Anyway some Apps got lost during installing the update; maybe this doesn't happen if you precautionary choose "Fix permissions" in recovery.

Anyway, Titanium Backup helps a lot.
[Android Apps and Games] bumbernut:
Just discovered this app, what kind of battery improvement are people seeing?
[Android Apps and Games] Aiakio:
If you dont see a battery improvement, your settings are wrong or App is not working for you...^^

I doubled my Batterylife with this app! :eek:

Battery improvement comes from switching between WCDMA and GSM.

Only GSM consumes way less battery than "WCDMA Preferred".

Well, how big the imrovement is, depends on you Region..
[Android Apps and Games] cmfrtblynmb:
I got drastic amounts of improvement. It just disconnects me :) (and I have good coverage of both 2g and 3g in my area)

I guess it is not for every phone

I use cyanogenmod 7 on a cappy.
[Android Apps and Games] burnout:
Hi,

Works perfectly with modaco GR4 on Lg 2x.

Request : enable 2G when on Roaming ? Would be nice. Thanks

edit : automatically 2G when no data in roaming ? That's the solution ?
[Android Apps and Games] Aiakio:
Yes, i think so! This is when u are disconnected from your Mobile Network.

If u are disconnected u dont need WCDMA, so this option will swich your phone to 2G.
[Android Apps and Games] chareos12:
Could this be made to switch back to 3G only when device gets unlocked, rather than when screen is switched on? Great battery savings for those who use phone as a wristwatch, or popups notifications that turn screen on.
[Android Apps and Games] TheMasterBaron:
Use the notification plugin. It allows you to decide when to switch back to 3G.