PDA

View Full Version here: : Mount controller


bojan
25-01-2016, 09:56 AM
Recently I decided to make better DIY controllers for my EQ6 and LXD75 mounts...
The requirements are as follows in order of priorities:

1) low cost and simple, no nonsese design.
2) must have handpad, for quick and fine positioning
3) guiding port (must be)
4) Connectivity to CdC or other PC planetarium software (nice to have but not mandatory)

I altready had my own hand-pad controller, based on 68HC705 processor, which I was using for the last couple of years for AP on my permanent mount. The tracking accuracy was excellent, the only drawback with this system was the lack of connectivity with CdC (this is basically just a dumb software-implenented timer, outputting a step pulse every 15ms for tracking and every 100us for positioning), and when I needed GoTo (on very rare occasions) I was using SoundStepper.

My LXD75 controller is "Duo", similar in functionality to my own controller (tracking, 1x, 8x, 32x slew on both axes), but because of large PE MT-1 motor with gearbox), I decided to replace the final gear transmission with timing belt 5:1 transmission.. and that meant different timing => new controller (or hacking firmware. Or different crystal.. definitelly not the low cost solution).

Arduino board seemed to be a good and universal platform for more clever controllers.. So I had a look at AstrEQ and ONstep solutions, based on arduino:
http://www.stellarjourney.com/index.php?r=site/equipment_onstep
http://www.astroeq.co.uk/tutorials.php?link=/doku/doku.php?id=buildown


As they are at the moment, neither of those approaches are ideal (to my taste).

ONstep requires Android smart phone and BT connectivity to initialise and start tracking with hand pad emulated by android app.There is no app for Windows...
When connected to CdC (via USB, using ASCOM driver) there is a limitation to sync functionality (after manual move of the telescope - the author told me fimware can't sync on anything further away than 30 degrees or so... I didn't ask why yet).
Guiding is possible via ST-4 port or via serial (LX200 protocol), I tested it and it worked fine with K3CCD.

AstroEQ works via ASCOM driver only (USB port), and it doesn't even start without it.
It has ST-4 port... and no handpad.
I asked the author about stand-alone.. and he told me he is working on the hand pad right now, the code will be available for testing in couple od days... So if this works out OK, AstroEQ will be the ideal solution for me.

I will place arduino Mega board in handpad box, equipped with push buttons and necessary connectors. The motor drivers (accepting STEP and DIR pulses) are already in the mount.
This solution is very flexible:
It will work as stand-alone, with or without handpad, with or without computer.

glend
25-01-2016, 10:42 AM
I will folllow this thread with interest. Thanks.

luka
25-01-2016, 11:27 AM
Hi Bojan

I recently got involved in adding Ethernet functionality to OnStep and also adapting OnStep code to run on Tiva Launchpads ($20, cheaper than Arduinos).

One of the followup changes to the Ethernet capability of Onstep was the addition of the web interface. This will let you use your web browser to initialise the mount without phone. This may be a preferred option, especially if you are already using a laptop next to your setup.

Also you can start tracking from CdC without the use of a phone.

Luka

bojan
25-01-2016, 11:54 AM
Yes, I know about this... but I can't Sync to the object on the other side of the sky (Howard told me this is one of the limitations).
To ovecome this limitation, I did GoTo to desired object with motors OFF (no power to mount). Then I would manually move the scope to that object, power ON the mount and continue working.

Ethernet functionality may be interesting, but in my case not for now.

I actually want a completely stand-alone operation (with physical handpad), for me this will be 99% of times.. with addition of guiding (ST-4 and/or Serial) for longer exposures, and then GoTo as the option for special occasions.
If AstroEQ does this (and Thomas is on the task already), then I will stick to AstroEQ.

