×

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

Bi-monthly release with minor bug fixes and improvements

For those with focus issues

  • Posts: 278
  • Thank you received: 17

Replied by S on topic For those with focus issues

Finally some nice weather and I was able to test the new algorithm. I turns out that I also previously has a problem with my coma corrector so I have now switched to another one. This did wonders on the focusing and my curves are no longer very flat near the bottom but actually looks more V-shaped. After fixing this issue, all algorithms in EKOS actually seems to work OK, including Linear. I also identified that I might have some kind of slip in my focusing system, so next step is to fix this and hopefully focusing will be very reliable. So in total, it seems that most of my problems with focusing was related to both optics and mechanics. I look forward to trying out the linear algorithm more when I fix my remaining mechanical issues.

As I general note, it seems to me that indi/ekos/kstars have become much more stable during the last year. Great work to all the coders out there :-)
4 years 1 week ago #50754

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

  • Posts: 985
  • Thank you received: 160

Replied by Alfred on topic For those with focus issues

Yesterday I finally got to run an Ekos session and for the first time ever I did use the linear focus mode. From the very start it did perform flawlessly and IMO it reliably achieved the best possible focus position. I tested with two self-made stepper motors driven by a Robofocus compatible controller. Excellent work, Hy, thanks an awful lot!
4 years 1 week ago #50766

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

  • Posts: 278
  • Thank you received: 17

Replied by S on topic For those with focus issues

Hi!

I still can't get autofocus to work reliably. After fixing some mechanical and optical problems it is much better than before, but only works in say 50% of the time and this applies to all algorithms. In 100% of the time I can focus manually using the in and out buttons. Here is an example where the linear algorithm gave an error:

The algorithm continued to move the focuser the wrong way until it was so out of focus and could not detect any stars and gave an error.

Here are some other things that seems to mess with all the algorithms:

1. The HFR values calculated are very noisy in general, and I imagine it can be hard to focus with noisy values. I use 'auto star' and 'full field'. Maybe one should be able to choose also the minimum or maximum HFR instead of the average?

2. The star locater is sometimes locating non-stars, which messes up the HFR value. This can be e.g. hot pixels, edges of dust motes, edges of the CCD (my CCD for some reason give a black border around the whole image). I have tried all star detection algorithm and can't seem to get reliable results.

3. If image is far from focus, the star detection detects sometimes the edges of the donut-star-image produced by a Newtonian telescope and most often it does not detect the donut-start-images.

I have now ordered a ZWO EAF, which I hope will improve upon my FCUSB+DC AccuFocus motor, but all helps is appreciated since I imagine the EAF might not solve all problems for me...

Best Regards,
Søren
4 years 4 days ago #51069
Attachments:

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

  • Posts: 1208
  • Thank you received: 559
Søren,

Thanks for the feedback. Can you please do the following:

