Giter Club home page Giter Club logo

esp32_ublox_gps's Introduction

GPS

Gps component for easy readout of GPS coordinates in latitude/longitude format.

This component is compatible with the uBlox NEO-6 series.

Requirements

  • IDF v4.2
  • C++

How do I get set up?

Initialize the Gps object, and pass in your UART_NUM to use and Tx, Rx lines to use. The Tx line is never used, so you can pass in any Tx line.

The Rx line is the only one used, since we only read from the Gps module.

// create new object
class Gps Gps;

// init the Gps object
Gps.init(GPS_UART_NUM, GPS_UART_TX, GPS_UART_RX);

After init() is called, this spawns a new freeRTOS task handling the UART data by using a pattern detection.

Lat / long

The module reports different NMEA frames, but only the GPGLL address is used to read the lat/lng data. You can write you own parser for other addresses if you want.

After init, you can call:

Gps.getLat();
Gps.getLng();

To get lat/lng in float format.

If you like string format, you can do:

Gps.getLatStr();
Gps.getLngStr();

Other NMEA addresses

The code can be extended to support more NMEA addresses. However, I only needed the lat/long data so the reset is not implemented.

It is not 'complete' so to say...

esp32_ublox_gps's People

Stargazers

 avatar

Watchers

Peter avatar

Forkers

wireless-hazard

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.