Sci.Electronics.Basics

on Electronics-Related.com

  Home  |  Books  |  Sci.Electronics.Design  |  Sci.Electronics.Basics  |  Resources  |  Contact  | 
Sign in
username:

password:

Remember Me

Not a member?
Search Sci.Electronics.Basics

Search Tips

Sci.Electronics.Basics -> how to do it? RS232

There are 23 messages in this thread.
You are currently looking at messages 1 to 20.






Author: RsK
Date: 10:26 18-11-06


Please anybody can give me a brief idea that using oscilloscope how i
can capture the waveform on a serial link, tranmitting the ASCII letter
'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?

I have connected oscilloscope with serial interface then? then selected
the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
wt to do?

waiting for ur reply?

regards


Author: John Popelish
Date: 10:46 18-11-06

RsK wrote:
> Please anybody can give me a brief idea that using oscilloscope how i
> can capture the waveform on a serial link, tranmitting the ASCII letter
> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>
> I have connected oscilloscope with serial interface then? then selected
> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
> wt to do?
>
> waiting for ur reply?

You need a terminal emulator program to capture the
character stream into a file (that you name). Depending on
what file format you set the scope to use to format the
image, you use an image viewer to look at the resulting
file. The details are dependent on the scope model and the
terminal emulator program you have.

Author: Jerry Avins
Date: 11:02 18-11-06

John Popelish wrote:
> RsK wrote:
>> Please anybody can give me a brief idea that using oscilloscope how i
>> can capture the waveform on a serial link, tranmitting the ASCII letter
>> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>>
>> I have connected oscilloscope with serial interface then? then selected
>> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
>> wt to do?
>>
>> waiting for ur reply?
>
> You need a terminal emulator program to capture the character stream
> into a file (that you name). Depending on what file format you set the
> scope to use to format the image, you use an image viewer to look at the
> resulting file. The details are dependent on the scope model and the
> terminal emulator program you have.

Does the OP want to see the letter, or the waveform? The ASCII letter R
in hexadecimal is 52. RS-232 standard levels are +/- 12 volts, with
"mark" = +12 and "space" = -12. The line protocol is "mark
idle", which
means that a quiet line is +12. ASCII characters begin with a start bit
(space), followed by 7 or 8 or 9 data bits (including parity if any),
and one, 1.5, or two stop bits. The usual is 8 data bits and one stop
bit. Hex 52 = 0101 0010, which in RS-232 becomes +-+-++-+. When framed
with start and stop bits, the sequence becomes -+-+-++-++. I generally
use letter U (hex 55) for testing. It's sequence is -+-+-+-+-+.

Jerry
--
Engineering is the art of making what you want from things you can get.
ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ

Author: Jan Panteltje
Date: 11:05 18-11-06

On a sunny day (18 Nov 2006 07:26:52 -0800) it happened "RsK"
<rizkhan7@gmail.com> wrote in
<1163863612.012437.59900@e3g2000cwe.googlegroups.com>:

>Please anybody can give me a brief idea that using oscilloscope how i
>can capture the waveform on a serial link, tranmitting the ASCII letter
>'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>
>I have connected oscilloscope with serial interface then? then selected
>the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
>wt to do?
>
>waiting for ur reply?

OK

>regards

really

As was pointed out you need some terminal program to send the 'R' repeatedly.

When you connect the scope to the serial out RS232 line, the following applies:

1200 Baud is 1200 bits / second, so the time for one bit is about 830 uS.

If you have the terminal program and press 'R' with short intervals, and
trigger the scope on the start bit (pos or negative depends on where you
measure), and set the trace so one division is exactly 1/1200 sec (830us),
then you should be able to see a full character plus start and parity bit
(10 bits in your case = 10 divisions), on the scope.

Works both with a normal and with a storage scope, analog or digital.
If the picture is faint (dim) use auto-repeat..... stick a match in the 'R' key
to hold it down.

Now what you will see is one start bit, the ASCII code for 'R', and a parity bit.
the ASCII code for 'R' is 52 hex, or in binary, with MSB first:
0101 0010

