Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Making a RS232 hub.

Status
Not open for further replies.

madsovenielsen

New Member
Hello

I want to make a RS232 hub, i have some old hardware wich i communicate with over serial. So i am getting pretty tired of switching the cables.

Ideally i want 4 RS232 ports and one for the "console" so a total of 5 ports.

A simple google search diden't bring up anything useful.

If someone couldt point me in the right direction. preferrably a schematic.

Any help is greatly appriciated.

Kind regards Mads Nielsen
 
Five sockets and a five way multipole switch - you can't make a 'hub' - RS232 doesn't work in that way.

Such switches used to be commonplace, but are probably getting a bit rare now with the demise of RS232?.

It's still got a couple of four way ones knocking about somewhere, and parallel port ones.
 
Its easy to make with a switch, bu thats not what i want. if its super complex to make a switch, i don't think i am up for it now.

If you wouldt be interested in selling one of your RS232 switches, mabye we could make a deal.

Kind regards Mads Nielsen
 
Well, you could make a hub with RS-232, unless there is something I'm missing. But first, are you sure you want a hub ( all computers hear all messages, if they are intended for that computer or not ) or do you really want a switch ( 1 communication path between the sender and receiver ) A hub will be simple, a switch is possible, but you would have to create some sort of switching protocol. Maybe there is already something you can use for a protocol, but i wouldn't be aware of it. I'll poke around a little later and see if I can come up with something.

Otherwise, you might think about another simple serial method, RS422, RS485, CAN, SPI or I2C. One of those might already have a portocol to do what you want.
 
Last edited:
Thanks that wouldt be great.

Its a switch i want. But i have no idea how to designate the signal to a particular port on the switch, but i guess thats what the protocol is used for.

This is going to involve some microcontroller programming right ?

Kind regards Mads Nielsen
 
Last edited:
Its a switch i want. But i have no idea how to designate the signal to a particular port on the switch, but i guess thats what the protocol is used for.

This is going to involve some microcontroller programming right ?

You betcha!
 
All you need to do is come up with some addressing scheme. Use the I/O ports of a uC to route the serial data to the desired port. If you're unfamiliar with programming, you won't be by the time you finish :)
 
All you need to do is come up with some addressing scheme. Use the I/O ports of a uC to route the serial data to the desired port. If you're unfamiliar with programming, you won't be by the time you finish :)

Okay. What is a uC ?

I know how to program in C, so i am not a total newbie to programming.

Can you give me a schematic ?

Kind regards Mads Nielsen
 
Okay. What is a uC ?

I know how to program in C, so i am not a total newbie to programming.

Can you give me a schematic ?

Kind regards Mads Nielsen

hi,
How are the 5 ports connectors wired.?
Are all the 9 pins used by each port or are some wired as Null modem connectors.??
 
hi,
How are the 5 ports connectors wired.?
Are all the 9 pins used by each port or are some wired as Null modem connectors.??

I dont know. what will you recommend ? :)

The RS232 switch will be connected to the serial ports of 4 computers, the 5th port is for the console.

Kind regards Mads Nielsen
 
The RS232 switch will be connected to the serial ports of 4 computers, the 5th port is for the console.

I think we need to know what sort of "computers" ? I suspect these are not the average "PC".
And, what is "the console".

A bit more idea about how you want to use this switch/hub and how you intend to select the routing from console to computer would be useful.

JimB
 
Anyway here is another: **broken link removed**

Use it as a basis.

For a simple RS232 switch all you really need is RS232 level converters and a multiplexor or cross point switch depending on how complicated you want to be.

Many years ago, there were mechanical switches on the market.
 
I think we need to know what sort of "computers" ? I suspect these are not the average "PC".
And, what is "the console".

A bit more idea about how you want to use this switch/hub and how you intend to select the routing from console to computer would be useful.

JimB

It is actually just simple plain PC's running Linux, they are used in a server context though.

The "console" is just where i will connect the computer used to control the other PC's connected to the switch.

I have no idea about the routing.

Kind regards Mads Nielsen
 
I have an A/B/C/D DB-25 switch box you can have. For a while they were being thrown out right and left. I used many for nice project boxes.

Ken
 

Attachments

  • ABCD DB25 Swt1.JPG
    ABCD DB25 Swt1.JPG
    139.9 KB · Views: 299
  • ABCD DB25 Swt.JPG
    ABCD DB25 Swt.JPG
    143.6 KB · Views: 309
It is actually just simple plain PC's running Linux, they are used in a server context though.

The "console" is just where i will connect the computer used to control the other PC's connected to the switch.

I have no idea about the routing.

Kind regards Mads Nielsen
If the four computers are just PCs, why are you controlling them via an RS232 port?
Would you not be better using a KVM switch to connect a VDU and keyboard to each computer as required?

JimB
 
Last edited:
If the four computers are just PCs, why are you controlling them via an RS232 port?
Would you not be better using a KVM switch to connect a VDU and keyboard to each computer as required?

JimB

The setup i need is a laptop connected to the RS232 switch which is again connected to the computers on the network. This allows me to control the computers connected to the switch over the internet without connecting them directly to the network.

If a KVM switch was a option i would just go buy one. :)

Kind regards Mads Nielsen
 
Last edited:
I lost everything I typed.

Your system is well defined. Ports, baud rate etc. You need to know what signals you need to support: DTR, DSR, CTS, RTS, TxD, Rxd, SG and/or RI (Ring Indicator)

The MAX232 is a well know chip for interfacing RS232 to TTL levels. Start there.

You might be able to directly tri-state the I/O pins or add your own tri-state buffer or use data selectors/multiplexor chips to select which port.

3 bits will do seven ports, 4 bits can select them one at a time.

Now, the question is "How do you envision how your going to select which computer is connected."?
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top