Serial Communication Problem: DB9 Port & Max232

Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
12 replies · 4K views
asad1111
Messages
51
Reaction score
0
iam making a project of serial communication between computer and controller the problem is:- db9 female port is connected to computer and male port is there to connect with max232 now in all circuits i have seen they have written that pin 2 is RTX or receiving pin whereas when i send signal from hyper terminal it appears on pin 2(i see it on oscilloscope) instead of pin3 which is transmission pin should it not have to appear on transmission pin??
reply soon
 
Engineering news on Phys.org
look for a RS232 tutorial
best i recall you roll the pins in the interconnecting cable because what is transmit to one guy is receive to the other.

we used 3 wires for 232 and telephone jacks.
 
This gets me every time, and I usually end up making some adapter DB9 connector.

It has to do with the old RS-232 stuff where one device functions as a data terminal and the other as data terminating equipment. On one, the 2 and 3 pins will be the opposite of the other, so whatever you're trying to talk to, you need to have the pins swapped from that.
 
so i need to give pin '2'(where signal is coming) to pin 8 or 13 of max 232 which is RS232 inputs instead of 11 or 10 of max 232
 
roll transmit and receive pins whatever they are. i think they're called TXD and RXD

look at pinouts for DTE and DCE

you really need to look up a tutorial on RS232

for there's other pins
clear to send, ready to send,

and lots of settings : baud rate , # of start & stop bits, parity,

that may or may not have to be dealt with. in my day those were set usually by DIP switches internal.

and i have long forgot the details.
 
Last edited:
now when i roll the pins the max232 is giving incerted output by using not gate iam getting correct signal any idea why max232 is giving inverted output
 
jim hardy said:
look for a RS232 tutorial
best i recall you roll the pins in the interconnecting cable because what is transmit to one guy is receive to the other.

we used 3 wires for 232 and telephone jacks.

An intelligent RS232 interface can tell who it's talking to and swap the I/O to suit itself. No more Null Modem Grimblers needed!
 
MATLABdude said:
Just remember it from the perspective of the computer: computer RECEIVES data from the peripheral, and computer TRANSMITS data to the peripheral. The direction arrows help also:
http://pinouts.ru/SerialPorts/Serial9_pinout.shtml

That's all very well but two computers can talk to each other quite happily via RS232. Which one is the 'peripheral' then?
RS232 was, afaik, a system for communicating with an external modem - where there was no confusion - but it has been used for other devices. Why not use an intelligent interface which will take care of Pins 1 and 2 quite well?
If you don't use an intelligent interface then there is no way of connecting a random choice of two out of three RS232 boards without needing to use a naff adapter and choose, each time, which is to to be the Tx and which the Rx. Not good Engineering and not necessary nowadays.
[Edit: I of course meant pins 2 and 3]
 
Last edited:
sophiecentaur said:
That's all very well but two computers can talk to each other quite happily via RS232. Which one is the 'peripheral' then?
RS232 was, afaik, a system for communicating with an external modem - where there was no confusion - but it has been used for other devices. Why not use an intelligent interface which will take care of Pins 1 and 2 quite well?
If you don't use an intelligent interface then there is no way of connecting a random choice of two out of three RS232 boards without needing to use a naff adapter and choose, each time, which is to to be the Tx and which the Rx. Not good Engineering and not necessary nowadays.
[Edit: I of course meant pins 2 and 3]

An intelligent interface would be cool and definitely designable. I have never seen an RS-232 transceiver with this ability though, and it would make sense for them to build that in.
 
sophiecentaur said:
You need to buy an Apple, then. That capability goes back years and years on the Mac. I thought EVERYONE had that facility by now!

They still make Apples with serial ports on them? :-p

(Conveniently, OS X ships with drivers for both FTDI- and Prolific-based USB to serial adapters--no smart interfaces that I'm aware of, however.)