Funambol přes bluetooth

Tento článek popisuje konfiguraci serveru Funambol, který se používá pro synchronizaci s mobilními zařízeními.
Zároveň se zabývá otázkou synchronizace přes bluetooth.

http://bluez.sourceforge.net/contrib/HOWTO-PAN

Bluetooth PAN nabízí mimo jiné podporu IP přečs bluetooth (L2CAP), což je v podstatě srovnatelné s Wireless LAN na PC.

Je možné využít následující modely:

– PAN user (PANU):
Kleint NAP nebo client-type člen GN (viz níž)

– Skupinaový ad-hoc Network (GN) kontrolér:
Forwarding nodů v peer-to-peer style network (Bluetooth Piconet).
Interconnects up to 7 (active) PANUs to a real peer-to-peer network.

+——+ +——+ +——+
| PANU | | PANU | | PANU |
+——+ +——+ +——+
\ | /
\ | /
\ | /
\ | /
\ | /
\ | /
\ | /
+———+
| GN |
+———+
/ | \
/ | \
/ | \
/ | \
/ | \
/ | \
+——+ +——+ +——+
| PANU | | PANU | | PANU |
+——+ +——+ +——+

– Network Access Point (NAP):
Acts as proxy, router or bridge between an existing network infrastructure
(typically LAN) and (up to 7 active) wireless clients (PANUs).

+====================+
| LAN Infrastructure |
+====================+
|
|
|
+———+
| NAP |
+———+
/ | \
/ | \
/ | \
/ | \
/ | \
/ | \
+——+ +——+ +——+
| PANU | | PANU | | PANU |
+——+ +——+ +——+

Hlavní nastavení

Aby bylo možné využít PAN funkcionalitu BlueZk potřebujeme tyto balíčky:

BlueZ-Kernel (obsaženo v CentOS)
BlueZ-Libs   (obsaženo v CentOS)
Bluez-Utils  (obsaženo v CentOS) 
BlueZ-SDP    (v CentOS obsaženo v balíčku bluez-utils)
BlueZ-PAN    (v CentOS obsaženo v balíčku bluez-utils)

Jakmile je vše připraveno ujistíme se, že hcid běží a BlueZ device je „up“
(tj. ‚hciconfig‘ ukazuje číslo zařízení, adresu atd…)

Pro nastavení PAN nodu bude možná zapotřebí zavést modul do jádra:

# modprobe bnep

Nyní můžeme nastartovat PAN proces (‚pand‘) nod.
Na straně serveru použijeme parametr listen (viz help)
a použijeme jednu z rolí:

# pand –listen –role PANU
nebo:
# pand –listen –role GN
nebo:
# pand –listen –role NAP

Na GN a NAP straně se má BlueZ device schopnost chovat jako master.
proto tedy přepínač master/slave má být zapnut v konfiguračním souboru ‚/etc/bluetooth/hcid.conf‘:

lm accept, master

Možná bude třeba ho odkomentovat v defaultní verzi ‚/etc/bluetooth/hcid.conf‘.)

Alternativně lze také použít príkaz pand s parametrem — master

Nyní můžeme zřídit jasné spojení mezi PANU a GN nebo NAP, respektive z dalšího nodu:

# pand –connect

Zde je příklad:

Pro připojení PANU nodu (00:37:5C:67:D3:01) s GN (00:37:5C:67:D3:02),
BlueZ musí být spuštěn na obou stranách
GN musí být schopen běžet jako Bluetooth master (viz výš).

Zadáme:

# modprobe bnep

na obou nodech.
Pak zadáme:
# pand –listen –role GN

na straně GN.

Poté se můžeme připojit ze strany PANU:
# pand –connect 00:37:5C:67:D3:02

