×

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

Bi-monthly release with minor bug fixes and improvements

AZ Goto direct control of mount from PiZero

  • Posts: 9
  • Thank you received: 0
I am fully conversant with INDI on the Pi and have recently been using the Python wrapper to create some cool automation scripts for my EQ6. INDI Rocks!

I have a new project where I want a very simple PiZero controlling a SW AZ-Goto mount. The older silver/black one. I made a direct cable with FTDI chip but indi_eqmod_telescope complains about reflected commands (Tx/Rx short on MC001 motor controller?)

I have done a ton of reading online and lots of testing, including looking at the TX/Rx on my scope where I can see the MC001 motor control board responding to the EQMOD commands, but the EQMOD driver seems to be confused by seeing the reflected command comming back. Sent=:j1<0d> Recvd=:j1<0d>

Obviously the standard Synscan handset I have will talk to the mount fine, however I want to dispense with that and talk directly. Am I mad?? Is what I want to do possible?

Many thanks

Roo, UK
5 years 2 days ago #36998

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

  • Posts: 407
  • Thank you received: 74
No you are not mad :-)

I have used the PI 0 (wifi) in the following ways :-

1. Indi Synscan with the Hand set using the PI on the PC outlet - so real RS232 - works but Wifi can be a pain at times -not an Indi problem but RPI

2. No Handset Indi Synscan with RPI 0 (wifi) connected to mount via TTL (GND,RX,TX) using USB adapter and Indiserver running on RPI (Stretch) connected to 18.04 Ubuntu Kstars on Desktop(AMD) and/or RPI3b/B+ (Ubuntu 16.04). Both using Legacy and newer Indi Synscan driver. Worked mostly but had problems with PARK and some Slewing which I never had an answer for - i.e. Mount Cork Screwing instead of doing some intelligent slewing so not to tangle wires (Power etc)

3. RPI 0 (wifi) using Stretch and Ser2net but running Kstars and Indiserver on another device (tried on Windows/Ascom , RPI3b/B+ Kstars/Indiserver and Desktop/Laptop running Kstars/Indiserver. Here you just use the UDP connection in the Indi Synscan driver to connect to Ser2net (just add 1 line and alter 1 line in Ser2net). Biggest problem here is that UDP under Ser2net doesn't know when you have disconnected - it just uses a timeout(if I remember it right). Works with the same problems as in (2). Under Windows Ascom (or Synscan App/Sky Safari without Virtual Com) you need a virual com driver which converts to IP (most are free - even one posted on EQMOD site) plus you can just use Ser2net in its standard serial/IP mode(TCP).

P.S. I use it as a DSLR Wide field mount and so I have even had Indi_cannon DSLR driver running on the RPI 0 - but I wouldn't do streaming from a CCD IMO

Hope that helps - be interested in how you get on :-)
RPI3 Ubuntu 16.04 / AMD desktop Kstars under Ubuntu 16.04 Mounts :azeq6 ,SWAZGoTo

RPI3 Fedora testing out on AMD desktop Fedpra 28 - running kstars 2.9.4 , Indilib 1.7.4 ?????
Last edit: 5 years 1 day ago by Clive Stachon.
5 years 1 day ago #37034

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

  • Posts: 9
  • Thank you received: 0
Firstly - many thanks for replying. I was beginning to think I was the only one trying to do this.

It sounds like scenario 2 is the same as mine. I am using an FTDI USB to TTL convertor wired like you (GND, TX, RX) to the mount. I have soldered the connection directly to the small PCB in the mount (the one next to the RJ12) where you can CLEARLY see the PCB track shorting out the Tx & Rx wires together. That is whatt he driver complains about in the log window in KStars (same as you - running on a seperate PC... connected to the PiZero over WiFi).

Just to clarify which INDI driver you are using. I tried it with indi_eqmod_telescope.

Are you using a different driver?
Last edit: 5 years 1 day ago by Rupert Powell.
5 years 1 day ago #37037

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

  • Posts: 407
  • Thank you received: 74
Didn't do any internal soldering - I am no that good (in fact bad) at soldering so just created rj12 connector to Ch340G USB/TTL - works fine. I Noted the short but I guess the board just uses "Half Duplex".

