On Thu, 2007-12-27 at 12:25 +0000, John Carr wrote: > I like the idea of dbus activation, and using HAL to automatically > close sync-engine when the device is unplugged, but am not how the > device will cope if it is plugged in and the HTTP server for AirSync > is not responding straight away. >
One doesn't need to close sync-engine when a device is unplugged - or restart it when a device is plugged in. The problem is starting it the first time - once it is started it can be left running throughout the session. I am looking at some modifications to sync-engine to allow it to fork itself into the background and log to a file - all that has to happen then (as with now) is for the user to include it in a suitable startup file. Thanks to a patch from Guido Diepen sync-engine will also now start cleanly in the absence of a running odccm and pick up the connection when odccm comes alive. If we make an init.d script for odccm (so it starts as root: I'll do a quick one for SuSE if you like and pop it in the odccm tree) and place the call to sync-engine in a user's startup file for whatever environment is chosen, then everything should work. All we need to do now is to find a way to terminate OpenSync cleanly if the sync-engine is not running or a device is not connected. This should be easy in OpenSync 0.3x but may be troublesome in the earlier releases. I am working on this. There are some remaining error-handling issues in sync-engine which require a restart of sync-engine to clear (e.g. RAPI call failure/timeout). Once these are cleared sync-engine should run happily in the background. John. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ SynCE-Devel mailing list SynCE-Devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/synce-devel