Hi all,
Could someone please to make more clear next 2 questions:
I have PCI card with 2 UARTs( 8 serial interfaces - ComA, ComB,…,ComH).
1). How can I handle access to ComA,…,ComH in PCI driver (PLX chip)?
2). How I can get access to ComA,…,ComH from user level application?
Thanks,
Andrey
For Driver, you have to get the datasheet of UART and learn how to control UART first. Then you have to know the I/O address of each UART(assigned by BIOS) so you can control it in your driver.
For Application, please install SDK first. Please refer to http://msdn2.microsoft.com/en-us/library/ms810467.aspx for more information.
1). How can I handle access to ComA,…,ComH in PCI driver (PLX chip)? I would asume of course you have a driver for this PCI card. If you do not have a driver for this card you will need to write one. In writing a driver I would consider the serial drivers in the DDK either the KMDF / UMDF or the kernel sample. You will have to vary this driver to support the multiple UARTS. This will require info on which IRQs / IO ports are used with the card.
Now if I read the question as you wish to call these ports from within another driver you will have to get the Device Object and then send our IRPs to it. See: IoGetDeviceObjectPointer(), IoBuildDeviceIoControlRequest() for thing like setting line parameters, etc, and IoBuildSynchronousFsdRequest().
2). How I can get access to ComA,…,ComH from user level application. Use HyperTerminal and connect two your serial ports with a null modem cable. You can search the internet for sample win32 communication applications with source. You could use an old dos program that virtualizes - traps on the UART access and translates this to a com VVD application. Again connect the RS-232 ports with a null modem cable.
-W. M. Jones