RS232 <-> TTL converting (max232)

Discussion in 'General Electronics Chat' started by somlioy, Jan 15, 2012.

  1. somlioy

    Thread Starter Member

    Jul 28, 2010
    22
    3
    Hi

    Currently fuzzing around with a Max232 and I got some questions about the level converting.

    This is my current setup:
    http://i.imgur.com/NpnCd.png

    Idle: http://i40.tinypic.com/332uydj.png
    Sending data: http://i41.tinypic.com/se62jk.jpg
    Channel 1 is TTL
    Channel 2 is RS232

    What I dont get, is why my leds are lit all the time.

    As you can see on the first scope-shot TTL is idling on 5v and RS232 on -8v

    This way, my leds wont blink when data is sent/recieved.
    Is there something wrong with my circuit or is this intended?

    Edit: VCC and GND for max232 is hidden on the schematic.
     
    Last edited: Jan 15, 2012
  2. kubeek

    AAC Fanatic!

    Sep 20, 2005
    4,670
    804
    First, you have the LEDs on the wrong side, they should be on the TTL side because they unnecesarily load the charge pump voltage.
    Second, one is connected to input, the other to output, and both these channels are left open at the TTL side, so no wonder nothing happens.

    Are you sure you understand how the chip works? T1IN changes T1OUT, R1IN changes R1OUT and so forth, T2 and R2 are completely independent of T1 and R1.
     
    somlioy likes this.
  3. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,884
    1,001

    You need to invert the signal to the LEDs

    This is what I did.

    [​IMG]

    You are not going to see them blink anyway. Your eye doe not move that fast.
     
    somlioy likes this.
  4. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,884
    1,001
    Here is the whole thing since you have errors in your schematic.
     
    somlioy likes this.
  5. somlioy

    Thread Starter Member

    Jul 28, 2010
    22
    3
    @kubeek Actually. I do have the leds on the TTL side, I just failed drawing the schematic. Respectively T1In and R1Out.
     
  6. kubeek

    AAC Fanatic!

    Sep 20, 2005
    4,670
    804
    Then try connecting them the other way, not connected to ground but connected to +5V. You could also use a tad higher values of the led resistors so that you don´t load the ttl outputs too much, 5mA should be enough to see.
     
    somlioy likes this.
  7. kubeek

    AAC Fanatic!

    Sep 20, 2005
    4,670
    804
    Serial port idle is high level on ttl side and low level on rs232 side as you confirmed with scope, so you need to invert the leds.
     
    somlioy likes this.
  8. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,884
    1,001
    I chose to use the transistor method so I can have a 3V or 5V MCU and not have to worry about changing the current limiting resistor though thinking it again I probably could have picked a happy medium for the resistor and do away with the transistors.

    Plus I read the MAx data sheet only after I had the thing built and found it would operate at a +3v supply too. :)
     
    somlioy likes this.
Loading...