- Manual focus youself until you're in focus.
- Run the Linear focus algorithm with
- Full Field and the same anulus as you've used
- Detection: SEP (that should be better than what you were using with star detection & HFR)
- Experiment with gain, exposure & binning and see if you can get 50+ stars detected in each image (not absolutely necessary, but let's start there).
- Step size: same as you were using above.
- Make sure max travel is not limiting you--make sure it's very large for now
- I assume backlash compensation is off. Let me know if otherwise. (turn it off if you're having issues).
- Repeat several times or do whatever you have to do (and describe it) so that you get a failure .
- Send me a log

Notes:
The linear algorithm might work when you're way out-of-focus, but it's best to start it roughly in focus.
In your example above, even though it went back about 7 steps to start, it is still too far in to start.
I can't tell if you should increase the step size, or start with better focus. Try both if you have issues.

If you can, please retry and send me a log with at least the settings checked as in the attached picture.
Since you say it works about half the time, of course, please repeat enough times to get a few failures.

For my f/5.6 refractor with an ASI1600, I use 2x2 bins, gain of 200 and 3-5s exposure depending on the filter.

Appreciate your help in getting me to get this right,
Hy
4 years 4 days ago #51076
Attachments:

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

  • Posts: 278
  • Thank you received: 17

Replied by S on topic For those with focus issues

Thanks for the reply.

The (1) dot is what I would call close to focus. HFR ~1.7 and "perfect" focus may be like 1.3-ish.

There is no backlash compensation in FCUSB, as far as I know, do it should be off.

There is a "reverse direction" switch in the FCUSB tab. Could that mess with the algorithm? (maybe the motor is always turning the wrong way?)

The more stars the better in the image, when using full field?

I'll try again and report back. Thanks for making this happen in the first place :-)

I have attached an image of NGC 3793 and its friend, to show that it is not "all work and no play". I feel that everything is continuously improving at the moment :-)
4 years 4 days ago #51090
Attachments:

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

  • Posts: 348
  • Thank you received: 69

Replied by Giles on topic For those with focus issues

These are just some thoughts:

I have issues with the Linear focuser, so I'm just doing a manual focus for the time being (Capture frame, focus in or focus out, capture frame again).

I don't think, that I can improve or use the autofocus routines with any settings, but it is probably not the fault of those routines.

I think the main problem is that I essentially have a cheap focuser, attached to a DC (not Stepper motor).

Because it is a DC motor the "steps" is essentially a milliseconds setting, so when pointing at anything at any altitude >15 the focus in steps are actually a lot smaller than the focus out steps (gravity is helping the focus out, and working against focus in).

While it is probably a problem related to using a DC motor, it would be nice if the driver could somehow have a setting like - focus in / out step size ratio, or even Ekos focuser module to have different focus in / focus out step sizes (although probably better implemented in the HitecAstroDC driver, as this is strictly an issue with DC motors compared with Stepper motors).
4 years 4 days ago #51095

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

  • Posts: 1119
  • Thank you received: 182

That is a beautiful picture, Soren!

Regarding the FCUSB and the AccuFocuser/analog DC motor focuser: I basically use the same system, although the motors I just got from Amazon for $15, so cheaper than the (now discontinued) AccuFocuser system.
It works beautifully in my hands, but there are a few things to consider.
I think the main issues you are facing results from the differential load on the motor due to the weight of the camera/filter wheel. That means the motor will move faster in the outward direction than the inward direction.
But that can easily be fixed. This is the way how I did it:

1) Note the position on the focus tube where your telescope is in focus.
2) Then attach a rubber band or a string with a spring to the telescope and the other end to the focuser tube.



3) Next, you move the telescope into a 60 degree vertical position, so that you have average gravity force pulling on the tube.
4) Loosen the clutch screw, so that the tube now moves freely
5) Add or remove rubber bands until the tube is in equilibrium at the focus point, i.e. it neither is being pulled inside by too much force from the rubber bands and neither does it slide out.

That pretty much equalizes the force the motor has to work against when moving the tube inwards and outwards and now the timed movements will be approximately equal. That will dramatically improve the ability of any of the algorithms to find focus. Basically, the principle is no different from balancing the mount. You want to minimize the strain on the motors there as well.

A couple of other things that I find important:

1) Do not make the steps the motor moves too small. If they are smaller than the variability of the HFR, the algorithm will have trouble calculating the V-curve.
2) Hy suggests using SEP, which is definitely better than the Gradient algorithm you are using. However, for some reason I find that the Centroid Algorithm works best for me, closely followed by SEP.
3) I just use Full Field, without Autostar.

Unless there was a change in the code recently that may have caused these problems, this methods works beautifully for me. Here another screenshot showing the quality of the V curve using Hy's Linear algorithm:

4 years 4 days ago #51104
Attachments:

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

  • Posts: 348
  • Thank you received: 69

Replied by Giles on topic For those with focus issues

I've made a little modification to the HitecAstroDC focuser driver, wondering whether it might help out with the disparity between the In / Out focus rate.

The old driver had a setting to set the number of Steps / Second it would drive the focuser at.

I have split this out to two settings, one to control the rate that it focuses inwards and another to control the rate that it focuses outwards.

The idea is, you can, say point your telescope at a 45 degree angle and adjust these values so that focusing in and focusing out occurs at the same rate.

