1. how to trigger a driver reload for dynamically created based devices in the indiserver and Ekos?
Alain: I did not find any way to do that in an unattended way nut via button ... not nice
Alex: ok, I will have a look if I find a way. The other solution would be to create all drivers static and disable them, if they are not needed.
2. is it possible to drop the dependency on Lx200generic?
Alain: Needs a complete rewrite from scratch and this is exactly what TeenAstro did.
Alex: First look does not seem to be that big of a deal. LX200Telescope is just 1600 lines of code compared to the onstep driver with around 5000 lines. And as the onstep driver is overwriting some functionality of the LX200Telescope driver this might be even less. But yes the change is still quite substantial. Thats why I am asking if this would be accepted or if a smaller change is preferred.
3. are there problems with concurrency when reading and writing to PortFD unprotected?
Alain: What do you mean by unprotected?
Alex: Never mind, I found the lx200CommsLock mutex.
4. what do you think about the hacky approach and a complete restructuring of the driver?
Alain: same as for 2, rewrite all from scratch
Alex: Ok, I assume the smaller change is preffered.

I will continue working on the "smaller change" solution. Thank you for your help!

regards
Alex

Read More...

Hi,

I had a deeper look into the problem of multiple focusers and stumbled upon some things I wanted to clarify before I continue.

One problem I see, when using FocuserInterface is, that it is impossible to inherit it multiple times. Because of that, it is necessary to have multiple BaseDevices which implement the FocuserInterface. I assume it would be better to use the INDI::Focuser class as a base for the Onstep Focuser. I also saw that approach in the focuslynx driver .
Unfortunately, this only works flawlessly for statically created drivers. Unfortunately, the diver tabs do not get updated when I create a new Focuser dynamically. It requires a reconnect to the indiserver within Ekos. But maybe I am still missing something.
You can see this in my basic implementation .
Furthermore the dependency on Lx200Generic restricts the implementation of a shared lx200 parser class. That's why the onstep_focuser needs access to the file descriptor PortFD and implements its own lx200 parser.
I attached a drawing to illustrate the new class hierarchy. (File: "Blank diagram Focuser Update.png")

This is quite a hacky approach and will result in some duplicated code. As I can see that there is a discussion about restructuring the driver I also made a drawing of a in my opinion better approach. (File: "Blank diagram New Structure.png") But this would mean dropping the dependency on lx200generic and writing some onstep protocol parser, that can be shared between drivers.
As a bonus, it would be also possible to make just a bare rotator driver.

Questions:

1. how to trigger a driver reload for dynamically created based devices in the indiserver and Ekos?
2. is it possible to drop the dependency on Lx200generic?
3. are there problems with concurrency when reading and writing to PortFD unprotected?
4. what do you think about the hacky approach and a complete restructuring of the driver?

regards Alex

Read More...

Hello Alain,

I am quite new to this topic and am very interested in contributing to the onstep driver and to onstepx. As my setup is using two focuser I would like to improve the second focuser feature in the driver. Right now the driver can be selected with a custom switch that is not used by any indi client application. To me this looks like a workaround to avoid adding multiple focusers to the driver.
Do you know if it is possible to add multiple focuser tabs to the driver, so it can be selected by client applications like Ekos etc.?
I am not quite sure if this is possible or if adding two devices of the same kind to one driver is not provided by the indi library.

regards
Alex

Read More...