The only driver I have found to work is the Synscan drivers (legacy and new version) - indi-synscan and indi-synscan-legacy.
EQMOD complains as one would expect you are using an AZ mount and the board on the mount doesn't support EQ - well mine doesn't (I have a Silver and a black version). AZGTI sort of works but insists on starting at Polaris where as I just wanted the "old fashioned" way of pointing north at 0,0.

The TTL is 5v and doesn't like 3.3v at all in my testing - luckily the CH340G has a switch for 5 or 3.3v.

The most consistent method I found was to run Synscan app pro under Wine on Ubuntu 18.04 (desktop/Laptop) - so long as you use TCP/UDP it works except for when you closes down. Then you point Synscan driver (indi-synscan) to the IP address and set the port to either 11880 or 11882 or 11885 - cant remember which.

The zero is quite capable of talking to a mount , a focuser and a DSLR with no speed problems (30mb file 6-10 secs) - remembering the speed is 72mb Wifi (at best). Even worked ok in a chain - so Zero chains to 3b+ and then run Kstars/Ekos on something powerful. As I say just dont run CCD/CMOS camera's.

Been a while so I think my info is correct- Search Indi Forum for different bits of info.

Oh one thing I have found with Linux and AZgoto mounts is that you have to start up the Linux box first then switch on the mount as doing it the other way the mount will not do initial hand shaking correctly.
RPI3 Ubuntu 16.04 / AMD desktop Kstars under Ubuntu 16.04 Mounts :azeq6 ,SWAZGoTo

RPI3 Fedora testing out on AMD desktop Fedpra 28 - running kstars 2.9.4 , Indilib 1.7.4 ?????
5 years 1 day ago #37040

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

  • Posts: 9
  • Thank you received: 0
I am creating a mount/scope set-up that simply finds the moon. The intention is that all there is int eh system is the Mount / scope / PiZero (GPS). The mount will be in a perminent location and therefore the pointing model should be ready for action. All the user does is turn on the system and the mount (via a Python script which I have already written using the emulator) will unpark and move to the moon's position (calculated using AstroPy). That's it.

So that means no WiFi...other than for configuration and editing of the Python script. No KStars...again other than for possible maintenance.

BUT. I still cannot make it work!

You say indi-synscan and synscan-legacy..... The only drivers I see in my 1.7.4 install are the following....in fact this is what I type in the PiZero terminal:

indiserver -vv indi_synscan_telescope

BUT this does not work.....it simply reports (in KStars) "Synscan Mount Not Responding"

I get a little further with the following:

indiserver -vv indi_eqmod_telescope

That produces the following:

2019-03-27T17:09:07: [ERROR] Error when disconnecting mount -> Invalid response to command :f1 - Reply :f1
2019-03-27T17:09:06: [WARNING] Warning: Invalid command -> Invalid response to command :j2 - Reply :j2
2019-03-27T17:09:05: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:09:04: [WARNING] Warning: Invalid command -> Invalid response to command :j2 - Reply :j2
2019-03-27T17:09:03: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:09:02: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:09:01: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:09:00: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:08:59: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:08:53: [WARNING] Warning: Invalid command -> Invalid response to command :j1 - Reply :j1
2019-03-27T17:08:47: [INFO] updateLocation: long = -1.083 lat = 53.95
2019-03-27T17:08:47: [INFO] Setting UTC Time to 2019-03-27T15:34:08, Offset 0
2019-03-27T17:08:47: [WARNING] Warning: Invalid command -> Invalid response to command :a1 - Reply :a1
2019-03-27T17:08:47: [INFO] EQMod Mount is online.
2019-03-27T17:08:47: [WARNING] Warning: Invalid command -> Invalid response to command :e1 - Reply :e1
2019-03-27T17:08:44: [INFO] updateLocation: long = -1.083 lat = 53.95
2019-03-27T17:08:44: [INFO] Setting UTC Time to 2019-03-27T15:34:08, Offset 0
2019-03-27T17:08:44: [ERROR] Error when disconnecting mount -> Invalid response to command :f1 - Reply :f1
2019-03-27T17:08:44: [ERROR] Error: Communication failed -> tty read failed, check connection: Timeout error
2019-03-27T17:08:39: [INFO] EQMod Mount is online.
2019-03-27T17:08:39: [WARNING] Warning: Invalid command -> Invalid response to command :e1 - Reply :e1

