HELP!!! Opening Serial Ports through VC 6.0 
Author Message
 HELP!!! Opening Serial Ports through VC 6.0

Hi All,

I'm having a real problem.

I have installed 2 x 16 serial port cards in my Windows NT 4.0 SP 6  pc.

I can use Hyperterminal to communicate down all the ports (COM3 - COM34) and
they work fine.

I have written a multithread app in VC V.6.0 which tries to open the first
16 ports, it returns a opens (COM3 - COM9) ok but won't return a file handle
for the rest.

I've checked that I'm passing the string correctly.

Anyone any ideas????

Regards,

Tony...



Sun, 24 Oct 2004 21:19:48 GMT  
 HELP!!! Opening Serial Ports through VC 6.0

Quote:
> Hi All,

> I'm having a real problem.

> I have installed 2 x 16 serial port cards in my Windows NT 4.0 SP 6  pc.

> I can use Hyperterminal to communicate down all the ports (COM3 - COM34)
and
> they work fine.

> I have written a multithread app in VC V.6.0 which tries to open the first
> 16 ports, it returns a opens (COM3 - COM9) ok but won't return a file
handle
> for the rest.

> I've checked that I'm passing the string correctly.

How do you try to open the ports? CreateFile? Then what names do you
specify? COMx only works for COM1 through COM9. COM10 and later are no
reserved device names. To open a device (instead of a file) you should
prefix the name with \\.\. So try \\.\COM10 etc. (\\.\COM1 et.al. should
also work)

HTH
    Heinz



Sun, 24 Oct 2004 21:28:49 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. I want open the COM1 Port (serial Port)

2. Serial port access in VC ++, Help!

3. Serial port to serial port copying software

4. Challenge: Virtual serial ports from real serial port

5. open serial port with C

6. opening serial ports above 9 using CreateFile

7. Serial Port Com10 can't be open

8. How to open serial port in Win2000?

9. Opening multiple serial ports

10. How can I check carrier status on an open serial port

11. URGENT-Opening a serial port

12. uart+serial port on NT 4.0 using VC++5.0

 

 
Powered by phpBB® Forum Software