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.

MSP-EXP430G2ET: Serial.print() not working. Nothing is being printed on Serial Monitor

Part Number: MSP-EXP430G2ET
Other Parts Discussed in Thread: ENERGIA, MSP-EXP430FR2355

I'm trying to use MSP-EXP430G2ET with Energia 1.8.7E21. Sample programs like Blink work fine. However, when I try to use a program like DigitalReadSerial that print to Serial, nothing is getting appeared on Serial Monitor. Tried keeping the TX, RX Jumpers horizontally as well as vertically. Still didn't work.

  • Did you set the baud rate on the terminal to match your program?

  • Yes. The program has 9600 baud rate in Serial.begin and the same has been selected in the serial monitor.
  • Hi,

    some thing you can check:
    The jumpers for the your should have the some direction than the other jumpers.
    If you rotate them by 90 Degree you get a feedback loop. So in this setting just send some characters from the PC. If they are echoed you know already that this part of the path is OK. If not check your com port. The debugger enumerates 2 port and often is the debug com port the one with the higher number.
    The MSP-EXP430G2ET is not available to be selected as board i assume you have used the MSP-EXP430FR2355 - right.

    Regards,
    Stefan
  • Hi,

    I checked the following,

    Kept the jumpers in the same direction as other jumpers. Same result, nothing printed on Serial monitor after reading a pin continuously.

    Rotated the jumpers by 90 deg. And tried sending characters from Serial monitor didn't get any echo.

    As you said, there are two COM ports MSP Application UART1 and MSP Debug Interface. Tried opening the serial monitor on MSP Debug Interface port (higher number). Still no result.

    I downloaded the latest version of Energia. It has the MSP-EXP430G2ET board listed.

    MSP Application UART1 and MSP Debug Interface 

  • Hi Stefan,

    Any ideas on this? The problem isn't solved yet

  • When I

    1) Rotated the TXD and RXD jumpers on J101(/J105) so that they were perpendicular to all the others

    2) Selected the "Application UART" COM port

    3) Ran the sketch below with Energia 1.8.7E21 (October 2018) on an MSP-EXP430G2ET Launchpad

    I got a (fast) sequence of "Hi" messages.

    I'm not sure what we're doing differently.

    void setup() {
      Serial.begin(9600);
    }
    
    void loop() {
      Serial.println("Hi");
      delay(1);
    }

  • I'm following the same, but getting no result. I have attached the picture of my board. Am I missing anything?

  • This looks the same as mine.

    All I can think of is something about the PC drivers. I get mine as part of CCS, but you had to install yours separately. Have you updated them recently?
  • Hi Avinash,

    sorry for the late reply as i was offline for a while.

    I assume that this issue is still not solved.

    I checked again that schematic of the launchpad and realized that this as a few things a little bit different then most others.

    So to do a loop back on the UART on the PC side you need to connect the UART pins in a cross. So

    RXD on the USB side with TXD on the MSP 430 side

    TXD on the USB side with RXD on the MSP 430 side

    This will generate the loopback on both sides.

    If you now open a terminal on the PC you should see that any typed character is echoed / displayed in the receive window.

    With this short Energia code you can test the same on the MSP430 side. If the loopback is OK the RED LED should be on

    #define LED RED_LED
    
    void setup()
    {
      // start serial port at 9600 bps:
      Serial.begin(9600);
    
      // initialize the digital pin as an output.
      pinMode(LED, OUTPUT);     
    }
    
    void loop()
    {
      // if we get a valid byte, read analog ins:
      if (Serial.available() > 0) {
        if (Serial.read() == 'A')
        {
            digitalWrite(LED, HIGH);   // turn the LED on (HIGH is the voltage level)
        }
      }else{
            digitalWrite(LED, LOW);    // turn the LED off by making the voltage LOW
        }
      Serial.print('A'); // send a capital A
      delay(300);
    }
    

    Regards,

     Stefan

  • Hi Stefan,

    Thanks for your reply. I am unable to understand what you imply on the following,

    RXD on the USB side with TXD on the MSP 430 side

    TXD on the USB side with RXD on the MSP 430 side

    How to actually connect the Jumper pins?

    I connected the RXD, TXD in cross like an X (not vertical or horizontal) in the following manner using jumper wires. Then tried your program. When I press 'A' or any other key and send. I get a junk value back as a reply on the Serial monitor. Attached the screenshot below

  • Hi Avinash,

    the setting of the jumper and the X on UART is perfect (exactly what i meant).

    So from the results we can see that the LED on pin 2 (P1.0) is on -> this means that sending and receiving data from the MSP430 side is OK (if you remove the X bridge then it will go off).

    But what is strange that you get some cryptic characters back on the PC side. It looks like an issue there.
    Just to check the simple things:
    - please ensure you have the right COM port selected. Just try all available COM ports.
    - can you open the device manager and check the driver version of the MSP430 UARTs
    - can you test on another PC ?

    Regards,
    Stefan
  • Hi Avinash,

    could you solve the issue or do you have further questions regarding this topic?
    If solved, please select "Resolved" for the post that solved your issue so this thread can be closed out. If you have a different question, please select "Ask a related question" or " Ask a new question".
    Thanks a lot!

    Best regards,
    Stefan
  • Hi Stefan,

    The problem isn't resolved yet. In the last picture that I had sent, the LED was on due to previously tried Blink example program and other sample programs for testing. It didnt get turned on when i sent the characters from serial monitor.

    However when I tried in another PC, I received back the characters sent on the serial monitor correctly (not any junk characters). But  the LED didn't glow though. I then switched the jumpers back to horizontal position (HW UART) and tried the AnalogReadSerial sketch. Still no output on serial monitor.

    Driver version from device manager: 1.4.0.0

    Tried both the COM ports MSP Application UART1 and MSP Debug Interface.

  • Hi Avinash,

    thanks for testing.

    So we know that:

    The communication part of the Serial on the PC side of the Launchpad is OK.

    Your first PC you used for testing seems to have a problem with the driver (you may can try again with the loopback and selecting the other available serial ports if not already done. I see a similar behavior when i select the wrong com port).

    The real issues seems to be on the MSP430 side on the Launchpad. The question is why the loopback is not working here. There are mainly two options for that:
    - the MSP430 got damaged and one of the IOs do not work. (could be checked with replacing the device)
    - there is a connection issue on the PCB. May you have a Multimeter available to check the connection between:
      - Pin 3 on the MSP430 socket to pin 5 on J101 (Header with jumpers)
      - Pin 4 on the MSP430 socket to pin 8 on J101 (Header with jumpers)

    Regards,

     Stefan

  • HI Avinash,

    could you solve the issue or do you have further questions regarding this topic?
    If solved, please select "Resolved" for the post that solved your issue so this thread can be closed out. If you have a different question, please select "Ask a related question" or " Ask a new question".
    Thanks a lot!

    Best regards,
    Stefan
  • Hi,

    I suppose that you were able to move on with your application as you didn't reply anymore, so I'll close this post.
    Please feel free to comment again if you look for further assistance regarding this topic, it will re-open the thread. If you have a different question, please select "Ask a related question" or " Ask a new question".

    Best regards,
    Stefan
  • Hi,
    The issue didn't get resolved for me. I will try with a new board.
  • Hi Avinash,

    thanks for the update. Please let me know the results, really would like to understand the issue.

    Regards,
    Stefan
  • Hi Avinash,
    have you already been able to test with a new board?
    Would be very interested if this did solve the issue.

    Thanks,
    Stefan
  • Hi Avinash,

    I suppose that you were able to move on with your application as you didn't reply anymore, so I'll close this post.
    Please feel free to comment again if you look for further assistance regarding this topic, it will re-open the thread. If you have a different question, please select "Ask a related question" or " Ask a new question".

    Best regards,
    Stefan

**Attention** This is a public forum