Another good thing about ONstep is, it understands LX200 commands (via both of it's serial ports).
I used USB serial port and LX200 protocol for guiding.
By replacing the BT adapter with RS232-TTL adapter I could have normal wired COM port for guiding... and another one for GoTo if I need all this at he same time.

All in all, it is not easy to pronounce one solution as absolutely ideal..

kens
25-01-2016, 04:18 PM
Interesting project that I'll watch with interest.
If it's any help I built a controller for my Super Polaris so I could autoguide it. I used the Freeduino board as it is functionally equivalent to the Arduino Uno but has a crystal oscillator. All I had to do was add a couple of ULN2003 drivers and a 7809 regulator on some veroboard for it all to work. Input commands are serial text and the hardest part was writing an ASCOM driver for it.
Even wrote a PEC routine which didn't really work out - great in theory but not so effective in real life.
With more time I wanted to add manual controls. My preference was to try rotary encoders rather than buttons in order to emulate the manual slow motion controls.
Happy to share code etc.. if it helps

bojan
26-01-2016, 09:50 AM
Hi Ken,
Looks like Super Polaris is very similar to my LXD75 (or Bresser.. or Meade... ).
It is pretty good in terms of transportability.
But the PE was killing it.
I wanted to add ST-4 guiding port to DUO controller that came with the mount and sort this out, but when having a closer look at how the buttons are connected and what they do, I found out the controller has a bug in firmware or just h/w problem: pressing the RA forward button increases motor speed 2x (which is OK) but backwards button did nothing (and in this case the motor is supposed to stop) so this controller was totally useless for guiding as it was.
Unfortunately I couldn't find the schematic or firmware listing anywhere on the net..
Interestingly, manufacturer did some wire modifications on the back side of the board.

One forum member gave me a following link some time ago:
http://bbs.astron.ac.cn/forum.php?mod=viewthread&tid=49588&extra=&highlight=&page=10
Unfortunately there is no mention about DUO controller (board is marked as "KM JH DK-3").. or at least I think there isn't.

Google search for "KM JH DK-3" resulted in this link:
http://picasaweb.google.com/100000953785276585002/Projects?feat=directlink&gsessionid=LyHNZVL2q3X2Zt-x9AnMwA
There were no wire modifications shown on this board !!! (in other aspects mine seems to be identical)..
Because DUO controller has two separate processors for RA and DEC axes, and the modification done to my board was not consistent for both processors, I tried to match it.. and voila, now the Left button stops the RA motor, and the controller is now suitable for guiding (pending the addition of ST-4 port).

However, the problem with high PE would still be there without guiding, so I decided to try belt modification (on second picture attached) in hope it would reduce the PE by down to 1/5) and to try to use my own simple controller I designed some tome ago, because now I need 5x higher motor speed.
The immediate challenge now is to finalise the code for 68HC705KJ (attached).
It's supposed to have the (almost) same functionality as DUO controller (DUO controller has two separate processors for RA and DEC axes, my solution has only one - which means my controller doesn't accept both guide commands at the same time - telescope guides only in RA or DEC ) ... I still need to test it.

Or, I will go with one of available arduino solutions.

bojan
27-01-2016, 07:26 AM
Ken,
Would your code (or just tracking part of it) be suitable for Arduino Nano V3.0 board?
(It is not hard to replace ceramic resonator with crystal)

kens
27-01-2016, 01:45 PM
I would think so. Even the more complicated version (v7) uses only about 7k of code but also uses more variable memory to hold the PEC data. The half-stepping version uses almost all the variable memory.
I've attached both a simple (v2) and the latest version (v7). In the latest I commented out the half stepping as the motors didn't have enough torque in that mode. As a result the comments are a bit out of whack.

bojan
28-01-2016, 07:39 AM
Ken,
Thank you for sharing the code, the comments are full of information :-)
MT-1 motors (from LDX75) have 20ohms coils, and are used as bipolars.. however they are actually unipolar (6 wires, but only 2 half-coils are connected to DIN connector.. and there are enough unused pins for the rest od wires to be connected) so they can be driven with ULN2003 as well (DUO controller has 2 H-bridges for each motor).

When I was modifying my EQ6, I decided to have microstepping drivers inside the mount, so the circuitry that generates timing can be part of hanpad.
I even have 15ms timing generator placed inside DSUB15 connector housing, without anything else.. to be used for most basic mount operation (tracking only).
This way, I can use Bartels, SoundStepper.. whatever is suitable for that particular moment.

However, there is one problem with this particular implementation (or the way I did it) - the microstepping settings are in a form of jumpers insie the mount.... This is fine for Bartels, SoundStepper, ONstep (for now) but not OK for AstroEQ, which dynamically controls the microsteping mode of each motor, in order to achieve optimal torque and slew speed.

