×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

Driver OnStep (LX200 like) for INDI

  • Posts: 257
  • Thank you received: 22
uhoh...misunderstanding. These things happen. :) No need to work around. I just (also) can't test onstep's focuser because I use an external driver. I emulated moonlite when I made it and my focuser works fine like that. I may choose to integrate it at some point to reduce usb load. We will have to wait for someone who does have the onstep focuser wired in before we can get a good test on it.
The tab did show up anyway ad looks nice.

Here's my messy report from last night. I'm planning to redo the test.

The control panel should show park at start (and cold start/reset) getting the status at startup should fix this even if the user has
"#define AUTOSTART_TRACKING_ON"

Setting tracking on or starting alignment procedure should unpark the mount and track sidereal.

Cold start should also reset alignment buttons and status.
(stayed on align and status at alignment completed when park clicked - scope did home)

I have a 2-10 second lag on commands I had not noticed previously, turned off debug to see if it helped.

Wrongly shows parked in ekos during alignment.

1 star align worked okay once I waited out the slew command.

Park returned home but failed to disable the motors?

Mount control "pad" shows error in status on opening during 3 star alignment - related to below i think.

after slewing to second star, could not click align. control panel Button already down. (something broke I think.)

This may not matter but PEC might be set to off by defult or maybe remember the previous setting.
I wonder how to store things in the save files. That would fix it too.

unit did not complete second slew from dubhe to capella
After doing meridan flip, stopped part way and showed error but no status reported as I had turned off
debug mode to see if it would speed things up.
-claims cannot stop slew to any command, cannot abort.
--this is my weird thing happened for the day.

could not cold start after error.

...it got late. I'd like do another run this evening if i'm not cleaning up water in the basement again and see if I can narrow down the issue.

I just realized that the flip probably caused the error. I should choose closer stars?
Last edit: 6 years 1 month ago by Ray Wells.
6 years 1 month ago #23270

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

  • Posts: 452
  • Thank you received: 71
Oh I see you made good testing.
Will investigate all this:
I am not really fond of encapsulated commands like Track On unparking the scope as well,
I rather would prefer to add a generic function "Initialize" may be with checkboxes as options.

I also noticed some lags on certain commands:
Example Focuser commands are slow to rtespond (tested with terminal)
I did remove polling of unnecessary focusers today (V1.301)
I have also some concerns about buttons not showing the righjt status, example Track On / Off but they are managed by Indi, have to look at it to see what is going on here
But many thanks for the exhaustive list.
6 years 1 month ago #23271

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

  • Posts: 452
  • Thank you received: 71
Hi Blueshawk,

See my answers hereunder and again many thanks for the report

The control panel should show park at start (and cold start/reset) getting the status at startup should fix this even if the user has
"#define AUTOSTART_TRACKING_ON"
===>
AUTOSTART_TRACKING_ON is not a configuration option (at least not in the Config files) thats why I did not consider it.
Tried to define it in my Config.MaxPCB.h and at cold start I have this situation and driver is showing the right status
I think since it is managed by the firmware nothing required in the driver.

===============================
Setting tracking on or starting alignment procedure should unpark the mount and track sidereal.
===>
This is really a question depending on type of installation, moveable or fixed.
there are two questions here:
track on --> unparks
tarck on --> sidereal rate
If I built in the track on button it becomes unflexible.
would prefer to add an option somewhere like selection boxes on track on -- Unpark -- Sidereal

===============================
Cold start should also reset alignment buttons and status.
(stayed on align and status at alignment completed when park clicked - scope did home)
===>
If fact it does in OnStep, I have to reset the buttons

===============================
I have a 2-10 second lag on commands I had not noticed previously, turned off debug to see if it helped.
===>
I obeserved this also.
I tested sending commands with terminal and observed dealy commes from certain commands.
But I never observe 10 seconds delays! all my serail traces are timestamped
I had also some polling for focuser even when not present.
disabled now when no focuser present.

===============================

Wrongly shows parked in ekos during alignment.
===>
Could not reproduce this

===============================

1 star align worked okay once I waited out the slew command.
===>
I have no way to follow Star Alignment except via polling of Manual Alaign Status ":A?#" that returns 3xx

