mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-06-04 22:17:01 +08:00
[multigps] modified defines
This commit is contained in:
@@ -57,10 +57,6 @@
|
||||
#define GpsIsLost() !GpsFixValid()
|
||||
#endif
|
||||
|
||||
#ifndef GPS_NB_CHANNELS
|
||||
#define GPS_NB_CHANNELS 16
|
||||
#endif
|
||||
|
||||
#define GPS_VALID_POS_ECEF_BIT 0
|
||||
#define GPS_VALID_POS_LLA_BIT 1
|
||||
#define GPS_VALID_POS_UTM_BIT 2
|
||||
@@ -69,17 +65,30 @@
|
||||
#define GPS_VALID_HMSL_BIT 5
|
||||
#define GPS_VALID_COURSE_BIT 6
|
||||
|
||||
/* GPS model specific implementation or sim */
|
||||
#ifdef GPS_TYPE_H
|
||||
#include GPS_TYPE_H
|
||||
#ifndef GPS_NB_CHANNELS
|
||||
#define GPS_NB_CHANNELS 1
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef GPS_TYPE_H
|
||||
|
||||
#define PRIMARY_GPS_INSTANCE 0
|
||||
#define SECONDARY_GPS_INSTANCE 1
|
||||
|
||||
#ifndef GPS_NB_CHANNELS
|
||||
#define GPS_NB_CHANNELS 16
|
||||
#endif
|
||||
|
||||
#ifdef USE_MULTI_GPS
|
||||
#define GPS_NUM_INSTANCES 2
|
||||
#else
|
||||
#define GPS_NUM_INSTANCES 1
|
||||
#endif
|
||||
|
||||
|
||||
#define GPS_MODE_PRIMARY 0
|
||||
#define GPS_MODE_SECONDARY 1
|
||||
#define GPS_MODE_AUTO 2
|
||||
@@ -148,11 +157,6 @@ extern struct GpsState gps;
|
||||
typedef void (*ImplGpsInit)(void);
|
||||
typedef void (*ImplGpsEvent)(void);
|
||||
|
||||
|
||||
/* GPS model specific implementation or sim */
|
||||
#ifdef GPS_TYPE_H
|
||||
#include GPS_TYPE_H
|
||||
#endif
|
||||
#ifdef PRIMARY_GPS_TYPE_H
|
||||
void GpsEvent(void);
|
||||
/*
|
||||
|
||||
@@ -37,14 +37,21 @@
|
||||
#define PIKSI_HEARTBEAT_MSG
|
||||
|
||||
#if GPS_SECONDARY_PIKSI
|
||||
#ifndef PIKSI_GPS_LINK
|
||||
#define PIKSI_GPS_LINK GPS_SECONDARY_PORT
|
||||
#define SecondaryGpsImpl piksi
|
||||
#endif
|
||||
#else
|
||||
#ifndef PrimaryGpsImpl
|
||||
#define PrimaryGpsImpl piksi
|
||||
#endif
|
||||
#endif
|
||||
#if GPS_PRIMARY_PIKSI
|
||||
#ifndef PIKSI_GPS_LINK
|
||||
#define PIKSI_GPS_LINK GPS_PRIMARY_PORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
extern void piksi_gps_event(void);
|
||||
extern void piksi_gps_impl_init(void);
|
||||
|
||||
@@ -28,14 +28,20 @@
|
||||
#define GPS_UBX_H
|
||||
|
||||
#if GPS_SECONDARY_UBX
|
||||
#ifndef UBX_GPS_LINK
|
||||
#define UBX_GPS_LINK GPS_SECONDARY_PORT
|
||||
#define SecondaryGpsImpl ubx
|
||||
#endif
|
||||
#else
|
||||
#ifndef PrimaryGpsImpl
|
||||
#define PrimaryGpsImpl ubx
|
||||
#endif
|
||||
#endif
|
||||
#if GPS_PRIMARY_UBX
|
||||
#ifndef UBX_GPS_LINK
|
||||
#define UBX_GPS_LINK GPS_PRIMARY_PORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef GPS_CONFIGURE
|
||||
#warning "Please use gps_ubx_ucenter.xml module instead of GPS_CONFIGURE"
|
||||
|
||||
Reference in New Issue
Block a user