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.

MSP430FR5739: Internal pull up/ pull down not functioning as expected

Part Number: MSP430FR5739
Other Parts Discussed in Thread: MSP-EXP430FR5739

I wrote a code which lights up leds when two switches connected to pins in port 3 are pressed together. The code is displayed below:

#include <msp430.h>

int main(void)
{

  WDTCTL = WDTPW + WDTHOLD;                 // Stop the watchdog timer

  P3DIR  = 0;                // Set P3as inputs
  P3REN  = (BIT0 + BIT1 + BIT2 + BIT3);    // Pull BIT 0,1 HIGH and Keep them HIGH.
  P3OUT  = (BIT0 | BIT1 | BIT2 | BIT3);   

  PJDIR  = ( BIT0 + BIT1 + BIT2 + BIT3);    // Set outputs in PORT
 
  PJOUT  = 0; //set initial outputs to LOW

  while (1) {

    if ((!(P3IN & 0x04)) && (!(P3IN & 0x08))) {

        PJOUT = ( BIT0 + BIT1 + BIT2 + BIT3);

    }

   
  }
}

The code failed to work as expected and it turned out that adding a external pullup resistor to port 3.2 solved my problem.

Is there any particular reason why the internal pullup configuration of port3.3 works fine but not in port 3.2?

P.S. I am using the FRAM experimeter's board which consists the MSP430FR5739 MCU.

Thanks in advance.

  • P3.2 is connected to the ADXL335 accelerometer's ZOUT pin with a 100 nF pulldown capacitor, whereas P3.3 is only tied to P2.7 (the LDR is not populated). This additional hardware connection most likely has to do with the issues you are seeing, please review Section 3.2 (Schematics) of the MSP-EXP430FR5739 FRAM Experimenter Board User's Guide.

    Regards,
    Ryan

**Attention** This is a public forum