===============================

Park returned home but failed to disable the motors?
===>
Park returned Home? Which version of OnStep do you use? Beta or Alpha?
when I issue a Park command, ":hP", the remaining process is fully under control of OnStep. I just poll the Status via ":GU# and wait eitehr a (P)arked (F)ailed (I)n Progress (U)nParkes in the status string
I had these issues with previous versoions where Park Failed depending on Backlash values.

Just retested with last Alpha and when Parked, Motors are Off
When UnPark Motors are On

===============================

Mount control "pad" shows error in status on opening during 3 star alignment - related to below i think.
===>
Do not understand

===============================

after slewing to second star, could not click align. control panel Button already down. (something broke I think.)
===>
The "Align" Button Down is something I need to fix (manage ISS_OFF/ISS_On on buttons) , but the button reacts on click.

===============================

This may not matter but PEC might be set to off by defult or maybe remember the previous setting.
I wonder how to store things in the save files. That would fix it too.
===>
PEC not yet implemented, button not connected to any command, for the time beeing is only shown due to HAS_PEC Option.

===============================

unit did not complete second slew from dubhe to capella
After doing meridan flip, stopped part way and showed error but no status reported as I had turned off
debug mode to see if it would speed things up.
===>
Do not see how to reproduce this.

===============================
-claims cannot stop slew to any command, cannot abort.
===>
Also heredo not see how to reproduce.

===============================

Sorry for some questions I could not answer

I really have to manage all the button status so the they are reflecting the real situation.

I think htis is my next task
6 years 1 month ago #23272

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

  • Posts: 452
  • Thank you received: 71
6 years 1 month ago #23273

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

  • Posts: 257
  • Thank you received: 22
I don't understand a few of those points yet myself. :unsure: Good to know the buttons weren't just out to get me. :P

I now think we have different firmware due to different arduino's and that may cause some things to work different too ...though the command structure should be the same for everybody. I need to retest and see if I can narrow my issues a bit. Soemthing like that could have even been supply related. More time needed.

For the record, I'm using an Arduino Mega2560 with DRV8825 stepper modules and belt driven 5:1 nema17 steppers to drive the slow motion controls of a Celestron Omni CG-4 with various implements of destruction mounted on it. Another arduino nano handles the focus. currently 2 ZWO cameras(asi178 asi120) send me images and guide via a powered hub to a raspberry pi3b running as a server connected at 1gig wired. Supply is 12v via battery and charger.

My current onstep.cpp shows:
"11 21 17"
FirmwareNumber "1.0b"

I have a config.h instead of Config.MaxPCB.h
I plan to look over old and new code to try to update if needed but I still need to work on my almost done filter wheel project sometime too.

I think I may have moved that autostart define to config.h myself after finding it commented out elsewhere in code in order to troubleshoot why my motor drivers wouldn't start. It is still commented out on mine. Or Maybe it was just removed as too problematic, Not sure. We're well past the point of needing it anyway. I was just thinking some people may set it to go at startup, in which case the park/unpark might not follow unless polled at startup. I need to read what you've done with it in code maybe that will help me understand.
I also think having a single straightforward and workable procedure to get up and running is what really matters in the end. Also, I like being able to shut down the motors and leave the mount set up and running so some sort of stop/start that leaves the thing aligned is nice, and maybe we don't need too many ways to do it.
For example, in the coming weeks I'll(hopefully) be setting up before I sleep then getting up before dawn to try to get some video data of Jupiter and possibly Saturn which are highest at that time for me.

re: Layout. What if we removed the track on/off completely and just added an off next to the different rates? so:
off || sidereal || lunar || Solar || custom
and that would take care of which one as it is already saved I think?
since parking is for settling into support mounts for big rigs it might be bad to track from there. That would also be handled by doing the above. ...unless I'm trying to reinvent the wheel while the car is moving.

I would do skype but I'm a chicken. :P Social situations wear me out very quickly. I may get up the courage at some point to try though. My family uses a program called Discord chat for gaming sometimes. Never have done skype much. Maybe a group chat with my older son along as a translator just in case. Have to be on a weekend though as I'm at -5utc which puts me (and him too) at work for reasonable times. Anxiety mode..engage... :S
6 years 1 month ago #23276

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

  • Posts: 452
  • Thank you received: 71
