×

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

Bi-monthly release with minor bug fixes and improvements

Driver OnStep (LX200 like) for INDI

  • Posts: 14
  • Thank you received: 0
Thanks Kbahey,

I still have trouble connecting with Ekos/KStars, both with an Onstep Maxi and Mini PCB, it works only sporadically.
Using the App, the OnStep works fine.

The python script gives an error, and I don't see the problem.
Python3 and Python3-serial are both installed and the script has been made executable.
Please see attachment.

Best regards,
Albert
5 years 4 months ago #32085
Attachments:

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

  • Posts: 452
  • Thank you received: 71
@James,
I am still struggling with Indi since the merge of yesterdy.
One thing is sure it has nothing to do with an error in the version.
The crash happens with all versions but not on all machines :whistle:

The faultly machine is an Intel Laptop
The Other machine is an AMD Desktop
Both run Debian Buster, same packages, libraries and kernel version so I woul expect to have the eeror on both, but No!

Symptoms:
When I run indiserver -vvv indi_lx200_OnStep (or run it from within Kstars)
the server crashes (contropl panel is opened but not initialized)
dmesg shows [17443.498606] indi_lx200_OnSt[15817]: segfault at 40 ip 00007feca554697e sp 00007ffcbb3981f8 error 4 in libc-2.27.so[7feca54d9000+146000]

After many time debugging it appear that the crash happens during loading of the xml config file .indi/LX200\ OnStep_config.xml

So effectively when removing the entry for the serial port
<newTextVector device='LX200 OnStep' name='DEVICE_PORT'>
<oneText name='PORT'>
/dev/ttyACM0
</oneText>
</newTextVector>

the server starts and runs fine as long I do not update the config file. I can shutdown and restart the server without crashes.
But as soon I update the file the problem is there again.

If somebody has an idea before I commit ......... :)

I will continue to try to find what causes this behaviour but it is not easy to debug, the debugger crashes too when I arrive at the point of the error.

at least the weather is horrible so I have no frustration on this side :-)
5 years 4 months ago #32098

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

My fault, it's fixed in GIT.
5 years 4 months ago #32112

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

  • Posts: 452
  • Thank you received: 71
Jasem,
there is a nice phrase in French: "Faute avouée, faute pardonnée" (Admitted fault, forgiven fault)
At least I passed a nice foggy day to debug, it was not in vain, during searching I learned lot of other things.
Just tryed it now, yes it is fixed.

Thank you for the Fix
5 years 4 months ago #32124

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

  • Posts: 107
  • Thank you received: 4
Onstep and INDI connection issue

Short My Setup
Setup Linux with Canon, SX CC, OnStep, OnFocus, One USB hub OnStep and OnFocus
This setup is working, When i replace OnStep with my FS2 usb to serial all are working in INDI But with the OnStep
The aim is to move to Raspberry

I use the
Onstep version 1.17 Last Alpha, type Mini. Umbuntu 18.04 LTS Gnome 3.82.2 64 Bit
Indi Last versions LX200 onStep 1.3 int 5

The Issue 1. Connecting via USB
The connection on wifi is working partly this means.
Status is connected., Site Management is updated from OnStep,
Firmware is displayed correctly but the status is grey instead of green
OnStep status Tab :GU# Return Npza/ET0 No idea what this means
The position of the scope as defined (in Coordinates) via my phone is pointing to the right star.
Mount controllable gives the status left below Error.

The logs after start up everything goes oke until

==> Update OnSTep Status
CMD <:FG#>
RES <-2>
CMD <GR#>
The Error Reading RA/DEC
CMD <GR#>
The Error Reading RA/DEC
endless loop

Thats the end

The replay on CMD <GR#> must be like Reply: HH:MM:SS# * From the site of howard
But the answer i don't see


The second issue: Connecting via USB
Communicated @9600 failed on
Connect via USB get Failed to connect (/dev/ttyUSB0) Error: Port Failure Error: No such File or directory Check device is connect to port

