Several slaves, each with it's own Modbus master

Here's the topology:
There are several devices that may have different baudrates, parity,...
The slaves are connected to the "multi-master" computer through USB (hubs); each device gets it's own Com port. On each serial port a Modbus Master is created, basically each device gets it's own master. So each master communicates via a single serial port with only one device; but Masters run in parallel in respect to each other.
Everything seems to work ok for 1,2 maybe 3 connected devices; afterwards it all gets faulted; leaving the ports in odd states. Also, sometime reads are hanging forever.


1. Does anyone took this approach? Any recommendations?
2. Should I suspect the serial ports implementation; the modbus implementation or both?
In my world, Modbus over USB is the exception, not the rule, so the devil, like always, will be in the details. Answer to your question number 1, I've never run into anyone using Modbus over USB.

1. I have no idea how you've implemented 'On each serial port a Modbus Master is created, basically each device gets it's own master."

Can you explain how you accomplish that and on what type of host?

2. I took a look at a USB-to-serial box, the SeaLINK® 2167 16-port USB to serial adapter, which "offers an easy way to connect multiple RS-232 or RS-485 devices via a single USB port. <snip> After installing the software, each serial port appears as a standard COM port to the host system enabling compatibility with legacy software."
link to Sealevel USB-to-serial box

Are you using a converter box like that?

Going back to item 1, presumably the host is running multiple Modbus Masters, each on its own virtual COM port talking through a single USB port to a hub with multiple serial ports?
Ok, lets get into details a little bit

The devices are CP210x capable and are connected to the host via USB. There's a CP210x USB to UART bridge driver that associates each device with a distinct virtual COM port. Using USB hubs the no. of devices that can be attached can be (allegedly) any number. So on the host computer there's one USB connected via cascaded USB hubs to many devices; and the devices look as they're connected on different COM ports.

I don't know the internals, but it each COM virtual port seems to have a channel to the device (wonder how that is achieved).
That gives me the possibility to
1. Talk to each device on its specific baudrate, parity,...
2. To create a master modbus (RTU) for each port.

Since they are separate channels, i thought that each master can talk to it's device in parallel with the others. But it looks that something is happening when the number increases, and the communication begin to crash.

Does it make more sense?