The start bit added
0 0 1 0 1 0 0 1 0

Parity added (you do not say odd or even):
0 0 1 0 1 0 0 1 0 x

The stop bit added:
0 0 1 0 1 0 0 1 0 x 1

^
scope trigger point
This is what the scope will display.
On the scope you will not see the last '1' if 10 divisions and 1 bit per division, no
problem,
that bit is always the same.









Author: krw
Date: 11:07 18-11-06

In article <1163863612.012437.59900@e3g2000cwe.googlegroups.com>,
rizkhan7@gmail.com says...
> Please anybody can give me a brief idea that using oscilloscope how i
> can capture the waveform on a serial link, tranmitting the ASCII letter
> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>
> I have connected oscilloscope with serial interface then? then selected
> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
> wt to do?

- Connect CH1 to TXD
- Select CH1
- Select CH1 as the trigger source
- Select trigger slope = negative
- Vertical amplifier = 1 to 5V/div, depending on the situation
- Time base = 1msec/div

You should see the initial positive to negative transition with the
signal low for the start bit. The rest of the bits should follow
at 833usec (a little less than a division) intervals. The ten bits
should almost fill up the display (8.3 divisions). If the
characters are being sent one after another the display may be a
bit unstable. Depending on the scope, playing with the trigger
holdoff may help.

--
Keith

Author: Chris
Date: 11:08 18-11-06


RsK wrote:
> Please anybody can give me a brief idea that using oscilloscope how i
> can capture the waveform on a serial link, tranmitting the ASCII letter
> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>
> I have connected oscilloscope with serial interface then? then selected
> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
> wt to do?
>
> waiting for ur reply?
>
> regards

Hi, RsK. You might want to consider using a "U" (0x55), because each
bit changes (01010101).

Set your timing so you send the character every 50ms. or so, then put
your scope on RxD and set your scope for auto trigger, 5V/div, 5ms/div.
Tweak your PGT trigger level to +3V, and you should be good to go

Are you having trouble setting the scope, your terminal program
settings, or what?

Cheers
Chris


Author: =?UTF-8?B?UGFsaW5kcuKYu21l?=
Date: 11:19 18-11-06

John Popelish wrote:
> RsK wrote:
>
>> Please anybody can give me a brief idea that using oscilloscope how i
>> can capture the waveform on a serial link, tranmitting the ASCII letter
>> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>>
>> I have connected oscilloscope with serial interface then? then selected
>> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
>> wt to do?
>>
>> waiting for ur reply?
>
>
<piggyback> Sorry, didn't get the OP.
http://www.picotech.com/experiments/serial_data/results.html


A letter R in ASCII is 01010010 in binary. (8 bit - leave off the
leading zero for 7 bit)

Reversing that to put the least significant bit first, this is 01001010
- this is the order in which the bits will be sent down the line.

At 1200 Baud, there will be a maximum of 1200 transitions in voltage
level a second.

Initially, the scope will show a steady input of -12v.

The first transition will be the beginning of the start bit, which will
take the input to +12v.

~0.8mSec later the least significant bit of the character is sent, as
this is a 0, the input will go to -12v.

~0.8mSec later, the next least significant bit will be sent - this time
a 1, so the input will rise to +12v.

The other bits will then be sent, at the same spacing. The parity bit,
assuming even parity, will be sent as a 1. Then the end bit will be sent
-this is just a period at -12v to ensure that the next start bit can be
recognised.


--
Sue







Author: PeteS
Date: 11:45 18-11-06

