I’m having a problem with GPS connectivity on a Mega. After looking through the Google (or whatever the young people are calling it these days), I came across a thread on this subforum about how someone else wasn’t able to get the GPS signal off of their Arduino. It was a different GPS, but it worked when the sketch below was uploaded.
I’m trying to get a program I saw in this post:
Compiled, not tested:
SoftwareSerial gps(3, 4);
Serial.begin(9600); // Whatever rate you like; better be higher than the gps rate though. Set serial monitor to match
gps.begin(4800); // Or whatever rate the GPS uses
to work on my Mega. I’ve had problems using GPS in another sketch and I am trying to strip down to the bare basics of what I need to run in order to get a GPS signal. I was originally using the TinyGPS++ library.
I am currently running the GPS (a USGlobalSat EM-406A) through a SparkFun CAN-Bus shield on a Mega 2560. I’ve tried changing the pins from 4,3 on the SoftwareSerial line to 5,4 and 4,5 but nothing really happens. The code you see above will work with the exact same setup (minus the Mega) on an Uno R3.
A picture of the current setup is attached. I’ve got jumpers going to pins 50-53 from 10-13 for compatibility reasons.