Jump to content

NLCbanner2024.jpg.2478be509670e60c2d6efd04834b8b47.jpg

Nexstar Raspberry Pi Controller


tekkydave

Recommended Posts

Looks like I should soon be in a position to do all my imaging runs in KStars/Ekos/INDI :)  I'll finish off the all sky cam first as that is nearly done.  Just need to mount the focus motor and add the pinion, attach the focus gear to the lens and fit all the dew heater resistors, mount the RPi and connect everything up.  Then fit the case together and mount it on the mast.

For the main imager, I have a second HAT to add components to including stepper driver, buck converter for the RPi power and some fuses.  This will then be mounted in a 3D printed box with suitable connectors added and attached to the imaging rig.  I'm not sure yet whether one RPi will do everything or whether I might need two.  If using two, I would have one for the mount control and the other for camera, filter wheel and focuser.

  • Like 1
Link to comment
Share on other sites

Do you have the right driver?  I have a feeling the ASI120 uses a different driver from later models.  I'll check in a minute...

Meanwhile...  I can't connect SSH via wlan - eth0 is fine.  Here's my setup - I have replaced my SSID and PW with s & p.  Could you look it over please and see if I've got anything wrong.  This is SSH into my RPi 3 via Ethernet cable from Putty.

login as: pi
pi@192.168.1.74's password:

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sat Oct 15 06:17:47 2016 from 192.168.1.64
pi@raspberrypi:~ $ ifconfig
eth0      Link encap:Ethernet  HWaddr b8:27:eb:13:58:28
          inet addr:192.168.1.74  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::6d51:2c4a:2ed7:8d86/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:37 errors:0 dropped:0 overruns:0 frame:0
          TX packets:56 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:4429 (4.3 KiB)  TX bytes:10666 (10.4 KiB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:196 errors:0 dropped:0 overruns:0 frame:0
          TX packets:196 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1
          RX bytes:16372 (15.9 KiB)  TX bytes:16372 (15.9 KiB)

wlan0     Link encap:Ethernet  HWaddr b8:27:eb:46:0d:7d
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:24 errors:0 dropped:24 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:8843 (8.6 KiB)  TX bytes:0 (0.0 B)

pi@raspberrypi:~ $ sudo cat /etc/wpa_supplicant/wpa_supplicant.conf
country=GB
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
    ssid="ssssssssssss"
    psk="ppppppppppp"
    proto=RSN
    key_mgmt=WPA-PSK
    pairwise=CCMP
    auth_alg=OPEN
}
pi@raspberrypi:~ $ sudo nano /etc/network/interfaces
  GNU nano 2.2.6                               File: /etc/network/interfaces

# interfaces(5) file used by ifup(8) and ifdown(8)

# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'

# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto wlan0

iface lo inet loopback

iface eth0 inet dhcp

iface default inet dhcp

allow-hotplug wlan0
iface wlan0 inet static
address 192.168.1.77 # Static IP you want
netmask 255.255.255.0
gateway 192.168.1.254   # IP of your router
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf


















^G Get Help             ^O WriteOut             ^R Read File            ^Y Prev Page            ^K Cut Text             ^C Cur Pos
^X Exit                 ^J Justify              ^W Where Is             ^V Next Page            ^U UnCut Text           ^T To Spell

 

  • Like 1
Link to comment
Share on other sites

I have the following:

 

pi@indiserver:~ $ ifconfig
eth0      Link encap:Ethernet  HWaddr b8:27:eb:2d:bd:b2  
          inet6 addr: fe80::1c7f:22a8:3643:ebe2/64 Scope:Link
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:26 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:14712 (14.3 KiB)  TX bytes:14712 (14.3 KiB)

wlan0     Link encap:Ethernet  HWaddr b8:27:eb:78:e8:e7  
          inet addr:192.168.1.95  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::fcb6:1f2b:7869:f2e4/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:623 errors:0 dropped:195 overruns:0 frame:0
          TX packets:359 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:75719 (73.9 KiB)  TX bytes:58798 (57.4 KiB)



