|
Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
module used to send GPS data over a Tawaki UART for extern instrument using NMEA protocol Exemple of use : MAPIR camera stores GPS data in metadata on each frame More...
#include "modules/gps/gps_nmea_send.h"#include "mcu_periph/uart.h"#include "generated/airframe.h"#include "state.h"#include "modules/gps/gps.h"#include <string.h>#include <stdio.h>#include <stdint.h>#include <stdlib.h>#include <math.h>#include <inttypes.h>Go to the source code of this file.
Functions | |
| static void | recover_gps_data (void) |
| Function to recover data available onboard from GPS. | |
| static void | build_nmea_sentence (void) |
| Function to build sentence for NMEA Protocol. | |
| static uint8_t | nmea_checksum (const char *sentence, int length) |
| Function to calculate checksum. | |
| static void | nmea_convert_deg_to_DDMM (double deg, char *buf, int is_lat) |
| Function to convert lat long in DDLL.MMMM Format Lat and long don't have the same length. | |
| static void | gps_nmea_get_system_date_str (char *buf_date, size_t buf_date_size, char *buf_time, size_t buf_time_size) |
| Get Date from system. | |
| static void | nmea_send (const char *payload, int payload_length) |
| Function to send payload to UART. | |
| void | gps_nmea_send_init (void) |
| Initialization function. | |
| void | gps_nmea_send_periodic (void) |
| Periodic function to send data. | |
Variables | |
| struct Gps_Nmea_Send | gps_nmea_send |
module used to send GPS data over a Tawaki UART for extern instrument using NMEA protocol Exemple of use : MAPIR camera stores GPS data in metadata on each frame
Definition in file gps_nmea_send.c.
|
static |
Function to build sentence for NMEA Protocol.
Definition at line 105 of file gps_nmea_send.c.
References gps, GPS_FIX_3D, gps_nmea_get_system_date_str(), gps_nmea_send, nmea_checksum(), nmea_convert_deg_to_DDMM(), and nmea_send().
Referenced by gps_nmea_send_periodic().
|
static |
Get Date from system.
Definition at line 221 of file gps_nmea_send.c.
References gps.
Referenced by build_nmea_sentence().
| void gps_nmea_send_init | ( | void | ) |
| void gps_nmea_send_periodic | ( | void | ) |
Periodic function to send data.
Definition at line 72 of file gps_nmea_send.c.
References build_nmea_sentence(), and recover_gps_data().
|
static |
Function to calculate checksum.
Definition at line 190 of file gps_nmea_send.c.
Referenced by build_nmea_sentence().
|
static |
Function to convert lat long in DDLL.MMMM Format Lat and long don't have the same length.
Definition at line 203 of file gps_nmea_send.c.
Referenced by build_nmea_sentence().
|
static |
Function to send payload to UART.
Definition at line 273 of file gps_nmea_send.c.
References uart_put_buffer().
Referenced by build_nmea_sentence().
|
static |
Function to recover data available onboard from GPS.
Definition at line 82 of file gps_nmea_send.c.
References gps, gps_nmea_send, NormCourseRad, stateGetHmslOrigin_f(), stateGetHorizontalSpeedDir_f(), stateGetHorizontalSpeedNorm_f(), stateGetPositionEnu_f(), stateGetPositionLla_f(), and EnuCoor_f::z.
Referenced by gps_nmea_send_periodic().
| struct Gps_Nmea_Send gps_nmea_send |
Definition at line 43 of file gps_nmea_send.c.
Referenced by build_nmea_sentence(), gps_nmea_send_init(), and recover_gps_data().