Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Problem using 8 USB to RS232 adapters with PC and windows XP

Status
Not open for further replies.

asicguygmail

Newbie level 4
Joined
Jan 4, 2013
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,351
Hi,
I have to control 8 different devices from windows XP through RS232 interface.
I purchased 8 USB to RS232 adapter and connected to my system.

Hyper terminal works fine reading all adapters. The problem starts when I start reading/writing RS232 with C (or Matlab).
I use Microsoft visual C++ 2010 express which can't work with those many adapters. If it is one, it works fine but can't handle more than one. Matlab has the same issue.

can you suggest some other way of accessing RS232? Hyperterminal can not be used. Data must be processed before sending and there are many bytes to be transmitted. May be a different compiler?

Does any one know how hyper terminal accesses the RS232 interfaces? May be I can do the same thing. Does any one have the C code that hyper-terminal uses? Or describes how it does it?

Do you know what the addresses are for COM3 and above? (e.g. 3f8-3ff (for COM1), 3E8-3ff for COM2)

Help is much appreciated.

Alex
 

In the old days COM3 was at 2f8-2ff and COM4 was 2e8-2ef but those only apply to hardware UARTS. With USB the ports are virtualized so fixed addresses do not apply. I don't use MS compilers but I would suggest you look for a command that returns a list of virtual serial ports and use those.

Brian.
 

You must use Windows API (CreateFile and etc.) and forget about the addresses. In this case you can work with virtual serial ports for USB converters.
 

You must use Windows API (CreateFile and etc.) and forget about the addresses. In this case you can work with virtual serial ports for USB converters.

More about this can be found bellow:



+++
 

from device manger after connecting your usb serial converter , get the com number and work with it ,for simulation vspd virtual serial port driver .
 

As you have mentioned 8 USB to RS232 converter hence you have 8 virtual serial ports, Virtual serial ports doesn't have fixed address. Hence using OS syscalls they should be handled.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top