Hi Blueshawk,

when speaking about equipment:

My equipment:
Dobson 270 F6 vor visual use
Newton 250 F4 for Photo with motorized focuser
Lacerta-Mgen for guiding
Canon EOS 1100D for imaging
PiCAstro Controller for EQ6 and focuser

Developement Software:
Debian Testing
KStars 29.2 daily built from source
Indi daily built from source

OnStep Hardware:
Arduino Mega 2160 and DRV8825
Teensy 3.2 and A4988
Teensy 3.5 and 2xTMC2130 + 2xDRV8825
Did try ESP8266 but I fried two, they run but not able anymore to flash them (too much issued with these)

==========
The AUTOSTART_TRACKING_ON it is a simple solution for mobile mounts and as you said just define in the Config file and it seems it works and probably is the right solution to use OnStep without attached computer.

I don't think different hardware platform behave differently with OnStep since the interface with OnStep is command.ino.
Canged can come for Config File, example 0, One or two focusers.

I think this is one of the challenge with such a controller.
The driver must first verify all the possibilities of the controller before running and this is a little bit confusing to me at the moment.
OnStep implments a :GXnn# command tha should return the complete configuration as in Config....h

Considering the Commands having multiple actions and why I did not use it:

The one--> one way (On OnStep lx200command --> One button is easier to implement and sticks to OnStep functions.

OnStep itself does already internally multiple commands based on other, if I start to mic I will be lost soon.

On the other hand if I am sure each individual LX200 command is working then it would be easy to cretae a sort of batch
to rung commands in a sequence.

For the time beeing I prefer to test, remove bugs, work on some optimization and wait for my hardware top be build to start real testing.
6 years 1 month ago #23284

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

  • Posts: 257
  • Thank you received: 22
Debugging sounds like a plan. I need to spend time on other projects as well. I'm currently comparing code to get Onstep updated. I got most of the config and pins last night but my bluetooth module failed to light up. I think the new pinout may have used a pin I used to power it or something. With luck and some searching I should have it running on the new code in the next day or two, as well as nailing down any loose bits I changed that don't agree with the update.
I also fried at least one wifi module, spent a week with them and gave up, installing an hc-06 bluetoth instead. I still want wifi though. The Nodemcu modules are also problematic. You might try over flashing the whole esp8266 as that sometimes revives them but they are pesky little buggers for sure. I'm considering trying a wired ethernet module at some point.

Still raining!
6 years 1 month ago #23285

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

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

yes there are definitively big issues with these ESP WiFi.
Since My daughter lives in HongKong I will try to get a bunch for practically nothing so I can restart trying.

By the way the code in the WiFi is not as obscure that it could not be written for an Apache server on a Pi. I made some check and it is promising.

I just received the two MaxPCB from .... Utah :) it took six days.

Time to play a little bit with the soldering iron and order the missing parts, I was waiting for the PCB before ordering, never sure about the format to buy.

Yesterday, clear sky, install everything and ... snow :blink:

For Skype not an issue, I think I have Three addresses in my Skype, Mydaughter, My Neighbor and my Wife since I was always working abroad.

Regards
6 years 1 month ago #23286

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

  • Posts: 257
  • Thank you received: 22
@James_lan ...I just found your posts in a search! Hello and sorry if I seemed to be ignoring you. I think they didn't show up for some reason. And thanks for your help as well!

@Azwing
Yay snow! :P
After the story below I can report that the latest pull is working pretty well, though I still have some testing and mopping up to do.
I had to return to the earlier version of OnStep, my last working archive, after several hours of head scratching trying to figure out why things were so wrong. Lots of command fails and no motors or tracking at any point despite scouring the new config.classic.h and pins.classic.h . It's possible those aren't getting debugged due to the newer types popularity, so for now I'm going to stick to what is working. I found the broken bluetooth was actually a bad voltage regulator in the Arduino and swapped it from another unit that fell prey to the nodemcu debacle and lost its cpu comm channels. I think the damage was caused by a reset prevention cap causing a short while I fumbled around trying to get the download to go. I'm planning to install a small toggle or dip switch there to just lift that cap and let DTR do its job instead of the silly push button you have to hit at just the right moment to make work - and yet is on nearly every Arduino shield. :dry:
Since I had to return to earlier code I made a few changes while I had the unit apart and turned on the autostart tracking which got the rig running right away. Longitude worked too, unlike the update for some unexplained reason. I saw something in another thread that seems relavent to the whole longitudinal confusion we had(what we have now works). "INDI does not have negative longitude it is 0 to 360 E+" --that does explain a few things.
I noticed that even after fixes it always converts back to a positive 279 for my -80 location. Just something I noticed. I did notice thatI had to enter -80 while trying to use the new arduino code.

