Bug 96886 - Detecting port that the pilot is on is difficult - needs a detection tool.
Summary: Detecting port that the pilot is on is difficult - needs a detection tool.
Status: RESOLVED DUPLICATE of bug 152681
Alias: None
Product: kpilot
Classification: Applications
Component: General (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR wishlist
Target Milestone: ---
Assignee: groot
URL:
Keywords:
: 124166 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-01-13 03:26 UTC by bsamhaber
Modified: 2009-01-19 05:51 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bsamhaber 2005-01-13 03:26:12 UTC
Version:            (using KDE KDE 3.2.1KDE 1.2)
Installed from:    SuSE RPMsSuSE RPMs
OS:                Linux

In the kpilot FAQ under Normal Operation there is a topic  'How does Hotplug work? (I don't want to hardcode a device path)' that admits it is difficult to detect the port that the pilot is on. It seems to me that there is a need for a tool similar to 'detectups' for UPS power supplies that determines which port the pilot is connected to. Note that there is something in 'pilot-dedupe' that checks if it can connect to a pilot. A tool like this could could even query the user for what type of port that they have physically connected the pilot to; such as serial, USB, are they others? 
A tool like this could also be included in the setup screen of kpilot. Note that the trick is to determine which of hte serial ports the pilot was connected to. 

Thanks,
Comment 1 groot 2005-01-13 14:21:35 UTC
> others? A tool like this could also be included in the setup screen of
> kpilot. Note that the trick is to determine which of hte serial ports the
> pilot was connected to.

It _is_ included -- the configuration wizard has a button "try to 
automatically detect handheld and username" which polls a number of possible 
ports, at least for USB. I don't think serial ports are pollable that way 
(that's got to do with threading issues and the underlying libraries), but 
since there is a 1-1 mapping between physical ports and device names, I don't 
consider that much of a problem. Whether the USB detection code _works_ is 
another matter -- I expect you need to have a properly configured kernel and 
hotplug system for  that to work.

Comment 2 Jason 'vanRijn' Kasper 2005-02-06 03:27:48 UTC
I think this one can be marked as FIXED/etc., can't it?  The functionality requested is in kpilot.
Comment 3 Arthur 2005-06-07 17:12:21 UTC
I have attempted to use the "try to automatically detect handheld and username" feature in SuSE 9.3 with no avail. It worked fine in SuSE 9.2 and I could easily detect my Clie SJ20. However, upon upgrading to 9.3 I am not able to sync my Clie. Can you please describe to me the steps to have a properly configured kernel and hotplug system?

Thank you for your time.
Comment 4 bsamhaber 2005-06-07 20:05:39 UTC
Arthur, 

Sorry but I setup my SuSe 9.0 1.5yrs ago and do not really remember how to 
config things. I think your best but is to consult the KDE-pim email alis.

Cheers,


On Tuesday 07 June 2005 11:12, Arthur wrote:
[bugs.kde.org quoted mail]
Comment 5 David Martin 2005-08-06 07:30:01 UTC
Arthur, 
Is your version of SuSE using udev?
I'm running 9.2 Professional and it is utilizing udev. In my case the pilot-xfer command would utilize a "device"  of /dev/usb/ttyUSB1
Look in your /dev directory for either tts or usb...
this is presuming a USB cradle for your Sony Clie.
If you connect your Clie and hit the hotsync button and then look at your dmesg output you should see something on the order of: (This is for my Handspring Visor)
usb 4-1: new full speed USB device using address 20
usb 4-1: Product: Handspring Visor
usb 4-1: Manufacturer: Handspring Inc
usb 4-1: Handspring Visor / Palm OS: port 1, is for Generic use
usb 4-1: Handspring Visor / Palm OS: port 2, is for HotSync use
usb 4-1: Handspring Visor / Palm OS: Number of ports: 2
visor 4-1:1.0: Handspring Visor / Palm OS converter detected
usb 4-1: Handspring Visor / Palm OS converter now attached to ttyUSB0
usb 4-1: Handspring Visor / Palm OS converter now attached to ttyUSB1
usb 4-1: USB disconnect, address 20
visor ttyUSB0: Handspring Visor / Palm OS converter now disconnected from ttyUSB0
visor ttyUSB1: Handspring Visor / Palm OS converter now disconnected from ttyUSB1
visor 4-1:1.0: device disconnected

(I'm having some problems but I think I'm on the road to fixing it...)
You can see in the output that ttyUSB0 and ttyUSB1 are used.

You should check your /etc/udev/permissions.d/50-permissions.d file for the permissions and group for the ttyUSB ports.
Do a "grep ttyUSB  /etc/udev/permissions.d/50-udev.permissions"
 
/etc/udev/rules.d/50-udev.rules"
You probably need to add symbolic links for the Clie and possibly create a rule for the Clie.  If the permissions do not include the group you are in you will need to create a group and add a class in the permissions file and then add your group to the second group in the permissions file for the ttyUSB ports.

http://gentoo-wiki.com/HOWTO_USB_sync_for_Palm_PDAs_with_Evolution_2.0_and_udev

This site has some excellent info and may help you figure out what you need.
If you have a serial connection, then it gets more complicated. If you aren't running udev but devfs then I might be able to point you to some URLs where some ideas on things to try and test are located...


Cheers,

David
Comment 6 Jason 'vanRijn' Kasper 2008-10-29 20:06:25 UTC
Yeah, so sadly this functionality is actually there, but I broke it with the multi-threading changes to the device daemon. Hopefully we can get to this soon.
Comment 7 Jason 'vanRijn' Kasper 2008-10-30 21:07:27 UTC
*** Bug 124166 has been marked as a duplicate of this bug. ***
Comment 8 Jason 'vanRijn' Kasper 2009-01-19 05:51:49 UTC

*** This bug has been marked as a duplicate of bug 152681 ***