Solved

control of the motors (input data)

Posted on 1998-04-03
2
198 Views
Last Modified: 2010-04-06
How can I make a box, or window... which will be control the motion of
 the motors which are connected for the parallel port, I mean, in that box or window
I will send the information to move the motors as the number of steps I want to move
them,or the number of degrees that the motors move.....
thanks
Juan
 


0
Comment
Question by:guerra
2 Comments
 
LVL 5

Accepted Solution

by:
inter earned 0 total points
Comment Utility
The simplest way to that is :

1 - Add two buttons to your form as Button1and Button2
2 - Button1.Caption := 'Step By', Button2.Caption := 'Step Degrees'
3 - On Button1Click
     StepBy := StrToInt(InputBox('Enter steps to move the motor','','2'));
4 - On Button2Click
     StepBy := StrToInt(InputBox('Enter degrees to move the motor','','30'));

More user friendly way is to use TTrackBar component in Win95(or Win32 tab if you use Delphi 3.0+):
1 - Just place 2 tractbar components to your form. One for steping by steps and other for steping by Degrees(or radians)
2 - OR place two SpinEdit controls to do the same

Regards,
Igor
0
 

Author Comment

by:guerra
Comment Utility
Hi
Thanx for the help, I think that the Ttrackbar is a  good solution, but I don't know to
put them in the form, the procedure which I need, etc... if one of them is for the
stepping by degrees, how can i do that, in the trackbar i define the number of degrees, e.g.  from 0 to 360 in intervals of five degrees and how can I send this information to the
motor which is connected in the parallel port for the pin D0 and D1..., the pin D0 is for the
direction of the motor (clockwise and ccw) and the D1 is for the clock of the motor..
If you have any advice to this, please help me
Many thanks
Guerra
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now