This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

5V input pins on MSP430-5529 for a sensor

Other Parts Discussed in Thread: MSP430F5529

I've seen the 5V output pins on the board, however, I am not sure whether is safe to have a 5V input.

I want to implement a program that switches a led on when it gets close to something. To do so, I am using the HC-SR04 sensor, and I already found this code.

The code seems to use port 1.3 for the input of the sensor (echo) and interrupt, but, since there is not hardware set up explanation I don't know if I need to process it (5V >> 3.3V) or I am ready to go.

Thank you.

  • Hi Jon,

    The 5V output comes from the USB connection. These output pins on the board will only be available if you have a jumper for 5V between the ezFet and Launchpad. However, the MSP430F5529 does not use the 5V for input (it uses the 3.3V input which is stepped down from 5V from the onboard TPS62237). This 5V input is available as users will want to attach boosterpacks to this launchpad which may require 5V. Please see the hardware design files for the launchpad for more details about this connection and the buck converter: software-dl.ti.com/.../MSP-EXP430F5529LP_Hardware_Design_Files.zip

    The sensor that you wish to use appears to require 5V so if you are using the launchpad powered by USB then you can use the 5V output as long as you have the jumper placed. Please see the picture below:

    Regards,

    Akash Patel

  • The 5V pins on the LaunchPad are just power supplies, coming directly from USB; they are not related with the MCU itself.

    The F5529 does not have 5V-tolerant inputs. You have to use some level shifter circuit.
  • Would a resistor be enough to lower the current ? I think I read somewhere that a 4k7 resistor would make it, wouldn't it ?

  • This depends on whether the sensor actually outputs a signal with a TLL or a CMOS level. See sections 3.1/3.2 of the application report 3.3 V I/O Considerations for Hercules™ Safetywhatever MCUs.

  •  

    The sensor inputs a TTL level signal. However, I am not very familiar with electric schemes, long time since I last used them.

    Source, page 1, Electronic Parameter.

    Should I check the 3.1 on the pfd you linked ? In that case, a resistor (Figure 1) between both devices would be enough right ?

    I just need to know the max current for the pin input, in order to calculate the resistor ohm resistance needed.

  • That PDF is utter garbage. With "TTL", they mean "5 V". The HC-SR04 actually outputs a 5 V CMOS signal.
  •  

    LOL, good to know. Where did you find that out ? That documentation would be helpful.

    In that case, is 3.2 - 5 V CMOS 3.3 V CMOS the way to go ? Will a 130 μA input be safe for the board pin ?

  • Google finds oscilloscope measurements of its output.

    In theory, no current is really safe for the ESD protection diodes, but if TI says that 75 µA work, it probably will.
    Anyway, in the voltage divider, all current flows to ground.

  • Even though I live in Germany, I can't speak it and I don't really understand the schemes on the pdf.

    The diode part is inside the devide, that's not something I have to set up, right ?

  • The ESD protection diodes are part of the F5529's GPIO inputs. If they were not there, you would not need to shift the signal level down.
  • To be honest, I am so confused right now.

    The boxes represent the devices, so I only need 2 resistors and a ground pin to set it all up, right ?

    Also, you said the pin current limit is 75 μA:

    Clemens Ladisch said:
    TI says that 75 µA work

    However, the scheme limits it to 130 µA.

    http://www.ti.com/lit/an/spna087a/spna087a.pdf said:
    The LOH current will be limited to 130 μA

    Do I have to use bigger resitance resistors to low it to 75 μA ?

  • Yes, you need only the two resistors to build a voltage divider.

    In section 3.1, the current flows through the ESD protection diodes.
    In section 3.2, the entire current flows through both resistors, so the amount does not matter for the F5529. (You'd have to ensure that you do not try to draw more current than the sensor can supply, but the datasheet does not tell you about this.)

**Attention** This is a public forum