I do not see anything about synscan legacy!?
5 years 1 day ago #37042

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

I see it here:
/usr/bin/indi_synscanlegacy_telescope

This appears like a serial communication issue and I doublt the synscanlegacy would work. Can you use minicom to get any response from the mount?
5 years 1 day ago #37043

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

  • Posts: 407
  • Thank you received: 74
I will leave you with the expert - but i seem to remember a discussion about the multiple SW protocol that are different depending how you are connected - see attached Image.

The RPI 0 Wifi I use doesn't now have Indi mount control at all but as you can see from the 2nd image both the GPSD and Canon DSlr indi drivers do work using these command lines showing separate scripts lines on my testing Zero for a different project
RPI3 Ubuntu 16.04 / AMD desktop Kstars under Ubuntu 16.04 Mounts :azeq6 ,SWAZGoTo

RPI3 Fedora testing out on AMD desktop Fedpra 28 - running kstars 2.9.4 , Indilib 1.7.4 ?????
5 years 23 hours ago #37047
Attachments:

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

  • Posts: 9
  • Thank you received: 0
This morning I connected my Linux PC directly to the mount (using the FTDI USB/TTL adaptor) and from a terminal sent :j1<0D> and received back only the same each time. In fact any command is simply echoed by the mount - obviously because of the Tx/Rx being wired together... but nothing back from the mount.

Then something weird happened.....

I connected my logic analyser to the Rx line to see what was happening and hey-presto I started to see (in the terminal) valid responses from the mount.

From sending :j1<0d> I received :j1<0d> followed by =000080 , which I believe is the current Az position. Other commands also produced valid responses. As soon as I disconnected the LA it stopped responding.

I think there is a triggering problem on the front-end of the FTDI USB interface. I see you have an CH340G device.....I need to lay my hands on one of those too and see if that is maybe the secret! (I have a prolific one as well...but that is not working either).

Chip-chip-chip away...

Thanks for the support guys - I'm sure we will get there!
5 years 7 hours ago #37068

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

  • Posts: 298
  • Thank you received: 46
Hi,

If you get proper communication by connecting your logicanalyzer to the Rx line then I would guess that you need a pullup resistor on the Rx line.. ?
Take a look here : electronics.stackexchange.com/questions/...up-resistors-on-uart

Br
/Markku
5 years 5 hours ago #37070

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

  • Posts: 9
  • Thank you received: 0
I now have a 10k pullup resistor fitted to the Rx line and using Minicom on the Pi I can see valid responses from the mount :-) ....however,

Still no joy connecting using indi_eqmod_telescope (exactly the same) and indi_synscan_telescope. The latter spits out one Tx when the connect button in KStars is pressed. But it always says the following in the KStars window:

2019-03-28T15:38:12: [WARNING] Synscan Mount not responding
2019-03-28T15:38:12: [WARNING] Communication with /dev/ttyUSB0 @ 9600 failed. Starting Auto Search...
2019-03-28T15:38:12: [WARNING] Synscan Mount not responding

Using minicom on /dev/ttyUSB0 I get correct responses from the mount.

One last question. I do not have indi_synscanlegacy_telescope on my PiZero. How would I add that to the drivers?
5 years 2 hours ago #37078

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

If you don't have indi_synscanlegacy_telescope already then indi_synscan_telescope is the legacy one you're using right now! You can compile from GIT.

Look in the Handshake() functions in the EQMod and Synscan drivers to try to see why it's failing to respond.
5 years 2 hours ago #37080

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

  • Posts: 9
  • Thank you received: 0
SUCCESS!!!

While looking for indi_synscan_telescope I found this:

/usr/bin/indi_skywatcherAltAzMount

.... so I did the following:

indiserver -vv indi_skywatcherAltAzMount

.... and it conencted first time and all works a treat. I obviously haven't tried it under the stars yet, but it seems to be doing the right things!!

So in summary it does work with a FTDI 232R chip with a 10k resistor between 5v and Rx, AND using the indi_synscanAltAzMount driver.

Thanks guys! :-) :-) :-)

- now I can get on with my Python script for "Moon-Raker!"
5 years 2 hours ago #37082

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

Time to create page: 2.912 seconds