Auto connect ActiveSync via BT (when in range), auto A2DP & more

Search This thread

dmkpoznan

Member
Aug 10, 2008
20
0
Poznan
AutoActiveSync via BT

I’m using Windows Mobile devices for years. And I like this OS and devices, but I found one big mistake (comparing to Nokia for example). There is no way to auto-connect ActiveSync via BT. For example Nokia e50 connect to synchronization software when is in range! I now, that this could be because of architecture of WM devices (for example deep suspend and problem with waking device up and checking… blah blah).

Ok, I decided to create small software to auto-connect via BT when in range of Bluetooth cradle (your device could be on or suspended).

There is two settings:
• first: select device from list (device must be paired – this device is computer with ActiveSync profile)
• second: select interval of searching (in suspend and in powered on mode) – this settings are in milliseconds. Please don’t set less then 15000 (15 sec)! Remember that less value cause your device to more often wake up from suspend to unattended mode and check for device if is in range (this could drain battery). My setting is 120 sec (120000 ms) - now I’m testing this value.

How does it work? It is looking for some system states before looking for specified by user BT cradle and allowing to connect:
• device can’t be connected to cradle (any other connection by USB or manual via BT will be detected)
• device can’t be connected to BT A2DP or BT Hands Free (this is to prevent of audio interruptions)
• device must be charged over “VeryLow” state (I think this is around 20%) or being connected to charger

How to use it? After first run (if You use cab please run it again to show settings window) You must select your ActiveSync BT destination device and set interval. Then click “Save” and “Hide Window”. If you like to exit application – just click “Exit”. The device will look for cradle every _your_interval_ of time (in sleep also). The application window must run in background for now (for people who use for example HTC Task Manager – you can add this window to special applications). And when device detected in suspend mode possibilities to connect the program will wake up device, connect and in maximum 10 second put device back to sleep (unattended mode).

Warning! Remember, that not only searching for device via BT could drain your battery. When ActiveSync is connected via BT and device is in suspend mode in real it is unattended mode. It mean, that for example CPU is working normally (not in deep suspend) and draining battery.

Registry. This software store settings in registry, right here: HKCU\Software\AutoActiveSync

Questions & Sugestions Write here, but please remember, that I have limited free time – I will try to answer, but sometimes this could be difficult (to find this free time). And sorry for my bad english ;)

What you need? You need only .NET framework 3.5 & Windows Mobile 6+ (because I use 6 SDK).

Update 19.07.2009:

Ok, version 2.0 published.

What's new? Application has been rewirted. Now it is working as managed service (in background - no more running window!). I tested cpu usage and minimized ram usage - now it's getting less ten 0.5% of CPU and only 450KB of ram (can't get lowwer - .NET :). There is also two new features:
• disable wifi (after connecting by bluetooth to cradle - personaly I don't need two connections...)
• autoconnect to a2dp profile (if bluetooth headset is present - I used for many days AutoA2DP from this froum (thanks for author), but I decided to create for me "all in one")

Usage. After installing please run AutoActiveSync from start menu (this is only configurator - you must configure it before first usage). Then just run the service (on first tab). After restarting device service will autostart (via startup folder in Windows directory). Please note, that application can crash before accepting usage of unsigned dll's! For me the best solution is to disable checking it.

If you have problem... let me know ;)


Update 03.10.2009:

Version 2.5 is out :)

What's new? There is a lot of small improvements, some code has been optimized and rewritten. I added scheduling (for now for daily cycle, but I am thinking about week cycle), some tweeks to ActiveSync module, some to A2DP module (please run and check, what is new – for this version in my opinion there is no need to write manual).

What you need? Still .NET framework 3.5 & Windows Mobile 6+ (because I use 6 SDK). There will be no support for 5.0/2003SE because I have no time
to rewrite part of this software without SDK for WM6.

In next release could be… I’m thinking about adding AutoWifi – auto connect to open wifi networks, and test if there is internet access (but integrating with windows mobile WiFi manager!). I used for 15 minutes WeFI but for me this Was bad written program (slow & ugly & crashing..). Maybe someday I will add possibility to create some “scripts” for automating some tasks based on conditions, but this is long term plan… (not for next release).

Please try and let me know is this working :)

2.5.1 released!

There is bug fix for scheduling and new feature - auto disable GPRS/EDGE/HSDPA connections in roaming.

2.5.2 released!

Please install 2.5 and then unzip 2.5.2 and copy to program files folder (before that stop service and exit configurator!).

There is bug fix for scheduling (now tested) and new feature - allow enable wifi using Comm Manager when autodisabled after connecting to A2DP or ActiveSync.



autoactivesync25main.png
autoactivesync25actives.png
autoactivesync25a2dpf.png
 

Attachments

  • AutoActiveSync_v1.0.cab
    148.4 KB · Views: 477
  • AutoActiveSync_v1.0.zip
    149.8 KB · Views: 247
  • AutoActiveSync_2.0.cab
    451.1 KB · Views: 1,802
  • AutoActiveSync_v2.5.cab
    172 KB · Views: 1,855
  • AutoActiveSync_v2.5.1.zip
    177.6 KB · Views: 337
  • AutoActiveSync_v2.5.2.zip
    177.3 KB · Views: 3,406
Last edited:

htc-alb-1