(the Usb connections with my Window PC no problem and under INDI with the FS2 Usb/Serial als on issue anymore)


here after de search of port connection successful
attempting to handshake using ACk
No response on ACk
Handshake failed


Any Ideas how tow handle this two issue

Chris
5 years 4 months ago #32126

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

  • Posts: 452
  • Thank you received: 71
Chris,

I try to answer to your questions:

Setup Linux with Canon, SX CC, OnStep, OnFocus, One USB hub OnStep and OnFocus
What is SX CC?

When i replace OnStep with my FS2 usb to serial all are working in INDI But with the OnStep do you try to connect OnStep with FS2? Sorry I do not understand here.
Seems you try a complete setup before making sure each individual piece is working, this makes difficult to interpret errors and answer.

You say "The Issue 1. Connecting via USB The connection on wifi is working partly this means."
Are you trying to connect via WiFi or USB?
WiFi does not work with Indi if you try to connect on the WiFi Server

I did it via a Raspberry see

GU# Return Npza/ET0 (this is documented in command.ino in the OnStep code) see below
=======================
reply to :GU#

n Not tracking
N No Goto
p Not Parked
P Parked
F Parking Failed
R PEC Recorded
H Telescope at Home
S Synceced from PPS
G Guide Active
f Axis1/Axis2 fault


#ifndef MOUNT_TYPE_ALTAZM
r refractoring compensation enabled
s refractoring compensation single axis
t refractoring full compensation enabled
#endif

w Waiting at Home
u pause at home enabled?
z Buzzer enabled

a autoMeridianFlip

#ifndef MOUNT_TYPE_ALTAZM
const char *pch = PECStatusStringAlt; reply[i++]=pch[pecStatus]; // PEC Status is one of "/,~;^" (/)gnore, get ready to (,)lay, (~)laying, get ready to (;)ecord, (^)ecording
// if (wormSensedAgain) { reply[i++]='.'; wormSensedAgain=false; } // PEC optional (.) to indicate an index detect since last call
#endif

E Mount type German Equatorial Mount
K Mount type Fork
k Mount type Fork Alt
A Mount type Altazimuthal

o PierSideNone
T PierSideEast
W PierSideWest

n an number 0 ..9 for last Error
=============================
Firmware is displayed correctly but the status is grey instead of green. You are right it is confusing, I take note. This could be green as soon communication is working.

Connect via USB get Failed to connect (/dev/ttyUSB0) Error: Port Failure Error: No such File or directory Check device is connect to port
this is a normal message at first connection attempt, but there is an option in the connection tab "Scan Ports" and "Auto Search Enable"
Normally after a while Indi finds the correct port which should be something like /dev/ttyACM0

I fear there is a mismatch between OnStep, OnFocus somewhere in Indi when you connect both via USB.
(Indi OnStep driver trying the link to OnFocus and vice versa)

Don't forget the ports change each time you connect an USB except if you define rules in /etc/udev/rules.d

I would suggest before testing a complete setup, to test individually each piece (may be you did but not as described)
Check OnStep alone with Indi, if it works go ahead and check OnFocus .... ans so on.
5 years 4 months ago #32133
Attachments:

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

  • Posts: 107
  • Thank you received: 4
Alain

Thanks for you quick and big replay
Below the point, your questions
1. SX CCD is the SX Lodedstar.
2. I have the whole INDI Kstar setup working with my FS2 (USB to RS232). I only change the FS2 with the OnStep. I didn't change the USB Ports (during the test i removed only the OnFocus USB connection
3. The issue 1 (Typo must be Connecting Via Wifi is not working as expected sorry :-)
4. The drawing i like Cool, thanks. I will add the focus -stepper to my mini setup this weekend.
You are running also on the Onstep mini, which operating system do you use on de RASP, Ubuntu Mate?
And aim right the RASP is the wifi AP and router do you have extra wifi adapter to connect to the internet?