I put in skype4linux to patch to Pidgin chat[this failed badly - just run skype.] so I can use both skype and discord channels and found at least 4 accounts that have to be yours. :silly: I also finally joined the Onstep ".io" group. Last time I looked that was Yahoo. :blink: It was very busy.

okay...better get back to work changing tiny smt caps on this old 3 phase soft start.
cheers!
Last edit: 6 years 1 month ago by Ray Wells.
6 years 1 month ago #23308

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

  • Posts: 452
  • Thank you received: 71
My Skype accout is join.skype.com/invite/jTdvcEHPk0EC
Cannot remove the othjer one.
Today was a long sleeping mornig since I past the night outside, and it was a disater. My garden is surrounded by 4 public lights (have to speak with village mayor :-) and the trees do not help either but cannot speak to my boss :-(
No coding this week, rest a bit and see if some ideas come up.

Busy with hardware since my PCB arrived.

Regards
6 years 1 month ago #23311

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

  • Posts: 51
  • Thank you received: 9
I have been trying to get my OnStep Max connected to indi/ekos but Its failing. When I look at the logs I see this:

[2018-02-22T19:09:11.519 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Trying connection to /dev/ttyACM2 @ 9600 ... "
[2018-02-22T19:09:11.520 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Connecting to /dev/ttyACM2 "
[2018-02-22T19:09:11.520 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Port FD 6 "
[2018-02-22T19:09:11.520 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Connection successful, attempting handshake... "
[2018-02-22T19:09:11.520 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Testing telescope connection using ACK... "
[2018-02-22T19:09:21.630 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Failure. Telescope is not responding to ACK! "
[2018-02-22T19:09:21.630 PST DEBG ][ org.kde.kstars.indi] - LX200 OnStep : "[DEBUG] Handshake failed.

I'm running the latest Alpha version of Onstep from github with the lastest KStars-bleeding / Indi running on Ubuntu 16.04.

This same Onstep MaxPCB works
6 years 1 month ago #23567

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

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

I experienced this situation on both Teensy and Arduino hardware and found two workarrounds (not solutions).
1) Disconnect and Reconnect the OnStep controller USB which always solved the issue.

2) using a terminal (I use minicom) and issue a command (:GR# or :GD# to see if OnStep responds) and each time I saw OnStep not responding to the first command issue but answering correctly to the second and after that I diconnect terminal and retry a connection with Indi and it works.

I could not yet find out what is wrong and even was not able to find out which conditions produce this error but I am sure of one thing, the error is on OnStep side.
Somehow it happens that the serial communication hangs in a situation where AcK is not recognized.
May be there is some situation where at connection wrong serial charaters are received by OnStep (When I tried with terminal to send random characters I succeded to have OnStep not responding anymore, only after diconnect / reconnect)

Are you in position to test with a serial sniffer, to see if your problem is same I experience?

I use a scprit based on slsniff that I called « teensy »
The script uses slsiff
Opens a pseudo serial on devpts/n (where n can change)
You need to set this devpts/n in Indi Control Panel and connect

see screenshot 1
- Upper Left Terminal : Script call
- Lower Left Terminal : The script
- Lower Right the communication setup in Indi Control Pannel

Screenshot 2
After connection
as you can see the serial communication is printed on the top middle terminal


Hope this helps.

I am still trying to find a real solution but before I send a request to Howard Dutton I prefer to be 100 % sure that problem is on OnStep side
6 years 1 month ago #23570
Attachments:

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

Time to create page: 0.632 seconds