Jump to content

SkySurveyBanner.jpg.21855908fce40597655603b6c9af720d.jpg

Help with Raspberry Pi Controlled Telsecope Mount


kman42

Recommended Posts

I have an EQ5 telescope mount which i use for astrophotography. I have modified it with a motorised RA axis using a bipolar stepper motor - my thread for the build is here .

I want to expand the mount's tracking ability by motorising the DEC axis and using a guide scope/camera. I generally use the mount in fairly remote locations so would like to use a raspberry Pi for portability.

I understand that I'll need to use a Raspberry Pi Camera Module for the guide camera. 

The capability I want is:

1. guide the mount along RA and DEC axes using a guide star as feedback

2. track the mount using the RA axis only, and if possible continuously take 20-30 second exposures on the guide camera (this functionality is optional, but would assist in polar alignment of the mount)

I don't want any GOTO capability. I am very new to RPi and need some help:

- do I need to write code for this, or is there existing programming available for what I want to do?

- is it possible to avoid the use of screens (in the field)? My preferred option would be to flick a switch to start and stop the guiding, with another switch for alignment mode (or something simple like this).

- do I need to use any particular stepper motors/drivers for raspberry Pi? I'm using a bipolar stepper motor running quarter steps, with an A4988 stepper driver

- is the RPi 3 Model B+ the unit I should buy?

Thanks

 

Link to comment
Share on other sites

51 minutes ago, kman42 said:

I have an EQ5 telescope mount which i use for astrophotography. I have modified it with a motorised RA axis using a bipolar stepper motor - my thread for the build is here .

I want to expand the mount's tracking ability by motorising the DEC axis and using a guide scope/camera. I generally use the mount in fairly remote locations so would like to use a raspberry Pi for portability.

I understand that I'll need to use a Raspberry Pi Camera Module for the guide camera. 

The capability I want is:

1. guide the mount along RA and DEC axes using a guide star as feedback

2. track the mount using the RA axis only, and if possible continuously take 20-30 second exposures on the guide camera (this functionality is optional, but would assist in polar alignment of the mount)

I don't want any GOTO capability. I am very new to RPi and need some help:

- do I need to write code for this, or is there existing programming available for what I want to do?

- is it possible to avoid the use of screens (in the field)? My preferred option would be to flick a switch to start and stop the guiding, with another switch for alignment mode (or something simple like this).

- do I need to use any particular stepper motors/drivers for raspberry Pi? I'm using a bipolar stepper motor running quarter steps, with an A4988 stepper driver

- is the RPi 3 Model B+ the unit I should buy?

Thanks

 

RPi is a small linux based computer, -  you can also install adjusted Windows for it (it was Windows 10 IoT I think).

Linux distros, for example Ubuntu, has free Astro software for guiding  and imaging (available to download), you can Install Ubuntu into any larger USB drive and boot it on your laptop to test the soft with your devices before you buy RPi.

Not sure about RPi windows version... never tried it before.

I guess, there are even Specialized Linux Distros for Astrophotography (with the software pre-installed), - you should be able to install them on USB stick for testing also, but I am almost sure not all of them will work with RPi

 

Edited by RolandKol
Link to comment
Share on other sites

P.S.

Once I had a thought about it also... the time spent on all the learning just for one particular task, - guiding - set me off.

I think,, - the second hand 14" laptop connected to WiFi and controlled via TeamViewer is much simpler/faster/ and probably cheaper solution in total.

Edited by RolandKol
Link to comment
Share on other sites

Raspberry Pi is quite handy for controlling astronomy hardware. I've been using it for a long time.

This however means switching to linux. If you're ready for this, take a look at KStars/Ekos, INDI and either install all the neccessary components RPi yourself or use ready to use RPi system images, namely Stellarmate or Astroberry Server.

I see some challenges though... First, you use custom solution for driving RA/DEC axis. Nothing that I know would support it out of a box. Second, using Raspberry Pi Camera Module is not supported with astro software I know. And the last but not least, make sure you're ready for a learning curve with linux and new software. It might be frustrating, however I believe it's worthwhile.

  • Like 1
Link to comment
Share on other sites

8 hours ago, RolandKol said:

P.S.

