Here's somethin I wrote up based on my experiences with getting IRCOMM to
work with the Toshiba Libretto and my Palm IIIxe.
System versions:
Palm: PalmOS 3.5
Linux:2.2.14 w/ irda patch 1
I'd bve interested in getting any feedback from people on stuff that I've
missed, what you think is good and what isn't quite corect or clear.
Thanks,
----Steve
The LINUX<->PALM IRCOMM MINI-HOWTO
What this is:
An attempt to encapsulate what I've learned from setting up and running
the Linux-IRDA Project's IRCOMM implementation between my Palm devices
and my Linux Laptop(A Toshiba Libretto 70CT). Hopefully, it will help
you with your efforts.
What this is not:
- A treatise on IRDA or the Linux-IRDA Project. You can find that kind of
info at either http://www.irda.org or http://www.cs.uit.no/linux-irda.
BEFORE YOU BEGIN
If you have not yet configured and compiled your kernel to include the
Linux-IRDA extensions, *STOP*. Put this down and go to the above mentioned
sites for background and then read Werner Heuser's Linux-IR HOWTO at:
http://home.snafu.de/wehe/IR-HOWTO.html
Things here will make far more sense after you've read the stuff over there :)
Platform and Experience:
I have been able to successfully establish HotSync and PPP connections between
my Palm IIIx, IIIxe and my Toshiba Libretto 70Ct using the built-in IRDA port
and also using the Belkin SmartBeam dongle. The Libretto only has a SIR
transceiver on it so you won't be able to get faster than 115200bps out of
it. I make no guarantees, but since Toshiba are among the most proprietary
hardware vendors implementing IRDA(and therefore the hardest to get this
working) you really shouldn't have any problems.
HotSync via IRCOMM:
WHAT TO SET UP
Linux Side:
Protocols/Modules: IRDA, IRCOMM,IRTTY,IRPORT all configured as modules
These will auto-load when needed if you have compiled your kernel with
CONFIG_KMOD=y.
If you did not do this, you will need to 'insmod <modulename>' in the
following order: irda irtty ircomm-tty ircomm.
Commands: irattach /dev/<devname of the physical IR transceiver>
As in:
irattach /dev/ttyS1 -s 1
setenv PILOTPORT /dev/ircomm0
setenv PILOTRATE 115200 (go slower if this doesn't work)
DON'T run irmanager. It grabs control of the IRDA port and pilot-xfer
won't be able to get through to the Palm. The more detailed
explanation is that irmanager is designed to smartly manage the
IRDA port for things like IRLAN. Pilot-xfer is just checking to
see if ANYTHING else is using that port. If it can't exclusively
lock the device, it dies. It won't even try to talk to irmanager.
Palm Side:
HotSync configured to use IRCOMM as connection/sync method.
WHAT TO DO:
>From the Linux side, do: pilot-xfer --sync <dest dir> .
>From the Palm side start the HotSync session by tapping on the HotSync
glyph on the Palm. (You DID remember to point your Palm's IRDA port
at the IRDA port of your Linux system right? :) )
WHAT SHOULD HAPPEN:
After about 5 seconds you should hear the familiar sync-up chimes, followed
later, by the sync-down chime when the Palm is finished.
It may take a few seconds for the two to connect, esp. if the two IR ports
aren't aligned well, flourescent light in the room, etc. Don't worry if
you don't immediately hear the sync tones. I've had it take as long as 10
seconds for me.
IF IT DOESN'T WORK:
Do an 'lsmod'. Make sure that all the modules are loaded. You should see
results similar to this:
chameleon:~>lsmod
Module Size Used by
smc91c92_cs 15088 1
irtty 7484 2 (autoclean)
ircomm-tty 32096 2 (autoclean)
ircomm 14236 0 (autoclean) [ircomm-tty]
irda 146369 2 (autoclean) [irtty ircomm-tty ircomm]
ds 6184 2 [smc91c92_cs]
i82365 21108 2
pcmcia_core 37952 0 [smc91c92_cs ds i82365]
chameleon:~>
If you don't see these, try to insmod them manually one at a time. This will
either work or fail. If it fails, your modules aren't built correctly or
loading properly. Go check /var/log and check things like kernel.log and
syslog for recent messages. Also go back to Werner's IR-HOWTO mentioned at
the top of this one and see if you missed anything.
If it works, then you just need to remember to load the kernel modules by
hand each time you reboot. (You should really rebuild your kernel to
auto-load modules).
COMMON MISTAKES:(I made, so you don't have to :) )
--irda not compiled as a module.
It seems to like being a module more than a built-in for some reason.
When configuring the kernel, check ALL the IRDA options as modules.
--In the excitement over being almost there, forgetting to make modules and
then make modules_install. (DOH!)
--Running irmanager as well as irattach. This is overkill for what we're
trying to do and gets in the way. The pilot-xfer utility is expecting
an empty, dumb serial port it can lock on but instead finds irmanager
standing in the way and gets annoyed. Kill irmanager and try again.
--Not loading modules in the proper order or not loading all the modules.
Really, you should let the kernel deal with this. If you must load them
by hand, you should load them in this order: irda irtty ircomm-tty ircomm.
--Running pilot-sync with PILOTPORT set to the IRDA hardware port instead of
the pseudo-device /dev/ircommN(as in /dev/ttyS1 instead of /dev/ircomm0).
See the comments about irmanager for why this is bad.
--Not having proper perms/ownership on the /dev/ircomm* device(s). These
need to be set like so:
crw-rw-rw- 1 root dialout 161, 0 May 10 05:13 /dev/ircomm0
crw-rw-rw- 1 root dialout 161, 1 May 4 14:31 /dev/ircomm1
crw-rw-rw- 1 root dialout 4, 64 May 6 17:25 /dev/ttyS0
crw-rw-rw- 1 root dialout 4, 65 Oct 24 1999 /dev/ttyS1
crw-rw-rw- 1 root dialout 4, 66 Mar 3 1999 /dev/ttyS2
crw-rw-rw- 1 root dialout 4, 67 Mar 3 1999 /dev/ttyS3
pilot-xfer needs to have read/write access to these ports and seems
to get annoyed if they don't have group access set to dialout or ppp
or something other than root.
Running PPP between a Palm and Linux system:
"Never ask a geek why, just nod your head and walk away slowly"
O'Reilly has a really cool article about doing this that I found
very helpful with doing this.
Check it out at:
http://oreilly.linux.com/pub/a/network/2000/05/05/magazine/PalmLinux.html?page=2
This worked for me with the following command line:
/usr/sbin/pppd /dev/ircomm0 115200 192.168.1.13:192.168.1.18 proxyarp passive silent
persist local noauth
_______________________________________________
Linux-IrDA mailing list - [EMAIL PROTECTED]
http://www4.pasta.cs.UiT.No/mailman/listinfo/linux-irda