About the issue 1 wifi, connection is not working 100%
"WiFi does not work with Indi if you try to connect on the WiFi Server" What doe you mean with this. I connect my wifi of my laptop to ONSTEP
and than i add the IP adres and Port of the OnStep in the Connection Tab after selecting Ethernet. Skysafari on my ip works with that. Do you mean that i must configure my OnStep that it will join my local network and from there connect to the OnStep via Indi? What is the symptom from your point of view in the way i connect to the wifi

Issue 2, Connecting via USB to the OnStep
I will check the usb if there is no hardware issues, I did all the steps, but its still strange because it works under windows with Howards ASCOM drivers ;-)
I did it again, connected the OnStep and on camera ( Star/Indi requires one camera)

I enabled Auto Search
First on port found then
waring Communication with /dev/ttyACM0 @ 9600 Failed. Starting Auto Search
repeating the last message

Still hoop you have some more suggestions

Chris
5 years 4 months ago #32136

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

  • Posts: 452
  • Thank you received: 71
@calberts,

Sorry for the WiFi. I cannot check since I dont have the hardware anymore. At the time I tested it was not possible and I had so much trouble flashing this horrible ESP8266 that gave it up at the profit of the raspberry solution.
But on the principle, yes the way you describe it should work provided the ESP let you pass lx200 commands.
May be somebody else vcan help you on this one.

Concerning connection via USB, it is starnge that you have a correct update of OnStep status but no answer on ":GR#".

A trial with minicom could also help to see if communication works or not.

Have you logs (setup in option tab, see picture) and then you shoud get somhing like that under ~.indi/logs/2018-11-30/indi_lx200_OnStep/
=============== logs
INFO 0.002136 sec : Session log file /home/alain/.indi/logs/2018-11-30/indi_lx200_OnStep/indi_lx200_OnStep_16:31:35.log
DEBUG 0.004782 sec : Active Snoop, driver: Dome Simulator, property: DOME_PARK
DEBUG 0.005766 sec : Active Snoop, driver: Dome Simulator, property: DOME_PARK
DEBUG 1.422239 sec : Connecting to /dev/ttyACM0
DEBUG 1.423027 sec : Port FD 8
DEBUG 1.423096 sec : Connection successful, attempting handshake...
DEBUG 1.423159 sec : Testing telescope connection using ACK...
DEBUG 1.428481 sec : Testing successful!
INFO 1.428610 sec : LX200 OnStep is online.
DEBUG 1.430089 sec : Configuration successfully saved for DEVICE_PORT.
DEBUG 1.431553 sec : Configuration successfully saved for DEVICE_BAUD_RATE.
DEBUG 1.433205 sec : Configuration successfully saved for CONNECTION_MODE.
SCOPE 1.434321 sec : CMD <:GR#>
SCOPE 1.452819 sec : RES <15:40:10>
SCOPE 1.452869 sec : Coordinate format is high precision.
SCOPE 1.452879 sec : <ACK>
SCOPE 1.452886 sec : CMD <0X6>
SCOPE 1.456815 sec : RES <P>
SCOPE 1.456861 sec : <getTimeFormat>
SCOPE 1.456870 sec : CMD <:Gc#>
SCOPE 1.465066 sec : RES <24>
SCOPE 1.465123 sec : <getSiteName>
SCOPE 1.465138 sec : CMD <:GM#>
SCOPE 1.481480 sec : RES <Schoenau>
DEBUG 1.481532 sec : Site Name <Schoenau>
SCOPE 1.481566 sec : <getTrackFreq>
SCOPE 1.481579 sec : CMD <:GT#>
SCOPE 1.497823 sec : RES <0.00000#>
SCOPE 1.497883 sec : VAL [0]
SCOPE 1.497908 sec : <getSiteLatitude>
SCOPE 1.497924 sec : CMD <:Gt#>
SCOPE 1.514193 sec : RES <+48*13>
SCOPE 1.514248 sec : VAL [48,13]
SCOPE 1.514264 sec : <getSiteLongitude>
SCOPE 1.514277 sec : CMD <:Gg#>
SCOPE 1.530709 sec : RES <-007*39>
SCOPE 1.530758 sec : VAL [-7,39]
DEBUG 1.530779 sec : Mount Controller Latitude: 48.2167 Longitude: 7.65
DEBUG 1.531260 sec : Configuration successfully saved for GEOGRAPHIC_COORD.
======================
5 years 4 months ago #32140
Attachments:

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

  • Posts: 107
  • Thank you received: 4