As for my LDX75, I designed a small board that holds only Pololu-style driver, and I was tempted to place them in each motor housing, to standardise the interface..
The similar driver boards are available on ebay:
http://www.ebay.com.au/itm/DC9-24V-Mini-Driver-Module-for-NEMA16-NEMA17-Stepper-Motor-3213-/301827384625?hash=item4646506531:g: qiYAAOxy0x1TWANj

kens
28-01-2016, 12:45 PM
Being a software guy and control freak I try to do everything in code and minimise the hardware and hard-wiring of functions. Plus in the particular case of the Super Polaris I'm reluctant to make any physical changes to such a classic mount.

The original reason I built the controller was that I thought I had fried my original one with reversed voltage. (The original connector had +ve on the outside!) As it was it is ok. But I took one look inside and decided it would be easier to build on an Arduino. It didn't take long to realise I could then design it for pulse guiding.
The only physical change I've mad was to reverse the connector inside the hand controller to the more usual +ve inside and add a 9V regulator so I can power it from a 12V supply. It possible I could run off 12V and get more torque but the original used a 9V battery pack and I didn't want to risk damaging anything without having access to the full specs for the motors.

I like the design of the PCB. It's not something I've ever attempted.

bojan
16-04-2016, 09:17 AM
Last week I decided to try another solution - to keep the original handpad, modified to accept the 5x higher clock frequency (17.897725MHz instead of 3.579545MHz).

My DUO handpad actually has two independent stepper motor drivers for each axis (each with its own processor including crystal clock oscillator).

The new crystals would be the simplest option for this mod, but there was nothing available on ebay. Local manufacturer (Hy-Q) accepts any "strange" orders, but charges $45 per unit and lead time is 4-5 weeks.

Since the declination axis doesn't really require accurate timing for stepper motor, I simply used 16MHz crystal and solve half of the problem.

However, RA axis needs at least 50ppm accuracy (for 10 minutes exposure without guiding for 400mm FL and 4um pixel size).
Being RF engineer, I tried to force the original crystal to work in overtone mode, but without success.. Then I tried with external transistor oscillator, 3rd overtone was not the problem but the circuit didn't operate at 5th overtone reliably, so I decided to try with NB3N511 (Clock multiplier IC.. it is actually PLL, and it can be programmed for 5x output frequency. AU$7.70 at RS).
This worked OK - the same circuit can be used for other additional (timing belt) reduction ratios.. 2, 2.5, 3, 3.333, 4, 5, 5.333, 6, 8)
The modification is relatively simple (it is reversible in principle), it involves cutting two tracks (to disconnect crystal circuit from processor) and adding couple of wires to bring the new 5x faster clock to the microcontroller clock input.

With this mod my LXD75 has now much lower PE while tracking.
Adding the ST-4 port is still pending.

However, because the whole controller actually operates from single power rail (including motor drivers on PCB) via provided 6V regulator in the handpad enclosure, 32x slewing speed is now too high and motors are stalled at that rate.