V případě prolémů najdeme infomrace v logu (/var/log/ (tj. ‚messages‘
a ‚warn‘).

Je dobré staartovat pand jako server na GN (nebo NAP)
raději než PANU, jelikož pak budete mít trvalý přístup z každého PANU. When you do so, ‚pand‘ permanently listens for
Připojení přicházející z ostatních módů se tak stane trvalé.
V případě, že máme pouze jeden PANU, nicméně, můžete také swapovat role a
startovat ‚pand‘ jako server (tj. s použitím parametru ‚–listen‘ na straně PANU
a připojit se ze strany GN nebo NAP.

SDP

Volitelně ‚Service Discovery Protocol‘ (SDP) může být užit uvnitř ‚pand‘
k registraci GN nebo NAP jako SDP-searchable služby.
Pro použití SDP se ujistěte, že ‚sdpd‘ běží.
SDP je aktivován současně s ‚pand‘ když je ‚pand‘ spuštěn jako GN nebo NAP:
# pand –listen –role GN –sdp
nebo
# pand –listen –role NAP –sdp

V tomto případě jednoznačné spojení mezi PANU a GN nebo NAP je vytvořeno následovně:

# pand –connect –service GN
nebo
# pand –connect –service NAP

s odpovídající GN/NAP službou u cílového hosta.
Opět spojení může být také vytvořeno ze strany NAP/GN, takže role jsou vyměnitelné.
swapped.

Vyhledávání komunikačních klientů

Aby byl život snažší v případě, že neznáte adrsu zařízení Vašeho požadovaného komunikačního partnera,
volitelný parametr‘–search‘ Vám umožní vyhledat PAN komunikační partnery. Např:

# pand –role PANU –search [doba_trvání]

vykoná Bluetooth vyhledávání po PAN zařízeních v okolí a pokusí se připojit ke objevenému zařízení.
Vyhledávání nepokračuje déle než je ‚duration‘ jednotka 1.28 sekundy.

Použití SDP umožňuje vykonat vyhledávání selektivněji. Např.:

# pand –role PANU –search –service NAP –sdp

bude hledat a připojovat pouze NAP nody.

V případě problémů lze nalézt výsledek pand vyhledávání ve’/var/log/messages‘.
Pomoci může i další kontrola pomocí ‚hcitool scan‘.

Rozhraní

Během založení spojení(může to trvat několik sekund), se vytvoří virtuální síťové rozhraní ‚bnep0‘
na obou nodech. Toto rozhraní může být konfigurování (stejně jako každé jiné síťové rozraní) pomocí příkazu ‚ifconfig‘.

Například na GN:

# ifconfig bnep0 10.0.0.1

nebo na PANU
# ifconfig bnep0 10.0.0.2

To vytvoří privátní IP síť s rozsahem adres 10.x.x.x
Nyní je možné aby nody mezi sebou navzájem pingaly.

Normálně, ale není tonezbytné je možné konfigurovat ‚bnep0‘ ručně.
Linuxový „hotplug“ mechanismus, který umožňuje odpovědné přidělení IP addres
(statických addres neboDHCP) klasickým ethernetovým adapterům může dělat tu samou práci
pro naše PAN.for our PAN
Proto je nezbytné umístit konfigurační soubor
‚ifcfg-bnep0‘ do adresáře /etc/sysconfig/network-scripts/ (Redhat).

Pro statické adresy, ‚ifcfg-bnep0‘ bude vypadat podobně:
DEVICE=bnep0
BOOTPROTO=static
IPADDR=10.0.0.1
NETMASK=255.0.0.0
ONBOOT=no

Pro DHCP, ‚ifcfg-bnep0‘ bude vypadat podobně:
DEVICE=bnep0
BOOTPROTO=DHCP
ONBOOT=no

U SuSE 8.0, ‚ifcfg-bnep0‘ (v /etc/sysconfig/network/) pro statické adresy bude vypadat podobně:
BOOTPROTO=static
IPADDR=10.0.0.1
NETMASK=255.0.0.0
STARTMODE=hotplug

Mimo to, yje třeba nastavit ‚HOTPLUG_NET_DEFAULT_HARDWARE=net‘
v souboru /etc/sysconfig/hotplug (SuSE 8.0).

Pro další distribuce podrobnosti naleznete zadáním příkazů
‚man hotplug‘ a/nebo ‚man ifup‘.

V případě problémů prohlédněte logy.

Soubor ‚ifcfg-bnep0‘ sám je zpracovaný vždycky,když je vytvořen ‚bnep0‘.
Síťové rozhraní ‚bnepx'(‚bnep0‘ je první z nich) jsou vytvořeny
(a smazány) plně dynamickým způsobem, tj. jedno zařízení je vytvořeno přes
PAN připojení a pojmenováno ‚bnep0‘, ‚bnep1‘ atd.
Ačkoliv toto chování obvykle nezpůsobuje problémy na straně PANU
(memáme tu rádi více než jedno PAN připojení)
to čistě znamená problém při skupinové ad-hoc síťi
kde se u GN předpokládá služba do 7 aktivních PANU.
Budete chtít mít 7 virtuálních síťových rozhraní
(s rozdílnými IP adresamy pro každý jeden BT adapter (nod)?
Mimo to budete potřebovat několik (max. 7) ‚ifcfg-bnepx‘ konfiguračních souborů
k autokonfigurování individuálních rozhraní a 7 různých adres??

Ethernet Bridging

Pro vyhnutí se výše uvedené situaci přichází „802.1d Ethernet Bridging“ (od 2.4.x Linux kernelu)
Hlavní myšlenkou je, že se spojují dvě síťové vrstvydohormadu do nové sítě.
Pro BlueZ PANs, to učiníme také tak: spojíme odělená síťová rozhraní do jednoho (nového)

Před aktivací pro pořádek ověříme, že je vše připraveno:
# make menuconfig

Vyberte „Networking options“ -> „802.1d Ethernet Bridging“ (jako část modulu kernelu).
Pokud změníte nastavení, nezapomeňte zadat:
# make modules
# make modules_install

aby se skutečně vytvořily nové moduly jádra. A reboot.

Modul jádra pro bridge vyžaduje doplňkové kontrolní softwarové balíčky, které se jmenují
„bridge utils“, které často nebývají součástí Linuxových distribucí.
Pokud je to tak, je možné je stáhnout z adresy http://bridge.sf.net.
Pro většinu distribucí jsou k dispozici rpm balíčky. Pokud ne je možné stáhnout
zdrojové kódy a bildovat balíček.

Konečně máme funkční ‚brctl‘ program.
K vytvoření PAN bridge na GN zadáme:
# brctl addbr pan0
# ifconfig pan0 10.0.0.1

Rozhraní ‚pan0‘ je nyní unikátní zastupující rozhraní a následovně vytvoří rozhraní ‚bnepx‘.
V případě, že chcete připojit komplexní vrstvu dvou sítí, kde se může objevit loop musíte nyní vypnout některou z chytrých voleb „802.1d Ethernet Bridging“
Jmenovitě „Spanning Tree Protocol“ – STP a „Listening and Learning States“) zadáním:
# brctl setfd pan0 0
# brctl stp pan0 disable

Výsledek: bridge bude funkční okamžitě po vytvoření nového ‚bnepx‘ rozhraní.
Pokud nechcete zadávat tato volání, vytvoření bridge může trvat do ~ 30 sekund
v závislosti na komplexnosti brigovaných sítí.

Normálně jestliže připojujete Vaši Pan do komplexní sítě je třeba, abyste uskutečnili tato dvě volání.

V případě, že chcete vytvořit NAP, jednoudše přidejte rozhraní do infrastruktury sítě (typicky ‚eth0‘)
do bridge (viz příklad 2):
# brctl addif pan0 eth0

Jeden bridge port ‚bnep0‘ (nebo nějaký další port ‚bnepx‘) byl vytvořen.
Na GN jen zadejte:
# brctl addif pan0 bnep0
# ifconfig bnep0 0.0.0.0′

Pro ověření stavu bridge zadejte
# brctl show

to ukáže seznam vytvořených rozhraní a
# brctl showmacs

ukáže seznam připojení (na rozhraní) forwardovaných přes bridge.

‚dev-up‘ Script

„But hey, how will I ever learn that a ‚bnepx‘ interface has been created on
the GN, if the PAN connection was initiated from the PANU?“, you may ask.
Indeed, you won’t, unless you’re the person who’s in charge of both
manually initiating the connection on the PANU and subsequently configuring
the bridge on the GN appropriately. Apparently, we need some help from BlueZ
here. So what happens is that the PAN daemon ‚pand‘ calls a script named
‚dev-up‘ in /etc/bluetooth/pan/ whenever a ‚bnepx‘ interface has been
created. It passes the interface name as the first parameter, and the device
address of the remote device as the second. This script may look as follows:
#!/bin/sh
# ‚dev-up‘ script to do dynamic bridge management on GN
brctl addif pan0 $1 # $1 is the new if name, passed by ‚pand‘
ifconfig $1 0.0.0.0

On the PANU side, ‚dev-up‘ would look like this:
#!/bin/sh
# ‚dev-up‘ script to do dynamic interface management on PANU
ifconfig $1 10.0.0.2

Make sure that the ‚dev-up‘ scripts have both the ‚Read‘ and ‚eXecutable‘
attribute set.

Alternatively, on the PANU side, you may stick with the ‚ifcfg-bnep0‘
configuration file, as outlined above.

You can verify the correct functioning of ‚dev-up‘ by calling ‚ifconfig‘
manually subsequently. It should show the newly created interface (amongst
others) with the HW device address of the BlueZ adapter and its correct IP
(v4) address. In the GN case, you will only see ‚pan0‘ (‚bnepx‘ is shown,
but doesn’t have an IP (v4) address. In the PANU case, you will see ‚bnepx‘
with a valid IP address.

NAP

The instructions just given on how to set up a Group ad-hoc Network (GN)
apply accordingly for the Network Access Point (NAP) case. Just replace the
‚GN‘ parameter token consequently with ‚NAP‘.

Miscellaneous options

‚pand‘ offers (among other options that are too trivial to enumerate here;
call ‚pand‘ to get the full list of options) the following additional command
line options:

– ‚–device ‚
allows you to specify a name different from ‚bnepx‘ for dynamic interface
name association. E.g., if you specify ‚–device pandev‘, an interface
‚pandev‘ will be created.

– ‚–source ‚
allows you to specify the BT device to be chosen in case more than one
device is registered (and „up“) with BlueZ. You may specify either the
HCI device number (e.g. ‚hci0‘) or the device address itself. If you call
e.g.
# pand –role NAP –listen –source 00:37:5C:67:D3:05

the device with the address 00:37:5C:67:D3:05 will listen, and no other.

– ‚–kill ‚
allows you to disconnect a PAN connection, the remote device address of
which you explicitly know (e.g. because you created it with ‚–connect
‚).
To obtain a list of existing connections, use the option ‚–show‘:

– ‚–show‘ or ‚–list‘
displays a list of currently existing PAN connections, including the
device address of the respective remote device and the role of the local
device in this connection.

– ‚–persist [interval]
allows you to reconnect to an existing connection once it has been dropped
and re-establishment becomes (technically) possible again.
The exact behavior depends on the way how ‚pand‘ has been started:
If ‚pand‘ was started like:
# pand –connect –persist

it will always try to connect to the same address.
If, however it was started like:
# pand –search –persist

it will perform the search again instead of just trying to reconnect the
previous connection. Reconnection is attempted periodically, with ‚interval‘
specifying the period, after which a reconnection is attempted (in seconds).
‚interval‘ defaults to 5.

– ‚–encrypt‘
activates BT security (authentication and encryption) on the server (GN or
NAP) side. PANUs connect in a normal way, i.e. no further changes are
necessary. If no pairing has taken place so far, the PANU user will be
prompted to enter a PIN.
For details reg. the BlueZ security support, please read the respective
discussion threads in the „bluez-users“ and „bluez-devel“ mailing list
archives.

Second Example

This example is going to show how PANUs automatically connect (and reconnect)
to a NAP, creating a 192.168.0.x subnet. At the same time, the NAP acts as a
router to a corporate 10.x.x.x network, using ‚eth0‘ as adapter on the
10.x.x.x side, and ‚pan0‘ as adapter for the 192.168.0.x side. The NAP shall
own 10.0.0.1 as ‚eth0‘ IP address and 192.168.0.1 as ‚pan0‘ address. All nodes
use static IP addresses.

After full installation of BlueZ (‚hcid‘ and ‚sdpd‘ running, all BlueZ devices
are „up“, „bridge utils“ are installed on NAP, the NAP must be able to run as
Bluetooth master, see above.) on NAP and PANU(s), the
following configuration steps are necessary:

On NAP:
Setup bridge:
# brctl addbr pan0
# ifconfig pan0 192.168.0.1
# brctl setfd pan0 0
# brctl stp pan0 disable
# brctl addif pan0 eth0

Place a script ‚dev-up‘ in /etc/bluetooth/pan/ (without leading tabs, ‚Read‘
and ‚eXecutable‘ attributes set):
#!/bin/sh
brctl addif pan0 $1 # $1 is the new if name, passed by ‚pand‘
ifconfig $1 0.0.0.0

Start NAP server:
# pand –listen –role NAP –sdp

On PANU:
Place a configuration file ‚ifcfg-bnep0‘ in /etc/sysconfig/network-scripts/
(without leading tabs, Redhat version shown):
DEVICE=bnep0
BOOTPROTO=static
IPADDR=192.168.0.x
NETMASK=255.255.255.0
ONBOOT=no

with ‚x‘ being an IP address fragment (2 … 254) that is unique for each PANU.

Start connection establishment (with reconnection option):
# pand –role PANU –search –service NAP -sdp –persist

Furthermore, each node that is supposed to participate in communication
across the router requires a proper ‚route‘ entry.

I.e. on the PANUs:
# route add 10.0.0.0 gw 192.168.0.1

and on the nodes in the 10.x.x.x network (i.e. the machines „behind“ the
router):
# route add 192.168.0.0 gw 10.0.0.1

Now the PANUs should automatically connect to the 10.x.x.x network as soon as
they come into reach of the NAP. Furthermore, they automatically reconnect
after a broken connection when they come into NAP reach next time.

Enjoy!

References:

[1] „Specification of the Bluetooth System“, Volume 1,
http://www.bluetooth.com/pdf/Bluetooth_11_Specifications_Book.pdf

[2] „Personal Area Networking Profile“, Revision 0.95a,
http://www.bluetooth.com/pdf/PAN_Profile_0_95a.pdf

Author: Michael Schmidt, University of Siegen, Germany
schmidt@nue.et-inf.uni-siegen.de

Please don’t hesitate to send me your comments, criticisms, proposals,

supplements etc.

=============================================================================
=============================================================================
=============================================================================

https://core.forge.funambol.org/wiki/FunambolOverBluethooth

A Guide to Synchronization with Funambol DS Server over Bluetooth PAN

From time to time the topic of synchronizing a mobile phone with Funambol over Bluetooth comes up on the mail list. However, Funambol currently does not implement the SyncML OBEX Binding for Bluetooth.

Instead Bluetooth PAN can be used to attach the mobile phone to a TCP/IP network, and then access the Funambol DS Server normally over HTTP. This guide illustrates synchronization over Bluetooth with the Sony Ericsson W850i phone and a Funambol DS Server running under Linux (Debian Etch).

The key to success is the Bluetooth Personal Area Networking profile (PAN), which defines different roles like PAN User (PANU), PAN Group Network (GN) and PAN Network Access Point (NAP). For me it worked best when using my Linux PC as NAP and the phone as PANU. Other role assignments might work, too, or even other profiles, like LAP (LAN Access Profile) or DUN (?DialUp Networking). The problem is that mobile phones usually don’t support all these profiles and/or are poorly documented.

On the Linux PC:

I used the BlueZ protocol stack and the corresponding tools, and I followed two detailed guides:

These assume that all participants in the PAN run Linux, and that you can freely configure them. However, that was not the case for my phone, where I could not assign an IP address manually. Instead the phone tried to obtain an IP address via DHCP, so I needed to set up a DHCP server, too.

Set up a bridge (e.g. pan0) for the PAN, and assign a private IP address (e.g. 192.168.42.1) to it:

     $ brctl addbr pan0
     $ brctl setfd pan0 0
     $ brctl stp pan0 disable
     $ ifconfig pan0 192.168.42.1

Start the PAN daemon to listen for Bluetooth PAN connections:

     $ pand -s -M -r NAP

Edit configuration script /etc/bluetooth/pan/dev-up to contain the following, and make it executable:

     #!/bin/sh
     # called by pand each time a Bluetooth PAN connection is made
     # argument $1 is the name of a newly created interface representing the connection
     brctl addif pan0 $1
     ifconfig $1 0.0.0.0

Start a DHCP server on pan0. (I used the dhcp3-server package from Debian Etch, and configured it with a GUI frontend.) For the private IP network used above, these informal suggestions might help:

     Client IP Range:   192.168.42.2 - 192.168.42.127
     Gateway:   192.168.42.1
     DNS Server:

Enable IP forwarding to your network and/or the Internet, e.g. using interface eth0:

     $ echo "1" > /proc/sys/net/ipv4/ip_forward
     $ iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

You can now start Funambol DS Server, if not already running. This could be on the PC, which is now serving as a Bluetooth NAP, or on any other machine in your network and/or the Internet.

On the mobile phone (e.g. Sony Ericsson W850i):

Go to „Menu / Settings / Connectivity / Bluetooth / My Devices“. Select „New device“, and pair the phone with your PC, if not already done. Then the Bluetooth name of your PC should appear in the list under „My Devices“. Select your PC from the list and press „Connect“!

After a short time (max. a few seconds) your phone should be connected to your PC and your network. You can test this by opening you phone’s Browser and accessing a web server on your PC or the network or the Internet. (Make sure that the phone does not use a different connection, e.g. GPRS!)

Now you can configure a new SyncML server (e.g. Funambol) under „Menu / Organizer / Synchronization / New account“. For the setting „Connection“ you can use the Bluetooth name of your PC, since a corresponding data account was automatically created when you first connected over PAN. The other settings are pretty straight forward, and could look like this:

  • Server address : http://192.168.42.1:8080/funambol/
  • App. settings / Contacts / Database name : card
  • App. settings / Calendar / Database name : cal
  • Applications : Contacts, Calendar
  • Username : …
  • Password : …

After saving the new SyncML server configuration, you can select it from the list under „Synchronization“. Then select start and watch SyncML working!

Conclusion

The above setup seems to work pretty well for me, though I did not try any fancy SyncML stuff yet. The important thing is, that Bluetooth is for free, while other network connections like e.g. GPRS may be quite expensive for some users. Using SyncML and Funambol should work equally well over Bluetooth PAN, at least in most cases.

While the generic instructions given above seem rather complicated, I was able to tweak my Debian installation, so it all comes up automatically at startup. Under Windows, its probably even more easy to set up Bluetooth PAN. Just search the web for it! As far as the W850i is concerned, the crux was to make sure it can reach a DHCP server, when trying to connect. It does not seem to be possible to set an IP address manually. Other phones may have different peculiarities.

Anyway, I don’t know how many mobile phones or PDAs support Bluetooth PAN today. But I think, it can make the development of mobile applications easier. You can first test your stuff under laboratory conditions before going out to the real world!

— Michael Riedel

============

http://uiqmania.cz/forum/viewtopic.php?t=945

Synchronizace P1i a Thunderbirdu (nebo jakéhokoliv telefonu – Symbian i „nesymbian“) ve Windows. Toto řešení jsem ozkoušel na telefonech SE K790i a P1i.

Dlouho jsem řešil, jak sesynchronizovat telefon se symbianem a emailovým klientem Thunderbird. Šlo mi hlavně o synchronizaci kontaktů a položky v kalendáři (on taky Thunderbird nic jinýho nemá). Na Outlook jsem přejít nechtěl, protože osobně si myslím, že Thunderbird je lepší, ale to je na jinou debatu. Stále jsem narážel na Funambol a na tvrzení, že Funambol je poměrně složité řešení. Sice jsem tím strávil delší dobu, ale zpětně musím říci, že to až tak komplikované řešení není.
Jsou v zásadě 2 řešení a to lokální a vzdálené. Osobně mi přijde lepší to vzdálené, ale každé má svoje. Obě řešení využívají Open Source Funambol server.
POZOR: nejde synchronizovat kontakty a položky kalendáře s diakritikou – to pak dělá dost binec – u kontaktů nedojde k synchronizaci a položky kalendáře mi to změnilo k nečitelnosti!
1) Vzdálené řešení
Na http://my.funambol.com se zaregistrujte – vytvořte si účet a zadejte model telefonu, operátora a zadejte telefonní číslo. Můžete využít volby nechat si poslat konfigurační sms, ale třeba na P1i mi to moc nefungovalo.
POZOR: pro synchronizaci kalendáře jsem musel u P1i na my.funambol.com v menu Profile vedle Time zone v Advanced povolit (Enable) nastavení času, jinak se synchro kalendáře nezdaří!update: 18.3.2008
POZOR: problém při synchronizaci kontaktů dělají duplicitní položky, použijte v Thunderbirdu doplněk Duplicate Contact Manager, ten Vám je odstraní Smileupdate: 23.4.2008
a) Nastavení telefonu:
P1i tedy nastavíte v menu – nástroje – vzdálená synchronizace
zaškrtněte kalendář a nastavte:
typ synchronizace: synchronizovat
název úkolu: Kalendar
databáze serveru: cal
zaškrtněte Kontakty a nastavte:
typ synchronizace: synchronizovat
název úkolu: Kontakty
databáze serveru: card
Dále klikněte na Více a zvolte upravit profil, zde nastavte:
Název profilu: Funambol
Adresa serveru: http://my.funambol.com/sync
Uživatelské jméno: …
Heslo: …
Protokol přenosu: http
Vyberte funkční internetový účet (u Vodafonu např. GPRS Web)
b) nastavení emailového Thunderbirdu
stáhněte a nainstalujte si doplněk Funambol PIM Plugin:
http://sourceforge.net/project/screenshots.php?group_id=149326
Pak v menu nástroje – Funambol Plugin v Options nastavte:
Záložka Account: Server URL: http://my.funambol.com:80/sync
Záložka Synchronize: Details u kalendáře u Remote name vypište cal a u kontaktů u Remote name vypište card.
Pak je vše nastaveno a jestliže máte funkční připojení k internetu v telefonu, nic by nemělo bránit synchronizaci kontaktů a položky kalendáře.

