Bakulin Ilya wrote (2008-03-24 16:00:11):
> Very glad to see you as FreeBSD & SynCE user! I have some questions to you:
> 1. What application are you syncing with?

I mainly sync with kde-pim. I also sync with file backend to keep a backup 
around.

> 2. What PDA do you have? I tried to use uppc-kmod driver and get this
> error: ==============
> ucom0: <HTC USB Serial for Wizard, class 0/0, rev 2.00/0.00, addr 2> on
> uhub1 ucom0: failed to set configuration, err=STALLED
> device_attach: ucom0 attach returned 6
> ==============
> , while uipaq driver works fine. Of course, FDI rule remains the same
> because upper-level driver (ucom) remains the same.

I have a HTC TyTN with official WM6 ROM. Oh yes, I had to patch the uppc 
driver to use configuration 0 instead of 1 (line 134 in uppc.c). I have used 
uipaq too, but found a port easier to patch so that csup'ing the latest 
kernel won't overwrite my changes. uppc driver also feels a bit more stable. 
uipaq used to panic from time to time.

> > The first patch, hal-freebsd.patch, addresses a few FreeBSD specific hal
> > DCCM issues. First, linux/if.h header doesn't exist on other platforms. I
> > think net/if.h should work on Linux too, but I ifdef'd it just in case.
> > Second issues was that usb-rndis-ng rule in 10-synce.fdi created some
> > conflicts so I removed it. I also tried to make the FreeBSD ucom rule
> > more general.
>
> What exactly conflicts were caused?

When I plug my PDA in HAL creates two 
devices: /org/freedesktop/Hal/devices/usb_device_bb4_ce_noserial_if0 
and /org/freedesktop/Hal/devices/usb_device_bb4_ce_noserial. Without removing 
the usb-rndis-ng rule sync-engine got confused because both device entries 
have sync capabilities and friends (thanks to that rule), but only one has 
the entries like pda.pocketpc.name. Depending on luck sync-engine might find 
first the device entry that hal-dccm handles, or the one that is unhandled 
and gets confused.

> >Then I made some adjustments for hal-synce-legacy script. There were few
> > other things I noticed: device file handling did not work at all on
> > FreeBSD, FreeBSD ppp doesn't support linkname, and last, at least on my
> > computer, HAL 0.5.11rc2 doesn't set environmental variable HALD_ACTION.
> > HAL also searches the scripts only from $prefix/libexec so I adjusted the
> > Makefile accordingly.
>
> I used hal-0.5.10 (of course not from ports) and HALD_ACTION exists
> there... Will try with 0.11 soon. I also removed all linkname stuff, and
> used /dev/cuaU${HAL_FREEBSD_UNIT}.

Ok. That HALD_ACTION issue is weird. I believe it should be there, but anyway 
the script doesn't see it. I have to investigate this further.  I think there 
is not much difference between cua and tty in this case.

> > The third issue the second patch fixes is something I had quite hard time
> > to figure out. It seems that rapi contexts are created and stored into
> > TLS so they are per thread. So when the rapi context is created in main
> > thread in kernel.py and used later in another thread in synchandler.py,
> > librapi method rapi_context_current() returns new, uninitialized context,
> > that results in sync-engine crash. I fixed this by creating and using a
> > new rapi context in SyncHandler.run() method. This makes the thing work.
>
> Great! Now SynCE doesn't coredump while syncing to Google-calendar.
> (instead, Google calendar doesn't work, don't know why yet) :)))
>
> > At least hal-synce-legacy and 10-synce.fdi need some work to be platform
> > independet, but now the thing works on FreeBSD.
>
> Yes, but now HAL also invokes synce-scripts when plugging in USB2COM bridge
> (PL2303-based in my case. I actively work with ARM- and MIPS-based
> development boards and use these bridges because my laptop doesn't have
> ordinary COM ports). This is not good. I think that we should hack HAL
> itself to include information about lower-level driver (uipaq, uppc) in
> ucom-based device node... Or add info about more PDA vendors to
> 10-synce.fdi :-)

Ok. That can be possible. It would be great to find out the exact driver from 
HAL. I don't think there is any hassle free solution for this currently.

Yours,
        Markus

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
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

Reply via email to