Logo Search packages:      
Sourcecode: garmindev version File versions  Download package

Garmin::IDevice Class Reference

#include <IDevice.h>

Inheritance diagram for Garmin::IDevice:


List of all members.

Detailed Description

interface class for device driver plugins

This is the common interface to all devices. The application uses this definition to gain access to the plugin. Thus if you are an application programmer simply load the plugin, resolve and call the init function. The object you will get will be of type IDevice. There is no need to link against libgarmin.a.

If you are a plugin programmer you will rather use IDeviceDefault, than IDevice. The inheritance chain will look like:

IDevice -> IDefaultDevice -> CDevice

Thus if you miss a public method you have to add it here as pure virtual and as a default implementation to IDeviceDefault.

NOTE: If you change this interface you _must_ increment the version number defined by INTERFACE_VERSION. This is important to prevent crashes due to different interface definitions.

Most likely your device driver will implement the protected methods with leading '_' of IDeviceDefault.

Definition at line 422 of file IDevice.h.

Public Member Functions

virtual void downloadTracks (std::list< Garmin::Track_t > &tracks)=0
 download track from device
virtual void downloadWaypoints (std::list< Garmin::Wpt_t > &waypoints)=0
 download waypoints from device
virtual const std::string & getCopyright ()=0
 get the copyright notice of this driver
virtual void getDevProperties (Garmin::DevProperties_t &properties)=0
 get the device's properties.
virtual const std::string & getLastError ()=0
 get reason string for last exception
virtual void getRealTimePos (Garmin::Pvt_t &pvt)=0
 request real time position
virtual void queryMap (std::list< Map_t > &maps)=0
 query loaded map list
virtual void screenshot (char *&clrtbl, char *&data, int &width, int &height)=0
 download a screenshot from the device
void setGuiCallback (void(*func)(int, int *, int *, const char *, const char *, void *), void *p)
 setup gui callback for user interaction
virtual void setPort (const char *port)=0
 set port string used for communication
virtual void setRealTimeMode (bool on)=0
 switch device into realtime position mode
virtual void uploadCustomIcons (std::list< Garmin::Icon_t > &icons)=0
 upload custom icons to device
virtual void uploadMap (const char *filename, uint32_t size, const char *key)=0
 alternative map uppload API
virtual void uploadMap (const uint8_t *mapdata, uint32_t size, const char *key)=0
 upload a single map file to device
virtual void uploadRoutes (std::list< Garmin::Route_t > &routes)=0
 upload route to device
virtual void uploadTracks (std::list< Garmin::Track_t > &tracks)=0
 upload track to device
virtual void uploadWaypoints (std::list< Garmin::Wpt_t > &waypoints)=0
 upload waypoints to device

Protected Attributes

void(* _callback_ )(int, int *, int *, const char *, const char *, void *)
 see setGuiCallback()
void * _self_
 see setGuiCallback()

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index