2) Lokální řešení
Na http://ww.funambol.com si stáhněte Funambol server a nainstalujte jej na svůj počítač. Při instalaci budete vyzváni k vytvoření účtu – uživatelské jméno a heslo bude důležité Smile.
a) Nastavení telefonu:
P1i tedy nastavíte v menu – nástroje – vzdálená synchronizace
zaškrtněte kalendář a nastavte:
typ synchronizace: synchronizovat
název úkolu: Kalendar
databáze serveru: cal
zaškrtněte Kontakty a nastavte:
typ synchronizace: synchronizovat
název úkolu: Kontakty
databáze serveru: card
Dále klikněte na Více a zvolte upravit profil, zde nastavte:
Název profilu: Funambol
Adresa serveru: http://localhost:8080/funambol/ds
POZOR: namísto localhost vyberte IP adresu svého počítače s nainstalovaným Funambol serverem
Uživatelské jméno: …
Heslo: …
Protokol přenosu: http
Vyberte funkční bod připojení – třeba Bluetooth připojení k počítači, kde je nainstalovaný Funambol server
b) nastavení emailového Thunderbirdu
stáhněte a nainstalujte si doplněk Funambol PIM Plugin:
http://sourceforge.net/project/screenshots.php?group_id=149326
Pak v menu nástroje – Funambol Plugin v Options nastavte:
Záložka Account: Server URL: http://localhost:8080/funambol/ds
Záložka Synchronize: Details u kalendáře u Remote name vypište cal a u kontaktů u Remote name vypište card.

