×

INDI Library v1.9.8 Released (29 Sep 2022)

Bi-monthly INDI Library released with new drivers and bug fixes.

How can I select stepper2 on Adafruit Motor Hat on Astroberry

  • Posts: 5
  • Thank you received: 1
Hi I did have the focuser working on astroberry, but unfortunately I have blown the chip on the Adafruit motor hat.
I have proved that the second connection M2 is working Ok with a simple python script but I don't know how to tell astroberry to use M2 / stepper2.

I would really appreciate any help! Then all i need is clear skies.

Thanks in advance
2 years 3 months ago #58041

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

  • Posts: 385
  • Thank you received: 27
Slowlearn,

Can you reprogram the Arduino to swap the ports?

Paul
Losmandy G11 with Gemini 2 controller
QSI 583/683 monochrome cameras with filter wheel
Starlight Xpress Lodestar X2 guide camera
Microtouch Focuser controlled using Arduino UNO emulating Feathertouch controller
Raspberry Pi 2GB with Raspberry Pi OS 64bit Bullseye
2 years 3 months ago #58083

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

  • Posts: 5
  • Thank you received: 1
Hi Paul

Thanks for the reply but I am not using an Arduino, I have a Raspberry Pi 4 with an Adafruit motor HAT directly attached to the GPIO pins.

Steve
2 years 3 months ago #58089

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

  • Posts: 385
  • Thank you received: 27
Steve,

What controls the HAT?
Is it something in INDI?

Paul
Losmandy G11 with Gemini 2 controller
QSI 583/683 monochrome cameras with filter wheel
Starlight Xpress Lodestar X2 guide camera
Microtouch Focuser controlled using Arduino UNO emulating Feathertouch controller
Raspberry Pi 2GB with Raspberry Pi OS 64bit Bullseye
2 years 3 months ago #58091

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

  • Posts: 5
  • Thank you received: 1
Hi Paul
I am using Astroberry which has an inbuilt driver for the Focuser using the Adafruit motor hat. That is what I need to change, but i don't know how.
Steve
2 years 3 months ago #58092

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

  • Posts: 983
  • Thank you received: 375
The driver handles only stepper 1. However you can recompile it, forcing to use stepper 2.
Source files and instruction is located here: github.com/rkaczorek/astroberry-amh
After downloading the sources code change line 62 in the file amh_focuser.h so it says:
Adafruit_StepperMotor myStepper = hat.getStepper(2);

Then, compile, install and have fun
--
Radek Kaczorek
Astroberry Server | Orion CT8 | Askar FRA 400 | NEQ6 (hypermod) | Atik 460EX | ASI 1600 | ASI 120MM | Atik EFW2
The following user(s) said Thank You: Steve Conway
2 years 3 months ago #58103

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

  • Posts: 5
  • Thank you received: 1
Thanks Radek this looks like solution I was looking for.

This will save me buying a new Motor Hat

Thanks for your help

Steve
2 years 3 months ago #58130

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

  • Posts: 5
  • Thank you received: 1
Worked a treat thanks.

Just as a note to others that follow instructions.

Cmake was not on Astroberry image had to install it, and had to run Cmake as sudo, but still very easy and quick to sort out.
The following user(s) said Thank You: Bill McDaniel
2 years 3 months ago #58141

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

  • Posts: 983
  • Thank you received: 375
Thanks for the feedback Steve
--
Radek Kaczorek
Astroberry Server | Orion CT8 | Askar FRA 400 | NEQ6 (hypermod) | Atik 460EX | ASI 1600 | ASI 120MM | Atik EFW2
2 years 3 months ago #58145

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

Moderators: Radek Kaczorek
Time to create page: 0.874 seconds