Go Back   IceInSpace > Equipment > Software and Computers
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Rate Thread
  #1  
Old 05-10-2010, 02:26 PM
bojan's Avatar
bojan
amateur

bojan is offline
 
Join Date: Jul 2006
Location: Mt Waverley, VIC
Posts: 7,097
Question LPT port and Delphi 4

I want to write an application which will control stepper motor (for focus) for my XP machine.. Simple slider on a screen and output to ULN2003 on LPT port... but I have a problem accessing the port..

Long time ago I did some applications for serial port (timer for camera) and this worked OK wit TcomPort pack.. but I never actually found LPT port package anywhere on the net.

Anyone could help me out here?

Thanks in advance!

Last edited by bojan; 05-10-2010 at 02:58 PM.
Reply With Quote
  #2  
Old 05-10-2010, 03:21 PM
Tandum's Avatar
Tandum (Robin)
Registered User

Tandum is offline
 
Join Date: Apr 2008
Location: Wynnum West, Brisbane.
Posts: 4,166
I've never done any LPT port stuff but a quick google points to inpout32.dll. Have look at this page for delphi examples and this page for the dll with source by the looks. It says it works in WinXp but I doubt it will work in anything newer. Looks like you have to set bits in the register for port.
Reply With Quote
  #3  
Old 05-10-2010, 05:53 PM
AndrewJ
Watch me post!

AndrewJ is offline
 
Join Date: Mar 2006
Location: Melbourne
Posts: 1,905
Gday Bojan

I use the freeware AsynchPro with D6,
http://sourceforge.net/projects/tpapro/
and it does everything you could ever want.
Lots of worked examples too.
I see its valid for D4 but i've never tried it with that.
Otherwise, you can use simple embedded assembler code to read/write as long as you use something like Userport to disable the Windows port security.

Andrew
Reply With Quote
  #4  
Old 05-10-2010, 06:43 PM
bojan's Avatar
bojan
amateur

bojan is offline
 
Join Date: Jul 2006
Location: Mt Waverley, VIC
Posts: 7,097
Many thank, guys.. Will try :-)
If successful, I will post the app to the forum.. it looks like there is nothing suitable on the web (at least to my knowledge).
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +10. The time is now 08:52 PM.

Powered by vBulletin Version 3.8.7 | Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Advertisement
Bintel
Advertisement