Once I had a thought about it also... the time spent on all the learning just for one particular task, - guiding - set me off.

I think,, - the second hand 14" laptop connected to WiFi and controlled via TeamViewer is much simpler/faster/ and probably cheaper solution in total.

I have considered this,  the laptop route will be about twice as expensive. It is my plan B if I can't get my head around RPi. 

Link to comment
Share on other sites

4 hours ago, RadekK said:

Raspberry Pi is quite handy for controlling astronomy hardware. I've been using it for a long time.

This however means switching to linux. If you're ready for this, take a look at KStars/Ekos, INDI and either install all the neccessary components RPi yourself or use ready to use RPi system images, namely Stellarmate or Astroberry Server.

I see some challenges though... First, you use custom solution for driving RA/DEC axis. Nothing that I know would support it out of a box. Second, using Raspberry Pi Camera Module is not supported with astro software I know. And the last but not least, make sure you're ready for a learning curve with linux and new software. It might be frustrating, however I believe it's worthwhile.

What won't be supported out of the box?  Having to control DEC axis? 

If astro software isn't supported by the RPi camera module,  can you suggest an alternative camera?  I thought RPi could only support the RPi camera module

Link to comment
Share on other sites

With INDI on the RPi you can use any camera supported by an INDI driver. Normally USB connected. Since you have DIY mount controller that becomes harder. If it is coded to use LX200 commands then it should be possible to get it to work.

You can certainly run PHD2 on the RPi and you also have several native camera driver options there too. 

Link to comment
Share on other sites

Quote

 

- do I need to write code for this, or is there existing programming available for what I want to do?

- is it possible to avoid the use of screens (in the field)? My preferred option would be to flick a switch to start and stop the guiding, with another switch for alignment mode (or something simple like this).

 - do I need to use any particular stepper motors/drivers for raspberry Pi? I'm using a bipolar stepper motor running quarter steps, with an A4988 stepper driver

 - is the RPi 3 Model B+ the unit I should buy?

 

1) Nope, you use existing software called INDI. No programming required.

2) You dont need a screen in the field. You leave the raspberry outside with your scope and connect it to your home network somehow (WiFi, or better, network cable). You generally install Kstars (with INDI) on your computer in the warmth of your house, and then use it to connect to over the network to INDI running on the raspberry pi. 

3) look online to see if there is an INDI driver for your focuser hardware (https://www.indilib.org/devices/focusers.html)

4) I use a raspberry pi 3B, not the 3B+. I use Ubuntu Mate as the OS. I think Ubuntu Mate doesnt work "out of box" on the 3B+, but I may be wrong. I think you can get it to work with some extra work, but read about it online first.

 

You will want to follow some kind of tutorial to set up the raspberry pi. It runs Linux based operating systems, which you may not be familiar with (takes a bit of learning!). Enjoy.

Link to comment
Share on other sites

3 hours ago, kman42 said:

What won't be supported out of the box?  Having to control DEC axis? 

If astro software isn't supported by the RPi camera module,  can you suggest an alternative camera?  I thought RPi could only support the RPi camera module

If you plan to use a raspberry pi for telescope control, you will be using INDI, which is the RPi/linux equivalent to ascom. INDIserver is a piece of software thet sits between the hardware drivers and the astronomy software client. On the indilib web site there's a list of all devices that are supported, ie for which hardware drivers exist. The list also contains cameras that are supported. ZWO, QHY, Atik and dslr cameras as well as most other astro cameras are supported out of the box. Btw, the original RPi camera is very limited in capability, and not really suited for AP. Have a look here

https://pixinsight.com/forum/index.php?topic=10003.0

If you build your own hardware you have two options in order to get communication between your solution and your client going. 1. You build your own hardware driver. 2. You build your hardware such that it is compatible with an existing driver. Eg. there are several diy autofocusers that are based on an arduino microcontroller and that use the moonlite communications protocol. These hardware solutions can then use the Moonlite autofocus driver that comes with INDI.

If you use your own ra and dec motors, you need software that can translate indi commands (track, slew, etc) to actual motor movements. Easiest is probably option 2. where you use an arduino to do this translation, because even if you write your own driver, you still need a micro controller based motor driver (from your other thread I can see that you already have an arduino nano for this). And existing drivers (eqmod, celestron, etc) already have a mature functionality.

  • Like 1
