×

INDI Library v1.9.8 Released (Yesterday)

Bi-monthly INDI Library released with new drivers and bug fixes.

Port is already used error

  • Posts: 103
  • Thank you received: 6
My Eqod mount just started doing this out of the blue. Had connected without issue before.

RP4 - Astroberry

2020-07-26T21:58:12: [WARNING] Port /dev/ttyACM0 is already used by another driver or process.
2020-07-26T21:58:09: [INFO] Trying connecting to /dev/ttyACM0 @ 9600 ...
2020-07-26T21:58:08: [WARNING] Port /dev/ttyUSB0 is already used by another driver or process.
2020-07-26T21:58:05: [INFO] Trying connecting to /dev/ttyUSB0 @ 9600 ...
2020-07-26T21:58:04: [WARNING] Communication with /dev/ttyUSB1 @ 9600 failed. Starting Auto Search...
2020-07-26T21:58:04: [ERROR] Failed to connect to port (/dev/ttyUSB1). Error: Port failure Error: No such file or directory. Check if device is connected to this port.
2020-07-26T21:58:04: [INFO] Auto search is enabled. When connecting, the driver shall attempt to communicate with all available system ports until a connection is established.

If I just unplug it, plug it back in, then restart Ekos - it works. Any idea what causes this?

Thanks
2 years 2 months ago #57368

Please Log in or Create an account to join the conversation.

  • Posts: 380
  • Thank you received: 113

Replied by Doug S on topic Port is already used error

I experience this error as both a result of the semi-random order that the tabs start up (thus devices start up), and as a result of not using the port mapper. Jasem has a video on mapping ports to named devices that would likely solve this for you. I'm just too lazy to do it. It's pretty easy to just scan the ports if necessary at startup contention and set another available port. But I believe the youtube video gives details on how this is done to avoid it entirely. Cheers, Doug
RASA11, Celestron CGX-L, ASI183mc Pro, 60mm guider + ASI290mm mini, ASI EAF focuser, PPB, Rpi4-4Gb+SSD, Powered USB3 hub, hardwire Ethernet.
The following user(s) said Thank You: David Rankin
2 years 2 months ago #57372

Please Log in or Create an account to join the conversation.

  • Posts: 103
  • Thank you received: 6
Thanks, found the article on this.

Cheers
2 years 2 months ago #57375

Please Log in or Create an account to join the conversation.

  • Posts: 1117
  • Thank you received: 182

I experienced the same problem recently. Usually it is the mount that cannot connect. All I have to do then is click 'Connect' in the Control Panel and the problem usually goes away.
The other option is the port mapping. After it happened for the third time, that's what I did and it seems stable since then.
Atlas Pro AZ-EQ, ASI1600MM-Pro, ASI120MM-S, ES102ED, WO-Z61, Nikon D3300, ASI-EFW, ZWO LRGB,Ha,O3,S2 filter set
2 years 2 months ago #57418

Please Log in or Create an account to join the conversation.

  • Posts: 3
  • Thank you received: 0

Replied by Duccio on topic Port is already used error

Who is James? and we can find solution?
1 year 4 months ago #70895

Please Log in or Create an account to join the conversation.

This issue is already fixed with latest INDI stable. Please update.
Jasem Mutlaq
Support INDI & Ekos; Get StellarMate Astrophotography Gadget.
How to Submit Logs when you have problems?
Add your observatory info
1 year 4 months ago #70897

Please Log in or Create an account to join the conversation.

  • Posts: 18
  • Thank you received: 1
@Jasem,  I regret to say that am still seeing the same error " [WARNING] Port /dev/ttyUSB0 is already used by another driver or process."  I am running astroberry 2.03 downloaded from the .img file.  I have gone through this process  indilib.org/get-indi/download-rpi.html  Additionally I have done sudo apt dist-upgrade, sudo apt update, several reboots, I have removed modemmanager and gpsd.  I am running this on a Pi4 / 8GB and have connected my Losmandy G11 Gemini-1 to both USB2 and USB3 ports.  I have gone through power off of the Gemini and the Pi, disconnections of both. I have made sure that only the Gemini (and the USB 3.0 boot SSD) are connected to the Pi.

I do not know what to do next.  I know this should work and I know that you know it works.  What next please?

Thanks
Pete
1 year 3 months ago #72322

Please Log in or Create an account to join the conversation.

  • Posts: 880
  • Thank you received: 419
Pete,

In case you didn't see it, I'm expanding on something said above.

