TTL vs RS232

Discussion in 'General Electronics Chat' started by TBayBoy, Oct 30, 2011.

  1. TBayBoy

    Thread Starter Member

    May 25, 2011
    148
    19
    I'm scratching my head on this, probably searching for the wrong thing, but in rs232, binary is sent with idle bits, start bit, parity LSB to MSB, start, idle.

    TTL is MSB to LSB parity but is there any idle, start and stop?
     
  2. kubeek

    AAC Fanatic!

    Sep 20, 2005
    4,670
    804
    TTL UART is the same as RS232 only with different leves, so MSB and LSB have the same positions. Look in MAX232 datasheet.
     
  3. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    Rs232 have different voltage levels than TTL. Therfore communication with real RS232 devices we need a TTL to RS232 level converter. If you want to send data between two UARTS both working with the same voltage. No level conversion is needed
     
  4. TBayBoy

    Thread Starter Member

    May 25, 2011
    148
    19
    Thanks for the replies. :)
     
  5. samin

    Member

    Oct 14, 2011
    32
    6
    The RS232 uses to represent the 1 at between (-3V and-25V) and 0 to between (3 V and 25 V). Usually out of our PCs found-12V to +12 V.

    As against with TTL, 0 is represented by a voltage between 0 and 0.7V. while 1 is between 2.2V and 5V.
     
  6. RiJoRI

    Well-Known Member

    Aug 15, 2007
    536
    26
    Don't confuse the voltage levels/signal descriptions with the message format. RS-232 & TTL are voltage levels. What you send over the comm. lines is up to you: 5,6,7,8,9,etc. bits per byte, Odd, even, fixed-level or no parity; 1, 1.5, 2, 3, 4, etc. stop bits/idle. You could even start with more than one start bit.

    The common formats allow equipment by different manufacturers to communicate with each other, but if you do not care about that, you can use any format your heart desires.

    --Rich
     
  7. samin

    Member

    Oct 14, 2011
    32
    6
    Proof by example, here is a PC serial port connected to a MAX3235 , all connected to an oscilloscope.

    In red channel 1, a probe x10 on the wire 3 of the DB9, so Tx of RS232 .
    In blue channel 2, a probe x10 on the leg of a max3235 , so Rx of TTL .

    The PC is sending two characters in C 9600-8N1.

    So:
    * In Idle line is at 1. -10V in RS232 & +5V in TTL
    * The start bit S is set to 0
    * 8 bits of data for C, the ASCII character 0x43 or b01000011, knowing that the LSB is transmitted first
    * The stop bit S' at 1.
    * To the next character ...
     
  8. kubeek

    AAC Fanatic!

    Sep 20, 2005
    4,670
    804
    Nice shot, how did you do the labels?
     
Loading...