Jerry Avins wrote:
> John Popelish wrote:
>> RsK wrote:
>>> Please anybody can give me a brief idea that using oscilloscope how i
>>> can capture the waveform on a serial link, tranmitting the ASCII letter
>>> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>>>
>>> I have connected oscilloscope with serial interface then? then selected
>>> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
>>> wt to do?
>>>
>>> waiting for ur reply?
>>
>> You need a terminal emulator program to capture the character stream
>> into a file (that you name). Depending on what file format you set
>> the scope to use to format the image, you use an image viewer to look
>> at the resulting file. The details are dependent on the scope model
>> and the terminal emulator program you have.
>
> Does the OP want to see the letter, or the waveform? The ASCII letter R
> in hexadecimal is 52. RS-232 standard levels are +/- 12 volts, with
> "mark" = +12 and "space" = -12. The line protocol is "mark
idle", which
> means that a quiet line is +12. ASCII characters begin with a start bit
> (space), followed by 7 or 8 or 9 data bits (including parity if any),
> and one, 1.5, or two stop bits. The usual is 8 data bits and one stop
> bit. Hex 52 = 0101 0010, which in RS-232 becomes +-+-++-+. When framed
> with start and stop bits, the sequence becomes -+-+-++-++. I generally
> use letter U (hex 55) for testing. It's sequence is -+-+-+-+-+.
>
> Jerry

Minor correction; a marking line is -3 <> -15V (logical 1) :)

Cheers

PeteS

Author: Jerry Avins
Date: 11:47 18-11-06

PeteS wrote:

...

> Minor correction; a marking line is -3 <> -15V (logical 1) :)

Of course. Sometimes my head gets stuffed with current loop facts.

Thanks.

Jerry
--
Engineering is the art of making what you want from things you can get.
ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ

Author: PeteS
Date: 12:15 18-11-06

PeteS wrote:
> RsK wrote:
>> Please anybody can give me a brief idea that using oscilloscope how i
>> can capture the waveform on a serial link, tranmitting the ASCII letter
>> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>>
>> I have connected oscilloscope with serial interface then? then selected
>> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
>> wt to do?
>>
>> waiting for ur reply?
>>
>> regards
>>
>
> To assist in your reading the replies here, I posted a PDF of a
> simulated scope trace of the letter 'R' (assuming it to be the only
> transmission) on RS232.
>
> Cheers
>
> PeteS

Helps if I identify where, of course

On a.b.s.e.

Cheers

PeteS

Author: PeteS
Date: 12:21 18-11-06

RsK wrote:
> Please anybody can give me a brief idea that using oscilloscope how i
> can capture the waveform on a serial link, tranmitting the ASCII letter
> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>
> I have connected oscilloscope with serial interface then? then selected
> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
> wt to do?
>
> waiting for ur reply?
>
> regards
>

To assist in your reading the replies here, I posted a PDF of a
simulated scope trace of the letter 'R' (assuming it to be the only
transmission) on RS232.

Cheers

PeteS

Author: Jan Panteltje
Date: 12:46 18-11-06

On a sunny day (18 Nov 2006 07:26:52 -0800) it happened "RsK"
<rizkhan7@gmail.com> wrote in
<1163863612.012437.59900@e3g2000cwe.googlegroups.com>:

Now what you will see is one start bit, the ASCII code for 'R', and a parity bit.
the ASCII code for 'R' is 52 hex, or in binary, with MSB first:
0101 0010

Correction, seems it is transmitted LSB first:
see
http://www.acumeninstruments.com/Support/documentation/SerialPortBasics/index_pg6.shtml



Author: jasen
Date: 17:52 18-11-06

On 2006-11-18, Jerry Avins <jya@ieee.org> wrote:
> John Popelish wrote:
>> RsK wrote:
>>> Please anybody can give me a brief idea that using oscilloscope how i
>>> can capture the waveform on a serial link, tranmitting the ASCII letter
>>> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>>>
>>> I have connected oscilloscope with serial interface then? then selected
>>> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
>>> wt to do?
>>>
>>> waiting for ur reply?
>>
>> You need a terminal emulator program to capture the character stream
>> into a file (that you name). Depending on what file format you set the
>> scope to use to format the image, you use an image viewer to look at the
>> resulting file. The details are dependent on the scope model and the
>> terminal emulator program you have.
>
> Does the OP want to see the letter, or the waveform? The ASCII letter R
> in hexadecimal is 52. RS-232 standard levels are +/- 12 volts, with
> "mark" = +12 and "space" = -12.

T'other way round. mark is negative.

--

Bye.
Jasen

Author: jasen
Date: 18:28 18-11-06

