pocketmax
Welcome, Guest. Please login or register.
Did you miss your activation email?
July 29, 2010, 07:34:49 am

Login with username, password and session length
Search:     Advanced search
phoneAlarm v2.40 released with improved stability and many other improvements
38044 Posts in 6145 Topics by 8984 Members
Latest Member: ness
* Home Help mobile Login Register
+  pocketmax
|-+  General
| |-+  Other Questions
| | |-+  first phoneAlarm 1.60 addon : attaching network profiles to phone profiles.
« previous next »
Pages: [1] 2 Print
Author Topic: first phoneAlarm 1.60 addon : attaching network profiles to phone profiles.  (Read 4978 times)
silvio
Full Member
***
Posts: 83


Egghead


WWW
« on: July 26, 2006, 07:45:20 am »

Hello,

I've finished a phoneAlarm addon "Mobile Profiler".

It solves this problem:
I need different proxy servers and different connection settings depending the location.

How it works:
It saves a snapshot of the current network settings and attaches it to a phoneAlarm profile. Whenever phoneAlarm switches to a profile with an attached network snapshot, it will call Mobile Profiler which restore the network settings.

An example:
At home I use Wifi to connect to the internet. So I have created a network "home" with no GRPS settings and no proxy server settings and selected this as the default for internet connections. With Mobile Profiler I have created a snapshot of this state an attached it to the phoneAlarm home profile.
In my company my Pocket PC is connected via ActiveSync and it needs a proxy server to get to the internet from there. So I have created a "work" network entry with the correct proxy settings as default for internet connections, created a snapshot with Mobile Profiler and attached this snapshot to the phoneAlarm company profile.
On the road I use GPRS for the internet. So I have created a "gprs" network entry with the GPRS settings as the default for internet connections. And after another Mobile Profiler session this network snaphot is attached to the Loud-, Car- and Meeting phoneAlarm profile.

Now wherever I am, phoneAlarm selects the correct Network for my busyness. PushMail will start automatically when the GPRS snapshot is active.

Here you may get this addon:
http://www.iaccarino.de/silvio/ppcstuff.htm#MobileProfiler


regards,
Silvio

PS: Advanced users could enhance and modify the Mobile Profiler snapshot functionality to get more settings attached to phoneAlarm profiles. Contact me for further informations.
« Last Edit: September 20, 2006, 06:07:29 am by silvio » Logged

XDA Neo, XDA Phone
penguin
Administrator
Hero Member
*****
Posts: 14560



« Reply #1 on: July 26, 2006, 03:17:11 pm »

Hi,

Nice work - might save me some effort on similar pA function  wink
Logged

cheers
Bruce (pocketMax)
______________________
(HTC Diamond, Omnia, TyTn, Treo 750v, Neo, MDA Pro, iPaq 514, Qtek 8500, MDAIII, MDAc , Samsung i700, Dell X30)
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #2 on: July 26, 2006, 06:39:08 pm »

until you change the pA registry keys...
Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #3 on: July 27, 2006, 02:04:38 am »

For HTC Prophet (XDA Neo etc.) users with the annoying backlight timeout bug (backlight switches off every 10 s.):
Copy the content of the attached file into the \My Documents\MobileProfiler directory - in every new snapshot the timeout bug will be fixed automatically.

You may manipulate existing snaphots by including this code in the snapshot (as you may see in trick no. 1):
Code:
<characteristic type="Registry">
  <characteristic type="HKCU\ControlPanel\BackLight\LockLevel">
      <parm name="LockLevel" datatype="integer" value="0"/>
   </characteristic>
</characteristic>

If there is already a "<characteristic type="Registry">" section, you should combine the code so there is only one "<characteristic type="Registry">" section in the snapshot.

* Cleanup.zip (0.44 KB - downloaded 146 times.)
« Last Edit: September 15, 2006, 05:00:59 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #4 on: July 27, 2006, 03:08:57 am »

Enhance your Mobile Profiler snapshots - Trick No. 1:

If you have made some snapshots and you want to receive full mails in a specific snapshot and mail headers only in other snapshots, go to the \My Documents\MobileProfiler folder - every snapshot is stored in an Unicode XML file. Copy the snapshots to your PC and open them with a unicode aware editor (eg. Windows Notepad ).
You'll see a html like file structure like this:
Code:
<?xml version="1.0" encoding="utf-16"?>
<wap-provisioningdoc>
  < ... blah - blubb ... />
</wap-provisioningdoc>

Append this code to your snapshot in the line above the "</wap-provisioningdoc>" tag:
Code:
<characteristic type="Sync">
  <characteristic type="Mail">
    <parm name="MailBodyTruncation" value="-1"/>
    </characteristic>
</characteristic>

Now in this snapshot the full mail will be downloaded.