Snad Vám to bude běhat. Já jsem se dlouho rozmýšlel, jestli zvolit lokální či vzdálení řešení a nakonec jsem zvolil vzdálené. Sice to trochu žere data (jen málo po první synchronizaci se posílají jen změněná data), ale je to pohodlnější – pokud nemáte pevnou IP adresu, musíte ji pak stále měnit v Thunderbirdu.

Naposledy upravil konec dne st duben 23, 2008 11:06, celkově upraveno 2 krát.

=================

http://www.hitsw.com/Funambol/index.html

Allora DBConnector for Funambol works with Funambol’s mobile application server, to allows server side synchronization of relational data with any mobile application. Funambol is based on an open standard solution for mobile data synchronization, remote device management and application provisioning.

SyncML, an XML-based open standard, provides a means for mobile device data exchange in applications such as contact management, calendaring, email and to-do lists. SyncML also works over various types of connections, including Wireless Internet, Bluetooth, and infrared. With the combination of Funambol, the leading open source implementation of SyncML, and Allora DBConnector, mobile application developers can now synchronize personal organizer data between any relational database and any mobile device. The benefits of Allora DBConnector extend beyond PIM synchronization and can be used for complex client-server mobile applications like sales force automation.

Allora DBConnector
for Funambol

Technical Overview (HTML)
Technical Overview (PDF)
If you are using Sync4j v2.3, please click here

