Parallel port interfacing with C#

Parallel port interfacing with C#

Post by Shahram Ah » Thu, 10 Jul 2003 17:51:43


I'm working on a project called controlling devices
over internet. The hardware intefacing part is to be
done through parallel port. The whole project have
been done using C# of .Net platform. My problem is
that I don't know what's the class that I can use to
communicate with parallel port and send a byte
corresponding to command I want to give out to device
connected to it. I don't want to use old system dll
files that might make my code unamanged and out of
.Net framework. I want to know the way I can have it
done in c#.

I'll be so thankful if you help me.
Thanks in advance,
Shahram.
 
 
 

Parallel port interfacing with C#

Post by Thomas Sch » Fri, 11 Jul 2003 06:30:54

.NET 1.0/1.1 has no support for legacy ports (COM/LPT)
You have to use PInvoke or Interop...


If the attached device follows printer hand-shaking protocols:
HOW TO: Send Raw Data to a Printer by Using Visual C# .NET :
http://www.yqcomputer.com/


If you want to control the port pins:
You have to install some kind of hardware drivers!
(Warning: will impact system security/reliability)

[NOTE: this is a restriction of the OS, not of .NET]


commercial, specific for printer ports, e.g.:
http://www.yqcomputer.com/
http://www.yqcomputer.com/
for .NET : generic IO
http://www.yqcomputer.com/

C++/Win32
http://www.yqcomputer.com/
http://www.yqcomputer.com/
http://www.yqcomputer.com/


For more information about ports, check this sites:
http://www.yqcomputer.com/
http://www.yqcomputer.com/


for Interop, please use newsgroup:
microsoft.public.dotnet.framework.interop



--
Thomas Scheidegger - MVP .NET - 'NETMaster'
http://www.yqcomputer.com/ ://dnetmaster.net/