Link to comment
Share on other sites

3 hours ago, kman42 said:

What won't be supported out of the box?  Having to control DEC axis?

As already discussed - controlling stepper motors and integrating it with any star map (KStars, Cartes du Ciel etc.) requires compatible software/driver for slewing, tracking etc. Unless you plan to point to an object manually and only manage sidereal speed in RA. This can be easily achieved. However, it get really complicated when considering guiding of such a setup. As @wimvb already stated, I would go for building hardware which is compatible with existing software.

  • Like 1
Link to comment
Share on other sites

9 minutes ago, RadekK said:

As @wimvb already stated, I would go for building hardware which is compatible with existing software.

This is what I plan to do if/when I build my DIY mount for widefield imaging.

 

Link to comment
Share on other sites

Thanks for all the help. After further research I will shrink my project a little to achieve high accuracy at low cost. To this end I will discard DEC control as I have heard they are hard to get accurate tracking when motorised. Instead I will use drift alignment and only guide for sidereal movement. 

To clarify, I will not be doing this in my backyard. Typically I shoot at dark sky sites in Australia,  so will be in the field with my gear. For this reason I don't need autofocus or wireless communication. I was steering away from laptops because of the battery life limitation but I am swinging back around now after what you guys are suggesting. 

It sounds like my Arduino Nano will be sufficient if I am only controlling RA movement. So my setup will be:

1. Stepper motor and driver moves mount

2. Arduino Nano controls motor

3. RPi or computer gives commands to arduino

4. Guide Camera feeds to RPi/computer

Laptop sounds straightforward - my only question is how does my Arduino talk to my laptop? 

I am still interested in the RPi for portability. What would be involved in such a setup using a RPi? 

Link to comment
Share on other sites

An arduino like the Uno or Pro Micro has usb capability built in. If you start with one of the autofocuser projects that I already mentioned, you can just replace the focus commands (that drive a stepper motor) with the appropriate mount commands. Skywatcher have published their synscan command protocol in the synscan manual. The arduino in essence emulates a synscan hand controller. You just ignore all commands that target the dec motor driver. Or you can make the arduino emulate the motor control board so that you can drive it with the indi eqmod driver. It shouldn't be too much of a problem to make this work.

In stead of a laptop, you can use a raspberry pi which you control with vnc from a tablet, or a laptop inside your car/house/tent/etc. But you won't need a laptop near your mount.

Edited by wimvb
Link to comment
Share on other sites

8 hours ago, kman42 said:

Thanks for all the help. After further research I will shrink my project a little to achieve high accuracy at low cost. To this end I will discard DEC control as I have heard they are hard to get accurate tracking when motorised. Instead I will use drift alignment and only guide for sidereal movement. 

To clarify, I will not be doing this in my backyard. Typically I shoot at dark sky sites in Australia,  so will be in the field with my gear. For this reason I don't need autofocus or wireless communication. I was steering away from laptops because of the battery life limitation but I am swinging back around now after what you guys are suggesting. 

It sounds like my Arduino Nano will be sufficient if I am only controlling RA movement. So my setup will be:

1. Stepper motor and driver moves mount

2. Arduino Nano controls motor

3. RPi or computer gives commands to arduino

4. Guide Camera feeds to RPi/computer

Laptop sounds straightforward - my only question is how does my Arduino talk to my laptop? 

I am still interested in the RPi for portability. What would be involved in such a setup using a RPi? 

If you ask even such a basic questions, I would not jump into guiding system straight...
Try a simple autofocuser first.. There are several DIY autofocusers projects using arduino and stepper motors online.

Just keep in mind, if you will decide to go Arduino + Rpi and 100% DIY and not to use any of OpenSource pre-built software and drivers, -  you will need:

1) Learn coding Arduino  (to create Arduino code to control Motor)

2) Learn coding Linux (to Create Linux Soft and Drivers  to Control Arduino device)

Even simple focuser becomes, Not completely simple. 

If you have got coding knowledge/Experience, - possible.

Otherwise, - it will take ages to learn two different coding languages/systems, - and I doubt you will built something reliable

Edited by RolandKol
Link to comment
Share on other sites

