Astroberry Focuser with Adafruit Motor HAT
Replied by Kaczorek on topic Astroberry Focuser with Adafruit Motor HAT
Also make sure that you run sudo make install instead ust make install. Everything should work just fine when you follow these. If not, just let me know.
Radek Kaczorek
Astroberry Server | NEQ6 | Atik 460EX | Atik EFW2 | ASI 120MM
Please Log in or Create an account to join the conversation.
Replied by RobJones on topic Astroberry Focuser with Adafruit Motor HAT
Don't you ever sleep?

Please Log in or Create an account to join the conversation.
Replied by Kaczorek on topic Astroberry Focuser with Adafruit Motor HAT

Radek Kaczorek
Astroberry Server | NEQ6 | Atik 460EX | Atik EFW2 | ASI 120MM
Please Log in or Create an account to join the conversation.
Replied by Ihoujin on topic Astroberry Focuser with Adafruit Motor HAT
Best of luck!
Lubuntu 16.04
Skywatcher HEQ5 Pro Mount
Canon 600D Camera
Orion SSAG @280mm Guide Scope
PHD2
Adafruit Motor Hat shield
Adafruit GPS Module
Generic Bluetooth Joystick.
Startech 7 port powered USB Hub.
Please Log in or Create an account to join the conversation.
Replied by Ihoujin on topic Astroberry Focuser with Adafruit Motor HAT
The driver does still function in that profile mind you.
Nevermind. I fixed it by moving the executable from /usr/local/bin to /usr/bin
Lubuntu 16.04
Skywatcher HEQ5 Pro Mount
Canon 600D Camera
Orion SSAG @280mm Guide Scope
PHD2
Adafruit Motor Hat shield
Adafruit GPS Module
Generic Bluetooth Joystick.
Startech 7 port powered USB Hub.
Please Log in or Create an account to join the conversation.
Replied by Ihoujin on topic Astroberry Focuser with Adafruit Motor HAT
>Please refer to the attached images.
The photo illustrates how I was measuring the position. Each tick, 0-8 was drawn at 100 step increments.
The chart includes my data set. Each line represents a backlash value of 0 to 500 at 50 step increments. The drive-steps to take are along the X axis, 1 to 400. And the position reached from Zero with the compensation is the field of data points. Values of 0.1 only mean the needle budged indicating clearance of true backlash, which I now believe is under 50 steps, clearly evident in the chart on the far left.
Notice that as I increase the drive step value to travel further, the position obtained actually Decreases. Only once the drive step value is greater than the backlash setting does it trend back upwards linearly.
In addition, recall I set the scale with 100 step increments, but a difference of just 50 backlash comp steps results in a full position increment up the scale, rather than just a half position. So a backlash step is also traveling double what it should.
Curious. Above, I see it moved 49 steps overall when changing position. That is 2x Backlash (25) Minus 1 travel step.2017-09-20T01:42:30: Adafruit Motor HAT Focuser moved to position 6400
2017-09-20T01:42:45: Adafruit Motor HAT Focuser is moving inward by 1
2017-09-20T01:42:45: Adafruit Motor HAT Focuser backlash compensation by 25 steps...
2017-09-20T01:42:47: Adafruit Motor HAT Focuser moved to position 6351
Total Travel 400 Steps. Now backlash had no effect at all. As if it were 02017-09-20T01:58:05: Adafruit Motor HAT Focuser moved to position 6330
2017-09-20T01:58:09: Adafruit Motor HAT Focuser backlash set to 0 steps
2017-09-20T01:58:11: Adafruit Motor HAT Focuser is moving inward by 400
2017-09-20T01:58:28: Adafruit Motor HAT Focuser moved to position 5930
When they do count they count for double. And they only count after the travel steps are done.
It is as if there needs to be a delay to finish the travel before compensating backlash.
Please have a look once more when you have the time.
Thank you.
Lubuntu 16.04
Skywatcher HEQ5 Pro Mount
Canon 600D Camera
Orion SSAG @280mm Guide Scope
PHD2
Adafruit Motor Hat shield
Adafruit GPS Module
Generic Bluetooth Joystick.
Startech 7 port powered USB Hub.
Please Log in or Create an account to join the conversation.
Replied by Kaczorek on topic Astroberry Focuser with Adafruit Motor HAT
Radek Kaczorek
Astroberry Server | NEQ6 | Atik 460EX | Atik EFW2 | ASI 120MM
Please Log in or Create an account to join the conversation.
Replied by Ihoujin on topic Astroberry Focuser with Adafruit Motor HAT
It really took me this long to realize something was up because of a combination of few opportunities to use it over months of bad conditions and doubt that my design was sound.
I did have a buddy look at the code, and he thought maybe associating an integer value with a floating point number on line 146 is related. Only you would know.
And if you have the time, can a console option for stepper mode be added? (Single, Double, Interleave, Micro). I reason that will make it more convenient for DIY builds with different specs to not required recompiling for it.
Thanks again.
Lubuntu 16.04
Skywatcher HEQ5 Pro Mount
Canon 600D Camera
Orion SSAG @280mm Guide Scope
PHD2
Adafruit Motor Hat shield
Adafruit GPS Module
Generic Bluetooth Joystick.
Startech 7 port powered USB Hub.
Please Log in or Create an account to join the conversation.
Replied by Ihoujin on topic Astroberry Focuser with Adafruit Motor HAT
2017-10-01T23:34:33 Adafruit Motor HAT Focuser moved to position 0
2017-10-01T23:35:08 Adafruit Motor HAT Focuser is moving outward by 100
2017-10-01T23:35:10 Adafruit Motor HAT Focuser moved to position 100
2017-10-01T23:35:17 Adafruit Motor HAT Focuser backlash compensation by 25 steps...
2017-10-01T23:35:17 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:18 Adafruit Motor HAT Focuser moved to position 51
^Moved 2x set backlash minus travel steps (1). EKOS reports focuser moved to position 99.
2017-10-01T23:35:21 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:21 Adafruit Motor HAT Focuser moved to position 98
2017-10-01T23:35:22 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:22 Adafruit Motor HAT Focuser moved to position 96
2017-10-01T23:35:22 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:22 Adafruit Motor HAT Focuser moved to position 97
2017-10-01T23:35:23 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:23 Adafruit Motor HAT Focuser moved to position 95
2017-10-01T23:35:25 Adafruit Motor HAT Focuser backlash compensation by 25 steps...
2017-10-01T23:35:25 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:26 Adafruit Motor HAT Focuser moved to position 144
^Moved 2x set backlash minus travel steps (1). EKOS reports focuser moved to position 96.
2017-10-01T23:35:33 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:33 Adafruit Motor HAT Focuser moved to position 97
2017-10-01T23:35:34 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:34 Adafruit Motor HAT Focuser moved to position 98
2017-10-01T23:35:34 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:34 Adafruit Motor HAT Focuser moved to position 99
2017-10-01T23:35:35 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:35 Adafruit Motor HAT Focuser moved to position 100
2017-10-01T23:35:43 Adafruit Motor HAT Focuser backlash compensation by 25 steps...
2017-10-01T23:35:43 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:44 Adafruit Motor HAT Focuser moved to position 51
^Moved 2x set backlash minus travel steps (1). EKOS reports focuser moved to position 99.
2017-10-01T23:35:45 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:45 Adafruit Motor HAT Focuser moved to position 98
2017-10-01T23:35:46 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:46 Adafruit Motor HAT Focuser moved to position 96
2017-10-01T23:35:46 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:46 Adafruit Motor HAT Focuser moved to position 97
2017-10-01T23:35:47 Adafruit Motor HAT Focuser is moving inward by 1
2017-10-01T23:35:47 Adafruit Motor HAT Focuser moved to position 95
2017-10-01T23:35:49 Adafruit Motor HAT Focuser backlash compensation by 25 steps...
2017-10-01T23:35:49 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:50 Adafruit Motor HAT Focuser moved to position 144
^Moved 2x set backlash minus travel steps (1). EKOS reports focuser moved to position 96.
2017-10-01T23:35:53 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:53 Adafruit Motor HAT Focuser moved to position 97
2017-10-01T23:35:54 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:54 Adafruit Motor HAT Focuser moved to position 98
2017-10-01T23:35:54 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:54 Adafruit Motor HAT Focuser moved to position 99
2017-10-01T23:35:56 Adafruit Motor HAT Focuser is moving outward by 1
2017-10-01T23:35:56 Adafruit Motor HAT Focuser moved to position 100
Lubuntu 16.04
Skywatcher HEQ5 Pro Mount
Canon 600D Camera
Orion SSAG @280mm Guide Scope
PHD2
Adafruit Motor Hat shield
Adafruit GPS Module
Generic Bluetooth Joystick.
Startech 7 port powered USB Hub.
Please Log in or Create an account to join the conversation.
Replied by Kaczorek on topic Astroberry Focuser with Adafruit Motor HAT
Radek Kaczorek
Astroberry Server | NEQ6 | Atik 460EX | Atik EFW2 | ASI 120MM
Please Log in or Create an account to join the conversation.
Replied by Ihoujin on topic Astroberry Focuser with Adafruit Motor HAT
For a final tweak, I suggest setting the stepper mode to Double by default in the code. The added torque is useful to avoid skipped steps. And finally to update Astrobery Server with this version.
And with that it appears we have two mature focus drivers for the Raspberry Pi people can choose from. For the Adafruit Motor HAT, and Piface Digital driver boards.
Amazing work.
Lubuntu 16.04
Skywatcher HEQ5 Pro Mount
Canon 600D Camera
Orion SSAG @280mm Guide Scope
PHD2
Adafruit Motor Hat shield
Adafruit GPS Module
Generic Bluetooth Joystick.
Startech 7 port powered USB Hub.
Please Log in or Create an account to join the conversation.
Replied by Kaczorek on topic Astroberry Focuser with Adafruit Motor HAT

I will add the latest version to Astroberry Server next release.
Radek Kaczorek
Astroberry Server | NEQ6 | Atik 460EX | Atik EFW2 | ASI 120MM
Please Log in or Create an account to join the conversation.