Change the value "-1" to "0" to receive the mail headers only or to a value like "512", "1024" or "5120" to receive the amount of bytes.

Copy the manipulated snapshots back to the NetManager folder.

I use this trick to get mail headers only via GPRS and full mails via ActiveSync and Wifi.
« Last Edit: September 15, 2006, 05:01:54 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #5 on: July 27, 2006, 03:47:41 am »

Enhance your Mobile Profiler snapshots - Trick No. 2:

You may want to exclude or include some mail folders from sync in specific profiles (eg. excluding the junk mail folder sync under GPRS based connections). You can do this by manipulating your Mobile Profiler snapshots like you did it in trick no. 1 - use this code:
Code:
<characteristic type="Sync">
  <characteristic type="FolderHierarchy">
    <characteristic type="Junk-E-Mail">
      <parm name="SyncEnabled" value="1"/>
    </characteristic>
  </characteristic>
</characteristic>

You may include or exclude any folder you like (not only "Junk-E-Mail") an maybe more then one folder.  Set the value to "0" to exclude this folder from sync.

If you use trick no. 1 too you should combine the codes below the "<characteristic type="Sync">" tag, so there is only one "<characteristic type="Sync">" tag in the snapshot.
« Last Edit: September 15, 2006, 05:02:24 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #6 on: July 27, 2006, 04:18:39 am »

Total controlling - the magic of phone profiles.

As you may see in the tricks above Mobile Profiler and phoneAlarm are a very powerfull combination for controlling your phone.

There are much more things you may put into your snaphots. If you use your brain and want to do crazy things with your phone study this web site:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/DevGuideSP/html/sp_wce51grfavailablecspsforwindowsmobile-baseddevicesozup.asp

I would be very pleased to see new codes and tricks in this thread or in the german speaking thread:
http://www.ppc-welt.info/community/showthread.php?p=741418

By the way - the XML files create.snapshot and cleanup.snapshot are used by Mobile Profiler to create new snapshots. The content of cleanup.snapshot will be inserted in front of any new snapshot.
« Last Edit: September 15, 2006, 05:03:15 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #7 on: July 28, 2006, 06:35:37 am »

a new version is out and it is also available as zip file for manual install because phoneAlarm has problems with spaces in paths and the default path for cab installations on english devices has spaces in the path (\Program Files).

http://www.iaccarino.de/silvio/ppcstuff.htm#MobileProfiler

the new version creates an error dump in your \temp folder - if you do some experiments with modified XML files the dump will help you to find errors in your modifications.

Another enhancement: now you will be notified, when a new snapshot is going to be activated.
« Last Edit: September 15, 2006, 05:03:53 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #8 on: July 31, 2006, 07:29:01 am »

New version 1.4 is out.
Project was renamed (previous name was NetManager) because of collision with existing software - the new project name is Mobile Profiler now.
What's new:
  • supports phoneAlarm 1.5x (lite) now too
  • stand alone mode
  • query mode for advanced users
  • error output in \temp folder
  • visible notifications during switching phase
  • a detailed user guide (see containing readme.htm)
Because of the new project name you have to reassign all snapshots once - sorry.

Project home page :
http://www.iaccarino.de/silvio/ppcstuff.htm#MobileProfiler
« Last Edit: September 15, 2006, 05:04:59 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #9 on: August 01, 2006, 02:33:27 am »

Enhance your Mobile Profiler snapshots - Trick No. 3:

How to use different IP settings for networking depending the phone profile.

To change the IP settings of your device Mobile Profiler has to read and write registry keys. Because the key is device specific you have to locate the correct key. The best way to do this is to enter a fixed IP number and to search for the IP number in the registry (eg. with Resco Regedit).
On HTC Prophet (XDA Neo, QTek S200, ...) devices the WiFi IP settings are stored in HKEY_LOCAL_MACHINE\Comm\TNETWLN1\Parms\Tcpip.
Once you have located the correct key you may create and execute a query to see which parameters you have to change:

Code:
<?xml version="1.0" encoding="utf-16"?>
<wap-provisioningdoc>
  <characteristic type="Registry">
    <characteristic-query type="HKLM\Comm\TNETWLN1\Parms\Tcpip" />
  </characteristic>
</wap-provisioningdoc>

This query.xml will generate a result.xml file with all parameters. As you can see you have to use short formed registry key names for the root keys:
HKEY_LOCAL_MACHINE = HKLM
HKEY_CURRENT_USER = HKCU
HKEY_CLASSES_ROOT = HKCR

Unfortunately the result of this query doesn't contain the types of all the values - so it is impossible to put this query into the CreateSnapshot.xml. You have to query every single value to receive the correct value type:

Code:
<characteristic type="Registry">
  <characteristic type="HKLM\Comm\TNETWLN1\Parms\Tcpip">
    <parm-query name="EnableDHCP" />
    <parm-query name="IpAddress" />
    <parm-query name="Subnetmask" />
    <parm-query name="DNS" />
    <parm-query name="DhcpIpAddress" />
    <parm-query name="DhcpSubnetMask" />
    <parm-query name="DhcpDNS" />
    <parm-query name="DhcpServer" />
  </characteristic>
</characteristic>

With this part in your create.snapshot Mobile Profiler will read and restore the minimum required IP settings of the device TNETWLN1.

One problem is left:
if you assign snapshots with specific IP settings to phoneAlarm profiles, phoneAlarm is not able to switch on the networking device with the correct settings, because phoneAlarm switches the networking device on before it runs Mobile Profiler.
So you have to switch on your networking device manually until a later phoneAlarm version may includes the feature to execute external programs before profile switching...
« Last Edit: September 15, 2006, 05:05:44 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #10 on: August 04, 2006, 06:36:09 am »

There is a new version 1.6 out - with this version you can stop and restart ActiveSync.
Some parameters you may want to integrate into your snapshots affects a running sync - especially those for <characteristic type="Sync">.
As a side effect GPRS/UMTS users with an internet Exchange account can stop or force a pushmail session.
Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #11 on: September 08, 2006, 04:33:11 am »

New Version 1.7 is out now:

You can switch on and off Bluetooth before and after a snapshot gets active - this is necessary if you modify bluetooth parameters with your snapshots.

You can execute a program (optional with commandline) before and after a snapshot gets active. Mobile Profiler can wait until the program terminates. You may use this feature to assign batch scripts (SK Schema, Mort Script) to a snapshot.

More examples in Readme (eg. howto include Opera settings in your snapshots, howto activate pushmail via snapshots)

More fun...
Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #12 on: September 14, 2006, 05:26:12 am »

New version 2.0 is out
http://www.iaccarino.de/silvio/ppcstuff.htm#MobileProfiler

It is completely revised now and has some new functions:

Mobile Profiler reminds the active snapshot so if you switch to a phone profile with an assigned snapshot which is already active, it wil not be activated again. This will preserve existing GPRS/UMTS connections. In standalone mode a snapshot will be activated although it is active.
You will embrace this feature if your provider discounts data transfer in packages - activating a "GPRS" snapshot twice will break an existing connection and an inchoate packet will be lost.

There is a simple XML Editor included now. It can reformat XML spaghetti code to human readeable code (Ctl+r).

There is a desktop setup programm now.

English is the default language now.

Snapshots will be stored in the \My Documents\MobileProfiler folder. This folder can be better synchronised via ActiveSync (eg. to edit the snapshots with a desktop XML editor).

Existing Users of Mobile Profiler prior the 2.0 version have to do some work to migrate their old snapshots and phoneAlarm assignments for the new version. You may read about this here:
http://www.iaccarino.de/silvio/stuff/MBMigration.htm


Since Mobile Profiler uses it's own document type now (.snapshot instead of .xml) phoneAlarm can activate snapshots wherever they resides - in previous versions phoneAlarm was unable to activate snapshots if Mobile Profiler was installed into a path that contains space characters.
« Last Edit: September 15, 2006, 05:06:25 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #13 on: September 15, 2006, 05:13:14 am »

Bugfix Release 2.1 is out

http://www.iaccarino.de/silvio/ppcstuff.htm#MobileProfiler

No new functions but you may use other fontsizes and manipulate the spaghetti code reformatter by creating some registry values:

For the XML Editor:
HKEY_CURRENT_USER\Software\Iaccarino\MobileProfiler\Editor

(DWORD)fontsize
Fontsize in points

(DWORD)indent_char
ASC value of the character which is used for ident (eg. 32 for space, 9 for tab)

(DWORD)indent
Count of characters for each ident level

For the standalone mode:
HKEY_CURRENT_USER\Software\Iaccarino\MobileProfiler\Selector

(DWORD)fontsize
Fontsize in points
« Last Edit: September 20, 2006, 06:07:09 am by silvio » Logged

XDA Neo, XDA Phone
silvio
Full Member
***
Posts: 83


Egghead


WWW
« Reply #14 on: September 20, 2006, 06:06:15 am »

New release 2.2
  • Bugfixes
  • Better look & feel
  • viewer with syntax highlighting (colours on WM5 only)
  • New modus "Select" - will display only snaphots that can be activated - good solution for hotkeys
  • Error output in the standard document folder instead of \temp
  • Duplicate function - duplicate a snapshot to create a new one to manipulate it

If you miss the phoneAlarm automatic profile lock functionality, you may add this into your snapshots to lock the current phone profile:
Code:
<!-- exec after "paWakeup.exe" "-ll"-->

« Last Edit: September 20, 2006, 06:08:32 am by silvio » Logged

XDA Neo, XDA Phone
Pages: [1] 2 Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!