Jump to content
43oh

GPS showing scrambled output on Serial monitor


Recommended Posts

Hello! I've got a problem when I want to show the output on serial monitor of a GPS. 

When I put a basic example (fade example) and the TX of the GPS on the TX of MSP430 (P1_2 pin) the output shows good, without any problem. The baud rate was the stock one (9600).

output_fade_example.thumb.png.9a12061f66fb2adb869e06fc6182891a.png

 


When I try to make the same thing on other pins (I've choosed RX of GPS to P1_3 and TX of GPS to P1_4) a scrambled output takes place on the serial monitor and I don't really know what to do.  

output_gps_example.png.ce90b97af90b11a3ab644c9b477b9e7e.png

I'll attach the code, maybe it's a code issue. Thanks in advance!

I'm new in this so take me easy please :D

 

//THE CODE

https://pastebin.com/cjFyjHns


 

#include <SoftwareSerial.h>
static const int RXPin = P1_4, TXPin = P1_3;
static const uint32_t GPSBaud = 9600;
// The serial connection to the GPS device
SoftwareSerial ss(RXPin, TXPin);
void setup()
{
  Serial.begin(115200);
  ss.begin(GPSBaud);
}
void loop()
{
  // Output raw GPS data to the serial monitor
  while (ss.available() > 0){
    Serial.write(ss.read());
   // delay(10);
  }
}

 

Edited by bluehash
[ADMIN] Please use code tags
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...