Connect with us

RS232 Voltage Levels

Discussion in 'General Electronics' started by Charles Jean, Jan 5, 2006.

Scroll to continue with content
  1. Charles Jean

    Charles Jean Guest

    I've got a datasheet for a chip that takes an RS232 serial input with
    a protocol of 9600,N,8,1. It indicates the voltage level at this
    input is hardware-selectable to either +/- 12V(as found from a PC
    serial port), and either normal or inverted TTL level(0-5V). I plan on
    feeding this chip a TTL level serial stream by bit-banging it rather
    than using a UART. I am familiar with the polarities and V
    requirements of the "real" RS232 as shown in the example below for
    ASCII 65("A"):


    +15V-|------<--8 character bits---->--------------
    | ___ _______________ ___
    | |S | | | | |
    | |T | | | | |
    | |A | | | | |
    +3V-|--|R-|--|--------------|--|--|--------------
    | |T | | | | |INDETERMINATE
    | | | | | | |VOLTAGE
    0V-|--|B-|--|--------------|--|--|--------------
    | |I | | | | |REGION
    | |T | | | | |
    -3V-|--|--|--|--------------|--|--|--------------
    | | | | | | |
    | | | | | | | TWO
    | | | | | | | STOP
    | | | | | | | BITS
    ____|__| |__| | | | | |__| |__|__| | | |
    | 0 1 0 0 0 0 0 1 0 1 1
    -15V-|------LSB------------------MSB--------------

    Bit width = 1/9600 seconds = 104.2 microseconds


    Can someone please educate me as to what are:

    1)"normal" TTL RS232 voltage levels
    2)"inverted" TTL RS232 voltage levels

    TIA
    Charlie
     
  2. There is no such thing as "TTL RS232 voltage" levels.

    UARTs send/receive a logic "1" (e.g. 5V or 3.3V) for a mark,
    and a logic "0" (e.g. 0V) for a space.
    You really don't know what it means to invert a TTL signal?
     
  3. Charles Jean

    Charles Jean Guest

    ___

    Thanks Mark, for clearing that up. Does this look like the proper way
    to send the chip an "A", then, with the mode set at "normal"
    TTL(0-5V)? What are the indeterminate voltage limits? Any need for a
    delay prior to sending the next character"?


    |------<--8 character bits---->--------------
    +5V_|___ ___ ___ ______
    | |S | | | | | | | | | | |
    | |T | | | | |2 STOP
    | |A | | | | |BITS
    +?V-|--|R-|--|--------------|--|--|--------------
    | |T | | | | |
    | | | | | | |INDETERMINATE
    | |B | | | | |VOLTAGE
    | |I | | | | |REGION
    | |T | | | | |
    +?V-|--|--|--|--------------|--|--|--------------
    | | | | | | |
    | | | | | | |
    | | | | | | |
    | | | | | | |
    0V_| |__| |--|--|--|--|--| |__| | |
    0 1 0 0 0 0 0 1 0 1 1
    LSB MSB

    Bit width = 1/9600 seconds = 104.2 microseconds



    "Sic hoc legere scis nimium eruditionis habes."
    (If you can read this, you're overeducated.)
     
  4. Who's Mark?
    You'll have to look at the electrical specs for the UART in
    question. For standard TTL, a "0" has to be below 0.7V and a
    "1" has to be above something like 2V. For CMOS, it's usually
    1/3 and 2/3 of the supply voltage.
    Not usually, no.

    It looks like a 0x41 to me.
     
  5. Must be a spurious random message being generated by those TTL RS232
    signals.

    Hi Charlie, have a look at the MAX232 or MAX233 (no caps).

    The only thing that springs to mind from reading your post is, "What on
    earth does this mysterious chip do, what is it called, who makes it?"
     
  6. David Tweed

    David Tweed Guest

    No delay should be required.

    -- Dave Tweed
     
  7. Jim Thompson

    Jim Thompson Guest

    [snip]

    Space's brother ?:)

    ...Jim Thompson
     
  8. "Jim Thompson" wrote ...
    ROTFL! :))

    (But likely lost on the younger crowd.)
     
  9. Jasen Betts

    Jasen Betts Guest

    As shown above

    mark (binary 1) 1s -12V(ish) stop bits, 1 in the data and idle time
    space (binary 0) is +12V(ish) start bits, 0 the data and the break signal
    for +12V read "0V" logic low
    for -12V read "+5V" logic high

    Chips like max232 and LM1488+LM1489 convert between the two.
    not that you'll need to do that, but the data sheets may prove
    informative.

    Bye.
    Jasen
     
  10. Robert Baer

    Robert Baer Guest

    There is no such thing as a TTL RS232 level; there are the nominal
    TTL levels (0 to 0.8V for a low or "zero" and 2.4V to 5.0V for a high or
    a "one"), and there are the levels for RS-232 which you have so
    elegantly demonstrated.
    There may still be some devices that will convert RS-232 levels to
    TTL and some that go the other way.
     
  11. Robert Baer

    Robert Baer Guest

    I believe a logic 1 is negative and a logic zero is positive as per
    the elegant diagram provided by the O.P. .
    For a teletype, i think (it has been a few daze) a mark was current
    flowing for a logic one.
     
  12. How long distances do you intend to transfer the TTL signal ?

    Is there a cable between the devices or is this just a PCB track above
    a continuous ground plane ?

    The standard TTL maximum receiver "0" state voltage is 0.8 V, so if
    you have some ground potential differences, such as ground bounce due
    to fast peak currents or feeding both equipment from a single DC power
    supply with common 0 V causing large ground return currents, your "0"
    state noise marginal can be quite quickly ruined.
    If you are using bit banging, you usually have some degree of
    uncertainty about your timing. I would suggest that you on transmit
    generate at least 2 (or even more) stop bits and on receive, always
    accept a new start bit after 1 stop bit (or even 0.5-0.7) stop bit
    time, regardless what the specification says about the number of stop
    bits in each case. This ensures a reliable connection even if the
    sampling points are a bit off and only reduces the throughput about 10
    % on transmit.

    Paul
     
  13. Roy L. Fuchs

    Roy L. Fuchs Guest


    Can you say "False low"?
     
  14. Chuck F.

    Chuck F. Guest

    The receiver will normally sample the incoming line at 1/2 bit time
    from the nominal transition. Once the stop bit has been sampled,
    it should immediately go into a 'hunt' mode for the start bit of
    the next character. This automatically yields 1/2 bit of timing
    slop. So there is never any point to using more than two stop bits
    at the transmitter.

    --
    Some informative links:
    http://www.geocities.com/nnqweb/
    http://www.catb.org/~esr/faqs/smart-questions.html
    http://www.caliburn.nl/topposting.html
    http://www.netmeister.org/news/learn2quote.html
     
  15. Jim Thompson

    Jim Thompson Guest

    On Fri, 06 Jan 2006 09:46:11 GMT, Robert Baer

    [snip]
    RS-232 -> TTL = MC1489

    TTL -> RS-232 = MC1488

    These chips are still available more than 40 years after I designed
    them ;-)

    These chips adhere to the original RS-232 spec.

    Later versions, such as some of those from Maxim, are "one-sided",
    5V-only devices.

    ...Jim Thompson
     
  16. No. TTL didn't use any negative voltages. Logic 0 is <0.7 and
    logic 1 is >2.X.

    Inverting a TTL signal means you convert a Logic 0 to a Logic 1
    and vice versa. A Boolean "not".
    He's asking about TTL. I think.
     
  17. Do you have a "top-10" list of Thompson's Greatest Hits?

    I see your air freshener puffing away frequently on TV.
    How did they select thost (odd) intervals?
     
  18. Jim Thompson

    Jim Thompson Guest

    MC1488/89 RS-232... still in manufacture

    MC1530/31 OpAmp... still in manufacture

    MC1650/51 HS Comparator... still in manufacture

    All the PLL stuff, VCO's, VCM's, phase detectors... most still in
    manufacture

    Automotive stuff in the '60's, early '70's

    USB driver/receiver for Intel

    Roughly 160 custom chips (ASIC's)... the largest source of my income
    ;-)
    I designed the combination flyback power supply / driver for the piezo
    pump, and the low power clock.

    Two associates of mine in Columbus, Ohio, did the "microprocessor".
    The odd intervals probably came from how rudimentary the uP is.

    ...Jim Thompson
     
  19. EIA RS232 spec says that the max. voltage level is 15V.
    It also says that the minimum non-space voltage level
    is (7.5V?), but most devices will work at lower levels
    so TTL signal levels work but not be in conformance
    with the standard.
     
  20. 1488 requiring several supplies -- and runs hot as a pistol, too. I've
    got a box of both; they were about all there was to use in the market
    and worked well when I was using them; but don't use them much now
    because of the power requirements (especially the 1488) and the
    serious heat to be removed (again the 1488 much more than the 1489, if
    memory serves, but neither of them slouches in the heating
    department.)

    Jon
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-