On 2006-11-18, RsK <rizkhan7@gmail.com> wrote:
> Please anybody can give me a brief idea that using oscilloscope how i
> can capture the waveform on a serial link, tranmitting the ASCII letter
> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>
> I have connected oscilloscope with serial interface then? then selected
> the CH1 & CH2 then changed some setting on oscilloscope for RS232 , the
> wt to do?

assuming you're using 7 data bits even parity and one stop bit
(which is a fairly common line protocol)

idle line is negative , then 7 data bits (1 is negative 0 is positive)
then the stop parity and then the stop bit.

start 0
data (lsb first) 0100101
parity 1
stop 1


set you scope for positive triggering, and about 2ms/division scan rate
and 5V/division vertical gain (assuming a "X10" probe)
connect it to pin 3 of the 9-pin serial port, pin 5 is your ground.
you'll get something like this.

(view with fixed font)


S D0 D1 D2 D3 D4 D5 D6 P S

-------- -------- ----
---- ---- -------------...

|
after the stop bit the voltage will stay low until
the start bit of the next symbol...

if your terminal program has such a feature you can program one of the
function keys to send RRR and then wedge it down
which will give a brighter trace and also show the start bit coming
right after the stop bit.

with the keyboar repeat at about 16 per second (fairly normal) you'll see
some idle time and
some start bit immediatley after the stop bit.

Bye.
Jasen

Author: Jerry Avins
Date: 21:07 18-11-06

jasen wrote:
> On 2006-11-18, Jerry Avins <jya@ieee.org> wrote:
>> John Popelish wrote:
>>> RsK wrote:
>>>> Please anybody can give me a brief idea that using oscilloscope how i
>>>> can capture the waveform on a serial link, tranmitting the ASCII letter
>>>> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?
>>>>
>>>> I have connected oscilloscope with serial interface then? then selected
>>>> the CH1 & CH2 then changed some setting on oscilloscope for RS232 ,
the
>>>> wt to do?
>>>>
>>>> waiting for ur reply?
>>> You need a terminal emulator program to capture the character stream
>>> into a file (that you name). Depending on what file format you set the
>>> scope to use to format the image, you use an image viewer to look at the
>>> resulting file. The details are dependent on the scope model and the
>>> terminal emulator program you have.
>> Does the OP want to see the letter, or the waveform? The ASCII letter R
>> in hexadecimal is 52. RS-232 standard levels are +/- 12 volts, with
>> "mark" = +12 and "space" = -12.
>
> T'other way round. mark is negative.

Yes. Sorry. Sometimes the TTL version sticks in my head. It's been a
long time.

Jerry
--
Engineering is the art of making what you want from things you can get.
ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ

Author: Jerry Avins
Date: 21:08 18-11-06

Jerry Avins wrote:

From provate email. because I don't see it here:

Patrick Klos wrote:
> To: jya@ieee.org
> Subject: Re: how to do it? RS232
> Newsgroups:
comp.robotics.misc,sci.engr.control,sci.electronics.basics,alt.engineering.electrical,sc
i.electronics.design
> In-Reply-To: <f8udnWF5wKqDpMLYnZ2dnUVZ_tCdnZ2d@rcn.net>
> References: <1163863612.012437.59900@e3g2000cwe.googlegroups.com>
<hqGdnSs2ZtLdtcLYnZ2dnUVZ_s2dnZ2d@adelphia.com>
<pJ6dnYD4NK_ns8LYnZ2dnUVZ_q-dnZ2d@rcn.net>
<9NG7h.10349$Fv1.4670@newsfe2-win.ntli.net>
> Organization: Klos Technologies, Inc.
> Cc:
>
> In article <f8udnWF5wKqDpMLYnZ2dnUVZ_tCdnZ2d@rcn.net> you write:
>> PeteS wrote:
>>
>> ...
>>
>>> Minor correction; a marking line is -3 <> -15V (logical 1) :)
>> Of course. Sometimes my head gets stuffed with current loop facts.
>>
>> Thanks.
>
> Correct me if I'm wrong, but I'm pretty sure the serial bits are
> transmitted LSB first? Your picture gave the impression that MSB
> is sent first. Am I remembering that correctly?
>
> Patrick
> =========== For PPP Protocol Analysis, check out PacketView Pro!
===========
> Patrick Klos Email: patrick@klos.com
> Klos Technologies, Inc. Web: http://www.klos.com/
>
============================================================================