Because of the lousy design (the designer didn't think much about the circuit... yes it does work, but... ), the solution to this problem is a tricky one - I need to rewire additional 16 outputs from processors in total to be able to have separate (and higher) power supply for motor drivers.
So I left this exercise for some other time.

mswhin63
16-04-2016, 02:41 PM
Found these OCXO - not sure if is suitable but it is at the right frequency - https://world.taobao.com/item/44915586532.htm

bojan
16-04-2016, 03:23 PM
Malcolm,
I know about this add - I actually tried Alibaba for crystals, and there was this guy who offered me the very same OCXO (MOQ=5) as crystals for US$50 plus freight (another US$40) so I pulled out because I found this IC on RS, which is much more flexible approach IMO.

I am also waiting for programmer for AT89C2051, I will try to read back the processor and possibly disassemble the code.. which would be the best solution.

bojan
27-04-2016, 10:59 AM
Programmer (SP200SE, willard.com) arrived and (after sorting out some issues with windows drivers) it works OK, but this particular processor can't be read back because it is protected..
So, clock multiplier chip (AU$7.00) is the best (and only available) option to finalise timing belt modification with the original controller.

bojan
14-10-2019, 11:48 AM
Following up on my LXD75 modification..
Recently I was given Arduino MEGA board with Steve's shield (courtesy garymck).
This means the next step in life of my LXD75 will be latest OnStep firmware + 400s/rev steppers + timing belt reduction (most likely 60/16) using standard (and cheap) parts from ebay.
I already tested the system on bench, mount GoTo will be VERY fast, judging from time it took motors to stop on target on the other side of the sky (control was from CdC).
Steve's board has the same problem as almost all Pololu drivers based on DRV8825, available on the market: DECAY pin is left floating, which means chip works in mixed decay mode.. which is not adequate for motors I have (Longs 17HM0423, 2.3A). Tying this pin to 3V on chip regulator solved the problem (see attached pic), so motors are running smooth now in 32 /ustep mode (perhaps there is a bit more noise, but this issue actually depends on motor design and manufacturing quality - the noise people complain about is generated in windings if they are not wound tightly enough or not immersed in resin to prevent them from vibrating).
This also gave me an incentive to improve EQ6 as well (currently this mount works with OnStep w/o switching /u stepping). I only need to connect 6 additional wires from my driver board (inside mount) to connector (and controller). And, using STM32 with OnStep will add even more to GoTo speed performance (not that it is REALLY needed...)
I will post the progress here..

bojan
20-10-2019, 08:14 PM
And, this weekend I assembled another OnStep controller, this time it is with STM32.
Thread is here (https://onstep.groups.io/g/main/topic/stm32_103f_power_supply/34541379?p=,,,20,0,0,0::recentpostd ate%2Fsticky,,,20,2,0,34541379)...

ChrisV
21-10-2019, 06:18 PM
Very nice Bojan. I like the idea of an external controller and having drivers inside the mount with the steppers - at least that's what I think you did ?

bojan
21-10-2019, 08:04 PM
Yes, exactly that.
It evolved from need to control mount with couple of controllers, because at that time I was using Mel Bartel's system, running on PC (whole motherboard then, Fujitsu st1000 now), and I wanted something more portable... so I started to experiment, keeping the common parts (motors, Pololu drivers) and interface (STEP/DIR pulses) in the mount.
Currently I am using OnStep, but other systems are also OK.
Attached is the schematic of the motor driver, mounted in the EQ6.

Wavytone
22-10-2019, 01:14 PM
So.. on that schematic, what are the IC's J1 and J2 ?

I've been following with mild interest... I'd like to get rid of the synscan handset and DIY, though I have way too many other priorities.

bojan
22-10-2019, 01:19 PM
In mu case they are Pololu stepper drivers, 4988
https://www.pololu.com/product/2975
You can also use those based on DRV8825.

Both of them need to be modified to sort out "missing pulses" issue.

Wavytone
23-10-2019, 06:48 PM
Thanks Bojan I know the Polulu site - I’ve used their motors to make a motor drive for my focuser.

bojan
22-03-2020, 04:23 PM
Almost finished.
I was thinking of printing motor brackets, but decided to make them, using Al "L" profile - process is quicker and result is much stronger (not that is really important.. but since the motors are mounted such that they could collide, perhaps metal bracket is the way to go).
Electronics is also ready (OnStep), I just need to mount it in enclosure.


It will be ready for winter SV camp :-)

bojan
27-03-2020, 02:32 PM
Finished, ready for action.
ONstep controller (classic MEGA, with Steve's daughter board) is stand-alone (with keypad), or it can be controlled by mob app (via BT) or from laptop (via BT or USB), as convenient.

Sunfish
28-03-2020, 06:04 PM
Very cool Bojan . Looks the goods. My old onstep projects is not nearly so neat and a little like Frankensteins monster.

bojan
28-03-2020, 08:58 PM
Hi Ray,

Thanks, it is nice little mount, very portable.
I specifically bought it for 2014 solar eclipse, and it did very good job then.

bojan
29-03-2020, 09:17 AM
Packed....

ChrisV
29-03-2020, 10:11 AM
Very nice Bojan, but would look better wih an Anset sticker. I have to get something that for my onstepped eq5 - mines in a dodgy old toolbox.