HiT Software’s Allora technology is currently deployed across industries and governmental agencies as the leader in easy-to-use, yet powerful XML-to-Database mapping and transformation technology. Allora is the middleware solution of choice for application developers that need to bring together the benefits of the scalability, robustness and high-performance of relational databases with the versatility found in the data-exchange and content-management capabilities of XML.

Funambol is a HiT Software Technology Partner.

================

https://wiki.objectweb.org/sync4j/Wiki.jsp?page=FunambolOverBluethoot

FunambolOverBluethoot

Reporting Success: Synchronizing with Funambol over Bluetooth PAN

Hello Funambol users!

A few weeks ago someone asked, if he could synchronize a mobile phone with Funambol over Bluetooth. However, Funambol currently does not implement the SyncML OBEX Binding for Bluetooth. Instead I suggested to use Bluetooth PAN to attach the mobile phone to a TCP/IP network, and then access the Funambol DS Server normally over HTTP.

Meanwhile I actually managed to synchronize my Sony Ericsson W850i phone with a Funambol DS Server running under Linux (Debian Etch), and I’d like to share my experiences here.

The key to success is the Bluetooth Personal Area Networking profile (PAN), which defines different roles like PAN User (PANU), PAN Group Network (GN) and PAN Network Access Point (NAP). For me it worked best when using my Linux PC as NAP and the phone as PANU. Other role assignments might work, too, or even other profiles, like LAP (LAN Access Profile) or DUN (DialUp Networking). The problem is that mobile phones usually don’t support all these profiles and/or are poorly documented.

