×

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

Bi-monthly release with minor bug fixes and improvements

INDI focuser driver for Waveshare Stepper Motor HAT for Raspberry Pi / Rock Pi

  • Posts: 421
  • Thank you received: 102
Very nice! Just curious, what are using to control the stepper motor? The Waveshare HAT, or some other (possibly Arduino) controller?
3 years 10 months ago #54528

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

  • Posts: 1119
  • Thank you received: 182

Yes, very nice! I think as far as accurate focus is concerned, this may come to a draw. This is what I got from the middle of a large metro area (Dallas), Bortle 8/9, and with an inferior mount (iOptron SmartEQPro+; RMS 4+, 7 arcsec/pixel).



Not nearly as nice as yours, editing not yet completed, needs more narrowband, but this is about focusing. The focusing routine (linear, automated and repeated hourly through the night) was posted earlier in this thread.
Last edit: 3 years 10 months ago by Jose Corazon.
3 years 10 months ago #54532
Attachments:

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

  • Posts: 59
  • Thank you received: 3
The focused worked much better last night. I now get the expected V / curve during auto focus. I could repeatably move focus away from the focus point and back to the same step number and things were in sharp focus. I still need to tune the parameters for the auto focus algorithm itself. It was never able get it to automatically choose the focus point (though I was able to choose it myself based on the data from the auto focus process). I’m using the linear focus algorithm. Once it finishes the first pass, it then appears to try to take multiple readings at the same steps right around the focus point. However my seeing must be varying enough that it couldn’t get consistent enough readings without moving the focuser and would eventually error out. I adjusted the tolerance % without success, though I’m not sure that’s the right parameter. I didn’t spend a lot of time as I wanted to get started imaging, so I just chose the best focus point and moved on.
3 years 10 months ago #54558

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

  • Posts: 421
  • Thank you received: 102
Congrats on the progress! :)

For myself, auto selecting a single focus point has never been reliable. I either need to manually select a single point, or use full field mode. Full field mode is the method I use now. You can even tell it to limit itself to the central part of the image, if you prefer.

I use the polynomial focus method. It seems to work well enough. I never tried the linear. I might give that a try. Some people say it works better.
3 years 10 months ago #54565

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

  • Posts: 1119
  • Thank you received: 182


I have always used Full Field mode. Set tolerance to 5%. Much depends on the initial step size with the linear focuser. If that is too large, it may miss the minimum. But once established for a specific focuser and telescope, it will hit the optimal focus every time.

If you have NO backlash, polynomial may be better, because step size will continuously decrease while converging upon the minimum. But if there is ANY backlash in your system, linear will be more consistent and reliable IME.
3 years 10 months ago #54566

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

  • Posts: 59
  • Thank you received: 3
Thanks for the advice everybody. Full Field mode worked *great* last night! It was bang on and worked the first time. Linear worked just the way that I would expect it to. I even tried polynomial mode and it picked the same focus point as Linear, though it didn't seem like it took enough data points to come to that conclusion. I'll have to play around with it more before I put my trust in it.

Woot! I'm really happy with how things are working. I'll still probably switch to the 5:1 stepper at some point, but I'm not in a hurry.
3 years 10 months ago #54640

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

  • Posts: 421
  • Thank you received: 102
Sweet! Another satisfied customer! :)

Sounds like you might not need the geared stepper.
3 years 10 months ago #54642

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

  • Posts: 59
  • Thank you received: 3
Its not needed, but it might provide some additional resolution, though it remains to be seen whether the mechanics of the RedCat or my seeing conditions lend themselves to improvement.
3 years 10 months ago #54643

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

  • Posts: 1119
  • Thank you received: 182

Great! Congratulations. Glad it works out well for you now.

I guess there is some truth to the saying that having a screw loose is not a good thing after all.... :-)

Best wishes,

Jo
3 years 10 months ago #54647

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

  • Posts: 59
  • Thank you received: 3
Everything has been working well over a few nights of imaging with one exception. I had an (apparently) unrelated issue where I had Kstars crash on me a couple of times. Once that happens while the focuser is not at zero, I have to manually move focus back to the zero position before starting indi / Ekos again. If I don't, the focuser is at the previous focus position (say 78) but the driver now thinks its at zero and there's no way to move past the zero point. Does anybody know of any way around this? I'm not sure there is a good solution. The best I can see would be to always save the focus position and assume it hasn't moved (while also moving to zero on a clean shutdown). Support for going below zero would also help manually get out of this situation if there was then a "set as zero" option to go with it.

I was hoping the stepper driver hardware might have support for stall detection so we could use something like 3d printers use for senseless homing, but it doesn't look like it does. I suppose another option would be an actual end stop / zero switch, but that would be a good bit of extra work / hardware.
3 years 9 months ago #54902

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

  • Posts: 421
  • Thank you received: 102
Sorry, I just now saw your post.

I use the "sync" feature for that. I just type in a large enough number (usually 5000) and hit "sync" in the focuser INDI control panel. It now things the focuser is at position 5000.
3 years 9 months ago #54991

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

  • Posts: 983
  • Thank you received: 375
Hi Kevin, I'm glad you found my Astroberry AMH driver inspiring and base for your project. Great work!
I have just purchased Waveshare motor HAT and given it a try with Astroberry DIY , which is much more advanced focuser driver than Astroberry AMH.
It supports DRV8834 and A4988 stepper controllers, supports custom GPIO pins, uses kernel native libgpiod instead of bcm2835 or wiringpi, remembers focuser position between runs and provides focuser temperature compensation with DS18B20 sensor.
It uses typical DIR, STEP, SLEEP, M0, M1, M2 pins connected to Raspberry GPIO so I tested it with Waveshare motor HAT. Well, it works but I faced some issues with microstepping and sleeping a motor.

As you probably have much more experience with this device, I've got two questions:
1) It looks like the device does not handle software microstepping without touching hardware i.e. dip-switches. Am I right saying that you cannot control microstepping with software only?
2) Another issue is related to sleeping a stepper motor. Apparently hardware designers did not wired SLEEP pin of DRV8825 to any of Raspberry GPIO. Does ENABLE pin cut off step motor power circuit so it does not get hot?

Clear skies!
3 years 5 months ago #60858

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

Time to create page: 2.213 seconds