Because the HitecAstroDC is a relative DC motor and not a stepper motor, steps are effectively milliseconds of focusing in a direction, and focusing out is usually faster than focusing in (due to the gravity assistance of your imaging train).

Patch is attached, quickly dry tested with my focuser, will try it out on the next sky watch outing.

Disclaimer - I know nothing of programming, and if I've done something very silly then maybe someone could help correct it!
4 years 3 days ago #51148
Attachments:

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

  • Posts: 8
  • Thank you received: 6
Hi universalmaster,
I had very similar issues than you:
1.) The HFR values are "noise", so to get a reliable v-curve, I either had to use long focus-exopsures or averaging over many frames. This made autofocus very slow and not practical.
2.) When focusing with the full field, the different detection algorithms either detected to few stars, or to many "false" stars (noise, hot pixel).
3.) The the different focus algorithms move all very far out of the focus, so that eventually they don't recognize stars properly anymore. That gives completely wrong measurments for the HFR values at the edges of the v-curve.
All these issues prevented me from using autofocus automatically and without supervision.

I found a solution I am very happy with:
- Don't focus on your actual target, but focus on a bright star close to your target (really bright). (create a "fake" job in your scheduler, to slew to a bright star and focus, before slewing to your actual target).
- With a short focus-exposure time of 0.5 seconds, star detection "gradient", "Auto-select star" and "subframe", the algorithm reliably picks up the very bright star as the target to focus on. The short exposure time and the subframing means, that you can rapidly take many frames to get a more averaged (and less noise hfr measurments). (I average over 8 frames)
- The linear algorithm works best. Even if it moves far away from the minimum of the v-curve, the star is so bright that the algorithm still detects it reliably.
Because the v-curve is very clear and not noise at all, I can choose a tolerance of 0.5%.

With these settings, the automatic focuser works without intervention flawlessly and very quickly.

The only downside is the requirment to work with "fake" jobs in the scheduler, to slew to the bright focus-star of your choice.
4 years 3 days ago #51160

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

  • Posts: 643
  • Thank you received: 62
Hi!

I'm not sure if this fits here, but this is an issue I have. I use Polynomial. What happens is this: After having found a star and measured it a few times, at times the focuser goes some way out or in. Fine, if it so to speak would there measure a clearly more unfocused star. But what happens often is what is on the attached picture:



It seems to pick up some hot pixels, and then get data that severly corrupts the V-curve. ANd then might land on something that is far from good focus.

Does this make sense? What might I do wrong here?

Settings:
Algoritm Polynomial
Tolerance: 0,80 %
Initial step: 150
Max travel 600

I have a strong sense that longer exposure times limits this, as if higher SNR makes this less of a risk. However, sometimes, as now, it still happens.

Any ideas?

Magnus
4 years 2 days ago #51182
Attachments:

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

  • Posts: 278
  • Thank you received: 17

Replied by S on topic For those with focus issues

To comfort you, I can say that I see the same kind of error all the time. And with any of the star detection algorithms. Other non-star features are also sometimes picked up, like edges of dust mites, ccd defects and so on. Also sometimes extremely large features are found (most stars hfr 1.5 and then one with hfr 50). Maybe, when using full field, ekos should throw away outliers, i.e. extremely large and extremely small 'stars' when compared to the mean size of all stars?
The following user(s) said Thank You: Eric
Last edit: 4 years 2 days ago by S.
4 years 2 days ago #51197

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

  • Posts: 1208
  • Thank you received: 559
I agree with the above comments, which is why I strongly recommend you use the "Full Field" focus setting (in focus tab, under settings sub-tab).
Use it with an Annulus of like 25% 80%. Doing this and it will detect many stars, throw away outliers, and then average the results. This is much more stable.
I recommend the SEP star detection algorithm also.

Finally, if you're not happy with the Polynomial algorithm, please try the "Linear" algorithm too ;)
The following user(s) said Thank You: Magnus Larsson, Eric
4 years 2 days ago #51198

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

Time to create page: 0.799 seconds