Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux? |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
12-17-2010, 11:47 AM
|
#1
|
|
LQ Newbie
Registered: Nov 2010
Posts: 8
Rep:
|
Multiserial Ports Identification
Hello everybody.
I'm writting an app for desktop and embedded linux and I need to get information about the multiserial port, and I need to know which port is been used (by a printer, por example).
The multiserial I'm using is an Altera Corporation Device 0004, and I just need to tell how many ports are there and how many is been used.
any ideas?
PS: I know if the multiserial is there by lspci, and to know the information I need I'm thinking about using setserial, but I'm having some trouble to do that.
|
|
|
|
12-18-2010, 07:31 AM
|
#2
|
|
Moderator
Registered: Aug 2002
Posts: 10,756
|
There is no standard protocol so trying to automatically identify devices attached to a serial port will be difficult.
|
|
|
|
12-19-2010, 07:48 AM
|
#3
|
|
LQ Newbie
Registered: Nov 2010
Posts: 8
Original Poster
Rep:
|
Tks for the post Michaelk, but I don't need to identify the devices, I just need to know
how many of those ports are conected to something ...
The output of the program would be something like:
You Have an an Altera Corporation Device 0004
Total Ports: 4
Ports Conected to any device: 3
Ports Avaliable: 1
--
ya see, I think it's pretty much easy than the know what is the device conected.
tks
|
|
|
|
12-20-2010, 07:22 AM
|
#4
|
|
Moderator
Registered: Aug 2002
Posts: 10,756
|
Again it depends on the hardware. For devices that use hardware flow control you could check for the status of the CTS,DSR, DCD or RI signals. However, there are special serial cables that have hardware loopback for flow control on the PC side so this method not work. I do not know if you can check the status of the RX or TX signals if the device is not continuously sending data. So for devices that may only use the min number of wires i.e. TX,RX and GND not sure if there is any method to detect the device.
|
|
|
1 members found this post helpful.
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 12:35 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|