navit
0.5.3-trunk
|
The Vehicle to gain position data from the gpsd service. More...
Data Structures | |
struct | vehicle_priv |
Macros | |
#define | DEFAULT_RETRY_INTERVAL 10 |
#define | MIN_RETRY_INTERVAL 1 |
Functions | |
static void | vehicle_gpsd_io (struct vehicle_priv *priv) |
static void | vehicle_gpsd_callback (struct gps_data_t *data, const char *buf, size_t len, int level) |
static int | vehicle_gpsd_try_open (struct vehicle_priv *priv) |
static void | vehicle_gpsd_open (struct vehicle_priv *priv) |
static void | vehicle_gpsd_close (struct vehicle_priv *priv) |
static void | vehicle_gpsd_destroy (struct vehicle_priv *priv) |
static int | vehicle_gpsd_position_attr_get (struct vehicle_priv *priv, enum attr_type type, struct attr *attr) |
static struct vehicle_priv * | vehicle_gpsd_new_gpsd (struct vehicle_methods *meth, struct callback_list *cbl, struct attr **attrs) |
void | plugin_init (void) |
The plugin entry point. More... | |
Variables | |
char * | vehicle_priv::gpsd_query |
struct event_watch * | vehicle_priv::evwatch |
guint | vehicle_priv::retry_interval |
struct gps_data_t * | vehicle_priv::gps |
int | vehicle_priv::fix_type |
time_t | vehicle_priv::fix_time |
int | vehicle_priv::sats |
struct event_timeout * | vehicle_priv::retry_timer2 |
static struct vehicle_priv * | vehicle_last |
static struct vehicle_methods | vehicle_gpsd_methods |
The Vehicle to gain position data from the gpsd service.
#define DEFAULT_RETRY_INTERVAL 10 |
Referenced by vehicle_gpsd_new_gpsd().
#define MIN_RETRY_INTERVAL 1 |
Referenced by vehicle_gpsd_new_gpsd().
void plugin_init | ( | void | ) |
The plugin entry point.
The plugin entry point
The plugin entry point.
This function is called once on startup.
The plugin entry point.
The plugin entry point.
Navit, a modular navigation system. Copyright (C) 2005-2008 Navit Team
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
References dbg, lvl_debug, and vehicle_gpsd_new_gpsd().
|
static |
References callback_list_call_attr_0, vehicle_priv::cbl, dbg, vehicle_priv::direction, vehicle_priv::fix_time, vehicle_priv::fix_type, vehicle_priv::geo, vehicle_priv::hdop, vehicle_priv::height, coord_geo::lat, coord_geo::lng, LONGLONG_HEX_FMT, lvl_debug, lvl_error, lvl_info, MPS_TO_KPH, vehicle_priv::nmea_data, vehicle_priv::nmea_data_buf, startup::pos, vehicle_priv::sats, vehicle_priv::sats_signal, vehicle_priv::sats_used, vehicle_priv::speed, vehicle_priv::status, and vehicle_last.
Referenced by vehicle_gpsd_io(), and vehicle_gpsd_try_open().
|
static |
References callback_destroy(), vehicle_priv::cb, vehicle_priv::cbt, dbg, err(), event_remove_timeout(), event_remove_watch(), vehicle_priv::evwatch, vehicle_priv::gps, lvl_debug, lvl_error, and vehicle_priv::retry_timer2.
Referenced by vehicle_gpsd_destroy(), and vehicle_gpsd_io().
|
static |
References vehicle_priv::gps, vehicle_priv::gpsd_query, vehicle_priv::source, and vehicle_gpsd_close().
|
static |
References dbg, vehicle_priv::gps, lvl_debug, lvl_error, vehicle_gpsd_callback(), vehicle_gpsd_close(), vehicle_gpsd_open(), and vehicle_last.
Referenced by vehicle_gpsd_try_open().
|
static |
References attr_search(), vehicle_priv::attrs, vehicle_priv::cbl, dbg, DEFAULT_RETRY_INTERVAL, vehicle_priv::gps, vehicle_priv::gpsd_query, lvl_debug, lvl_error, MIN_RETRY_INTERVAL, attr::num, vehicle_priv::retry_interval, vehicle_priv::source, attr::str, attr::u, vehicle_gpsd_methods, and vehicle_gpsd_open().
Referenced by plugin_init().
|
static |
Open a connection to gpsd. Will re-try the connection if it fails
References vehicle_priv::cbt, dbg, event_add_timeout(), lvl_debug, lvl_error, vehicle_priv::retry_interval, vehicle_priv::retry_timer2, and vehicle_gpsd_try_open().
Referenced by vehicle_gpsd_io(), and vehicle_gpsd_new_gpsd().
|
static |
References active, attr_search(), vehicle_priv::attrs, attr::coord_geo, vehicle_priv::direction, vehicle_priv::fix_time, vehicle_priv::fix_type, vehicle_priv::fixiso8601, vehicle_priv::geo, vehicle_priv::hdop, vehicle_priv::height, vehicle_priv::nmea_data, attr::num, attr::numd, vehicle_priv::sats, vehicle_priv::sats_signal, vehicle_priv::sats_used, vehicle_priv::speed, attr::str, type, attr::type, and attr::u.
|
static |
Attempt to open the gps device. Return FALSE if retry not required Return TRUE to try again
References callback_cast, callback_new_1, vehicle_priv::cb, vehicle_priv::cbt, dbg, event_add_watch(), event_remove_timeout(), event_watch_cond_read, vehicle_priv::evwatch, vehicle_priv::gps, vehicle_priv::gpsd_query, lvl_debug, lvl_error, vehicle_priv::retry_interval, vehicle_priv::retry_timer2, vehicle_priv::source, vehicle_gpsd_callback(), and vehicle_gpsd_io().
Referenced by vehicle_gpsd_open().
struct event_watch* vehicle_priv::evwatch |
Referenced by vehicle_gpsd_close(), and vehicle_gpsd_try_open().
time_t vehicle_priv::fix_time |
Timestamp of last fix (not used)
Referenced by QNavitGeoReceiver::positionUpdated(), vehicle_gpsd_callback(), vehicle_gpsd_dbus_filter(), vehicle_gpsd_dbus_position_attr_get(), vehicle_gpsd_position_attr_get(), vehicle_gypsy_position_attr_get(), vehicle_gypsy_position_changed(), vehicle_maemo_callback(), vehicle_maemo_position_attr_get(), vehicle_qt5_position_attr_get(), vehicle_webos_gps_update(), vehicle_webos_parse_nmea(), vehicle_webos_position_attr_get(), and vehicle_webos_timeout_callback().
int vehicle_priv::fix_type |
Type of last fix (1 = valid, 0 = invalid)
Referenced by QNavitGeoReceiver::positionUpdated(), vehicle_android_fix_callback(), vehicle_android_position_attr_get(), vehicle_gpsd_callback(), vehicle_gpsd_position_attr_get(), vehicle_gypsy_fixstatus_changed(), vehicle_gypsy_position_attr_get(), vehicle_maemo_callback(), vehicle_maemo_position_attr_get(), and vehicle_qt5_position_attr_get().
struct gps_data_t* vehicle_priv::gps |
Referenced by vehicle_gpsd_close(), vehicle_gpsd_destroy(), vehicle_gpsd_io(), vehicle_gpsd_new_gpsd(), and vehicle_gpsd_try_open().
char* vehicle_priv::gpsd_query |
Referenced by vehicle_gpsd_destroy(), vehicle_gpsd_new_gpsd(), and vehicle_gpsd_try_open().
guint vehicle_priv::retry_interval |
struct event_timeout* vehicle_priv::retry_timer2 |
Referenced by vehicle_gpsd_close(), vehicle_gpsd_open(), and vehicle_gpsd_try_open().
int vehicle_priv::sats |
Number of satellites in view
Referenced by QNavitGeoReceiver::satellitesInViewUpdated(), vehicle_android_new_android(), vehicle_android_position_attr_get(), vehicle_android_status_callback(), vehicle_gpsd_callback(), vehicle_gpsd_position_attr_get(), vehicle_gypsy_position_attr_get(), vehicle_gypsy_satellite_changed(), vehicle_maemo_callback(), vehicle_maemo_position_attr_get(), and vehicle_qt5_position_attr_get().
|
static |
Referenced by vehicle_gpsd_new_gpsd().
|
static |
Referenced by vehicle_gpsd_callback(), and vehicle_gpsd_io().