I should point out that I observe the same issue with the kstars/indi Windows build (Windows 10) as well as directly with the kstars/indi build on Stellarmate on the Raspberry Pi
Shutting down the client windows and opening them up again will sometimes *not* show a value in the fields (hi-lighted in red in my screen captures) then for the same session shutting down
the client windows and stopping/re-starting indi will sometimes show a value in the field.
I observe that shutting down kstars completely and then restarting is another way that I'm able to reproduce the issue (sometimes)
I've not yet worked out the exact pattern/scenario to reproduce this consistently but I'll stick with it until I do.
A fresh install is a good idea. I have a vanilla build of Stellarmate on another SD card which I can bring into play.
I'll see about starting from that sd card then fetch the nightly build and then see if I can reproduce the issue
I think that the only way you might to the bottom of this is if the serial log files are looked at,
Thant would determine if it is a serial timeout issue, a serial timing issue on connect, or if it is a problem in either the firmware or higher up the chain.
2. Start the INDI server
All devices defined in the equipment profile will start-up as expected
3. Open Kstars
4. From the Kstars "Tools" menu select "Ekos"
5. "Start" Ekos from the "Ekos Profile - KStars" GUI
In my case, I have it set in my equipmemt profile to "auto connect" all devices
6. Click "Connect" to connect all devices defined in the equipment profile
7. Once the "INDI Control Panel - Kstars" screen opens then navigate to the MyFocuserPro2 page
Note the values shown in "Absolute Position" and "Max Position" fields
e.g. In my case see the first screen capture below
Note the empty fields for Absolute Position and Max Position
8. Close the "INDI Control Panel - Kstars" screen
9. Click "Disconnect" to disconnect all devices
10. Stop Ekos
11. Close Kstars
Follow steps 3 through 7 again
Now note that this time once you get to step 7, the Absolute Position and Max Position fields are now populated as expected
e.g. In my case see the second screen capture below
12. Close all screens and disconnect devices
13. Stop the indi server via the Stellarmate web manager
Repeat the steps 1 through 7 to reproduce the issue again
If you don't use Stellarmate, substitute steps 1,2 and 13 for the equivalent steps for your set-up
I think we may have a misunderstanding here. Your first picture clearly shows the abs and max fields are filled in. The zeros are in the set fields, what ever value you choose to put in those fields and then click set will either move the focuser to the new position, or update the max field.
What causes the behaviour with the fields "to the right" getting populated/non-populated given the steps followed ?
NB: Nothing was manually changed when walking through those steps yet the fields "to the right" got set to zero and then subsequently got populated without any intervention
The topic has been locked.
8 months 2 weeks ago
8 months 2 weeks ago by ajt68.
All I can say is that it is not driven from the driver. At the end of the day is it a bug or an annoyance, either way it is unexpected behaviour. Maybe ask the question in a separate thread, is there a gui forum?
It seems to me this behaviour is frequent in other drivers and cannot be regarded as a bug nor an annoyance. In my opinion, there is no clear interest having this box filled out, as the value is already set in the left one at the connection.
Great thanks to the developer(s). I hope this driver will be included soon in the stable indi library.
Ok, here is what causes this behavior. If all drivers, you have updateProperties() function. In this function, we define or delete properties based on whether we are connecting or disconnecting.
If the properties are initialized _before_ we define them, then both the right and left fields in KStars would be equal. I just took a look at the driver code, and made changes so that values are read before we define them. I pushed the changes to master, please compile and retest.
I have just committed change for serial connection poll period to be specified from 1 - 30s.
Regards, the commit that fills in the max and abs "set" points to be the same as the actual values just seems wrong to me. I think the change should have been to make sure these fields always be zeroed on connection.
Also things like reverse direction, max step, temp comp. should also be on the options page, as they are options and probably only need setting once, but this would require overrides and so perhaps should be applied in the base class? The abort button should also be more accessible and obvious, possibly next option after Direction, or better still when the Abs or Relative Set buttons are pressed, they toggle to Abort buttons?
The next thing in my sights is "Home Position" and "Backlash", both of which I need to understand a bit more before implementing.
I saw that the auto focus control in Ekos has a backlash tick box and value, but they are greyed out. I do not know why I cannot access them, but if I could it negates having to do it in the focuser driver?
I am nervous about implementing "Home Position" as I do not understand the logic behind it yet. Is it a button that triggers the focuser to move toward zero until the switch input is seen? If so is there any protection against just endlessly driving the focuser in, perhaps because the switch has fallen off, or does it get to maybe -10 and then stop, as a safety measure? Or is it just an option , that if selected causes the focuser to do the same as already described but on startup?
If Robert does not respond in this thread I will ask in his forums.
In myFocuserPro2, home position is a method of going to position 0.
If no hardware switch is fitted, the focuser will stop when the focuser position is 0.
If a hardware switch is implemented, then myfocuserpro2 firmware will manage and find the 0 position based on the switch value. And yes there are limits and methods in firmware to prevent endlessly winding the motor to oblivion. But INDI shouldnt really know about this, its in firmware and that is where it is managed.
Thus is any case the end result of HOME POSITION is ending up at position 0.
This does not need to be managed by INDI, in fact it would not be a good thing in my opinion. INDI should not be concerned with exactly how that is done.
In terms of backlash, there are two ways to look at this.
1. Let the client application handle it [disable backlash in the firmware]
2. Let the firmware handle it [enable backlash in the firmware]. In this case the application should not handle backlash else you have two competing methods fighting against it.
If backlash is enabled in firmware, it really does not need to be changed/altered that much over time. It is not like tommorrow one wakes up and backlash has suddenly halved or doubled. Once set it is remembered by the controller in EEPROM, thus retored when the controller boots.
So if one used windows or even a serial terminal to configure the backlash in firmware it will be remmebered and thus INI would not be required to remember it. It depends if you want to place that capability in the INDI driver or leave it to a client app to manage.