Page 1 of 1

Flora GPS

Posted: Thu Nov 16, 2023 11:14 pm
by maxwoodward
I am trying to use the Flora Ultimate GPS Module with an ESP32 dev board and I can't get it to work. I have just been trying to get the Hardware Serial Echo example to work, but I never get an output in the serial monitor. I have tried it with multiple different boards with the same results. I have also tried going outside for it to connect, but still no luck. Any other tips to try to get it to work or is it possible I got a faulty module?
Thanks in advance!

Re: Flora GPS

Posted: Fri Nov 17, 2023 11:27 am
by dastels
Please post photos of your connections.

Dave

Re: Flora GPS

Posted: Sat Nov 18, 2023 11:22 pm
by maxwoodward
Sorry I forgot to add a picture of my wiring! I am using a Lolin D32 Pro board in this picture, but I have tried it on a different ESP32 board with the same results.
[attachment=0]GPS module.jpg[/attachment
I have TX to RX and RX to TX, GND to GND, 3V from dev board to the module. The module turns on and the LED flashes, but I never get any output in the serial monitor.
I have also tried adjusting the baud rate just to see if that would do anything, but it did not.

Re: Flora GPS

Posted: Sat Nov 18, 2023 11:37 pm
by dastels
I'm not a fan of alligator clips used like this but as long as you're careful not to let them touch (a bit of tape around the exposed bits goes a long way to avoiding shorts) it should be good enough to test things.

The next question is your code. Can you post it?

Dave

Re: Flora GPS

Posted: Sun Nov 19, 2023 12:58 am
by maxwoodward
Thanks for the tip with the electrical tape!
This is just the Hardware Serial Echo test from the Adafruit GPS library

Code: Select all

#define GPSSerial Serial1


void setup() {
  // make this baud rate fast enough to we aren't waiting on it
  Serial.begin(115200);

  // wait for hardware serial to appear
  while (!Serial) delay(10);

  // 9600 baud is the default rate for the Ultimate GPS
  GPSSerial.begin(9600);
}


void loop() {
  if (Serial.available()) {
    char c = Serial.read();
    GPSSerial.write(c);
  }
  if (GPSSerial.available()) {
    char c = GPSSerial.read();
    Serial.write(c);
  }
}

Re: Flora GPS

Posted: Sun Nov 19, 2023 12:28 pm
by dastels
Hmm. Everything looks reasonable. The connections still make me wonder if it could be a bad connection. What other board have you tried it with? Anything other than ESP32 boards? It would be nice to ascertain whether the GPS board is working.

Dave

Re: Flora GPS

Posted: Sun Nov 19, 2023 2:56 pm
by maxwoodward
I found the problem! On this line

Code: Select all

#define GPSSerial
the example had it defined as Serial1, and the D32 Pro only has UART0 pins accessible. So changing Serial1 to just Serial fixed my issue.
Thanks for the help, it led me in the right direction!

Re: Flora GPS

Posted: Sun Nov 19, 2023 3:09 pm
by dastels
Really? Serial is generally the USB "serial".

On most boards with native USB (unlike the UNO where Rx/Tx *is* the USB serial) the Rx/Tx pins are Serial1.

Anyway... yay!

Dave