It may be that your problem is the following: Linux randomly assigns serial USB devices to the ports /dev/ttyUSB0, /dev/ttyUSB1, /dev/ttyUSB2, ... That is, the first device it chooses will get ttyUSB0 and the 2nd device ttyUSB1 and so on, but how it decides what is first is unpredictable. There's a fancy scheme referred to above to help with with this, but understanding this is important. So, what I'd do if I were you is unplug all serial devices, reboot and only plug-in the one you want. I'll bet you find that it connects now to /dev/ttyUSB0. You can then connect the next device, and I'll bet it connects to /dev/ttyUSB1, and so on. Alternatively, you can keep things as is, and change /dev/ttyUSB0 to /dev/ttyUSB1 on the indi control panel connections tab for the device that's not connecting and try to re-connect to it. Bottom line, this may not be a KStars/Ekos problem, but rather a linux one. Here's the recommended work-around for that Linux issue: indilib.org/support/tutorials/157-persis...al-port-mapping.html

Hy
AP1100 & Orion Atlas Pro, WO/ZS105 w/Moonlight V2 focus, GSO RC10 w/RSF focus
ZWO ASI1600, Astronomik Filters, ST80, QHY 5L-IIm.
KStars/Ekos/Indi on NUC10 & RPi4 w/SSD -- Ubuntu
Projects: Greedy Scheduler, Terrain, Polar Align, Analyze, Linear Focuser, SEP MultiStar & GPG Guide, FITS autostretch.
1 year 3 months ago #72323

Please Log in or Create an account to join the conversation.

  • Posts: 1067
  • Thank you received: 137
Hy,
this currently does not work as you say, my Stellarmate is unusable ATM for this same issue, I have two serial devices and no matter how I plug them in they will not work, one sometimes connects to USB0 and then the other searches and can’t find a port so trys USB0 and then reports it’s in use, so crashes….and so this goes on, I have asked Jasem but with no answer but there is an issue somewhere….I am a seasoned user and I can’t solve it….it used to work fine till last updates two days ago, and I use stable PPA not Beta….
Stellarmate OS on Raspberry pi4b
Skywatcher EQ8 pro, on steel pier
Takahashi FSQ85, FS60cb & Meade 8” SCT (de-forked)
Starlight Xpress SXVR H18, SXVR M25c, Lodestar x2 Guide Camera
Pegasus Ultimate Hub V2 for all USB & Power
Pegasus focus motors on all scopes
1 year 3 months ago #72324

Please Log in or Create an account to join the conversation.

  • Posts: 18
  • Thank you received: 1
Thanks for your reply. Much appreciated. I did all you suggest many times. The Gemini (mount) never connects. I have tried it on its own with nothing else connected. ls -l /dev/tty* then shows no port suffixed by USB. Plugging my mount into either a Pi USB 2 or USB 3 port immediately generated a ttyUSB0 port. It never connects to KStars. The error message is always the same " [WARNING] Port /dev/ttyUSB0 is already used by another driver or process."

In all honesty, I would not have written had I not been totally stuck. Finally, plugging my mount's USB cable into a Windows 10 laptop it immediately connects to Stellarium either via Stellarium native or using the ASCOM driver.

This is very puzzling.
1 year 3 months ago #72325

Please Log in or Create an account to join the conversation.

  • Posts: 838
  • Thank you received: 80

Replied by alacant on topic Port is already used error


Rather, I think it was introduced by the latest INDI, Previously, all devices connected without issue.

Unfortunately, the workaround mentioned here:
indilib.org/support/tutorials/157-persis...al-port-mapping.html
doesn't work.

My workaround is currently to plug in the usb cables one at a time -the mount must be the first connected- and hit connect for each device on the indi control panel. This is the only reliable way I can connect our eq6. Not elegant, but may help rescue a session.

If the devs need anything testing or if we could revert this section of the code to the stable version immediately before 3.5.3, please don't hesitate to ask.
Cheers and clear skies,
Steve


 
kubuntu 22.04
700d, eq6, 120mm. Yes, the old one.
1 year 3 months ago #72334

Please Log in or Create an account to join the conversation.

  • Posts: 838
  • Thank you received: 80

Replied by alacant on topic Port is already used error

cat 99-observatory.rules
#EqmodMount
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", ATTRS{serial}=="PGB1MMQ", MODE="0666", SYMLINK+="mount"

ls -l /dev/mount
lrwxrwxrwx 1 root root 15 jun 15 14:44 /dev/mount -> bus/usb/003/003

indi screenshot attached
TIA
 
kubuntu 22.04
700d, eq6, 120mm. Yes, the old one.
1 year 3 months ago #72335
Attachments:

Please Log in or Create an account to join the conversation.

Time to create page: 0.379 seconds