On the PC:

I used the BlueZ protocol stack and the corresponding tools, and I followed two detailed guides:
http://bluez.sourceforge.net/contrib/HOWTO-PAN
http://fedoranews.org/contributors/muhammad_al_ismail/bluetooth/
These assume that all participants in the PAN run Linux, and that you can freely configure them. However, that was not the case for my phone, where I could not assign an IP address manually. Instead the phone tried to obtain an IP address via DHCP, so I needed to set up a DHCP server, too.

Set up a bridge (e.g. pan0) for the PAN, and assign a private IP address (e.g. 192.168.42.1) to it:
$ brctl addbr pan0
$ brctl setfd pan0 0
$ brctl stp pan0 disable
$ ifconfig pan0 192.168.42.1

Start the PAN daemon to listen for Bluetooth PAN connections:
$ pand -s -M -r NAP

Edit configuration script /etc/bluetooth/pan/dev-up to contain the following, and make it executable:
#!/bin/sh
# called by pand each time a Bluetooth PAN connection is made
# argument $1 is the name of a newly created interface representing the connection
brctl addif pan0 $1
ifconfig $1 0.0.0.0

Start a DHCP server on pan0. (I used the dhcp3-server package from Debian Etch, and configured it with a GUI frontend.) For the private IP network used above, these informal suggestions might help:
Client IP Range: 192.168.42.2 – 192.168.42.127
Gateway: 192.168.42.1
DNS Server:

