Solved

Comm. with parallel

Posted on 1997-12-10
3
165 Views
Last Modified: 2010-04-04
Hi everybody

I have a big problem, I have to send some commands through different pins on the paralleport to control a external device in a College project, I don't have a clue on how to do that. I only need to send commands, not receive any, if anybody know how to do that I would be very happy :-). I have said the question is easy... for you, I have tried for a long time, so please help.
0
Comment
Question by:koger
  • 2
3 Comments
 
LVL 8

Accepted Solution

by:
ZifNab earned 50 total points
ID: 1353291
This is what I gave as an answer a while ago :

check out if it helps you.

 I can give you already this code. That's the easiest way. It's the way to print by bypassing windows. Don't think it's different to send your codes to your hardware.

                   var
                    f : TextFile;
                   begin
                    AssignFile( f, 'LPT1' );
                    Rewrite( f );
                     //
                     // do your printing here...
                     //
                    WriteLn( f, {codes});
                    CloseFile( f );
                   end;

(Following: I'm not sure if you need it)
If you plan on sending control codes to the printer, call this function immediat

 procedure SetBinaryMode (var F: Text); assembler;
                      asm
                      mov ax,$4400
                      les di,F
                      mov bx,word ptr es:[di]
                      int $21
                      or dl,$20
                      xor dh,dh
                      mov ax,$4401
                      int $21
                      end;

Look on the net for this file! --
                                 |

The Delphi Hardware Programmers's Archive
All of the files in this archive were collected from FTP sites to illustrate how to interface Delphi with IBM PC hardware. They are all public domain and should be used with care. I disclaim                    everything, this file is provided as a service to all who are interested.

GOOD LUCK! Alan Young
ajtech@apc.net

DELFHDWR.DOC Contains a MS Word document explaining how to interface Delphi with hardware. Contains references to the other files below.

VBAJGAME.ZIP Shows how to interface a Delphi DLL with Visual Basic. Accesses joystick port

->>>>>>>>>>>>>>>>>>>>>>>>>

LPCTRL.ZIP Shows how to program parallel LPT port in Delphi

->>>>>>>>>>>>>>>>>>>>>>>>>> Isn't this what you need?

HWPORT95.ZIP A PORT I/O Driver for Win 95. Use with Delphi as per document's instructions

loaddrv.ZIP CONTAINS LOADDRV program for WinNT. This is for loading the giveio.sys driver

DIRECTIO.ZIP Contains GIVEIO.SYS driver for WINNT.



                   Have fun,
                   c.u. ZifNab;
0
 

Author Comment

by:koger
ID: 1353292
Where did you said that I could find the files?
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1353293
Well, after my computer melt-down :-(. Everything was lost. Including these files, but!! I found them again :

http://Sunsite.icm.edu.pl/delphi/ftp/d10free/delfhdwr.zip

Don't let d10free let you think that it's only for D1. This file contains documents about delphi and hardware for ALL delphi versions

Have fun,
c.u. Zif;
0

Featured Post

Are your AD admin tools letting you down?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Delphi Dbf export problem to a Visual Foxpro application 6 189
Delphi inherited method 6 68
how to resize animated Gif image in delphi ? 1 31
DBGrid or StringGrid ? 6 88
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

770 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