RS-232 with TeraTerm [FOLLOW-UP]

Hi guys:

I posted a few days ago about reading a mystery serial line and you were all very helpful. I downloaded the Tera Term program, but I'm still not getting it to work. It's probably something simple/stupid.

I know I'm getting a serial signal along pin 3 (with respect to ground pin 5) of the 9-pin D-sub cable because I can see it on a scope. In TeraTerm I have clicked on the "Serial" radio button and selected COM1. Then I have set up the serial parameters to what I believe is coming from the source, viz. 9600 baud, 8 data bits, one stop bit, no parity. And then I get a blank screen with flashing cursor in the upper left-hand corner.

I'm assuming (maybe unwisely) that a serial signal received along pin 3 of the jack should generate some sort of characters on this blank screen (if the parameters are set correctly, I know what characters I'm looking for). But I get nothing.

I know I'm getting a signal (on the scope), and I've tried both serial ports on the back of the computer with no luck.

If the serial parameters are in error, would I get nothing, or just incorrect jibberish? Do any of you have an idea what I could be doing wrong? Thanks for any help you can provide.

Don Mechanical Engineer Kansas City

Reply to
eromlignod
Loading thread data ...

Don,

1) On a standard 9 pin PC serial port, the signal you want the *PC* to *receive* should be on *pin 2* (not 3!). Pin 3 is the PC's transmitted data. 2) When you setup TeraTerm, did you tell it to use *no* flow control? (It's under Setup->Serial) 3) The next thing to try would be to make yourself a "loopback" connector that shorts pins 2 and 3 of a female DB-9 connector that you stick on the PC's serial port connector: Whatever your type in TeraTerm should then be echoed back, since you're shorting transmit and receive together.

Depending on how much they're in error, it could be either... although sooner or later you typically get at least *some* jibberish.

---Joel

Reply to
Joel Kolstad

It's been a while since I've played with serial ports, but there are handshaking lines that need to be taken into account. I think one was called DTR, Data Terminal Ready, and others like DSR and CTS, etc..

These lines were meant for handshaking, ie the polite preliminaries before talking if you will. If your terminal is set up for hardware handshaking, it might be waiting for those signals to be asserted before "listening". Check your terminal's setup.

You should see something strange if you are at the incorrect baud rate. Incoming data's start bit will start the UART's internal state-machine to start sampling bits at its baud rate, so it's anyone's guess what exactly it will see if you're sending it stuff at the wrong rate.

A useful gizmo I had a while ago was a bunch of LEDs in a plastic box with 9 pin connectors on both ends. The LEDs would tell me the status of each line on the port. Don't know how common these are these days.

Reply to
a7yvm109gf5d1

Late to this thread, so hopefully the below is not a repeat...

I'd start with your terminal and make sure it communicates. The easiest way to do this is just do a loopback on the connector. Just short pins 2 & 3 of your DB-9 (PC terminal) and type a few characters. If they are echoed back, at least you know that's working. (Unshort the pins.)

If not, fix this before doing anything else.

Usually DB-9 pins 2, 3 and 5 are the bare minimum required. However, some arrangements want to see the other signals before they'll allow data across the interface. It that is the case with yours, try the following, which usually does the trick:

DB-9 short pins 1, 6 & 4 together. Then short pins 7 & 8 together. Your connection will use 2, 3 and 5 as above. Pin 9 is left unconnected.

Note: If you look carefully inside the DB-9 connector shell, you will see the numbering. It may not follow the way you think it should. Go by the printed numbers. Tiny, hard to see, etc..

Anyway, this arrangment is pretty good at convincing the interface that it's OK to send data. If your baud rate is truly 9600, then chances are pretty good you won't overflow the receive buffer, but be aware this is a possibility.

To answer your question: If your parameters are incorrect, you may see jibberish, or you may see nothing. Either is a real possibility. It seems to me jibberish is more often encountered when the 7-bit or 8-bit word length is off. But really, this "information" is pretty useless.

Also remember, the pins are named from the DTE perspective. That means transmit on pin-2, receive on pin-3 on the terminal side, and exactly opposite on the DCE (modem) side. Make sure you don't have two devices of the same sex. If you do, either use a null modem, or flip the TD and RD pins (2 & 3) yourself.

-Michael

Reply to
mpm

  1. You say you see the line transitions on a scope. In that case it is trivial to work out what the *actual* data rate is. Assuming you can see a single bit position (and that's about guaranteed in random data), then take the bit time -> 1/x -> data rate.
  2. Turn off _all_ handshaking in Teraterm (under serial port settings). Hardware (or even software) handshaking can easily suppress the data (because the serial port won't pass things through without the handshake signals).
  3. Incorrect speed parameters might yield either gibberish or absolutely nothing.

Cheers

PeteS

Reply to
PeteS

Oh, s***! I'm an idiot, just like I thought. I forgot you needed a cable with the crossed RX and TX lines. I've been using a parallel cable. What's stupid is that I even pinned out the cable with a meter to make *sure* all the lines were parallel connected...Duh!

I'll get a real serial cable and try it again. Thanks for the help as usual.

Don Kansas City

Reply to
eromlignod

It works! It's a miracle!

Thanks again to all.

Don Kansas City

Reply to
eromlignod

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.