Enable IP forwarding to your network and/or the Internet, e.g. using interface eth0:
$ echo „1“ > /proc/sys/net/ipv4/ip_forward
$ iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

You can now start Funambol DS Server, if not already running. This could be on the PC, which is now serving as a Bluetooth NAP, or on any other machine in your network and/or the Internet.

On the phone (Sony Ericsson W850i):

Go to „Menu / Settings / Connectivity / Bluetooth / My Devices“. Select „New device“, and pair the phone with your PC, if not already done. Then the Bluetooth name of your PC should appear in the list under „My Devices“. Select your PC from the list and press „Connect“!

After a short time (max. a few seconds) your phone should be connected to your PC and your network. You can test this by opening you phone’s Browser and accessing a web server on your PC or the network or the Internet. (Make sure that the phone does not use a different connection, e.g. GPRS!)

Now you can configure a new SyncML server (e.g. Funambol) under „Menu / Organizer / Synchronization / New account“. For the setting „Connection“ you can use the Bluetooth name of your PC, since a corresponding data account was automatically created when you first connected over PAN. The other settings are pretty straight forward, and could look like this:
„Server address“: http://192.168.42.1:8080/funambol/ds
„App. settings / Contacts / Database name“: card
„App. settings / Calendar / Database name“: cal
„Applications“: Contacts, Calendar
„Username“: …
„Password“: …

