PDA

View Full Version : Idea for a small but useful app... suggestions?


Dishe
2nd August 2007, 01:35 AM
I'm fairly certain this is a simple app to build, but I've got some questions I'm hoping some folks in the forum here can help me with!

Basically, I need an app that can toggle the roaming settings for my device.

The Reason:
In a nutshell, I work in a poor reception area where I need to roam on another network to get good coverage.
On the Titan (CDMA device), I get very poor battery life and dropped calls when it keeps trying to switch back to the barely visible home network. I can help keep the signal and save battery while I'm at work if I first set the service to "roaming only" when I'm there.
Problem is, switching from "automatic" and "roaming only" and back again is a very tedious process, buried under many menus and clicks.

To illustrate, I have to click Start, settings, phone, services, roaming, get settings, roaming only. Why it takes so many clicks and menus is a mystery to me, but that's the only way I've seen to do this. Even worse, some of these clicks take a couple of seconds to register before going on to the next screen, which makes this whole process take a few moments each time.

The Object:
I'd like to have an app that will toggle these settings so that all those menus and clicks aren't necessary. Then, one could even map this app to a hardware button for the ultimate ease of use!

The problem is that I don't know how to write a program that accesses that kind of internal phone information. Is this sort of stuff (roaming, forwarding, etc) even available to a developer?
Does anyone have any reference resources or tips/opinions they could share with me?

Thanks!

Dishe
3rd August 2007, 05:10 PM
:bump: no one?

shantzg001
3rd August 2007, 05:29 PM
I dont think there is much that can be done in this regard programmatically..I'd look around a bit, but dont keep much hopes..
the best possible solution for u would be to use mortscript (free), which can simmulate all those clicks and menus, and will surely provide u the same effect..
mortscript is quite easy to pickup even if u r a non-programmer and if u have had even the most basic classes of any programming language then it'll be a breeze for u..

Vinny75
3rd August 2007, 05:47 PM
I think you want to look at RIL_SetRoamingMode and RIL_GetRoamingMode.

There are three options:
Value Description
RIL_ROAMMODE_HOMEONLY
The user is restricted to the home network. The user does not roam.

RIL_ROAMMODE_AUTOMATICA
Network defined. The effect of this setting is carrier dependent.

RIL_ROAMMODE_AUTOMATICB
Network defined. The effect of this setting is carrier dependent.

AUTOMATICA or AUTOMATICB may be the roam only setting as defined by Sprint, I would set the phone to roaming only then call RIL_GetRoamingMode and see what the return value is.

There may be other ways to do this, this is just the first I've found and I'm at work so I can't test this out.

shantzg001
3rd August 2007, 06:47 PM
Dishe has a CDMA device. I dunno whether the same RIL functions are there for CDMA as well as GSM. So far I've seen hdr files and dlls for gsm ril's only, but that might be cuz I never looked around for CDMA ones ;)

Vinny75
3rd August 2007, 07:12 PM
Dishe has a CDMA device. I dunno whether the same RIL functions are there for CDMA as well as GSM. So far I've seen hdr files and dlls for gsm ril's only, but that might be cuz I never looked around for CDMA ones ;)

http://msdn2.microsoft.com/en-us/library/aa919907.aspx
"This function retrieves the CDMA roaming mode."

Dishe
5th August 2007, 04:19 AM
cool, I'm actually away for the weekend now (responding from my device), but thanks for all the helpful responses!

vinny75, I'm going to look into that when I get back and report back what I see.

Dishe
7th August 2007, 08:48 AM
Until I'm able to determine what changes internally when roaming settings are toggled, I guess I'll have to settle with something like MortScript as shantzg001 suggested for now.

MortScript is a great automation tool, I've never really played with it before! However I'd still rather have a standalone app that can determine which state is currently active, and toggle it.
In other words, with mortscript, I need to have 2 apps- a "roaming only" app, and then a "automatic" app. Ideally, I'd want one program that could detect the current setting, and switch to the other. This way, it could be mapped to a button, etc...
But I'll have to settle with what I have for now. Unless I'm missing something, you can't have mortscript toggle something that detailed, can you?
I'm new, still figuring out how to calculate x,y for mouse clicks...
Any suggestions would be welcome!

Vinny75
7th August 2007, 04:29 PM
I take it those functions didn't work?

Dishe
7th August 2007, 06:11 PM
looks like its for embedded CE, and not for Windows Mobile...
I could play with it some more, but in the mean time a simple script might be my only option...

famewolf
7th August 2007, 08:18 PM
looks like its for embedded CE, and not for Windows Mobile...
I could play with it some more, but in the mean time a simple script might be my only option...

Well you could always have mortscript alternate the mode it changes to by writing to a file "Roaming" or "Not Roaming" or something to that effect so the most you would have to do is click the button twice instead of once yes?