If you're up for some P/Invoking, you can use overlapped I/O to do all the work yourself using the direct Win32 functions. It's not all that complex once you figure out how overlapped I/O works -- there are some good examples out there written in C, IIRC.
On 11/29/05, Eddie Lascu <[EMAIL PROTECTED]> wrote: > > I knew about the .NET 2.0 way, but I am not ready to there yet. I read > about > MSComm COM/OCX solution but I have hoped to find a pure class or library > that would do that. > Meanwhile, I learned about this solution: > > http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=9dde5 > cf3-4842-4d4b-baa7-73e09c4d5890 > > I will also search the SerialStream class. > > Thanks everybody for your suggestions. > > Cheers, > Eddie > > -----Original Message----- > From: Discussion of advanced .NET topics. > [mailto:[EMAIL PROTECTED] Behalf Of Eames, Andrew > Sent: Tuesday, November 29, 2005 4:30 PM > To: [email protected] > Subject: [ADVANCED-DOTNET] Read and Write data from/to a serial port > (such as COM1) > > > There is a SerialPort class in 2.0 which looks pretty good. > Unfortunately, I have been unable to use it since it requires the serial > device names to begin with "COM" (and my device name doesn't). I have > used a SerialStream class (by Marcus Lorentzon) which is floating around > somewhere in googlespace - this has worked pretty well for me > Andrew > > -----Original Message----- > From: Discussion of advanced .NET topics. > [mailto:[EMAIL PROTECTED] On Behalf Of Eddie Lascu > Sent: Tuesday, November 29, 2005 4:22 PM > To: [email protected] > Subject: [ADVANCED-DOTNET] Read and Write data from/to a serial port > (such as COM1) > > Has anyone here ever attempted to send/read data to/from a serial port? > If > so, what objects from the FCL have you used? A short code sample would > be > much appreciated. > > TIA, > Eddie > > =================================== > This list is hosted by DevelopMentor(r) http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > > =================================== > This list is hosted by DevelopMentor. http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > > =================================== > This list is hosted by DevelopMentor(r) http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > -- Eric Means [EMAIL PROTECTED] http://www.randomtree.org/eric/ =================================== This list is hosted by DevelopMentorĀ® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com