After saving the new SyncML server configuration, you can select it from the list under „Synchronization“. Then select start and watch SyncML working!

The above setup seems to work pretty well for me, though I did not try any fancy SyncML stuff yet. The important thing is, that Bluetooth is for free, while other network connections like e.g. GPRS may be quite expensive for some users. Using SyncML and Funambol should work equally well over Bluetooth PAN, at least in most cases.

While the generic instructions given above seem rather complicated, I was able to tweak my Debian installation, so it all comes up automatically at startup. Under Windows, its probably even more easy to set up Bluetooth PAN. Just search the web for it! As far as the W850i is concerned, the crux was to make sure it can reach a DHCP server, when trying to connect. It does not seem to be possible to set an IP address manually. Other phones may have different peculiarities.

Anyway, I don’t know how many mobile phones or PDAs support Bluetooth PAN today. But I think, it can make the development of mobile applications easier. You can first test your stuff under laboratory conditions before going out to the real world!

Kind regards, Michael Riedel


Student – Mobile Solutions – Lab-Based Services

IBM Deutschland Entwicklung GmbH, Altrottstrasse 31, D-69190 Walldorf cellphone: e-mail: michael.riedel@de.ibm.com


IBM Deutschland Entwicklung GmbH Vorsitzender des Aufsichtsrats: Johann Weihen Geschäftsführung: Herbert Kircher Sitz der Gesellschaft: Böblingen Registergericht: Amtsgericht Stuttgart, HRB

=============