New member
Jan 18, 2009
3
0
Hello this is a great job, do you have an idea how can make it start as a service, I mean I know how to make it start with WM6 but how can I give AutoSync the good arguments to make it start with in backgroup with the right device and time interval ?

Best regards.
 

dmkpoznan

Member
Aug 10, 2008
20
0
Poznan
Hello this is a great job, do you have an idea how can make it start as a service, I mean I know how to make it start with WM6 but how can I give AutoSync the good arguments to make it start with in backgroup with the right device and time interval ?

Best regards.

Settings are saved in registry, so there is no need to run it with arguments. For now I am testing rewritten version as service with many improvments, and features added (like AutoA2DP connect or "disconnect wifi" when in range of AS). I will publish new version this week (there is no more problem with running application in background etc. - now this is service + configuration app + helper for running in suspend mode).
 

Zom

Member
Jun 1, 2006
11
0
But not for long

Settings are saved in registry, so there is no need to run it with arguments.

This app shows great promise and works OK except the registry entries do not stay set. Each time I exit and restart AutoActiveSync the registry entries go to default. They are OK after exit, but are defaulted when I start AutoActiveSync. Is there any way to make the registry entries stay?

[Touch HD - WM6]
 

dmkpoznan

Member
Aug 10, 2008
20
0
Poznan
Ok, this weekend I will post service (tested - I believe, that everything is working and writed in good way). Sorry for late, but last week my disk in notebook decided to die (aghr... 6 mounths old Hitachi with ThinkPad active protection system... grrr).

Best regards!
 

Zom

Member
Jun 1, 2006
11
0
Service works well. Have used for days now and it connects and disconnects as it should. Restarts on power up too. Well done!
 

htc-alb-1

New member
Jan 18, 2009
3
0
Working great for me too, i added the service.exe to the startup on the WM to get sure it is always runing after a reboot.

Nice job !
 

Qukace

Senior Member
Jul 16, 2008
73
0
Samsung Galaxy S22 Ultra
Thanks the very beneficial prog.

Is it possible to limit the running period? :confused: I mean allow to start the prog. 8h00 AM and not allowd after 22h00 (10h00 PM). During the sleeping time there is not need to sync (My laptop is switched off in the night).

Thanks
 

dmkpoznan

Member
Aug 10, 2008
20
0
Poznan
Ok, I will think about time scheduling soon! This could be good idea, but personally my notebook is always on ;-) (I know, I know... I am crazy).

The problem with Toshiba stack - could be. What version of WM do you have? I tested it only on WM 6.1 and higher version.
 

crashxp

New member
May 19, 2008
1
0
Works fine on ETEN X800 WM 6.0. Greate work :)

I only found one small mistake: it's installed on german devices at '\Program Files' instade of '\Programme' (where all other programs are installed by default)
 

nir36

Retired Moderator
Dec 5, 2007
3,858
339
Jerusalem
www.sq-web.com
2 suggestions if i may:

1. I believe that time scheduling is a must in such an application.
If i'm not mistaken, most people don't spend most of their time around their laptop and there is no need to have it running all the time.

2. It would be wise to have the option to run it only once, at a specific time during the day, so that you don't get disconnected everytime you move away from your comp and then connected when you are close to it.

That is, I know that my laptop is on everyday from about 21:00 to 00:00 (for example) so i'll have it either run once during those hours to sync once.. and then stop trying, or have it try to connect during those 3 hours, but if i managed to connect, have it stop working so that i don't sync 2000 times during those 3 hours.

I've been looking to autoactivesync using bluetooth in a comfortable manner a while back, and this is a perfect solution.

Thank you very much.
 

sztyopi

New member
Jun 12, 2009
2
0
Square screen

Hi, I have a 320x320 square screen (Palm Treo Pro). I can not fully see the lower button under the "Start/stop" service button. What is this button, anyone? :confused:

Anyway thank you for the application! :)
 

onesolo

Senior Member
Apr 18, 2006
2,580
227
Nexus 7 (2013)
Google Nexus 5
Wow!!!!
Finally an app to make autoconnect to Activesync via BT!!! Many thkx, it works like a charm on my Touch HD!!!

Is there any command for the Connecting button??

I think I found a possible bug.
If I disconnect on the big Disconnect button and then make save (left softkey) and exit, the program after a few minutes/seconds reconnect again the device to the Activesync... try to fix this please... very annoying
 

onesolo

Senior Member
Apr 18, 2006
2,580
227
Nexus 7 (2013)
Google Nexus 5
Wow!!!!
Finally an app to make autoconnect to Activesync via BT!!! After so many years in the winmo never found a free or payed app that did this...
Many thkx, it works like a charm on my Touch HD!!!

Is there any command for the Connecting button??

I think I found a possible bug.
If I disconnect on the big Disconnect button and then make save (left softkey) and exit, the program after a few minutes/seconds reconnect again the device to the Activesync... try to fix this please... very annoying
 

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    How about changing the strategy

    If I understand well it's the phone which try to connect to the PC by checking wether the computer is in range and thus emitting the signal.

    But would it be possible to do the contrary?
    How about having the computer sending the signal to connect to the phone and as soon as the phone get this particular signal it will then try to connect to the PC by launching activesync?
    Of course this involve some programing for the PC. Some sort of server stuff I guess.
    By the way, I just got a 26000 mA battery so I don't mind having the phone always on with the BT on.