Expand description
Interface to the data read from a gps module.
NOTE, the only data accepted in this crate is from the “$GPGGA” data stream. BE SURE the data you want is included in that data stream.
§Output
The data is output and printed in the terminal screen by using a vector to split the
data stream at every , instance. Every gps data is stored in a String format so it can
be easily accessed if you so choose.
§Examples
Basic example:
use gps_data_reader_bjarki18::GPS;
use rpi_embedded::uart::{Uart, Parity};
fn main(){
let mut gps = GPS::default();
gps.set_baud(9600);
let mut uart = Uart::new(gps.baud, Parity::None, 8, 1).unwrap();
let data_stream = uart.read_line().unwrap();
gps.read_data(data_stream);
}Structs§
- GPS
- Provides access to the data read from the gps module.