Shop OBEX P1 Docs P2 Docs Learn Events
PMB-648 not syncing to sats — Parallax Forums

PMB-648 not syncing to sats

observatusobservatus Posts: 6
edited 2018-12-18 21:31 in Accessories
I've read many of the threads about this. I have an old PMB-648 and it will not sync. The unit has a solid 5 volts, close to 5.22 if the meter is trusted. Its been outside for about 25 minutes and is still flashing. The device used to work well. Its been off for a couple of years since it was used. Is there any reason (age?) that would prevent it from working. I have it outside for a prolonged period of time because someone posted that the sats have to download if it is viewed as a first time connect. And at this age, and inactivity, I am sure that is a possibility.

Thanks in advance for any info provided.

Comments

  • Welcome to the forums!

    First question..what platform, (MCU), are you using? Can you share some code.

    I have a couple in my box that I could pull out.
  • Arduino code, loaded to an ESP8266. The ESP have been powered down because I was worried about the interference. It does not sync either way. Code below. Want to experiment with linking the GPS to the ESP8266 down the road. Only using power and pin 2 on the ESP. Just started messing with it today.

    Thanks!

    *********************************************************************************************
    //***Sample TinyGPS code by Mikal Hart******


    #include <SoftwareSerial.h>
    #include <TinyGPS.h>
    #include <ESP8266WiFi.h>
    #include <ESP8266WebServer.h>


    const char* ssid = "**********";
    //const char* password = "************";
    const char* password = "*********";

    /* This sample code demonstrates the normal use of a TinyGPS object.
    It requires the use of SoftwareSerial, and assumes that you have a
    4800-baud serial GPS device hooked up on pins 3(rx) and 4(tx).
    */

    TinyGPS gps;
    SoftwareSerial nss(2, 3);

    static void gpsdump(TinyGPS &gps);
    static bool feedgps();
    static void print_float(float val, float invalid, int len, int prec);
    static void print_int(unsigned long val, unsigned long invalid, int len);
    static void print_date(TinyGPS &gps);
    static void print_str(const char *str, int len);

    void setup()
    {
    // Serial.begin(115200);
    Serial.begin(9600);
    nss.begin(4800);

    Serial.print("Testing TinyGPS library v. "); Serial.println(TinyGPS::library_version());
    Serial.println("by Mikal Hart");
    Serial.println();
    Serial.print("Sizeof(gpsobject) = "); Serial.println(sizeof(TinyGPS));
    Serial.println();
    Serial.println("Sats HDOP Latitude Longitude Fix Date Time Date Alt Course Speed Card Distance Course Card Chars Sentences Checksum");
    Serial.println(" (deg) (deg) Age Age (m) --- from GPS ---- ---- to London ---- RX RX Fail");
    Serial.println("
    ");
    }

    void loop()
    {
    bool newdata = false;
    unsigned long start = millis();

    // Every second we print an update
    while (millis() - start < 1000)
    {
    if (feedgps())
    newdata = true;
    }

    gpsdump(gps);
    }

    static void gpsdump(TinyGPS &gps)
    {
    float flat, flon;
    unsigned long age, date, time, chars = 0;
    unsigned short sentences = 0, failed = 0;
    static const float LONDON_LAT = 51.508131, LONDON_LON = -0.128002;

    print_int(gps.satellites(), TinyGPS::GPS_INVALID_SATELLITES, 5);
    print_int(gps.hdop(), TinyGPS::GPS_INVALID_HDOP, 5);
    gps.f_get_position(&flat, &flon, &age);
    print_float(flat, TinyGPS::GPS_INVALID_F_ANGLE, 9, 5);
    print_float(flon, TinyGPS::GPS_INVALID_F_ANGLE, 10, 5);
    print_int(age, TinyGPS::GPS_INVALID_AGE, 5);

    print_date(gps);

    print_float(gps.f_altitude(), TinyGPS::GPS_INVALID_F_ALTITUDE, 8, 2);
    print_float(gps.f_course(), TinyGPS::GPS_INVALID_F_ANGLE, 7, 2);
    print_float(gps.f_speed_kmph(), TinyGPS::GPS_INVALID_F_SPEED, 6, 2);
    print_str(gps.f_course() == TinyGPS::GPS_INVALID_F_ANGLE ? "*** " : TinyGPS::cardinal(gps.f_course()), 6);
    print_int(flat == TinyGPS::GPS_INVALID_F_ANGLE ? 0UL : (unsigned long)TinyGPS::distance_between(flat, flon, LONDON_LAT, LONDON_LON) / 1000, 0xFFFFFFFF, 9);
    print_float(flat == TinyGPS::GPS_INVALID_F_ANGLE ? 0.0 : TinyGPS::course_to(flat, flon, 51.508131, -0.128002), TinyGPS::GPS_INVALID_F_ANGLE, 7, 2);
    print_str(flat == TinyGPS::GPS_INVALID_F_ANGLE ? "*** " : TinyGPS::cardinal(TinyGPS::course_to(flat, flon, LONDON_LAT, LONDON_LON)), 6);

    gps.stats(&chars, &sentences, &failed);
    print_int(chars, 0xFFFFFFFF, 6);
    print_int(sentences, 0xFFFFFFFF, 10);
    print_int(failed, 0xFFFFFFFF, 9);
    Serial.println();
    }

    static void print_int(unsigned long val, unsigned long invalid, int len)
    {
    char sz[32];
    if (val == invalid)
    strcpy(sz, "*******");
    else
    sprintf(sz, "%ld", val);
    sz[len] = 0;
    for (int i=strlen(sz); i<len; ++i)
    sz = ' ';
    if (len > 0)
    sz[len-1] = ' ';
    Serial.print(sz);
    feedgps();
    }

    static void print_float(float val, float invalid, int len, int prec)
    {
    char sz[32];
    if (val == invalid)
    {
    strcpy(sz, "*******");
    sz[len] = 0;
    if (len > 0)
    sz[len-1] = ' ';
    for (int i=7; i<len; ++i)
    sz = ' ';
    Serial.print(sz);
    }
    else
    {
    Serial.print(val, prec);
    int vi = abs((int)val);
    int flen = prec + (val < 0.0 ? 2 : 1);
    flen += vi >= 1000 ? 4 : vi >= 100 ? 3 : vi >= 10 ? 2 : 1;
    for (int i=flen; i<len; ++i)
    Serial.print(" ");
    }
    feedgps();
    }

    static void print_date(TinyGPS &gps)
    {
    int year;
    byte month, day, hour, minute, second, hundredths;
    unsigned long age;
    gps.crack_datetime(&year, &month, &day, &hour, &minute, &second, &hundredths, &age);
    if (age == TinyGPS::GPS_INVALID_AGE)
    Serial.print("******* ******* ");
    else
    {
    char sz[32];
    sprintf(sz, "%02d/%02d/%02d %02d:%02d:%02d ",
    month, day, year, hour, minute, second);
    Serial.print(sz);
    }
    print_int(age, TinyGPS::GPS_INVALID_AGE, 5);
    feedgps();
    }

    static void print_str(const char *str, int len)
    {
    int slen = strlen(str);
    for (int i=0; i<len; ++i)
    Serial.print(i<slen ? str : ' ');
    feedgps();
    }

    static bool feedgps()
    {
    while (nss.available())
    {
    if (gps.encode(nss.read()))
    return true;
    }
    return false;
    }
  • Does the GPS code from this page work?

    https://learn.parallax.com/KickStart
  • The unit should work. Age not a factor as the satellites in the sky have not changed in years.

    The only thing that changes is where the satellites are and which ones.

    Sometimes these old unit can get stuck and will not relearn what satellites are in view.

    Mike

  • observatusobservatus Posts: 6
    edited 2018-12-17 00:44
    Publison wrote: »
    Does the GPS code from this page work?

    https://learn.parallax.com/KickStart

    Not sure if the GPS code works. Seems to. Here is the serial monitor data............

    Frankly I have not gotten very far into the code, and I'm not an expert at C code. But the flashing continues even without the code. As disconnected the ESP and just powered by the PMB and it flashes for over 30 minutes outside. So I think that means it's not connecting. So that was my first focus.

    Thanks for looking at this on a Sunday. Its kind of a hobby for me, so I GREATLY appreciate you taking the time.

    Sizeof(gpsobject) = 120

    Sats HDOP Latitude Longitude Fix Date Time Date Alt Course Speed Card Distance Course Card Chars Sentences Checksum
    (deg) (deg) Age Age (m) --- from GPS ---- ---- to London ---- RX RX Fail
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 163 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 326 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 507 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 670 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 833 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 996 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 1159 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 1340 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 1503 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 1666 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 1829 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 1992 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 2173 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 2336 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 2499 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 2662 0 0
    **** **** ******* ******* **** 00/00/2000 198:96:72 **** ******* ****** ***** *** 0 0.00 *** 2825 0 0
  • iseries wrote: »
    The unit should work. Age not a factor as the satellites in the sky have not changed in years.

    The only thing that changes is where the satellites are and which ones.

    Sometimes these old unit can get stuck and will not relearn what satellites are in view.

    Mike

    Thanks Mike, duly noted. Is there anyway to reset the device using the other pins. Sorry, might be in the documentation. Frankly the darn this was so easy to light up and code when I first hooked it up that I didn't read much about it. I'll look deeper, but if you happen to know of the top of your head let me know. Thanks!

    P.S. iSeries? If that is a reference to the AS400 I just want to say that is a badass machine. My company does software for supply chain and we interface with the iSeries with custom APIs the client IT creates in their apps on the iSeries. Darn solid system from IBM.
Sign In or Register to comment.