×

INDI Library v2.0.7 is Released (01 Apr 2024)

Bi-monthly release with minor bug fixes and improvements

[SOLVED] unable to connect to /dev/ttyUSB0

  • Posts: 2255
  • Thank you received: 223
I have an AstroEQ box to control my EQ3-2, until now it worked perfectly fine, however after a while of not "playing with it" I am now unable to connect to it as connect to /dev/ttyUSB0

I get the following error:
<setSwitchVector device="EQMod Mount" name="CONNECTION" state="Busy" timeout="60" timestamp="2015-01-25T17:05:54" message="connecting to port /dev/ttyUSB0">
    <oneSwitch name="CONNECT">
Off
    </oneSwitch>
    <oneSwitch name="DISCONNECT">
On
    </oneSwitch>
</setSwitchVector>
2015-01-25T17:06:09: Driver indi_eqmod_telescope: read message EQMod Mount   'Error:  -> tty read failed, check connection: Timeout error'
2015-01-25T17:06:09: Client 0: queuing <message device='EQMod Mount' name=''>
2015-01-25T17:06:09: Driver indi_eqmod_telescope: read setSwitchVector EQMod Mount CONNECTION Alert
    CONNECT='Off'
 DISCONNECT='On'
2015-01-25T17:06:09: Client 0: queuing <setSwitchVector device='EQMod Mount' name='CONNECTION'>
2015-01-25T17:06:09: Client 0: sending msg copy 1 nq 2:
<message device="EQMod Mount" timestamp="2015-01-25T17:06:09" message="Error:  -&gt; tty read failed, check connection: Timeout error"/>


I am able to access the AtroEQ box using the firmware uploader tool, so there is no issues with the box itself.
I wrote a udev rule to map /dev/ttyACM0 to /dev/ttyUSB0
but getting the /dev/ttyUSB0 resource busy.

anyone would have a idea please?
Last edit: 9 years 2 months ago by Gonzothegreat. Reason: solved
9 years 2 months ago #2812

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

  • Posts: 314
  • Thank you received: 34
maybe its an permission problem? Could be you need to be in the "dialout/usb" group, on my gentoo system I need to be in the "uucp" group the get access to tty*
--= human, without Windows™ =--
pls excuse my bad english! :)
9 years 2 months ago #2822

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

If this is a new system, make sure to have your user added to the appropiate group. In Ubuntu:
sudo adduser $USER dialout

Then restart before trying again.
9 years 2 months ago #2823

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

  • Posts: 2255
  • Thank you received: 223

I'll give that a try this evening, and yes it's a brand install on a B+.
9 years 2 months ago #2825

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

  • Posts: 2255
  • Thank you received: 223
I've tried that and still the same thing.
9 years 2 months ago #2827

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

  • Posts: 2255
  • Thank you received: 223
here's an strace of the indiserver process while I try to connect to it:
)     = 0 (Timeout)
gettimeofday({1422294112, 282998}, NULL) = 0
gettimeofday({1422294112, 283787}, NULL) = 0
write(1, "<?xml version='1.0'?>\n<message\n "..., 162) = 162
gettimeofday({1422294112, 287441}, NULL) = 0
write(1, "<?xml version='1.0'?>\n<setSwitch"..., 278) = 278
gettimeofday({1422294112, 290862}, NULL) = 0
write(1, "<?xml version='1.0'?>\n<setSwitch"..., 277) = 277
select(1, [0], NULL, NULL, NULL)        = 1 (in [0])
read(0, "<newSwitchVector device=\"EQMod M"..., 1024) = 127
gettimeofday({1422294112, 297154}, NULL) = 0
write(1, "<?xml version='1.0'?>\n<setSwitch"..., 320) = 320
open("/dev/ttyS64", O_RDWR|O_NOCTTY)    = 7
ioctl(7, TCFLSH, 0x2)                   = 0
ioctl(7, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0
ioctl(7, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0
ioctl(7, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0
ioctl(7, TCFLSH, 0x2)                   = 0
write(7, ":e1\r", 4)                    = 4
gettimeofday({1422294112, 309743}, NULL) = 0
select(8, [7], NULL, NULL, {15, 0})     = 0 (Timeout)
gettimeofday({1422294127, 315406}, NULL) = 0
gettimeofday({1422294127, 316673}, NULL) = 0
write(1, "<?xml version='1.0'?>\n<message\n "..., 162) = 162
gettimeofday({1422294127, 320181}, NULL) = 0
write(1, "<?xml version='1.0'?>\n<setSwitch"..., 278) = 278
select(1, [0], NULL, NULL, NULL
9 years 2 months ago #2828

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

  • Posts: 2255
  • Thank you received: 223
Here's a bit of a good news, I have installed EqMac on my Mac and my AstroEQ works fine.
Now I need to figure out why indiserver does not want to connect to /dev/ttyS64

Some info about my PI:
root@ekos:~# /opt/vc/bin/vcgencmd version
Jan 21 2015 23:59:04 
Copyright (c) 2012 Broadcom
version 2433779e6b2d922c3d1fff6101413156e7db747c (clean) (release)
root@ekos:~# uname -a
Linux ekos 3.18.3+ #741 PREEMPT Fri Jan 23 13:32:52 GMT 2015 armv6l GNU/Linux
root@ekos:~# 
9 years 2 months ago #2829

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

  • Posts: 2255
  • Thank you received: 223
!!!!!FIXED!!!!!!

I have re-installed the SD-card with a fresh Raspbian install.
apt-get update / upgrade / reboot a few times
installed indiserver
connected my AstroEQ and it started to work.

The issue lies with the latest firmware/Kernel of the Raspberry pi.
Do NOT upgrade the firmware and Kernel to the following:
root@ekos:~# /opt/vc/bin/vcgencmd version
Jan 21 2015 23:59:04 
Copyright (c) 2012 Broadcom
version 2433779e6b2d922c3d1fff6101413156e7db747c (clean) (release)
root@ekos:~# uname -a
Linux ekos 3.18.3+ #741 PREEMPT Fri Jan 23 13:32:52 GMT 2015 armv6l GNU/Linux
root@ekos:~# 

The one I'm using now is that one:
root@ekos:~# /opt/vc/bin/vcgencmd version
Dec 19 2014 18:35:53 
Copyright (c) 2012 Broadcom
version 5abd572e2ed1811283443387af09377b95501c50 (clean) (release)
root@ekos:~# uname -a
Linux ekos 3.12.35+ #730 PREEMPT Fri Dec 19 18:31:24 GMT 2014 armv6l GNU/Linux
root@ekos:~# 
9 years 2 months ago #2830

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

Time to create page: 0.220 seconds