Connecting to the serial port of a real motherboard. Both ends are male...

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
User avatar
pearmypie
Posts: 21
Joined: Sat Mar 01, 2025 8:06 pm
GitHub: https://github.com/ionutcatana

Connecting to the serial port of a real motherboard. Both ends are male...

Post by pearmypie »

My motherboard has an internal serial port (COM1) and an bracket adaptor to RS232 (male). I carelessly bought an USB to RS232 adapter, which turned out to be a male connector as well.

USB to female RS232 are ridiculously expensive (the only one I'm able to buy online in my area is about $90...), so I impulse-bought a female-female adapter.

Currently, serial port output works OK when using qemu, I aim to use /dev/ttyUSB0 to see if it works on real hardware. Will this janky setup work?
MichaelPetch
Member
Member
Posts: 857
Joined: Fri Aug 26, 2016 1:41 pm
Libera.chat IRC: mpetch

Re: Connecting to the serial port of a real motherboard. Both ends are male...

Post by MichaelPetch »

This setup should work with one major caveat. Most DCE (data carrier equipment) like modems etc have female RS-232 connectors on them. Most DTE equipment (ie computer) have male connectors on them. The fact you you need to terminate on a 9pin female connector in your setup makes me wonder if you intend to hook up to another computer? I ask because if you are hooking up directly to another computer (or other DTE device) you may need to use a null modem adapter or a crossover cable like https://www.amazon.ca/female-slimline-t ... HWVSJ?th=1

One other observation. I don't know if you need low latency data communications but I have noticed over the years that most of these USB RS-232 adaptors may introduce a bit of lag upon receiving data as data is buffered internally before being sent via a USB packet to the PC. Under normal conditions this behaviour can usually be modified via USB serial device driver.
nullplan
Member
Member
Posts: 2034
Joined: Wed Aug 30, 2017 8:24 am

Re: Connecting to the serial port of a real motherboard. Both ends are male...

Post by nullplan »

Yes, just use a crossover cable (also called nullmodem cable). I use them at work all the time. They swap certain pins around (Tx and Rx, RTS and CTS, and there was a third pair I forget), allowing both sides to think they are the DTE.
Carpe diem!
User avatar
pearmypie
Posts: 21
Joined: Sat Mar 01, 2025 8:06 pm
GitHub: https://github.com/ionutcatana

Re: Connecting to the serial port of a real motherboard. Both ends are male...

Post by pearmypie »

All my stuff finally arrived, I hope I don't fry my PC.
It's My PC -> USB -> RS232 male -> Gender changer -> Null Modem -> Target PC.
abomination-cable.jpeg
User avatar
pearmypie
Posts: 21
Joined: Sat Mar 01, 2025 8:06 pm
GitHub: https://github.com/ionutcatana

Re: Connecting to the serial port of a real motherboard. Both ends are male...

Post by pearmypie »

nullplan wrote: Sun Nov 23, 2025 12:54 am Yes, just use a crossover cable (also called nullmodem cable). I use them at work all the time. They swap certain pins around (Tx and Rx, RTS and CTS, and there was a third pair I forget), allowing both sides to think they are the DTE.
Thanks for the advice, my janky setup now works. However, it seems that my serial port setup works on qemu but not on real hardware
Post Reply