Patrick,

These followups belong in the newsgroup with the rest of the thread. The
most significant bit is sent first and appears on the left of the scope
trace. http://francis.courtois.free.fr/jc1/serial/Basics/RawSignals.html
might be helpful

--
A quitter never wins. A winner never quits. A fool never does either.
ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ

Author: HKJ
Date: 03:40 19-11-06

RsK wrote:
> Please anybody can give me a brief idea that using oscilloscope how i
> can capture the waveform on a serial link, tranmitting the ASCII letter
> 'R' with 1 start bit, 1 end bit, 1 parity, with 1200 Baud.?

Your can see the waveform for any serial data with this program:

http://www.miscel.dk/MiscEl/miscelSerialCommunication.html

If your want to capture it live on an oscilloscope your need a scope
with storage (a PC based digital scope is fine) or your must send the
data repeatedly.

Author: john jardine
Date: 11:56 19-11-06


"HKJ" <henrik.k.jensen@miscel.dk> wrote in message
news:45601883$0$182$157c6196@dreader1.cybercity.dk...
[...]
>
> Your can see the waveform for any serial data with this program:
>
> http://www.miscel.dk/MiscEl/miscelSerialCommunication.html
>
Nice idea you have there, hope you stick with it.
Use it when I'm just too bone idle to pick up the calculator.
The "Attenuators" section (nice!). Any chance of offering say 3 digits of
resistor precision in addition to the E12 rounding?. Or maybe offer an
E12/E24/E96 rounding option?.
john



--
Posted via a free Usenet account from http://www.teranews.com


Author: john jardine
Date: 12:08 19-11-06


"john jardine" <john@jjdesigns.fsnet.co.uk> wrote in message
news:45607fc7$0$21121$88260bb3@free.teranews.com...
>
> "HKJ" <henrik.k.jensen@miscel.dk> wrote in message
> news:45601883$0$182$157c6196@dreader1.cybercity.dk...
> [...]
> >
> > Your can see the waveform for any serial data with this program:
> >
> > http://www.miscel.dk/MiscEl/miscelSerialCommunication.html
> >
[...]
> The "Attenuators" section (nice!). Any chance of offering say 3 digits of
> resistor precision in addition to the E12 rounding?. Or maybe offer an
> E12/E24/E96 rounding option?.

Ignore that. Just spotted all the rounding options :)



--
Posted via a free Usenet account from http://www.teranews.com


Author: HKJ
Date: 12:30 19-11-06

john jardine wrote:
> "HKJ" <henrik.k.jensen@miscel.dk> wrote in message
> news:45601883$0$182$157c6196@dreader1.cybercity.dk...
> [...]
>> Your can see the waveform for any serial data with this program:
>>
>> http://www.miscel.dk/MiscEl/miscelSerialCommunication.html
>>
> Nice idea you have there,

Thanks,

> hope you stick with it.

I plan to.


> Use it when I'm just too bone idle to pick up the calculator.
> The "Attenuators" section (nice!). Any chance of offering say 3 digits of
> resistor precision in addition to the E12 rounding?. Or maybe offer an
> E12/E24/E96 rounding option?.


It is already there, use the "System, Preferede component" page to
select it.
http://www.miscel.dk/MiscEl/miscelPreferedComponents.html

In the System menu your also have a search function, that can be used to
locate the correct page to do something. Write E96 in it at it will tell
your to look at the "Prefered component" page.

1 2


      Contact  |  Electronic Portal


Sci.Electronics.Basics by Keywords
ADC
Antenna
CAD
Coil
Generator
IDE
LCD
Modulator
MOSFET
NiMH
Opamp
Oscilloscope
PID
RS232
Telephone
Transformers
TTL
USB

Sci.Electronics.Basics By Author