Thankyou larry.
I will try to do as you have suggested.
Chandu
----- Original Message -----
From: Harmon, Larry CT
To: NT Developers Interest List
Sent: Friday, October 05, 2001 6:52 PM
Subject: [ntdev] RE: Very Critical - Serial Ports
I can’t send you my driver, it is proprietary. But I can describe its development to you.
Start with the serial driver sample which comes with the DDK (downloadable from MS)
Cut out all the code which referenced hardware, I/O and IRQs
Modify IOCTL code to do nothing when requested to set COM Port I/O controls (RTS/CTS DTS/DSR…), except record the virtual state
Created linked list to queue write and IRPs in the device extension
Add code and variables in the device extension to create a second symbolic link for each device, you can use any name you like.
NOTE: Had I to do it over again I would create the second interface with a com port link also - then I would have a virtual loopback!
This second interface shares the device extension with the first interface, therefor when driver requests come in the driver must determine which interface the request is comming from
The logic for the second interface kind of hooks into where the serial driver ISR & DPC routines were used.
Writes to the com port are queued to a linked list - when the second interface is read, IRP’s are pulled off this list, completed and the data passed back. Reads to the com port are handled exactly the opposite.
Hope this helps
Larry
-----Original Message-----
From: ntdev [mailto:xxxxx@yahoo.com]
Sent: Thursday, October 04, 2001 12:18 AM
To: NT Developers Interest List
Subject: [ntdev] RE: Very Critical - Serial Ports
Hai Larry,
Can you send me the driver? I haven’t written any driver until now. I have just gone through some chapters of art bakers book and still I am at the beginning stage.
Please help me
Chandu
----- Original Message -----
From: Harmon, Larry CT
To: NT Developers Interest List
Sent: Wednesday, October 03, 2001 10:54 PM
Subject: [ntdev] RE: Very Critical - Serial Ports
I don’t know of any way to emulate a serial port from user mode. If you discover a method please let me know too!
To solve a similar problem, I wrote a serial port emulator for NT 4.0 last year. The driver provides two interfaces; one is standard serial port the other “backdoor” . Using this driver an application which which uses a serial port can open the serial interface and read / write normally, then another application can open the “backdoor”, read the data written to the serial interface and write data to be read from the serial interface.
The driver was fairly easy to write starting from the DDK serial driver sample.
Larry
-----Original Message-----
From: ntdev [mailto:xxxxx@yahoo.com]
Sent: Wednesday, October 03, 2001 10:46 AM
To: NT Developers Interest List
Subject: [ntdev] Very Critical - Serial Ports
I have two windows applications monitoring two devices on two serialports.
In the above two applications one is written by me and other is from some other vendor.
I want to use a single serialport for both the applications by having some compromise in my application
that whenever the other application wants to send some data I have to stop my communication and give
it the port.
At the device level I can take care and combine the packets from two devices and can send packets with
distinguition as to which packet has to go to which application which is decoded by my application.
Windows won’t allow two processes to use same serialport. Is there any method so that I can emulate
a serial port to the other application providing it as if it is writing to serialport, and handle all
the reads and write on to that with my application.
Any help will be very very usefull for me.
You are currently subscribed to ntdev as: xxxxx@diebold.com
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
You are currently subscribed to ntdev as: xxxxx@yahoo.com
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
You are currently subscribed to ntdev as: xxxxx@diebold.com
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
You are currently subscribed to ntdev as: xxxxx@yahoo.com
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com