Hoi Alian

Yes the ESP-01 was very hard, i remember more than year ago i had lot of Mail conversation with Howard to fix this. I stop the project. But the OnStep evolved in code today its very easy to flash the ESP when all components are on the PCB. Form its working all under windows 10 with the ascot drivers of howard.

The Indi/Ekos Setup looks promising, the problem with my existing setup is that my FS2 can't park and Cant do the median flip. To get this working for remote Observatorium i need this functions, so that the why for the OnStep. So a little background of my journey;-)

In de meen time i have I have change the ESP WIfi to Join my local network, still the same Indi Driver gets information from the OnSteps but will not go in track mode
The mount control status is in error. and looking in to the logs its shows

==> Update OnSTep Status
CMD <:FG#>
RES <-2>
CMD <GR#>
The Error Reading RA/DEC
CMD <GR#>
The Error Reading RA/DEC
endless loop

So i get not any RES value back than only the error reading RA/DEC.
It makes no difference using my local network or connect to the AP of the OnStep

And connection with USB still Fails also executing with your suggestions.

So what ideas are left? Which lung do you used on your raspberry which worked?


Chris
Last edit: 5 years 4 months ago by Chris Alberts.
5 years 4 months ago #32147

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

  • Posts: 452
  • Thank you received: 71
Chris,

On Raspberry unbuntu mate OnStep works out of the box.
Just need to follow the instructions in the Download area www.indilib.org/download/ubuntu.html

Did you make the test with minicom and direct connection via USB?
without an output of the terminal session I cannot give you more help.

Start mith minicom -s
Configure you serial port
/dev/ttyACMx (where x is depending on your system) (ls -l /dev/ttyACM* )
set the communication to 9600,8,N,1 no flow control

and then you are ready to communicate with OnStep via the terminal

just enter some lx200 commands lik :GR# og :GD# and you should see returned values
============== here an output of minicom terminal session zith OnStep
Bienvenue avec minicom 2.7.1

OPTIONS: I18n
Compilé le May 6 2018, 08:02:47.
Port /dev/ttyACM0, 21:31:12

Tapez CTRL-A Z pour voir l'aide concernant les touches spéciales

:GR#19:46:04#
:GD#+90*00:00#
:GD#+90*00:00#
:GR#19:46:28#
:GU#nNpHz/Eo0#
:FG#11627#
============================
5 years 4 months ago #32153

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

  • Posts: 322
  • Thank you received: 31

That is why for the STM32 PCB, we opted to use the WeMos, which has a micoUSB port, and is flashed directly, without any changes in the config file for it. The defaults work the first time you try. You then plug the WeMos into the PCB and leave it there and it just works.

Easier for everyone.
5 years 4 months ago #32155

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

  • Posts: 452
  • Thank you received: 71
Khalid,

this is alos my point.
I received recently a Wemos from HK but did not yet test it.
My set-up via the raspberry really work well and will not change it.
This is why wanted to build a STM32 based OnStep, but the builtup takes some time (to busy elewhere).

What about direct connectivity via WiFi to Indi, does it relally work now? or is it still the web server only?

regards
Last edit: 5 years 4 months ago by Alain Zwingelstein.
5 years 4 months ago #32157

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

Time to create page: 0.597 seconds