×

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

Bi-monthly release with minor bug fixes and improvements

Celestron Motorised Focuser - Is it supported in EKOS yet

  • Posts: 13
  • Thank you received: 2
I have a focusor and a Stellarmate, Happy to give you remote access if it helps.

Let me know what you need and I can arrange it
5 years 1 month ago #35087

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

  • Posts: 200
  • Thank you received: 57
Jasem!
I do not know if you noticed but the AUX communication protocol is already implemented in nexstarevo driver. If another driver starts to run the same stack both will stop to work (there is no queue and target selection in the protocol). We need to move the comms to the common place and add target arbitration. Maybe I can help with some parts of that task.
The following user(s) said Thank You: Jasem Mutlaq
5 years 1 month ago #35091

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

  • Posts: 554
  • Thank you received: 138
I have a Celestron focuser that I will be able to use for testing once there's some code to try.
I can help because I implemented the combined ASCOM telescope and focuser drivers. Celestron provided me with a beta version of the focuser.

There are a number of possibilities for connecting:
a) Connect the focuser to the mount and use the connection to the AUX bus for the telescope and the mount. That could be an extension to the nexstarevo driver.
b) Connect to the focuser independently of the telescope using the focuser's USB port. This also used the AUX bus connection.
c) Connect the mount and focuser using the AUX bus connector, not the focuser USB connection, and use a connection to the base of the HC to control both the telescope and focuser. that uses the same commands but through the HC passthrough engine.

I described some commands a few days ago, some more are:
// Focuser commands
FOC_ENABLE_CALIBRATE = 0x2A, // send 1 data byte 1 to start calibration, 0 to stop
FOC_IS_CALIBRATED = 0x2B, // return 2 bytes, [0] != 0 for calibrate complete,
// [1] is calibrate step, up to 12

FOC_GET_HS_POSITIONS = 0x2C, // returns 2 uints, [0] is low and [1] is high

I'm not an expert with INDI or C++ so setting up the structure of the various drivers is something that would be better left to the experts but once there's something there I should be able to help with debugging adding functionality.

Chris
The following user(s) said Thank You: Jasem Mutlaq
5 years 1 month ago #35092

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

Thanks Chris! That clears it up. I believe we definitely need to have a dedicated driver for #2. I can create a skeleton driver today in a new branch (celestron_focuser) so you can get started on that.

For #1, can we also add this support to the regular Celestron driver as well? This way both drivers can control the focuser. The driver also uses a few passthru commands.

Pawel, maybe you can suggest to Chris how to proceed in the nexstarevo driver?
5 years 1 month ago #35095

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

Chris, I'd like to know if you if the focuser USB connection is via HID or regular USB? how is it recognized by Linux?
5 years 1 month ago #35098

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

  • Posts: 200
  • Thank you received: 57
I "bet" it is just usb->serial converter connected to aux bus. This is the way Celestron does things. It would simplify things. We would not need three drivers just one and the abstraction leyer for the communication. As a side effect It would make implementing support for other mounts in nexstarevo driver trivial. And the protocol part is ready in nexstarevo driver.
We need common communication "server" inside INDI. I just do not know how to go about it.
Jasem - any ideas? Is there a driver model we can use or should it be a library providing singleton object menaging comms?
5 years 1 month ago #35102

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

  • Posts: 554
  • Thank you received: 138
Thanks Jasem, I'll look out for the new branch.

I think you are right, it needs a dedicated Celestron USB focuser driver and ideally adding a focuser to the nexstarevo and Celestron telescope drivers.

I'm not sure how the focuser is seen by Linux but in Windows it is a serial port. It seems to use the same connection as the USB port on the mount. I guess that the tty commands should work. The baud rate is 19200.

I'm not sure how the system prevents commands from different devices stepping on each other, I think it's by using the flow control lines CTS and RTS. This won't be an issue for a single controller connected to a single device.

Nexstarevo seems to use a UDP socket, however that seems to be because it only uses the WiFi connection.

Chris
5 years 1 month ago #35103

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

  • Posts: 200
  • Thank you received: 57
Adding the focuser to the nexstarevo would be simple.
Add new target and commands in NexStarAUXScope.h, add next axis in the processCmd selector for motor commands in NexStarAUXScope.cpp, and either process them the way emulateGPS is implemented or rather as one more axis. The rest is adding Focuser API
to nexstarevo.cpp/h using the additional axis in NexStarAUXScope.

But let me note that this will force everyone to load the nexstarevo for the focuser. This is non-intuitive and suboptimal. Three separate drivers is even worse - they will conflict with each other and will contain unnecesary duplication of code. I think that the factorization of tcp/serial code done some time ago by Jasem should be our model here. The rest is just a driver keeping track of motor position/movements and the INDI API/GUI.
5 years 1 month ago #35104

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

So it uses COM1 / COM2..etc in Windows? In that case, it's probably using USB to Serial adapter. Can you plug it in Linux and check the output of dmesg ?
5 years 1 month ago #35105

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

We can have one file to implement the commands and it gets called by the 3 drivers?

We need a dedicated driver because some folks might want to use it over USB and not via the mount. Then those using the Celestron and NexstarEvo drivers should be able to connect to the focuser as well.
5 years 1 month ago #35106

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

  • Posts: 200
  • Thank you received: 57
Chris, there is no target arbitration in the AUX protocol. All messages are broadcast over all devices and sockets. The HC pass-thru filters responses so you get only replies to your commands (you cannot snoop messages of other devices) - this will make gps emulator in nextstarevo not working over HC serial connection. But you cannot connect two drivers to one serial line they will disrupt each others' communication by eating characters from the buffer. It will be the same for the NSE driver (it uses TCP for comms UDP is just the scope detection) - the WiFi chip in the scope can serve only one connection at the time. The focuser would need to be implemented inside standard celestron driver, separately and inside nexstarevo driver. Only driver using usb would not conflict with others since this is a separate physical connection and usb layer handles the switching.
5 years 1 month ago #35107

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

  • Posts: 200
  • Thank you received: 57
Exactly Jasem. We would need to remove and use the AUX protocol implementation from the NSE driver, add serial line and HC-pass channels and make it into kind of server for the drivers. The usb case should be handled by starting separate instance of the server for this connection. The drivers will just get the data they register for, this should not be very difficult.
We have a similar case with the GPS emulator implemented inside NSE. Sometimes you just need a GPS for your scope but you need to load the mount driver for it and risk interference with HC operations. I would separate theis emulator into separate driver as well.
5 years 1 month ago #35108

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

Time to create page: 0.996 seconds