I don't use the intermediate Arduino but a HAT on the RPi with A4988 stepper driver module plugged into that.   The A4988 is driven from GPIO lines of the RPi directly.  A HAT (Hardware Attached on Top) is a PCB with a connector that plugs onto the GPIO pins of the RPi with either a stripboard for your own circuitry which I use or other electronic components with a variety of functions.  The stripboard version brings out all available GPIO lines to convenient solder rings plus the +5v and +3.3v power lines and data Ground.

This photo shows the HAT board plugged onto the RPi with a modified mini stepper motor used for remote focussing.  The HAT also has a power MOSFET for controlling a dew heater and provides a convenient place to mount a buck converter to drop my 12v observatory power supply to 5.1v for the RPi.  Firmware in the RPi micro SD card includes INDI drivers including the Astroberry Focuser (modified slightly for controlling the A4988).

Electronics.JPG

Edited by Gina
  • Like 2
Link to comment
Share on other sites

  • 4 months later...
On ‎06‎/‎02‎/‎2019 at 12:57, RolandKol said:

RPi is a small linux based computer, -  you can also install adjusted Windows for it (it was Windows 10 IoT I think).

Not sure about RPi windows version... never tried it before.

I tried to use the Raspberry Pi 3 B+ for a SkyAlert system using Windows 10 IoT however it appears you cannot install any .exe files on it so I would stray away from it unless you know how to code the programs properly. I have zero coding experience 😛

Edited by stardude07
Link to comment
Share on other sites

Stick with Ubuntu Mate on the RPi and run INDI drivers and control system on it, then KStars/Ekos on your indoor computer and you have easy and free (except for the hardware) remote control of mount, EFW, focussing and imaging camera plus anything else you want to control such as a dew heater or roll-off-roof or dome.

Link to comment
Share on other sites

On 07/02/2019 at 10:54, Gina said:

I don't use the intermediate Arduino but a HAT on the RPi with A4988 stepper driver module plugged into that.   The A4988 is driven from GPIO lines of the RPi directly.  A HAT (Hardware Attached on Top) is a PCB with a connector that plugs onto the GPIO pins of the RPi with either a stripboard for your own circuitry which I use or other electronic components with a variety of functions.  The stripboard version brings out all available GPIO lines to convenient solder rings plus the +5v and +3.3v power lines and data Ground.

This photo shows the HAT board plugged onto the RPi with a modified mini stepper motor used for remote focussing.  The HAT also has a power MOSFET for controlling a dew heater and provides a convenient place to mount a buck converter to drop my 12v observatory power supply to 5.1v for the RPi.  Firmware in the RPi micro SD card includes INDI drivers including the Astroberry Focuser (modified slightly for controlling the A4988).

Electronics.JPG

That would make a more compact setup than RPi + Arduino with less cables to worry about, but would require coding in Python or similar, afaIk. With this solution there is a small risk that a bug in the motor code can cripple the whole setup. Using an Arduino and having a similar bug would most likely only result in unresponsive piece of hardware. There are advantages and disadvantages with either solution.

Link to comment
Share on other sites

On 14/06/2019 at 22:38, Gina said:

All the code is in the INDI driver and written in C++

But also has python API (converted using can't remember 🙂 ) and has straight forward scripting language DBUS API. Examples of which on the Indi site.

BUT IMO dont bother just use one of the existing drivers (e.g. Moonlite focuser ) and just make you RPI or Arduino talk the same protocol and connect using Serial/UDP or TCP even though its on the same RPI device - you can always then split things up easily and dont have to support your own coding.

Hell you can even use Node.js Node-red to access/control most, if not all, Indi devices via the Indiserver over TCP or UDP or Serial if you don't like the integrated Ekos/Kstars method. 

There are pro's and con's to using remote PC using Kstars/Ekos connected to Indiserver on a RPI and the alternative is just run it all on the RPI with local devices (Arduino or Distributed Indi set up) and just Remote Desktop. As always it depends on the kit and RPI know limitations (USB2/share Ethernet).

I tend to bend towards Wimvb design and comments about using a RPI and HAT VS Arduino but agree its neat.

Just my opinion - good luck which ever route you use.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. By using this site, you agree to our Terms of Use.