pi@indiserver:~ $ sudo cat /etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=GB

network={
	ssid="ssssssss"
	psk="pppppppp"
	key_mgmt=WPA-PSK
}



pi@indiserver:~ $ sudo cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)

# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'

# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback

iface eth0 inet manual

allow-hotplug wlan0
iface wlan0 inet manual
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

allow-hotplug wlan1
iface wlan1 inet manual
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

I have used the advanced config in my Homehub to tie the RPi IP address to the same address every time. Not foolproof but I haven't tried setting up a static address yet.

  • Like 1
Link to comment
Share on other sites

WiFi fixed :)

I had "auto wlan0" instead of "auto lo" and a line you haven't got :-

iface default inet dhcp

Taking that line out and changing the auto has fixed it :)

New file content :-

pi@raspberrypi:~ $ sudo cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)

# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'

# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback
iface eth0 inet dhcp
allow-hotplug wlan0
iface wlan0 inet static
address 192.168.1.77 # Static IP you want
netmask 255.255.255.0
gateway 192.168.1.254   # IP of your router
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
pi@raspberrypi:~ $

 

Edited by Gina
Link to comment
Share on other sites

Strange - shut down RPi, unplugged and plugged back in (Mains PSU to mains socket) and tried to connect with Putty but no joy.  It connected to the WiFi once it was connected by Ethernet and then rebooted using "sudo reboot" from the Putty Ethernet connection but won't connect to WiFi from a cold boot.

Link to comment
Share on other sites

Tested the ASI120MC with my Win10 laptop and it works fine. I think these older cameras have issues working with Linux and virtual machines. It doesnt work at all with a Windows vm running on Linux and only works when it feels like it with a Linux PC. I have no chance with a RPi methinks. I'll leave that for now and stick to the laptop for capture.

Screenshot from Win10 Dell 630 laptop:

IMG_20161017_105622.jpeg

Link to comment
Share on other sites

I see...  I'm not doing planetary currently and the small camera is for all sky, but I do have an ASI185MC which I might try for planetary some time in the future.  I'm currently working on the ASC and also building the HAT circuitry for my main imaging using the ASI1600MM-Cool. 

I'm hoping I might have something working for tomorrow night when there are some clear skies forecast.  I'm looking forward to seeing if the auto-focussing works :)  I shall not be connecting the MS 1,2,3 driver lines - leaving it at full stepping.  The auto-focus simulation doesn't work - maybe the real thing will :D  I'm at least 99% convinced that the auto-focussing doesn't use anything but full stepping as there's no sign of any activity on the M0 or M1 driver lines when Ekos thinks it's auto-focussing..

  • Like 1
Link to comment
Share on other sites

A couple of items I was expecting in the post today haven't arrived so this leaves me lacking bits to finish off both HATs for tonight.  However, I might be able to "mix and match" and get something sorted out this afternoon.  I have only the one step-down buck converter ATM which is currently on the ASC HAT.  I think I would really like to get the main observatory imaging rig working with the RPi system and I could either use the ASC HAT for that or move the buck converter across to the main rig HAT.

For the ASC I could use the PSU I've been using for the Arduino version viz. an ex PC ATX unit with a 3 core cable up to the ASC and use the ATX 5v supply instead of the buck converter.

Link to comment
Share on other sites

I'm not using guiding with this rig - it isn't needed but if I were I too would use the powered USB hub in the camera for the guide camera and run the mount from the RPi

  • Like 1
Link to comment
Share on other sites

Good to know my thinking is in line with yours.

When using EQMOD, my mount is very tempramental if I try to attach it through a different USB [like it refuses to find the mount at all], so I was thinking I would stick to specific USB ports for everything. If linux programs are not so "sulky", all to the good.

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.