Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Parellel port programming
Index -> Programming, C++ -> C++ Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
S_Grimm




PostPosted: Sat Oct 31, 2009 8:42 pm   Post subject: Parellel port programming

right this is going to seem weird but bear with me.....

So my father collects H/O scale slot cars (http://rcvehicles.about.com/od/glossary/g/hoscale.htm), pretty much little cars on tracks. anyway to get to the point here, we have a computerized system that keeps track of laps via a parallel port wiring harness. This harness has light sensative diodes (sorry i dont have a link, ill find one then at least you know what im dealing with here) on the end of the wires that appear to be naturally open (im bolding the important words here so that there is no major confusion later). Now what i need to do is write a program that uses a similar wiring harness for a drag race. I will post a couple of pictures when i get a chance, along with a circuit diagram of the harness.

Pretty much, i need to know how to include parallel ports into my program.

Ill have some more questions later, but right now i need to get the parallel ports included so i can run some tests on the harness to make sure it works right

edit: you know i better point out that i'm using XP and Vista as the base for this program. The machine that will run the program is XP but i have the harness connected to a vista machine. I also have Ubuntu installed in case i need to use it, but id preffer advice for the XP OS over the other two
Sponsor
Sponsor
Sponsor
sponsor
OneOffDriveByPoster




PostPosted: Sat Oct 31, 2009 8:51 pm   Post subject: Re: Parellel port programming

Standard C++ does not include parallel port access in the core language and the standard library. It may be appropriate to use DOS or Windows 9x here.
md




PostPosted: Sun Nov 01, 2009 8:17 am   Post subject: RE:Parellel port programming

Windows (all versions) and linux can also provide low-level access to the parallel port.

http://www.faqs.org/docs/Linux-mini/IO-Port-Programming.html for linux and C; and even though it's 9 years old, when I tried a similar technique about 5 years ago it worked... and the parallel port system isn't exactly an area of hot development.
DtY




PostPosted: Sun Nov 01, 2009 11:01 am   Post subject: Re: RE:Parellel port programming

md @ Sun Nov 01, 2009 8:17 am wrote:
Windows (all versions) and linux can also provide low-level access to the parallel port.

http://www.faqs.org/docs/Linux-mini/IO-Port-Programming.html for linux and C; and even though it's 9 years old, when I tried a similar technique about 5 years ago it worked... and the parallel port system isn't exactly an area of hot development.

Don't you need to run in Kernel space to get direct access to any hardware on Linux, or is that different with parallel?

I'm going to suggest something really, really bad.
Use Turing. It has built in support for parallel, I've never used it, but I understand it's really easy to use.

[edit] Looked at the page you linked to, so I guess you only need root access for it.
md




PostPosted: Mon Nov 02, 2009 9:21 pm   Post subject: RE:Parellel port programming

Root access is easy - and you could write a simple daemon to do the root-level work for you and just interact with that using standard POSIX calls.
Display posts from previous:   
   Index -> Programming, C++ -> C++ Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: