View Full Version here: : Focus control software, freeware
bojan
11-10-2010, 06:46 PM
It seems nothing suitable (functionality, freeware) exists on the web :sadeyes:..
So I decided to write my own :eyepop:.
Attached is the GUI example of what it should look like (currently it does nothing useful.. apart from keeping up appearances ;)).
It will control the stepper motor (step-direction, or 4-phase unipolar),
The position of focuser will be saved into a file... and that's about it.
When finished, I will post it here. Hopefully it will work on XP machines.
Any comments?
EDIT: sample program removed and replaced with working version later in the thread
Karls48
15-10-2010, 01:38 PM
Hi Bojan. It would be good to have a computer focus control.It looks good. Few questions. How are you going to control stepper motor – RS232 or USB? I think that your control slider should be in the middle position. +50 – 0 -50. This way you will not need extra button to reverse motor direction. Also – what I found out with almost all stepper controllers. They do not provide option to switch the motor off. Holding current on most of the small steppers is in vicinity of 2A and that flattens the battery pretty quickly. Not talking about the motor heating up considerably.
bojan
18-10-2010, 06:46 AM
Hi Karl,
thank you for your comments.
Well, my thoughts were in line with yours basically, however, I don't know how to program USB in Delphi (yet), so I intend to use LPT and RS232 (by toggling data / control lines).
Also I changed GUI somewhat, have a look at working version lower in the hread. Now it also creates a file and stores current position in it by clicking a button.
Button for reverse and ON/OFF function are a good ideas (I was thinking about rotating the motor connector by 180° for reversing - if wires are allocated properly, it is the easiest way, I am using this method on all my designs with steppers. However reversing on software side is better idea), I will certainly think about the way how to implement them.
Cloudyagain
18-10-2010, 08:36 PM
Not sure what you are using to drive your stepper motor but have you seen these? http://www.oceancontrols.com.au/SMC-020.html
Basically needs an input for direction and another (pulse) to step the motor. Accommodates various stepper motors and you can also change the micro steps, sleep etc. I have an older one with less versatility but I haven't used it as I can't program. Always thought that it would be easy for someone in the know as you really only need 2 inputs. Cheap too but I notice they are currently out of stock.
Neale.
bojan
22-10-2010, 07:26 PM
Finally, here it is.
Zip file contains executable, configuration file, source and INPOUT32.dll.
All of those should be unzipped into subdirectory of your choice.
LPT1 connector wiring is as follows:
First 4 bits are used for strobe/direction stepper drivers (with additional signal for motor ON/OFF, as per suggestions)
The other 4 bits are for conventional drivers (individual transistor for each coil).
Pin No
2 - direction
3 - strobe
4 - motor ON
6 - Motor coil A
7 - Motor coil B
8 - Motor coil C
9 - Motor coil D
Step-Dir (first 4 bits) are not tested yet, because I don't have appropriate hardware ready yet. However, I don't expect problems..
4-phase stepper driving works OK on my XP machine.
When inactive (bar not moving), motor is idle (not powered).
However, I certainly recommend disconnecting power supply or DB25 connector from computer, in case utility is not used, as the LPT port output could be anything initially.. and as a result, motor could be overloaded.
Direction of motor can be changed by rewiring.. I didn't bother to implement the direction change in software at the moment (something must be left for tomorrow, n'est-ce pas? ;))
All comments are welcome (including suggestions for improvement and/or modification for other applications.. I will try to address them as soon as possible).
vBulletin® v3.8.7, Copyright ©2000-2025, vBulletin Solutions, Inc.