LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 12-21-2007, 01:45 PM   #1
knobby67
Member
 
Registered: Mar 2006
Posts: 461

Rep: Reputation: 31
Detecting USB comms ports


Hi all,
I've been working on code using rs232 comms ports, except I need to add some additional comms ports using USB to rs232. The problem is I have no idea where the USB will attach to, so I don't know what ports to write to in my code.
Has anyone any idea how I can find out what ports the USB has assigned, with out connecting it to another pc and doing trial and error.
 
Old 12-21-2007, 02:55 PM   #2
David1357
Senior Member
 
Registered: Aug 2007
Location: South Carolina, U.S.A.
Distribution: Ubuntu, Fedora Core, Red Hat, SUSE, Gentoo, DSL, coLinux, uClinux
Posts: 1,285
Blog Entries: 1

Rep: Reputation: 103Reputation: 103
Quote:
Originally Posted by knobby67 View Post
Has anyone any idea how I can find out what ports the USB has assigned, with out connecting it to another pc and doing trial and error.
My Keyspan USB-to-serial adapters start at "/dev/ttyUSB0". The first one plugged in gets assigned to 0, the second to 1, etc. I do not know how they get assigned if they are already plugged in at boot.

Plug yours in and look at the output of "dmesg" to see where it ends up.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
USB 2.0 ports: devices not detected, but works fine with USB 1.1 ports (Kubuntu 6.06) KWTm Linux - Hardware 1 05-09-2007 04:42 AM
Detecting USB ports on Dell 2001fp monitor on Ubuntu Linux j3nnifers Linux - Hardware 8 10-10-2005 05:37 PM
Detecting USB port without......... BajaNick Linux - Hardware 2 07-22-2004 08:25 PM
stop hotplug from detecting things connected to usb (but still noticing usb itself) TheOneAndOnlySM Linux - Hardware 5 10-18-2003 10:35 AM
Lockup detecting USB Sailorgoon Linux - Software 5 03-21-2003 06:19 PM


All times are GMT -5. The time now is 04:42 AM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration