View previous topic :: View next topic |
Author |
Message |
umka
Joined: 28 Aug 2007 Posts: 99 Location: New Zealand
|
|
|
Humberto
Joined: 08 Sep 2003 Posts: 1215 Location: Buenos Aires, La Reina del Plata
|
|
Posted: Sat Sep 08, 2007 6:56 pm |
|
|
Quote: |
is this a good way to connect a pic to the serial port of a pc or is there a better way?
|
It is not. Correct the wiring according to this:
Code: |
MAX232 PC Connector
T1OUT ----> PIN3 Tx
R1IN ----> PIN2 Rx
|
Humberto |
|
|
umka
Joined: 28 Aug 2007 Posts: 99 Location: New Zealand
|
|
Posted: Sat Sep 08, 2007 7:47 pm |
|
|
are you sure as i ahve looked at a few different schematics and they all have it com pin 2(rxd) to max pin 14 and com pin 3(txd) to max pin 13 |
|
|
Humberto
Joined: 08 Sep 2003 Posts: 1215 Location: Buenos Aires, La Reina del Plata
|
|
Posted: Sat Sep 08, 2007 9:08 pm |
|
|
Usually signals names are labeled from the standpoint of the DTE device. In this case
the PC is a DTE device. RS232 comunications are single point only. Any project using
RS232 that comunicate with a PC becomes in a generic DCE device, hence the
output is wired to a DB9 female connector as its own connector.
In the real world, nobody connect a wire directly from an RS232 transceiver
pins to a comm port connector of a PC, as shown in your drawing. Usually the are
standard cables that make that link.
Regarding the linked schematic, the DB9 connector should shown the RS232 project
connector, not the PC connector which is in the outside world.
To shown it properly, the DB9 female connector of your project should have PIN2
named Tx and PIN3 Rx.
I realize that this is confusing.
Humberto |
|
|
umka
Joined: 28 Aug 2007 Posts: 99 Location: New Zealand
|
|
Posted: Sat Sep 08, 2007 11:35 pm |
|
|
do you have a schematic of how it sohuld be? in the linked schematic if i change the T1out from MAX232 to connect to pin3 and R1in from MAX232 to connect to pin2 on a female serial plug it will work? is there a differant way to do it or is this the best way?
Quote: | In the real world, nobody connect a wire directly from an RS232 transceiver
pins to a comm port connector of a PC, as shown in your drawing. Usually the are standard cables that make that link. |
when you say that do you mean one normally uses an extension cable and are not actually puting the wires into the plug at the back of the computer? |
|
|
Humberto
Joined: 08 Sep 2003 Posts: 1215 Location: Buenos Aires, La Reina del Plata
|
|
Posted: Sun Sep 09, 2007 7:52 am |
|
|
Quote: |
do you have a schematic of how it sohuld be? in the linked schematic if i change the T1out
from MAX232 to connect to pin3 and R1in from MAX232 to connect to pin2 on a female serial
plug it will work
|
The electrical schematic you posted is right, BUT the plug should be female with
different names:
Code: |
T1OUT to PIN2 but rename the pin to Tx
R1IN to PIN3 but rename the pin to Rx
|
Quote: |
is there a differant way to do it or is this the best way?
|
It is not the best way, is the right way.
Quote: |
when you say that do you mean one normally uses an extension cable and are not
actually puting the wires into the plug at the back of the computer?
|
Yes, you are right. Once you connect the female plug in your project, you will need to
made an external cable with a connector in each end wired according to this:
Code: |
DB9 Male DB9 Female
PIN2 (Tx) to PIN2 (Rx)
PIN3 (Rx) to PIN3 (Tx)
PIN5 Gnd to PIN5 (Gnd)
|
Finally, connecting the male to your project and the female to the PC comm plug
your whole RS232 cabling will be according to the standard, and running.!!
Best regards,
Humberto |
|
|
|